
7-1
MSM64164C User's Manual
Chapter 7 Ports (P0, P1, P2, P3 and P4)
7
Chapter 7 Ports (P0, P1, P2, P3 and P4)
7.1 Overview
The MSM64164C has one 4-bit input port, three 4-bit input/output ports and one 4-bit output
port built-in.
Table 7-1 shows the list of functions of each port. For secondary functions of the capture timer,
the A/D converter and the serial port, refer to Chapter 10 "Capture Circuit", Chapter 12 "A/D
Converter", and Chapter 8 "Serial Port", respectively.
Table 7-1 List of Functions of Each Port
Pin name
Pin No.
GS-BK GS-K
TS-K
Pad No.
Input/
Output
P0.0
77
75
77
Input
4-bit input port (P0):
Can select (1) pull-up resistance input, (2) pull-down
resistance input or (3) high-impedance input by the port
01 control register (P01CON). As a secondary function,
P0.0 to P0.3 are assigned external interrupt functions and
P0.0 and P0.1 are assigned a capture trigger function.
Function
P0.1
78
76
78
Input
P0.2
79
77
79
Input
P0.3
80
78
80
Input
P1.0
73
71
73
Output
4-bit output port (P1):
Can select NMOS open drain output or CMOS output by
the port 01 control register (P01CON). P1.0 is a large
current drive output port.
P1.1
74
72
74
Output
P1.2
75
73
75
Output
P1.3
76
74
76
Output
P2.0
18
16
18
Input/Output 4-bit input/output port (P2):
Selection of (1) pull-up/pull-down resistance input, (2)
high-impedance input, (3) NMOS open drain output and
(4) CMOS output by the port 2 control registers 0 to 3
(P20CON to P23CON) is possible. As a secondary
function, an external interrupt function is assigned.
P2.1
19
17
19
Input/Output
P2.2
20
18
20
Input/Output
P2.3
21
19
21
Input/Output
P3.0
22
20
22
Input/Output 4-bit input/output port (P3):
Selection of (1) pull-up/pull-down resistance input, (2)
high-impedance input, (3) NMOS open drain output and
(4) CMOS output by the port 3 control registers 0 to 3
(P30CON to P33CON) is possible. As a secondary
function, P3.0 to P3.3 are assigned an external interrupt
function and P3.3 is assigned a serial port function.
P3.1
23
21
23
Input/Output
P3.2
24
22
24
Input/Output
P3.3/SIN
25
23
25
Input/Output
P4.0/SOUT
26
24
26
Input/Output 4-bit input/output port (P4):
Selection of (1) pull-up/pull-down resistance input, (2)
high-impedance input, (3) NMOS open drain output and
(4) CMOS output by the port 4 control registers 0 to 3
(P40CON to P43CON) is possible. As a secondary
function, P4.0 to P4.3 are assigned an external interrupt
function, P4.0 to P4.2 are assigned a serial port function
and P4.3 is assigned a monitor function of the RC
oscillation clock for A/D conversion.
P4.1/SPR
27
25
27
Input/Output
P4.2/SCLK
28
26
28
Input/Output
P4.3/MON
29
27
29
Input/Output