RL78/G1P
CHAPTER 4 PORT FUNCTIONS
R01UH0895EJ0100 Rev.1.00
73
Nov 29, 2019
4.2.3 Port 3
Port 3 is an I/O port with an output latch. Port 3 can be set to the input mode or output mode in 1-bit units using port
mode register 3 (PM3). When the P30 to P35 pins are used as an input port, use of an on-chip pull-up resistor can be
specified in 1-bit units by pull-up resistor option register 3 (PU3).
This port can also be used for external interrupt request input, serial interface data I/O, clock I/O, programming UART
transmission/reception, timer I/O, and chip select input.
Reset signal generation sets P30 to P35 to input mode.
Table 4-6. Settings of Registers When Using Port 3
Name I/O PM3
Alternate Function Setting
Remark
P30 Input 1
Output
0
SO00/TxD0 output = 1
Note 1
P31 Input 1
Output 0
P32 Input 1
Output
0
SCK00 output = 1
Note 1
P33 Input 1
Output
0
TO02 output = 0
Note 2
P34, P35
Input
1
Output 0
Notes 1.
To use P30/INTP2/TxD0/TOOLTxD/SO00, P32/INTP3/SCK00 as a general-purpose port, set bit 0 (SE00)
of serial channel enable status register 0 (SE0), bit 0 (SO00) of serial output register 0 (SO0) and bit 0
(SOE00) of serial output enable register 0 (SOE0) to the default status.
2.
To use P33/TI02/TO02 as a general-purpose port, set bit 2 (TO02) of timer output register 0 (TO0) and bit
2 (TOE02) of timer output enable register 0 (TOE0) to “0”, which is the same as their default status setting.
Remark
: don’t
care
PM3
: Port mode register 3