Modules | |
Internal Time Management Functions | |
Defines | |
#define | TICKS_PER_SEC 256 |
Number of otOS system ticks per second. | |
#define | MS10 (TICKS_PER_SEC / 100) |
#define | MS20 (TICKS_PER_SEC / 50) |
#define | MS50 (TICKS_PER_SEC / 20) |
#define | MS100 (TICKS_PER_SEC / 10) |
#define | MS125 (TICKS_PER_SEC / 8) |
#define | MS200 (TICKS_PER_SEC / 5) |
#define | MS250 (TICKS_PER_SEC / 4) |
#define | MS500 (TICKS_PER_SEC / 2) |
#define | MS1000 TICKS_PER_SEC |
#define | SEC1 TICKS_PER_SEC |
#define | SEC2 (TICKS_PER_SEC * 2) |
#define | SEC5 (TICKS_PER_SEC * 5) |
#define | SEC10 (TICKS_PER_SEC * 10) |
#define | SEC20 (TICKS_PER_SEC * 20) |
#define | SEC30 (TICKS_PER_SEC * 30) |
#define | SEC40 (TICKS_PER_SEC * 40) |
#define | SEC50 (TICKS_PER_SEC * 50) |
#define | SEC60 (TICKS_PER_SEC * 60) |
#define | MIN1 (TICKS_PER_SEC * 60) |
#define | MIN2 (MIN1 * 2) |
#define | MIN5 (MIN1 * 5) |
#define | MIN10 (MIN1 * 10) |
#define | INFINITE 0xffffffffL |
Functions | |
uint32_t | otosGetTicks (void) |
Get the system tick counter. | |
void | otosSleep (uint32_t ticks) |
Block running task for specified number of ticks. | |
void | otosDelay (uint32_t ticks) |
Delay running task for specified number of ticks (wait actively, don't block task!). | |
void | otosSetTickHook (void(*pFunc)(void)) |
Set tick hook function. | |
uint32_t | otosGetTickDiff (uint32_t earlier) |
Calculate time difference between an earlier time and now. |
|
Delay running task for specified number of ticks (wait actively, don't block task!).
Definition at line 111 of file time.c. References otosGetTickDiff(), and otosGetTicks(). |
|
Calculate time difference between an earlier time and now.
Definition at line 149 of file time.c. References otosGetTicks(). Referenced by otosDelay(), and otosScheduler(). |
|
Get the system tick counter. The system tick counter is incremented TICKS_PER_SEC times per second.
Definition at line 69 of file time.c. Referenced by main(), otosDelay(), otosGetTickDiff(), and otosScheduler(). |
|
Set tick hook function. The tick hook function will be called by the system tick handler with a frequency of TICKS_PER_SEC Hz.
|
|
Block running task for specified number of ticks. If ticks is zero, immediately call scheduler
Definition at line 92 of file time.c. References g_pRunningTask, otosBlock, and otosScheduler(). |