mirror of
https://bitbucket.org/librepilot/librepilot.git
synced 2025-01-18 03:52:11 +01:00
safeboot: add safe boot support to OP and PIPX bootloaders
Application support for OP and PIPX will show up in future commits.
This commit is contained in:
parent
2d27c54d48
commit
1d14ab00e1
@ -353,10 +353,18 @@ void processComand(uint8_t *xReceive_Buffer) {
|
||||
DeviceState = failed_jump;
|
||||
break;
|
||||
} else {
|
||||
if (Data == 0x5AFE) {
|
||||
/* Force board into safe mode */
|
||||
PIOS_IAP_WriteBootCount(0xFFFF);
|
||||
}
|
||||
FLASH_Lock();
|
||||
JumpToApp = 1;
|
||||
}
|
||||
} else {
|
||||
if (Data == 0x5AFE) {
|
||||
/* Force board into safe mode */
|
||||
PIOS_IAP_WriteBootCount(0xFFFF);
|
||||
}
|
||||
FLASH_Lock();
|
||||
JumpToApp = 1;
|
||||
}
|
||||
|
@ -301,6 +301,10 @@ void processComand(uint8_t *xReceive_Buffer) {
|
||||
sendData(Buffer + 1, 63);
|
||||
break;
|
||||
case JumpFW:
|
||||
if (Data == 0x5AFE) {
|
||||
/* Force board into safe mode */
|
||||
PIOS_IAP_WriteBootCount(0xFFFF);
|
||||
}
|
||||
FLASH_Lock();
|
||||
JumpToApp = 1;
|
||||
break;
|
||||
|
@ -1,6 +1,6 @@
|
||||
BOARD_TYPE := 0x01
|
||||
BOARD_REVISION := 0x01
|
||||
BOOTLOADER_VERSION := 0x00
|
||||
BOOTLOADER_VERSION := 0x01
|
||||
HW_TYPE := 0x00
|
||||
|
||||
MCU := cortex-m3
|
||||
|
@ -1,6 +1,6 @@
|
||||
BOARD_TYPE := 0x03
|
||||
BOARD_REVISION := 0x01
|
||||
BOOTLOADER_VERSION := 0x00
|
||||
BOOTLOADER_VERSION := 0x01
|
||||
HW_TYPE := 0x01
|
||||
|
||||
MCU := cortex-m3
|
||||
|
Loading…
x
Reference in New Issue
Block a user