Simon Goldschmidt wrote
How come your PC retransmits with the same sequence number after 300ms?
The
Modbus implementations I know are retransmitting the application data
(i.e.
Modbus frame), not the TCP seqnos.
The retransmission is not done by the Modbus implementation but by the
Windows 7 TCP/IP stack.
For me this seems OK. Because the initial modbus frame from PC is not
acknowledged by our device (the frame containing the ACK is the frame
getting lost), Windows has to do a retransmission after some time.
Do you see a problem here?
Thinking about the retransmission from PC side:
Shouldn't lwip also do a retransmission of the lost frame?
You know, these bytes never get acknowledged by PC.
Patrick Klos-2 wrote
Based on your description, yes, LwIP is acting properly. You need to
find out why the payload packet isn't making it to the PC? How big is
the payload packet? Can you share a file with the packets from Wireshark?
The frame just contains a dozen bytes of TCP-payload, thus, with all the
TCP/IP headers the raw ethernet frame is about 65 bytes.
We are investigating where the frame gets lost.
This may be some hardware issue.
However, as Simon Goldschmidt wrote, TCP is a reliable protocol.
As far as my understanding goes, one lost ethernet frame should be no
problem because TCP/IP has mechanisms to handle this.
Again I'm wondering why lwip does not perform a retransmission after not
getting acknowledged by PC-side?
trace.pcap <http://lwip.100.n7.nabble.com/file/t2047/trace.pcap>