mirror of
https://github.com/PX4/PX4-Autopilot.git
synced 2026-11-25 08:40:30 +08:00
fix(commander): allow reboot in termination state
This commit is contained in:
1 parent
29decda537
commit
2a4ce5dd86
2 files changed
+2
-1
No files matched your search
@@ -1400,7 +1400,7 @@ Commander::handle_command(const vehicle_command_s &cmd)
|
||||
|
||||
#if defined(CONFIG_BOARDCTL_RESET)
|
||||
|
||||
} else if ((param1 == 1) && !isArmed() && (px4_reboot_request(REBOOT_REQUEST, 400_ms) == 0)) {
|
||||
} else if ((param1 == 1) && (!isArmed() || isTerminated()) && (px4_reboot_request(REBOOT_REQUEST, 400_ms) == 0)) {
|
||||
// 1: Reboot autopilot
|
||||
answer_command(cmd, vehicle_command_ack_s::VEHICLE_CMD_RESULT_ACCEPTED);
|
||||
|
||||
|
||||
Reference in new issue
Block a user