English
Language : 

MC908AZ32ACFUE Datasheet, PDF (260/324 Pages) Freescale Semiconductor, Inc – Microcontrollers
I/O Ports
23.9.2 Data Direction Register H
Data direction register H determines whether each port H pin is an input or an output. Writing a logic 1 to
a DDRH bit enables the output buffer for the corresponding port H pin; a logic 0 disables the output buffer.
Address:
Read:
Write:
Reset:
$000F
Bit 7
6
5
4
3
2
1
0
0
0
0
0
0
DDRH1
R
R
R
R
R
R
0
0
0
0
0
0
0
R
= Reserved
Figure 23-24. Data Direction Register H (DDRH)
Bit 0
DDRH0
0
DDRH[1:0] — Data Direction Register H Bits
These read/write bits control port H data direction. Reset clears DDRG[1:0], configuring all port H pins
as inputs.
1 = Corresponding port H pin configured as output
0 = Corresponding port H pin configured as input
NOTE
Avoid glitches on port H pins by writing to the port H data register before
changing data direction register H bits from 0 to 1.
Figure 23-25 shows the port H I/O logic.
READ DDRH ($000F)
WRITE DDRH ($000F)
RESET
WRITE PTH ($000B)
DDRHx
PTHx
PTHx
READ PTH ($000B)
Figure 23-25. Port H I/O Circuit
MC68HC908AZ32A Data Sheet, Rev. 2
260
Freescale Semiconductor