Skip to content

TCP packet size #7640

Closed Answered by samkumar
kmfnjtze8888 asked this question in Q&A
Apr 26, 2022 · 1 comments · 3 replies
Discussion options

You must be logged in to vote

Hi @kmfnjtze8888, thanks for your interest in TCP.

The maximum segment size is defined at https://github.com/openthread/openthread/blob/main/third_party/tcplp/bsdtcp/tcp_const.h#L54. It is calculated assuming a target of 5 frames per TCP segment (that's why FRAMECAP_6LOWPAN is set to 5). In that code, MSS_6LOWPAN is set to 474; the actual amount of data in each outgoing packet comes out to 462 bytes because 12 bytes are lost due to the TCP timestamp option.

If you wish to tune this value, I would recommend first reading Section 6.1 of the TCPlp paper, which explains how the current MSS of 5 frames was chosen. In high-interference environments, it may make sense to reduce the MSS to 3 fram…

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@kmfnjtze8888
Comment options

@samkumar
Comment options

@samkumar
Comment options

Answer selected by jwhui
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants