Coroutines and std::execution in Embedded Systems
This talk is about using the latest developments in C++ for really small systems.
Since C11, Standard C already provides some mechanisms to run task on multpile cores. RP2040, the processor of Raspberry Pi Pico, features two Cortex M0+ cores, but as an implementation of the Armv6-M architecture it’s not really meant for symmetric multi-processing (SMP), so std::thread is not appropriate for using these two cores.
But with coroutines in C20 and std::execution (probably in C26) there are other standard mechanisms in C++ to utilize multiple cores.
COS is a proof of concept that implements the C Standard API as pre-emptive multitasking system on bare metal. This makes it possible to explore how far the C++ Standard interfaces can provide the interface for portable embedded applications and what’s still missing.
COS also provides a partial preliminary implementation for the std::execution interface that's currently proposed for C26. This allows for more task launching control than simply std::thread.
This presentation will not go deeply into the technical details of RP2040, but will show several applications that use both cores based on the the existing and proposed mechanisms of Standard C++.