Initial AltOS import
[fw/altos] / README
1 AltOS - 8051 operating system for Altus-Metrum projects
2
3 Parameters:
4
5  * Multi-tasking
6  * Non-preemptive
7  * Unix-style sleep/wakeup scheduling
8  * Strict round-robin, no priorities
9
10 API:
11
12         int ao_sleep(void *wchan)
13
14                 Puts current task to sleep. Will wake up when wchan is signalled
15         
16         int ao_wakeup(void *wchan)
17
18                 Wakeup all tasks sleeping on wchan
19
20         void ao_add_task(struct ao_task *task)
21
22                 Adds a task to the queue of available tasks
23
24         void ao_start_scheduler(void)
25
26                 Invokes the scheduler, starting the operating system
27
28         void ao_switch(void)
29
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