The API to share information between the bootloader and the main application.
We set aside a small region of RAM at the end of the address space and use this to pass information between the application and the bootloader.
During the initial boot process, if the cause of the reset was a software reset, we check the boot token to see if the application wants us to enter bootloader mode.
The application can enter the bootloader mode by calling BootloaderOptions_SetNextBoot(BOOT_BOOTLOADER) and then forcing a s/w reset.
Go to the source code of this file.
enum | BootOption { BOOT_BOOTLOADER, BOOT_PRIMARY_APPLICATION } |
The different boot options. More... | |
BootOption | BootloaderOptions_GetBootOption () |
Check what code we should run. More... | |
void | BootloaderOptions_SetBootOption (BootOption option) |
Control what we boot after the next s/w reset. More... | |
enum BootOption |
BootOption BootloaderOptions_GetBootOption | ( | ) |
Check what code we should run.
This will only return BOOT_BOOTLOADER after a s/w reset.
void BootloaderOptions_SetBootOption | ( | BootOption | option | ) |
Control what we boot after the next s/w reset.
option | The code to boot. |