TCP protocol definitions. More...
Go to the source code of this file.
Data Structures | |
struct | tcphdr |
TCP protocol header structure. More... | |
struct | _TCPPSEUDOHDR |
TCP pseudo header structure. More... | |
Defines | |
#define | TH_FIN 0x01 |
Finishing transmission. | |
#define | TH_SYN 0x02 |
Synchronizing sequence numbers. | |
#define | TH_RST 0x04 |
Reset connection. | |
#define | TH_PUSH 0x08 |
Push data to application level. | |
#define | TH_ACK 0x10 |
Acknowledge field is valid. | |
#define | TH_URG 0x20 |
Urgent data present. | |
#define | TH_FLAGS (TH_FIN | TH_SYN | TH_RST | TH_ACK | TH_URG) |
TCP flag mask. | |
#define | TCPOPT_EOL 0 |
End of options. | |
#define | TCPOPT_NOP 1 |
Nothing. | |
#define | TCPOPT_MAXSEG 2 |
Maximum segment size. | |
#define | TCPOLEN_MAXSEG 4 |
Maximum segment size length. | |
#define | TCPOPT_WINDOW 3 |
Receive window. | |
#define | TCPOLEN_WINDOW 3 |
Receive window length. | |
#define | TCP_MSS 536 |
Default maximum segment size. The maximum size of an IP datagram, that will not become fragmented, is 576. The maximum IP datagram for Ethernet is 1500. Reduce this number by 40, 20 bytes TCP header and 20 bytes IP header. | |
#define | TCP_WINSIZE 3216 |
Default window size. It's recommended to set this 6 times the maximum segment size. | |
#define | TCP_MAXWIN 65535 |
Largest value for (unscaled) window. | |
#define | TTCP_CLIENT_SND_WND 4096 |
Default send window for T/TCP client. | |
#define | TCP_MAX_WINSHIFT 14 |
Maximum window shift. | |
#define | TCP_MAXHLEN (0xf<<2) |
Maximum length of header in bytes. | |
#define | TCP_MAXOLEN (TCP_MAXHLEN - sizeof(struct tcphdr)) |
Maximum space left for options. | |
#define | TCP_NODELAY 0x01 |
Don't delay send to coalesce segments. | |
#define | TCP_MAXSEG 0x02 |
Set maximum segment size. | |
#define | TCP_NOPUSH 0x04 |
Don't push last block of write. | |
#define | TCP_NOOPT 0x08 |
Don't use TCP options. | |
Typedefs | |
typedef struct tcphdr | TCPHDR |
TCP protocol header type. | |
typedef struct _TCPPSEUDOHDR | TCPPSEUDOHDR |
TCP pseudo header type. |
TCP protocol definitions.
Definition in file tcp.h.
#define TH_FIN 0x01 |
Finishing transmission.
Definition at line 126 of file tcp.h.
Referenced by NutDumpTcpHeader(), and NutTcpOutput().
#define TH_SYN 0x02 |
Synchronizing sequence numbers.
Definition at line 127 of file tcp.h.
Referenced by NutDumpTcpHeader(), NutTcpOutput(), and NutTcpReject().
#define TH_RST 0x04 |
Reset connection.
Definition at line 128 of file tcp.h.
Referenced by NutDumpTcpHeader(), and NutTcpReject().
#define TH_PUSH 0x08 |
Push data to application level.
Definition at line 129 of file tcp.h.
Referenced by NutDumpTcpHeader(), and NutTcpOutput().
#define TH_ACK 0x10 |
Acknowledge field is valid.
Definition at line 130 of file tcp.h.
Referenced by NutDumpTcpHeader(), NutTcpOutput(), and NutTcpReject().
#define TH_URG 0x20 |
#define TH_FLAGS (TH_FIN | TH_SYN | TH_RST | TH_ACK | TH_URG) |
#define TCPOPT_MAXSEG 2 |
#define TCPOLEN_MAXSEG 4 |
#define TCP_MSS 536 |
Default maximum segment size. The maximum size of an IP datagram, that will not become fragmented, is 576. The maximum IP datagram for Ethernet is 1500. Reduce this number by 40, 20 bytes TCP header and 20 bytes IP header.
Definition at line 192 of file tcp.h.
Referenced by NutTcpCreateSocket().
#define TCP_WINSIZE 3216 |
Default window size. It's recommended to set this 6 times the maximum segment size.
Definition at line 200 of file tcp.h.
Referenced by NutTcpCreateSocket().
#define TTCP_CLIENT_SND_WND 4096 |
#define TCP_MAXHLEN (0xf<<2) |
#define TCP_MAXOLEN (TCP_MAXHLEN - sizeof(struct tcphdr)) |
#define TCP_NODELAY 0x01 |
#define TCP_MAXSEG 0x02 |
Set maximum segment size.
Definition at line 218 of file tcp.h.
Referenced by NutFtpDataConnect(), NutTcpGetSockOpt(), and NutTcpSetSockOpt().
TCP protocol header type.
TCP pseudo header type.