![]() |
AKOS
v1.0.0
Documentation
|
Inter-thread synchronization is the coordination of multiple threads so their actions happen in the correct order and shared resources are used safely.
In practice, synchronization is:
In AKOS today, synchronization is intentionally lightweight. The kernel mainly uses critical sections, message queues, and scheduler-managed blocking or wakeup paths to coordinate threads. That is enough for the current design, but more complete synchronization features will need to be developed in the future if the application grows and needs richer coordination patterns.
Common synchronization mechanisms provided by RTOS kernels (such as FreeRTOS or ZephyrRTOS) include:
It has usually 2 types
AKOS does not currently expose the full set of primitives above. Instead, it relies on critical sections for protection, message queues for communication, and scheduler-managed blocking and wakeup paths for synchronization behavior. That gives the kernel a smaller surface area while still covering the most common event-driven patterns used in embedded applications.
In a small RTOS, synchronization usually serves two jobs:
AKOS currently handles those jobs with critical sections, scheduler-managed blocking, and message-based wakeups. The kernel does not expose classic mutex or semaphore APIs in the current codebase, so this chapter focuses on the mechanisms that are actually implemented today.
AKOS currently keeps synchronization lightweight. In practice, it relies on critical sections to protect shared kernel state, and it uses message-driven blocking and wakeups to coordinate threads when work becomes available.
That is enough for the current kernel design, but the model is intentionally small. As applications grow, richer synchronization primitives such as semaphores, mutexes, or event groups may be added in the future to support more complex coordination patterns.