I'm using KBOOT v2.0 and a MK22F512VLH12 chip.
I currently have my user application placed at 0xA000 and it is running MQX. Direct boot is currently enabled, so at power-up, it skips the bootloader and goes straight into user application.
Now, I want to be able to go from my user application into the bootloader. I've tried using the code found in the bootloader manual however that seems to be unsuccessful:
void (*runBootloader)(void * arg);
void run_bootloader(void * arg)
// Read the function address from the ROM API tree.
runBootloaderAddress = **(uint32_t **)(0x0000001CUL);
runBootloader = (void (*)(void * arg))runBootloaderAddress;
And then I eventually call:
What am I doing wrong? How can I jump back into bootloader successfully?