44 #define BUF ((struct uip_tcpip_hdr *)&uip_buf[UIP_LLH_LEN])
46 #ifdef UIP_SPLIT_CONF_SIZE
47 #define UIP_SPLIT_SIZE UIP_SPLIT_CONF_SIZE
49 #define UIP_SPLIT_SIZE UIP_TCP_MSS
57 uint16_t tcplen, len1, len2;
62 if(BUF->proto == UIP_PROTO_TCP &&
63 uip_len >= UIP_SPLIT_SIZE + UIP_TCPIP_HLEN) {
65 tcplen =
uip_len - UIP_TCPIP_HLEN;
68 len1 = len2 = tcplen / 2;
69 if(len1 + len2 < tcplen) {
75 uip_len = len1 + UIP_TCPIP_HLEN;
79 BUF->len[0] = ((
uip_len - UIP_IPH_LEN) >> 8);
80 BUF->len[1] = ((
uip_len - UIP_IPH_LEN) & 0xff);
109 uip_len = len2 + UIP_TCPIP_HLEN;
113 BUF->len[0] = ((
uip_len - UIP_IPH_LEN) >> 8);
114 BUF->len[1] = ((
uip_len - UIP_IPH_LEN) & 0xff);
uint8_t uip_acc32[4]
4-byte array used for the 32-bit sequence number calculations.
uint16_t uip_ipchksum(void)
Calculate the IP header checksum of the packet header in uip_buf.
uip_len
The length of the packet in the uip_buf buffer.
void tcpip_ipv6_output(void)
This function does address resolution and then calls tcpip_output.
uIP packet forwarding header file.
Header file for the uIP TCP/IP stack.
Header for the Contiki/uIP interface.
uint8_t tcpip_output(const uip_lladdr_t *a)
Output packet to layer 2 The eventual parameter is the MAC address of the destination.
void uip_split_output(void)
Handle outgoing packets.
uint16_t uip_tcpchksum(void)
Calculate the TCP checksum of the packet in uip_buf and uip_appdata.
void uip_add32(uint8_t *op32, uint16_t op16)
Carry out a 32-bit addition.
Module for splitting outbound TCP segments in two to avoid the delayed ACK throughput degradation...
Declarations of architecture specific functions.
uip_appdata
Pointer to the application data in the packet buffer.