mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-01-20 15:48:29 -04:00
Plane: Remove unutilized case
This commit is contained in:
parent
30fd915312
commit
0b01bb531d
@ -295,15 +295,6 @@ void Plane::crash_detection_update(void)
|
|||||||
|
|
||||||
} else if ((now_ms - crash_state.debounce_timer_ms >= crash_state.debounce_time_total_ms) && !crash_state.is_crashed) {
|
} else if ((now_ms - crash_state.debounce_timer_ms >= crash_state.debounce_time_total_ms) && !crash_state.is_crashed) {
|
||||||
crash_state.is_crashed = true;
|
crash_state.is_crashed = true;
|
||||||
|
|
||||||
if (aparm.crash_detection_enable == CRASH_DETECT_ACTION_BITMASK_DISABLED) {
|
|
||||||
if (crashed_near_land_waypoint) {
|
|
||||||
gcs().send_text(MAV_SEVERITY_CRITICAL, "Hard landing detected. No action taken");
|
|
||||||
} else {
|
|
||||||
gcs().send_text(MAV_SEVERITY_EMERGENCY, "Crash detected. No action taken");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else {
|
|
||||||
if (aparm.crash_detection_enable & CRASH_DETECT_ACTION_BITMASK_DISARM) {
|
if (aparm.crash_detection_enable & CRASH_DETECT_ACTION_BITMASK_DISARM) {
|
||||||
arming.disarm(AP_Arming::Method::CRASH);
|
arming.disarm(AP_Arming::Method::CRASH);
|
||||||
}
|
}
|
||||||
@ -313,7 +304,6 @@ void Plane::crash_detection_update(void)
|
|||||||
gcs().send_text(MAV_SEVERITY_EMERGENCY, "Crash detected");
|
gcs().send_text(MAV_SEVERITY_EMERGENCY, "Crash detected");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
Loading…
Reference in New Issue
Block a user