
CHAPTER 4 PORT FUNCTIONS
User’s Manual U15905EJ2V1UD
117
(e) Port function register 4 (PF4)
This 8-bit register specifies normal output or N-ch open-drain output.
It can be read or written in 8-bit or 1-bit units.
0
Normal output
N-ch open-drain output
PF4n
0
1
Controls normal output or N-ch open-drain output (n = 1, 2)
PF4
0
PF42
PF41
0
After reset: 00H
R/W
Address: FFFFFC68H
Cautions 1. The N-ch open-drain output voltage is the normal voltage, not the medium voltage.
2. PF4n = 1 is enabled only in the following cases. Otherwise, the setting is prohibited.
n = 1: SO0, SDA
n = 2: SCK0, SCL
3. Be sure to set N-ch open-drain output when using I
2C (the SDA and SCL pins).
4. Follow the procedure below to set N-ch open drain.
<1> Set the P4n bit to 1.
<2> Set the PF4n bit to 1.
<3> Set the CSIE0 bit of the CSIM0 register or the IICE bit of the IICC register to 1.
<4> Set the PFC4n bit.
<5> Set the PMC4n bit to 1.
(f) Pull-up resistor option register 4 (PU4)
This is an 8-bit register that specifies connection of an internal pull-up resistor.
This register can be read or written in 8-bit or 1-bit units.
0
Not connected.
Connected.
PU4n
0
1
Controls connection of internal pull-up resistor (n = 0 to 6)
PU4
PU46
PU45
PU44
PU43
PU42
PU41
PU40
After reset: 00H
R/W
Address: FFFFFC48H