On Thu, 2009-02-05 at 12:59 +0530, devesh wrote:

> Anyways, can I put " tcp_write(pcb, test, n, 1);" in loop, but
> conncetion gets closed after sending 1024.

Here's how you're supposed to do it: use tcp_snd_buf() to find out how
much space there is, and call tcp_write() to send that much.  Wait until
your tcp_sent() callback is called, then call tcp_snd_buf() to find out
how much space there is, and call tcp_write() to send that much.  And so
on.  This is all described in the documentation for the raw api
(lwip/doc/rawapi.txt) - I think you would do well to read that.

Kieran



_______________________________________________
lwip-users mailing list
[email protected]
http://lists.nongnu.org/mailman/listinfo/lwip-users

Reply via email to