Hitachi H8/3022 Hardware Manual page 144

H8/3022 series hitachi single-chip microcomputer
Table of Contents

Advertisement

Table 7-2 Port 1 Registers
Address*
Name
H'FFC0
Port 1 data direction
register
H'FFC2
Port 1 data register
Note: Lower 16 bits of the address.
Port 1 Data Direction Register (P1DDR): P1DDR is an 8-bit write-only register that can select
input or output for each pin in port 1.
Bit
P1 DDR
Initial value
Modes
1, 3
Read/Write
Initial value
Modes
5 to 7
Read/Write
P1DDR is initialized to H'00 by a reset and in hardware standby mode. In software standby mode
it retains its previous setting. If a P1DDR bit is set to 1, the corresponding pin maintains its output
state in software standby mode.
Port 1 Data Register (P1DR): P1DR is an 8-bit readable/writable register that stores data for pins
P1
to P1
.
7
0
Bit
P1
Initial value
Read/Write
R/W
When a bit in P1DDR is set to 1, if port 1 is read the value of the corresponding P1DR bit is
returned directly, regardless of the actual state of the pin. When a bit in P1DDR is cleared to 0, if
port 1 is read the corresponding pin level is read.
132
Abbreviation
P1DDR
P1DR
7
6
P1 DDR
P1 DDR
7
6
1
1
0
0
W
W
7
6
P1
P1
7
6
0
0
R/W
R/W
R/W
W
R/W
5
4
P1 DDR
P1 DDR
5
4
1
1
0
0
W
W
Port 1 data direction 7 to 0
These bits select input or
output for port 1 pins
5
4
P1
P1
5
4
0
0
R/W
R/W
Port 1 data 7 to 0
These bits store data for port 1 pins
Initial Value
Modes 1, 3
H'FF
H'00
3
2
P1 DDR
P1 DDR
3
2
1
1
0
0
W
W
3
2
P1
P1
3
2
0
0
R/W
R/W
Modes 5 to 7
H'00
H'00
1
0
P1 DDR
1
0
1
1
0
0
W
W
1
0
P1
1
0
0
0
R/W

Advertisement

Table of Contents
loading

This manual is also suitable for:

H8/3021H8/3020H8/3022 f-ztat

Table of Contents