![]() |
#define FW_TIME 20 |
#define FWCACHE_SIZE 2 |
#define ICMP_ECHO 8 |
#define ICMP_TE 11 |
#define ICMPBUF ((struct icmpip_hdr *)&uip_buf[UIP_LLH_LEN]) |
#define UIP_FW_DROPPED |
An error message that indicates that a packet that should be forwarded or output was dropped.
#define UIP_FW_FORWARDED |
A non-error message that indicates that a packet was forwarded.
#define UIP_FW_LOCAL |
A non-error message that indicates that a packet should be processed locally.
#define UIP_FW_NETIF | ( | ip1, | |||
ip2, | |||||
ip3, | |||||
ip4, | |||||
nm1, | |||||
nm2, | |||||
nm3, | |||||
nm4, | |||||
outputfunc | ) |
Intantiating macro for a uIP network interface.
Example:
struct uip_fw_netif slipnetif = {UIP_FW_NETIF(192,168,76,1, 255,255,255,0, slip_output)};
ip1,ip2,ip3,ip4 | The IP address of the network interface. | |
nm1,nm2,nm3,nm4 | The netmask of the network interface. | |
outputfunc | A pointer to the output function of the network interface. |
#define UIP_FW_NOROUTE |
An error message that indicates that no suitable interface could be found for an outbound packet.
#define UIP_FW_OK |
A non-error message that indicates that something went OK.
#define uip_fw_setipaddr | ( | netif, | |||
addr | ) |
Set the IP address of a network interface.
netif | A pointer to the uip_fw_netif structure for the network interface. | |
addr | A pointer to an IP address. |
#define uip_fw_setnetmask | ( | netif, | |||
addr | ) |
Set the netmask of a network interface.
netif | A pointer to the uip_fw_netif structure for the network interface. | |
addr | A pointer to an IP address representing the netmask. |
#define UIP_FW_TOOLARGE |
An error message that indicates that a packet that was too large for the outbound network interface was detected.
#define UIP_FW_ZEROLEN |
A non-error message that indicates that a zero-length packet transmission was attempted, and that no packet was sent.
void uip_fw_default | ( | struct uip_fw_netif * | netif | ) |
Register a default network interface.
All packets that don't go out on any of the other interfaces will be routed to the default interface.
netif | A pointer to the network interface that is to be registered. |
u8_t uip_fw_forward | ( | void | ) |
Forward an IP packet in the uip_buf buffer.
void uip_fw_init | ( | void | ) |
Initialize the uIP packet forwarding module.
u8_t uip_fw_output | ( | void | ) |
Output an IP packet on the correct network interface.
The IP packet should be present in the uip_buf buffer and its length in the global uip_len variable.
UIP_FW_ZEROLEN | Indicates that a zero-length packet transmission was attempted and that no packet was sent. | |
UIP_FW_NOROUTE | No suitable network interface could be found for the outbound packet, and the packet was not sent. |
void uip_fw_periodic | ( | void | ) |
Perform periodic processing.
void uip_fw_register | ( | struct uip_fw_netif * | netif | ) |
Register a network interface with the forwarding module.
netif | A pointer to the network interface that is to be registered. |
u8_t tcpip_hdr::ackno[4] [inherited] |
u16_t fwcache_entry::destipaddr[2] [inherited] |
u16_t icmpip_hdr::destipaddr[2] [inherited] |
u16_t tcpip_hdr::destipaddr[2] [inherited] |
u16_t tcpip_hdr::destport [inherited] |
u8_t tcpip_hdr::flags [inherited] |
u16_t icmpip_hdr::icmpchksum [inherited] |
u8_t icmpip_hdr::icode [inherited] |
u16_t icmpip_hdr::id [inherited] |
u16_t icmpip_hdr::ipchksum [inherited] |
u16_t tcpip_hdr::ipchksum [inherited] |
u16_t fwcache_entry::ipid [inherited] |
u16_t tcpip_hdr::ipid [inherited] |
u16_t tcpip_hdr::ipoffset [inherited] |
u16_t tcpip_hdr::len [inherited] |
u8_t tcpip_hdr::optdata[4] [inherited] |
u8_t icmpip_hdr::payload[1] [inherited] |
u8_t fwcache_entry::proto [inherited] |
u8_t tcpip_hdr::proto [inherited] |
u16_t icmpip_hdr::seqno [inherited] |
u8_t tcpip_hdr::seqno[4] [inherited] |
u16_t fwcache_entry::srcipaddr[2] [inherited] |
u16_t icmpip_hdr::srcipaddr[2] [inherited] |
u16_t tcpip_hdr::srcipaddr[2] [inherited] |
u16_t tcpip_hdr::srcport [inherited] |
u16_t tcpip_hdr::tcpchksum [inherited] |
u8_t tcpip_hdr::tcpoffset [inherited] |
u8_t tcpip_hdr::ttl [inherited] |
u8_t icmpip_hdr::type [inherited] |
u8_t fwcache_entry::unused [inherited] |
u8_t tcpip_hdr::urgp[2] [inherited] |
u8_t tcpip_hdr::wnd[2] [inherited] |