Whenever using setTargetTime() function, timer behavior becomes irrelevant in case interval scheduled is less than time specified. Expected behavior is interval is recalculated or ignored.
I found two ways to fix this:
- The timer interval must be specified definetly longer than expected in application, for example (uint32_t)(-1)
- The start() function must be called before setTargetTime(). This case target time calculation happens in startFrom() is overrided.
P.S.: Found this issue when applied a MillisTimer as a scheduler.
Whenever using setTargetTime() function, timer behavior becomes irrelevant in case interval scheduled is less than time specified. Expected behavior is interval is recalculated or ignored.
I found two ways to fix this:
P.S.: Found this issue when applied a MillisTimer as a scheduler.