simple task scheduler for times up to 6000 seconds More...
#include <Ports.h>
Public Member Functions | |
| Scheduler (byte max) | |
| initialize for a specified maximum number of tasks | |
| Scheduler (word *buf, byte max) | |
| char | poll () |
| Return next task to run, -1 if there are none ready to run, but there are tasks waiting, or -2 if there are no tasks waiting (i.e. More... | |
| char | pollWaiting () |
| same as poll, but wait for event in power-down mode. More... | |
| void | timer (byte task, word tenths) |
| set a task timer, in tenths of seconds | |
| void | cancel (byte task) |
| cancel a task timer | |
| byte | idle (byte task) |
| return true if a task timer is not running | |
simple task scheduler for times up to 6000 seconds
| char Scheduler::poll | ( | ) |
Return next task to run, -1 if there are none ready to run, but there are tasks waiting, or -2 if there are no tasks waiting (i.e.
all idle)
| char Scheduler::pollWaiting | ( | ) |
same as poll, but wait for event in power-down mode.
Uses Sleepy::loseSomeTime() - see comments there re requiring the watchdog timer.