
Rev. 1.40
126
March 29, 2019
Rev. 1.40
127
March 29, 2019
HT45F23A/HT45F24A
TinyPower
TM
Flash MCU with OPA & Comparators
HT45F23A/HT45F24A
TinyPower
TM
Flash MCU with OPA & Comparators
INTEDGE Register
Bit
7
6
5
4
3
2
1
0
Name
—
—
—
—
INT1S1
INT1S0
INT0S1
INT0S0
R/W
—
—
—
—
R/W
R/W
R/W
R/W
POR
—
—
—
—
0
0
0
0
Bit 7~4
unimplemented, read as “0”
Bit 3~2
INT1S1, INT1S0
: INT1 Edge select
00: disable
01: rising edge trigger
10: falling edge trigger
11: dual edge trigger
Bit 1~0
INT0S1, INT0S0
: INT0 Edge select
00: disable
01: rising edge trigger
10: falling edge trigger
11: dual edge trigger
External Peripheral Interrupt
The External Peripheral Interrupt operates in a similar way to the external interrupt and is contained
within the Multi-function interrupt.
For an external peripheral interrupt to occur, the global interrupt enable bit, EMI, external peripheral
interrupt enable bit, EPI, and Multi-function interrupt enable bit, EMFI, must first be set. An actual
external peripheral interrupt will take place when the external interrupt request flag, PEF, is set, a
situation that will occur when a negative transition, appears on the PINT pin. The external peripheral
interrupt pin is pin-shared with the I/O pin PB5, and is configured as a peripheral interrupt pin via
a configuration option. When the interrupt is enabled, the stack is not full and a negative transition
type appears on the external peripheral interrupt pin, a subroutine call to the Multi-function interrupt
vector at location18H, will take place. When the external peripheral interrupt is serviced, the EMI
bit will be cleared to disable other interrupts, however only the MFF interrupt request flag will be
reset. As the PEF flag will not be automatically reset, it has to be cleared by the application program.
Timer/Event Counter Interrupt
For a Timer/Event Counter interrupt to occur, the global interrupt enable bit, EMI, and the
corresponding timer interrupt enable bit, ET0I or ET1I, must first be set. An actual Timer/Event
Counter interrupt will take place when the Timer/Event Counter request flag, T0F or T1F, is set, a
situation that will occur when the Timer/Event Counter overflows. When the interrupt is enabled, the
stack is not full and a Timer/Event Counter overflow occurs, a subroutine call to the timer interrupt
vector at location 0CH or 10H, will take place. When the interrupt is serviced, the timer interrupt
request flag, T0F or T1F, will be automatically reset and the EMI bit will be automatically cleared to
disable other interrupts.