I have a known working distribution (ZIP) file that when flashed onto a device, correctly goes into the application and is able to do buttonless DFU. This was left behind by a previous engineer.
I modified the bootloader to show debug statements to RTT and to change the UUID when in DFU mode (from the default DfuTarg). I then generated a settings hex file and the distribution ZIP using nrfutil as such:
nrfutil settings generate --family NRF52840 \ --key-file $KEYFILE \ --application $HEXFILE --application-version 0 \ --bootloader-version 0 --bl-settings-version 1 \ $SETTINGSFILE nrfutil pkg generate --key-file $KEYFILE --application $HEXFILE $PKGFILE \ --hw-version 52 --sd-req 0xAE --application-version 0 \ --bootloader $BL_FILE --bootloader-version 0 \
When I program up a DK with the combined hex files, it goes into application mode as supposed but it fails to recognize the bootloader and settings Thus I can't go into buttonless DFU. nrfConnect Programmer shows this:
The merged hex files are on the right and it shows that the bootloader and settings are viewed as application data on the DK. For comparison here's the working ZIP:
It has recognized the bootloader and settings.
nrfConnect Programmer shows that the bootloader, settings and softdevice are set to the same address in memory however, the size of the bootloader and application is different obviously due to the changes I've made. I've tried reverting my changes to the bootloader but no luck.
I'm using a nRF52840-Preview-DK and SDK15.2.0.0.
Can anyone tell me what's wrong?