Hitachi H8/3032 Series Hardware Manual page 144

Table of Contents

Advertisement

Downloaded from
Elcodis.com
electronic components distributor
Mode 1: Address output or generic input can be selected for each pin in port 2. A pin becomes an
address output pin if the corresponding P2DDR bit is set to 1, and a generic input pin if this bit is
cleared to 0. Following a reset, all pins are input pins. To use a pin for address output, its P2DDR
bit must be set to 1. Figure 7-5 shows the pin functions in mode 1.
Port 2
Figure 7-5 Pin Functions in Mode 1 (Port 2)
Modes 2 and 3: Input or output can be selected separately for each pin in port 2. A pin becomes an
output pin if the corresponding P2DDR bit is set to 1, and an input pin if this bit is cleared to 0.
Figure 7-6 shows the pin functions in modes 2 and 3.
Figure 7-6 Pin Functions in Modes 2 and 3 (Port 2)
When P2DDR = 1
When P2DDR = 0
A
(output)
P2 (input)
15
A
(output)
P2 (input)
14
A
(output)
P2 (input)
13
A
(output)
P2 (input)
12
A
(output)
P2 (input)
11
A
(output)
P2 (input)
10
A (output)
P2 (input)
9
A (output)
P2 (input)
8
P2 (input/output)
7
P2 (input/output)
6
P2 (input/output)
5
P2 (input/output)
4
Port 2
P2 (input/output)
3
P2 (input/output)
2
P2 (input/output)
1
P2 (input/output)
0
129
7
6
5
4
3
2
1
0

Advertisement

Table of Contents
loading

Table of Contents