UM10503
All information provided in this document is subject to legal disclaimers.
© NXP B.V. 2012. All rights reserved.
User manual
Rev. 1.3 — 6 July 2012
1169 of 1269
NXP Semiconductors
UM10503
Chapter 46: LPC43xx flash programming/ISP and IAP
46.4 General description
The boot loader controls initial operation after reset and also provides the tools for
programming the flash memory. This could be initial programming of a blank device,
erasure and re-programming of a previously programmed device, or programming of the
flash memory by the application program in a running system.
The boot loader code is executed every time the part is powered on or reset. The boot
loader can execute the ISP command handler or the user application code.
A HIGH level after reset on pin P2_7, starts the boot process either from on-chip flash if
available or from an external boot source for flashless parts (see
A LOW level after reset on pin P2_7 indicates an external hardware request to start the
ISP command handler:
•
On parts with on-chip flash, the setting of the OTP bits and the boot pins determine
which USART (USART0 or USART3) is configured for ISP communication (see
•
On flashless parts, ISP communication uses USART0 regardless of the settings of the
OTP bits or the boot pins.
When the ISP mode is entered after a power-on-reset, the IRC and PLL1 are used to
generate the core clock of 96 MHz. Pins P2_0 and P2_1 are used for communication with
the USART0 and pins P2_3 and P2_4 are used for USART3. The UART PCLK (from
BASE_UART0/3_CLK) is set to the IRC (12 MHz).
After determining the host’s baud rate, the test string “Synchronized” is sent to a host.
After a successful handshake, ISP enters the command interpret mode.
46.4.1 Sampling of pin P2_7
Assuming that power supply pins are on their nominal levels when the rising edge on
RESET pin is generated, it may take up to 3 ms before P2_7 is sampled and the decision
on whether to continue with user code or ISP handler is made.
If P2_7 is sampled LOW and the watchdog overflow flag is set, the external hardware
request to start the ISP command handler is ignored. If there is no request for the ISP
command handler execution (P2_7 is sampled HIGH after reset), the boot loader
searches for a valid user program in the on-chip flash or, on flashless parts, enters one of
the external boot modes.
If a valid user program is found, then the execution control is transferred to it. If a valid
user program is not found, the boot process defaults to the ISP mode using USART0 and
the auto-baud routine is invoked.
Pin P2_7 is used as a hardware request signal for ISP and requires special attention. It is
recommended to provide external hardware (a pull-up resistor or other device) to put the
pin in a defined state. Otherwise unintended entry into ISP mode may occur.