工具与软件:
您好!
我将以 rfOAD 和 Linux 应用为基础编写 TI15.4 OAD 服务器代码以嵌入到 CC1312PSIP 中。
您能告诉我将映像识别负载添加到 OAD 文件的位置吗? 我已经浏览过 oad_image_tool.py 和 oad_write_bin.py 但我无法看到此标头创建的位置。
/* Image Identify Payload */
typedef struct __attribute__((packed))
{
uint8_t imgID[8]; //!< User-defined Image Identification bytes. */
uint8_t bimVer; //!< BIM version */
uint8_t metaVer; //!< Metadata version */
uint8_t imgCpStat; //!< Image copy status bytes */
uint8_t crcStat; //!< CRC status */
uint8_t imgType; //!< Image Type */
uint8_t imgNo; //!< Image number of 'image type' */
uint32_t len; //!< Image length in bytes
uint8_t softVer[4]; //!< Software version of the image */
uint8_t isDeltaImg; //!< Indicates if payload is delta image */
uint8_t toadMetaVer; //!< Turbo OAD header version */
uint8_t toadVer; //!< Turbo OAD version */
uint8_t memoryCfg; //!< Flash configuration used */
uint32_t oldImgCrc; //!< CRC of the current app image */
uint32_t newImgLen; //!< Length of the new app image */
} OADStorage_imgIdentifyPld_t;
我考虑这一点的原因是 BIM 和 meta 版本导致我在将 bin 文件上传到服务器时在 oad_storage.c 中出现问题。 如何确保 BIM 和 meta 版本匹配?
// Ensure the image is built with a compatible BIM and META (ensures the image is meant for the right bootloader too)
if(idPld->bimVer != currentImageHeader->fixedHdr.bimVer ||
idPld->metaVer != currentImageHeader->fixedHdr.metaVer )
{
status = OADStorage_Rejected;
}
谢谢!
Andy