Hi guys,
I've almost got DFU working on SDK10. However I am having issues at post validation of the image, specifically in the function dfu_init_postvalidate() in file dfu_init_template.c. In this function the CRC passed from the init file is compared to the locally calculated CRC via a crc16_compute() call. However this function does not seem to return a matching value. I know the init file has the correct the CRC of my image and it is correctly passed to the bootloader. However every time, the locally calculated CRC does not match (incorrect). I could easily bypass this step, but I'd rather keep it for an image integrity check.
If directly DFU the .hex file without .zip generation via NrfStudio I see that nrfStudio sends the same CRC calculation as my .zip file. So the only possible source of error is in the local crc16_compute() . How is crc16_compute() different from the way nrf.exe calculates the CRC? Has anyone faced this issue?
Thanks guys,
DC