RTCS send TCP packet with zero (raw) sequence number

cancel
Showing results for 
Search instead for 
Did you mean: 

RTCS send TCP packet with zero (raw) sequence number

94 Views
Contributor III

I am investigating an Ethernet connection issue on our custom PCB with K66 MCU (LQFP package). The application is utilized with MQX, and RTCS from KSDK 1.3.0 by KDS 3.0.0. The application basically initialize the RTCS when boot-up, open and listen on two sockets. Once the host PC connect to the listen port, they start to exchange information. Most of time, the application runs pretty well. However, after certain time, the connection will be closed itself.

I had chance to observe the protocol from Wireshark, and found the issue always happened when the device application sent packets with raw sequence number zero. This cause the host side keep re-sending the acknowledgment and finally close the port.

In the following screenshot, on packet 1159669, our device (10.0.4.208) was trying to send data to the host PC (10.0.4.163). However, On packet 1159733, the Sequence number (raw) was reset to zero instead of 578995+5 = 579000. All the following packets sent from the device have the wrong sequence number. Eventually, the host side close the port. The Acknowledgement number seems OK all the time.
pastedImage_1.png

pastedImage_2.png

I am not sure what cause this happened and not sure if the issue is in the application or RTCS. I did applied the RTCS 4.2.0.2 software patch and it didn't help. If you have any idea or recommendation, please let me know. Thanks your support.

Peter Shih

Tags (1)
0 Kudos
2 Replies

36 Views
NXP TechSupport
NXP TechSupport

Hi Peter:

I would suggest you refer to the attached document written by Carlos Musich. It seems  similar to your issue.

I hope it helps.

Regards

Daniel

0 Kudos

23 Views
Contributor III

Hi Daniel:

Thanks your feedback. I read through your enclosed document regarding the re-transmission timeout, and implemented the "_TCP_rto_min = 250;" in the source code after RTCS initialization. However, it doesn't help. I am still seeing the sequence number been reset to zero.

I think the situation mentioned in the document is different with our issue. In our case, the TCP re-transmission and duplicate acknowledgement are cause by unexpected sequence number. I need to find out what cause the sequence number reset to zero in the RTCS. If you have any idea or suggestion, please let me know. Thanks! Appreciate your help.

Peter Shih

0 Kudos