Hello,
I used the taget CPU is MK22FN1M0AVLQ12,the bootloader version is NXP_Kinetis_Bootloader_2_0_0,the development tool is KDS 3.2.0.
The bootloader running OK and the Update image funcion is OK.When CPU power,the bootloader timeout 2S,then jump to APP,the APP running OK.
Now i want to implemnet the function that Jump to bootloader from APP,and through the APP_flag control the bootloader running.
bool RunBootloaderFlag = 0U;
if(0x55 = APP_flag)
{
RunBootloaderFlag = 1U;
}
time out = 2000U; /* 2S */
while(activePeripheral == NULL)
{
if((time out > 0U) && (RunBootloaderFlag == 0))
{
time out--;
}
if(time out == 0 )
{
jump_to_application(applicationAddress, stackPointer);
}
wait the shake hands;
}
How can i do that modify the APP_flag?Whether i can call the runBootloader function and pass the parameter.