diff --git a/drivers/TimerEvent.cpp b/drivers/TimerEvent.cpp index d7fbd42f5f..4bbe710faf 100644 --- a/drivers/TimerEvent.cpp +++ b/drivers/TimerEvent.cpp @@ -44,6 +44,10 @@ void TimerEvent::insert(timestamp_t timestamp) { ticker_insert_event(_ticker_data, &event, timestamp, (uint32_t)this); } +void TimerEvent::insert_absolute(us_timestamp_t timestamp) { + ticker_insert_event(_ticker_data, &event, timestamp, (uint32_t)this); +} + void TimerEvent::remove() { ticker_remove_event(_ticker_data, &event); } diff --git a/drivers/TimerEvent.h b/drivers/TimerEvent.h index b186c25b93..7a54c42617 100644 --- a/drivers/TimerEvent.h +++ b/drivers/TimerEvent.h @@ -44,9 +44,12 @@ protected: // The handler called to service the timer event of the derived class virtual void handler() = 0; - // insert in to linked list + // insert relative timestamp in to linked list void insert(timestamp_t timestamp); + // insert absolute timestamp into linked list + void insert_absolute(us_timestamp_t timestamp); + // remove from linked list, if in it void remove();