www
.mcu.com.cn
204
/
239
Rev.
1.00
CMS80F731x Reference Manual
22.5 UARTn Interrupt
The interrupt number of UART0 is 4, where the interrupt vector is 0x0023.
The interrupt number of UART1 is 6, where the interrupt vector is 0x0033.
To enable a UARTn interrupt, it must set its enable bit ESn to 1 and the global interrupt enable bit EA to 1. If the interrupt
enables associated with UARTn are turned on, TIn=1 or RIn=1, the CPU will enter the corresponding interrupt service program.
TIn/RIn is independent of the state of ESn and requires software zeroing, which describes the reference register SCONn in
detail.
22.5.1
Interrupt Mask Register IE
0xA8
Bit7
Bit6
Bit5
Bit4
Bit3
Bit2
Bit1
Bit0
IE
SHE
ES1
ET2
ES0
ET1
EX1
ET0
EX0
R/W
R/W
R/W
R/W
R/W
R/W
R/W
R/W
R/W
Reset value
0
0
0
0
0
0
0
0
Bit7
SHE:
Global interrupt enable bits;
1=
Enable all unblocked interrupts;
0=
Disable all interrupts.
Bit6
ES1:
UART1 interrupt enable bit;
1=
Enable UART1 interrupt;
0=
Disable UART1 Interrupt.
Bit5
ET2:
TIMER2 Global interrupt Enable bits;
1=
Enable all interrupts of TIMER2;
0=
All interrupts of TIMER2 are Disabled.
Bit4
ES0:
UART0 interrupt enable bit;
1=
Enable UART0 interrupts;
0=
Disable UART0 Interrupt.
Bit3
ET1:
TIMER1 interrupt enable bit;
1=
Enable TIMER1 interrupts;
0=
Disable TIMER1 Interrupt.
Bit2
EX1:
External interrupt 1 interrupt enable bits;
1=
Enable external interrupt 1 interrupt;
0=
Disable external interrupt 1 interrupt.
Bit1
ET0:
TIMER0 interrupt enable bits;
1=
Enable TIMER0 interrupts;
0=
Disable TIMER0 Interrupts.
Bit0
EX0:
External interrupt 0 interrupt enable bit;
1=
Enable external interrupt 0 interrupts;
0=
Disable external interrupt 0 interrupt.