![NXP Semiconductors LPC43Sxx Скачать руководство пользователя страница 70](http://html1.mh-extra.com/html/nxp-semiconductors/lpc43sxx/lpc43sxx_user-manual_1721827070.webp)
UM10503
All information provided in this document is subject to legal disclaimers.
© NXP B.V. 2015. All rights reserved.
User manual
Rev. 2.1 — 10 December 2015
70 of 1441
NXP Semiconductors
UM10503
Chapter 6: LPC43xx/LPC43Sxx flash programming/ISP and IAP
6.4.3 Boot process for parts with internal flash
See
Section 5.3.1 “Boot process for parts with internal flash”
.
6.4.4 Memory map after any reset
When a user program begins execution after reset, the interrupt vectors are set to point to
the beginning of flash memory (see
).
6.4.4.1 Criterion for Valid User Code
The reserved Cortex-M4 exception vector location 7 (offset 0x 001C in the vector table)
should contain the 2’s complement of the check-sum of table entries 0 through 6. This
causes the checksum of the first 8 table entries to be 0. The boot loader code checksums
the first 8 locations in sector 0 of the flash. If the result is 0, then execution control is
transferred to the user code.
If the signature is not valid, the auto-baud routine synchronizes with the host via serial port
0. The host should send a “?” (0x3F) as a synchronization character and wait for a
response. The host side serial port settings should be 8 data bits, 1 stop bit and no parity.
The auto-baud routine measures the bit time of the received synchronization character in
terms of its own frequency and programs the baud rate generator of the serial port. It also
sends an ASCII string ("Synchronized<CR><LF>") to the host. In response to this the host
should send the same string ("Synchronized<CR><LF>"). The auto-baud routine looks at
the received characters to verify synchronization. If synchronization is verified then
"OK<CR><LF>" string is sent to the host. The host should respond by sending
“0<CR><LF>" for backwards compatibility with existing tools. "OK<CR><LF>" string is
sent to the host after receiving “0<CR><LF>". If synchronization is not verified then the
auto-baud routine waits again for a synchronization character.
Once the UART has established synchronization, the boot loader invokes the ISP
command handler. For safety reasons an "Unlock" command is required before executing
the commands resulting in flash erase/write operations and the "Go" command. The rest
of the commands can be executed without the unlock command. The Unlock command is
required to be executed once per ISP session. The Unlock command is explained in
6.4.5 Communication protocol
All 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.
6.4.5.1 ISP command format
"Command Parameter_0 Parameter_1 … Parameter_n<CR><LF>" "Data" (Data only for
Write commands).
6.4.5.2 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).