SERIAL I/O
7902 Group User’s Manual
12-48
12.4 Clock asynchronous serial I/O (UART) mode
Reception will start when the start bit (’s
falling edge) is detected.
Port P8 direction register (Address 1416)
b7
b0
0
Pin RxD0
Pin RxD1
UART0 baud rate register (BRG0) (Address 3116)
UART1 baud rate register (BRG1) (Address 3916)
b7
b0
Can be set to “0016” to “FF16.”
UART0 receive interrupt control register (Address 7216)
UART1 receive interrupt control register (Address 7416)
b7
b0
Interrupt priority level select bits
When using interrupts, set these bits to
one of levels 1 to 7.
When disabling interrupts, set these bits
to level 0.
T Set the same transfer data format
as that of the transmitter side.
1
UART0 transmit/receive control register 1 (Address 3516)
UART1 transmit/receive control register 1 (Address 3D16)
b7
b0
Receive enable bit
1: Reception enabled
UART0 transmit/receive mode register (Address 3016)
UART1 transmit/receive mode register (Address 3816)
b7
b0
Internal/External clock select bit
0: Internal clock
1: External clock
1 0 0: UART mode (7 bits)
1 0 1: UART mode (8 bits)
1 1 0: UART mode (9 bits)
Stop bit length select bit
0: 1 stop bit
1: 2 stop bits
Odd/Even parity select bit
0: Odd parity
1: Even parity
Parity enable bit
0: Parity is disabled.
1: Parity is enabled.
Sleep select bit
0: Sleep mode cleared (invalid)
1: Sleep mode selected
1
b2 b1 b0
UART0 transmit/receive control register 0 (Address 3416)
UART1 transmit/receive control register 0 (Address 3C16)
b7
b0
BRG count source select bits
CTS/RTS function select bit
0: CTS function selected
1: RTS function selected
0 0 : f2
0 1 : f16
1 0 : f64
1 1 : f512
b1 b0
0
CTS/RTS enable bit
0: CTS/RTS function is enabled.
1: CTS/RTS function is disabled.
Notes 1: The CLKi pin cannot be used
when the CTSi/RTSi separation
is selected. (Refer to “[Precau-
tion for clock asynchronous
serial I/O (UART) mode].”)
2: When performing reception only,
if these bits are set to “1,” the
TxDi pin can be used as a
programmable I/O port pin.
UARTi receive interrupt mode select bit
0: Reception interrupt
1: Reception error interrupt
Serial I/O mode select bit
Serial I/O pin control register (Address AC16)
b7
b0
CTS0/RTS0 separate select bit
0: CTS0/RTS0 are used together.
1: CTS0/RTS0 are separated (Note 1).
CTS1/RTS1 separate select bit
0: CTS1/RTS1 are used together.
1: CTS1/RTS1 are separated (Note 1).
TxD0/P83 switch bit (Note 2)
0: Functions as TxD0.
1: Functions as P83.
TxD1/P87 switch bit (Note 2)
0: Functions as TxD1.
1: Functions as P87.
Fig. 12.4.10 Initial setting example for relevant registers when receiving