Rev. 1.0, 02/00, page 214 of 1141
Port Control Register 4 (PCR4)
0
0
1
0
W
2
0
W
3
0
4
0
W
0
W
5
0
7
0
W
W
W
W
6
PCR44
PCR43
PCR42
PCR41
PCR40
PCR47
PCR46
PCR45
Bit :
Initial value :
R/W :
Port control register 4 (PCR4) controls the I/Os of pins P47 to P40 of port 4 in a unit of bit.
When PCR4 is set to 1, the corresponding P47 to P40 pins become output pins, and when it is set
to 0, they become input pins. When the relevant pin is set to a general I/O by PMR4, settings of
PCR4 and PDR4 become valid.
PCR4 is an 8-bit write-only register. When PCR4 is read, 1 is read. When reset, PCR4 is
initialized to H'00.
Bits 7 to 0
P47 to P40 Pin Switching (PCR47 to PCR40)
Bit n
PCR4n
Description
0
The P4n pin functions as an input pin
(Initial value)
1
The P4n pin functions as an output pin
(n = 7 to 0)
Port Data Register 4 (PDR4)
0
0
1
0
R/W
2
0
R/W
3
0
4
0
R/W
0
R/W
5
0
7
0
R/W
R/W
R/W
R/W
6
PDR44
PDR43
PDR42
PDR41
PDR40
PDR47
PDR46
PDR45
Bit :
Initial value :
R/W :
Port data register 4 (PDR4) stores the data for the pins P47 to P40 of port 4. When PCR4 is 1
(output), the PDR4 values are directly read if port 4 is read. Accordingly, the pin states are not
affected. When PCR4 is 0 (input), the pin states are read if port 4 is read.
PDR4 is an 8-bit read/write enable register. When reset, PDR4 is initialized to H'00.