PDK API Guide for J721E
Timer_mgr

Introduction

===========================================================================

This is the CSL-FL API documentation for the timer_mgr module.

The following sequence of API calls must be followed to properly configure and initialize the timer_mgr.

  1. Allocate and initialize a CSL_TimermgrCfg structure. A pointer to this structure must be passed to every API function.
  2. Set the maximum number of timers to be monitored by calling the CSL_timermgrSetMaxTimers function.
  3. Write initial counter setup values to the desired timers by calling the CSL_timermgrSetTimerCnt function for each timer. All timers that will be used initially must have a setup value written to them before the timer_mgr is enabled.
  4. If timer events are desired, call the CSL_timermgrSetEventIdx function to configure the event index for each desired timer.
  5. Enable the desired timers. There are two ways to do this: a) To enable all timers, call the CSL_timermgrEnableAllTimers function. This will enable all timers from 0 .. CSL_timermgrGetMaxTimers. b) Enable (or disable) individual timers by calling the CSL_timermgrSetTimerEnable function for each timer.

    If less than half of the available timers are to be enabled initially, it is faster to enable individual timers by calling CSL_timermgrSetTimerEnable with bEnable=true. If more than half of the available timers are to be enabled initially, it is faster to call CSL_timermgrEnableAllTimers and then disable specific timers by calling CSL_timermgrSetTimerEnable with bEnable=false.

  6. Enable the timer_mgr by calling the CSL_timermgrSetEnable function with bEnable=true.

Once the timer_mgr has been configured and enabled, the following functions can be called to service the active timers: CSL_timermgrIsTimerExpired CSL_timermgrGetExpiredTimers CSL_timermgrTouchTimer

References


Sub Modules

 TIMER_MGR Data Structures
 
 TIMER_MGR Enumerated Data Types
 
 TIMER_MGR Functions