www
.mcu.com.cn
206
/
239
Rev.
1.00
CMS80F731x Reference Manual
22.6 UARTn Mode
22.6.1
Mode 0 - Synchronous Mode
Pin RXDn is the input or output and TXDn is the clock output. The TXDn output is a shift clock. The baud rate is fixed at
1/12 of the system clock frequency. 8 bits are transmitted preferentially with LSB. Initialize the receive by setting the flag in
SCONN, set to: RIn = 0 and RENn = 1. The mode 0 timing diagram is shown in the following figure:
D0
D1
D2
D3
D4
D5
D6
D7
RXDn
TIn
TXDn
22.6.2
Mode 1-8 Bit Asynchronous Mode (Variable Baud Rate)
The pin RXDn is used as the input and the TXDn is used as the serial output. Send 10 bits: start bit (always 0), 8 bits of
data (LSB first), and stop bit (always 1). When received, the start bit is transmitted synchronously, 8 data bits can be obtained
by reading SBUFn, and the stop bit sets the flag RBn8 in SCONn. The baud rate is variable and depends on the
TIMER1/TIMER2/TIMER4/BRT mode. The Mode 1 timing diagram is shown in the following figure:
D1
D2
D3
D4
D5
D6
TXDn
TIn
RXDn
D7
D0
STOP
START