The idea of timer_spliter is to take a single timer and split it into multiple timers. It would take size_t template parameter which is used to create memory for N number of callbacks for each timer.
The timer spliter would have to manage associating scheduled timeouts with the time given and when an interrupt occurs will track down the associated scheduled callbacks and execute them then set the schedule to the next callback. This is effectively a form of a scheduler or event loop (see js).
The idea of
timer_spliter
is to take a single timer and split it into multiple timers. It would takesize_t
template parameter which is used to create memory for N number of callbacks for each timer.The timer spliter would have to manage associating scheduled timeouts with the time given and when an interrupt occurs will track down the associated scheduled callbacks and execute them then set the schedule to the next callback. This is effectively a form of a scheduler or event loop (see js).