From 2f1406c952fa1f27ba2cba3d8db8b560241064f0 Mon Sep 17 00:00:00 2001 From: Mehmet Killioglu Date: Mon, 8 Apr 2024 15:24:22 +0200 Subject: [PATCH] add skywalker airframe --- .../init.d/airframes/4421_ssrc_skywalker | 81 +++++++++++++++++++ .../init.d/airframes/CMakeLists.txt | 1 + 2 files changed, 82 insertions(+) create mode 100644 ROMFS/px4fmu_common/init.d/airframes/4421_ssrc_skywalker diff --git a/ROMFS/px4fmu_common/init.d/airframes/4421_ssrc_skywalker b/ROMFS/px4fmu_common/init.d/airframes/4421_ssrc_skywalker new file mode 100644 index 000000000000..479f0539000c --- /dev/null +++ b/ROMFS/px4fmu_common/init.d/airframes/4421_ssrc_skywalker @@ -0,0 +1,81 @@ +#!/bin/sh +# +# @name Skywalker X5 +# +# @type Flying Wing +# @class Plane +# +# @board px4_fmu-v2 exclude +# @board bitcraze_crazyflie exclude +# + +. /etc/init.d/rc.fw_defaults + +# Control allocator parameters +param set-default CA_AIRFRAME 1 +param set-default CA_ROTOR_COUNT 1 + +# PWM +param set-default PWM_MAIN_FUNC1 201 +param set-default PWM_MAIN_FUNC2 202 +param set-default PWM_MAIN_FUNC3 101 + +# Airspeed parameters +ms4525do start -X -f 500 +param set-default SENS_EN_MS4525DO 1 +param set-default ASPD_DO_CHECKS 15 +param set-default FW_AIRSPD_MAX 25.0 +param set-default FW_AIRSPD_MIN 13.0 +param set-default FW_AIRSPD_STALL 10.0 +param set-default FW_AIRSPD_TRIM 18.0 + +# Mission parameters +param set-default MIS_TAKEOFF_ALT 25.0 +param set-default MIS_TKO_LAND_REQ 4 +param set-default NAV_LOITER_RAD 40.0 + +# Battery parameters +param set-default BAT1_N_CELLS 6 +param set-default BAT1_V_EMPTY 3.7000 + +# Disable internal magnetometer +param set-default CAL_MAG0_PRIO 1 +param set-default CAL_MAG0_ROT 0 +param set-default CAL_MAG1_PRIO 100 +param set-default CAL_MAG1_ROT 0 + +param set-default SENS_MAG_MODE 0 + +# Launch detection +param set-default FW_LAUN_AC_T 0.0 +param set-default FW_LAUN_AC_THLD 0.0 +param set-default FW_LAUN_DETCN_ON 1 + +# Launch detection +param set-default FW_LND_ANG 15.0 +param set-default FW_LND_ABORT 0 + +# Maximum manual roll angle +param set-default FW_MAN_R_MAX 60.0 + +# Misc +param set-default RTL_RETURN_ALT 100.0 + +# Failsafe +param set-default NAV_RCL_ACT 1 +param set-default NAV_DLL_ACT 0 +param set-default RC_MAP_KILL_SW 5 + +# Flight mode +param set-default RC_MAP_FLTMODE 6 +param set-default COM_FLTMODE1 0 +param set-default COM_FLTMODE4 1 +param set-default COM_FLTMODE6 2 + +# Geometry +param set-default FW_WING_HEIGHT 0.2 +param set-default FW_WING_SPAN 2.1 + +param set-default SYS_AUTOCONFIG 1 + +set MIXER fw_generic_wing diff --git a/ROMFS/px4fmu_common/init.d/airframes/CMakeLists.txt b/ROMFS/px4fmu_common/init.d/airframes/CMakeLists.txt index 11425887ba24..c93aef7ed84d 100644 --- a/ROMFS/px4fmu_common/init.d/airframes/CMakeLists.txt +++ b/ROMFS/px4fmu_common/init.d/airframes/CMakeLists.txt @@ -69,6 +69,7 @@ px4_add_romfs_files( 4400_ssrc_fog_x 4401_ssrc_fog_x_tmotor 4420_ssrc_arwing + 4421_ssrc_skywalker 4430_ssrc_strivermini 4500_clover4 4900_crazyflie