This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

nrf_dfu_flash needs improvement

Hi. Nordic.

Now I'm developing custom DFU transport which was already developed with SDK 12.x.

At the time of SDK 12, fs_evt_handler calls user's callback with the result flag.

But in SDK15, dfu_fstorage_evt_handler in nrf_dfu_flash.c, just call the registered callback with no result.

I found this only 1/4 of data was written to the flash, because nrf_dfu_flash_store() stores real byte length, in SDK12 that was word length.

I myself would fix this for my project but in my opinion this should be fixed for the Nordic users.

If you have another opinion about this please let me know.

Best.

  • Hi Caram, 

    Thanks for your feedback. I agree that the documentation should be improved. And the callback may need to be implemented, just in case the write execution may fail. 

    But I don't think it's a bug with the implementation in SDK v15.

    The bootloader has been refactored quite a lot from SDK v12 to SDK v15. And we changed the size from len_words to len in nrf_dfu_flash_store() function (because fstorage changed).

    In addition, if the write command fail, the CRC check at the end of the process would be able to detect this. 

Related