UM10360 All information provided in this document is subject to legal disclaimers. © NXP B.V. 2013. All rights reserved.
User manual Rev. 3 — 19 December 2013 106 of 841
NXP Semiconductors
UM10360
Chapter 8: LPC176x/5x Pin connect block
The direction control bit in the GPIO registers is effective only when the GPIO function is
selected for a pin. For other functions, direction is controlled automatically. Each
derivative typically has a different pinout and therefore a different set of functions possible
for each pin. Details for a specific derivative may be found in the appropriate data sheet.
Multiple connections
Since a particular peripheral function may be allowed on more than one pin, it is in
principle possible to configure more than one pin to perform the same function. If a
peripheral output function is configured to appear on more than one pin, it will in fact be
routed to those pins. If a peripheral input function is configured to appear on more than
one pin for some reason, the peripheral will receive its input from the lowest port number.
For instance, any pin of port 0 will take precedence over any pin of a higher numbered
port, and pin 0 of any port will take precedence over a higher numbered pin of the same
port.
8.4 Pin mode select register values
The PINMODE registers control the input mode of all ports. This includes the use of the
on-chip pull-up/pull-down resistor feature and a special open drain operating mode. The
on-chip pull-up/pull-down resistor can be selected for every port pin regardless of the
function on this pin with the exception of the I
2
C pins for the I2C0 interface and the USB
pins (see Section 8.5.10
). Three bits are used to control the mode of a port pin, two in a
PINMODE register, and an additional one in a PINMODE_OD register. Bits are reserved
for unused pins as in the PINSEL registers.
Repeater mode enables the pull-up resistor if the pin is at a logic high and enables the
pull-down resistor if the pin is at a logic low. This causes the pin to retain its last known
state if it is configured as an input and is not driven externally. The state retention is not
applicable to the Deep Power-down mode. Repeater mode may typically be used to
prevent a pin from floating (and potentially using significant power if it floats to an
indeterminate state) if it is temporarily not driven.
Table 75. Pin function select register bits
PINSEL0 to
PINSEL9 Values
Function Value after Reset
00 Primary (default) function, typically GPIO port 00
01 First alternate function
10 Second alternate function
11 Third alternate function
Table 76. Pin Mode Select register Bits
PINMODE0 to
PINMODE9 Values
Function Value after
Reset
00 Pin has an on-chip pull-up resistor enabled. 00
01 Repeater mode (see text below).
10 Pin has neither pull-up nor pull-down resistor enabled.
11 Pin has an on-chip pull-down resistor enabled.