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

Bootloader: DFU Start by Flash content instead of Key operation

Controller: nRF52832-QFAA

Reference project: nRF5_SDK_11.0.0_89a8197/examples/dfu/bootloader/pca10040/dual_bank_ble_s132

Question: The idea is, to store a init_DFU_by_flag into the data flash by the application to initiate the DFU service after RESET. The bootloader has to clear this flag after its recognizing by the erasing of the regarding data page. I guess, the NORDIC-bootloader could use the pstorage raw functions. Exists there a possibility to erase one special data page inside of more than one data page by help of the functions the bootloader uses for the upload of firmware?.

Parents
  • Sorry for my delayed next question. Sometimes I had to work on other parts of the project: I set the GPREGRET register with the value 0xB1 and tried to start the DFU - with the following sequency:

    err_code = sd_power_gpregret_clr(0xFF); APP_ERROR_CHECK(err_code); err_code = sd_power_gpregret_set(BOOTLOADER_DFU_START); APP_ERROR_CHECK(err_code); err_code = sd_power_gpregret_get(&GPREGRET); APP_ERROR_CHECK(err_code); if (0xB1==GPREGRET) { NVIC_SystemReset(); }

    But the bootloader didn't start the DFU and went ahead with the normal start of application. What is wrong?

Reply
  • Sorry for my delayed next question. Sometimes I had to work on other parts of the project: I set the GPREGRET register with the value 0xB1 and tried to start the DFU - with the following sequency:

    err_code = sd_power_gpregret_clr(0xFF); APP_ERROR_CHECK(err_code); err_code = sd_power_gpregret_set(BOOTLOADER_DFU_START); APP_ERROR_CHECK(err_code); err_code = sd_power_gpregret_get(&GPREGRET); APP_ERROR_CHECK(err_code); if (0xB1==GPREGRET) { NVIC_SystemReset(); }

    But the bootloader didn't start the DFU and went ahead with the normal start of application. What is wrong?

Children
No Data
Related