lwip-users
[Top][All Lists]
Advanced

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

Re: [lwip-users] Re: Resolving- sending data from spartan3 to another (D


From: Kieran Mansley
Subject: Re: [lwip-users] Re: Resolving- sending data from spartan3 to another (David Empson & all)
Date: Thu, 05 Feb 2009 09:32:47 +0000

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





reply via email to

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