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

Buttonless DFU jumps to Application not Bootloader

Hi everybody,

we have implemented DFU with button and it works like a charm. Now we want to improve that and implemented the buttonless version too. Though, instead of starting the bootloader the application is restarted. There may be something wrong with addresses causing this behavior.

Here is the code called when triggering DFU from application:

static void boot_start(void) {
	ble_conn_params_stop();
	sd_power_gpregret_clr(POWER_GPREGRET_GPREGRET_Msk);
	sd_power_gpregret_set(BOOTLOADER_DFU_START);
	sd_softdevice_disable();
	interrupts_disable();
	sd_softdevice_vector_table_base_set(CODE_REGION_1_START);	
	bootloader_util_app_start(CODE_REGION_1_START);
}

Looking forward to your reply.

Best Philipp

Parents
  • Hi Hung Bui, thanks for the feedback. Yes, you are right CODE_REGION_1_START is application start address. When I manually set the address of the bootloader to 7a000 or the value of the register NRF_UICR->NRFFW[0] nothing happens and I got a freeze. I also tried the NVIC_SystemReset. That one starts with the bootloader but DFU mode is not accessed. In application I already set the GPREGRET register and in bootloader the register is checked.

    Forwarding of bonding information is not required.

Reply
  • Hi Hung Bui, thanks for the feedback. Yes, you are right CODE_REGION_1_START is application start address. When I manually set the address of the bootloader to 7a000 or the value of the register NRF_UICR->NRFFW[0] nothing happens and I got a freeze. I also tried the NVIC_SystemReset. That one starts with the bootloader but DFU mode is not accessed. In application I already set the GPREGRET register and in bootloader the register is checked.

    Forwarding of bonding information is not required.

Children
No Data
Related