Time Base Interrupt
The function of the Time Base Interrupt is to provide regular time signal in the form of an internal
interrupt. It is contained within the Multi-function interrupt and controlled by the overflow signal
from its internal timer. When this happens its interrupt request flag, TBnF, will be set. To allow
the program to branch to its respective interrupt vector addresses, the global interrupt enable bit,
EMI, Time Base enable bit, TBnE, and Multi-function interrupt enable bit must first be set. When
the interrupt is enabled, the stack is not full and the Time Base overflows, a subroutine call to its
respective Multi-function interrupt vector location will take place. When the interrupt is serviced,
the EMI bit will automatically be cleared to disable other interrupts. Also the corresponding Multi-
function interrupt request flag will be automatically reset. As the interrupt request flag, TBnF, will
not be automatically reset, it has to be cleared by the application program.
The purpose of the Time Base Interrupt is to provide an interrupt signal at fixed time periods. Its
clock source, f
PSC0
passes through a divider, the division ratio of which is selected by programming the appropriate bits
in the TB0C and TB1C registers to obtain longer interrupt periods whose value ranges. The clock
source which in turn controls the Time Base interrupt period is selected using the CLKSEL0[1:0]
and CLKSEL1[1:0] bits in the PSC0R and PSC1R register respectively.
f
M
SYS
f
/4
U
SYS
f
X
SUB
CLKSEL0[1:0]
f
M
SYS
f
/4
U
SYS
f
X
SUB
CLKSEL1[1:0]
PSC0R Register
Bit
7
Name
—
R/W
—
POR
—
Bit 7~2
Unimplemented, read as "0"
Bit 1~0
CLKSEL01~CLKSEL00: Prescaler 0 clock source
00:
01:
1x:
Rev. 1.60
Advanced A/D Flash MCU with LCD & EEPROM
or f
, originates from the internal clock source f
PSC1
TB0ON
8
f
/2
~ f
/2
f
PSC0
PSC0
PSC0
Prescaler 0
8
f
/2
~ f
/2
f
PSC1
PSC1
PSC1
Prescaler 1
TB1ON
Time Base Interrupts
6
5
4
—
—
—
—
—
—
—
—
—
f
SYS
f
/4
SYS
f
SUB
262
HT67F2350/HT67F2360
HT67F2370/HT67F2390
, f
/4 or f
SYS
SYS
M
15
U
Time Base 0 Interrupt
X
TB0[2:0]
15
M
U
Time Base 1 Interrupt
X
TB1[2:0]
3
2
1
—
—
CLKSEL01 CLKSEL00
—
—
R/W
—
—
0
f
selection
PSC0
and then
SUB
0
R/W
0
May 16, 2019
Need help?
Do you have a question about the HT67F2350 and is the answer not in the manual?