Tcp server disconnecting if idle for sometime

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Anonymous
Not applicable

Hi,

I want to display the data from uart to the webpage(client) via tcp connection. once data has been received wifi module(server) will transmit data to the webpage(client).

If no data has been received for more than 2 minutes(i.e. wifi module is idle) tcp serever(wifi module) is getting disconnected and webpage is showing could not connect to server.

What i have done is iam receiving the data from uart (i don't know the size of the data iam receiving so i have given that wiced_uart_receive_bytes in while condition which receives 1 character till end of string is reached, once it reaches the end of the string iam breaking that loop)after that iam checking for tcp accept and iam trying to send the data........y it is happening ??? how can i make the server not to get disconnected after sometime....please help me...

And how can I change the ThreadX/NetX_Duo to lwIP.....

Thank you!!!

0 Likes
9 Replies