lwip-users
[Top][All Lists]
Advanced

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

Re: [lwip-users] tcpip thread / no_sys


From: Robert Deschambault
Subject: Re: [lwip-users] tcpip thread / no_sys
Date: Tue, 4 Aug 2015 18:28:48 -0400

Hi,

I don't think that using the raw api is recommended in a threaded environment since the lwIP core is not thread safe.  The better approach is to use the netconn or socket api and there are many examples of how to set this up with freertos and an stm32f4.

We have done multithreaded applications where multiple services (UDP echo service, TCP echo service, custom TCP service, UDP identification service) are running in different threads under cmsis-rtos/rtx and it works really well on an stm32f429. 

We use the raw api in our bootloader using a super loop to emulate "threads" for each "service" because we don't use an rtos in the bootloader.

Bob

On Aug 4, 2015 17:24, "Michael Steinberg" <address@hidden> wrote:

Hello,

during my implementation of a STM32F4 port I'm running across the
situation where I want to roll my own ip-thread, because I have more
base protocols (ptp for instance, more to come) rolling in that service
(want to use raw api) and I'm crossing thread boundaries very often. Now
the NO_SYS api would be a good match to drive lwip from my custom thread
I suppose? According to sources and documentation lwip-tcpip-thread as
well as the no_sys-api both directly incorporate the scheduling theme
instead of passing the problem to a kind of "scheduler api", which could
be exchanged. Now obviously I need timing for my own constructs in my
thread, that way I'm basically having 2 timer schedulers running in my
custom thread (ie. my own and the one lwip is doing). Is there a way to
forward lwip's timing requirements to my "timer service" without hacking
around in lwip's sources or copying/changing it over to my own sources?

Kind regards,
Michael


_______________________________________________
lwip-users mailing list
address@hidden
https://lists.nongnu.org/mailman/listinfo/lwip-users

reply via email to

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