Figure 18.2 shows a block diagram of the 4-bit general-purpose I/O port.
PBnPUP
Pull-up resistor
PORTEN
Internal bus
Port 19 (input/
output)/D51
to
Port 16 (input/
output)/D48
0
1
Dn output data
D
C
Q
PDTRW
BCK
0
1
DnDIR
PBnIO
Data input strobe
0
1
C
D
Q
BCK
Dn input data
PORTEN
PBnPuP
DnDIR
0: Port not available 1: Port available
0: Pull-up
0: Input
0: Input
1: Pull-up off
1: Output
1: Output
PBnIO
Figure 18.2 4-Bit Port
Rev. 6.0, 07/02, page 733 of 986