WIZnet Developer Forum

W5100 Ignores TCP ZeroWindow

All,

I am doing network performance tests with the W5100 connected to a FPGA. I have optimised the read, write and sequenctial cycles periods to their minimum specified (80ns, 70ns and 30ns respectively). I am able to reach approximately 67Mbps sustained using a single socket (in contrast to the specified 25Mbps).

However it happends regulary that the PC receiving the data from the W5100 has a “TCP ZeroWindow” (Win=0). When this occurs the W5100 keeps on transmitting data to the PC well outside the W5100 internal 16kbyte buffers. I have captured the behaviour with Wireshark.

Please find attached the following files:

  1. A screenshot of the point where the Windows Size of the PC becomes 0 (2016-02-29 11_45_32-i2chip_00002_20160229111116.png)
  2. Wireshark capture (PCAP) of the link behaviour as described (W5100_Transmittion_Wireshark_Capture.zip)

As can be seen in the Wireshark capture the W5100 (192.168.3.100) transmits data to the PC (192.168.3.1). Once the Window Size of the PC reaches ‘0’ it remains as such. I would expect that the W5100 stops transmission until the ACK from the PC is received and the Windows Size becomes >0. However the W5100 keeps transmitting TCP packets continuously and so now and then performs a re-transmission of the TCP packet as requested (Seq=20574722). At this point the W5100 and PC are out of sequence which does not resolve anymore.

Has anyone experienced this and if yes, am I doing something wrong?
This seems to be an “issue” at TCP level for which I have no control.

All help welcome.

Many thanks,

Jasper.



W5100_Transmittion_Wireshark_Capture.zip (4.74 MB)

Jasper, I think if there’s no space in remote device’s buffers, W5100 should stop sending data, keeping its RD/WR TX pointers unchanged, and TX buffer free to 0. However it is good question what will happen if controller, even if there’s no free space in TX buffers, writes to buffers and continuously instructs W5100 with SEND command.
Are you managing the chip properly - checking is socket’s TX free size, and not updating buffer/not performing another SEND command on the content you already executed SEND command on?

Copyright © 2017 WIZnet Co., Ltd. All Rights Reserved.