mc9s12hz256v2 Freescale Semiconductor, Inc, mc9s12hz256v2 Datasheet - Page 160

no-image

mc9s12hz256v2

Manufacturer Part Number
mc9s12hz256v2
Description
Hcs12 Microcontrollers
Manufacturer
Freescale Semiconductor, Inc
Datasheet
Chapter 4 Port Integration Module (PIM9HZ256V2)
4.4
Each pin associated with ports AD, L, P, S, T, U and V can act as general-purpose I/O. In addition the pin
can act as an output from a peripheral module or an input to a peripheral module.
A set of configuration registers is common to all ports. All registers can be written at any time, however a
specific configuration might not become active.
4.4.1
The I/O Register holds the value driven out to the pin if the port is used as a general-purpose I/O. Writing
to the I/O Register only has an effect on the pin if the port is used as general-purpose output.
When reading the I/O Register, the value of each pin is returned if the corresponding Data Direction
Register bit is set to 0 (pin configured as input). If the data direction register bits is set to 1, the content of
the I/O Register bit is returned. This is independent of any other configuration
Due to internal synchronization circuits, it can take up to 2 bus cycles until the correct value is read on the
I/O Register when changing the data direction register.
4.4.2
The Input Register is a read-only register and generally returns the value of the pin
be used to detect overload or short circuit conditions.
Due to internal synchronization circuits, it can take up to 2 bus cycles until the correct value is read on the
Input Register when changing the Data Direction Register.
4.4.3
The Data Direction Register defines whether the pin is used as an input or an output. A Data Direction
Register bit set to 0 configures the pin as an input. A Data Direction Register bit set to 0 configures the pin
as an output. If a peripheral module controls the pin the contents of the data direction register is ignored
(Figure
160
Example: Selecting a pull-up resistor. This resistor does not become active while the port is used
as a push-pull output.
4-55).
Functional Description
I/O Register
Input Register
Data Direction Register
MC9S12HZ256 Data Sheet, Rev. 2.05
(Figure
(Figure
Freescale Semiconductor
4-55).
4-55). It can

Related parts for mc9s12hz256v2