lwip-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[lwip-users] TCP full-duplex communication problem


From: pekez
Subject: [lwip-users] TCP full-duplex communication problem
Date: Thu, 8 Dec 2016 00:43:44 +0100
User-agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.5.0

Hi guys,

me again, with new question. :)

On my client side (PC) right now I have two threads, one thread only sending, whreas other one is always receiving. Both threads work with same socket. On the server side (ZYNQ) I have the same thing, one thread receiving, while other is sending.

Now, when I test only one direction independently, let's say only sending from PC to ZYNQ, or vice verca sending from ZYNQ to PC, everything works fine. However, I need everything to work simultaneously, and when I let all threads start working, next thing happens: both threads on PC finish working as expected, while on the ZYNQ, one thread finish working as expected, most often the one that is sending, while the other one never receives all the data it is supposed to receive, as though the socket is closed or something (it's not, I checked carefully). Nothing is happening at all, I am looking in Wireshark, and there is just no communication at all after the first thread on the ZYNQ finish working.

I also tried to make two separate connections so that one direction (PC--->ZYNQ) is working over one socket, and other one (PC<---ZYNQ) over some other socket. This works much better, never have similiar problems on ZYNQ side, but really rarely even in this case, communication stops working, but this time the problem seems to be PC side, again when one thread finish before the other, I am getting some kind of strange messages in Wireshark, such as "tcp acked unseen segment".

I have made referent server application for PC, and when communication is PC to PC, everything is OK, so I assume that it's some kind of problem with lwIP, which can be solved maybe by changing some options in lwipopts.h (I hope it's only that :) ). I guess is hard to help with only this much of information, but maybe someone has already faced similar problems.

I am working with Socket API, lwIP v1.4.1 with FreeRTOS v8.2.3.

Best regards,
and thanks in advance.


---
This email has been checked for viruses by Avast antivirus software.
https://www.avast.com/antivirus




reply via email to

[Prev in Thread] Current Thread [Next in Thread]