1 AltOS - 8051 operating system for Altus-Metrum projects
7 * Unix-style sleep/wakeup scheduling
8 * Strict round-robin, no priorities
12 int ao_sleep(void *wchan)
14 Puts current task to sleep. Will wake up when wchan is signalled
16 int ao_wakeup(void *wchan)
18 Wakeup all tasks sleeping on wchan
20 void ao_add_task(struct ao_task *task)
22 Adds a task to the queue of available tasks
24 void ao_start_scheduler(void)
26 Invokes the scheduler, starting the operating system
30 Switches to another task which is ready to run. Allows
31 tasks which want to run for a while to give up the CPU
32 without needing to sleep