-
Notifications
You must be signed in to change notification settings - Fork 4
Ref::Delay
Leo Selavo edited this page Jan 13, 2016
·
1 revision
Delay is used when busy- waiting is acceptable. busy waiting means that the CPU is busy while the wait, just looping around, but not letting any other useful work done. Delay is easy to program and recommended for the beginners, but wasteful on compute resources.
For a simple example using a delay to wait for some time between blinking a LED, look at the Blink application description - or at: MansOS/apps/demo/Blink
Delay function is available at mos/include/delay.h
Wait for a number of mili- or microseconds. The availability and precision depends on the platform.
void udelay(uint16_t microseconds)
void mdelay(uint16_t miliseconds)