[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [lwip-users] Struggling to build a TCP echo server
From: |
Kieran Mansley |
Subject: |
Re: [lwip-users] Struggling to build a TCP echo server |
Date: |
Fri, 13 Feb 2009 16:48:03 +0000 |
On Fri, 2009-02-13 at 10:50 -0500, Chen wrote:
> First, thanks to all the helping hands from the group!
>
> Weighing my options, I decided to use "real" socket programming
> instead of TCI_* raw APIs.
>
> Attached is the codes of a working echo server, running on FreeRTOS.
>
> After getting it to work, I tried to implement two echo servers on
> FreeRTOS.
>
> I duplicated the codes to a different thread, on a different port, and
> fired it up, none worked. It seems as long as I have one socket
> opened, the other will not be able to work.
Two things:
1) You should be very careful when using multiple threads with lwIP: it
is not thread-safe.
2) You may not have allocated enough PCBs to handle multiple
connections. Check your lwipopts.h
Kieran
- Re: RE: Re: [lwip-users] Struggling to build a TCP echo server, Chen, 2009/02/05
- Re: RE: Re: [lwip-users] Struggling to build a TCP echo server, Chen, 2009/02/05
- Re: Re: [lwip-users] Struggling to build a TCP echo server, Chen, 2009/02/05
- Re: [lwip-users] Struggling to build a TCP echo server, Chen, 2009/02/13
- Re: [lwip-users] Struggling to build a TCP echo server, Chen, 2009/02/13
- Re: Re: [lwip-users] Struggling to build a TCP echo server, Chen, 2009/02/13
- Re: Re: Re: [lwip-users] Struggling to build a TCP echo server, Chen, 2009/02/16