Hi,
Chip : NRF52810
Soft Device : s132_nrf52_5.1.0
SDK : nrf5_sdk_for_thread_and_zigbee_v4.2.0_af27f76 (BLE BootLoader)
IDE : Segger Embedded Studio
SDK : nRF5_SDK_14.2.0_17b948a (BLE Application)
IDE : IAR Embedded Workbench
in BLE Application i am trying to reboot and enter to bootloader for serial DFU.
i have checked in nrf devzone and did some changed as suggested but still it reboot and enter to BLE Application.
BLE application main.c has been added following codes to set start bootloader
sd_power_gpregret_set(1,BOOTLOADER_DFU_START); // to enable dfu_check true
nrf_nvmc_write_word(0x00022000, (uint32_t) dfu_flag); // to enable dfu_check true
nrf_pwr_mgmt_shutdown(NRF_PWR_MGMT_SHUTDOWN_GOTO_DFU); //
NVIC_SystemReset();. //reboot to jump to bootloader
in Application sdkconfig did following changes.
#define BLE_DFU_ENABLED 1
#define NRF_DFU_BLE_BUTTONLESS_SUPPORTS_BONDS 1
#define NRF_PWR_MGMT_CONFIG_AUTO_SHUTDOWN_RETRY 1
#define NRF_SDH_BLE_VS_UUID_COUNT 2
#define NRF_SDH_BLE_SERVICE_CHANGED 1
#define NRF_SDH_BLE_SERVICE_CHANGED 1
From bootloader dfu_enter_check() nrf_power_gpregret_get() but it never returns true.
also tries to read nvic memory to read flag to make dfu_enter_check true.
uint32_t DFU_Flag_data = 0;
uint32_t* dfu_flag_mem2 = (uint32_t*) 0x00022000;
DFU_Flag_data = (uint32_t)*dfu_flag_mem2 ;
if(DFU_Flag_data != 0xFFFFFFFF) dfu_enter = true;
but after NVIC_SystemReset(); the application restart without entering to dfu_check.
how can i verify and enter to bootloader after systemreset().
Both BLE Application and BLE Bootloader is tested individually and works fine.