Datasheet

79
4337K–USB–04/08
AT89C5130A/31A-M
16. Interrupt System
16.1 Overview
The AT89C5130A/31A-M has a total of 11 interrupt vectors: two external interrupts (INT0 and
INT1), three timer interrupts (timers 0, 1 and 2), the serial port interrupt, SPI interrupt, Keyboard
interrupt, USB interrupt and the PCA global interrupt. These interrupts are shown in Figure 16-1.
Figure 16-1. Interrupt Control System
Each of the interrupt sources can be individually enabled or disabled by setting or clearing a bit
in the Interrupt Enable register (
Table 16-2). This register also contains a global disable bit,
which must be cleared to disable all interrupts at once.
IE1
0
3
High priority
interrupt
Interrupt
Polling
Sequence, Decreasing From
High-to-Low Priority
Low Priority
Interrupt
Global DisableIndividual Enable
EXF2
TF2
TI
RI
TF0
INT0
INT1
TF1
IPH, IPL
IE0
0
3
0
3
0
3
0
3
0
3
0
3
PCA IT
KBD IT
SPI IT
0
3
0
3
0
3
UEPINT
USBINT
0
3
TWI IT
IT0
TCON.0
IT1
TCON.2