control allocation: introduce parameter SYS_CTRL_ALLOC & unify build targets

This commit is contained in:
Beat Küng
2021-09-10 16:06:05 +02:00
committed by Daniel Agar
parent 0c5a79d84d
commit a51c465b54
13 changed files with 56 additions and 42 deletions
@@ -8,7 +8,8 @@
#
. ${R}etc/init.d/rc.mc_defaults
. ${R}etc/init.d/rc.ctrlalloc
param set-default SYS_CTRL_ALLOC 1
param set-default MPC_USE_HTE 0
@@ -6,7 +6,8 @@
#
. ${R}etc/init.d/rc.mc_defaults
. ${R}etc/init.d/rc.ctrlalloc
param set-default SYS_CTRL_ALLOC 1
param set-default MC_PITCHRATE_P 0.0800
param set-default MC_PITCHRATE_I 0.0400
@@ -55,5 +55,4 @@ px4_add_romfs_files(
rc.vehicle_setup
rc.vtol_apps
rc.vtol_defaults
rc.ctrlalloc
)
@@ -11,10 +11,11 @@
#
. ${R}etc/init.d/rc.mc_defaults
. ${R}etc/init.d/rc.ctrlalloc
set MIXER none
param set-default SYS_CTRL_ALLOC 1
param set-default MPC_USE_HTE 0
param set-default VM_MASS 1.5
@@ -11,8 +11,8 @@
#
. ${R}etc/init.d/rc.mc_defaults
. ${R}etc/init.d/rc.ctrlalloc
param set-default SYS_CTRL_ALLOC 1
param set-default MPC_USE_HTE 0
param set-default VM_MASS 1.5
-26
View File
@@ -1,26 +0,0 @@
#!/bin/sh
#
# Standard apps for new control allocation and controllers
#
# NOTE: Script variables are declared/initialized/unset in the rcS script.
#
#
# Start angular velocity controller
#
# angular_velocity_controller start
# mc_rate_control stop
#
# Start Control Allocator
#
control_allocator start
#
# Disable hover thrust estimator and prearming
# These features are currently incompatible with control allocation
#
# TODO: fix
#
param set MPC_USE_HTE 0
param set COM_PREARM_MODE 0
+17
View File
@@ -48,6 +48,23 @@ fi
# End Estimator Group Selection #
###############################################################################
if param compare SYS_CTRL_ALLOC 1
then
#
# Start Control Allocator
#
control_allocator start
#
# Disable hover thrust estimator and prearming
# These features are currently incompatible with control allocation
#
# TODO: fix
#
param set MPC_USE_HTE 0
param set COM_PREARM_MODE 0
fi
#
# Start Multicopter Rate Controller.
#