pico-sdk
pico-sdk copied to clipboard
Add alarm_pool_remaining_time()
Add a function that returns the time remaining before triggering for a given pool and alarm id It uses difference between an alarm register and the timerawl register. (see RP2040 datasheet chapter 4.6.3) It also check that the alarm for which we're asking the remaining time is the actual one running on the hardware timer (and not in the alarm pool)
Refer to #1628
fixes #1628
will fix this internally as part of redoing the alarm pool implementation; note the return should be 64 bit.
added