OM13008,598 NXP Semiconductors, OM13008,598 Datasheet - Page 320

no-image

OM13008,598

Manufacturer Part Number
OM13008,598
Description
BOARD LPC XPRESSO LPC122X
Manufacturer
NXP Semiconductors
Series
LPCXpressor
Datasheets

Specifications of OM13008,598

Lead Free Status / RoHS Status
Lead free / RoHS Compliant
Other names
568-6642
OM13008
NXP Semiconductors
UM10441
User manual
20.8.2 Copy RAM to flash
Table 307. IAP Prepare sector(s) for write operation command
Table 308. IAP Copy RAM to flash command
Command
Input
Return Code
Result
Description
Command
Input
Return Code
Result
Description
Prepare sector(s) for write operation
Command code: 50 (decimal)
Param0: Start Sector Number
Param1: End Sector Number (should be greater than or equal to start sector
number).
CMD_SUCCESS |
BUSY |
INVALID_SECTOR
None
This command must be executed before executing "Copy RAM to flash" or "Erase
Sector(s)" command. Successful execution of the "Copy RAM to flash" or "Erase
Sector(s)" command causes relevant sectors to be protected again. The boot
sector can not be prepared by this command. To prepare a single sector use the
same "Start" and "End" sector numbers. To prepare a page or pages for erasing,
use this command and specify the sector or sectors that contain the pages to be
erased.
Copy RAM to flash
Command code: 51 (decimal)
Param0(DST): Destination flash address where data bytes are to be written. This
address must be on a 4 byte boundary. The destination address should be on a
flash word (4 bytes) boundary. Writes on a row boundary (128 bytes) are
preferred as they can be performed more efficiently. The total number of bytes
copied must be ≤ 4096 bytes.
Param1(SRC): Source RAM address from which data bytes are to be read. This
address should be a word boundary.
Param2: Number of bytes to be written. Must be a multiple of 4 bytes.
Param3: System Clock Frequency (CCLK) in kHz.
CMD_SUCCESS |
SRC_ADDR_ERROR (Address not a word boundary) |
DST_ADDR_ERROR (Address not on correct boundary) |
SRC_ADDR_NOT_MAPPED |
DST_ADDR_NOT_MAPPED |
COUNT_ERROR (Byte count is not a multiple of 4) |
SECTOR_NOT_PREPARED_FOR_WRITE_OPERATION |
BUSY |
None
This command is used to program the flash memory. The affected sectors should
be prepared first by calling "Prepare Sector for Write Operation" command. The
affected sectors are automatically protected again once the copy command is
successfully executed.
All information provided in this document is subject to legal disclaimers.
Rev. 1.1 — 10 March 2011
Chapter 20: LPC122x Flash ISP/IAP
UM10441
© NXP B.V. 2011. All rights reserved.
320 of 442

Related parts for OM13008,598