Next up are of synchronization primitives (mutex, semaphore) and stack overflow protection
The mutex implementation will be minimal (without priority inversion)
Most RTOS append tasks waiting for a semaphore to a pending list within the semaphore. Because the Bern RTOS isolates task stacks, the pending list must be kept in kernel memory. There are two possible solutions:
The kernel keeps a pending list per synchronization object. Fast but needs list for every sync object.
The kernel keeps one pending list for all sync object. Slower but needs only one list.
Off Topic:
Interrupts in uC/OS are divided into OS aware interrupts and low latency/high priority interrupts. ISR unaware of the OS must not call the RTOS. In Rust we could use procedural macros to see which ISR run outside the RTOS and could possibly check at compile time that the ISR doesn't contain any RTOS API calls.
Action Item
Owner
Due Date
Done
Close milestone Kernel v0.1.0
Stefan Lüthi
07.05.2021
Shorten/Optimize critical sections in the scheduler
Stefan Lüthi
deferred
Compare/Evaluate different pending list approaches for sync objects
Stefan Lüthi
21.05.2021
Testing on Host
Current testing strategy
Test API calls on host (off target)
Test hardware integration on target (microcontroller)
The CPU architecture is completely isolated (through trait interfaces) and mocks are provided for off target testing
Some unit tests are already running (linked-list), while others pose some issues with the mocking framework
Action Item
Owner
Due Date
Done
Implement a unit test for the scheduler to check if mocks are working
Stefan Lüthi
21.05.2021
Remote Tracing Station
The remote tracing station consists of
a SEGGER J-Trace Cortex-M edition trace adapter
a SEGGER Cortex-M trace reference board (STM32F407)
a Digilent Digital Discovery logic analyzer & pattern generator
a PC (running GNU/Linux)
The tracing station can be accessed within the bfh.ch domain.
Tracing allows for in-depth kernel execution and stack analysis.