Important changes to forums and questions
All forums and questions are now archived. To start a new conversation or read the latest updates go to forums.mbed.com.
6 years, 10 months ago.
Timer API mapping to EventQueue
Hi,
I am looking for mbed OS APIs to manage timers for my application. Typical Timer APIs we have worked with earlier are
CreateTimer – creates a timer handle StartTimer – start the timer with period specified StopTimer – stop the timer DeleteTimer – Delete timer
I thought the mbed RtosTimer class could be used for it. But when I look at ARM mbed documentation about these APIs it says,
Deprecated: The EventQueue has superseded the RtosTimer. The RtosTimer and EventQueue duplicate the functionality of timing events outside of interrupt context; however, the EventQueue has additional features to handle deferring other events to multiple contexts.
looking through EventQueue documentation, I am kind of lost on how to map the timer API requirements to EventQueue. Is there a good example somewhere on how to use EventQueue for timer operations?
Thanks Santosh