Ticker interrupt

03 Apr 2017

In my program, I need to run my code at a set interval (drone flightcontroller). For this I was having some questions about the Ticker class.

What happens if the time for the code triggered by the Ticker interrupt takes too long and the new interrupt fires? Will the previous routine be finished or will the new interrupt start instantly? And if the second thing happens, does this mean that the old (interrupted) routine is discarded or will it still finish when the cpu has some time left?

04 Apr 2017

If this is being controlled by the standard NVIC features of the MCU new interrupts of the same priority as the original are blocked until the first finishes.

06 Apr 2017

Thanks for the reply.

It seems that this is not the case though. A quick test which turns off a led, waits 0.5 seconds, turns the led on and then waits 0.5 seconds on a ticker frequency of 0.5 seconds does not ever show a led that is on. This makes me wonder if all the unfinished interrupts are queued or discarded...