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
40 of 1269
NXP Semiconductors
UM10503
Chapter 5: LPC43xx Boot ROM
The first message block is the header. Since the CMAC tag is stored in the header field
HASH_VALUE, and this tag is not yet known until after CMAC calculation, a temporary
header with a dummy tag value of 0x3456789A is used during CMAC calculation. This
dummy value should be replaced by the calculated tag value in the final header field
HASH_VALUE.
For LPC43xx the chosen CMAC parameters are: encryption key K = User Key (same as
used for decryption) and tag length l = 64. Data is processed in little endian mode. This
means that the first byte read from the image is integrated into the AES codeword as least
significant byte. The 16th byte read from the image is the most significant byte of the first
AES codeword.
CMAC is calculated over the header and encrypted image.
5.3.5 Boot modes
5.3.5.1 UART boot mode
details the boot-flow steps of the UART boot mode. The execution of this mode
occurs only if the boot mode is set accordingly (see boot modes
).
As illustrated in
, configure the UART with the following settings:
•
Baudrate = 115200, 57600, 38400, 19200, or 9600
•
Data bits = 8
•
Parity = None
•
Stop bits = 1
Auto baud is active; boot waits until 0x3F is received and responds with “OK”. This should
be followed by the header and image. The boot ROM doesn't implement any flow control
or any handshake mechanisms during file transfer.
After the boot image is downloaded, it is checked (based on header information) to be a
valid or invalid image and OK respectively FAILED is sent to a host followed by CR and
LF. Finally, the full boot image is copied, processed to address 0x10000000 and executed
from there.
Fig 12. CMAC generation
M
1
AES
K
+
M
2
AES
K
+
M*
n
AES
K
K
1
MSB
64
Tag