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

serial DFU - failing on execution of init-pack

Hi @ all,

I am trying to get the serial DFU process runnning. The process worked fine for nrf52832 and now I am on the nrf52840.

I encountered a problem with executing the init-package.

The following process is done fine:

1. Get MTU - set PRN to 0

2. Selecting the command object

3. Transmit Data of command object

4. Read CRC/Offset

Reading the CRC and offset values is showing that the data from the init pack got transfered successfully. After this, I am trying to execute the init-pack and I get the following response:

"0x60 0x04 0x0b 0x07 0xc0". So there is somehow one byte too much and the error code is not listed in the execute-request documentation. The execute request should return one of those: 

The object type of the currently selected object is invalid. NRF_DFU_RES_CODE_INVALID_OBJECT
The current state of the transfer does not permit executing the current object. NRF_DFU_RES_CODE_OPERATION_NOT_PERMITTED

what does 0x0b 0x07 mean? Am I missing a step? The bootloader is based on SDK 15.0.0

Hope you guys can help me out!

Sincerly,

Hannes

Parents
  • Hi Ha,

    If you have a look inside the code you can find error code 0x0b =  NRF_DFU_RES_CODE_EXT_ERROR inside nrf_dfu_req_handler.h 

    The extended error code is listed inside nrf_dfu_ext_error_code_t in nrf_dfu_handling_error.h. Code 0x07 meaning :

    NRF_DFU_EXT_ERROR_SD_VERSION_FAILURE = 0x07, /**< The array of supported SoftDevices for the update does not contain
    the FWID of the current SoftDevice or the first FWID is '0' on a
    bootloader which requires the SoftDevice to be present. */

    Could it be that you used the wrong SD version, doesn't match with what on the nRF52840 ? 

    You can add a breakpoing inside sd_req_ok() to check what exactly went wrong. 

Reply
  • Hi Ha,

    If you have a look inside the code you can find error code 0x0b =  NRF_DFU_RES_CODE_EXT_ERROR inside nrf_dfu_req_handler.h 

    The extended error code is listed inside nrf_dfu_ext_error_code_t in nrf_dfu_handling_error.h. Code 0x07 meaning :

    NRF_DFU_EXT_ERROR_SD_VERSION_FAILURE = 0x07, /**< The array of supported SoftDevices for the update does not contain
    the FWID of the current SoftDevice or the first FWID is '0' on a
    bootloader which requires the SoftDevice to be present. */

    Could it be that you used the wrong SD version, doesn't match with what on the nRF52840 ? 

    You can add a breakpoing inside sd_req_ok() to check what exactly went wrong. 

Children
Related