Hi!
I'm
working with FreeRTOS v7.0.1 and LwIP 1.4.0 and I'm facing the
following problem:
Device
A and B transmit data every 40 ms to my board (where I'm
running LwIP) and once in a while I can notice some data from
device A is being missed.
So
I did some research with CommView and found that:
1)
Device A sends data (9 bytes length) to my board and get
correct ACK from it:
Sequence: 0x13D5388C (332740748)
|
Acknowledgement:
0x00001A57 (6743) |
Response
from my board:
Sequence: 0x00001A57 (6743) |
|
Acknowledgement:
0x13D53895 (332740757) |
2)
Device A send 9-bytes data to my board, but this won´t ACK:
Sequence: 0x13D5389E
(332740766) |
Acknowledgement:
0x00001A57 (6743) |
Sequence: 0x00001A57 (6743) |
|
Acknowledgement:
0x13D5389E (332740766) |
3)Device
A does not care about it (maybe because data is already in
ethernet transceiver buffer) and sends a new data (9-bytes);
my board will not ACK it:
Sequence: 0x13D538A7
(332740775) |
Acknowledgement:
0x00001A57 (6743) |
Sequence: 0x00001A57 (6743) |
|
Acknowledgement:
0x13D5389E (332740766)
4)Same as 3
Sequence: 0x13D538B0 (332740784) |
Acknowledgement:
0x00001A57 (6743) |
Sequence: 0x00001A57
(6743) |
|
Acknowledgement: 0x13D5389E
(332740766) |
|
5)
Same as 3
Sequence: 0x13D538B9
(332740793) |
Acknowledgement:
0x00001A57 (6743) |
Sequence: 0x00001A57 (6743) |
|
Acknowledgement:
0x13D5389E (332740766) |
6)
Finally, device A is aware of the problem and retransmits
data, but instead of transmitting 36 bytes (9 x 4), only
transmits 18 bytes
Sequence: 0x13D5389E
(332740766) |
Acknowledgement:
0x00001A57 (6743) |
And
my board running Lwip 1.4.0 will acknowledge 36 bytes instead
of 18:
Sequence: 0x00001A57 (6743) |
|
Acknowledgement:
0x13D538C2 (332740802)
|
So
device A won´t transmit last two 9-bytes packets, and they
will be lost!
Anyone
can help me with this? Is it a bug in LwIP or what is
happening?
Thank
you!