NetBurner 3.5.0
PDF Version
 
Interval Timer

The Interval Timer user a processor hardware timer to schedule periodic interrupts. This can be useful for applications that need to do something at reliable intervals.

The example demonstrates how to:

  • Create an IntervalTimer object
  • Trigger an interrupt and access an interrupt service routine
  • Post a semaphore
  • Post a flag

The default for the timer constructor is to use the next available system timer, but you can also specify a specific timer as an optional parameter. Depending on the application requirements, the system may also use one or more of the available timers.

Warning
Always check the return value when creating a timer object. A value of less than 0 means a timer could not be allocated.

Available Timers MODM7AE70: 0 - 11 MOD54415, MOD54417, NANO54415, SB800EX: 1-3 MODRT1061: 0 - 20