mirror of
https://github.com/PX4/PX4-Autopilot.git
synced 2026-06-01 19:07:45 +08:00
NXPHlite-V3:Add reset to bootloader detection
On the K66 we use the first word of the Battery backed up RAM as the bootloader - app communication location.
This commit is contained in:
committed by
Daniel Agar
parent
cb58fa5131
commit
35960fb012
@@ -42,6 +42,8 @@
|
|||||||
#include <nuttx/board.h>
|
#include <nuttx/board.h>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
int board_set_bootload_mode(board_reset_e mode)
|
int board_set_bootload_mode(board_reset_e mode)
|
||||||
{
|
{
|
||||||
uint32_t regvalue = 0;
|
uint32_t regvalue = 0;
|
||||||
@@ -59,8 +61,7 @@ int board_set_bootload_mode(board_reset_e mode)
|
|||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
}
|
}
|
||||||
|
|
||||||
// todo: Add a way to enter bootloader
|
*((uint32_t *) KINETIS_VBATR_BASE) = regvalue;
|
||||||
UNUSED(regvalue);
|
|
||||||
return OK;
|
return OK;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user