Chapter 10: Programmable Timer/Contents
TX7901 User’s Manual (Rev. 6.30T – Nov, 2001)
10-18
10.5.2 Pulse Generator Mode Operation
This mode is set up by setting the timer mode (TMODE) field of the Timer Control Register
(TMTCR) to 0b01 (binary). In this mode, rectangular pulses of specific frequency and duty-cycle
can be generated with the help of the two compare registers TMCPRA and TMCPRB. The
contents of TMCPRA and TMCPRB should be set up with the value in TMCPRA being less than
the value in TMCPRB.
When the Timer Counter Enable (TCE) bit of the Timer Control Register is set to “1”, the 24-bit
counter begins counting. When the counter reaches the value set in compare register TMCPRA,
the Timer Flip-Flop toggles, inverting its output, which is made available on the TMFFOUT output
of the timer/counter. The counter continues counting until the counter reaches the (larger) value
set in compare register TMCPRB. The Timer Flip-Flop toggles again, and the counter is cleared.
Setting the required state in the Flip-Flop Initialize (FFI) field of the Pulse Generator Mode
Register (TMPGMR) configures the initial state of the Timer Flip-Flop.
When the count value reaches the TMCPRA compare register value, the Pulse Generator
Interrupt Status bit for Compare Register A (TPIAS) in the Timer Interrupt Status Register
TMTISR is set to “1”. The interrupt control logic asserts TMINTREQ* when the TPIAS bit is set
and also enabled (by having the TPIAE bit of the TMPGMR register set as well). If the TPIAE bit
is cleared, it masks the TPIAS bit from being forwarded as an interrupt request and masks
assertion of TMINTREQ* Low. Similarly, the interrupt control logic asserts TMINTREQ* when the
TPIBS bit is set as well as enabled (by having the TPIBE bit of the TMPGMR register set as well).
If the TPIBE bit is cleared, it masks the TPIBS bit from being forwarded as an interrupt request
and masks assertion of TMINTREQ* Low. These interrupt requests may be respectively reset
(cleared) by clearing the TPIAS or TPIBS bits as appropriate, causing TMINTREQ* to be de-
asserted as well.
The counter can be clocked by either the internal system clock or the external clock. The CCS
bit of the Timer Counter Register is used to select the clock that controls the timer.
The selected clock is frequency divided before being used to clock the counters. When the
CCDE bit of the TMTCR register is a “1”, the three CCD bits of the divider register scale the
clock down to between 1/2 and 1/256 of the selected clock frequency. When using the internal
clock, the counter is triggered by the rising edge of the clock. When using the external clock, it
may be configured to trigger on either edge by writing a “0” or a “1” for bit ECES of the Timer
Counter Register.
Содержание TMPR7901
Страница 1: ...TX System RISC TX79 Family TMPR7901 Symmetric 2 way superscalar 64 bit CPU ...
Страница 14: ...Handling Precautions ...
Страница 15: ......
Страница 17: ...1 Using Toshiba Semiconductors Safely 1 2 ...
Страница 41: ...4 Precautions and Usage Considerations 4 2 ...
Страница 42: ...TX7901 User s Manual Rev 6 30T November 2001 DOCUMENT NUMBER M 99 00004 07 ...
Страница 43: ......
Страница 259: ...Chapter 13 Removed TX7901 User s Manual Rev 6 30T Nov 2001 13 1 13 Removed ...
Страница 260: ...Chapter 13 Removed TX7901 User s Manual Rev 6 30T Nov 2001 13 2 ...