Re:FreeRTOS meets Rust
by kartD on Tuesday September 27, 2016 @05:20PM
(#12593326)
Little off topic, but does anyone have a good resource or tutorial for FreeRTOS. I find freertos.org sparse and not really illustrative.
[ Parent
| on HN ]
The PDF manual sold by FreeRTOS, "Using the FreeRTOS Real Time Kernel - A Practical Guide", is worthwhile. I agree that the web documentation is somewhat lacking and suspect that for better or worse, it is that way in order to encourage buying the book.
I bought the book and looked through some example programs. That was enough for me to get going.
The main things you want to keep in mind is that the queues and such are not for large amounts of data. It is better, for example, to statically allocate three buffers, and then send the buffer number over a queue interface, rather than send the data itself, which involves two copy operations.
The other thing to pay attention to is that you should only be using the ISR specific versions of the API inside an ISR. That, and minimize the code in the ISRs in general, but that is applicable to anything.
I had heard about the book. Thanks for the info!
The lack of documentation was one of the reasons I ditched FreeRTOS and moved to ChibiOS, which I'm enjoying a lot. It has a much nicer API and cleaner codebase, really good demo projects, and a good discussion forum where the main developer usually answers any questions in a day or two. Unfortunately it still isn't that much better in terms of written documentation though.
The lack of vendor-agnostic hardware abstraction layer (drivers) in FreeRTOS was my main reason to use ChibiOS for my projects.
Although, libopencm3 has progressed nicely, so FreeRTOS + libopencm3 could now be a decent alternative to ChibiOS.
FreeRTOS official documentation is good enough though.
Re:FreeRTOS meets Rust
by mrlambchop on Tuesday September 27, 2016 @06:40PM
(#12593824)
Whilst not entirely the answer you're after, I highly recommend reading the micrium book for general RTOS understanding (now in its 3rd version!).