[Top][All Lists]

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

Re: [lwip-users] Raw TCP - PBuf segment not decreasing

From: LRA_
Subject: Re: [lwip-users] Raw TCP - PBuf segment not decreasing
Date: Mon, 18 Mar 2019 11:08:00 -0700 (MST)

Thank you for the reply.
The example provided is not very good to explain how to use all that so I
probably did something wrong.

I actually didn't quite understand how to use tcp_sent() since I didn't
understand where the argument came from (the buffer to send). I will try to
find out more about how to use it in this case without OS.

What you mean by " but remember both must be on the same context" is that I
should not use tcp_write in normal run code and tcp_output inside interrupt
routine? Since this has no threads. 

What I would try from this is:
- set up tcp_sent() callback
- Call tcp_write at 2Khz (or whatever).
- If tcp_write has the current buffer full, set new buffer for tcp_sent to
- Call tcp_output inside tcp_sent() callback. After that, let it call
tcp_write if there is extra data.

Sent from: http://lwip.100.n7.nabble.com/lwip-users-f3.html

reply via email to

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