English
Language : 

PC87365 Datasheet, PDF (129/215 Pages) National Semiconductor (TI) – 128-Pin LPC SuperI/O with System Hardware Monitoring
6.0 General-Purpose Input/Output (GPIO) Port (Continued)
6.2 BASIC FUNCTIONALITY
The basic functionality of each GPIO pin is based on four configuration bits and a bit slice of runtime registers GPDO and
GPDI. The configuration and operation of a single pin GPIOXn (pin n in port X) is shown in Figure 19.
Read Only
Data In
GPIO Device
Enable
Read/Write
Data Out
Push-Pull =1
Static
Pull-Up
Pin
Internal
Bus
Pull-Up
Enable
Lock
Pull-Up
Control
Output
Type
Output
Enable
Bit 3
Bit 2
Bit 1
Bit 0
GPIO Pin Configuration (GPCFG) Register
Figure 19. GPIO Basic Functionality
6.2.1 Configuration Options
The GPCFG register controls the following basic configuration options:
• Port Direction - Controlled by the Output Enable bit (bit 0).
• Output Type - Push-pull vs. open-drain. It is controlled by Output Buffer Type (bit 1) by enabling/disabling the pull-up
portion of the output buffer.
• Weak Static Pull-up - May be added to any type of port (input, open-drain or push-pull). It is controlled by Pull-Up Control
(bit 2).
• Pin Lock - GPIO pin may be locked to prevent any changes in the output value and/or the output characteristics. The
lock is controlled by Lock (bit 3). It disables writes to the GPDO register bits and to bits 0-3 of the GPCFG register (In-
cluding the Lock bit itself). Once locked, it can be released by hardware reset only.
6.2.2 Operation
The value that is written to the GPDO register is driven to the pin if the output is enabled. Reading from the GPDO register
returns its contents regardless of the pin value or the port configuration. The GPDI register is a read-only register. Reading
from the GPDI register returns the pin value regardless of what is driving it (the port itself, configured as an output port, or
the external device when the port is configured as an input port). Writing to this register is ignored.
Activation of the GPIO port is controlled by external device specific configuration bit (or a combination of bits). When the port
is inactive, access to GPDI and GPDO registers is disabled and the inputs are blocked. However, there is no change in the
port configuration and in the GPDO value and hence there is no effect on the outputs of the pins.
129
www.national.com