T5L_ASIC Development Guide
- 29
-
www.dwin-global.com
DWIN Technology
Professional,
Creditable,
S
uccessful
3.7.3 UART4
UART4 related SFR are shown in the following table.
SFR name
Address
Instructions
SCON2T
0x96
UART4 sending control:
.7 UART4 sending enable. 0=close;1=open;
.6 0=8bit mode,1=9bit mode;
.5 TB8, 9th bit sent in 9bit mode;
.4-.1 Write0;
.0 TI, send mark. The position at which the stop bit is sent.
SCON2R
0x97
UART4 receive control:
.7 UART4 sending enable. 0=close;1=open;
.6 Write0;
.5 RB8, 9th bit received in 9bit mode;
.4-.1 Write 0;
.0 R RI, receive mark. Set when the stop bit is received when a valid stop bit is received.
SBUF2_TX
0x9E
UART4 sending data interface
SBUF3_RX
0x9F
UART4 receiving data interface
BODE2_DIV_H
0XD9
UART4 baud rate setting
BODE2_DIV_H:L=CPU main frequency/(8*baud rate)
BODE2_DIV_L
0XD7
The relevant settings of UART4 interruption are as follows:
Interrupt type
Program entry
address
Trigger
marker
Interrupt enabling
control
Remarks
UART4 send
interrupt
0x0053
SCON2T.0
IEN1.2
After interruption, clear the interruption trigger mark by
software.
UART4 receive
Interrupt
0x005B
SCON2R.0
IEN1.3
After interruption, clear the interruption trigger mark by
software.