
UM10413
All information provided in this document is subject to legal disclaimers.
© NXP B.V. 2011. All rights reserved.
User manual
Rev. 1 — 16 December 2011
231 of 268
NXP Semiconductors
UM10413
MPT612 User manual
25.9.13 Compare <address1> <address2> <no of bytes>
25.9.14 ISP Return codes
Table 229. ISP Compare command
Command
M
Input
address1 (DST):
starting flash or RAM address of data bytes to be compared.
address must be a word boundary.
address2 (SRC):
starting flash or RAM address of data bytes to be compared.
Address must be a word boundary.
number of bytes:
number of bytes to be compared; must be a multiple of 4
Return Code
CMD_SUCCESS | (source and destination data are equal)
COMPARE_ERROR | (followed by the offset of first mismatch)
COUNT_ERROR (byte count is not a multiple of 4) |
ADDR_ERROR |
ADDR_NOT_MAPPED |
PARAM_ERROR |
Description
compares the memory contents at two locations
compare result may not be correct when source or destination address
contains any of the first 64 bytes starting from address zero. First 64 bytes
are
remapped
to flash boot sector
Example
"M 8192 1073741824 4<CR><LF>" compares 4 bytes from the RAM address
0x4000 0000 to the 4 bytes from the flash address 0x2000
Table 230. ISP Return codes summary
Return
code
Mnemonic
Description
0
CMD_SUCCESS
command executed successfully. Sent by ISP
handler only when command given by the host has
been completely and successfully executed.
1
INVALID_COMMAND
invalid command
2
SRC_ADDR_ERROR
source address is not on word boundary
3
DST_ADDR_ERROR
destination address is not on a correct boundary
4
SRC_ADDR_NOT_MAPPED
source address is not mapped in the memory map.
Count value is considered where applicable.
5
DST_ADDR_NOT_MAPPED
destination address is not mapped in the memory
map. Count value is considered where applicable.
6
COUNT_ERROR
byte count is not a multiple of 4 or is not a
permitted value
7
INVALID_SECTOR
sector number is invalid or end sector number is
greater than start sector number
8
SECTOR_NOT_BLANK
sector is not blank
9
SECTOR_NOT_PREPARED_FOR_
WRITE_OPERATION
command to prepare sector for write operation was
not executed
10
COMPARE_ERROR
source and destination data not equal
11
BUSY
flash programming hardware interface is busy
12
PARAM_ERROR
insufficient number of parameters or invalid
parameter
13
ADDR_ERROR
address is not on word boundary