TI BLE-Stack for Bluetooth API Documentation
3.03.02.00
|
Structure definition for image header and segments, these are prepended to the over the air images.
Go to the source code of this file.
Data Structures | |
struct | eccSignature_t |
ECC signature pair. More... | |
Macros | |
#define | BIM_VER 0x1 |
#define | BIM_VER_OFFSET offsetof(imgHdr_t, fixedHdr.bimVer) |
#define | BOUNDARY_SEG_LEN 0x18 |
#define | BOUNDARY_SEG_OFFSET offsetof(imgHdr_t, fixedHdr.segTypeBd) |
#define | COPY_DONE 0xFC |
#define | CRC_INVALID 0xFC |
#define | CRC_OFFSET offsetof(imgHdr_t, fixedHdr.crc32) |
#define | CRC_STAT_OFFSET offsetof(imgHdr_t, fixedHdr.crcStat) |
#define | CRC_VALID 0xFE |
#define | DEFAULT_CRC 0xFFFFFFFF |
#define | DEFAULT_STATE 0xFF |
#define | ECDSA_KEY_LEN 32 |
#define | ECDSA_SHA_TEMPWORKZONE_LEN ECDSA_KEY_LEN*6 |
#define | EFL_MATADATA_HDR_LEN OAD_IMG_HDR_LEN + 8 |
#define | HDR_LEN_WITH_SECURITY_INFO offsetof(imgHdr_t, secInfoSeg.segTypeSecure) + sizeof(securityInfoSeg_t) |
#define | IMG_BOUNDARY_SEG_ID 0x00 |
#define | IMG_COPY_STAT_OFFSET IMG_INFO_OFFSET |
#define | IMG_COPY_STAT_OFFSET IMG_INFO_OFFSET |
#define | IMG_DATA_OFFSET BIM_VER_OFFSET |
#define | IMG_INFO_OFFSET offsetof(imgHdr_t, fixedHdr.imgCpStat) |
#define | IMG_NONCOUNT_SEG_ID 0x02 |
#define | IMG_PAYLOAD_SEG_ID 0x01 |
#define | IMG_SECURITY_SEG_ID 0x03 |
#define | IMG_START_ADDR_OFFSET offsetof(imgHdr_t, imgPayload.startAddr) |
#define | IMG_TYPE_OFFSET offsetof(imgHdr_t, fixedHdr.imgType) |
#define | INVALID_ADDR 0xFFFFFFFF |
#define | INVALID_LEN INVALID_ADDR |
#define | META_VER 0x1 |
#define | NEED_COPY 0xFE |
#define | OAD_EXTFL_ID_VAL {'O', 'A', 'D', ' ', 'N', 'V', 'M', '1'} |
OAD_IMG_ID_VAL Magic number to identify OAD image header. It is recommended that the customer adjust these to uniquely identify their device. More... | |
#define | OAD_IMG_FULL_HDR_LEN sizeof(imgHdr_t) |
#define | OAD_IMG_HDR_LEN sizeof(imgFixedHdr_t) |
#define | OAD_IMG_ID_LEN 8 |
#define | OAD_IMG_ID_LEN 8 |
#define | OAD_IMG_TYPE_APP 1 |
#define | OAD_IMG_TYPE_APP_STACK 3 |
#define | OAD_IMG_TYPE_APPSTACKLIB 7 |
#define | OAD_IMG_TYPE_BIM 6 |
#define | OAD_IMG_TYPE_FACTORY 5 |
#define | OAD_IMG_TYPE_HOST_BEGIN 32 |
#define | OAD_IMG_TYPE_HOST_END 63 |
#define | OAD_IMG_TYPE_NP 4 |
#define | OAD_IMG_TYPE_PERSISTENT_APP 0 |
#define | OAD_IMG_TYPE_RSVD_BEGIN 64 |
#define | OAD_IMG_TYPE_RSVD_END 255 |
#define | OAD_IMG_TYPE_STACK 2 |
#define | OAD_IMG_TYPE_USR_BEGIN 16 |
#define | OAD_IMG_TYPE_USR_END 31 |
#define | OAD_NUM_NV_PGS 1 |
#define | OAD_SEG_BOUNDARY 0x00 |
#define | OAD_SEG_CONTIGUOUS 0x01 |
#define | OAD_SEG_NON_CONTIGUOUS 0x02 |
#define | OAD_SEG_RSVD 0xFF |
#define | OAD_SW_VER_LEN 4 |
#define | OAD_SW_VER_LEN 4 |
#define | OAD_WIRELESS_TECH_BLE 0xFFFE |
#define | OAD_WIRELESS_TECH_EASYLINK 0xFFBF |
#define | OAD_WIRELESS_TECH_RF4CE 0xFFEF |
#define | OAD_WIRELESS_TECH_THREAD 0xFFDF |
#define | OAD_WIRELESS_TECH_TIMAC_2_4G 0xFFFB |
#define | OAD_WIRELESS_TECH_TIMAC_SUBG 0xFFFD |
#define | OAD_WIRELESS_TECH_ZIGBEE 0xFFF7 |
#define | SEC_VERIF_STAT_OFFSET offsetof(imgHdr_t, secInfoSeg.verifStat) |
#define | SECURITY_SEG_LEN 0x55 |
#define | SECURITY_VER 0x1 |
#define | SEG_HDR_LEN 12 |
#define | SEG_LEN_OFFSET 4 |
#define | SEG_LEN_OFFSET 4 |
#define | SEG_SIGERINFO_OFFSET offsetof(imgHdr_t, secInfoSeg.secSignerInfo) |
#define | SEG_SIGNR_OFFSET offsetof(imgHdr_t, secInfoSeg.eccSign.sign_r) |
#define | SEG_SIGNS_OFFSET offsetof(imgHdr_t, secInfoSeg.eccSign.sign_s) |
#define | SIG_OFFSET offsetof(imgHdr_t, secInfoSeg.eccSign.sign_r) |
#define | SOFTWARE_VER {'0', '0', '0', '1'} |
#define | VERIFY_FAIL 0xFC |
#define | VERIFY_PASS 0xFE |
Variables | |
uint8_t | bimVer |
BIM version. | |
boundarySeg_t | |
uint32_t | boundarySegLen |
uint32_t | crc32 |
Image's 32-bit CRC value. | |
uint8_t | crcStat |
CRC status. | |
eccSignature_t | eccSign |
Security signature */. | |
ecdsaSigVerifyBuf_t | |
uint16_t | hdrLen |
Total length of the image header. | |
uint8_t | imgCpStat |
Image copy status. | |
uint32_t | imgEndAddr |
Address of the last byte of a contiguous image. | |
imgFixedHdr_t | |
imgHdr_t | |
uint8_t | imgNo |
Image number of 'image type'. | |
imgPayloadSeg_t | imgPayload |
Required contiguous image segment. | |
imgPayloadSeg_t | |
uint32_t | imgSegLen |
Payload segment length. | |
uint8_t | imgType |
Image Type. | |
uint32_t | imgVld |
This field is RFU. | |
uint32_t | len |
Image length in bytes. | |
uint8_t | metaVer |
Metadata version. | |
uint32_t | prgEntry |
Program entry address. | |
uint32_t | ram0EndAddr |
uint32_t | ram0StartAddr |
uint16_t | rfu |
Reserved bytes. More... | |
uint32_t | secSegLen |
Payload segment length. | |
uint8_t | secSignerInfo [8] |
Security signer info */. | |
uint32_t | secTimestamp |
Security timestamp */. | |
securityInfoSeg_t | |
uint8_t | secVer |
Security version */. | |
uint8_t * | SHAWorkzone |
SHA workzone buffer should be of size(SHA256_memory_t) bytes. | |
uint8_t | softVer [4] |
Software version of the image. | |
uint32_t | stackEntryAddr |
uint32_t | stackStartAddr |
uint32_t | startAddr |
Start address of image on internal flash. | |
uint16_t | techType |
Wireless protocol type BLE/TI-MAC/ZIGBEE etc. | |
uint8_t * | tempWorkzone |
Should be size 6*ECDSA_KEY_LEN bytes. | |
TYPEDEF_STRUCT_PACKED | |
OAD Core image header structure definition More... | |
uint8_t | verifStat |
Verification status. | |
uint16_t | wirelessTech |
Wireless technology type. More... | |
#define BIM_VER 0x1 |
Version of BIM this image is intended to work with
#define BOUNDARY_SEG_LEN 0x18 |
Length of the boundary segment.
#define COPY_DONE 0xFC |
Flagimg CpStat indicating the image is already copied
#define CRC_INVALID 0xFC |
Flag for crcStat indicating the CRC of the image is invalid
#define CRC_VALID 0xFE |
Flag for crcStat indicating the CRC of the image is valid
#define DEFAULT_CRC 0xFFFFFFFF |
An invalid address as shown by unprogrammed flash.
#define DEFAULT_STATE 0xFF |
Default state of unprogrammed flash in an image header field
#define ECDSA_KEY_LEN 32 |
Length of ECDSA keys in bytes.
#define ECDSA_SHA_TEMPWORKZONE_LEN ECDSA_KEY_LEN*6 |
space for six buffers finalHash, reverseHash, pubkeyX, pubKeyY, sign1, sign2 .
#define EFL_MATADATA_HDR_LEN OAD_IMG_HDR_LEN + 8 |
Length of image external flash image header
#define INVALID_ADDR 0xFFFFFFFF |
An invalid address as shown by unprogrammed flash
#define INVALID_LEN INVALID_ADDR |
An invalid length as shown by unprogrammed flash.
#define META_VER 0x1 |
Version of metadata that defined this image header
#define NEED_COPY 0xFE |
FlagimgCpStat indicating the image should be copied
#define OAD_IMG_FULL_HDR_LEN sizeof(imgHdr_t) |
The length of the OAD Header + Segments.
#define SECURITY_SEG_LEN 0x55 |
Length of the security segment.
#define SECURITY_VER 0x1 |
Version of metadata that defined this image header
#define SIG_OFFSET offsetof(imgHdr_t, secInfoSeg.eccSign.sign_r) |
Offset from the start of security seg to sig.
#define SOFTWARE_VER {'0', '0', '0', '1'} |
Software version of the image.
#define VERIFY_FAIL 0xFC |
Flagimg verification status indicating the failed sign verification
#define VERIFY_PASS 0xFE |
Flagimg verification status indicating the successful sign verification
uint32_t boundarySegLen |
Boundary segment length
uint32_t ram0EndAddr |
RAM entry end address
uint32_t ram0StartAddr |
RAM entry start address
uint8_t rfu |
Reserved bytes.
Reserved byte.
Reserved byte
uint32_t stackEntryAddr |
Stack start address
uint32_t stackStartAddr |
Start address of stack image on internal flash
TYPEDEF_STRUCT_PACKED |
OAD Core image header structure definition
ECDSA sign verification buffer.
OAD Image Header.
OAD security information segment.
OAD boundary segment.
OAD continuous image payload segment.
This segment is used to describe a contiguous region of an image The code data in this blob will be flashed to sequential addressesSegment type - for Contiguous image payload
This segment is used to describe the RAM and Flash boundaries in a split image system.
This segment is used to describe the security information stored in security segment such as verification status, security version, timestamp etc.Segment type - for Secuirty info payload
This structure represents the complete header to be prepended to an OAD image
It is an amalgamation of the structures defined above, and must contain a core headerRequired core image header
This structure used to describe the structure of ECC workzone bufferShould be of length ECCROMCC26XX_NIST_P256_WORKZONE_SIGN_VERIFY_LEN_IN_BYTES*sizeof(uint32_t) bytes
uint16_t wirelessTech |
Wireless technology type.
Wireless technology type