Apart from pressing Button 4 or adding a DFU service to current running application. Is there any way to enter DFU mode from application?
Is it possible with nrfutil to move from application to DFU Mode, Update the image.
Apart from pressing Button 4 or adding a DFU service to current running application. Is there any way to enter DFU mode from application?
Is it possible with nrfutil to move from application to DFU Mode, Update the image.
Hi!
I am using SDK10 nRF51 and dual boot S310 version of the DFU.
Also i do not intend to share information and I do not have BLE stack set up in my app (using ANT)
Two steps:
In my app call the following:
NRF_POWER->GPREGRET = 0xB1; NVIC_SystemReset();
(You can disable the option at all or do something else)
in /examples/dfu/bootloader/main.c
I simply disabled the check inside ble_stack_init() by removing the if (init_softdevice). I need to always startup the SD since I do not have it enabled in my app and I am doing complete reset in step 1.
Also I disabled anything that is connected to GPIO since on my custom board I do not have buttons etc...
So at the end of the day bootloader(DFU) always starts first, checks the GPREGRET register. If it matches the magic value, voilaa.
This is pretty close to what I am doing as well.
This is pretty close to what I am doing as well.