cancel
Showing results for 
Search instead for 
Did you mean: 

OS with constraints for STM32F4 discovery

account-st
Associate II
Posted on February 27, 2014 at 12:03

Hello all,

I bought a STM32F4 Discovery recently, and I am trying really hard to find an OS that could help me to port a POSIX application I have developed.

The problem is that my application use some plugin mechanisms and use  POSIX dlfcn. I have tried some differents OS, as CHibiOS, FreeRTOS and eCOS, but I don't manage to find a simple one that support standard/official BSP (that could allow me to debug over the LCD screen, and to easily use Ethernet port / Wifi extension for example), and that support a File system + a dynamic loading mechanism.

If you have some idea/suggestions, I plan to give NuttX and uC/OS-III a try, if possible, but I would like to have you opinion.

Is it possible to find such a complete OS ?

Thank you by advance

--

Valentin BOUSSON

#horses-for-courses #stm32f4-discovery-os-dloading
7 REPLIES 7
chen
Associate II
Posted on February 27, 2014 at 12:46

Hi

I believe there is a stripped down version of Linux ported to STM32F4 called

uCLinux

This thread has been discussing it/supporting it :

https://my.st.com/public/STe2ecommunities/mcu/Lists/STM32Discovery/Flat.aspx?RootFolder=%2fpublic%2fSTe2ecommunities%2fmcu%2fLists%2fSTM32Discovery%2fuCLinux%20on%20STM32F429I-DISCO&FolderCTID=0x01200200770978C69A1141439FE559EB459D75800084C20D8867EAD444A5987D47BE638E0F&TopicsView=https%3A%2F%2Fmy.st...

I have not tried it - so I do not know if it supports what you want (Posix dlfcn).

account-st
Associate II
Posted on February 27, 2014 at 14:40

This threads seems awesome, unfortunatly that's not the same board as mine.

Theirs (STM32F429I-DISCO) have 2MB of Flash, and mine has only 1MB.

I will take a look, but I'm not sure it will be possible, some threads I've seen about uCLinux + stm32f4discovery are saying that's quite impossible. Thank you anyway.

Some other propositions ?

chen
Associate II
Posted on February 27, 2014 at 16:41

Hi

You have already tried the (free) ones I know.

Try cross referencing the list of RTOS

http://en.wikipedia.org/wiki/List_of_real-time_operating_systems

(why RTOS and not any OS. The STM32 is an embedded processor and has most support from RTOS)

with the list of POSIX compliant OSs

http://en.wikipedia.org/wiki/POSIX

As you have already discovered, resources (Flash and RAM) are going to be the limiting factor!

Good luck.

frankmeyer9
Associate II
Posted on February 27, 2014 at 16:59

IMHO the idea to ask for POSIX compliance for a Cortex M seems a bit overstretched.

Microcontrollers primarily target cost sensitive markets, were designers and PMs are usually put through the mill for any extra half-penny they want to add to the BOM.

Andrew Neil
Evangelist
Posted on February 27, 2014 at 23:55

As fm says, Linux is not really suited to microcontrollers.

So you need to ask yourself which is most important to you: to have Linux, or to run on a microcontroller - because the two are pretty much mutually exclusive.

account-st
Associate II
Posted on February 28, 2014 at 15:36

Hello,

Thanks for your responses;

Yes I understand well that's not possible to make big structures/OS to run over such tiny boards. However, my problem is not having Linux on my STM32F4Discovery, but an OS that implement a simple mechanism to use to load dynamically libraries.

I have formerly limited myself to shared libraries, but that could be a simple object binary file. My former application which was running on a POSIX environnement used the DLFCN ''interface'', and I'm now searching an equivalent to keep my application with the same structure on stm32f4.

eCos seems to implement an object loader on ARM processors, but not on CORTEXM ones. That seems weird to me, but I'm not an expert. Do you have any idea that could come from ?

Posted on February 28, 2014 at 15:46

Cortex-Mx processors don't have CACHE or MMU, but instead tightly couple smaller memories. For dynamic loading you need plenty of RAM to accommodate the loading and linking of the modules. This can be done, but is atypical for micro-controller based embedded applications.

If you have to use external RAM, it will be SLOW.

If you can't change your paradigm, then you'll need to pick a more appropriate target.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..