Download uEZ+ Bootloader User`s Manual

Transcript
Appendix B: Image Header Format
The format of each image/file contains the following bytes. All values are given in little endian format.
This header is stored with the image data. The data then directly follows this header.
!
Item
Size
Description
Header
4
Common header for all these files. Must be Hex string 0x48 0x49 0x6D
0x67 for “HImg”
Header size
2
Size in bytes (16-bit value).
Length
4
Number of bytes of this image past this header.
Product ID
32
Null terminated product ID. Must match expected product name
programmed in bootloader.
Reserved
32
Padding of 0’s. Reserved for future use. Must be 0’s.
Version info
4
Must exactly match the other files on the USB drive. First 2 bytes are
major version number. Second 2 bytes are minor version number.
Image location
4
32-bit address in memory. If a standard file on the SDCard, this
location is 0.
CRC
4
CRC of the following data of the above size
Reserved
170
Padding of 0’s to make the header the same size and to reserve possible
future information.
!
!
!26