239
CHAPTER 14 16-BIT RELOAD TIMER
■ Operation at Underflow
When the start trigger is inputted, the value set in the 16-bit reload register (TMRLR) is reloaded to the 16-
bit timer register, starting decrementing in synchronization with the count clock. When the 16-bit timer
register (TMR) is decremented from "0000
H
" to "FFFF
H
", an underflow occurs.
• When an underflow occurs with an underflow interrupt enabled (TMCSR:INTE = 1), an underflow
interrupt is generated.
• The 16-bit reload timer operation when an underflow occurs is set by the reload select bit in the timer
control status register (TMCSR:RELD).
[One-shot mode (TMCSR: RELD=0)]
When an underflow occurs, the TMR count operation is stopped. When the next start trigger is inputted, the
value set in the TMRLR is reloaded in the TMR, starting the TMR count operation.
• In the one-shot mode, during the TMR count operation, a High-level or Low-level rectangular wave is
outputted from the TOT pin.
• The pin output level select bit in the timer control status register (TMCSR:OUTL) can be set to select
the level (High or Low) of the rectangular wave.
[Reload mode (TMCSR: RELD=1)]
When an underflow occurs, the value set in the TMRLR is reloaded to the TMR, continuing the TMR count
operation.
• In the reload mode, a toggle wave inverting the output level of the TOT pin is outputted each time an
underflow occurs during the TMR count operation.
• The pin output level select bit in the timer control status register (TMCSR:OUTL) can be set to select
the level (High or Low) of a toggle wave at starting the reload timer.
• The 16-bit reload timer can be used as an interval timer by using an underflow interrupt.
Table 14.1-2 Interval Time for the 16-bit Reload Timer
Count clock Count clock period Interval time
Internal clock mode
2
1
T(0.083 µs)
0.083 µs to 5.46 ms
2
3
T(0.33 µs)
0.33 µs to 21.8 ms
2
5
T(1.3 µs)
1.3 µs to 87.4 ms
Event count mode
2
3
T or more
0.33 µs or more
T: Machine cycle
The values in interval time and the parenthesized values are provided when the machine clock operates at 24 MHz.