146
9.3
Port 2
9.3.1
Overview
Port 2 is a 3-bit I/O port, configured as shown in figure 9.2.
P22/TXD
P21/RXD
P20/SCK3
Port 2
Figure 9.2 Port 2 Pin Configuration
9.3.2
Register Configuration and Description
Table 9.3 shows the port 2 register configuration.
Table 9.3
Port 2 Registers
Name
Abbrev.
R/W
Initial Value
Address
Port data register 2
PDR2
R/W
H'F8
H'FFD5
Port control register 2
PCR2
W
H'00
H'FFE5
9.3.3
Port Data Register 2 (PDR2)
Bit
7
6
5
4
3
2
1
0
—
—
—
—
—
P22
P21
P20
Initial value
1
*
1
*
1
*
1
*
1
*
0
0
0
Read/Write
—
—
—
—
—
R/W
R/W
R/W
Note:
*
Bits 7 to 3 are reserved; they are always read as 1 and cannot be modified.
PDR2 is an 8-bit register that stores data for port 2 pins P22 to P20. If port 2 is read while PCR2
bits are set to 1, the values stored in PDR2 are read, regardless of the actual pin states. If port 2 is
read while PCR2 bits are cleared to 0, the pin states are read.
Upon reset, PDR2 is initialized to H'F8.
Summary of Contents for H8/3660
Page 4: ......
Page 26: ...10 ...
Page 82: ...66 ...
Page 152: ...136 ...
Page 154: ...138 ...
Page 260: ...244 ...