294
CHAPTER 16 SERIAL INTERFACE UART0
User’s Manual U15798EJ2V0UD
16.4.2 Asynchronous serial interface (UART) mode
This mode enables full-duplex operation wherein one byte of data after the start bit is transmitted or received.
The on-chip baud rate generator dedicated to UART enables communications using a wide range of selectable
baud rates.
The UART baud rate generator can also be used to generate a MIDI-standard baud rate (31.25 kbps).
(1) Register settings
UART mode settings are performed by asynchronous serial interface mode register 0 (ASIM0), asynchronous
serial interface status register 0 (ASIS0), and baud rate generator control register 0 (BRGC0).
(a) Asynchronous serial interface mode register 0 (ASIM0)
ASIM0 is set by a 1-bit or 8-bit memory manipulation instruction.
RESET input sets the value of this register to 00H.
Caution In UART mode, set the port mode register (PMXX) as follows. Set the output latch of a port
set to output mode (PMXX = 0) to 0.
•
During receive operation
Set P26 (R
X
D0) to input mode (PM26 = 1)
•
During transmit operation
Set P27 (T
X
D0) to output mode (PM27 = 0)
•
During transmit/receive operation
Set P26 to input mode, and P27 to output mode