CLK Module
Application Program Interface
2-41
Timer Counter
The timer counter changes at a relatively fast rate until it reaches a target
value. When the target value is reached, the timer counter is reset, a
timer interrupt occurs, the low-resolution time is incremented, and any
functions defined for CLK objects are run.
Table 2-1 shows the rate at which the timer counter changes, its target
value, and how the value is reset once the target value has been
reached.
Low-Resolution Time
When the value of the timer counter is reset to the value in the right-
column of Table 2-1, the following actions happen:
❏
A timer interrupt occurs
❏
As a result of the timer interrupt, the HWI object for the timer runs the
CLK_F_isr function.
Table 2-1.
Timer Counter Rates, Targets, and Resets
Platform
Timer Counter Rate
Target
Value
Value Reset
’C5501, ’C5502
Incremented at CLKOUT / (PLLDIV1 *
(TDDR+1)), where CLKOUT is the DSP clock
speed in MHz (see GBL Module Properties),
and TDDR is the value of the timer divide-
down register (see CLK Manager Properties).
PLLDIV1 is an additional divide-down factor;
DSP/BIOS assumes its value is 4. If you
change the value of PLLDIV1, timings will be
incorrect.
PRD value
Counter reset to 0.
’C5503, ’C5507,
’C5509, ’C5510,
’C5561
Decremented at CLKOUT / (TDDR+1), where
CLKOUT is the DSP clock speed in MHz (see
GBL Module Properties) and TDDR is the
value of the timer divide-down register (see
CLK Manager Properties).
0
Counter reset to PRD
value.
1x10 and 59xx
Decremented at: CLKOUT * (2^
(1)), where CLKOUT is the DSP
clock speed in MHz (see GBL Module Proper-
ties) and TCRPTV is the value in the prescalar
register (see CLK Manager Properties).
0
Counter reset to PRD
value.
OMAP 2320
Incremented at DSP clock speed
Counter
register rolls
over.
Counter reset to 0.
OMAP 2420
Incremented at the INPUTCLK rate, which is
usually either 32 kHz or 12 MHz (see CLK
Manager Properties).
Counter
register rolls
over.
Counter reset to period
register value of
0xFFFFFFFF minus
PRD value in CLK
Manager Properties.