166
CHAPTER 5 TIMEBASE TIMER
5.4
Timebase Timer Interrupt
As an interrupt source of the timebase timer, an overflow of the specified bit of the
timebase timer counter is available (interval timer function).
I
Interrupt when the Interval Timer Function is Active
If an overflow of the selected interval timer bit occurs after the counter is counted up by the
internal count clock, the overflow interrupt request flag bit (TBTC: TBOF) is set to "1". At this
time, if the interrupt request enable bit is set (TBTC: TBIE=1), an interrupt request to CPU
(IRQ7) is generated. Clear the interrupt request by writing "0" into the TBOF bit using an
interrupt processing routine. The TBOF bit is set whenever an overflow of the specified bit
occurs regardless of the value of the TBIE bit.
Note:
To allow interrupt request output (TBIE=1) after releasing a reset, clear (TBOF=0) the TBOF
bit at the same time.
Reference:
If the TBIE bit is changed from prohibition to permission (0 --> 1) when the TBOF bit is "1",
an interrupt request is issued immediately.
If the counter clear (TBTC: TBR=0) and an overflow of the selected bit occur at the same
time, the TBOF bit is not set.
I
Oscillation Stabilization Wait Time and Timebase Timer Interrupts
If interval time shorter than the oscillation stabilization wait time of the main clock is set, an
interval interrupt request (TBTC: TBOF=1) of the timebase timer is generated when the
operation in main clock mode starts. In this case, prohibit (TBTC: TBIE=0) interrupts of the
timebase timer when making a transition to a mode in which the oscillation of the main clock
stops (main stop and subclock modes).
I
Register and Vector Table Related to the Timebase Timer Interrupts
For the interrupt operations, see Section 3.4.2 "Interrupt Processing".
Table 5.4-1 Register and Vector Table Related to the Timebase Timer Interrupts
Interrupt
name
Interrupt level setting register
Vector table address
Register
Bit to be set
Upper
Lower
IRQ7
ILR2 (007C
H
)
L71 (bit 7)
L70 (bit 6)
FFEC
H
FFED
H