AnsweredAssumed Answered

Calculating application image CRC for KBOOT V2

Question asked by Kevin Luty on May 26, 2016
Latest reply on May 27, 2016 by Bob Paddock

I'm looking to implement the bootloader integrity checking and need to set the CRC start address, byte count, and expected value found in KBOOT V2. 


The reference manual states the crcStartAddress is "generally the start address of the application image, where it resides in the flash or QuadSPI memory." so I'm curious if that start address of the application image would be BL_APP_VECTOR_TABLE_ADDRESS, or is it where main is placed (0xa464 in my case).  Also, what do you recommend I do to figure out the crcByteCount?  Can I just pull a number/calculation out of the .map file, and if so, which one?


Lastly, how should I actually calculate the application CRC?  It seems like a utility or tool should be available where I can easily generate the CRC for my application.  The documentation doesn't really specify much to go off of so I'm hoping you can help.


Using IAR EWARM, FRDM-K22F board, KBOOT V2 freedom bootloader, app vector table address set to 0xA000, USB HID peripheral enabled.