Datasheet

User’s Manual U18172EJ3V0UD
54
CHAPTER 4 PORT FUNCTIONS
4.1 Functions of Ports
The 78K0S/KU1+ has the ports shown in Figure 4-1, which can be used for various control operations. Table 4-1
shows the functions of each port.
In addition to digital I/O port functions, each of these ports has an alternate function. For details, refer to
CHAPTER 2 PIN FUNCTIONS.
Figure 4-1. Port Functions
P43
Port 4
P40
P20
Port 2
P23
P32
Port 3
P34
Table 4-1. Port Functions (
μ
PD78F920x)
Pin Name I/O Function After Reset Alternate-
Function Pin
P20 ANI0/TI000/TOH1
P21 ANI1/TI010/TO00/
INTP0
P22
Note 1
X2/ANI2
Note 1
P23
Note 1
I/O Port 2.
4-bit I/O port.
Can be set to input or output mode in 1-bit units.
On-chip pull-up resistor can be connected by setting software.
Input
X1/ANI3
Note 1
P32 I/O Can be set to input or output mode in 1-
bit units.
On-chip pull-up resistor can be
connected by setting software.
Input INTP1
P34
Note 1
Input
Port 3
Input only Input
RESET
Note 1
P40 and P43
Note 2
I/O Port 4.
2-bit I/O port.
Can be set to input or output mode in 1-bit units.
On-chip pull-up resistor can be connected setting software.
Input
Notes 1. For the setting method for pin functions, see CHAPTER 15 OPTION BYTE.
2. At program initialization, set PM41, PM42, and PM44 to PM47 to "0".
Caution The P22/X2/ANI2 and P23/X1/ANI3 pins are pulled down during reset.
Remarks 1. P22 and P23 can be allocated when the high-speed internal oscillation is selected as the system clock.
2. P22 can be allocated when an external clock input is selected as the system clock.