UM10429
All information provided in this document is subject to legal disclaimers.
© NXP B.V. 2010. All rights reserved.
User manual
Rev. 1 — 20 October 2010
152 of 258
NXP Semiconductors
UM10429
Chapter 17: LPC1102 Flash memory programming firmware
In case a CRP mode is enabled and access to the chip is allowed via the ISP, an
unsupported or restricted ISP command will be terminated with return code
CODE_READ_PROTECTION_ENABLED.
17.4 UART Communication protocol
All UART ISP commands should be sent as single ASCII strings. Strings should be
terminated with Carriage Return (CR) and/or Line Feed (LF) control characters. Extra
<CR> and <LF> characters are ignored. All ISP responses are sent as <CR><LF>
terminated ASCII strings. Data is sent and received in UU-encoded format.
17.4.1 UART ISP command format
"Command Parameter_0 Parameter_1 ... Parameter_n<CR><LF>" "Data" (Data only for
Write commands).
17.4.2 UART ISP response format
"Return_Code<CR><LF>Response_0<CR><LF>Response_1<CR><LF> ...
Response_n<CR><LF>" "Data" (Data only for Read commands).
17.4.3 UART ISP data format
The data stream is in UU-encoded format. The UU-encode algorithm converts 3 bytes of
binary data in to 4 bytes of printable ASCII character set. It is more efficient than Hex
format which converts 1 byte of binary data in to 2 bytes of ASCII hex. The sender should
send the check-sum after transmitting 20 UU-encoded lines. The length of any
UU-encoded line should not exceed 61 characters (bytes) i.e. it can hold 45 data bytes.
Table 150. ISP commands allowed for different CRP levels
ISP command
CRP1
CRP2
CRP3
Unlock
yes
yes
n/a
Set Baud Rate
yes
yes
n/a
Echo
yes
yes
n/a
Write to RAM
yes; above 0x1000 0300
only
no
n/a
Read Memory
no
no
n/a
Prepare sector(s) for
write operation
yes
yes
n/a
Copy RAM to flash
yes; not to sector 0
no
n/a
Go
no
no
n/a
Erase sector(s)
yes; sector 0 can only be
erased when all sectors are
erased.
yes; all sectors
only
n/a
Blank check sector(s)
no
no
n/a
Read Part ID
yes
yes
n/a
Read Boot code version yes
yes
n/a
Compare
no
no
n/a
ReadUID
yes
yes
n/a