Datasheet

LPC2109_2119_2129_5 © NXP B.V. 2007. All rights reserved.
Product data sheet Rev. 05 — 7 March 2007 12 of 35
NXP Semiconductors
LPC2109/2119/2129
Single-chip 16/32-bit microcontrollers
6.6 Pin connect block
The pin connect block allows selected pins of the microcontroller to have more than one
function. Configuration registers control the multiplexers to allow connection between the
pin and the on chip peripherals. Peripherals should be connected to the appropriate pins
prior to being activated, and prior to any related interrupt(s) being enabled. Activity of any
enabled peripheral function that is not mapped to a related pin should be considered
undefined.
The Pin Control Module contains three registers as shown in Table 5
.
6.7 Pin function select register 0 (PINSEL0 - 0xE002 C000)
The PINSEL0 register controls the functions of the pins as per the settings listed in
Table 6
. The direction control bit in the IODIR register is effective only when the GPIO
function is selected for a pin. For other functions, direction is controlled automatically.
Settings other than those shown in Table 6
are reserved, and should not be used
System Control External Interrupt 0 (EINT0) 14
External Interrupt 1 (EINT1) 15
External Interrupt 2 (EINT2) 16
External Interrupt 3 (EINT3) 17
A/D A/D Converter 18
CAN CAN1, CAN2 and Acceptance Filter 19 to 23
Table 4. Interrupt sources
…continued
Block Flag(s) VIC channel #
Table 5. Pin control module registers
Address Name Description Access
0xE002 C000 PINSEL0 Pin function select register 0 Read/Write
0xE002 C004 PINSEL1 Pin function select register 1 Read/Write
0xE002 C014 PINSEL2 Pin function select register 2 Read/Write
Table 6. Pin function select register 0 (PINSEL0 - 0xE002 C000)
PINSEL0 Pin name Value Function Value after reset
1:0 P0.0 0 0 GPIO Port 0.0 0
0 1 TXD (UART0)
10PWM1
1 1 Reserved
3:2 P0.1 0 0 GPIO Port 0.1 0
0 1 RXD (UART0)
10PWM3
11EINT0
5:4 P0.2 0 0 GPIO Port 0.2 0
01SCL (I
2
C-bus)
1 0 Capture 0.0 (Timer 0)
1 1 Reserved