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

NRF52832 DFU problems

Why each time to upgrade your program need to manually reset chips to run at a time, I use a software reset, but no effect?

Parents
  • Hi Tom,

    Please provide more information. Which SDK version you are using ?

    How did you test? Have you tried with our stock bootloader example in the SDK and the example .zip file comes with the phone app ?

  • Hi Hung Bui,

    The SDK version is V11. I in official Bootlader program to modify some of the program, modify parts as follows: if(*p0==0x55667788) dfu_start=true; else dfu_start=false; //dfu_start |= ((nrf_gpio_pin_read(BOOTLOADER_BUTTON) == 0) ? true: false);

    if(dfu_start )//||(!bootloader_app_is_valid(DFU_BANK_0_REGION_START)))
    {
    		  *p0=0;
        //nrf_gpio_pin_clear(UPDATE_IN_PROGRESS_LED);
    
        // Initiate an update of the firmware.
        err_code = bootloader_dfu_start(); 
        APP_ERROR_CHECK(err_code);
    
        //nrf_gpio_pin_set(UPDATE_IN_PROGRESS_LED);
    }
    else if(!dfu_start)
    //if(bootloader_app_is_valid(DFU_BANK_0_REGION_START) && !bootloader_dfu_sd_in_progress())
    {
        // Select a bank region to use as application region.
        // @note: Only applications running from DFU_BANK_0_REGION_START is supported.
        bootloader_app_start(DFU_BANK_0_REGION_START);
    }
    

    When I want to upgrade, I have already wrote in the specified flash 0 x55667788, can now normal upgrade, just after the upgrade need to manually reset the development board, is this why?

Reply
  • Hi Hung Bui,

    The SDK version is V11. I in official Bootlader program to modify some of the program, modify parts as follows: if(*p0==0x55667788) dfu_start=true; else dfu_start=false; //dfu_start |= ((nrf_gpio_pin_read(BOOTLOADER_BUTTON) == 0) ? true: false);

    if(dfu_start )//||(!bootloader_app_is_valid(DFU_BANK_0_REGION_START)))
    {
    		  *p0=0;
        //nrf_gpio_pin_clear(UPDATE_IN_PROGRESS_LED);
    
        // Initiate an update of the firmware.
        err_code = bootloader_dfu_start(); 
        APP_ERROR_CHECK(err_code);
    
        //nrf_gpio_pin_set(UPDATE_IN_PROGRESS_LED);
    }
    else if(!dfu_start)
    //if(bootloader_app_is_valid(DFU_BANK_0_REGION_START) && !bootloader_dfu_sd_in_progress())
    {
        // Select a bank region to use as application region.
        // @note: Only applications running from DFU_BANK_0_REGION_START is supported.
        bootloader_app_start(DFU_BANK_0_REGION_START);
    }
    

    When I want to upgrade, I have already wrote in the specified flash 0 x55667788, can now normal upgrade, just after the upgrade need to manually reset the development board, is this why?

Children
No Data
Related