Chen,
Can you give me the RAM usage of your project,
since its similar? Mine bust 64 kB of RAM...
----- Original Message -----
Sent: Friday, February 13, 2009 4:19
PM
Subject: Re: Re: [lwip-users] Struggling
to build a TCP echo server
Maybe I missed something, but all I need to kill
my working echo server is to add this line (in the same
thread)
lSocket2 = socket(AF_INET,
SOCK_STREAM, 0);
So that my code turns into
this:
int lSocket; int lSocket2; struct sockaddr_in
sLocalAddr;
lSocket = socket(AF_INET, SOCK_STREAM, 0); lSocket2 = socket(AF_INET, SOCK_STREAM,
0);
....
Date: Fri, 13 Feb 2009 14:45:01
-0500 From: "Francois Bouchard"
<address@hidden> Subject: Re: [lwip-users] Struggling to
build a TCP echo server To: "Mailing list for lwIP users"
<address@hidden> Message-ID:
<address@hidden> Content-Type: text/plain;
charset="iso-8859-1"
I don't know any
difference/advantage/disavantage of using the netconn_* API, or maybe one
its simple, and its the one I started with. Beside this, I can show
you some of the code which has httpserver-netconn project has starting point
(with modification):
while(1)
{
// Wait for
connection newconn
= netconn_accept( conn
);
if( newconn
!= NULL )
{
/* msg
*/
printf("%s\n", lwip_strerr(netconn_err(newconn)));
while(http_server_serve(newconn) ==
ERR_OK)
{;}
/* server has encountered an error
*/
netconn_delete(newconn);
} } Francois
_______________________________________________ lwip-users mailing
list address@hidden http://lists.nongnu.org/mailman/listinfo/lwip-users
|