# parameters for the Stinger drone # flight modes FLTMODE1 5 FLTMODE4 2 FLTMODE_CH 6 # enable PID logging LOG_BITMASK 65535 # mag field varies quite a lot between batteries ARMING_MAGTHRESH 200 # IMU orientation # 4 = YAW 180 AHRS_ORIENTATION 4 # Forced external compass COMPASS_EXTERNAL 2 # compass orientation # 2 = YAW 90 COMPASS_ORIENT 8 # filtering INS_GYRO_FILTER 40 INS_HNTCH_ENABLE 1 INS_HNTCH_ATT 40.0 INS_HNTCH_BW 50.0 INS_HNTCH_FM_RAT 1.0 INS_HNTCH_FREQ 100.0 INS_HNTCH_HMNCS 7 INS_HNTCH_MODE 3 INS_HNTCH_OPTS 2 INS_HNTCH_REF 1.0 # run IMU at 2kHz INS_GYRO_RATE 1 # a bit more agressive loiter PILOT_SPEED_UP 500 LOIT_BRK_ACCEL 500 LOIT_BRK_JERK 1000 LOIT_BRK_DELAY 0.200000 # Tune parameters from Quik Tune ATC_ACCEL_Y_MAX 30000.0 ATC_ACCEL_R_MAX 125000.0 ATC_ACCEL_P_MAX 125000.0 ATC_RAT_PIT_D 0.002856164472177625 ATC_RAT_PIT_FLTD 40.0 ATC_RAT_PIT_FLTT 40.0 ATC_RAT_PIT_I 0.124929137527942657 ATC_RAT_PIT_P 0.124929137527942657 ATC_RAT_PIT_SMAX 50.0 ATC_RAT_RLL_D 0.001519999350421131 ATC_RAT_RLL_FLTD 40.0 ATC_RAT_RLL_FLTT 40.0 ATC_RAT_RLL_I 0.075611755251884460 ATC_RAT_RLL_P 0.075611755251884460 ATC_RAT_RLL_SMAX 50.0 ATC_RAT_YAW_D 0.010000008158385754 ATC_RAT_YAW_FLTD 40.0 ATC_RAT_YAW_FLTE 2.0 ATC_RAT_YAW_FLTT 40.0 ATC_RAT_YAW_I 0.050000030547380447 ATC_RAT_YAW_P 0.500000298023223877 ATC_RAT_YAW_SMAX 50.0 # battery setup BATT_LOW_VOLT 14.2 BATT_OPTIONS 64 BATT_VOLT_PIN 1 BATT_CURR_PIN 2 BATT_VOLT_MULT 1 BATT_AMP_PERVLT 1 BATT_AMP_OFFSET 0.0 # 4S battery range MOT_BAT_VOLT_MAX 16.800000 MOT_BAT_VOLT_MIN 13.200000 # Learned hover thrust MOT_THST_EXPO 0.550000011920928955 MOT_THST_HOVER 0.130549192428588867 # quad-X FRAME_CLASS 1 # tweak R/C inputs RC1_MIN 1000 RC1_MAX 2000 RC1_DZ 40 RC2_MIN 1000 RC2_MAX 2000 RC2_REVERSED 1 RC3_MIN 1000 RC3_MAX 2000 RC4_MIN 1000 RC4_MAX 2000 RC4_DZ 40 # add arming on right switch RC7_OPTION 153 # Motor mappings SERVO1_FUNCTION 33 SERVO2_FUNCTION 36 SERVO3_FUNCTION 34 SERVO4_FUNCTION 35