mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-07-16 04:50:36 +08:00
commander: prevent setting nav_state to takeoff after disarming (#25735)
* commander: prevent setting nav_state after disarming to takeoff * wrap in function
This commit is contained in:
@@ -91,6 +91,7 @@ public:
|
||||
|
||||
private:
|
||||
bool isArmed() const { return _vehicle_status.arming_state == vehicle_status_s::ARMING_STATE_ARMED; }
|
||||
bool isTakeOffIntended(uint8_t user_intented_nav_state) const {return user_intented_nav_state == vehicle_status_s::NAVIGATION_STATE_AUTO_TAKEOFF || user_intented_nav_state == vehicle_status_s::NAVIGATION_STATE_AUTO_VTOL_TAKEOFF;}
|
||||
|
||||
const vehicle_status_s &_vehicle_status;
|
||||
const HealthAndArmingChecks &_health_and_arming_checks;
|
||||
|
||||
Reference in New Issue
Block a user