
Rev. 1.00
5�
��ne 1�� �01�
Rev. 1.00
53
��ne 1�� �01�
HT46R003B
Cost-Effective A/D 8-bit OTP MCU
HT46R003B
Cost-Effective A/D 8-bit OTP MCU
Interrupts
Interrupts are an important part of any microcontroller system. When an external event or an internal
function such as a Timer/Event Counter requires microcontroller attention, their corresponding
interrupt will enforce a temporary suspension of the main program allowing the microcontroller to
direct attention to their respective needs.
The device contains only one external interrupt and multiple internal interrupts. The external
interrupts are controlled by the action of the external interrupt pin, while the internal interrupt is
controlled by the Timer/Event Counter, the A/D converter interrupt and Timer Base interrupt.
Interrupt Register
Overall interrupt control, which means interrupt enabling and request flag setting, is controlled by
using registers, INTC0 and INTC1. By controlling the appropriate enable bits in the register each
individual interrupt can be enabled or disabled. Also when an interrupt occurs, the corresponding
request flag will be set by the microcontroller. The global enable flag cleared to zero will disable all
interrupts.
Function
Enable Bit
Request Flag
Global
EMI
—
INT Pin
INTE
INTF
Timer
TE
TF
A/D Converter
ADE
ADF
Timer Base
TBE
TBF
INTC0 Register
Bit
7
6
5
4
3
2
1
0
Name
—
ADF
TF
INTF
ADE
TE
INTE
EMI
R/W
—
R/W
R/W
R/W
R/W
R/W
R/W
R/W
POR
—
0
0
0
0
0
0
0
Bit 7
Unimplemented, read as "0"
Bit 5
ADF
: A/D interrrupt request flag
0: No request
1: Interrupt request
Bit 5
TF
: Timer/Event Counter interrrupt request flag
0: No request
1: Interrupt request
Bit 4
INTF
: INT pin interrupt request flag
0: No request
1: Interrupt request
Bit 3
ADE
: A/D interrupt control
0: Disable
1: Enable
Bit 2
TE
: Timer/Event Counter interrupt control
0: Disable
1: Enable
Bit 1
INTE
: INT interrupt control
0: Disable
1: Enable
Bit 0
EMI
: Global interrupt control
0: Disable
1: Enable