Hi all,
I'd like to pass bootloader version (2bytes) from bootloader_util_reset function (bootloader) to the main of application. can help me to acheive that?
Thank you for your help in advance.
Hi all,
I'd like to pass bootloader version (2bytes) from bootloader_util_reset function (bootloader) to the main of application. can help me to acheive that?
Thank you for your help in advance.
I'd like to passe bootloder version as argument for main function (int main(int argc, char *argv[])
Which bootloader version are you using?
Custom bootloader (inspired from bootloader legacy sdk 9).
You could use the retention registers, each of which is one byte.
#import "nrf_power.h"
...
NRF_POWER->GPREGRET = bootloader_version && 0xff;
NRF_POWER->GPREGRET2 =bootloader_version >> 8 && 0xff;
...
These are retained when performing a standard soft reset NVIC_SystemReset
.
hi shibshab , thank you for your reply.