mirror of
https://github.com/PX4/PX4-Autopilot.git
synced 2026-05-30 12:50:37 +08:00
vehicles: add new vehicle type: Airship (#14862)
Co-authored-by: Anton Erasmus <anton@flycloudline.com> Co-authored-by: Beat Küng <beat-kueng@gmx.net>
This commit is contained in:
committed by
GitHub
parent
454433c2ef
commit
fa4818e467
@@ -0,0 +1,59 @@
|
||||
#!/bin/sh
|
||||
#
|
||||
# Standard apps for airships. Attitude/Position estimator, Attitude/Position control.
|
||||
#
|
||||
# NOTE: Script variables are declared/initialized/unset in the rcS script.
|
||||
#
|
||||
|
||||
###############################################################################
|
||||
# Begin Estimator Group Selection #
|
||||
###############################################################################
|
||||
|
||||
#
|
||||
# LPE
|
||||
#
|
||||
if param compare SYS_MC_EST_GROUP 1
|
||||
then
|
||||
#
|
||||
# Try to start LPE. If it fails, start EKF2 as a default.
|
||||
# Unfortunately we do not build it on px4_fmu-v2 due to a limited flash.
|
||||
#
|
||||
if attitude_estimator_q start
|
||||
then
|
||||
echo "WARN [init] Estimator LPE unsupported, EKF2 recommended."
|
||||
local_position_estimator start
|
||||
else
|
||||
echo "ERROR [init] Estimator LPE not available. Using EKF2"
|
||||
param set SYS_MC_EST_GROUP 2
|
||||
param save
|
||||
reboot
|
||||
fi
|
||||
else
|
||||
#
|
||||
# Q estimator (attitude estimation only)
|
||||
#
|
||||
if param compare SYS_MC_EST_GROUP 3
|
||||
then
|
||||
attitude_estimator_q start
|
||||
else
|
||||
#
|
||||
# EKF2
|
||||
#
|
||||
param set SYS_MC_EST_GROUP 2
|
||||
ekf2 start
|
||||
fi
|
||||
fi
|
||||
|
||||
###############################################################################
|
||||
# End Estimator Group Selection #
|
||||
###############################################################################
|
||||
|
||||
#
|
||||
# Start Airship Attitude Controller.
|
||||
#
|
||||
airship_att_control start
|
||||
|
||||
#
|
||||
# Start Land Detector.
|
||||
#
|
||||
land_detector start airship
|
||||
Reference in New Issue
Block a user