32-bit ARM Cortex-M3 microcontroller; up to 512 kB flash and
96 kB SRAM; USB Device/Host/OTG; Ethernet; LCD; EMC
Rev. 5 — 9 September 2014Product data sheet
1. General description
The LPC178x/7x is an ARM Cortex-M3 based microcontroller for embedded applications
requiring a high level of integration and low power dissipation.
The ARM Cortex-M3 is a next generation core that of fers better performance than the
ARM7 at the same clock rate and other system enhancements such as modernized
debug features and a higher level of support block integration. The ARM Cortex-M3 CPU
incorporates a 3-stage pipeline and has a Harvard architecture with separate local
instruction and data buses, as well as a third bus with slightly lower performance for
peripherals. The ARM Cortex-M3 CPU also includes an internal prefetch unit that
supports speculative branches.
The LPC178x/7x adds a specialized flash memory accelerator to accomplish optimal
performance when executing code from flash. The LPC178x/7x operates at up to
120 MHz CPU frequency.
The peripheral complement of the LPC178x/7x includes up to 512 kB of flash program
memory, up to 96 kB of SRAM data memory, up to 4032 byte of EEPROM data memory,
External Memory Controller (EMC), LCD (LPC178x only), Ethernet, USB
Device/Host/OTG, a General Purpose DMA controller, five UARTs, three SSP controllers,
2
three I
two general purpose PWMs with six outputs each and one motor control PWM, an
ultra-low power RTC with separa te battery supply and event recorder, a windowed
watchdog timer, a CRC calculation engine, up to 165 general purpose I/O pins, and more.
The analog peripherals include one eight-channel 12-bit ADC and a 10-bit DAC.
The pinout of LPC178x/7x is intended to allow pin function compatibility with the LPC24xx
and LPC23xx.
For additional documentation, see Section 18 “
C-bus interfaces, a Quadrature Encoder Interface, four general purpose timers,
2. Features and benefits
Functional replacement for the LPC23xx and LPC24xx family devices.
System:
ARM Cortex-M3 processor, running at frequencies of up to 120 MHz. A Memory
Protection Unit (MPU) supporting eight regions is included.
ARM Cortex-M3 built-in Nested Vectored Interrupt Controller (NVIC).
References”.
NXP Semiconductors
32-bit ARM Cortex-M3 microcontroller
Multilayer AHB matrix interconnect provides a separate bus for each AHB master.
AHB masters include the CPU, USB, Ethernet, and the General Purpose DMA
controller. This interconnect provides communication with no arbitration delays
unless two masters attempt to access the same slave at the same time.
Split APB bus allows for higher throughput with fewer stalls between the CPU and
DMA. A single level of write buffering allows the CPU to continue without waiting for
completion of APB writes if the APB was not already busy.
Cortex-M3 system tick timer, including an external clock input option.
Standard JTAG test/debug interface as well as Serial Wire Debug and Serial
Up to 512 kB on-chip flash program memory with In-System Programming (ISP)
and In-Application Programming (IAP) capabilities. The combination of an
enhanced flash memory accelerator and location of the flash memory on the CPU
local code/data bus provides high code performance from flash.
Up to 96 kB on-chip SRAM includes:
64 kB of main SRAM on the CPU with local code/data bus for high-performance
CPU access.
Two 16 kB peripheral SRAM blocks with se parate access paths for higher
throughput. These SRAM blocks may be used for DMA memory as well as for
general purpose instruction and data storage.
Up to 4032 byte on-chip EEPROM.
LCD controller, supporting both Super-Twisted Nematic (STN) and Thin-Film
Transistors (TFT) displays.
Dedicated DMA controller.
Selectable display resolution (up to 1024 768 pixels).
Supports up to 24-bit true-color mode.
External Memory Controller (EMC) provides support for asynchronous static memory
devices such as RAM, ROM and flash, as well as dynamic memories such as single
data rate SDRAM with an SDRAM clock of up to 80 MHz.
Eight channel General Purpose DMA controller (GPDMA) on the AHB multilayer
matrix that can be used with the SSP, I2S, UART, CRC engine, Analog-to-Digital and
Digital-to-Analog converter peripherals, timer match signals, GPIO, and for
memory-to-memory transfers.
Serial interfaces:
Ethernet MAC with MII/RMII interface and associated DMA controller. These
functions reside on an independent AHB.
USB 2.0 full-speed dual-port device/host/OTG controller with on-chip PHY and
associated DMA controller.
Five UARTs with fractional baud rate generation, internal FIFO, DMA support, and
RS-485/EIA-485 support. One UART (UAR T1) has full modem control I/O, and one
UART (USART4) supports IrDA, synchronous mode, and a smart card mode
conforming to ISO7816-3.
Three SSP controllers with FIFO and multi-protocol capabilities. The SSP
Product data sheetRev. 5 — 9 September 2014 2 of 122
LPC178x/7x
NXP Semiconductors
LPC178x/7x
32-bit ARM Cortex-M3 microcontroller
Three enhanced I2C-bus interfaces, one with a true open-drain output supporting
the full I
with standard port pins. Enhancement s include multiple address recognition and
monitor mode.
2
I
with the GPDMA.
CAN controller with two channels.
Digital peripherals:
SD/MMC memory card interface.
Up to 165 General Purpose I/O (GPIO) pins depending on the packaging with
configurable pull-up/down resistors, open-drain mode, and repeater mode. All
GPIOs are located on an AHB bus for fast access and support Cortex-M3
bit-banding. GPIOs can be accessed by the General Purpose DMA Controller. Any
pin of ports 0 and 2 can be used to generate an interrupt.
T wo external interrupt in puts configurable as e dge/level sensitive. All pi ns on port 0
and port 2 can be used as edge sensitive interrupt sources.
Four general purpose timers/counters with a total of eight capture inputs and ten
compare outputs. Each timer block has an external count input. Specific timer
events can be selected to generate DMA requests.
Quadrature encoder interface that can monitor one external quadrature encoder.
Two standard PWM/timer blocks with external count input option.
One motor control PWM with support for three-phase motor control.
Real-Time Clock (RTC) with a separate power domain. The RTC is clocked by a
dedicated RTC oscillator. The RTC block includes 20 bytes of battery-powered
backup registers, allowing system status to be stored when the rest of the chip is
powered off. Battery power can be supplied from a sta ndard 3 V lithiu m button cell.
The RTC will continue working when the battery voltage drops to as low as 2.1 V.
An RTC interrupt can wake up the CPU from any reduced power mode.
Event Recorder that can capture the clock value when an event occurs on any of
three inputs. The event identification and the time it occurred are stored in
registers. The Event Recorder is located in the RTC power domain and can
therefore operate as long as there is RTC power.
oscillator, watchdog warning interrupt, and safety features.
CRC Engine block can calculate a CRC on supplied data using one of three
standard polynomials. The CRC engine can be used in conjunction with the DMA
controller to generate a CRC without CPU involvement in the data transfer.
Analog peripherals:
12-bit Analog-to-Digital Converter (ADC) with input multiplexing among eight pins,
conversion rates up to 400 kHz, and multiple result registers. The 12-bit ADC can
be used with the GPDMA controller.
10-bit Digital-to-Analog Converter (DAC) with dedicated conversion timer and
GPDMA support.
Power control:
Four reduced power modes: Sleep, Deep-sleep, Power-down, and Deep
power-down.
2
C-bus specification and Fast-mode Plus with data rates of 1 Mbit/s, two
S-bus (Inter-IC Sound) interface for digital audio input or output. It can be used
Product data sheetRev. 5 — 9 September 2014 3 of 122
NXP Semiconductors
Clock generation:
Versatile pin function selection feature allows many possibilities for using on-chip
Unique device serial number for identification purposes.
Single 3.3 V power supply (2.4 V to 3.6 V). Temperature range of 40 C to 85 C.
Available as LQFP208, TFBGA208, TFBGA180, and LQFP144 package.
LPC178x/7x
32-bit ARM Cortex-M3 microcontroller
The Wake-up Interrupt Controller (WIC) allows the CPU to automatically wake up
from any priority interrupt that can occur while the clocks are stopped in
Deep-sleep, Power-down, and Deep power-down mo d es .
Processor wake-up from Power-down mode via any interrupt able to operate
during Power-down mode (includes external interrupts, RTC interrupt, PORT0/2
pin interrupt, and NMI).
Brownout detect with separate threshold for interrupt and forced reset.
On-chip Power-On Reset (POR).
Clock output function that can reflect the main oscillator clock, IRC clock, RTC
clock, CPU clock, USB clock, or the watchdog timer clock.
On-chip crystal oscillator with an operating range of 1 MHz to 25 MHz.
12 MHz Internal RC oscillator (IRC) trimmed to 1% accuracy that can optionally be
used as a system clock.
An on-chip PLL allows CPU operation up to the maximum CPU rate without the
need for a high-frequency crystal. May be run from the main oscillator or the
internal RC oscillator.
A second, dedicated PLL may be used for USB interface in order to allow added
flexibility for the Main PLL settings.
peripheral functions.
3. Applications
Communications:
Industrial/Medical:
Consumer/Appliance:
Automotive:
Point-of-sale terminals, web servers, multi-protocol bridges
Product data sheetRev. 5 — 9 September 2014 8 of 122
NXP Semiconductors
002aaf519
LPC178x/7x
24681012 13 141357911
ball A1
index area
P
N
M
L
K
J
G
E
H
F
D
C
B
A
Transparent top view
LPC178x/7x
108
37
72
144
109
73
1
36
002aaf520
Fig 4.Pin configuration (TFBGA180)
LPC178x/7x
32-bit ARM Cortex-M3 microcontroller
Fig 5.Pin configuration (LQFP144)
6.2 Pin description
I/O pins on the LPC178x/7x are 5 V tolerant and have input hysteresis unless otherwise
indicated in the table below. Crystal pins, power pins, and reference voltage pins are not
5 V tolerant. In addition, when pins are selected to be ADC inputs, they are no longer 5 V
tolerant and the input voltage must be limited to the volt a ge at the ADC positive re ference
pin (VREFP).
Product data sheetRev. 5 — 9 September 2014 9 of 122
All port pins Pn[m] are multiplexed, and the multiplexed functions appear in Table 3
order defined by the FUNC bits of the corresponding IOCON register up to the highest
used function number. Each port pin can support up to eight multiplexed functions.
IOCON register FUNC values which are reserved are noted as ‘R’ in the pin configuration
table.
in the
NXP Semiconductors
LPC178x/7x
32-bit ARM Cortex-M3 microcontroller
Table 3.Pin description
Not all functions are available on all parts. See Table 2 (Ethernet, USB, LCD, QEI, SD/MMC, DAC pins) and Table 7 (EMC
pins).
Symbol
P0[0] to
P0[31]
[1]
Pin LQFP208
Ball TFBGA208
Ball TFBGA180
Pin LQFP144
Reset state
Description
[2]
Type
I/OPort 0: Port 0 is a 32-bit I/O port with individual direction
controls for each bit. The operation of port 0 pins depends upon
the pin function selected via the pin connect block.
P0[0]94U15M10 66
[3]
I; PUI/OP0[0] — General purpose digital input/output pin.
Product data sheetRev. 5 — 9 September 2014 12 of 122
NXP Semiconductors
LPC178x/7x
32-bit ARM Cortex-M3 microcontroller
Table 3.Pin description …continued
Not all functions are available on all parts. See Table 2 (Ethernet, USB, LCD, QEI, SD/MMC, DAC pins) and Table 7 (EMC
pins).
Symbol
Pin LQFP208
Ball TFBGA208
Ball TFBGA180
P0[13]45R2J532
P0[14]69T7M548
P0[15]128 J16H13 89
P0[16]130 J14H14 90
P0[17]126 K17J1287
P0[18]124 K15J1386
P0[19]122 L17J1085
[1]
Pin LQFP144
Reset state
[5]
I; PUI/OP0[13] — General purpose digital input/output pin.
[3]
I; PUI/OP0[14] — General purpose digital input/output pin.
[3]
I; PUI/OP0[15] — General purpose digital input/output pin.
[3]
I; PUI/OP0[16] — General purpose digital input/output pin.
[3]
I; PUI/OP0[17] — General purpose digital input/output pin.
[3]
I; PUI/OP0[18] — General purpose digital input/output pin.
[3]
I; PUI/OP0[19] — General purpose digital input/output pin.
Description
[2]
Type
OUSB_UP_LED2 — USB port 2 GoodLink LED indicator. It is
LOW when the device is configured (non-control endpoints
enabled), or when the host is enabled and has detected a
device on the bus. It is HIGH when the device is not configured,
or when host is enabled and has not detected a device on the
bus, or during global suspend. It transitions between LOW and
HIGH (flashes) when the host is enabled and detects activity on
the bus.
I/OSSP1_MOSI — Master Out Slave In for SSP1.
IADC0_IN[7] — A/D converter 0, input 7. When configured as an
ADC input, the digital function of the pin must be disabled.
OUSB_HSTEN2
— Host Enabled status for USB port 2.
I/OSSP1_SSEL — Slave Select for SSP1.
OUSB_CONNECT2 — SoftConnect control for USB port 2.
Signal used to switch an external 1.5 k resistor under software
control. Used with the SoftConnect USB feature.
OU1_TXD — Transmitter output for UART1.
I/OSSP0_SCK — Serial clock for SSP0.
IU1_RXD — Receiver input for UART1.
I/OSSP0_SSEL — Slave Select for SSP0.
IU1_CTS — Clear to Send input for UART1.
I/OSSP0_MISO — Master In Slave Out for SSP0.
IU1_DCD — Data Carrier Detect input for UART1.
I/OSSP0_MOSI — Master Out Slave In for SSP0.
IU1_DSR — Data Set Ready input for UART1.
OSD_CLK — Clock output line for SD card interface.
I; PUI/OP1[17] — General purpose digital input/output pin.
I/OENET_MDIO — Ethernet MIIM data input and output.
OI2S_RX_MCLK — I2S receive master clock.
[3]
P1[18]66P7L546
I; PUI/OP1[18] — General purpose digital input/output pin.
OUSB_UP_LED1 — It is LOW when the device is configured
(non-control endpoints enabled), or when the host is enabled
and has detected a device on the bus. It is HIGH when the
device is not configured, or when host is enabled and has not
detected a device on the bus, or during global suspend. It
transitions between LOW and HIGH (flashes) when the host is
enabled and detects activity on the bus.
OPWM1[1] — Pulse Width Modulator 1, channel 1 output.
IT1_CAP0 — Capture input for Timer 1, channel 0.
-R — Function reserved.
I/OSSP1_MISO — Master In Slave Out for SSP1.
[3]
P1[19]68U6P547
I; PUI/OP1[19] — General purpose digital input/output pin.
OUSB_TX_E1
— Transmit Enable signal for USB port 1 (OTG
transceiver).
OUSB_PPWR1
— Port Power enable signal for USB port 1.
IT1_CAP1 — Capture input for Timer 1, channel 1.
OMC_0A — Motor control PWM channel 0, output A.
I/OSSP1_SCK — Serial clock for SSP1.
OU2_OE — RS-485/EIA-485 output enable signal for UART2.
[3]
P1[20]70U7K649
I; PUI/OP1[20] — General purpose digital input/output pin.
OUSB_TX_DP1 — D+ transmit data for USB port 1 (OTG
transceiver).
OPWM1[2] — Pulse Width Modulator 1, channel 2 output.
IQEI_PHA — Quadrature Encoder Interface PHA input.
IMC_FB0 — Motor control PWM channel 0 feedback input.
I/OSSP0_SCK — Serial clock for SSP0.
OLCD_VD[6] — LCD data.
OLCD_VD[10] — LCD data.
I; PUI/OP1[22] — General purpose digital input/output pin.
IUSB_RCV1 — Differential receive data for USB port 1 (OTG
transceiver).
IUSB_PWRD1 — Power Status for USB port 1 (host power
switch).
OT1_MAT0 — Match output for Timer 1, channel 0.
OMC_0B — Motor control PWM channel 0, output B.
I/OSSP1_MOSI — Master Out Slave In for SSP1.
OLCD_VD[8] — LCD data.
OLCD_VD[12] — LCD data.
[3]
P1[23]76P9N753
I; PUI/OP1[23] — General purpose digital input/output pin.
IUSB_RX_DP1 — D+ receive data for USB port 1 (OTG
transceiver).
OPWM1[4] — Pulse Width Modulator 1, channel 4 output.
IQEI_PHB — Quadrature Encoder Interface PHB input.
IMC_FB1 — Motor control PWM channel 1 feedback input.
I/OSSP0_MISO — Master In Slave Out for SSP0.
OLCD_VD[9] — LCD data.
OLCD_VD[13] — LCD data.
[3]
P1[24]78T9P754
I; PUI/OP1[24] — General purpose digital input/output pin.
IUSB_RX_DM1 — D receive data for USB port 1 (OTG
transceiver).
OPWM1[5] — Pulse Width Modulator 1, channel 5 output.
IQEI_IDX — Quadrature Encoder Interface INDEX input.
IMC_FB2 — Motor control PWM channel 2 feedback input.
I/OSSP0_MOSI — Master Out Slave in for SSP0.
OLCD_VD[10] — LCD data.
OLCD_VD[14] — LCD data.
Product data sheetRev. 5 — 9 September 2014 19 of 122
NXP Semiconductors
LPC178x/7x
32-bit ARM Cortex-M3 microcontroller
Table 3.Pin description
…continued
Not all functions are available on all parts. See Table 2 (Ethernet, USB, LCD, QEI, SD/MMC, DAC pins) and Table 7 (EMC
pins).
Symbol
Pin LQFP208
Ball TFBGA208
Ball TFBGA180
P1[25]80T10L756
[1]
Pin LQFP144
Reset state
[3]
I; PUI/OP1[25] — General purpose digital input/output pin.
Description
[2]
Type
OUSB_LS1
— Low Speed status for USB port 1 (OTG
transceiver).
OUSB_HSTEN1
— Host Enabled status for USB port 1.
OT1_MAT1 — Match output for Timer 1, channel 1.
OMC_1A — Motor control PWM channel 1, output A.
OCLKOUT — Selectable clock output.
OLCD_VD[11] — LCD data.
OLCD_VD[15] — LCD data.
[3]
P1[26]82R10P857
I; PUI/OP1[26] — General purpose digital input/output pin.
OUSB_SSPND1
— USB port 1 Bus Suspend status (OTG
transceiver).
OPWM1[6] — Pulse Width Modulator 1, channel 6 output.
IT0_CAP0 — Capture input for Timer 0, channel 0.
OMC_1B — Motor control PWM channel 1, output B.
I/OSSP1_SSEL — Slave Select for SSP1.
OLCD_VD[12] — LCD data.
OLCD_VD[20] — LCD data.
[3]
P1[27]88T12M961
I; PUI/OP1[27] — General purpose digital input/output pin.
IUSB_INT1
— USB port 1 OTG transceiver interrupt (OTG
transceiver).
IUSB_OVRCR1
— USB port 1 Over-Current status.
IT0_CAP1 — Capture input for Timer 0, channel 1.
OCLKOUT — Selectable clock output.
I; PUI/OP1[28] — General purpose digital input/output pin.
2
I/OUSB_SCL1 — USB port 1 I
C serial clock (OTG transceiver).
IPWM1_CAP0 — Capture input for PWM1, channel 0.
OT0_MAT0 — Match output for Timer 0, channel 0.
OMC_2A — Motor control PWM channel 2, output A.
I/OSSP0_SSEL — Slave Select for SSP0.
OLCD_VD[14] — LCD data.
OLCD_VD[22] — LCD data.
Product data sheetRev. 5 — 9 September 2014 20 of 122
NXP Semiconductors
LPC178x/7x
32-bit ARM Cortex-M3 microcontroller
Table 3.Pin description
…continued
Not all functions are available on all parts. See Table 2 (Ethernet, USB, LCD, QEI, SD/MMC, DAC pins) and Table 7 (EMC
pins).
Symbol
Pin LQFP208
Ball TFBGA208
Ball TFBGA180
P1[29]92U14N10 64
[1]
Pin LQFP144
Reset state
[3]
I; PUI/OP1[29] — General purpose digital input/output pin.
Description
[2]
Type
I/OUSB_SDA1 — USB port 1 I
2
C serial data (OTG transceiver).
IPWM1_CAP1 — Capture input for PWM1, channel 1.
OT0_MAT1 — Match output for Timer 0, channel 1.
OMC_2B — Motor control PWM channel 2, output B.
OU4_TXD — Transmitter output for USART4 (input/output in
Product data sheetRev. 5 — 9 September 2014 23 of 122
NXP Semiconductors
LPC178x/7x
32-bit ARM Cortex-M3 microcontroller
Table 3.Pin description
…continued
Not all functions are available on all parts. See Table 2 (Ethernet, USB, LCD, QEI, SD/MMC, DAC pins) and Table 7 (EMC
pins).
Symbol
Pin LQFP208
Ball TFBGA208
Ball TFBGA180
P2[9]132 H16H1192
[1]
Pin LQFP144
Reset state
[3]
I; PUI/OP2[9] — General purpose digital input/output pin.
Description
[2]
Type
OUSB_CONNECT1 — USB1 SoftConnect control. Signal used to
switch an external 1.5 k resistor under the software control.
Used with the SoftConnect USB feature.
IU2_RXD — Receiver input for UART2.
IU4_RXD — Receiver input for USART4.
I/OENET_MDIO — Ethernet MIIM data input and output.
Product data sheetRev. 5 — 9 September 2014 28 of 122
NXP Semiconductors
LPC178x/7x
32-bit ARM Cortex-M3 microcontroller
Table 3.Pin description
…continued
Not all functions are available on all parts. See Table 2 (Ethernet, USB, LCD, QEI, SD/MMC, DAC pins) and Table 7 (EMC
pins).
Symbol
Pin LQFP208
Ball TFBGA208
Ball TFBGA180
P3[25]56U2M339
[1]
Pin LQFP144
Reset state
[3]
I; PUI/OP3[25] — General purpose digital input/output pin.
Description
[2]
Type
I/OEMC_D[25] — External memory data line 25.
OPWM1[2] — Pulse Width Modulator 1, output 2.
OT0_MAT0 — Match output for Timer 0, channel 0.
[3]
P3[26]55T3K738
I; PUI/OP3[26] — General purpose digital input/output pin.
I/OEMC_D[26] — External memory data line 26.
OPWM1[3] — Pulse Width Modulator 1, output 3.
OT0_MAT1 — Match output for Timer 0, channel 1.
ISTCLK — System tick timer clock input. The maximum STCLK
frequency is 1/4 of the ARM processor clock frequency CCLK.
[3]
P3[27]203 A1--
I; PUI/OP3[27] — General purpose digital input/output pin.
I/OEMC_D[27] — External memory data line 27.
OPWM1[4] — Pulse Width Modulator 1, output 4.
IT1_CAP0 — Capture input for Timer 1, channel 0.
[3]
P3[28]5D2--
I; PUI/OP3[28] — General purpose digital input/output pin.
I/OEMC_D[28] — External memory data line 28.
OPWM1[5] — Pulse Width Modulator 1, output 5.
IT1_CAP1 — Capture input for Timer 1, channel 1.
[3]
P3[29]11F3--
I; PUI/OP3[29] — General purpose digital input/output pin.
I/OEMC_D[29] — External memory data line 29.
OPWM1[6] — Pulse Width Modulator 1, output 6.
OT1_MAT0 — Match output for Timer 1, channel 0.
[3]
P3[30]19H3--
I; PUI/OP3[30] — General purpose digital input/output pin.
I/OEMC_D[30] — External memory data line 30.
OU1_RTS — Request to Send output for UART1. Can also be
configured to be an RS-485/EIA-485 output enable signal for
UART1.
OT1_MAT1 — Match output for Timer 1, channel 1.
[3]
P3[31]25J3--
I; PUI/OP3[31] — General purpose digital input/output pin.
I/OEMC_D[31] — External memory data line 31.
-R — Function reserved.
OT1_MAT2 — Match output for Timer 1, channel 2.
P4[0] to
P4[31]
I/OPort 4: Port 4 is a 32-bit I/O port with individual direction
controls for each bit. The operation of port 4 pins depends upon
the pin function selected via the pin connect block.
[3]
P4[0]75U9L652
I; PUI/OP4[0] — General purpose digital input/output pin.