Firmware · RTOS: tasks and scheduling
In a preemptive system, one task's action can instantly take the processor from another, which changes when your code runs.