Today I had to use thread and mutex… So looked if this kind of stuff exists and found RealTimeOS aka RTOS.
So let’s try it on my brand new F411RE.
Open Atom with platformIO, create a new project for the board, the past the example code and… ERROR on line #include "rtos.h"
So let’s go on the online compiler and do the same… Then ERROR again !
Do you know why ? May I missed a step or so ?
Given that you use the online compiler I assume you’re using http://developer.mbed.org. In that case, have you added mbed-rtos library to your project? If the library is not included it won’t find the header files :-).
Right click on the project → Import Library → From import wizard → Search for ‘rtos’. Double click on the top hit (mbed-rtos) to add it to your project.
Finally I can import it with the online compiler as you said, but can’t do it with PlatformIO and Atom integration. Do you know if it’s possible to get the mbed-rtos library apart and then I import it separately to my IDE ?
If you right click on the project and select ‘Export’ again you’d get the full source including the rtos library. But you should also be able to add it in PlatformIO somehow.
I can’t give an extensive list, but in my opinion Yotta is a superior build system to the online compiler (includes package management, allows fully customizeable build configurations, allows users to pick their favorite code editor, doesn’t force code to be uploaded to a 3rd party website). And the new scheduler in mbed OS (minar) seems legit and user-friendly. And I’ve been told that the rtos module is coming.
Disclaimer: I’m not involved in the development of mbed or other ARM software. Maybe @janjongboom could add his perspective.
Ditto what Aaron said, plus - for many of us, the online compiler is a negative. It feels railroaded into a particular way of working (their editor + mercurial). And compiling mbed 2.0 locally feels clumsy and doesn’t seem open source.
Yep, I agree. We’re working on unifying the best of both worlds (ecosystem, RTOS vs. better build system, scheduler). We’ll share more information soon.