The situation
The startup (around EUR 4M ARR, 280 drones deployed) has had 2 near-crash incidents traced to control-loop jitter and cannot ship the next product line without a real RTOS.
Your task
Port a Cortex-M7 flight controller from a bare-metal super-loop to FreeRTOS and prove the 1 kHz control-loop deadline is met under worst-case load.
The brief
What you do
- Take the existing bare-metal firmware (STM32H7, around 14,000 lines C).
- Identify the tasks (control loop 1 kHz, IMU read 2 kHz, GPS 10 Hz, telemetry 50 Hz, command parsing event-driven, logging background).
- Assign priorities, stack sizes, and synchronization primitives.
- Use Rate-Monotonic scheduling theory for the priority assignment and document the schedulability analysis.
- Port to FreeRTOS, validate on the hardware-in-the-loop rig (provided), measure worst-case execution time (WCET) per task with a logic analyzer + cycle-accurate counter.
You deliver
Source code, the schedulability analysis, and a 10-page writeup including measured vs theoretical jitter.
What you will practice
- Apply Rate-Monotonic scheduling theory to a real embedded task set
- Port bare-metal firmware to an RTOS without regressing real-time behavior
- Measure worst-case execution time with cycle-accurate instrumentation
- Choose synchronization primitives (mutex, semaphore, queue) appropriate to each task interaction
A suggested way in
- Liu & Layland's 1973 RMS paper is still the canonical reference for the priority assignment
- Priority inversion is the usual FreeRTOS bug — use mutexes with priority inheritance, not semaphores
- Measure WCET on the hardware, not the simulator — cache effects matter
Skills you will practice
Freertos, Rate monotonic scheduling, C programming, Wcet analysis, Arm cortex m, Real time systems
How it is assessed
- Schedulability analysis30%
Task priorities + WCET budgets validated against Rate-Monotonic bound.
- RTOS port quality25%
Synchronization primitives chosen correctly; no priority inversion under test.
- Measurement rigor25%
WCET measured with logic analyzer + cycle counter on real hardware.
- Writeup clarity20%
Analysis is reproducible by another firmware engineer with the writeup alone.
Resources
- FreeRTOSTool
Target RTOS for the port — widely deployed and well-documented.
- CTool
Implementation language for firmware.
- STM32CubeIDETool
Vendor IDE with HAL drivers and debugging support.
- TracealyzerTool
RTOS-aware trace visualization for jitter analysis.
- Saleae LogicTool
Logic analyzer for WCET measurement via GPIO instrumentation.
- NotionTool
Author schedulability analysis and writeup.
Finish it. Earn this.
A verified certificate with your name. Anyone can check it.
Time to practice.
Solve this challengeMore like this.
- Software EngineerBuild a Multi-Level Feedback Queue Scheduler in xv6
- Software EngineerReverse-Engineer a Stripped Binary to Restore Linking Symbols
- Software EngineerImplement a Distance-Vector Routing Algorithm
- AI EngineerEnd-to-End Lane Following on a Donkeycar Platform
-
Build a Multi-Level Feedback Queue Scheduler in xv6 Software Engineer Fork the xv6-riscv repository and implement MLFQ in proc.c with 3 priority queues, per-queue time slices (10ms / 20ms / 40ms), priority demotion on sl operating systemsschedulingc programming Open challenge → -
Reverse-Engineer a Stripped Binary to Restore Linking Symbols Software Engineer Receive the stripped shared object (Linux ELF, x86-64, ~280KB), a crash dump with 12 frames of indecipherable addresses, and 4 years of partial git hi reverse engineeringlinking and loadingmachine code Open challenge → -
Implement a Distance-Vector Routing Algorithm Software Engineer Implement distance-vector routing in Python: each simulated router maintains a distance vector, exchanges vectors with neighbors every 1 second of sim routingdistance vectornetwork simulation Open challenge → -
End-to-End Lane Following on a Donkeycar Platform AI Engineer Use the public Donkeycar Tub dataset (or collect about 30 minutes of driving on the simulator). Train a CNN-policy baseline (the Donkeycar default arc end to end learningimitation learningpytorch Open challenge →