diff --git a/ROMFS/px4fmu_common/init.d/airframes/17002_TF-AutoG2 b/ROMFS/px4fmu_common/init.d/airframes/17002_TF-AutoG2 new file mode 100644 index 0000000000..f795ecb0f0 --- /dev/null +++ b/ROMFS/px4fmu_common/init.d/airframes/17002_TF-AutoG2 @@ -0,0 +1,50 @@ +#!/bin/sh +# +# @name ThunderFly Auto-G2 +# +# @type Autogyro +# @class Autogyro +# +# @output MAIN1 rotor_head_L +# @output MAIN2 rotor_head_R +# @output MAIN3 elevator +# @output MAIN4 rudder +# @output MAIN5 rudder (second, optional) +# @output MAIN6 throttle +# @output MAIN7 wheel +# +# @output AUX1 feed-through of RC AUX1 channel for prerotator (optional) +# @output AUX2 feed-through of RC AUX2 channel for release device (optional) +# +# @url https://github.com/ThunderFly-aerospace/Auto-G2/ +# @maintainer ThunderFly s.r.o., Roman Dvorak +# + +sh /etc/init.d/rc.fw_defaults + +if [ $AUTOCNF = yes ] +then + param set BAT_CAPACITY 2500.0 + param set BAT_N_CELLS 3 + + param set PWM_AUX_RATE 50 + param set PWM_RATE 50 + + param set SENS_BOARD_ROT 8 + + param set FW_AIRSPD_MAX 20 + param set FW_AIRSPD_MIN 7 + param set FW_AIRSPD_TRIM 13 + param set FW_THR_CRUISE 0.8 + + param set FW_MAN_P_MAX 25.0 + param set FW_MAN_R_MAX 25.0 + param set FW_PR_I 0.02 + param set FW_R_LIM 40 + param set FW_P_LIM_MAX 25.0 + param set FW_P_LIM_MIN -5.0 + param set FW_P_RMAX_NEG 20.0 +fi + +set MIXER TF-AutoG2 +set MIXER_AUX pass diff --git a/ROMFS/px4fmu_common/mixers/CMakeLists.txt b/ROMFS/px4fmu_common/mixers/CMakeLists.txt index 647959b974..7fb5990970 100644 --- a/ROMFS/px4fmu_common/mixers/CMakeLists.txt +++ b/ROMFS/px4fmu_common/mixers/CMakeLists.txt @@ -84,4 +84,5 @@ px4_add_romfs_files( vtol_delta.aux.mix wingwing.main.mix zmr250.main.mix + TF-AutoG2.main.mix ) diff --git a/ROMFS/px4fmu_common/mixers/TF-AutoG2.main.mix b/ROMFS/px4fmu_common/mixers/TF-AutoG2.main.mix new file mode 100644 index 0000000000..bed0fedee2 --- /dev/null +++ b/ROMFS/px4fmu_common/mixers/TF-AutoG2.main.mix @@ -0,0 +1,55 @@ +Aileron/rudder/elevator/throttle mixer for PX4FMU +================================================== + +Inputs to the mixer come from channel group 0 (vehicle attitude), channels 0 +(roll), 1 (pitch) and 3 (thrust). + +CH1, 2: rotor-head mixer +------------- +Two scalers total (output, roll). + +M: 2 +O: 10000 10000 0 -10000 10000 +S: 0 0 -10000 -10000 0 -10000 10000 +S: 0 1 10000 10000 0 -10000 10000 + + +M: 2 +O: 10000 10000 0 -10000 10000 +S: 0 0 -10000 -10000 0 -10000 10000 +S: 0 1 -10000 -10000 0 -10000 10000 + + +CH3: Elevator, prerotator mixer +------------ +Two scalers total (output, roll). + +M: 1 +O: 7500 7500 0 -10000 10000 +S: 3 6 10000 10000 0 -10000 10000 + + +CH4, 5: Rudder mixer +------------ +Two scalers total (output, yaw). + +M: 1 +S: 0 2 10000 10000 0 -10000 10000 + +M: 1 +S: 0 2 -10000 -10000 0 -10000 10000 + +CH4: Motor speed mixer +----------------- +Two scalers total (output, thrust). + +M: 1 +S: 0 3 0 20000 -10000 -10000 10000 + + +CH3: Wheel mixer +------------ +Two scalers total (output, yaw). + +M: 1 +S: 0 2 10000 10000 0 -10000 10000 diff --git a/Tools/px4airframes/rcout.py b/Tools/px4airframes/rcout.py index 3ece11c1e5..18e8170ab3 100644 --- a/Tools/px4airframes/rcout.py +++ b/Tools/px4airframes/rcout.py @@ -28,6 +28,7 @@ class RCOutput(): "# 12000 .. 12999 Octo Cox\n" "# 13000 .. 13999 VTOL\n" "# 14000 .. 14999 Tri Y\n" + "# 17000 .. 17999 Autogyro\n" "\n") result += "\n" result += "set AIRFRAME none\n" diff --git a/Tools/px4airframes/srcparser.py b/Tools/px4airframes/srcparser.py index 0ecc9f7ecc..b10f9b6ba7 100644 --- a/Tools/px4airframes/srcparser.py +++ b/Tools/px4airframes/srcparser.py @@ -88,6 +88,8 @@ class ParameterGroup(object): return "YMinus" elif (self.name == "Tricopter Y+"): return "YPlus" + elif (self.name == "Autogyro"): + return "Autogyro" elif (self.name == "Rover"): return "Rover" elif (self.name == "Boat"):