diff --git a/Makefile b/Makefile index 328d4733802..e87790c93fd 100644 --- a/Makefile +++ b/Makefile @@ -210,7 +210,7 @@ define cmake-build || (rm -rf $(BUILD_DIR)); \ fi @# run the build for the specified target - @cmake --build $(BUILD_DIR) -- $(PX4_MAKE_ARGS) $(ARGS) + +@cmake --build $(BUILD_DIR) -- $(PX4_MAKE_ARGS) $(ARGS) endef # check if the options we want to build with in CMAKE_ARGS match the ones which are already configured in the cache inside BUILD_DIR @@ -440,10 +440,12 @@ px4_metadata: parameters_metadata airframe_metadata module_documentation extract check_format: $(call colorecho,'Checking formatting with astyle') @"$(SRC_DIR)"/Tools/astyle/check_code_style_all.sh + @"$(SRC_DIR)"/Tools/astyle/check_param_names.py @cd "$(SRC_DIR)" && git diff --check format: $(call colorecho,'Formatting with astyle') + @"$(SRC_DIR)"/Tools/astyle/check_param_names.py --fix @"$(SRC_DIR)"/Tools/astyle/check_code_style_all.sh --fix format_changed: diff --git a/ROMFS/CMakeLists.txt b/ROMFS/CMakeLists.txt index b6bb151c341..5401d548b49 100644 --- a/ROMFS/CMakeLists.txt +++ b/ROMFS/CMakeLists.txt @@ -125,6 +125,7 @@ add_custom_command( ${romfs_copy_files} ${jinja_templates} ${module_config_files} + ${PX4_BINARY_DIR}/px4_boardconfig.h ${romfs_cmake_files} ${PX4_SOURCE_DIR}/Tools/px_process_airframes.py ${PX4_SOURCE_DIR}/Tools/px4airframes/markdownout.py @@ -133,6 +134,7 @@ add_custom_command( ${PX4_SOURCE_DIR}/Tools/px4airframes/srcscanner.py ${PX4_SOURCE_DIR}/Tools/px4airframes/xmlout.py ${PX4_SOURCE_DIR}/Tools/serial/generate_config.py + ${PX4_SOURCE_DIR}/Tools/module_config/output_groups_from_timer_config.py ) @@ -153,7 +155,8 @@ add_custom_command( COMMAND ${PYTHON_EXECUTABLE} ${PX4_SOURCE_DIR}/Tools/serial/generate_config.py --rc-dir ${romfs_gen_root_dir}/init.d --serial-ports ${board_serial_ports} ${added_arguments} - --config-files ${module_config_files} #--verbose + --config-files ${module_config_files} + --board-config ${BOARD_CONFIG} #--verbose COMMAND ${PYTHON_EXECUTABLE} ${PX4_SOURCE_DIR}/Tools/filepaths/generate_config.py --rc-dir ${romfs_gen_root_dir}/init.d --params-file ${CONFIG_BOARD_PARAM_FILE} diff --git a/ROMFS/cannode/init.d/rcS b/ROMFS/cannode/init.d/rcS index a9fec3c28a1..c6b462c38eb 100644 --- a/ROMFS/cannode/init.d/rcS +++ b/ROMFS/cannode/init.d/rcS @@ -95,17 +95,6 @@ then gyro_calibration start fi - -if param compare -s MBE_ENABLE 1 -then - # conservative mag bias estimation - param set-default MBE_LEARN_GAIN 5 - param set-default IMU_GYRO_CUTOFF 20 - # nodes have no GCS calibration flow, persist the estimated bias - param set-default SENS_MAG_AUTOCAL 1 - mag_bias_estimator start -fi - param set-default SENS_MAG_RATE 100 sensors start diff --git a/ROMFS/px4fmu_common/init.d-posix/airframes/10019_gazebo-classic_omnicopter b/ROMFS/px4fmu_common/init.d-posix/airframes/10019_gazebo-classic_omnicopter index 765d3c9b0c8..481017612c1 100644 --- a/ROMFS/px4fmu_common/init.d-posix/airframes/10019_gazebo-classic_omnicopter +++ b/ROMFS/px4fmu_common/init.d-posix/airframes/10019_gazebo-classic_omnicopter @@ -90,7 +90,3 @@ param set-default PWM_MAIN_FUNC8 108 # disable MC desaturation which improves attitude tracking param set-default CA_METHOD 0 - -# disable attitude failure detection -param set-default FD_FAIL_P 0 -param set-default FD_FAIL_R 0 diff --git a/ROMFS/px4fmu_common/init.d-posix/airframes/10048_sihsim_rover_differential b/ROMFS/px4fmu_common/init.d-posix/airframes/10048_sihsim_rover_differential new file mode 100644 index 00000000000..da1b4126ca1 --- /dev/null +++ b/ROMFS/px4fmu_common/init.d-posix/airframes/10048_sihsim_rover_differential @@ -0,0 +1,56 @@ +#!/bin/sh +# @name Rover Differential +# @type Rover +# @class Rover + +. ${R}etc/init.d/rc.rover_differential_defaults + +PX4_SIMULATOR=${PX4_SIMULATOR:=sihsim} +PX4_SIM_MODEL=${PX4_SIM_MODEL:=rover_differential} + +param set-default SIH_VEHICLE_TYPE 6 # sih as rover differential + +param set-default PWM_MAIN_FUNC1 101 # Right wheel +param set-default PWM_MAIN_FUNC2 102 # Left wheel +param set-default SIH_MASS 20 +param set-default SIH_IXX 0.75 +param set-default SIH_IYY 1.2167 +param set-default SIH_IZZ 1.6667 +param set-default SIH_IXZ 0 +param set-default SIH_KDW 1 + +param set-default SENS_EN_GPSSIM 1 +param set-default SENS_EN_BAROSIM 1 +param set-default SENS_EN_MAGSIM 1 + +# Differential Parameters +param set-default RD_WHEEL_TRACK 0.6 +param set-default RD_TRANS_DRV_TRN 0.785398 +param set-default RD_TRANS_TRN_DRV 0.174533 +param set-default RD_YAW_STK_GAIN 0.6 + +# Rate Control Parameters +param set-default RO_YAW_RATE_I 0.01 +param set-default RO_YAW_RATE_P 0.25 +param set-default RO_YAW_RATE_LIM 180 +param set-default RO_YAW_ACCEL_LIM 400 +param set-default RO_YAW_DECEL_LIM 800 +param set-default RO_YAW_RATE_CORR 1 + +# Attitude Control Parameters +param set-default RO_YAW_P 5 + +# Velocity Control Parameters +param set-default RO_ACCEL_LIM 3 +param set-default RO_DECEL_LIM 4 +param set-default RO_JERK_LIM 10 +param set-default RO_MAX_THR_SPEED 2 +param set-default RO_SPEED_LIM 1.8 +param set-default RO_SPEED_I 0.01 +param set-default RO_SPEED_P 0.01 +param set-default RO_SPEED_RED 1 + +# Pure Pursuit parameters +param set-default PP_LOOKAHD_GAIN 1 +param set-default PP_LOOKAHD_MAX 10 +param set-default PP_LOOKAHD_MIN 1 diff --git a/ROMFS/px4fmu_common/init.d-posix/airframes/1010_gazebo-classic_iris_opt_flow b/ROMFS/px4fmu_common/init.d-posix/airframes/1010_gazebo-classic_iris_opt_flow index d334bdb4308..98d07ea9d36 100644 --- a/ROMFS/px4fmu_common/init.d-posix/airframes/1010_gazebo-classic_iris_opt_flow +++ b/ROMFS/px4fmu_common/init.d-posix/airframes/1010_gazebo-classic_iris_opt_flow @@ -34,7 +34,7 @@ param set-default EKF2_GPS_CTRL 0 param set-default EKF2_HGT_REF 0 param set-default EKF2_EVP_NOISE 0.05 param set-default EKF2_EVA_NOISE 0.05 -param set-default EKF2_OF_CTRL 1 +param set-default EKF2_OF0_CTRL 1 # LPE: Flow-only mode param set-default LPE_FUSION 242 @@ -45,7 +45,7 @@ param set-default LPE_FAKE_ORIGIN 1 param set-default MPC_ALT_MODE 2 -param set-default SENS_FLOW_ROT 6 -param set-default SENS_FLOW_MINHGT 0.7 -param set-default SENS_FLOW_MAXHGT 15 -param set-default SENS_FLOW_MAXR 2.5 +param set-default SENS_FLOW0_ROT 6 +param set-default SENS_FLOW0_HMIN 0.7 +param set-default SENS_FLOW0_HMAX 15 +param set-default SENS_FLOW0_MAXR 2.5 diff --git a/ROMFS/px4fmu_common/init.d-posix/airframes/1017_gazebo-classic_iris_opt_flow_mockup b/ROMFS/px4fmu_common/init.d-posix/airframes/1017_gazebo-classic_iris_opt_flow_mockup index 23928c0a9b2..bca7a1555e6 100644 --- a/ROMFS/px4fmu_common/init.d-posix/airframes/1017_gazebo-classic_iris_opt_flow_mockup +++ b/ROMFS/px4fmu_common/init.d-posix/airframes/1017_gazebo-classic_iris_opt_flow_mockup @@ -31,7 +31,7 @@ param set-default PWM_MAIN_FUNC4 104 # EKF2 param set-default EKF2_GPS_CTRL 0 -param set-default EKF2_OF_CTRL 1 +param set-default EKF2_OF0_CTRL 1 # LPE: Flow-only mode param set-default LPE_FUSION 242 diff --git a/ROMFS/px4fmu_common/init.d-posix/airframes/1045_gazebo-classic_quadtailsitter b/ROMFS/px4fmu_common/init.d-posix/airframes/1045_gazebo-classic_quadtailsitter index 9539ba6d740..d9ca6396e96 100644 --- a/ROMFS/px4fmu_common/init.d-posix/airframes/1045_gazebo-classic_quadtailsitter +++ b/ROMFS/px4fmu_common/init.d-posix/airframes/1045_gazebo-classic_quadtailsitter @@ -33,8 +33,6 @@ param set-default PWM_MAIN_FUNC3 103 param set-default PWM_MAIN_FUNC4 104 param set-default PWM_MAIN_FUNC5 0 -param set-default FD_FAIL_R 70 - param set-default FW_P_TC 0.6 param set-default FW_PR_I 0.3 diff --git a/ROMFS/px4fmu_common/init.d-posix/airframes/4006_gz_px4vision b/ROMFS/px4fmu_common/init.d-posix/airframes/4006_gz_px4vision index 20a9278463b..a80974cc2a7 100644 --- a/ROMFS/px4fmu_common/init.d-posix/airframes/4006_gz_px4vision +++ b/ROMFS/px4fmu_common/init.d-posix/airframes/4006_gz_px4vision @@ -23,10 +23,10 @@ param set-default EKF2_IMU_POS_X 0.02 param set-default SENS_GNSS0_OFFX 0.055 param set-default SENS_GNSS0_OFFZ -0.15 param set-default EKF2_MIN_RNG 0.03 -param set-default EKF2_OF_CTRL 1 -param set-default EKF2_OF_POS_X 0.055 -param set-default EKF2_OF_POS_Y 0.02 -param set-default EKF2_OF_POS_Z 0.065 +param set-default EKF2_OF0_CTRL 1 +param set-default SENS_FLOW0_POS_X 0.055 +param set-default SENS_FLOW0_POS_Y 0.02 +param set-default SENS_FLOW0_POS_Z 0.065 param set-default GNSS_REQ_HDRIFT 0.3 param set-default GNSS_REQ_SACC 1 param set-default GNSS_REQ_VDRIFT 0.3 @@ -84,8 +84,8 @@ param set-default SDLOG_PROFILE 131 # Sensors Parameters # param set-default SENS_CM8JL65_CFG 202 Not found -param set-default SENS_FLOW_MAXHGT 25 -param set-default SENS_FLOW_MINHGT 0.5 +param set-default SENS_FLOW0_HMAX 25 +param set-default SENS_FLOW0_HMIN 0.5 param set-default IMU_GYRO_CUTOFF 100 # param set-default SENS_TFLOW_CFG 103 Not found diff --git a/ROMFS/px4fmu_common/init.d-posix/airframes/4018_gz_quadtailsitter b/ROMFS/px4fmu_common/init.d-posix/airframes/4018_gz_quadtailsitter index bced062c1eb..bd6d5db9c55 100644 --- a/ROMFS/px4fmu_common/init.d-posix/airframes/4018_gz_quadtailsitter +++ b/ROMFS/px4fmu_common/init.d-posix/airframes/4018_gz_quadtailsitter @@ -48,8 +48,6 @@ param set-default SIM_GZ_EC_MAX2 1500 param set-default SIM_GZ_EC_MAX3 1500 param set-default SIM_GZ_EC_MAX4 1500 -param set-default FD_FAIL_R 70 - param set-default FW_P_TC 0.6 param set-default FW_PR_I 0.3 diff --git a/ROMFS/px4fmu_common/init.d-posix/airframes/5021_xplane_qtailsitter b/ROMFS/px4fmu_common/init.d-posix/airframes/5021_xplane_qtailsitter index ae9092a8979..690136a2600 100644 --- a/ROMFS/px4fmu_common/init.d-posix/airframes/5021_xplane_qtailsitter +++ b/ROMFS/px4fmu_common/init.d-posix/airframes/5021_xplane_qtailsitter @@ -298,10 +298,8 @@ param set-default RTL_RETURN_ALT 180 param set-default RTL_DESCEND_ALT 150 param set-default RTL_MIN_DIST 50 -param set-default FD_FAIL_R 85 -param set-default FD_FAIL_P 85 -param set-default FD_FAIL_R_TTRI 1.0 -param set-default FD_FAIL_P_TTRI 1.0 +param set-default FD_TILT_ERROR 85 +param set-default FD_TILT_ERROR_T 1 param set-default WV_EN 0 ################################################################################ diff --git a/ROMFS/px4fmu_common/init.d-posix/airframes/60002_gz_uuv_bluerov2_heavy b/ROMFS/px4fmu_common/init.d-posix/airframes/60002_gz_uuv_bluerov2_heavy index 3946b89e0d6..0eb7a7aa9f1 100644 --- a/ROMFS/px4fmu_common/init.d-posix/airframes/60002_gz_uuv_bluerov2_heavy +++ b/ROMFS/px4fmu_common/init.d-posix/airframes/60002_gz_uuv_bluerov2_heavy @@ -35,8 +35,7 @@ param set-default GF_ACTION 1 param set-default NAV_RCL_ACT 1 # disable attitude failure detection -param set-default FD_FAIL_P 0 -param set-default FD_FAIL_R 0 +param set-default FD_TILT_ERROR -1 param set-default CA_ROTOR_COUNT 8 param set-default CA_R_REV 255 diff --git a/ROMFS/px4fmu_common/init.d-posix/airframes/70000_gz_atmos b/ROMFS/px4fmu_common/init.d-posix/airframes/70000_gz_atmos index c843ac2e99f..bacdb6bef1d 100644 --- a/ROMFS/px4fmu_common/init.d-posix/airframes/70000_gz_atmos +++ b/ROMFS/px4fmu_common/init.d-posix/airframes/70000_gz_atmos @@ -30,8 +30,7 @@ param set-default SENS_EN_MAGSIM 0 param set-default COM_RC_IN_MODE 1 # disable attitude failure detection -param set-default FD_FAIL_P 0 -param set-default FD_FAIL_R 0 +param set-default FD_TILT_ERROR -1 # Disable magnetometer fusion in EKF2 param set-default EKF2_MAG_TYPE 5 diff --git a/ROMFS/px4fmu_common/init.d-posix/airframes/70001_gz_atmos_dual b/ROMFS/px4fmu_common/init.d-posix/airframes/70001_gz_atmos_dual index 406e0a4bb51..76a5bea9177 100644 --- a/ROMFS/px4fmu_common/init.d-posix/airframes/70001_gz_atmos_dual +++ b/ROMFS/px4fmu_common/init.d-posix/airframes/70001_gz_atmos_dual @@ -30,8 +30,7 @@ param set-default SENS_EN_MAGSIM 0 param set-default COM_RC_IN_MODE 1 # disable attitude failure detection -param set-default FD_FAIL_P 0 -param set-default FD_FAIL_R 0 +param set-default FD_TILT_ERROR -1 # Disable magnetometer fusion in EKF2 param set-default EKF2_MAG_TYPE 5 diff --git a/ROMFS/px4fmu_common/init.d-posix/airframes/8011_gz_omnicopter b/ROMFS/px4fmu_common/init.d-posix/airframes/8011_gz_omnicopter index be7a32431b0..a025995cec7 100644 --- a/ROMFS/px4fmu_common/init.d-posix/airframes/8011_gz_omnicopter +++ b/ROMFS/px4fmu_common/init.d-posix/airframes/8011_gz_omnicopter @@ -112,7 +112,3 @@ param set-default SIM_GZ_EC_MAX7 1100 param set-default SIM_GZ_EC_MAX8 1100 # disable MC desaturation which improves attitude tracking param set-default CA_METHOD 0 - -# disable attitude failure detection -param set-default FD_FAIL_P 0 -param set-default FD_FAIL_R 0 diff --git a/ROMFS/px4fmu_common/init.d-posix/airframes/CMakeLists.txt b/ROMFS/px4fmu_common/init.d-posix/airframes/CMakeLists.txt index 55ab76ebf5c..a4cae13670f 100644 --- a/ROMFS/px4fmu_common/init.d-posix/airframes/CMakeLists.txt +++ b/ROMFS/px4fmu_common/init.d-posix/airframes/CMakeLists.txt @@ -114,6 +114,7 @@ px4_add_romfs_files( 10045_sihsim_rover_ackermann 10046_sihsim_quadx_flow 10047_sihsim_standard_vtol_flow + 10048_sihsim_rover_differential 17001_flightgear_tf-g1 17002_flightgear_tf-g2 diff --git a/ROMFS/px4fmu_common/init.d/airframes/4016_holybro_px4vision b/ROMFS/px4fmu_common/init.d/airframes/4016_holybro_px4vision index bc1bb03b8d2..e3c707b2a71 100644 --- a/ROMFS/px4fmu_common/init.d/airframes/4016_holybro_px4vision +++ b/ROMFS/px4fmu_common/init.d/airframes/4016_holybro_px4vision @@ -22,10 +22,10 @@ param set-default EKF2_IMU_POS_X 0.02 param set-default SENS_GNSS0_OFFX 0.055 param set-default SENS_GNSS0_OFFZ -0.15 param set-default EKF2_MIN_RNG 0.03 -param set-default EKF2_OF_CTRL 1 -param set-default EKF2_OF_POS_X 0.055 -param set-default EKF2_OF_POS_Y 0.02 -param set-default EKF2_OF_POS_Z 0.065 +param set-default EKF2_OF0_CTRL 1 +param set-default SENS_FLOW0_POS_X 0.055 +param set-default SENS_FLOW0_POS_Y 0.02 +param set-default SENS_FLOW0_POS_Z 0.065 param set-default GNSS_REQ_HDRIFT 0.3 param set-default GNSS_REQ_SACC 1 param set-default GNSS_REQ_VDRIFT 0.3 @@ -79,8 +79,8 @@ param set-default RTL_RETURN_ALT 5 # Sensors Parameters param set-default SENS_CM8JL65_CFG 104 -param set-default SENS_FLOW_MAXHGT 25 -param set-default SENS_FLOW_MINHGT 0.5 +param set-default SENS_FLOW0_HMAX 25 +param set-default SENS_FLOW0_HMIN 0.5 param set-default IMU_GYRO_CUTOFF 100 param set-default SENS_EN_PMW3901 1 diff --git a/ROMFS/px4fmu_common/init.d/airframes/4020_holybro_px4vision_v1_5 b/ROMFS/px4fmu_common/init.d/airframes/4020_holybro_px4vision_v1_5 index 58440271e7b..f80774765b3 100644 --- a/ROMFS/px4fmu_common/init.d/airframes/4020_holybro_px4vision_v1_5 +++ b/ROMFS/px4fmu_common/init.d/airframes/4020_holybro_px4vision_v1_5 @@ -22,10 +22,10 @@ param set-default EKF2_IMU_POS_X 0.02 param set-default SENS_GNSS0_OFFX 0.055 param set-default SENS_GNSS0_OFFZ -0.15 param set-default EKF2_MIN_RNG 0.03 -param set-default EKF2_OF_CTRL 1 -param set-default EKF2_OF_POS_X 0.055 -param set-default EKF2_OF_POS_Y 0.02 -param set-default EKF2_OF_POS_Z 0.065 +param set-default EKF2_OF0_CTRL 1 +param set-default SENS_FLOW0_POS_X 0.055 +param set-default SENS_FLOW0_POS_Y 0.02 +param set-default SENS_FLOW0_POS_Z 0.065 param set-default GNSS_REQ_HDRIFT 0.3 param set-default GNSS_REQ_SACC 1 param set-default GNSS_REQ_VDRIFT 0.3 @@ -80,8 +80,8 @@ param set-default RTL_RETURN_ALT 5 # Sensors Parameters param set-default SENS_CM8JL65_CFG 202 -param set-default SENS_FLOW_MAXHGT 25 -param set-default SENS_FLOW_MINHGT 0.5 +param set-default SENS_FLOW0_HMAX 25 +param set-default SENS_FLOW0_HMIN 0.5 param set-default IMU_GYRO_CUTOFF 100 param set-default SENS_TFLOW_CFG 103 diff --git a/ROMFS/px4fmu_common/init.d/airframes/4061_atl_mantis_edu b/ROMFS/px4fmu_common/init.d/airframes/4061_atl_mantis_edu index f4b73b833bc..a8cdeff3830 100644 --- a/ROMFS/px4fmu_common/init.d/airframes/4061_atl_mantis_edu +++ b/ROMFS/px4fmu_common/init.d/airframes/4061_atl_mantis_edu @@ -58,13 +58,13 @@ param set-default EKF2_MAG_NOISE 0.1 param set-default EKF2_MIN_RNG 0.15 -param set-default EKF2_OF_DELAY 38 -param set-default EKF2_OF_GATE 2 -param set-default EKF2_OF_POS_X -0.035 -param set-default EKF2_OF_POS_Z 0.033 +param set-default SENS_FLOW0_DELAY 38 +param set-default EKF2_OF0_GATE 2 +param set-default SENS_FLOW0_POS_X -0.035 +param set-default SENS_FLOW0_POS_Z 0.033 param set-default EKF2_OF_MIN_RNG 0.01 param set-default EKF2_OF_A_HMAX 7 -param set-default EKF2_OF_QMIN 30 +param set-default EKF2_OF0_QMIN 30 param set-default EKF2_PCOEF_XN -0.3 param set-default EKF2_PCOEF_XP -0.4 @@ -147,9 +147,9 @@ param set-default RC_MAP_RETURN_SW 7 param set-default RC1_TRIM 1000 # optical flow -param set-default SENS_FLOW_MAXR 7.4 -param set-default SENS_FLOW_MINHGT 0.15 -param set-default SENS_FLOW_MAXHGT 5 +param set-default SENS_FLOW0_MAXR 7.4 +param set-default SENS_FLOW0_HMIN 0.15 +param set-default SENS_FLOW0_HMAX 5 # ignore the SD card errors and use normal startup sound set STARTUP_TUNE "1" diff --git a/ROMFS/px4fmu_common/init.d/airframes/4073_ifo-s b/ROMFS/px4fmu_common/init.d/airframes/4073_ifo-s index ecc7ed50789..41b4c6853a6 100644 --- a/ROMFS/px4fmu_common/init.d/airframes/4073_ifo-s +++ b/ROMFS/px4fmu_common/init.d/airframes/4073_ifo-s @@ -31,7 +31,7 @@ param set-default IMU_GYRO_CUTOFF 100 # Sensors param set-default SENS_BOARD_ROT 10 # Yaw 180 -param set-default SENS_FLOW_ROT 4 +param set-default SENS_FLOW0_ROT 4 # TFMini on TELEM3 param set-default SENS_TFMINI_CFG 103 @@ -43,8 +43,8 @@ param set-default EKF2_GND_EFF_DZ 6 param set-default EKF2_MIN_RNG 0.3 # Flow -param set-default EKF2_OF_CTRL 1 -param set-default EKF2_OF_QMIN 70 +param set-default EKF2_OF0_CTRL 1 +param set-default EKF2_OF0_QMIN 70 # Position control param set-default MPC_Z_P 1.1 @@ -86,9 +86,9 @@ param set-default MAV_1_MODE 0 param set-default SER_TEL2_BAUD 57600 # EKF OF POSITION -param set-default EKF2_OF_POS_X 0.06 -param set-default EKF2_OF_POS_Y 0.03 -param set-default EKF2_OF_POS_Z -0.07 +param set-default SENS_FLOW0_POS_X 0.06 +param set-default SENS_FLOW0_POS_Y 0.03 +param set-default SENS_FLOW0_POS_Z -0.07 # Failsafe param set-default COM_LOW_BAT_ACT 3 diff --git a/ROMFS/px4fmu_common/init.d/airframes/4601_droneblocks_dexi_5 b/ROMFS/px4fmu_common/init.d/airframes/4601_droneblocks_dexi_5 index 05452a1af1f..079d1810765 100644 --- a/ROMFS/px4fmu_common/init.d/airframes/4601_droneblocks_dexi_5 +++ b/ROMFS/px4fmu_common/init.d/airframes/4601_droneblocks_dexi_5 @@ -47,9 +47,9 @@ param set-default PWM_MAIN_TIM0 -3 param set-default DSHOT_TEL_CFG 104 param set-default EKF2_MIN_RNG 0.01 -param set-default EKF2_OF_POS_X 0.043 -param set-default EKF2_OF_POS_Y 0.011 -param set-default EKF2_OF_QMIN_GND 1 +param set-default SENS_FLOW0_POS_X 0.043 +param set-default SENS_FLOW0_POS_Y 0.011 +param set-default EKF2_OF0_QMINGND 1 param set-default EKF2_RNG_POS_X 0.043 param set-default EKF2_RNG_POS_Y 0 param set-default EKF2_RNG_A_HMAX 25 @@ -78,7 +78,7 @@ param set-default RC_CRSF_TEL_EN 1 param set-default RTL_RETURN_ALT 15 -param set-default SENS_FLOW_MINHGT 0 +param set-default SENS_FLOW0_HMIN 0 param set-default SER_TEL2_BAUD 3000000 diff --git a/ROMFS/px4fmu_common/init.d/airframes/4901_crazyflie21 b/ROMFS/px4fmu_common/init.d/airframes/4901_crazyflie21 index d3dc7578c07..9e9e7b842f5 100644 --- a/ROMFS/px4fmu_common/init.d/airframes/4901_crazyflie21 +++ b/ROMFS/px4fmu_common/init.d/airframes/4901_crazyflie21 @@ -20,7 +20,7 @@ . ${R}etc/init.d/rc.mc_defaults param set-default SYS_HAS_MAG 0 -param set-default EKF2_OF_CTRL 1 +param set-default EKF2_OF0_CTRL 1 param set-default EKF2_GPS_CTRL 0 param set-default EKF2_MAG_TYPE 5 diff --git a/ROMFS/px4fmu_common/init.d/airframes/60002_uuv_bluerov2_heavy b/ROMFS/px4fmu_common/init.d/airframes/60002_uuv_bluerov2_heavy index 646c86fb608..e56d62b989c 100644 --- a/ROMFS/px4fmu_common/init.d/airframes/60002_uuv_bluerov2_heavy +++ b/ROMFS/px4fmu_common/init.d/airframes/60002_uuv_bluerov2_heavy @@ -50,8 +50,7 @@ param set-default GF_ACTION 1 param set-default NAV_RCL_ACT 1 # disable attitude failure detection -param set-default FD_FAIL_P 0 -param set-default FD_FAIL_R 0 +param set-default FD_TILT_ERROR -1 param set-default CA_ROTOR_COUNT 8 param set-default CA_R_REV 255 diff --git a/ROMFS/px4fmu_common/init.d/airframes/6002_draco_r b/ROMFS/px4fmu_common/init.d/airframes/6002_draco_r index 99b2be3e697..1dde92e8abe 100644 --- a/ROMFS/px4fmu_common/init.d/airframes/6002_draco_r +++ b/ROMFS/px4fmu_common/init.d/airframes/6002_draco_r @@ -67,13 +67,13 @@ param set-default MIS_TAKEOFF_ALT 1.1 ##################################### # Enable optical flow and GPS param set-default EKF2_MAG_TYPE 1 -param set-default EKF2_OF_QMIN 80 +param set-default EKF2_OF0_QMIN 80 # default horizontal stablization sensors param set-default SENS_EN_PMW3901 1 param set-default SENS_EN_PX4FLOW 1 param set-default SENS_EN_LL40LS 2 -param set-default SENS_FLOW_ROT 2 +param set-default SENS_FLOW0_ROT 2 param set-default COM_DISARM_LAND 3 diff --git a/ROMFS/px4fmu_common/init.d/airframes/70000_atmos b/ROMFS/px4fmu_common/init.d/airframes/70000_atmos index a9f2b1df75d..d6218e23f19 100644 --- a/ROMFS/px4fmu_common/init.d/airframes/70000_atmos +++ b/ROMFS/px4fmu_common/init.d/airframes/70000_atmos @@ -25,8 +25,7 @@ param set-default UXRCE_DDS_AG_IP -1062731775 param set-default UXRCE_DDS_CFG 1000 # disable attitude failure detection -param set-default FD_FAIL_P 0 -param set-default FD_FAIL_R 0 +param set-default FD_TILT_ERROR -1 # Disable magnetometer fusion in EKF2 param set-default EKF2_MAG_TYPE 5 diff --git a/ROMFS/px4fmu_common/init.d/airframes/70001_atmos_dual b/ROMFS/px4fmu_common/init.d/airframes/70001_atmos_dual index 179708760e6..16be2c6fa1d 100644 --- a/ROMFS/px4fmu_common/init.d/airframes/70001_atmos_dual +++ b/ROMFS/px4fmu_common/init.d/airframes/70001_atmos_dual @@ -29,8 +29,7 @@ param set-default UXRCE_DDS_AG_IP -1062731775 param set-default UXRCE_DDS_CFG 1000 # disable attitude failure detection -param set-default FD_FAIL_P 0 -param set-default FD_FAIL_R 0 +param set-default FD_TILT_ERROR -1 # Disable magnetometer fusion in EKF2 param set-default EKF2_MAG_TYPE 5 diff --git a/Tools/astyle/astylerc b/Tools/astyle/astylerc index 3d1b437ef30..3ec7de132b9 100644 --- a/Tools/astyle/astylerc +++ b/Tools/astyle/astylerc @@ -10,9 +10,5 @@ keep-one-line-blocks keep-one-line-statements align-pointer=name align-reference=name --n #--suffix=none -ignore-exclude-errors-x -lineend=linux -exclude=EASTL add-brackets max-code-length=140 diff --git a/Tools/astyle/check_code_style.sh b/Tools/astyle/check_code_style.sh index a25fe62e8b6..836e2d8baab 100755 --- a/Tools/astyle/check_code_style.sh +++ b/Tools/astyle/check_code_style.sh @@ -1,22 +1,42 @@ #!/usr/bin/env bash +# Check the formatting of the given files, print a diff for each badly formatted +# one and fail. With PX4_ASTYLE_FIX=1 the files get fixed instead. +# +# All files are formatted in one batch on a temporary copy to keep the +# formatter startup cost independent of the number of files. -FILE=$1 -DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd ) - -CHECK_FAILED=$(${DIR}/fix_code_style.sh --dry-run --formatted $FILE) -if [ -n "$CHECK_FAILED" ]; then - ${DIR}/fix_code_style.sh --quiet < $FILE > $FILE.pretty - - echo -e 'Formatting issue found in' $FILE - echo - git --no-pager diff --no-index --minimal --histogram --color=always $FILE $FILE.pretty | grep -vE -e "^.{,4}diff.*\.pretty.{,3}$" -e "^.{,4}--- a/.*$" -e "^.{,4}\+\+\+ b/.*$" -e "^.{,5}@@ .* @@.*$" -e "^.{,4}index .{10}\.\." - rm -f $FILE.pretty - echo - - if [[ $PX4_ASTYLE_FIX -eq 1 ]]; then - ${DIR}/fix_code_style.sh $FILE - else - echo 'to fix automatically run "make format", "make format_changed" or "./Tools/astyle/fix_code_style.sh' $FILE'"' - exit 1 - fi +if [[ $# -eq 0 ]]; then + exit 0 fi + +DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd ) +TMP_DIR=$(mktemp -d) +trap 'rm -rf "$TMP_DIR"' EXIT + +FORMATTED=() +for FILE in "$@"; do + mkdir -p "$TMP_DIR/$(dirname "$FILE")" + cp "$FILE" "$TMP_DIR/$FILE" + FORMATTED+=("$TMP_DIR/$FILE") +done + +"${DIR}/fix_code_style.sh" "${FORMATTED[@]}" || exit 1 + +CHECK_FAILED=0 +for FILE in "$@"; do + if ! cmp -s "$FILE" "$TMP_DIR/$FILE"; then + echo -e 'Formatting issue found in' "$FILE" + echo + git --no-pager diff --no-index --minimal --histogram --color=always "$FILE" "$TMP_DIR/$FILE" | tail -n +5 + echo + + if [[ $PX4_ASTYLE_FIX -eq 1 ]]; then + cp "$TMP_DIR/$FILE" "$FILE" + else + echo 'to fix automatically run "make format", "make format_changed" or "./Tools/astyle/fix_code_style.sh' "$FILE"'"' + CHECK_FAILED=1 + fi + fi +done + +exit $CHECK_FAILED diff --git a/Tools/astyle/check_code_style_all.sh b/Tools/astyle/check_code_style_all.sh index 871ab622561..e8e11199d34 100755 --- a/Tools/astyle/check_code_style_all.sh +++ b/Tools/astyle/check_code_style_all.sh @@ -1,40 +1,12 @@ #!/usr/bin/env bash set -eu -# Check for the latest astyle version -ASTYLE_VER_REQUIRED_1="Artistic Style Version 2.06" -ASTYLE_VER_REQUIRED_2="Artistic Style Version 3.0" -ASTYLE_VER_REQUIRED_3="Artistic Style Version 3.0.1" -ASTYLE_VER_REQUIRED_4="Artistic Style Version 3.1" +DIR=$(cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd) -astyle_ver() { - echo "PX4 requires at least ${ASTYLE_VER_REQUIRED_1}" - echo "You can get the correct version here: https://sourceforge.net/projects/astyle/files/astyle/astyle%202.06/" -} - -# check if astyle is installed -condition=$(which astyle 2>/dev/null | grep -v "not found" | wc -l) -if [ $condition -eq 0 ]; then - echo "astyle is not installed" - astyle_ver - exit 1 -else - - ASTYLE_VER=`astyle --version` - - if [ "$ASTYLE_VER" != "$ASTYLE_VER_REQUIRED_1" -a \ - "$ASTYLE_VER" != "$ASTYLE_VER_REQUIRED_2" -a \ - "$ASTYLE_VER" != "$ASTYLE_VER_REQUIRED_3" -a \ - "$ASTYLE_VER" != "$ASTYLE_VER_REQUIRED_4" ] - then - echo "Error: you're using ${ASTYLE_VER}" - echo "but should be using ${ASTYLE_VER_REQUIRED_1}, ${ASTYLE_VER_REQUIRED_2}, ${ASTYLE_VER_REQUIRED_3}, or ${ASTYLE_VER_REQUIRED_4} instead" - exit 1 - fi -fi +# fail early if no usable astyle is installed +"${DIR}/fix_code_style.sh" CI="${CI:-false}" -DIR=$(cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd) DIFF_ONLY=false for arg in "$@"; do @@ -80,7 +52,7 @@ if [ -z "$FILE_LIST" ]; then exit 0 fi -echo "$FILE_LIST" | xargs -P 8 -I % ${DIR}/check_code_style.sh % +echo "$FILE_LIST" | xargs -P 8 -n 100 "${DIR}/check_code_style.sh" if [ $? -eq 0 ]; then echo "Format checks passed" diff --git a/Tools/astyle/check_param_names.py b/Tools/astyle/check_param_names.py new file mode 100755 index 00000000000..38683e2976e --- /dev/null +++ b/Tools/astyle/check_param_names.py @@ -0,0 +1,184 @@ +#!/usr/bin/env python3 +""" +Check that parameter members declared in DEFINE_PARAMETERS() follow the naming +convention _param_, e.g. + + (ParamFloat) _param_mpc_xy_vel_max + +Usage: + check_param_names.py report violations, exit 1 if there are any + check_param_names.py --fix rename violating members + +--fix renames the member in the declaring file and its implementation file +(same stem, optionally with _main suffix). If the old name also appears in any +other source file that does not declare it as a parameter member itself, it +might be a use (e.g. a derived class or a helper file) or an unrelated member +with the same name. Telling those apart needs a compiler, so such members are +not renamed but reported for manual renaming, and --fix exits with an error. +This keeps --fix from renaming a declaration while leaving its uses elsewhere +behind, which would break code that compiled before. +""" + +import argparse +import os +import re +import subprocess +import sys +from collections import defaultdict + +DECLARATION = re.compile(r'<\s*px4::params::(\w+)\s*>\s*\)\s*([A-Za-z_]\w*)') +IDENTIFIER = re.compile(r'[A-Za-z_]\w*') +SOURCE_EXTENSIONS = ('.c', '.cpp', '.h', '.hpp') + + +def expected_name(param): + return '_param_' + param.lower() + + +def find_violations(files): + violations = [] + + for path in files: + with open(path, encoding='utf-8', errors='replace', newline='') as f: + text = f.read() + + if 'px4::params::' not in text: + continue + + for match in DECLARATION.finditer(text): + param, member = match.groups() + + if member != expected_name(param): + line = text.count('\n', 0, match.start(2)) + 1 + violations.append((path, line, param, member)) + + return violations + + +def stem(path): + name = os.path.splitext(path)[0] + return name[:-len('_main')] if name.endswith('_main') else name + + +def stem_files(file_stem): + return [file_stem + suffix + extension + for suffix in ('', '_main') + for extension in SOURCE_EXTENSIONS + if os.path.isfile(file_stem + suffix + extension)] + + +def all_sources(): + """All tracked C/C++ sources as absolute path -> (identifiers used, parameter members declared).""" + top = subprocess.run(['git', 'rev-parse', '--show-toplevel'], + capture_output=True, text=True, check=True).stdout.strip() + paths = subprocess.run(['git', 'ls-files', '-z', '--'] + ['*' + e for e in SOURCE_EXTENSIONS], + cwd=top, capture_output=True, text=True, check=True).stdout.split('\0') + sources = {} + + for path in filter(None, paths): + path = os.path.join(top, path) + + if os.path.isfile(path): + with open(path, encoding='utf-8', errors='replace', newline='') as f: + text = f.read() + + sources[path] = (set(IDENTIFIER.findall(text)), {m.group(2) for m in DECLARATION.finditer(text)}) + + # a class usually declares its parameters in the header and uses them in the implementation file + declared_by_stem = defaultdict(set) + + for path, (_, declared) in sources.items(): + declared_by_stem[stem(path)] |= declared + + return {path: (identifiers, declared_by_stem[stem(path)]) for path, (identifiers, _) in sources.items()} + + +def outside_references(member, own_files, sources): + """Files outside own_files mentioning member without their stem declaring it as own parameter member.""" + own_files = {os.path.abspath(path) for path in own_files} + + return sorted(os.path.relpath(path) for path, (identifiers, declared) in sources.items() + if path not in own_files and member in identifiers and member not in declared) + + +def fix(violations): + # old name -> new name per file stem + renames = defaultdict(dict) + ok = True + + for path, line, param, member in violations: + stem_renames = renames[stem(path)] + new = expected_name(param) + + if stem_renames.get(member, new) != new: + print(f'{path}:{line}: {member} maps to both {stem_renames[member]} and {new}, rename manually') + ok = False + continue + + stem_renames[member] = new + + sources = all_sources() if renames else {} + + for file_stem, stem_renames in renames.items(): + files = stem_files(file_stem) + + for member in list(stem_renames): + references = outside_references(member, files, sources) + + if references: + print(f'{member} is also used in {", ".join(references)}, rename to {stem_renames[member]} manually') + del stem_renames[member] + ok = False + + if not stem_renames: + continue + + pattern = re.compile(r'\b(' + '|'.join(map(re.escape, stem_renames)) + r')\b') + + for path in files: + with open(path, encoding='utf-8', newline='') as f: + text = f.read() + + new_text = pattern.sub(lambda m: stem_renames[m.group(1)], text) + + if new_text != text: + with open(path, 'w', encoding='utf-8', newline='') as f: + f.write(new_text) + + print(f'renamed parameter members in {path}') + + return ok + + +def main(): + parser = argparse.ArgumentParser(description='Check parameter member naming') + parser.add_argument('--fix', action='store_true', help='rename violating members') + parser.add_argument('files', nargs='*', help='files to check (default: all checked by astyle)') + args = parser.parse_args() + + files = args.files + + if not files: + script_dir = os.path.dirname(os.path.abspath(__file__)) + os.chdir(os.path.join(script_dir, '..', '..')) + files = subprocess.run([os.path.join(script_dir, 'files_to_check_code_style.sh')], + capture_output=True, text=True, check=True).stdout.split() + + violations = find_violations(files) + + if args.fix: + return 0 if fix(violations) else 1 + + for path, line, param, member in violations: + print(f'{path}:{line}: parameter member {member} should be named {expected_name(param)}') + + if violations: + print(f'{len(violations)} parameter members not named _param_, ' + 'run `make format` to fix') + return 1 + + return 0 + + +if __name__ == '__main__': + sys.exit(main()) diff --git a/Tools/astyle/fix_code_style.sh b/Tools/astyle/fix_code_style.sh index af3a968e38a..8c5e390e549 100755 --- a/Tools/astyle/fix_code_style.sh +++ b/Tools/astyle/fix_code_style.sh @@ -1,11 +1,41 @@ #!/usr/bin/env bash - -if [[ $# -eq 0 ]] ; then - exit 0 -fi +# Format the given files in place with astyle 3.1 and the PX4 rules in astylerc. +# +# Prefers astyle-py (pip install astyle-py, see Tools/setup/requirements.txt) +# which bundles astyle 3.1 independent of the OS. Falls back to a natively +# installed astyle of a supported version. +# +# Without file arguments it only checks that a usable astyle is available. DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd ) -astyle \ - --options=$DIR/astylerc \ - --preserve-date \ - $* +ASTYLE_PY_VERSION="3.1" +ASTYLE_NATIVE_VERSIONS=("2.06" "3.0" "3.0.1" "3.1") + +if command -v astyle_py >/dev/null 2>&1; then + ASTYLE=(astyle_py) +elif python3 -c "import astyle_py" >/dev/null 2>&1; then + ASTYLE=(python3 -m astyle_py) +fi + +if [[ -n "${ASTYLE[*]}" ]]; then + ASTYLE+=("--astyle-version=${ASTYLE_PY_VERSION}" --options="${DIR}/astylerc" --quiet) +else + NATIVE_VERSION=$(astyle --version 2>/dev/null | sed -n 's/^Artistic Style Version //p') + for v in "${ASTYLE_NATIVE_VERSIONS[@]}"; do + if [[ "$NATIVE_VERSION" == "$v" ]]; then + ASTYLE=(astyle --options="${DIR}/astylerc" --suffix=none --lineend=linux --preserve-date --quiet) + fi + done +fi + +if [[ -z "${ASTYLE[*]}" ]]; then + echo "Error: no usable astyle found${NATIVE_VERSION:+ (installed astyle ${NATIVE_VERSION} is not supported)}." >&2 + echo "Install astyle 3.1 via: python3 -m pip install -r ${DIR}/../setup/requirements.txt" >&2 + exit 1 +fi + +if [[ $# -eq 0 ]]; then + exit 0 +fi + +"${ASTYLE[@]}" "$@" >/dev/null diff --git a/Tools/astyle/pre-commit b/Tools/astyle/pre-commit index 6c9bb248e62..2172e3bdc42 100755 --- a/Tools/astyle/pre-commit +++ b/Tools/astyle/pre-commit @@ -54,7 +54,7 @@ if [ $? -ne 0 ]; then fi # Check for code style, only in changed files -bash -c "comm -12 <(./Tools/astyle/files_to_check_code_style.sh | sort) <(git diff --cached --name-only --diff-filter=ACM) | xargs -P 8 -I % ./Tools/astyle/check_code_style.sh %" +bash -c "comm -12 <(./Tools/astyle/files_to_check_code_style.sh | sort) <(git diff --cached --name-only --diff-filter=ACM) | xargs ./Tools/astyle/check_code_style.sh" if [ $? -ne 0 ] then echo "Pre-commit style error: Bad formatting according to astyle rules" diff --git a/Tools/ci/build_all_config.yml b/Tools/ci/build_all_config.yml index d9a25869d4e..17b3f56ecb0 100644 --- a/Tools/ci/build_all_config.yml +++ b/Tools/ci/build_all_config.yml @@ -8,7 +8,7 @@ # Container images containers: default: "ghcr.io/px4/px4-dev:v1.18.0-beta2" - voxl2: "ghcr.io/px4/px4-dev-voxl2:v1.7" + voxl2: "ghcr.io/px4/px4-dev-voxl2:v1.8" # Runner specs runners: diff --git a/Tools/module_config/generate_params.py b/Tools/module_config/generate_params.py index b60d66ebc19..f57b8197364 100755 --- a/Tools/module_config/generate_params.py +++ b/Tools/module_config/generate_params.py @@ -8,7 +8,7 @@ import os import sys from copy import deepcopy -from output_groups_from_timer_config import get_timer_groups, get_output_groups +from output_groups_from_timer_config import get_timer_groups, get_output_groups, load_board_config try: import yaml @@ -29,7 +29,7 @@ parser.add_argument('--params-file', type=str, action='store', parser.add_argument('--timer-config', type=str, action='store', help='board-specific timer_config.cpp file') parser.add_argument('--board-config', type=str, action='store', - help='board Kconfig boardconfig file, evaluates the timer_config.cpp preprocessor conditionals') + help='board Kconfig boardconfig file, evaluates the timer_config.cpp preprocessor conditionals and Kconfig instance counts') parser.add_argument('--ethernet', action='store_true', help='Ethernet support') parser.add_argument('--board', type=str, action='store', @@ -52,6 +52,15 @@ board = args.board root_dir = os.path.join(os.path.dirname(os.path.realpath(__file__)),"../..") output_functions_file = os.path.join(root_dir,"src/lib/mixer_module/output_functions.yaml") +board_config = load_board_config(args.board_config) + +def get_num_instances(num_instances): + """ num_instances is an integer or {kconfig: SYMBOL, default: N} """ + if isinstance(num_instances, dict): + return int(board_config.get('CONFIG_' + num_instances['kconfig'], + num_instances['default'])) + return num_instances + def process_module_name(module_name): if module_name == '${PWM_MAIN_OR_AUX}': if board_with_io: return 'PWM AUX' @@ -102,7 +111,8 @@ def parse_yaml_parameters_config(yaml_config, ethernet_supported): for param in param_list: if param.get('requires_ethernet', False) and not ethernet_supported: continue - num_instances = param.get('num_instances', 1) + num_instances_config = param.get('num_instances', 1) + num_instances = get_num_instances(num_instances_config) instance_start = param.get('instance_start', 0) # offset instance_start_label = param.get('instance_start_label', instance_start) @@ -146,10 +156,13 @@ def parse_yaml_parameters_config(yaml_config, ethernet_supported): # default value default_value = 0 if 'default' in param: - # default can be a list of num_instances or a single value + # default can be a list of num_instances or a single value. + # With a Kconfig count, instances past the end of the list + # take its last entry. if type(param['default']) == list: - assert len(param['default']) == num_instances - default_value = param['default'][i] + if not isinstance(num_instances_config, dict): + assert len(param['default']) == num_instances + default_value = param['default'][min(i, len(param['default']) - 1)] else: default_value = param['default'] diff --git a/Tools/module_config/output_groups_from_timer_config.py b/Tools/module_config/output_groups_from_timer_config.py index 8e01ec4a27d..0410f12fd6e 100755 --- a/Tools/module_config/output_groups_from_timer_config.py +++ b/Tools/module_config/output_groups_from_timer_config.py @@ -78,12 +78,13 @@ def imxrt_is_dshot(line): return False def load_board_config(board_config): - """ return the set of symbols assigned in a Kconfig .config style file - (e.g. the boardconfig the build generates); None gives an empty set """ + """ return the symbols assigned in a Kconfig .config style file (e.g. the + boardconfig the build generates) as a dict of symbol to value, with string + quotes stripped; None gives an empty dict """ if board_config is None: - return set() + return {} with open(board_config, 'r') as f: - return {m.group(1) for m in (re.match(r'(\w+)=', l) for l in f) if m} + return {m.group(1): m.group(2).strip('"') for m in (re.match(r'(\w+)=(.*)', l.strip()) for l in f) if m} def preprocess(text, defined): """ return the lines of text the C preprocessor keeps, given the set of defined symbols. diff --git a/Tools/packaging/containers/ros2-install-dependencies.sh b/Tools/packaging/containers/ros2-install-dependencies.sh index b2b0822f9c5..f03e79b6d0c 100644 --- a/Tools/packaging/containers/ros2-install-dependencies.sh +++ b/Tools/packaging/containers/ros2-install-dependencies.sh @@ -18,10 +18,18 @@ apt-get install -y --no-install-recommends /ros2-apt-source.deb rm /ros2-apt-source.deb apt-get update apt-get install -y --no-install-recommends \ - build-essential ccache cmake git ninja-build \ + astyle build-essential ccache cmake git ninja-build \ python3-empy python3-pip ros-dev-tools "ros-${ROS_DISTRO}-ros-base" \ "ros-${ROS_DISTRO}-rmw-zenoh-cpp" +# astyle-py requires PyYAML 6, which conflicts with the distro PyYAML pinned +# below (5.4.1 on jammy). Rely on the distro astyle 3.1 installed above, which +# Tools/astyle/fix_code_style.sh accepts. /px4-setup is a read-only bind mount, +# so filter a copy of it. +px4_setup_dir=$(mktemp -d) +cp -r /px4-setup/. "${px4_setup_dir}" +sed -i '/^astyle-py/d' "${px4_setup_dir}/requirements.txt" + # Keep Ubuntu/ROS Python packages while satisfying PX4's shared requirements. # Distro-only versions (e.g. ubuntu suffixes) cannot be pip constraints. python3 - <<'PY' > /px4-python-constraints.txt @@ -43,8 +51,8 @@ else extra_args="" fi RUNS_IN_DOCKER=true PIP_CONSTRAINT=/px4-python-constraints.txt PIP_NO_CACHE_DIR=1 \ - bash /px4-setup/ubuntu.sh --no-nuttx ${extra_args} -rm /px4-python-constraints.txt + bash "${px4_setup_dir}/ubuntu.sh" --no-nuttx ${extra_args} +rm -rf /px4-python-constraints.txt "${px4_setup_dir}" rosdep init rosdep update --rosdistro "${ROS_DISTRO}" diff --git a/Tools/parameter_update.py b/Tools/parameter_update.py deleted file mode 100755 index 6d92dde4cbb..00000000000 --- a/Tools/parameter_update.py +++ /dev/null @@ -1,94 +0,0 @@ -#!/usr/bin/env python3 -# -*- coding: utf-8 -*- - -############################################################################ -# -# Copyright (c) 2018 PX4 Development Team. All rights reserved. -# -# Redistribution and use in source and binary forms, with or without -# modification, are permitted provided that the following conditions -# are met: -# -# 1. Redistributions of source code must retain the above copyright -# notice, this list of conditions and the following disclaimer. -# 2. Redistributions in binary form must reproduce the above copyright -# notice, this list of conditions and the following disclaimer in -# the documentation and/or other materials provided with the -# distribution. -# 3. Neither the name PX4 nor the names of its contributors may be -# used to endorse or promote products derived from this software -# without specific prior written permission. -# -# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS -# FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE -# COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, -# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, -# BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS -# OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED -# AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN -# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE -# POSSIBILITY OF SUCH DAMAGE. -# -############################################################################ - -""" -File: parameter_update.py -Description: - This script searches for declarations of BlockParam, creates a variable name of the - form "_param_name_of_parameter" and replaces the old variable with the new one. - -Example: - (ParamExtFloat) _gyroNoise, - [...] - _gyroNoise.set(1.f); - - is replaced by - - (ParamExtFloat) _param_ekf2_gyr_noise, - [...] - _param_ekf2_gyr_noise.set(1.f); - -Usage: - The script needs a list of files as an input. To quickly find and feed all the file - that it needs to inspect, one can simply pipe the result of a ripgrep -l command as follows: - - rg -l '\.[gs]et\(|px4::params::' -tcpp | python3 parameter_update.py -""" - -import re -import fileinput -import sys - -filenames = [] -for filename in sys.stdin: - filenames.append(filename.rstrip()) - -pattern = r'^.*\)\s*([A-Za-z0-9_]+)[,\s]?.*$' -regex = re.compile(pattern, re.MULTILINE) - -replace_dict = dict() - -print("Searching for parameters...") -for filename in filenames: - print(filename) - with open(filename, 'r') as f: - text = f.read() - for match in regex.finditer(text): - replace_dict[match.group(2)] = "_param_" + match.group(1).strip().lower() - -print("The following variables will be changed") -for old_var in replace_dict: - print("{} -> {}".format(old_var, replace_dict[old_var])) - -for filename in filenames: - print(filename) - for old_var in replace_dict: - for line in fileinput.input(filename, inplace=1): - line = re.sub(r'(>\)\s*)\b' + old_var + r'\b', r'\1' + replace_dict[old_var], line.rstrip()) # replace the declaration - line = re.sub(r'(^\s*)\b' + old_var + r'\b', r'\1' + replace_dict[old_var], line.rstrip()) # replace the 2 liner declaration and when the variable is used a the beginning of a new line - line = re.sub(r'\b' + old_var + r'\b(\.([gs]et|commit)\()',replace_dict[old_var] + r'\1' , line.rstrip()) # replace the usages (with get/set/commit) - line = re.sub(r'(\()\b' + old_var + r'\b', r'\1' + replace_dict[old_var], line.rstrip()) # replace the 2 liner declaration - print(line) diff --git a/Tools/serial/generate_config.py b/Tools/serial/generate_config.py index dc9c2762f9e..84aab8f4e3c 100755 --- a/Tools/serial/generate_config.py +++ b/Tools/serial/generate_config.py @@ -5,6 +5,9 @@ import argparse import os import sys +sys.path.append(os.path.join(os.path.dirname(os.path.realpath(__file__)), '../module_config')) +from output_groups_from_timer_config import load_board_config + try: from jinja2 import Environment, FileSystemLoader except ImportError as e: @@ -162,6 +165,8 @@ parser.add_argument('--params-file', type=str, action='store', help='Parameter output file', default=None) parser.add_argument('--ethernet', action='store_true', help='Ethernet support') +parser.add_argument('--board-config', type=str, action='store', default=None, + help='board Kconfig boardconfig file, for Kconfig instance counts') parser.add_argument('-v', '--verbose', dest='verbose', action='store_true', help='Verbose Output') @@ -201,6 +206,15 @@ if ethernet_supported: 'index': 1000 }) +board_config = load_board_config(args.board_config) + +def get_num_instances(num_instances): + """ num_instances is an integer or {kconfig: SYMBOL, default: N} """ + if isinstance(num_instances, dict): + return int(board_config.get('CONFIG_' + num_instances['kconfig'], + num_instances['default'])) + return num_instances + def parse_yaml_serial_config(yaml_config): """ parse the serial_config section from the yaml config file """ if 'serial_config' not in yaml_config: @@ -247,7 +261,10 @@ for tag, device in board_ports: # construct commands based on selected board commands = [] for serial_command in serial_commands: - num_instances = serial_command.get('num_instances', 1) + num_instances_config = serial_command.get('num_instances', 1) + num_instances = get_num_instances(num_instances_config) + # a Kconfig count of 1 still needs ${i} set in the script + multi_instance = num_instances > 1 or isinstance(num_instances_config, dict) # TODO: use a loop in the script instead of explicitly enumerating all instances for i in range(num_instances): port_config = serial_command['port_config_param'] @@ -264,8 +281,10 @@ for serial_command in serial_commands: default_port = 0 # disabled if 'default' in port_config: if type(port_config['default']) == list: - assert len(port_config['default']) == num_instances - default_port_str = port_config['default'][i] + # with a Kconfig count, instances past the end of the list take its last entry + if not isinstance(num_instances_config, dict): + assert len(port_config['default']) == num_instances + default_port_str = port_config['default'][min(i, len(port_config['default']) - 1)] else: default_port_str = port_config['default'] @@ -281,7 +300,7 @@ for serial_command in serial_commands: 'command': serial_command['command'], 'label': serial_command['label'], 'instance': i, - 'multi_instance': num_instances > 1, + 'multi_instance': multi_instance, 'port_param_name': port_param_name, 'default_port': default_port, 'param_group': port_config['group'], diff --git a/Tools/setup/arch.sh b/Tools/setup/arch.sh index d72be01f45d..5d2eea59aca 100755 --- a/Tools/setup/arch.sh +++ b/Tools/setup/arch.sh @@ -44,7 +44,6 @@ echo echo "Installing PX4 general dependencies" sudo pacman -Sy --noconfirm --needed \ - astyle \ base-devel \ clang \ cmake \ diff --git a/Tools/setup/macos.sh b/Tools/setup/macos.sh index 092415a3f89..e5bef6df8b5 100755 --- a/Tools/setup/macos.sh +++ b/Tools/setup/macos.sh @@ -84,7 +84,6 @@ brew tap PX4/px4 # Package list. This replaces the px4-dev meta-formula, which is kept # as a deprecated no-op upstream. See PX4/homebrew-px4 for history. PX4_BREW_PACKAGES=( - astyle bash-completion ccache cmake diff --git a/Tools/setup/requirements.txt b/Tools/setup/requirements.txt index 81a9c9facf0..94cc6c5a775 100644 --- a/Tools/setup/requirements.txt +++ b/Tools/setup/requirements.txt @@ -1,4 +1,5 @@ argcomplete +astyle-py==1.1.0 cerberus coverage empy>=3.3,<4 diff --git a/Tools/setup/ubuntu.sh b/Tools/setup/ubuntu.sh index a657f650e21..1d25b1094ab 100755 --- a/Tools/setup/ubuntu.sh +++ b/Tools/setup/ubuntu.sh @@ -79,7 +79,6 @@ echo "[ubuntu.sh] Installing PX4 general dependencies" sudo apt-get update -y --quiet sudo DEBIAN_FRONTEND=noninteractive apt-get -y --quiet --no-install-recommends install \ - astyle \ build-essential \ ccache \ cmake \ diff --git a/boards/accton-godwit/gfh7/bootloader.px4board b/boards/accton-godwit/gfh7/bootloader.px4board new file mode 100644 index 00000000000..19b6e662be6 --- /dev/null +++ b/boards/accton-godwit/gfh7/bootloader.px4board @@ -0,0 +1,3 @@ +CONFIG_BOARD_TOOLCHAIN="arm-none-eabi" +CONFIG_BOARD_ARCHITECTURE="cortex-m7" +CONFIG_BOARD_ROMFSROOT="" diff --git a/boards/accton-godwit/gfh7/debug.px4board b/boards/accton-godwit/gfh7/debug.px4board new file mode 100644 index 00000000000..0fbff84166d --- /dev/null +++ b/boards/accton-godwit/gfh7/debug.px4board @@ -0,0 +1,6 @@ +# Accton Godwit GFH7 debug build configuration +# Build target: make accton-godwit_gfh7_debug +# Merged on top of default.px4board, so only the differences belong here. + +# UART4 (/dev/ttyS3) is the NuttX console in this build. +# CONFIG_BOARD_SERIAL_TEL4 is not set diff --git a/boards/accton-godwit/gfh7/default.px4board b/boards/accton-godwit/gfh7/default.px4board new file mode 100644 index 00000000000..1185753049d --- /dev/null +++ b/boards/accton-godwit/gfh7/default.px4board @@ -0,0 +1,114 @@ +# Accton Godwit GFH7 default PX4 build configuration +# Board path: boards/accton-godwit/gfh7/ +# Build target: make accton-godwit_gfh7_default +# Board ID: 7122 +# MCU: STM32H753VIH6 (TFBGA100, 2MB Flash, 1MB RAM) + +CONFIG_BOARD_TOOLCHAIN="arm-none-eabi" +CONFIG_BOARD_ARCHITECTURE="cortex-m7" +CONFIG_BOARD_COMPILE_DEFINITIONS="-DUSE_S_RGB_LED_DMA" +CONFIG_BOARD_UAVCAN_INTERFACES=1 +CONFIG_BOARD_ROMFSROOT="px4fmu_common" +CONFIG_BOARD_ETHERNET=n +# USART1: ESC connector telemetry pin (RX only), ESC telemetry +CONFIG_BOARD_SERIAL_EXT2="/dev/ttyS0" +# USART2: T2/R2 pads +CONFIG_BOARD_SERIAL_TEL2="/dev/ttyS1" +# USART3: GPS connector +CONFIG_BOARD_SERIAL_GPS1="/dev/ttyS2" +# UART4: ELRS connector +CONFIG_BOARD_SERIAL_TEL4="/dev/ttyS3" +# UART5: SBUS connector (RX and TX), A-VTX connector (TX only, shared with the SBUS connector TX line) +CONFIG_BOARD_SERIAL_RC="/dev/ttyS4" +# UART7: TELEM connector +CONFIG_BOARD_SERIAL_TEL1="/dev/ttyS5" +# UART8: D-VTX connector +CONFIG_BOARD_SERIAL_TEL3="/dev/ttyS6" + +# ============================================================================ +# Drivers - Sensors +# ============================================================================ +CONFIG_DRIVERS_BAROMETER_DPS310=y +CONFIG_DRIVERS_MAGNETOMETER_ISENTEK_IST8310=y +CONFIG_DRIVERS_IMU_INVENSENSE_ICM42688P=y +CONFIG_DRIVERS_IMU_ST_LSM6DSV=y +CONFIG_DRIVERS_GPS=y + +# ============================================================================ +# Drivers - I/O and Comms +# ============================================================================ +CONFIG_COMMON_RC=y +CONFIG_DRIVERS_PWM_OUT=y +CONFIG_DRIVERS_DSHOT=y +CONFIG_DRIVERS_TONE_ALARM=y +CONFIG_DRIVERS_LIGHTS_NEOPIXEL=y +CONFIG_DRIVERS_CDCACM_AUTOSTART=y +CONFIG_DRIVERS_ADC_BOARD_ADC=y +CONFIG_DRIVERS_HEATER=y +CONFIG_DRIVERS_UAVCAN=y +CONFIG_DRIVERS_OSD_MSP_OSD=y +CONFIG_DRIVERS_OSD_ATXXXX=y + +# ============================================================================ +# System commands (px4 command-line utilities) +# ============================================================================ +CONFIG_SYSTEMCMDS_BL_UPDATE=y +CONFIG_SYSTEMCMDS_BSONDUMP=y +CONFIG_SYSTEMCMDS_DMESG=y +CONFIG_SYSTEMCMDS_DUMPFILE=y +CONFIG_SYSTEMCMDS_HARDFAULT_LOG=y +CONFIG_SYSTEMCMDS_LED_CONTROL=y +CONFIG_SYSTEMCMDS_MFT=y +CONFIG_SYSTEMCMDS_MTD=y +CONFIG_SYSTEMCMDS_NSHTERM=y +CONFIG_SYSTEMCMDS_PARAM=y +CONFIG_SYSTEMCMDS_PERF=y +CONFIG_SYSTEMCMDS_REBOOT=y +CONFIG_SYSTEMCMDS_SD_BENCH=y +CONFIG_SYSTEMCMDS_SD_STRESS=y +CONFIG_SYSTEMCMDS_SERIAL_TEST=y +CONFIG_SYSTEMCMDS_SYSTEM_TIME=y +CONFIG_SYSTEMCMDS_TOP=y +CONFIG_SYSTEMCMDS_TOPIC_LISTENER=y +CONFIG_SYSTEMCMDS_TUNE_CONTROL=y +CONFIG_SYSTEMCMDS_UORB=y +CONFIG_SYSTEMCMDS_USB_CONNECTED=y +CONFIG_SYSTEMCMDS_VER=y +CONFIG_SYSTEMCMDS_WORK_QUEUE=y + +# ============================================================================ +# Modules - Flight stack +# ============================================================================ +CONFIG_MODULES_AIRSPEED_SELECTOR=y +CONFIG_MODULES_ATTITUDE_ESTIMATOR_Q=y +CONFIG_MODULES_BATTERY_STATUS=y +CONFIG_MODULES_CAMERA_FEEDBACK=y +CONFIG_MODULES_COMMANDER=y +CONFIG_MODULES_CONTROL_ALLOCATOR=y +CONFIG_MODULES_DATAMAN=y +CONFIG_MODULES_EKF2=y +CONFIG_MODULES_EVENTS=y +CONFIG_MODULES_FLIGHT_MODE_MANAGER=y +CONFIG_MODULES_FW_ATT_CONTROL=y +CONFIG_MODULES_FW_AUTOTUNE_ATTITUDE_CONTROL=y +CONFIG_MODULES_FW_LATERAL_LONGITUDINAL_CONTROL=y +CONFIG_MODULES_FW_MODE_MANAGER=y +CONFIG_MODULES_FW_RATE_CONTROL=y +CONFIG_MODULES_GIMBAL=y +CONFIG_MODULES_LAND_DETECTOR=y +CONFIG_MODULES_LOAD_MON=y +CONFIG_MODULES_LOGGER=y +CONFIG_MODULES_MAG_BIAS_ESTIMATOR=y +CONFIG_MODULES_MANUAL_CONTROL=y +CONFIG_MODULES_MAVLINK=y +CONFIG_MODULES_MC_ATT_CONTROL=y +CONFIG_MODULES_MC_AUTOTUNE_ATTITUDE_CONTROL=y +CONFIG_MODULES_MC_HOVER_THRUST_ESTIMATOR=y +CONFIG_MODULES_MC_POS_CONTROL=y +CONFIG_MODULES_MC_RATE_CONTROL=y +CONFIG_MODULES_NAVIGATOR=y +CONFIG_MODULES_RC_UPDATE=y +CONFIG_MODULES_SENSORS=y +CONFIG_MODULES_SIMULATION_BATTERY_SIMULATOR=n +CONFIG_MODULES_UXRCE_DDS_CLIENT=y +CONFIG_MODULES_VTOL_ATT_CONTROL=y diff --git a/boards/accton-godwit/gfh7/extras/accton-godwit_gfh7_bootloader.bin b/boards/accton-godwit/gfh7/extras/accton-godwit_gfh7_bootloader.bin new file mode 100644 index 00000000000..6b562d5c938 Binary files /dev/null and b/boards/accton-godwit/gfh7/extras/accton-godwit_gfh7_bootloader.bin differ diff --git a/boards/accton-godwit/gfh7/firmware.prototype b/boards/accton-godwit/gfh7/firmware.prototype new file mode 100644 index 00000000000..af1bed97715 --- /dev/null +++ b/boards/accton-godwit/gfh7/firmware.prototype @@ -0,0 +1,13 @@ +{ + "board_id": 7122, + "magic": "PX4FWv1", + "description": "Firmware for the Accton Godwit GFH7 flight controller", + "image": "", + "build_time": 0, + "summary": "Accton-Godwit-GFH7", + "version": "0.1", + "image_size": 0, + "image_maxsize": 1835008, + "git_identity": "", + "board_revision": 0 +} diff --git a/boards/accton-godwit/gfh7/init/rc.board_defaults b/boards/accton-godwit/gfh7/init/rc.board_defaults new file mode 100644 index 00000000000..eefa733c4e7 --- /dev/null +++ b/boards/accton-godwit/gfh7/init/rc.board_defaults @@ -0,0 +1,32 @@ +#!/bin/sh + +# Analog battery voltage input: PC0 / ADC1 channel 10, 160k/10k divider. +param set-default BAT1_SOURCE 0 +param set-default BAT1_V_CHANNEL 10 +param set-default BAT1_V_DIV 17.0 + +# Enable the SPI1 MAX7456-compatible OSD in NTSC mode. +param set-default OSD_ATXXXX_CFG 1 + +# S.BUS receiver on the SBUS connector (UART5) disabled: ELRS is the RC input. +param set-default RC_SBUS_PRT_CFG 0 + +# ELRS (CRSF) receiver on the ELRS connector (UART4): 104 = TEL4 port. +# The debug build has no TEL4 port (UART4 is the NuttX console), so CRSF does not start there. +param set-default RC_CRSF_PRT_CFG 104 +# Send CRSF telemetry (battery, GPS, attitude, flight mode) back to the transmitter. +param set-default RC_CRSF_TEL_EN 1 + +# Boot into Stabilized mode instead of Hold: 15 = Stabilized. +param set-default COM_FLTMODE_BOOT 15 + +# ESC telemetry on the ESC connector (USART1, RX only): 401 = EXT2 port. +param set-default DSHOT_TEL_CFG 401 + +# Heater (PE3) is supported but off by default. Set SENS_EN_THERMAL to 1 to enable it. +param set-default SENS_EN_THERMAL 0 +# Heater target temperature (degC). +param set-default HEATER1_TEMP 45 + +# Start all populated NeoPixels; PB10 is not exposed as a motor output. +neopixel start diff --git a/boards/accton-godwit/gfh7/init/rc.board_extras b/boards/accton-godwit/gfh7/init/rc.board_extras new file mode 100644 index 00000000000..1c644d94c63 --- /dev/null +++ b/boards/accton-godwit/gfh7/init/rc.board_extras @@ -0,0 +1,7 @@ +#!/bin/sh + +# Start the SPI1 SW7456-compatible analog OSD when configured. +if ! param compare OSD_ATXXXX_CFG 0 +then + atxxxx start -s +fi diff --git a/boards/accton-godwit/gfh7/init/rc.board_sensors b/boards/accton-godwit/gfh7/init/rc.board_sensors new file mode 100644 index 00000000000..0c606fa3b0f --- /dev/null +++ b/boards/accton-godwit/gfh7/init/rc.board_sensors @@ -0,0 +1,21 @@ +#!/bin/sh + +# ICM-42688-P on SPI4, 32 kHz external clock on PD14. +# Rotation 6 = ROTATION_YAW_270. The chip sits rotated 90 degrees in yaw +# relative to the LSM6DSK320X on the PCB. The driver already flips y & z, +# so only the mounting rotation belongs here. +icm42688p -R 6 -C 32000 -s -b 4 start + +# LSM6DSK320X (lsm6dsv driver) on SPI2. +# Rotation 0 = ROTATION_NONE. Like the ICM-42688-P driver, this driver flips +# y & z, and the chip is aligned with the board axes. +lsm6dsv -R 0 -s -b 2 start + +# DPS368 on internal I2C1 at 0x77; the DPS310 driver supports this variant. +dps310 -I -b 1 -a 119 -8 start + +# IST8310 on internal I2C1 at 0x0c. +# Rotation 6 = ROTATION_YAW_270. The driver already flips z. +ist8310 -I -b 1 -a 12 -R 6 start + +board_adc start diff --git a/boards/accton-godwit/gfh7/nuttx-config/bootloader/defconfig b/boards/accton-godwit/gfh7/nuttx-config/bootloader/defconfig new file mode 100644 index 00000000000..8d07a0b811d --- /dev/null +++ b/boards/accton-godwit/gfh7/nuttx-config/bootloader/defconfig @@ -0,0 +1,94 @@ +# +# This file is autogenerated: PLEASE DO NOT EDIT IT. +# +# You can use "make menuconfig" to make any modifications to the installed .config file. +# You can then do "make savedefconfig" to generate a new defconfig file that includes your +# modifications. +# +# CONFIG_DEV_CONSOLE is not set +# CONFIG_DISABLE_PSEUDOFS_OPERATIONS is not set +# CONFIG_SPI_EXCHANGE is not set +# CONFIG_STM32H7_SYSCFG is not set +CONFIG_ARCH="arm" +CONFIG_ARCH_BOARD_CUSTOM=y +CONFIG_ARCH_BOARD_CUSTOM_DIR="../../../../boards/accton-godwit/gfh7/nuttx-config" +CONFIG_ARCH_BOARD_CUSTOM_DIR_RELPATH=y +CONFIG_ARCH_BOARD_CUSTOM_NAME="px4" +CONFIG_ARCH_CHIP="stm32h7" +CONFIG_ARCH_CHIP_STM32H753VI=y +CONFIG_ARCH_CHIP_STM32H7=y +CONFIG_ARCH_INTERRUPTSTACK=768 +CONFIG_ARMV7M_BASEPRI_WAR=y +CONFIG_ARMV7M_ICACHE=y +CONFIG_ARMV7M_MEMCPY=y +CONFIG_ARMV7M_USEBASEPRI=y +CONFIG_BOARDCTL=y +CONFIG_BOARDCTL_RESET=y +CONFIG_BOARD_ASSERT_RESET_VALUE=0 +CONFIG_BOARD_INITTHREAD_PRIORITY=254 +CONFIG_BOARD_LATE_INITIALIZE=y +CONFIG_BOARD_LOOPSPERMSEC=22114 +CONFIG_BOARD_RESET_ON_ASSERT=2 +CONFIG_CDCACM=y +CONFIG_CDCACM_IFLOWCONTROL=y +CONFIG_CDCACM_PRODUCTID=0x1BD2 +CONFIG_CDCACM_PRODUCTSTR="PX4 BL Accton GFH7" +CONFIG_CDCACM_RXBUFSIZE=600 +CONFIG_CDCACM_TXBUFSIZE=12000 +CONFIG_CDCACM_VENDORID=0x083A +CONFIG_CDCACM_VENDORSTR="Accton" +CONFIG_DEBUG_FULLOPT=y +CONFIG_DEBUG_SYMBOLS=y +CONFIG_DEBUG_TCBINFO=y +CONFIG_DEFAULT_SMALL=y +CONFIG_EXPERIMENTAL=y +CONFIG_FDCLONE_DISABLE=y +CONFIG_FDCLONE_STDIO=y +CONFIG_FILE_STREAM=y +CONFIG_HAVE_CXX=y +CONFIG_HAVE_CXXINITIALIZE=y +CONFIG_IDLETHREAD_STACKSIZE=750 +CONFIG_INIT_ENTRYPOINT="bootloader_main" +CONFIG_INIT_STACKSIZE=3194 +CONFIG_LIBC_FLOATINGPOINT=y +CONFIG_LIBC_LONG_LONG=y +CONFIG_LIBC_STRERROR=y +CONFIG_MEMSET_64BIT=y +CONFIG_MEMSET_OPTSPEED=y +CONFIG_PREALLOC_TIMERS=50 +CONFIG_PTHREAD_STACK_MIN=512 +CONFIG_RAM_SIZE=245760 +CONFIG_RAM_START=0x20010000 +CONFIG_RAW_BINARY=y +CONFIG_SERIAL_TERMIOS=y +CONFIG_SIG_DEFAULT=y +CONFIG_SIG_SIGALRM_ACTION=y +CONFIG_SIG_SIGUSR1_ACTION=y +CONFIG_SIG_SIGUSR2_ACTION=y +CONFIG_SPI=y +CONFIG_STACK_COLORATION=y +CONFIG_START_DAY=30 +CONFIG_START_MONTH=11 +CONFIG_STDIO_BUFFER_SIZE=32 +CONFIG_STM32H7_BKPSRAM=y +CONFIG_STM32H7_DMA1=y +CONFIG_STM32H7_DMA2=y +CONFIG_STM32H7_OTGFS=y +CONFIG_STM32H7_PROGMEM=y +CONFIG_STM32H7_SERIAL_DISABLE_REORDERING=y +CONFIG_STM32H7_TIM1=y +CONFIG_STM32H7_UART7=y +CONFIG_SYSTEMTICK_HOOK=y +CONFIG_SYSTEM_CDCACM=y +CONFIG_TASK_NAME_SIZE=24 +CONFIG_TTY_SIGINT=y +CONFIG_TTY_SIGINT_CHAR=0x03 +CONFIG_TTY_SIGTSTP=y +CONFIG_UART7_RXBUFSIZE=512 +CONFIG_UART7_RXDMA=y +CONFIG_UART7_TXBUFSIZE=512 +CONFIG_UART7_TXDMA=y +CONFIG_USBDEV=y +CONFIG_USBDEV_BUSPOWERED=y +CONFIG_USBDEV_MAXPOWER=500 +CONFIG_USEC_PER_TICK=1000 diff --git a/boards/accton-godwit/gfh7/nuttx-config/debug/defconfig b/boards/accton-godwit/gfh7/nuttx-config/debug/defconfig new file mode 100644 index 00000000000..848e3d0e1dc --- /dev/null +++ b/boards/accton-godwit/gfh7/nuttx-config/debug/defconfig @@ -0,0 +1,259 @@ +# +# This file is autogenerated: PLEASE DO NOT EDIT IT. +# +# You can use "make menuconfig" to make any modifications to the installed .config file. +# You can then do "make savedefconfig" to generate a new defconfig file that includes your +# modifications. +# +# CONFIG_DISABLE_ENVIRON is not set +# CONFIG_DISABLE_PSEUDOFS_OPERATIONS is not set +# CONFIG_DISABLE_PTHREAD is not set +# CONFIG_FS_PROCFS_EXCLUDE_BLOCKS is not set +# CONFIG_FS_PROCFS_EXCLUDE_MEMINFO is not set +# CONFIG_FS_PROCFS_EXCLUDE_MOUNT is not set +# CONFIG_FS_PROCFS_EXCLUDE_USAGE is not set +# CONFIG_LIBC_GAISTRERROR_ERRNUM is not set +# CONFIG_LIBC_STRFTIME_C_STANDARD_FORMATS is not set +# CONFIG_LIBC_STRFTIME_NONSTANDARD_FORMATS is not set +# CONFIG_MMCSD_HAVE_CARDDETECT is not set +# CONFIG_MMCSD_HAVE_WRITEPROTECT is not set +# CONFIG_MMCSD_IOCSUPPORT is not set +# CONFIG_MMCSD_MMCSUPPORT is not set +# CONFIG_MMCSD_SPI is not set +# CONFIG_NSH_DISABLEBG is not set +# CONFIG_NSH_DISABLESCRIPT is not set +# CONFIG_NSH_DISABLE_ARP is not set +# CONFIG_NSH_DISABLE_CAT is not set +# CONFIG_NSH_DISABLE_CD is not set +# CONFIG_NSH_DISABLE_CP is not set +# CONFIG_NSH_DISABLE_DATE is not set +# CONFIG_NSH_DISABLE_DF is not set +# CONFIG_NSH_DISABLE_ECHO is not set +# CONFIG_NSH_DISABLE_ENV is not set +# CONFIG_NSH_DISABLE_ERROR_PRINT is not set +# CONFIG_NSH_DISABLE_EXEC is not set +# CONFIG_NSH_DISABLE_EXIT is not set +# CONFIG_NSH_DISABLE_EXPORT is not set +# CONFIG_NSH_DISABLE_FREE is not set +# CONFIG_NSH_DISABLE_GET is not set +# CONFIG_NSH_DISABLE_IFCONFIG is not set +# CONFIG_NSH_DISABLE_IFUPDOWN is not set +# CONFIG_NSH_DISABLE_ITEF is not set +# CONFIG_NSH_DISABLE_KILL is not set +# CONFIG_NSH_DISABLE_LOOPS is not set +# CONFIG_NSH_DISABLE_LS is not set +# CONFIG_NSH_DISABLE_MKDIR is not set +# CONFIG_NSH_DISABLE_MKFATFS is not set +# CONFIG_NSH_DISABLE_MOUNT is not set +# CONFIG_NSH_DISABLE_MV is not set +# CONFIG_NSH_DISABLE_PRINTF is not set +# CONFIG_NSH_DISABLE_PS is not set +# CONFIG_NSH_DISABLE_PSSTACKUSAGE is not set +# CONFIG_NSH_DISABLE_PWD is not set +# CONFIG_NSH_DISABLE_RM is not set +# CONFIG_NSH_DISABLE_RMDIR is not set +# CONFIG_NSH_DISABLE_SEMICOLON is not set +# CONFIG_NSH_DISABLE_SET is not set +# CONFIG_NSH_DISABLE_SLEEP is not set +# CONFIG_NSH_DISABLE_SOURCE is not set +# CONFIG_NSH_DISABLE_TEST is not set +# CONFIG_NSH_DISABLE_TIME is not set +# CONFIG_NSH_DISABLE_UMOUNT is not set +# CONFIG_NSH_DISABLE_UNSET is not set +# CONFIG_NSH_DISABLE_USLEEP is not set +CONFIG_ARCH="arm" +CONFIG_ARCH_BOARD_CUSTOM=y +CONFIG_ARCH_BOARD_CUSTOM_DIR="../../../../boards/accton-godwit/gfh7/nuttx-config" +CONFIG_ARCH_BOARD_CUSTOM_DIR_RELPATH=y +CONFIG_ARCH_BOARD_CUSTOM_NAME="px4" +CONFIG_ARCH_CHIP="stm32h7" +CONFIG_ARCH_CHIP_STM32H753VI=y +CONFIG_ARCH_CHIP_STM32H7=y +CONFIG_ARCH_CHIP_STM32H7_CORTEXM7=y +CONFIG_ARCH_INTERRUPTSTACK=768 +CONFIG_ARCH_STACKDUMP=y +CONFIG_ARMV7M_BASEPRI_WAR=y +CONFIG_ARMV7M_DCACHE=y +CONFIG_ARMV7M_DTCM=y +CONFIG_ARMV7M_ICACHE=y +CONFIG_ARMV7M_MEMCPY=y +CONFIG_ARM_MPU_EARLY_RESET=y +CONFIG_BOARDCTL_RESET=y +CONFIG_BOARD_ASSERT_RESET_VALUE=0 +CONFIG_BOARD_CRASHDUMP_CUSTOM=y +CONFIG_BOARD_LOOPSPERMSEC=95150 +CONFIG_BOARD_RESET_ON_ASSERT=2 +CONFIG_BUILTIN=y +CONFIG_CDCACM=y +CONFIG_CDCACM_IFLOWCONTROL=y +CONFIG_CDCACM_PRODUCTID=0x1BD2 +CONFIG_CDCACM_PRODUCTSTR="PX4 Accton GFH7" +CONFIG_CDCACM_RXBUFSIZE=600 +CONFIG_CDCACM_TXBUFSIZE=12000 +CONFIG_CDCACM_VENDORID=0x083A +CONFIG_CDCACM_VENDORSTR="Accton" +CONFIG_DEBUG_FULLOPT=y +CONFIG_DEBUG_HARDFAULT_ALERT=y +CONFIG_DEBUG_MEMFAULT=y +CONFIG_DEBUG_SYMBOLS=y +CONFIG_DEFAULT_SMALL=y +CONFIG_DEV_FIFO_SIZE=0 +CONFIG_DEV_PIPE_MAXSIZE=1024 +CONFIG_DEV_PIPE_SIZE=70 +CONFIG_ETC_CROMFS=y +CONFIG_ETC_ROMFS=y +CONFIG_ETC_ROMFSSECTSIZE=128 +CONFIG_EXPERIMENTAL=y +CONFIG_FAT_DMAMEMORY=y +CONFIG_FAT_LCNAMES=y +CONFIG_FAT_LFN=y +CONFIG_FAT_LFN_ALIAS_HASH=y +CONFIG_FDCLONE_STDIO=y +CONFIG_FILE_STREAM=y +CONFIG_FS_BINFS=y +CONFIG_FS_CROMFS=y +CONFIG_FS_FAT=y +CONFIG_FS_FATTIME=y +CONFIG_FS_LARGEFILE=y +CONFIG_FS_PROCFS=y +CONFIG_FS_PROCFS_REGISTER=y +CONFIG_GRAN=y +CONFIG_GRAN_INTR=y +CONFIG_HAVE_CXX=y +CONFIG_HAVE_CXXINITIALIZE=y +CONFIG_I2C=y +CONFIG_I2C_RESET=y +CONFIG_IDLETHREAD_STACKSIZE=750 +CONFIG_INIT_ENTRYPOINT="nsh_main" +CONFIG_INIT_STACKSIZE=3194 +CONFIG_LIBC_FLOATINGPOINT=y +CONFIG_LIBC_LONG_LONG=y +CONFIG_LIBC_MAX_EXITFUNS=1 +CONFIG_LIBC_STRERROR=y +CONFIG_LIBC_STRERROR_SHORT=y +CONFIG_LIBM_TOOLCHAIN=y +CONFIG_LINE_MAX=128 +CONFIG_MMCSD=y +CONFIG_MMCSD_SDIO=y +CONFIG_MMCSD_SDIOWAIT_WRCOMPLETE=y +CONFIG_MM_REGIONS=4 +CONFIG_MTD=y +CONFIG_MTD_BYTE_WRITE=y +CONFIG_MTD_PARTITION=y +CONFIG_MTD_PROGMEM=y +CONFIG_NAME_MAX=40 +CONFIG_NSH_ARCHINIT=y +CONFIG_NSH_ARGCAT=y +CONFIG_NSH_BUILTIN_APPS=y +CONFIG_NSH_MAXARGUMENTS=15 +CONFIG_NSH_NESTDEPTH=8 +CONFIG_NSH_QUOTE=y +CONFIG_NSH_STRERROR=y +CONFIG_NSH_VARS=y +CONFIG_OTG_ID_GPIO_DISABLE=y +CONFIG_PIPES=y +CONFIG_PRIORITY_INHERITANCE=y +CONFIG_PTHREAD_MUTEX_ROBUST=y +CONFIG_PTHREAD_MUTEX_TYPES=y +CONFIG_PTHREAD_STACK_MIN=512 +CONFIG_RAM_SIZE=245760 +CONFIG_RAM_START=0x20010000 +CONFIG_RAW_BINARY=y +CONFIG_READLINE_CMD_HISTORY=y +CONFIG_READLINE_TABCOMPLETION=y +CONFIG_RTC_DATETIME=y +CONFIG_SCHED_HPWORK=y +CONFIG_SCHED_HPWORKPRIORITY=249 +CONFIG_SCHED_HPWORKSTACKSIZE=1280 +CONFIG_SCHED_INSTRUMENTATION=y +CONFIG_SCHED_INSTRUMENTATION_SWITCH=y +CONFIG_SCHED_LPWORK=y +CONFIG_SCHED_LPWORKPRIORITY=50 +CONFIG_SCHED_LPWORKSTACKSIZE=1632 +CONFIG_SCHED_WAITPID=y +CONFIG_SDMMC2_SDIO_PULLUP=y +CONFIG_SEM_PREALLOCHOLDERS=32 +CONFIG_SERIAL_IFLOWCONTROL_WATERMARKS=y +CONFIG_SERIAL_TERMIOS=y +CONFIG_SIG_DEFAULT=y +CONFIG_SIG_SIGALRM_ACTION=y +CONFIG_SIG_SIGUSR1_ACTION=y +CONFIG_SIG_SIGUSR2_ACTION=y +CONFIG_STACK_COLORATION=y +CONFIG_START_DAY=30 +CONFIG_START_MONTH=11 +CONFIG_STDIO_BUFFER_SIZE=256 +CONFIG_STM32H7_ADC1=y +CONFIG_STM32H7_ADC3=y +CONFIG_STM32H7_BBSRAM=y +CONFIG_STM32H7_BBSRAM_FILES=5 +CONFIG_STM32H7_BDMA=y +CONFIG_STM32H7_BKPSRAM=y +CONFIG_STM32H7_DMA1=y +CONFIG_STM32H7_DMA2=y +CONFIG_STM32H7_DMACAPABLE=y +CONFIG_STM32H7_I2C1=y +CONFIG_STM32H7_I2C4=y +CONFIG_STM32H7_I2C_DYNTIMEO=y +CONFIG_STM32H7_I2C_DYNTIMEO_STARTSTOP=10 +CONFIG_STM32H7_OTGFS=y +CONFIG_STM32H7_PROGMEM=y +CONFIG_STM32H7_RTC=y +CONFIG_STM32H7_RTC_HSECLOCK=y +CONFIG_STM32H7_RTC_MAGIC_REG=1 +CONFIG_STM32H7_SAVE_CRASHDUMP=y +CONFIG_STM32H7_SDMMC2=y +CONFIG_STM32H7_SERIALBRK_BSDCOMPAT=y +CONFIG_STM32H7_SERIAL_DISABLE_REORDERING=y +CONFIG_STM32H7_SPI1=y +CONFIG_STM32H7_SPI1_DMA=y +CONFIG_STM32H7_SPI1_DMA_BUFFER=1024 +CONFIG_STM32H7_SPI2=y +CONFIG_STM32H7_SPI2_DMA=y +CONFIG_STM32H7_SPI2_DMA_BUFFER=1024 +CONFIG_STM32H7_SPI4=y +CONFIG_STM32H7_SPI4_DMA=y +CONFIG_STM32H7_SPI4_DMA_BUFFER=1024 +CONFIG_STM32H7_UART4=y +CONFIG_STM32H7_UART5=y +CONFIG_STM32H7_UART7=y +CONFIG_STM32H7_UART8=y +CONFIG_STM32H7_USART1=y +CONFIG_STM32H7_USART2=y +CONFIG_STM32H7_USART3=y +CONFIG_STM32H7_USART_BREAKS=y +CONFIG_STM32H7_USART_INVERT=y +CONFIG_STM32H7_USART_SINGLEWIRE=y +CONFIG_STM32H7_USART_SWAP=y +CONFIG_SYSTEM_CDCACM=y +CONFIG_SYSTEM_NSH=y +CONFIG_TASK_NAME_SIZE=24 +CONFIG_TTY_SIGINT=y +CONFIG_TTY_SIGTSTP=y +CONFIG_UART4_BAUD=57600 +CONFIG_UART4_SERIAL_CONSOLE=y +CONFIG_UART4_RXBUFSIZE=600 +CONFIG_UART4_TXBUFSIZE=1500 +CONFIG_UART5_BAUD=57600 +CONFIG_UART5_RXBUFSIZE=600 +CONFIG_UART5_TXBUFSIZE=1500 +CONFIG_UART7_BAUD=57600 +CONFIG_UART7_RXBUFSIZE=600 +CONFIG_UART7_TXBUFSIZE=1500 +CONFIG_UART8_BAUD=57600 +CONFIG_UART8_RXBUFSIZE=600 +CONFIG_UART8_TXBUFSIZE=1500 +CONFIG_USART1_BAUD=57600 +CONFIG_USART1_RXBUFSIZE=600 +CONFIG_USART1_TXBUFSIZE=32 +CONFIG_USART2_BAUD=57600 +CONFIG_USART2_RXBUFSIZE=600 +CONFIG_USART2_TXBUFSIZE=1500 +CONFIG_USART3_BAUD=57600 +CONFIG_USART3_RXBUFSIZE=600 +CONFIG_USART3_TXBUFSIZE=1500 +CONFIG_USBDEV=y +CONFIG_USBDEV_BUSPOWERED=y +CONFIG_USBDEV_MAXPOWER=500 +CONFIG_USEC_PER_TICK=1000 +CONFIG_WATCHDOG=y diff --git a/boards/accton-godwit/gfh7/nuttx-config/include/board.h b/boards/accton-godwit/gfh7/nuttx-config/include/board.h new file mode 100644 index 00000000000..5920696fc4c --- /dev/null +++ b/boards/accton-godwit/gfh7/nuttx-config/include/board.h @@ -0,0 +1,384 @@ +/************************************************************************************ + * + * Copyright (C) 2026 Accton Technology Corporation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name PX4 nor the names of its contributors may be + * used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + * + ************************************************************************************/ +#pragma once + +#include "board_dma_map.h" + +#include + +#ifndef __ASSEMBLY__ +# include +#endif + +#include "stm32_rcc.h" +#include "stm32_sdmmc.h" + +/* Clocking *************************************************************************/ +/* The Accton Godwit GFH7 provides the following clock sources: + * + * X1: 16 MHz crystal for HSE + * + * So we have these clock source available within the STM32 + * + * HSI: 16 MHz RC factory-trimmed + * HSE: 16 MHz crystal for HSE + */ + +#define STM32_BOARD_XTAL 16000000ul + +#define STM32_HSI_FREQUENCY 16000000ul +#define STM32_LSI_FREQUENCY 32000 +#define STM32_HSE_FREQUENCY STM32_BOARD_XTAL +#define STM32_LSE_FREQUENCY 32768 + +/* Main PLL Configuration. + * + * PLL source is HSE = 16,000,000 + * + * PLL_VCOx = (STM32_HSE_FREQUENCY / PLLM) * PLLN + * Subject to: + * + * 1 <= PLLM <= 63 + * 4 <= PLLN <= 512 + * 150 MHz <= PLL_VCOL <= 420MHz + * 192 MHz <= PLL_VCOH <= 836MHz + * + * SYSCLK = PLL_VCO / PLLP + * CPUCLK = SYSCLK / D1CPRE + * Subject to + * + * PLLP1 = {2, 4, 6, 8, ..., 128} + * PLLP2,3 = {2, 3, 4, ..., 128} + * CPUCLK <= 480 MHz + */ + +#define STM32_BOARD_USEHSE + +#define STM32_PLLCFG_PLLSRC RCC_PLLCKSELR_PLLSRC_HSE + +/* PLL1, wide 4 - 8 MHz input, enable DIVP, DIVQ, DIVR + * + * PLL1_VCO = (16,000,000 / 1) * 60 = 960 MHz + * + * PLL1P = PLL1_VCO/2 = 960 MHz / 2 = 480 MHz + * PLL1Q = PLL1_VCO/4 = 960 MHz / 4 = 240 MHz + * PLL1R = PLL1_VCO/8 = 960 MHz / 8 = 120 MHz + */ + +#define STM32_PLLCFG_PLL1CFG (RCC_PLLCFGR_PLL1VCOSEL_WIDE | \ + RCC_PLLCFGR_PLL1RGE_4_8_MHZ | \ + RCC_PLLCFGR_DIVP1EN | \ + RCC_PLLCFGR_DIVQ1EN | \ + RCC_PLLCFGR_DIVR1EN) +#define STM32_PLLCFG_PLL1M RCC_PLLCKSELR_DIVM1(1) +#define STM32_PLLCFG_PLL1N RCC_PLL1DIVR_N1(60) +#define STM32_PLLCFG_PLL1P RCC_PLL1DIVR_P1(2) +#define STM32_PLLCFG_PLL1Q RCC_PLL1DIVR_Q1(4) +#define STM32_PLLCFG_PLL1R RCC_PLL1DIVR_R1(8) + +#define STM32_VCO1_FREQUENCY ((STM32_HSE_FREQUENCY / 1) * 60) +#define STM32_PLL1P_FREQUENCY (STM32_VCO1_FREQUENCY / 2) +#define STM32_PLL1Q_FREQUENCY (STM32_VCO1_FREQUENCY / 4) +#define STM32_PLL1R_FREQUENCY (STM32_VCO1_FREQUENCY / 8) + +/* PLL2 */ + +#define STM32_PLLCFG_PLL2CFG (RCC_PLLCFGR_PLL2VCOSEL_WIDE | \ + RCC_PLLCFGR_PLL2RGE_4_8_MHZ | \ + RCC_PLLCFGR_DIVP2EN | \ + RCC_PLLCFGR_DIVQ2EN | \ + RCC_PLLCFGR_DIVR2EN) +#define STM32_PLLCFG_PLL2M RCC_PLLCKSELR_DIVM2(4) +#define STM32_PLLCFG_PLL2N RCC_PLL2DIVR_N2(48) +#define STM32_PLLCFG_PLL2P RCC_PLL2DIVR_P2(2) +#define STM32_PLLCFG_PLL2Q RCC_PLL2DIVR_Q2(2) +#define STM32_PLLCFG_PLL2R RCC_PLL2DIVR_R2(2) + +#define STM32_VCO2_FREQUENCY ((STM32_HSE_FREQUENCY / 4) * 48) +#define STM32_PLL2P_FREQUENCY (STM32_VCO2_FREQUENCY / 2) +#define STM32_PLL2Q_FREQUENCY (STM32_VCO2_FREQUENCY / 2) +#define STM32_PLL2R_FREQUENCY (STM32_VCO2_FREQUENCY / 2) + +/* PLL3 */ + +#define STM32_PLLCFG_PLL3CFG (RCC_PLLCFGR_PLL3VCOSEL_WIDE | \ + RCC_PLLCFGR_PLL3RGE_4_8_MHZ | \ + RCC_PLLCFGR_DIVQ3EN) +#define STM32_PLLCFG_PLL3M RCC_PLLCKSELR_DIVM3(4) +#define STM32_PLLCFG_PLL3N RCC_PLL3DIVR_N3(48) +#define STM32_PLLCFG_PLL3P RCC_PLL3DIVR_P3(2) +#define STM32_PLLCFG_PLL3Q RCC_PLL3DIVR_Q3(4) +#define STM32_PLLCFG_PLL3R RCC_PLL3DIVR_R3(2) + +#define STM32_VCO3_FREQUENCY ((STM32_HSE_FREQUENCY / 4) * 48) +#define STM32_PLL3P_FREQUENCY (STM32_VCO3_FREQUENCY / 2) +#define STM32_PLL3Q_FREQUENCY (STM32_VCO3_FREQUENCY / 4) +#define STM32_PLL3R_FREQUENCY (STM32_VCO3_FREQUENCY / 2) + +/* SYSCLK = PLL1P = 480MHz + * CPUCLK = SYSCLK / 1 = 480 MHz + */ + +#define STM32_RCC_D1CFGR_D1CPRE (RCC_D1CFGR_D1CPRE_SYSCLK) +#define STM32_SYSCLK_FREQUENCY (STM32_PLL1P_FREQUENCY) +#define STM32_CPUCLK_FREQUENCY (STM32_SYSCLK_FREQUENCY / 1) + +/* Configure Clock Assignments */ + +/* AHB clock (HCLK) is SYSCLK/2 (240 MHz max) + * HCLK1 = HCLK2 = HCLK3 = HCLK4 = 240 + */ + +#define STM32_RCC_D1CFGR_HPRE RCC_D1CFGR_HPRE_SYSCLKd2 /* HCLK = SYSCLK / 2 */ +#define STM32_ACLK_FREQUENCY (STM32_CPUCLK_FREQUENCY / 2) /* ACLK in D1, HCLK3 in D1 */ +#define STM32_HCLK_FREQUENCY (STM32_CPUCLK_FREQUENCY / 2) /* HCLK in D2, HCLK4 in D3 */ +#define STM32_BOARD_HCLK STM32_HCLK_FREQUENCY /* same as above, to satisfy compiler */ + +/* APB1 clock (PCLK1) is HCLK/2 (120 MHz) */ + +#define STM32_RCC_D2CFGR_D2PPRE1 RCC_D2CFGR_D2PPRE1_HCLKd2 /* PCLK1 = HCLK / 2 */ +#define STM32_PCLK1_FREQUENCY (STM32_HCLK_FREQUENCY/2) + +/* APB2 clock (PCLK2) is HCLK/2 (120 MHz) */ + +#define STM32_RCC_D2CFGR_D2PPRE2 RCC_D2CFGR_D2PPRE2_HCLKd2 /* PCLK2 = HCLK / 2 */ +#define STM32_PCLK2_FREQUENCY (STM32_HCLK_FREQUENCY/2) + +/* APB3 clock (PCLK3) is HCLK/2 (120 MHz) */ + +#define STM32_RCC_D1CFGR_D1PPRE RCC_D1CFGR_D1PPRE_HCLKd2 /* PCLK3 = HCLK / 2 */ +#define STM32_PCLK3_FREQUENCY (STM32_HCLK_FREQUENCY/2) + +/* APB4 clock (PCLK4) is HCLK/2 (120 MHz) */ + +#define STM32_RCC_D3CFGR_D3PPRE RCC_D3CFGR_D3PPRE_HCLKd2 /* PCLK4 = HCLK / 2 */ +#define STM32_PCLK4_FREQUENCY (STM32_HCLK_FREQUENCY/2) + +/* Timer clock frequencies */ + +/* Timers driven from APB1 will be twice PCLK1 */ + +#define STM32_APB1_TIM2_CLKIN (2*STM32_PCLK1_FREQUENCY) +#define STM32_APB1_TIM3_CLKIN (2*STM32_PCLK1_FREQUENCY) +#define STM32_APB1_TIM4_CLKIN (2*STM32_PCLK1_FREQUENCY) +#define STM32_APB1_TIM5_CLKIN (2*STM32_PCLK1_FREQUENCY) +#define STM32_APB1_TIM6_CLKIN (2*STM32_PCLK1_FREQUENCY) +#define STM32_APB1_TIM7_CLKIN (2*STM32_PCLK1_FREQUENCY) +#define STM32_APB1_TIM12_CLKIN (2*STM32_PCLK1_FREQUENCY) +#define STM32_APB1_TIM13_CLKIN (2*STM32_PCLK1_FREQUENCY) +#define STM32_APB1_TIM14_CLKIN (2*STM32_PCLK1_FREQUENCY) + +/* Timers driven from APB2 will be twice PCLK2 */ + +#define STM32_APB2_TIM1_CLKIN (2*STM32_PCLK2_FREQUENCY) +#define STM32_APB2_TIM8_CLKIN (2*STM32_PCLK2_FREQUENCY) +#define STM32_APB2_TIM15_CLKIN (2*STM32_PCLK2_FREQUENCY) +#define STM32_APB2_TIM16_CLKIN (2*STM32_PCLK2_FREQUENCY) +#define STM32_APB2_TIM17_CLKIN (2*STM32_PCLK2_FREQUENCY) + +/* Kernel Clock Configuration */ + +/* I2C123 clock source */ + +#define STM32_RCC_D2CCIP2R_I2C123SRC RCC_D2CCIP2R_I2C123SEL_HSI + +/* I2C4 clock source */ + +#define STM32_RCC_D3CCIPR_I2C4SRC RCC_D3CCIPR_I2C4SEL_HSI + +/* SPI123 clock source */ + +#define STM32_RCC_D2CCIP1R_SPI123SRC RCC_D2CCIP1R_SPI123SEL_PLL2 + +/* SPI45 clock source */ + +#define STM32_RCC_D2CCIP1R_SPI45SRC RCC_D2CCIP1R_SPI45SEL_PLL2 + +/* SPI6 clock source */ + +#define STM32_RCC_D3CCIPR_SPI6SRC RCC_D3CCIPR_SPI6SEL_PLL2 + +/* USB 1 and 2 clock source */ + +#define STM32_RCC_D2CCIP2R_USBSRC RCC_D2CCIP2R_USBSEL_PLL3 + +/* ADC 1 2 3 clock source */ + +#define STM32_RCC_D3CCIPR_ADCSRC RCC_D3CCIPR_ADCSEL_PLL2 + +/* FDCAN 1 2 clock source */ + +#define STM32_RCC_D2CCIP1R_FDCANSEL RCC_D2CCIP1R_FDCANSEL_HSE + +#define STM32_FDCANCLK STM32_HSE_FREQUENCY + +/* FLASH wait states */ + +#define BOARD_FLASH_WAITSTATES 2 + +/* SDMMC definitions ********************************************************/ + +/* Init 400kHz, freq = PLL1Q/(2*div) div = PLL1Q/(2*freq) */ + +#define STM32_SDMMC_INIT_CLKDIV (300 << STM32_SDMMC_CLKCR_CLKDIV_SHIFT) + +/* 25 MHz Max for now, 25 mHZ = PLL1Q/(2*div), div = PLL1Q/(2*freq) + * div = 4.8 = 240 / 50, So round up to 5 for default speed 24 MB/s + */ + +#if defined(CONFIG_STM32H7_SDMMC_XDMA) || defined(CONFIG_STM32H7_SDMMC_IDMA) +# define STM32_SDMMC_MMCXFR_CLKDIV (5 << STM32_SDMMC_CLKCR_CLKDIV_SHIFT) +#else +# define STM32_SDMMC_MMCXFR_CLKDIV (100 << STM32_SDMMC_CLKCR_CLKDIV_SHIFT) +#endif +#if defined(CONFIG_STM32H7_SDMMC_XDMA) || defined(CONFIG_STM32H7_SDMMC_IDMA) +# define STM32_SDMMC_SDXFR_CLKDIV (5 << STM32_SDMMC_CLKCR_CLKDIV_SHIFT) +#else +# define STM32_SDMMC_SDXFR_CLKDIV (100 << STM32_SDMMC_CLKCR_CLKDIV_SHIFT) +#endif + +#define STM32_SDMMC_CLKCR_EDGE STM32_SDMMC_CLKCR_NEGEDGE + +/* LED definitions ******************************************************************/ + +/* LED index values for use with board_userled() */ + +#define BOARD_LED1 0 +#define BOARD_LED2 1 +#define BOARD_NLEDS 2 + +#define BOARD_LED_GREEN BOARD_LED1 +#define BOARD_LED_BLUE BOARD_LED2 + +/* LED bits for use with board_userled_all() */ + +#define BOARD_LED1_BIT (1 << BOARD_LED1) +#define BOARD_LED2_BIT (1 << BOARD_LED2) + +/* If CONFIG_ARCH_LEDS is defined, the usage by the board port is defined in + * include/board.h and src/stm32_leds.c. The LEDs are used to encode OS-related + * events as follows: + */ + +#define LED_STARTED 0 /* NuttX has been started OFF */ +#define LED_HEAPALLOCATE 1 /* Heap has been allocated OFF */ +#define LED_IRQSENABLED 2 /* Interrupts enabled OFF */ +#define LED_STACKCREATED 3 /* Idle stack created ON */ +#define LED_INIRQ 4 /* In an interrupt N/C */ +#define LED_SIGNAL 5 /* In a signal handler N/C */ +#define LED_ASSERTION 6 /* An assertion failed GLOW */ +#define LED_PANIC 7 /* The system has crashed Blink */ +#define LED_IDLE 8 /* MCU is in sleep mode ON */ + +/* Alternate function pin selections ************************************************/ + +#define GPIO_USART1_TX 0 /* RX-only ESC telemetry */ +#define GPIO_USART1_RX GPIO_USART1_RX_2 /* PA10 */ + +#define GPIO_USART2_TX GPIO_USART2_TX_2 /* PD5 */ +#define GPIO_USART2_RX GPIO_USART2_RX_1 /* PA3 */ + +#define GPIO_USART3_TX GPIO_USART3_TX_3 /* PD8 */ +#define GPIO_USART3_RX GPIO_USART3_RX_3 /* PD9 */ + +#define GPIO_UART4_TX GPIO_UART4_TX_4 /* PC10 */ +#define GPIO_UART4_RX GPIO_UART4_RX_4 /* PC11 */ + +#define GPIO_UART5_TX GPIO_UART5_TX_2 /* PB6 */ +#define GPIO_UART5_RX GPIO_UART5_RX_3 /* PD2 */ + +#define GPIO_UART7_TX GPIO_UART7_TX_3 /* PE8 */ +#define GPIO_UART7_RX GPIO_UART7_RX_3 /* PE7 */ + +#define GPIO_UART8_TX GPIO_UART8_TX_1 /* PE1 */ +#define GPIO_UART8_RX GPIO_UART8_RX_1 /* PE0 */ + +/* CAN */ + +#define GPIO_CAN1_RX GPIO_CAN1_RX_3 /* PD0 */ +#define GPIO_CAN1_TX GPIO_CAN1_TX_3 /* PD1 */ + +/* SPI */ + +#define GPIO_SPI1_SCK GPIO_SPI1_SCK_1 /* PA5 */ +#define GPIO_SPI1_MISO GPIO_SPI1_MISO_1 /* PA6 */ +#define GPIO_SPI1_MOSI GPIO_SPI1_MOSI_3 /* PD7 */ + +#define GPIO_SPI2_SCK GPIO_SPI2_SCK_5 /* PD3 */ +#define GPIO_SPI2_MISO GPIO_SPI2_MISO_2 /* PC2 */ +#define GPIO_SPI2_MOSI GPIO_SPI2_MOSI_3 /* PC3 */ + +#define GPIO_SPI4_SCK GPIO_SPI4_SCK_2 /* PE2 */ +#define GPIO_SPI4_MISO GPIO_SPI4_MISO_2 /* PE5 */ +#define GPIO_SPI4_MOSI GPIO_SPI4_MOSI_2 /* PE6 */ + +/* I2C */ + +#define GPIO_I2C1_SCL GPIO_I2C1_SCL_2 /* PB8 */ +#define GPIO_I2C1_SDA GPIO_I2C1_SDA_1 /* PB7 */ + +#define GPIO_I2C1_SCL_GPIO (GPIO_OUTPUT | GPIO_OPENDRAIN |GPIO_SPEED_50MHz | GPIO_OUTPUT_SET | GPIO_PORTB | GPIO_PIN8) +#define GPIO_I2C1_SDA_GPIO (GPIO_OUTPUT | GPIO_OPENDRAIN |GPIO_SPEED_50MHz | GPIO_OUTPUT_SET | GPIO_PORTB | GPIO_PIN7) + +#define GPIO_I2C4_SCL GPIO_I2C4_SCL_1 /* PD12 */ +#define GPIO_I2C4_SDA GPIO_I2C4_SDA_1 /* PD13 */ + +#define GPIO_I2C4_SCL_GPIO (GPIO_OUTPUT | GPIO_OPENDRAIN | GPIO_SPEED_50MHz | GPIO_OUTPUT_SET | GPIO_PORTD | GPIO_PIN12) +#define GPIO_I2C4_SDA_GPIO (GPIO_OUTPUT | GPIO_OPENDRAIN | GPIO_SPEED_50MHz | GPIO_OUTPUT_SET | GPIO_PORTD | GPIO_PIN13) + +/* SDMMC2 + * + * SDMMC2_CK PD6 + * SDMMC2_CMD PA0 + * SDMMC2_D0 PB14 + * SDMMC2_D1 PB15 + * SDMMC2_D2 PB3 + * SDMMC2_D3 PB4 + */ + +#define GPIO_SDMMC2_CK GPIO_SDMMC2_CK_1 /* PD6 */ +#define GPIO_SDMMC2_CMD GPIO_SDMMC2_CMD_2 /* PA0 */ +#define GPIO_SDMMC2_D2 GPIO_SDMMC2_D2_2 /* PB3 */ + +/* USB + * + * OTG_FS_DM PA11 + * OTG_FS_DP PA12 + * VBUS PA9 (not sensed, R114 not fitted) + */ + +/* Board provides GPIO or other Hardware for signaling to timing analyzer */ + +#define PROBE_INIT(mask) +#define PROBE(n,s) +#define PROBE_MARK(n) diff --git a/boards/accton-godwit/gfh7/nuttx-config/include/board_dma_map.h b/boards/accton-godwit/gfh7/nuttx-config/include/board_dma_map.h new file mode 100644 index 00000000000..17c6177a7b7 --- /dev/null +++ b/boards/accton-godwit/gfh7/nuttx-config/include/board_dma_map.h @@ -0,0 +1,46 @@ +/**************************************************************************** + * + * Copyright (C) 2026 Accton Technology Corporation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name PX4 nor the names of its contributors may be + * used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + * + ****************************************************************************/ + +#pragma once + +// DMAMUX1 + +#define DMAMAP_SPI1_RX DMAMAP_DMA12_SPI1RX_1 /* DMA2: OSD */ +#define DMAMAP_SPI1_TX DMAMAP_DMA12_SPI1TX_1 /* DMA2: OSD */ +#define DMAMAP_SPI2_RX DMAMAP_DMA12_SPI2RX_1 /* DMA2: LSM6DSK320X */ +#define DMAMAP_SPI2_TX DMAMAP_DMA12_SPI2TX_1 /* DMA2: LSM6DSK320X */ +#define DMAMAP_SPI4_RX DMAMAP_DMA12_SPI4RX_1 /* DMA2 */ +#define DMAMAP_SPI4_TX DMAMAP_DMA12_SPI4TX_1 /* DMA2 */ + +#define DMAMAP_UART7_RX DMAMAP_DMA12_UART7RX_1 /* DMA2: TEL1 bootloader */ +#define DMAMAP_UART7_TX DMAMAP_DMA12_UART7TX_1 /* DMA2: TEL1 bootloader */ diff --git a/boards/accton-godwit/gfh7/nuttx-config/nsh/defconfig b/boards/accton-godwit/gfh7/nuttx-config/nsh/defconfig new file mode 100644 index 00000000000..dc258cf4316 --- /dev/null +++ b/boards/accton-godwit/gfh7/nuttx-config/nsh/defconfig @@ -0,0 +1,259 @@ +# +# This file is autogenerated: PLEASE DO NOT EDIT IT. +# +# You can use "make menuconfig" to make any modifications to the installed .config file. +# You can then do "make savedefconfig" to generate a new defconfig file that includes your +# modifications. +# +# CONFIG_DISABLE_ENVIRON is not set +# CONFIG_DISABLE_PSEUDOFS_OPERATIONS is not set +# CONFIG_DISABLE_PTHREAD is not set +# CONFIG_FS_PROCFS_EXCLUDE_BLOCKS is not set +# CONFIG_FS_PROCFS_EXCLUDE_MEMINFO is not set +# CONFIG_FS_PROCFS_EXCLUDE_MOUNT is not set +# CONFIG_FS_PROCFS_EXCLUDE_USAGE is not set +# CONFIG_LIBC_GAISTRERROR_ERRNUM is not set +# CONFIG_LIBC_STRFTIME_C_STANDARD_FORMATS is not set +# CONFIG_LIBC_STRFTIME_NONSTANDARD_FORMATS is not set +# CONFIG_MMCSD_HAVE_CARDDETECT is not set +# CONFIG_MMCSD_HAVE_WRITEPROTECT is not set +# CONFIG_MMCSD_IOCSUPPORT is not set +# CONFIG_MMCSD_MMCSUPPORT is not set +# CONFIG_MMCSD_SPI is not set +# CONFIG_NSH_DISABLEBG is not set +# CONFIG_NSH_DISABLESCRIPT is not set +# CONFIG_NSH_DISABLE_ARP is not set +# CONFIG_NSH_DISABLE_CAT is not set +# CONFIG_NSH_DISABLE_CD is not set +# CONFIG_NSH_DISABLE_CP is not set +# CONFIG_NSH_DISABLE_DATE is not set +# CONFIG_NSH_DISABLE_DF is not set +# CONFIG_NSH_DISABLE_ECHO is not set +# CONFIG_NSH_DISABLE_ENV is not set +# CONFIG_NSH_DISABLE_ERROR_PRINT is not set +# CONFIG_NSH_DISABLE_EXEC is not set +# CONFIG_NSH_DISABLE_EXIT is not set +# CONFIG_NSH_DISABLE_EXPORT is not set +# CONFIG_NSH_DISABLE_FREE is not set +# CONFIG_NSH_DISABLE_GET is not set +# CONFIG_NSH_DISABLE_IFCONFIG is not set +# CONFIG_NSH_DISABLE_IFUPDOWN is not set +# CONFIG_NSH_DISABLE_ITEF is not set +# CONFIG_NSH_DISABLE_KILL is not set +# CONFIG_NSH_DISABLE_LOOPS is not set +# CONFIG_NSH_DISABLE_LS is not set +# CONFIG_NSH_DISABLE_MKDIR is not set +# CONFIG_NSH_DISABLE_MKFATFS is not set +# CONFIG_NSH_DISABLE_MOUNT is not set +# CONFIG_NSH_DISABLE_MV is not set +# CONFIG_NSH_DISABLE_PRINTF is not set +# CONFIG_NSH_DISABLE_PS is not set +# CONFIG_NSH_DISABLE_PSSTACKUSAGE is not set +# CONFIG_NSH_DISABLE_PWD is not set +# CONFIG_NSH_DISABLE_RM is not set +# CONFIG_NSH_DISABLE_RMDIR is not set +# CONFIG_NSH_DISABLE_SEMICOLON is not set +# CONFIG_NSH_DISABLE_SET is not set +# CONFIG_NSH_DISABLE_SLEEP is not set +# CONFIG_NSH_DISABLE_SOURCE is not set +# CONFIG_NSH_DISABLE_TEST is not set +# CONFIG_NSH_DISABLE_TIME is not set +# CONFIG_NSH_DISABLE_UMOUNT is not set +# CONFIG_NSH_DISABLE_UNSET is not set +# CONFIG_NSH_DISABLE_USLEEP is not set +# CONFIG_DEV_CONSOLE is not set +CONFIG_ARCH="arm" +CONFIG_ARCH_BOARD_CUSTOM=y +CONFIG_ARCH_BOARD_CUSTOM_DIR="../../../../boards/accton-godwit/gfh7/nuttx-config" +CONFIG_ARCH_BOARD_CUSTOM_DIR_RELPATH=y +CONFIG_ARCH_BOARD_CUSTOM_NAME="px4" +CONFIG_ARCH_CHIP="stm32h7" +CONFIG_ARCH_CHIP_STM32H753VI=y +CONFIG_ARCH_CHIP_STM32H7=y +CONFIG_ARCH_CHIP_STM32H7_CORTEXM7=y +CONFIG_ARCH_INTERRUPTSTACK=768 +CONFIG_ARCH_STACKDUMP=y +CONFIG_ARMV7M_BASEPRI_WAR=y +CONFIG_ARMV7M_DCACHE=y +CONFIG_ARMV7M_DTCM=y +CONFIG_ARMV7M_ICACHE=y +CONFIG_ARMV7M_MEMCPY=y +CONFIG_ARM_MPU_EARLY_RESET=y +CONFIG_BOARDCTL_RESET=y +CONFIG_BOARD_ASSERT_RESET_VALUE=0 +CONFIG_BOARD_CRASHDUMP_CUSTOM=y +CONFIG_BOARD_LOOPSPERMSEC=95150 +CONFIG_BOARD_RESET_ON_ASSERT=2 +CONFIG_BUILTIN=y +CONFIG_CDCACM=y +CONFIG_CDCACM_IFLOWCONTROL=y +CONFIG_CDCACM_PRODUCTID=0x1BD2 +CONFIG_CDCACM_PRODUCTSTR="PX4 Accton GFH7" +CONFIG_CDCACM_RXBUFSIZE=600 +CONFIG_CDCACM_TXBUFSIZE=12000 +CONFIG_CDCACM_VENDORID=0x083A +CONFIG_CDCACM_VENDORSTR="Accton" +CONFIG_DEBUG_FULLOPT=y +CONFIG_DEBUG_HARDFAULT_ALERT=y +CONFIG_DEBUG_MEMFAULT=y +CONFIG_DEBUG_SYMBOLS=y +CONFIG_DEFAULT_SMALL=y +CONFIG_DEV_FIFO_SIZE=0 +CONFIG_DEV_PIPE_MAXSIZE=1024 +CONFIG_DEV_PIPE_SIZE=70 +CONFIG_ETC_CROMFS=y +CONFIG_ETC_ROMFS=y +CONFIG_ETC_ROMFSSECTSIZE=128 +CONFIG_EXPERIMENTAL=y +CONFIG_FAT_DMAMEMORY=y +CONFIG_FAT_LCNAMES=y +CONFIG_FAT_LFN=y +CONFIG_FAT_LFN_ALIAS_HASH=y +CONFIG_FDCLONE_STDIO=y +CONFIG_FILE_STREAM=y +CONFIG_FS_BINFS=y +CONFIG_FS_CROMFS=y +CONFIG_FS_FAT=y +CONFIG_FS_FATTIME=y +CONFIG_FS_LARGEFILE=y +CONFIG_FS_PROCFS=y +CONFIG_FS_PROCFS_REGISTER=y +CONFIG_GRAN=y +CONFIG_GRAN_INTR=y +CONFIG_HAVE_CXX=y +CONFIG_HAVE_CXXINITIALIZE=y +CONFIG_I2C=y +CONFIG_I2C_RESET=y +CONFIG_IDLETHREAD_STACKSIZE=750 +CONFIG_INIT_ENTRYPOINT="nsh_main" +CONFIG_INIT_STACKSIZE=3194 +CONFIG_LIBC_FLOATINGPOINT=y +CONFIG_LIBC_LONG_LONG=y +CONFIG_LIBC_MAX_EXITFUNS=1 +CONFIG_LIBC_STRERROR=y +CONFIG_LIBC_STRERROR_SHORT=y +CONFIG_LIBM_TOOLCHAIN=y +CONFIG_LINE_MAX=128 +CONFIG_MMCSD=y +CONFIG_MMCSD_SDIO=y +CONFIG_MMCSD_SDIOWAIT_WRCOMPLETE=y +CONFIG_MM_REGIONS=4 +CONFIG_MTD=y +CONFIG_MTD_BYTE_WRITE=y +CONFIG_MTD_PARTITION=y +CONFIG_MTD_PROGMEM=y +CONFIG_NAME_MAX=40 +CONFIG_NSH_ARCHINIT=y +CONFIG_NSH_ARGCAT=y +CONFIG_NSH_BUILTIN_APPS=y +CONFIG_NSH_MAXARGUMENTS=15 +CONFIG_NSH_NESTDEPTH=8 +CONFIG_NSH_QUOTE=y +CONFIG_NSH_STRERROR=y +CONFIG_NSH_VARS=y +CONFIG_OTG_ID_GPIO_DISABLE=y +CONFIG_PIPES=y +CONFIG_PRIORITY_INHERITANCE=y +CONFIG_PTHREAD_MUTEX_ROBUST=y +CONFIG_PTHREAD_MUTEX_TYPES=y +CONFIG_PTHREAD_STACK_MIN=512 +CONFIG_RAM_SIZE=245760 +CONFIG_RAM_START=0x20010000 +CONFIG_RAW_BINARY=y +CONFIG_READLINE_CMD_HISTORY=y +CONFIG_READLINE_TABCOMPLETION=y +CONFIG_RTC_DATETIME=y +CONFIG_SCHED_HPWORK=y +CONFIG_SCHED_HPWORKPRIORITY=249 +CONFIG_SCHED_HPWORKSTACKSIZE=1280 +CONFIG_SCHED_INSTRUMENTATION=y +CONFIG_SCHED_INSTRUMENTATION_SWITCH=y +CONFIG_SCHED_LPWORK=y +CONFIG_SCHED_LPWORKPRIORITY=50 +CONFIG_SCHED_LPWORKSTACKSIZE=1632 +CONFIG_SCHED_WAITPID=y +CONFIG_SDMMC2_SDIO_PULLUP=y +CONFIG_SEM_PREALLOCHOLDERS=32 +CONFIG_SERIAL_IFLOWCONTROL_WATERMARKS=y +CONFIG_SERIAL_TERMIOS=y +CONFIG_SIG_DEFAULT=y +CONFIG_SIG_SIGALRM_ACTION=y +CONFIG_SIG_SIGUSR1_ACTION=y +CONFIG_SIG_SIGUSR2_ACTION=y +CONFIG_STACK_COLORATION=y +CONFIG_START_DAY=30 +CONFIG_START_MONTH=11 +CONFIG_STDIO_BUFFER_SIZE=256 +CONFIG_STM32H7_ADC1=y +CONFIG_STM32H7_ADC3=y +CONFIG_STM32H7_BBSRAM=y +CONFIG_STM32H7_BBSRAM_FILES=5 +CONFIG_STM32H7_BDMA=y +CONFIG_STM32H7_BKPSRAM=y +CONFIG_STM32H7_DMA1=y +CONFIG_STM32H7_DMA2=y +CONFIG_STM32H7_DMACAPABLE=y +CONFIG_STM32H7_I2C1=y +CONFIG_STM32H7_I2C4=y +CONFIG_STM32H7_I2C_DYNTIMEO=y +CONFIG_STM32H7_I2C_DYNTIMEO_STARTSTOP=10 +CONFIG_STM32H7_OTGFS=y +CONFIG_STM32H7_PROGMEM=y +CONFIG_STM32H7_RTC=y +CONFIG_STM32H7_RTC_HSECLOCK=y +CONFIG_STM32H7_RTC_MAGIC_REG=1 +CONFIG_STM32H7_SAVE_CRASHDUMP=y +CONFIG_STM32H7_SDMMC2=y +CONFIG_STM32H7_SERIALBRK_BSDCOMPAT=y +CONFIG_STM32H7_SERIAL_DISABLE_REORDERING=y +CONFIG_STM32H7_SPI1=y +CONFIG_STM32H7_SPI1_DMA=y +CONFIG_STM32H7_SPI1_DMA_BUFFER=1024 +CONFIG_STM32H7_SPI2=y +CONFIG_STM32H7_SPI2_DMA=y +CONFIG_STM32H7_SPI2_DMA_BUFFER=1024 +CONFIG_STM32H7_SPI4=y +CONFIG_STM32H7_SPI4_DMA=y +CONFIG_STM32H7_SPI4_DMA_BUFFER=1024 +CONFIG_STM32H7_UART4=y +CONFIG_STM32H7_UART5=y +CONFIG_STM32H7_UART7=y +CONFIG_STM32H7_UART8=y +CONFIG_STM32H7_USART1=y +CONFIG_STM32H7_USART2=y +CONFIG_STM32H7_USART3=y +CONFIG_STM32H7_USART_BREAKS=y +CONFIG_STM32H7_USART_INVERT=y +CONFIG_STM32H7_USART_SINGLEWIRE=y +CONFIG_STM32H7_USART_SWAP=y +CONFIG_SYSTEM_CDCACM=y +CONFIG_SYSTEM_NSH=y +CONFIG_TASK_NAME_SIZE=24 +CONFIG_TTY_SIGINT=y +CONFIG_TTY_SIGTSTP=y +CONFIG_UART4_BAUD=57600 +CONFIG_UART4_RXBUFSIZE=600 +CONFIG_UART4_TXBUFSIZE=1500 +CONFIG_UART5_BAUD=57600 +CONFIG_UART5_RXBUFSIZE=600 +CONFIG_UART5_TXBUFSIZE=1500 +CONFIG_UART7_BAUD=57600 +CONFIG_UART7_RXBUFSIZE=600 +CONFIG_UART7_TXBUFSIZE=1500 +CONFIG_UART8_BAUD=57600 +CONFIG_UART8_RXBUFSIZE=600 +CONFIG_UART8_TXBUFSIZE=1500 +CONFIG_USART1_BAUD=57600 +CONFIG_USART1_RXBUFSIZE=600 +CONFIG_USART1_TXBUFSIZE=32 +CONFIG_USART2_BAUD=57600 +CONFIG_USART2_RXBUFSIZE=600 +CONFIG_USART2_TXBUFSIZE=1500 +CONFIG_USART3_BAUD=57600 +CONFIG_USART3_RXBUFSIZE=600 +CONFIG_USART3_TXBUFSIZE=1500 +CONFIG_USBDEV=y +CONFIG_USBDEV_BUSPOWERED=y +CONFIG_USBDEV_MAXPOWER=500 +CONFIG_USEC_PER_TICK=1000 +CONFIG_WATCHDOG=y diff --git a/boards/accton-godwit/gfh7/nuttx-config/scripts/bootloader_script.ld b/boards/accton-godwit/gfh7/nuttx-config/scripts/bootloader_script.ld new file mode 100644 index 00000000000..faa61f0f31e --- /dev/null +++ b/boards/accton-godwit/gfh7/nuttx-config/scripts/bootloader_script.ld @@ -0,0 +1,142 @@ +/**************************************************************************** + * scripts/bootloader_script.ld + * + * Copyright (C) 2026 Accton Technology Corporation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name NuttX nor the names of its contributors may be + * used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + * + ****************************************************************************/ + +/* The Accton Godwit GFH7 uses an STM32H753VI with 2048Kb of main FLASH. + * The bootloader uses the first sector of flash, which is 128K in length. + */ + +MEMORY +{ + itcm (rwx) : ORIGIN = 0x00000000, LENGTH = 64K + flash (rx) : ORIGIN = 0x08000000, LENGTH = 128K + dtcm1 (rwx) : ORIGIN = 0x20000000, LENGTH = 64K + dtcm2 (rwx) : ORIGIN = 0x20010000, LENGTH = 64K + sram (rwx) : ORIGIN = 0x24000000, LENGTH = 512K + sram1 (rwx) : ORIGIN = 0x30000000, LENGTH = 128K + sram2 (rwx) : ORIGIN = 0x30020000, LENGTH = 128K + sram3 (rwx) : ORIGIN = 0x30040000, LENGTH = 32K + sram4 (rwx) : ORIGIN = 0x38000000, LENGTH = 64K + bbram (rwx) : ORIGIN = 0x38800000, LENGTH = 4K +} + +OUTPUT_ARCH(arm) +EXTERN(_vectors) +ENTRY(_stext) + +/* + * Ensure that abort() is present in the final object. The exception handling + * code pulled in by libgcc.a requires it (and that code cannot be easily avoided). + */ +EXTERN(abort) +EXTERN(_bootdelay_signature) + +SECTIONS +{ + .text : { + _stext = ABSOLUTE(.); + *(.vectors) + . = ALIGN(32); + /* + This signature provides the bootloader with a way to delay booting + */ + _bootdelay_signature = ABSOLUTE(.); + FILL(0xffecc2925d7d05c5) + . += 8; + *(.text .text.*) + *(.fixup) + *(.gnu.warning) + *(.rodata .rodata.*) + *(.gnu.linkonce.t.*) + *(.glue_7) + *(.glue_7t) + *(.got) + *(.gcc_except_table) + *(.gnu.linkonce.r.*) + _etext = ABSOLUTE(.); + + } > flash + + /* + * Init functions (static constructors and the like) + */ + .init_section : { + _sinit = ABSOLUTE(.); + KEEP(*(.init_array .init_array.*)) + _einit = ABSOLUTE(.); + } > flash + + + .ARM.extab : { + *(.ARM.extab*) + } > flash + + __exidx_start = ABSOLUTE(.); + .ARM.exidx : { + *(.ARM.exidx*) + } > flash + __exidx_end = ABSOLUTE(.); + + _eronly = ABSOLUTE(.); + + .data : { + _sdata = ABSOLUTE(.); + *(.data .data.*) + *(.gnu.linkonce.d.*) + CONSTRUCTORS + _edata = ABSOLUTE(.); + } > sram AT > flash + + .bss : { + _sbss = ABSOLUTE(.); + *(.bss .bss.*) + *(.gnu.linkonce.b.*) + *(COMMON) + . = ALIGN(4); + _ebss = ABSOLUTE(.); + } > sram + + /* Stabs debugging sections. */ + .stab 0 : { *(.stab) } + .stabstr 0 : { *(.stabstr) } + .stab.excl 0 : { *(.stab.excl) } + .stab.exclstr 0 : { *(.stab.exclstr) } + .stab.index 0 : { *(.stab.index) } + .stab.indexstr 0 : { *(.stab.indexstr) } + .comment 0 : { *(.comment) } + .debug_abbrev 0 : { *(.debug_abbrev) } + .debug_info 0 : { *(.debug_info) } + .debug_line 0 : { *(.debug_line) } + .debug_pubnames 0 : { *(.debug_pubnames) } + .debug_aranges 0 : { *(.debug_aranges) } +} diff --git a/boards/accton-godwit/gfh7/nuttx-config/scripts/script.ld b/boards/accton-godwit/gfh7/nuttx-config/scripts/script.ld new file mode 100644 index 00000000000..961c903b6ec --- /dev/null +++ b/boards/accton-godwit/gfh7/nuttx-config/scripts/script.ld @@ -0,0 +1,172 @@ +/**************************************************************************** + * scripts/script.ld + * + * Copyright (C) 2026 Accton Technology Corporation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name NuttX nor the names of its contributors may be + * used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + * + ****************************************************************************/ + +/* The Accton Godwit GFH7 uses an STM32H753VI with 2048Kb of main FLASH. + * The flash memory is partitioned into 16 sectors of 128Kb each: + * + * Sector 0 (128K): Bootloader + * Sectors 1-14 (1792K): Firmware + * Sector 15 (128K): Flash-based parameter storage + * + * The STM32H753VI has 1024Kb of data SRAM: + * + * 128Kb DTCM-RAM at 0x20000000 + * 64Kb ITCM-RAM at 0x00000000 + * 512Kb AXI SRAM at 0x24000000 + * 128Kb SRAM1 at 0x30000000 + * 128Kb SRAM2 at 0x30020000 + * 32Kb SRAM3 at 0x30040000 + * 64Kb SRAM4 at 0x38000000 + * 4Kb Backup RAM at 0x38800000 + */ + +MEMORY +{ + ITCM_RAM (rwx) : ORIGIN = 0x00000000, LENGTH = 64K + FLASH (rx) : ORIGIN = 0x08020000, LENGTH = 1792K + + DTCM1_RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 64K + DTCM2_RAM (rwx) : ORIGIN = 0x20010000, LENGTH = 64K + AXI_SRAM (rwx) : ORIGIN = 0x24000000, LENGTH = 512K /* D1 domain AXI bus */ + SRAM1 (rwx) : ORIGIN = 0x30000000, LENGTH = 128K /* D2 domain AHB bus */ + SRAM2 (rwx) : ORIGIN = 0x30020000, LENGTH = 128K /* D2 domain AHB bus */ + SRAM3 (rwx) : ORIGIN = 0x30040000, LENGTH = 32K /* D2 domain AHB bus */ + SRAM4 (rwx) : ORIGIN = 0x38000000, LENGTH = 64K /* D3 domain */ + BKPRAM (rwx) : ORIGIN = 0x38800000, LENGTH = 4K +} + +OUTPUT_ARCH(arm) +EXTERN(_vectors) +ENTRY(_stext) + +/* + * Ensure that abort() is present in the final object. The exception handling + * code pulled in by libgcc.a requires it (and that code cannot be easily avoided). + */ +EXTERN(abort) +EXTERN(_bootdelay_signature) + +SECTIONS +{ + .text : { + _stext = ABSOLUTE(.); + *(.vectors) + . = ALIGN(32); + /* + This signature provides the bootloader with a way to delay booting + */ + _bootdelay_signature = ABSOLUTE(.); + FILL(0xffecc2925d7d05c5) + . += 8; + *(.text .text.*) + *(.fixup) + *(.gnu.warning) + *(.rodata .rodata.*) + *(.gnu.linkonce.t.*) + *(.glue_7) + *(.glue_7t) + *(.got) + *(.gcc_except_table) + *(.gnu.linkonce.r.*) + _etext = ABSOLUTE(.); + + } > FLASH + + /* + * Init functions (static constructors and the like) + */ + .init_section : { + _sinit = ABSOLUTE(.); + KEEP(*(.init_array .init_array.*)) + _einit = ABSOLUTE(.); + } > FLASH + + + .ARM.extab : { + *(.ARM.extab*) + } > FLASH + + __exidx_start = ABSOLUTE(.); + .ARM.exidx : { + *(.ARM.exidx*) + } > FLASH + __exidx_end = ABSOLUTE(.); + + _eronly = ABSOLUTE(.); + + .data : { + _sdata = ABSOLUTE(.); + *(.data .data.*) + *(.gnu.linkonce.d.*) + CONSTRUCTORS + _edata = ABSOLUTE(.); + + /* Pad out last section as the STM32H7 Flash write size is 256 bits. 32 bytes */ + . = ALIGN(16); + FILL(0xffff) + . += 16; + } > AXI_SRAM AT > FLASH = 0xffff + + .bss : { + _sbss = ABSOLUTE(.); + *(.bss .bss.*) + *(.gnu.linkonce.b.*) + *(COMMON) + . = ALIGN(4); + _ebss = ABSOLUTE(.); + } > AXI_SRAM + + /* Emit the the D3 power domain section for locating BDMA data */ + + .sram4_reserve (NOLOAD) : + { + *(.sram4) + . = ALIGN(4); + _sram4_heap_start = ABSOLUTE(.); + } > SRAM4 + + /* Stabs debugging sections. */ + .stab 0 : { *(.stab) } + .stabstr 0 : { *(.stabstr) } + .stab.excl 0 : { *(.stab.excl) } + .stab.exclstr 0 : { *(.stab.exclstr) } + .stab.index 0 : { *(.stab.index) } + .stab.indexstr 0 : { *(.stab.indexstr) } + .comment 0 : { *(.comment) } + .debug_abbrev 0 : { *(.debug_abbrev) } + .debug_info 0 : { *(.debug_info) } + .debug_line 0 : { *(.debug_line) } + .debug_pubnames 0 : { *(.debug_pubnames) } + .debug_aranges 0 : { *(.debug_aranges) } +} diff --git a/boards/accton-godwit/gfh7/src/CMakeLists.txt b/boards/accton-godwit/gfh7/src/CMakeLists.txt new file mode 100644 index 00000000000..8dd6208e297 --- /dev/null +++ b/boards/accton-godwit/gfh7/src/CMakeLists.txt @@ -0,0 +1,72 @@ +############################################################################ +# +# Copyright (c) 2026 PX4 Development Team. All rights reserved. +# +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions +# are met: +# +# 1. Redistributions of source code must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# 2. Redistributions in binary form must reproduce the above copyright +# notice, this list of conditions and the following disclaimer in +# the documentation and/or other materials provided with the +# distribution. +# 3. Neither the name PX4 nor the names of its contributors may be +# used to endorse or promote products derived from this software +# without specific prior written permission. +# +# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS +# FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE +# COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, +# BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS +# OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED +# AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN +# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE +# POSSIBILITY OF SUCH DAMAGE. +# +############################################################################ +if("${PX4_BOARD_LABEL}" STREQUAL "bootloader") + add_library(drivers_board + bootloader_main.c + usb.c + ) + target_link_libraries(drivers_board + PRIVATE + nuttx_arch + nuttx_drivers + bootloader + ) + target_include_directories(drivers_board PRIVATE ${PX4_SOURCE_DIR}/platforms/nuttx/src/bootloader/common) + +else() + add_library(drivers_board + board_clock.c + i2c.cpp + init.c + led.c + sdio.c + spi.cpp + timer_config.cpp + usb.c + ) + add_dependencies(drivers_board nuttx_arch_build) + + target_link_libraries(drivers_board + PRIVATE + arch_board_reset + arch_io_pins + arch_spi + drivers__led + nuttx_arch + nuttx_drivers + px4_layer + systemlib + ) + + target_include_directories(drivers_board INTERFACE ${CMAKE_CURRENT_SOURCE_DIR}) +endif() diff --git a/boards/accton-godwit/gfh7/src/board_clock.c b/boards/accton-godwit/gfh7/src/board_clock.c new file mode 100644 index 00000000000..a704b202ef0 --- /dev/null +++ b/boards/accton-godwit/gfh7/src/board_clock.c @@ -0,0 +1,65 @@ +/**************************************************************************** + * + * Copyright (c) 2026 PX4 Development Team. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name PX4 nor the names of its contributors may be + * used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + * + ****************************************************************************/ + +#include +#include + +#include +#include +#include +#include + +#include + +#define TIM4_REG(offset) (*(volatile uint32_t *)(STM32_TIM4_BASE + (offset))) + +void board_clock_outputs_initialize(void) +{ + /* PA8/MCO1 is left unused: the STM32G431 OSD co-processor runs from its + * own crystal (X2), and R80, which would route MCO1 to it, is not fitted. + */ + + /* ICM-42688-P CLKIN: 240 MHz / (15 * 500) = 32 kHz on TIM4_CH3/PD14. */ + modifyreg32(STM32_RCC_APB1LENR, 0, RCC_APB1LENR_TIM4EN); + TIM4_REG(STM32_GTIM_CR1_OFFSET) = 0; + TIM4_REG(STM32_GTIM_CCER_OFFSET) = 0; + TIM4_REG(STM32_GTIM_CCMR2_OFFSET) = + (GTIM_CCMR_MODE_PWM1 << GTIM_CCMR2_OC3M_SHIFT) | GTIM_CCMR2_OC3PE; + TIM4_REG(STM32_GTIM_PSC_OFFSET) = 14; + TIM4_REG(STM32_GTIM_ARR_OFFSET) = 499; + TIM4_REG(STM32_GTIM_CCR3_OFFSET) = 250; + TIM4_REG(STM32_GTIM_EGR_OFFSET) = GTIM_EGR_UG; + TIM4_REG(STM32_GTIM_CCER_OFFSET) = GTIM_CCER_CC3E; + px4_arch_configgpio(GPIO_TIM4_CH3OUT_2); + TIM4_REG(STM32_GTIM_CR1_OFFSET) = GTIM_CR1_ARPE | GTIM_CR1_CEN; +} diff --git a/boards/accton-godwit/gfh7/src/board_config.h b/boards/accton-godwit/gfh7/src/board_config.h new file mode 100644 index 00000000000..871e08ad039 --- /dev/null +++ b/boards/accton-godwit/gfh7/src/board_config.h @@ -0,0 +1,142 @@ +/**************************************************************************** + * + * Copyright (c) 2026 PX4 Development Team. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name PX4 nor the names of its contributors may be + * used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + * + ****************************************************************************/ + +#pragma once + +#include +#include +#include +#include +#include + +/* Status LEDs, active low. */ +#define GPIO_nLED_GREEN /* PC13 */ (GPIO_OUTPUT|GPIO_PUSHPULL|GPIO_SPEED_50MHz|GPIO_OUTPUT_SET|GPIO_PORTC|GPIO_PIN13) +#define GPIO_nLED_BLUE /* PE10 */ (GPIO_OUTPUT|GPIO_PUSHPULL|GPIO_SPEED_50MHz|GPIO_OUTPUT_SET|GPIO_PORTE|GPIO_PIN10) + +#define BOARD_HAS_CONTROL_STATUS_LEDS 1 +#define BOARD_OVERLOAD_LED LED_GREEN +#define BOARD_ARMED_STATE_LED LED_BLUE + +/* ADC1 inputs. */ +#define PX4_ADC_GPIO \ + GPIO_ADC123_INP10, /* PC0: voltage */ \ + GPIO_ADC12_INP9, /* PB0: current */ \ + GPIO_ADC12_INP5 /* PB1: RSSI */ + +#define ADC_BATTERY_VOLTAGE_CHANNEL 10 +#define ADC_BATTERY_CURRENT_CHANNEL 9 +#define ADC_RSSI_IN_CHANNEL 5 +#define ADC_CHANNELS ((1 << ADC_BATTERY_VOLTAGE_CHANNEL) | \ + (1 << ADC_BATTERY_CURRENT_CHANNEL) | \ + (1 << ADC_RSSI_IN_CHANNEL)) + +/* 160 kOhm / 10 kOhm divider. Current scaling remains intentionally unset. */ +#define BOARD_BATTERY1_V_DIV 17.0f + +/* Eight motor outputs: TIM1 CH1-4 and TIM8 CH1-4. */ +#define DIRECT_PWM_OUTPUT_CHANNELS 8 +#define BOARD_NUM_IO_TIMERS 2 + +/* TIM3 is free from TIM2 NeoPixel and TIM4 IMU clock duties. */ +#define HRT_TIMER 3 +#define HRT_TIMER_CHANNEL 1 + +/* PE12 drives the external buzzer transistor. GPIO mode supports active buzzers. */ +#define GPIO_TONE_ALARM_IDLE /* PE12 */ (GPIO_OUTPUT|GPIO_PUSHPULL|GPIO_SPEED_2MHz|GPIO_OUTPUT_CLEAR|GPIO_PORTE|GPIO_PIN12) +#define GPIO_TONE_ALARM_GPIO GPIO_TONE_ALARM_IDLE + +/* Board controls. */ +/* Heater: PE3 high turns on low-side N-MOSFET Q2. The gate has a pull-down + * and the pin starts low, so the heater is off through reset and boot. + */ +#define GPIO_HEATER_OUTPUT +#define HEATER_NUM 1 +#define GPIO_HEATER1_OUTPUT /* PE3 */ (GPIO_OUTPUT|GPIO_PUSHPULL|GPIO_SPEED_2MHz|GPIO_OUTPUT_CLEAR|GPIO_PORTE|GPIO_PIN3) +#define HEATER1_OUTPUT_EN(on_true) px4_arch_gpiowrite(GPIO_HEATER1_OUTPUT, (on_true)) +/* 12 V BEC enable, active low: PC12 high turns Q3 on and the 12 V output off. + * The pin starts low, so 12 V is on at boot. + */ +#define GPIO_n12V_EN /* PC12 */ (GPIO_OUTPUT|GPIO_PUSHPULL|GPIO_SPEED_2MHz|GPIO_OUTPUT_CLEAR|GPIO_PORTC|GPIO_PIN12) +#define PAYLOAD_POWER_EN(on_true) px4_arch_gpiowrite(GPIO_n12V_EN, !(on_true)) +#define GPIO_HW_VER0 /* PC14 */ (GPIO_INPUT|GPIO_FLOAT|GPIO_PORTC|GPIO_PIN14) +#define GPIO_HW_VER1 /* PC15 */ (GPIO_INPUT|GPIO_FLOAT|GPIO_PORTC|GPIO_PIN15) +#define GPIO_PHY_RST_SAFE /* PD15 */ (GPIO_INPUT|GPIO_PULLDOWN|GPIO_PORTD|GPIO_PIN15) + +/* USB VBUS is not sensed: PA9 is a test point and the VBUS sense resistor + * (R114) is not fitted. The pull-up keeps PA9 high, so PX4 treats USB as + * always attached. + */ +#define BOARD_USB_VBUS_SENSE_DISABLED 1 +#define GPIO_OTGFS_VBUS /* PA9 */ (GPIO_INPUT|GPIO_PULLUP|GPIO_SPEED_100MHz|GPIO_PORTA|GPIO_PIN9) +#define BOARD_ADC_USB_CONNECTED (1) +#define BOARD_ADC_USB_VALID BOARD_ADC_USB_CONNECTED + +/* SDMMC2, card detect is active low. */ +#define SDIO_SLOTNO 0 +#define SDIO_MINOR 0 +#define GPIO_SDMMC2_NCD /* PA15 */ (GPIO_INPUT|GPIO_PULLUP|GPIO_EXTI|GPIO_PORTA|GPIO_PIN15) + +/* Up to eight WS2812/SK6812-compatible LEDs on TIM2 CH3 / PB10. */ +#if defined(USE_S_RGB_LED_DMA) +# define BOARD_HAS_N_S_RGB_LED 8 +# define BOARD_MAX_LEDS BOARD_HAS_N_S_RGB_LED +# define S_RGB_LED_DMA DMAMAP_DMA12_TIM2CH3_0 +# define S_RGB_LED_TIMER 2 +# define S_RGB_LED_CHANNEL 3 +# define S_RGB_LED_TIM_GPIO GPIO_TIM2_CH3OUT_2 +#endif + +#define BOARD_DMA_ALLOC_POOL_SIZE 5120 +#define BOARD_HAS_ON_RESET 1 +#define BOARD_ENABLE_CONSOLE_BUFFER +#define FLASH_BASED_PARAMS + +#define BOARD_ADC_BRICK_VALID (true) + +#define PX4_GPIO_INIT_LIST { \ + PX4_ADC_GPIO, \ + GPIO_CAN1_TX, GPIO_CAN1_RX, \ + GPIO_HEATER1_OUTPUT, GPIO_n12V_EN, GPIO_TONE_ALARM_IDLE, \ + GPIO_HW_VER0, GPIO_HW_VER1, GPIO_PHY_RST_SAFE \ + } + +__BEGIN_DECLS + +int stm32_sdio_initialize(void); +extern void stm32_spiinitialize(void); +extern void stm32_usbinitialize(void); +extern void board_peripheral_reset(int ms); + +#include + +__END_DECLS diff --git a/boards/accton-godwit/gfh7/src/bootloader_main.c b/boards/accton-godwit/gfh7/src/bootloader_main.c new file mode 100644 index 00000000000..d3c8e514e12 --- /dev/null +++ b/boards/accton-godwit/gfh7/src/bootloader_main.c @@ -0,0 +1,75 @@ +/**************************************************************************** + * + * Copyright (C) 2026 Accton Technology Corporation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name PX4 nor the names of its contributors may be + * used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + * + ****************************************************************************/ + +/** + * @file bootloader_main.c + * + * Accton Godwit GFH7 bootloader entry point. + */ + +#include "board_config.h" +#include "bl.h" + +#include +#include +#include +#include +#include +#include "arm_internal.h" +#include + +extern int sercon_main(int c, char **argv); + +__EXPORT void board_on_reset(int status) {} + +__EXPORT void stm32_boardinitialize(void) +{ + /* configure USB interfaces */ + stm32_usbinitialize(); +} + +__EXPORT int board_app_initialize(uintptr_t arg) +{ + return 0; +} + +void board_late_initialize(void) +{ + sercon_main(0, NULL); +} + +extern void sys_tick_handler(void); +void board_timerhook(void) +{ + sys_tick_handler(); +} diff --git a/boards/accton-godwit/gfh7/src/hw_config.h b/boards/accton-godwit/gfh7/src/hw_config.h new file mode 100644 index 00000000000..750686efff5 --- /dev/null +++ b/boards/accton-godwit/gfh7/src/hw_config.h @@ -0,0 +1,78 @@ +/**************************************************************************** + * + * Copyright (c) 2026 PX4 Development Team. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name PX4 nor the names of its contributors may be + * used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + * + ****************************************************************************/ + +#pragma once + +#define USB0_DEV 0x01 +#define SERIAL0_DEV 0x02 + +#define APP_LOAD_ADDRESS 0x08020000 +#define BOOTLOADER_DELAY 5000 +#define INTERFACE_USB 1 +#define INTERFACE_USB_CONFIG "/dev/ttyACM0" +#define INTERFACE_USART 1 +#define INTERFACE_USART_CONFIG "/dev/ttyS0,115200" + +#define BOOT_DELAY_ADDRESS 0x000001a0 +#define BOARD_TYPE 7122 +#define BOARD_FLASH_SECTORS 14 +#define BOARD_FLASH_SIZE (16 * 128 * 1024) +#define APP_RESERVATION_SIZE (1 * 128 * 1024) +#define OSC_FREQ 16 + +#define BOARD_PIN_LED_ACTIVITY GPIO_nLED_BLUE +#define BOARD_PIN_LED_BOOTLOADER GPIO_nLED_GREEN +#define BOARD_LED_ON 0 +#define BOARD_LED_OFF 1 + +#define SERIAL_BREAK_DETECT_DISABLED 1 + +#if !defined(ARCH_SN_MAX_LENGTH) +# define ARCH_SN_MAX_LENGTH 12 +#endif + +#if !defined(BOARD_FIRST_FLASH_SECTOR_TO_ERASE) +# define BOARD_FIRST_FLASH_SECTOR_TO_ERASE 1 +#endif + +#if !defined(USB_DATA_ALIGN) +# define USB_DATA_ALIGN +#endif + +#ifndef BOOT_DEVICES_SELECTION +# define BOOT_DEVICES_SELECTION (USB0_DEV | SERIAL0_DEV) +#endif + +#ifndef BOOT_DEVICES_FILTER_ONUSB +# define BOOT_DEVICES_FILTER_ONUSB (USB0_DEV | SERIAL0_DEV) +#endif diff --git a/boards/accton-godwit/gfh7/src/i2c.cpp b/boards/accton-godwit/gfh7/src/i2c.cpp new file mode 100644 index 00000000000..463747f2ad6 --- /dev/null +++ b/boards/accton-godwit/gfh7/src/i2c.cpp @@ -0,0 +1,39 @@ +/**************************************************************************** + * + * Copyright (c) 2026 PX4 Development Team. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name PX4 nor the names of its contributors may be + * used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + * + ****************************************************************************/ + +#include + +constexpr px4_i2c_bus_t px4_i2c_buses[I2C_BUS_MAX_BUS_ITEMS] = { + initI2CBusInternal(1), + initI2CBusExternal(4), +}; diff --git a/boards/accton-godwit/gfh7/src/init.c b/boards/accton-godwit/gfh7/src/init.c new file mode 100644 index 00000000000..d32c6c85420 --- /dev/null +++ b/boards/accton-godwit/gfh7/src/init.c @@ -0,0 +1,199 @@ +/**************************************************************************** + * + * Copyright (c) 2026 PX4 Development Team. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name PX4 nor the names of its contributors may be + * used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + * + ****************************************************************************/ + +/** + * @file init.c + * + * Accton Godwit GFH7 board-specific early startup. + * + * Two hooks are provided here: + * - stm32_boardinitialize(): called very early by NuttX, before device + * drivers exist. Only GPIO / pin-mux work allowed. + * - board_app_initialize(): called once NuttX user space is up; starts + * platform services (HRT, DMA pool, LED device, hardfault logger, + * parameter flash store, HW manifest). + */ + +#include "board_config.h" + +#include +#include +#include +#include +#include + +#include +#include +#include +#include +#include + +#include +#include +#include + +#include +#include + +#include +#include +#include +#include + +__BEGIN_DECLS +extern void led_init(void); +extern void led_on(int led); +extern void led_off(int led); +extern void board_clock_outputs_initialize(void); +__END_DECLS + +__EXPORT int board_app_initialize(uintptr_t arg); + +/**************************************************************************** + * Name: board_peripheral_reset + * + * Description: + * Called by PX4 system-reset to power-cycle external peripherals. + * GFH7 has no general peripheral power-cycle rail, so this is a no-op. + ****************************************************************************/ +__EXPORT void board_peripheral_reset(int ms) +{ + UNUSED(ms); +} + +/**************************************************************************** + * Name: board_on_reset + * + * Description: + * Put PWM outputs into a safe (input) state on reset. When reset comes + * from the running system (status >= 0), hold low for 100 ms to ensure + * ESCs are disarmed before further init continues. + ****************************************************************************/ +__EXPORT void board_on_reset(int status) +{ + for (int i = 0; i < DIRECT_PWM_OUTPUT_CHANNELS; ++i) { + px4_arch_configgpio(PX4_MAKE_GPIO_INPUT(io_timer_channel_get_as_pwm_input(i))); + } + + if (status >= 0) { + up_mdelay(100); + } +} + +/**************************************************************************** + * Name: stm32_boardinitialize + ****************************************************************************/ +__EXPORT void stm32_boardinitialize(void) +{ + /* Keep the debug port available across low-power states. */ + *(volatile uint32_t *)0x5C001004 |= (1u << 0) | (1u << 1) | (1u << 2); + + board_on_reset(-1); + + /* LEDs - NuttX arch-level hook (no-op unless CONFIG_ARCH_LEDS=y, which is + * off on this port; real LED setup happens later via drv_led_start() in + * board_app_initialize) */ + board_autoled_initialize(); + + /* Configure ADC, CAN, board controls and revision straps. */ + const uint32_t gpio[] = PX4_GPIO_INIT_LIST; + px4_gpio_init(gpio, arraySize(gpio)); + + board_clock_outputs_initialize(); + + /* USB OTG_FS. VBUS is not sensed on this board, see board_config.h. */ + stm32_usbinitialize(); +} + +/**************************************************************************** + * Name: board_app_initialize + ****************************************************************************/ +__EXPORT int board_app_initialize(uintptr_t arg) +{ + /* Need HRT running before ADC / workqueues can be used */ + px4_platform_init(); + + /* SPI buses so onboard devices can probe. */ + stm32_spiinitialize(); + + /* DMA allocator pool (required for SPI / UART DMA buffers on H7) */ + if (board_dma_alloc_init() < 0) { + syslog(LOG_ERR, "[boot] DMA alloc FAILED\n"); + } + +#if defined(SERIAL_HAVE_RXDMA) + static struct hrt_call serial_dma_call; + hrt_call_every(&serial_dma_call, 1000, 1000, (hrt_callout)stm32_serial_dma_poll, NULL); +#endif + + /* Register LED device and set initial state (all off) */ + drv_led_start(); + led_off(LED_GREEN); + led_off(LED_BLUE); + + /* BBSRAM crash-dump logger */ + if (board_hardfault_init(2, true) != 0) { + led_on(LED_GREEN); + } + + /* SDMMC2 / SD card bring-up. */ +#ifdef CONFIG_MMCSD + int sd_ret = stm32_sdio_initialize(); + + if (sd_ret != OK) { + syslog(LOG_ERR, "[boot] SDIO init FAILED: %d\n", sd_ret); + led_on(LED_GREEN); + } + +#endif + + /* Parameters in internal flash: sector 15 at 0x081E0000 (128 KB) -- + * matches bootloader's APP_RESERVATION_SIZE. */ +#if defined(FLASH_BASED_PARAMS) + static sector_descriptor_t params_sector_map[] = { + {15, 128 * 1024, 0x081E0000}, + {0, 0, 0}, + }; + + if (parameter_flashfs_init(params_sector_map, NULL, 0) != OK) { + syslog(LOG_ERR, "[boot] parameter_flashfs_init FAILED\n"); + led_on(LED_GREEN); + } + +#endif + + /* Configure HW per manifest (must be last) */ + px4_platform_configure(); + + return OK; +} diff --git a/boards/accton-godwit/gfh7/src/led.c b/boards/accton-godwit/gfh7/src/led.c new file mode 100644 index 00000000000..f05e3815e0d --- /dev/null +++ b/boards/accton-godwit/gfh7/src/led.c @@ -0,0 +1,133 @@ +/**************************************************************************** + * + * Copyright (c) 2026 PX4 Development Team. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name PX4 nor the names of its contributors may be + * used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + * + ****************************************************************************/ + +/** + * @file led.c + * + * LED backend. + */ + +#include + +#include + +#include "chip.h" +#include "stm32_gpio.h" +#include "board_config.h" + +#include +#include + +/* + * Ideally we'd be able to get these from arm_internal.h, + * but since we want to be able to disable the NuttX use + * of leds for system indication at will and there is no + * separate switch, we need to build independent of the + * CONFIG_ARCH_LEDS configuration switch. + */ +__BEGIN_DECLS +extern void led_init(void); +extern void led_on(int led); +extern void led_off(int led); +extern void led_toggle(int led); +__END_DECLS + +# define xlat(p) (p) +// index: 0=BLUE, 1=RED, 2=SAFETY, 3=GREEN +static uint32_t g_ledmap[] = { + GPIO_nLED_BLUE, // LED_BLUE (0) + 0, // LED_RED (1) + 0, // LED_SAFETY (2) + GPIO_nLED_GREEN, // LED_GREEN (3) +}; + +#ifndef arraySize +#define arraySize(a) (sizeof((a))/sizeof(((a)[0]))) +#endif + +static inline bool valid_led_index(int led) +{ + return (led >= 0) && ((size_t)led < arraySize(g_ledmap)); +} + +__EXPORT void led_init(void) +{ + /* Configure LED GPIOs for output */ + for (size_t l = 0; l < (sizeof(g_ledmap) / sizeof(g_ledmap[0])); l++) { + if (g_ledmap[l] != 0) { + stm32_configgpio(g_ledmap[l]); + } + } +} + +static void phy_set_led(int led, bool state) +{ + if (!valid_led_index(led)) { + return; + } + + /* Drive Low to switch on */ + if (g_ledmap[led] != 0) { + stm32_gpiowrite(g_ledmap[led], !state); + } +} + +static bool phy_get_led(int led) +{ + if (!valid_led_index(led)) { + return false; + } + + /* If Low it is on */ + if (g_ledmap[led] != 0) { + return !stm32_gpioread(g_ledmap[led]); + } + + return false; +} + + +__EXPORT void led_on(int led) +{ + phy_set_led(xlat(led), true); +} + +__EXPORT void led_off(int led) +{ + phy_set_led(xlat(led), false); +} + +__EXPORT void led_toggle(int led) +{ + phy_set_led(xlat(led), !phy_get_led(xlat(led))); +} diff --git a/boards/accton-godwit/gfh7/src/sdio.c b/boards/accton-godwit/gfh7/src/sdio.c new file mode 100644 index 00000000000..5c923a06abb --- /dev/null +++ b/boards/accton-godwit/gfh7/src/sdio.c @@ -0,0 +1,177 @@ +/**************************************************************************** + * + * Copyright (C) 2014, 2016 Gregory Nutt. All rights reserved. + * Author: Gregory Nutt + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name NuttX nor the names of its contributors may be + * used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + * + ****************************************************************************/ + +/**************************************************************************** + * Included Files + ****************************************************************************/ + +#include +#include + +#include +#include +#include +#include + +#include +#include + +#include "chip.h" +#include "board_config.h" +#include "stm32_gpio.h" +#include "stm32_sdmmc.h" + +#ifdef CONFIG_MMCSD + + +/**************************************************************************** + * Pre-processor Definitions + ****************************************************************************/ + +/* Card detections requires card support and a card detection GPIO */ + +#define HAVE_NCD 1 +#if !defined(GPIO_SDMMC2_NCD) +# undef HAVE_NCD +#endif + +/**************************************************************************** + * Private Data + ****************************************************************************/ + +static FAR struct sdio_dev_s *sdio_dev; +#ifdef HAVE_NCD +static bool g_sd_inserted = 0xff; /* Impossible value */ +#endif + +/**************************************************************************** + * Private Functions + ****************************************************************************/ + +/**************************************************************************** + * Name: stm32_ncd_interrupt + * + * Description: + * Card detect interrupt handler. + * + ****************************************************************************/ + +#ifdef HAVE_NCD +static int stm32_ncd_interrupt(int irq, FAR void *context, FAR void *arg) +{ + bool present; + + present = !stm32_gpioread(GPIO_SDMMC2_NCD); + + if (sdio_dev && present != g_sd_inserted) { + sdio_mediachange(sdio_dev, present); + g_sd_inserted = present; + } + + return OK; +} +#endif + +/**************************************************************************** + * Public Functions + ****************************************************************************/ + +/**************************************************************************** + * Name: stm32_sdio_initialize + * + * Description: + * Initialize SDIO-based MMC/SD card support + * + ****************************************************************************/ + +int stm32_sdio_initialize(void) +{ + int ret; + +#ifdef HAVE_NCD + /* Card detect */ + + bool cd_status; + + /* Configure the card detect GPIO */ + + stm32_configgpio(GPIO_SDMMC2_NCD); + + /* Register an interrupt handler for the card detect pin */ + + stm32_gpiosetevent(GPIO_SDMMC2_NCD, true, true, true, stm32_ncd_interrupt, NULL); +#endif + + /* Mount the SDIO-based MMC/SD block driver */ + /* First, get an instance of the SDIO interface */ + + finfo("Initializing SDIO slot %d\n", SDIO_SLOTNO); + + sdio_dev = sdio_initialize(SDIO_SLOTNO); + + if (!sdio_dev) { + syslog(LOG_ERR, "[boot] Failed to initialize SDIO slot %d\n", SDIO_SLOTNO); + return -ENODEV; + } + + /* Now bind the SDIO interface to the MMC/SD driver */ + + finfo("Bind SDIO to the MMC/SD driver, minor=%d\n", SDIO_MINOR); + + ret = mmcsd_slotinitialize(SDIO_MINOR, sdio_dev); + + if (ret != OK) { + syslog(LOG_ERR, "[boot] Failed to bind SDIO to the MMC/SD driver: %d\n", ret); + return ret; + } + + finfo("Successfully bound SDIO to the MMC/SD driver\n"); + +#ifdef HAVE_NCD + /* Use SD card detect pin to check if a card is g_sd_inserted */ + + cd_status = !stm32_gpioread(GPIO_SDMMC2_NCD); + finfo("Card detect : %d\n", cd_status); + + sdio_mediachange(sdio_dev, cd_status); +#else + /* Assume that the SD card is inserted. What choice do we have? */ + + sdio_mediachange(sdio_dev, true); +#endif + + return OK; +} + +#endif /* CONFIG_MMCSD */ diff --git a/boards/accton-godwit/gfh7/src/spi.cpp b/boards/accton-godwit/gfh7/src/spi.cpp new file mode 100644 index 00000000000..75ed24e151b --- /dev/null +++ b/boards/accton-godwit/gfh7/src/spi.cpp @@ -0,0 +1,52 @@ +/**************************************************************************** + * + * Copyright (c) 2026 PX4 Development Team. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name PX4 nor the names of its contributors may be + * used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + * + ****************************************************************************/ + +#include +#include +#include + +constexpr px4_spi_bus_t px4_spi_buses[SPI_BUS_MAX_BUS_ITEMS] = { + initSPIBus(SPI::Bus::SPI1, { + initSPIDevice(DRV_OSD_DEVTYPE_ATXXXX, SPI::CS{GPIO::PortA, GPIO::Pin4}), + }), + initSPIBus(SPI::Bus::SPI2, { + initSPIDevice(DRV_IMU_DEVTYPE_ST_LSM6DSV, SPI::CS{GPIO::PortB, GPIO::Pin9}, + SPI::DRDY{GPIO::PortD, GPIO::Pin11}), + }), + initSPIBus(SPI::Bus::SPI4, { + initSPIDevice(DRV_IMU_DEVTYPE_ICM42688P, SPI::CS{GPIO::PortE, GPIO::Pin4}, + SPI::DRDY{GPIO::PortD, GPIO::Pin10}), + }), +}; + +static constexpr bool unused = validateSPIConfig(px4_spi_buses); diff --git a/boards/accton-godwit/gfh7/src/timer_config.cpp b/boards/accton-godwit/gfh7/src/timer_config.cpp new file mode 100644 index 00000000000..7a574ced3ba --- /dev/null +++ b/boards/accton-godwit/gfh7/src/timer_config.cpp @@ -0,0 +1,53 @@ +/**************************************************************************** + * + * Copyright (c) 2026 PX4 Development Team. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name PX4 nor the names of its contributors may be + * used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + * + ****************************************************************************/ + +#include + +constexpr io_timers_t io_timers[MAX_IO_TIMERS] = { + initIOTimer(Timer::Timer1, DMA{DMA::Index1}), + initIOTimer(Timer::Timer8, DMA{DMA::Index1}), +}; + +constexpr timer_io_channels_t timer_io_channels[MAX_TIMER_IO_CHANNELS] = { + initIOTimerChannel(io_timers, {Timer::Timer1, Timer::Channel1}, {GPIO::PortE, GPIO::Pin9}), + initIOTimerChannel(io_timers, {Timer::Timer1, Timer::Channel2}, {GPIO::PortE, GPIO::Pin11}), + initIOTimerChannel(io_timers, {Timer::Timer1, Timer::Channel3}, {GPIO::PortE, GPIO::Pin13}), + initIOTimerChannel(io_timers, {Timer::Timer1, Timer::Channel4}, {GPIO::PortE, GPIO::Pin14}), + initIOTimerChannel(io_timers, {Timer::Timer8, Timer::Channel1}, {GPIO::PortC, GPIO::Pin6}), + initIOTimerChannel(io_timers, {Timer::Timer8, Timer::Channel2}, {GPIO::PortC, GPIO::Pin7}), + initIOTimerChannel(io_timers, {Timer::Timer8, Timer::Channel3}, {GPIO::PortC, GPIO::Pin8}), + initIOTimerChannel(io_timers, {Timer::Timer8, Timer::Channel4}, {GPIO::PortC, GPIO::Pin9}), +}; + +constexpr io_timers_channel_mapping_t io_timers_channel_mapping = + initIOTimerChannelMapping(io_timers, timer_io_channels); diff --git a/boards/accton-godwit/gfh7/src/usb.c b/boards/accton-godwit/gfh7/src/usb.c new file mode 100644 index 00000000000..7e436214165 --- /dev/null +++ b/boards/accton-godwit/gfh7/src/usb.c @@ -0,0 +1,70 @@ +/**************************************************************************** + * + * Copyright (C) 2026 Accton Technology Corporation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name PX4 nor the names of its contributors may be + * used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + * + ****************************************************************************/ + +/** + * @file usb.c + * + * Board-specific USB functions. + */ + +#include + +#include +#include +#include +#include + +#include +#include + +#include +#include +#include +#include +#include "board_config.h" + +__EXPORT void stm32_usbinitialize(void) +{ + /* The OTG FS has an internal soft pull-up */ + + /* Configure the OTG FS VBUS sensing GPIO, Power On, and Overcurrent GPIOs */ + +#ifdef CONFIG_STM32H7_OTGFS + stm32_configgpio(GPIO_OTGFS_VBUS); +#endif +} + +__EXPORT void stm32_usbsuspend(FAR struct usbdev_s *dev, bool resume) +{ + uinfo("resume: %d\n", resume); +} diff --git a/boards/agam/fmu-v6xrt/default.px4board b/boards/agam/fmu-v6xrt/default.px4board index 5a3e1768844..c53e3e457b2 100644 --- a/boards/agam/fmu-v6xrt/default.px4board +++ b/boards/agam/fmu-v6xrt/default.px4board @@ -77,6 +77,7 @@ CONFIG_MODULES_LOGGER=y CONFIG_MODULES_MAG_BIAS_ESTIMATOR=y CONFIG_MODULES_MANUAL_CONTROL=y CONFIG_MODULES_MAVLINK=y +CONFIG_MAVLINK_NUM_CONFIG_INSTANCES=5 CONFIG_MODULES_MC_ATT_CONTROL=y CONFIG_MODULES_MC_AUTOTUNE_ATTITUDE_CONTROL=y CONFIG_MODULES_MC_HOVER_THRUST_ESTIMATOR=y diff --git a/boards/agam/fmu-v6xrt/nuttx-config/scripts/itcm_functions_includes.ld b/boards/agam/fmu-v6xrt/nuttx-config/scripts/itcm_functions_includes.ld index 58a96d058ab..c27d1b61d3d 100644 --- a/boards/agam/fmu-v6xrt/nuttx-config/scripts/itcm_functions_includes.ld +++ b/boards/agam/fmu-v6xrt/nuttx-config/scripts/itcm_functions_includes.ld @@ -516,7 +516,7 @@ *(.text._ZN13NavigatorMode3runEb) *(.text._ZL19param_find_internalPKcb) *(.text.uart_datasent) -*(.text._ZN4EKF221PublishOpticalFlowVelERKy) +*(.text._ZN17OpticalFlowSource7publishERK3Ekf) *(.text.nxsem_destroy) *(.text.file_write) *(.text._ZN21MavlinkStreamAltitude4sendEv) diff --git a/boards/ark/can-flow-mr/init/rc.board_sensors b/boards/ark/can-flow-mr/init/rc.board_sensors index d08b1f9cf22..66672ed6db8 100644 --- a/boards/ark/can-flow-mr/init/rc.board_sensors +++ b/boards/ark/can-flow-mr/init/rc.board_sensors @@ -4,7 +4,7 @@ #------------------------------------------------------------------------------ param set-default IMU_GYRO_RATEMAX 1000 -param set-default SENS_FLOW_RATE 150 +param set-default SENS_FLOW0_RATE 150 param set-default SENS_IMU_CLPNOTI 0 # Internal SPI diff --git a/boards/ark/can-flow/init/rc.board_sensors b/boards/ark/can-flow/init/rc.board_sensors index 13502ed7ce0..dcbb87c6913 100644 --- a/boards/ark/can-flow/init/rc.board_sensors +++ b/boards/ark/can-flow/init/rc.board_sensors @@ -4,7 +4,7 @@ #------------------------------------------------------------------------------ param set-default IMU_GYRO_RATEMAX 1000 -param set-default SENS_FLOW_RATE 150 +param set-default SENS_FLOW0_RATE 150 param set-default SENS_IMU_CLPNOTI 0 # Internal SPI diff --git a/boards/ark/can-gps/default.px4board b/boards/ark/can-gps/default.px4board index 8b26a3b256e..5a2a72a5abf 100644 --- a/boards/ark/can-gps/default.px4board +++ b/boards/ark/can-gps/default.px4board @@ -22,7 +22,6 @@ CONFIG_UAVCANNODE_SAFETY_BUTTON=y CONFIG_UAVCANNODE_STATIC_PRESSURE=y CONFIG_UAVCANNODE_STATIC_TEMPERATURE=y CONFIG_MODULES_GYRO_CALIBRATION=y -CONFIG_MODULES_MAG_BIAS_ESTIMATOR=y CONFIG_MODULES_SENSORS=y # CONFIG_SENSORS_VEHICLE_AIRSPEED is not set # CONFIG_SENSORS_VEHICLE_AIR_DATA is not set diff --git a/boards/ark/can-gps/init/rc.board_defaults b/boards/ark/can-gps/init/rc.board_defaults index 90560b79854..1fa1d812894 100644 --- a/boards/ark/can-gps/init/rc.board_defaults +++ b/boards/ark/can-gps/init/rc.board_defaults @@ -3,7 +3,6 @@ # board specific defaults #------------------------------------------------------------------------------ -param set-default MBE_ENABLE 0 param set-default SENS_IMU_CLPNOTI 0 safety_button start diff --git a/boards/ark/can-rtk-gps/default.px4board b/boards/ark/can-rtk-gps/default.px4board index 125a41c646d..4bfc6d55b2c 100644 --- a/boards/ark/can-rtk-gps/default.px4board +++ b/boards/ark/can-rtk-gps/default.px4board @@ -25,7 +25,6 @@ CONFIG_UAVCANNODE_SAFETY_BUTTON=y CONFIG_UAVCANNODE_STATIC_PRESSURE=y CONFIG_UAVCANNODE_STATIC_TEMPERATURE=y CONFIG_MODULES_GYRO_CALIBRATION=y -CONFIG_MODULES_MAG_BIAS_ESTIMATOR=y CONFIG_MODULES_SENSORS=y # CONFIG_SENSORS_VEHICLE_AIRSPEED is not set # CONFIG_SENSORS_VEHICLE_AIR_DATA is not set diff --git a/boards/ark/can-rtk-gps/init/rc.board_defaults b/boards/ark/can-rtk-gps/init/rc.board_defaults index 3ac47e871fc..658cc31f511 100644 --- a/boards/ark/can-rtk-gps/init/rc.board_defaults +++ b/boards/ark/can-rtk-gps/init/rc.board_defaults @@ -7,7 +7,6 @@ param set-default CANNODE_SUB_MBD 1 param set-default CANNODE_SUB_RTCM 1 param set-default GPS_1_GNSS 63 param set-default GPS_UBX_BAUD1 921600 -param set-default MBE_ENABLE 0 param set-default SENS_IMU_CLPNOTI 0 safety_button start diff --git a/boards/ark/cannode/init/rc.board_defaults b/boards/ark/cannode/init/rc.board_defaults index 9fe7db23e0a..7d149ce5ad4 100644 --- a/boards/ark/cannode/init/rc.board_defaults +++ b/boards/ark/cannode/init/rc.board_defaults @@ -3,7 +3,6 @@ # board specific defaults #------------------------------------------------------------------------------ -param set-default MBE_ENABLE 0 param set-default SENS_IMU_CLPNOTI 0 pwm_out start diff --git a/boards/ark/fmu-v6xrt/nuttx-config/scripts/itcm_functions_includes.ld b/boards/ark/fmu-v6xrt/nuttx-config/scripts/itcm_functions_includes.ld index bbcfab71dc0..e91e9cd1c65 100644 --- a/boards/ark/fmu-v6xrt/nuttx-config/scripts/itcm_functions_includes.ld +++ b/boards/ark/fmu-v6xrt/nuttx-config/scripts/itcm_functions_includes.ld @@ -502,7 +502,7 @@ *(.text._ZN13NavigatorMode3runEb) *(.text._ZL19param_find_internalPKcb) *(.text.uart_datasent) -*(.text._ZN4EKF221PublishOpticalFlowVelERKy) +*(.text._ZN17OpticalFlowSource7publishERK3Ekf) *(.text.nxsem_destroy) *(.text.file_write) *(.text._ZN21MavlinkStreamAltitude4sendEv) diff --git a/boards/ark/pi6x/init/rc.board_defaults b/boards/ark/pi6x/init/rc.board_defaults index 7b264629237..ecc97dd1504 100644 --- a/boards/ark/pi6x/init/rc.board_defaults +++ b/boards/ark/pi6x/init/rc.board_defaults @@ -42,10 +42,10 @@ then fi param set-default EKF2_MULTI_IMU 0 -param set-default EKF2_OF_CTRL 1 -param set-default EKF2_OF_N_MIN 0.05 +param set-default EKF2_OF0_CTRL 1 +param set-default EKF2_OF0_N_MIN 0.05 param set-default EKF2_RNG_A_HMAX 25 param set-default EKF2_RNG_QLTY_T 0.1 -param set-default SENS_FLOW_RATE 150 +param set-default SENS_FLOW0_RATE 150 param set-default SENS_IMU_MODE 1 diff --git a/boards/ark/septentrio-gps/default.px4board b/boards/ark/septentrio-gps/default.px4board index b80f92a543c..e2a1574331a 100644 --- a/boards/ark/septentrio-gps/default.px4board +++ b/boards/ark/septentrio-gps/default.px4board @@ -23,7 +23,6 @@ CONFIG_UAVCANNODE_STATIC_PRESSURE=y CONFIG_UAVCANNODE_STATIC_TEMPERATURE=y CONFIG_MODULES_EKF2=y CONFIG_MODULES_GYRO_CALIBRATION=y -CONFIG_MODULES_MAG_BIAS_ESTIMATOR=y CONFIG_MODULES_SENSORS=y # CONFIG_SENSORS_VEHICLE_AIRSPEED is not set # CONFIG_SENSORS_VEHICLE_AIR_DATA is not set diff --git a/boards/ark/septentrio-gps/init/rc.board_defaults b/boards/ark/septentrio-gps/init/rc.board_defaults index 79a37bcb956..d3ce8dd5468 100644 --- a/boards/ark/septentrio-gps/init/rc.board_defaults +++ b/boards/ark/septentrio-gps/init/rc.board_defaults @@ -5,7 +5,6 @@ param set-default CANNODE_SUB_MBD 1 param set-default CANNODE_SUB_RTCM 1 -param set-default MBE_ENABLE 0 param set-default SENS_IMU_CLPNOTI 0 safety_button start diff --git a/boards/ark/teseo-gps/init/rc.board_defaults b/boards/ark/teseo-gps/init/rc.board_defaults index 0185027bf9d..5244cec4b0b 100644 --- a/boards/ark/teseo-gps/init/rc.board_defaults +++ b/boards/ark/teseo-gps/init/rc.board_defaults @@ -5,7 +5,6 @@ param set-default CANNODE_SUB_MBD 1 param set-default CANNODE_SUB_RTCM 1 -param set-default MBE_ENABLE 0 param set-default SENS_IMU_CLPNOTI 0 tone_alarm start diff --git a/boards/freefly/can-rtk-gps/default.px4board b/boards/freefly/can-rtk-gps/default.px4board index 4086949fc83..c59248ae2e4 100644 --- a/boards/freefly/can-rtk-gps/default.px4board +++ b/boards/freefly/can-rtk-gps/default.px4board @@ -20,7 +20,6 @@ CONFIG_UAVCANNODE_SAFETY_BUTTON=y CONFIG_UAVCANNODE_STATIC_PRESSURE=y CONFIG_UAVCANNODE_STATIC_TEMPERATURE=y CONFIG_MODULES_GYRO_CALIBRATION=y -CONFIG_MODULES_MAG_BIAS_ESTIMATOR=y CONFIG_MODULES_SENSORS=y # CONFIG_SENSORS_VEHICLE_AIRSPEED is not set # CONFIG_SENSORS_VEHICLE_AIR_DATA is not set diff --git a/boards/holybro/can-gps-v1/default.px4board b/boards/holybro/can-gps-v1/default.px4board index 41b3ceeafd4..1d681d6abea 100644 --- a/boards/holybro/can-gps-v1/default.px4board +++ b/boards/holybro/can-gps-v1/default.px4board @@ -21,7 +21,6 @@ CONFIG_UAVCANNODE_SAFETY_BUTTON=y CONFIG_UAVCANNODE_STATIC_PRESSURE=y CONFIG_UAVCANNODE_STATIC_TEMPERATURE=y CONFIG_MODULES_GYRO_CALIBRATION=y -CONFIG_MODULES_MAG_BIAS_ESTIMATOR=y CONFIG_MODULES_SENSORS=y # CONFIG_SENSORS_VEHICLE_AIRSPEED is not set # CONFIG_SENSORS_VEHICLE_AIR_DATA is not set diff --git a/boards/matek/gnss-m9n-f4/default.px4board b/boards/matek/gnss-m9n-f4/default.px4board index 13ecd3e14ce..2ef62352b14 100644 --- a/boards/matek/gnss-m9n-f4/default.px4board +++ b/boards/matek/gnss-m9n-f4/default.px4board @@ -21,7 +21,6 @@ CONFIG_UAVCANNODE_SAFETY_BUTTON=y CONFIG_UAVCANNODE_STATIC_PRESSURE=y CONFIG_UAVCANNODE_STATIC_TEMPERATURE=y CONFIG_MODULES_GYRO_CALIBRATION=y -CONFIG_MODULES_MAG_BIAS_ESTIMATOR=y CONFIG_MODULES_SENSORS=y # CONFIG_SENSORS_VEHICLE_AIRSPEED is not set # CONFIG_SENSORS_VEHICLE_AIR_DATA is not set diff --git a/boards/nxp/mr-navq95/nuttx-config/scripts/itcm_functions_includes.ld b/boards/nxp/mr-navq95/nuttx-config/scripts/itcm_functions_includes.ld index ca22774088d..c74ddeb7eb8 100644 --- a/boards/nxp/mr-navq95/nuttx-config/scripts/itcm_functions_includes.ld +++ b/boards/nxp/mr-navq95/nuttx-config/scripts/itcm_functions_includes.ld @@ -446,7 +446,7 @@ *(.text._ZN13NavigatorMode3runEb) *(.text._ZL19param_find_internalPKcb) *(.text.uart_datasent) -*(.text._ZN4EKF221PublishOpticalFlowVelERKy) +*(.text._ZN17OpticalFlowSource7publishERK3Ekf) *(.text.nxsem_destroy) *(.text._ZN21MavlinkStreamAltitude4sendEv) *(.text._ZN7sensors14VehicleAirData12UpdateStatusEv) diff --git a/boards/nxp/mr-tropic/nuttx-config/scripts/itcm_functions_includes.ld b/boards/nxp/mr-tropic/nuttx-config/scripts/itcm_functions_includes.ld index 148327d06bc..6f9141d6a96 100644 --- a/boards/nxp/mr-tropic/nuttx-config/scripts/itcm_functions_includes.ld +++ b/boards/nxp/mr-tropic/nuttx-config/scripts/itcm_functions_includes.ld @@ -171,7 +171,8 @@ *(.text._ZN28MavlinkStreamGpsGlobalOrigin4sendEv) *(.text._ZN11ControlMath15bodyzToAttitudeEN6matrix7Vector3IfEEfR27vehicle_attitude_setpoint_s) *(.text._ZN4EKF217UpdateRangeSampleER17ekf2_timestamps_s) -*(.text._ZN3Ekf24controlOpticalFlowFusionERKN9estimator9imuSampleE) +*(.text._ZN17OpticalFlowAiding6updateER3EkfRKN9estimator9imuSampleE) +*(.text._ZN17OpticalFlowSource6updateER3EkfRKN9estimator9imuSampleEb) *(.text._ZN19MavlinkStreamRawRpm4sendEv) *(.text._ZN13MavlinkStream10const_rateEv) *(.text._ZN4EKF215PublishOdometryERKyRKN9estimator9imuSampleERKN6matrix7Vector3IfEE) @@ -338,7 +339,6 @@ *(.text._ZN14FlightTaskAutoD1Ev) *(.text._ZN4uORB10DeviceNode22get_initial_generationEv) *(.text._ZN3Ekf23controlGnssHeightFusionERKN9estimator10gnssSampleE) -*(.text._ZN3Ekf40updateOnGroundMotionForOpticalFlowChecksEv) *(.text._ZN6matrix6MatrixIfLj3ELj1EEC1Ev) *(.text._ZN14ZeroGyroUpdate6updateER3EkfRKN9estimator9imuSampleE) *(.text._ZN30MavlinkStreamOpenDroneIdSystem4sendEv) @@ -401,7 +401,7 @@ *(.text.nxsem_set_protocol) *(.text.write) *(.text._ZN22MavlinkStreamSysStatus4sendEv) -*(.text._ZN4EKF216UpdateFlowSampleER17ekf2_timestamps_s) +*(.text._ZN17OpticalFlowAiding13updateSamplesER3Ekf) *(.text._ZN4cdevL10cdev_ioctlEP4fileim) *(.text._ZN7Mavlink10send_bytesEPKhj) *(.text._ZNK8Failsafe17checkModeFallbackERK16failsafe_flags_sh) @@ -507,7 +507,7 @@ *(.text._ZN13NavigatorMode3runEb) *(.text._ZL19param_find_internalPKcb) *(.text.uart_datasent) -*(.text._ZN4EKF221PublishOpticalFlowVelERKy) +*(.text._ZN17OpticalFlowSource7publishERK3Ekf) *(.text.nxsem_destroy) *(.text.file_write) *(.text._ZN21MavlinkStreamAltitude4sendEv) diff --git a/boards/nxp/tropic-community/nuttx-config/scripts/itcm_functions_includes.ld b/boards/nxp/tropic-community/nuttx-config/scripts/itcm_functions_includes.ld index e39df739da0..4aae975a259 100644 --- a/boards/nxp/tropic-community/nuttx-config/scripts/itcm_functions_includes.ld +++ b/boards/nxp/tropic-community/nuttx-config/scripts/itcm_functions_includes.ld @@ -171,7 +171,8 @@ *(.text._ZN28MavlinkStreamGpsGlobalOrigin4sendEv) *(.text._ZN11ControlMath15bodyzToAttitudeEN6matrix7Vector3IfEEfR27vehicle_attitude_setpoint_s) *(.text._ZN4EKF217UpdateRangeSampleER17ekf2_timestamps_s) -*(.text._ZN3Ekf24controlOpticalFlowFusionERKN9estimator9imuSampleE) +*(.text._ZN17OpticalFlowAiding6updateER3EkfRKN9estimator9imuSampleE) +*(.text._ZN17OpticalFlowSource6updateER3EkfRKN9estimator9imuSampleEb) *(.text._ZN19MavlinkStreamRawRpm4sendEv) *(.text._ZN13MavlinkStream10const_rateEv) *(.text._ZN4EKF215PublishOdometryERKyRKN9estimator9imuSampleERKN6matrix7Vector3IfEE) @@ -338,7 +339,6 @@ *(.text._ZN14FlightTaskAutoD1Ev) *(.text._ZN4uORB10DeviceNode22get_initial_generationEv) *(.text._ZN3Ekf23controlGnssHeightFusionERKN9estimator10gnssSampleE) -*(.text._ZN3Ekf40updateOnGroundMotionForOpticalFlowChecksEv) *(.text._ZN6matrix6MatrixIfLj3ELj1EEC1Ev) *(.text._ZN14ZeroGyroUpdate6updateER3EkfRKN9estimator9imuSampleE) *(.text._ZN30MavlinkStreamOpenDroneIdSystem4sendEv) @@ -401,7 +401,7 @@ *(.text.nxsem_set_protocol) *(.text.write) *(.text._ZN22MavlinkStreamSysStatus4sendEv) -*(.text._ZN4EKF216UpdateFlowSampleER17ekf2_timestamps_s) +*(.text._ZN17OpticalFlowAiding13updateSamplesER3Ekf) *(.text._ZN4cdevL10cdev_ioctlEP4fileim) *(.text._ZN7Mavlink10send_bytesEPKhj) *(.text._ZNK8Failsafe17checkModeFallbackERK16failsafe_flags_sh) @@ -506,7 +506,7 @@ *(.text._ZN13NavigatorMode3runEb) *(.text._ZL19param_find_internalPKcb) *(.text.uart_datasent) -*(.text._ZN4EKF221PublishOpticalFlowVelERKy) +*(.text._ZN17OpticalFlowSource7publishERK3Ekf) *(.text.nxsem_destroy) *(.text.file_write) *(.text._ZN21MavlinkStreamAltitude4sendEv) diff --git a/boards/px4/fmu-v6xrt/nuttx-config/scripts/itcm_functions_includes.ld b/boards/px4/fmu-v6xrt/nuttx-config/scripts/itcm_functions_includes.ld index 58a96d058ab..cba31d50340 100644 --- a/boards/px4/fmu-v6xrt/nuttx-config/scripts/itcm_functions_includes.ld +++ b/boards/px4/fmu-v6xrt/nuttx-config/scripts/itcm_functions_includes.ld @@ -173,7 +173,8 @@ *(.text._ZN28MavlinkStreamGpsGlobalOrigin4sendEv) *(.text._ZN11ControlMath15bodyzToAttitudeEN6matrix7Vector3IfEEfR27vehicle_attitude_setpoint_s) *(.text._ZN4EKF217UpdateRangeSampleER17ekf2_timestamps_s) -*(.text._ZN3Ekf24controlOpticalFlowFusionERKN9estimator9imuSampleE) +*(.text._ZN17OpticalFlowAiding6updateER3EkfRKN9estimator9imuSampleE) +*(.text._ZN17OpticalFlowSource6updateER3EkfRKN9estimator9imuSampleEb) *(.text._ZN19MavlinkStreamRawRpm4sendEv) *(.text._ZN13MavlinkStream10const_rateEv) *(.text._ZN4EKF215PublishOdometryERKyRKN9estimator9imuSampleERKN6matrix7Vector3IfEE) @@ -344,7 +345,6 @@ *(.text._ZN14FlightTaskAutoD1Ev) *(.text._ZN4uORB10DeviceNode22get_initial_generationEv) *(.text._ZN3Ekf23controlGnssHeightFusionERKN9estimator10gnssSampleE) -*(.text._ZN3Ekf40updateOnGroundMotionForOpticalFlowChecksEv) *(.text._ZN6matrix6MatrixIfLj3ELj1EEC1Ev) *(.text._ZN14ZeroGyroUpdate6updateER3EkfRKN9estimator9imuSampleE) *(.text._ZN30MavlinkStreamOpenDroneIdSystem4sendEv) @@ -408,7 +408,7 @@ *(.text.nxsem_set_protocol) *(.text.write) *(.text._ZN22MavlinkStreamSysStatus4sendEv) -*(.text._ZN4EKF216UpdateFlowSampleER17ekf2_timestamps_s) +*(.text._ZN17OpticalFlowAiding13updateSamplesER3Ekf) *(.text._ZN4cdevL10cdev_ioctlEP4fileim) *(.text._ZN7Mavlink10send_bytesEPKhj) *(.text._ZNK8Failsafe17checkModeFallbackERK16failsafe_flags_sh) @@ -516,7 +516,7 @@ *(.text._ZN13NavigatorMode3runEb) *(.text._ZL19param_find_internalPKcb) *(.text.uart_datasent) -*(.text._ZN4EKF221PublishOpticalFlowVelERKy) +*(.text._ZN17OpticalFlowSource7publishERK3Ekf) *(.text.nxsem_destroy) *(.text.file_write) *(.text._ZN21MavlinkStreamAltitude4sendEv) diff --git a/docs/_link_checker_sc/ignore_errors.json b/docs/_link_checker_sc/ignore_errors.json index 0767d986dcf..268239e8fe1 100644 --- a/docs/_link_checker_sc/ignore_errors.json +++ b/docs/_link_checker_sc/ignore_errors.json @@ -808,7 +808,7 @@ }, { "type": "UrlToLocalSite", - "fileRelativeToRoot": "en\\gps_compass\\rtk_gps_hex_hereplus.md", + "fileRelativeToRoot": "en\\gps_compass\\rtk_gps_cubepilot_hereplus.md", "link": { "url": "https://docs.px4.io/v1.11/en/gps_compass/rtk_gps_hex_hereplus.html", "text": "PX4v1.11 docs" @@ -1598,7 +1598,7 @@ }, { "type": "UrlToLocalSite", - "fileRelativeToRoot": "en\\gps_compass\\rtk_gps_hex_hereplus.md", + "fileRelativeToRoot": "en\\gps_compass\\rtk_gps_cubepilot_hereplus.md", "link": { "url": "https://docs.px4.io/v1.11/en/gps_compass/rtk_gps_hex_hereplus", "text": "PX4v1.11 docs" diff --git a/docs/assets/flight_controller/accton-godwit_gfh7/block_diagram.svg b/docs/assets/flight_controller/accton-godwit_gfh7/block_diagram.svg new file mode 100644 index 00000000000..077c9868f3c --- /dev/null +++ b/docs/assets/flight_controller/accton-godwit_gfh7/block_diagram.svg @@ -0,0 +1,1849 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/docs/assets/flight_controller/accton-godwit_gfh7/gps.png b/docs/assets/flight_controller/accton-godwit_gfh7/gps.png new file mode 100644 index 00000000000..f98d9623270 Binary files /dev/null and b/docs/assets/flight_controller/accton-godwit_gfh7/gps.png differ diff --git a/docs/assets/flight_controller/accton-godwit_gfh7/motor_esc_wiring.png b/docs/assets/flight_controller/accton-godwit_gfh7/motor_esc_wiring.png new file mode 100644 index 00000000000..1e8e36e4f43 Binary files /dev/null and b/docs/assets/flight_controller/accton-godwit_gfh7/motor_esc_wiring.png differ diff --git a/docs/assets/flight_controller/accton-godwit_gfh7/orientation_back.png b/docs/assets/flight_controller/accton-godwit_gfh7/orientation_back.png new file mode 100644 index 00000000000..709f568c2d6 Binary files /dev/null and b/docs/assets/flight_controller/accton-godwit_gfh7/orientation_back.png differ diff --git a/docs/assets/flight_controller/accton-godwit_gfh7/orientation_front.png b/docs/assets/flight_controller/accton-godwit_gfh7/orientation_front.png new file mode 100644 index 00000000000..747146bcebe Binary files /dev/null and b/docs/assets/flight_controller/accton-godwit_gfh7/orientation_front.png differ diff --git a/docs/assets/flight_controller/accton-godwit_gfh7/outlook.png b/docs/assets/flight_controller/accton-godwit_gfh7/outlook.png new file mode 100644 index 00000000000..ca2608d0614 Binary files /dev/null and b/docs/assets/flight_controller/accton-godwit_gfh7/outlook.png differ diff --git a/docs/assets/flight_controller/accton-godwit_gfh7/pin_definition.png b/docs/assets/flight_controller/accton-godwit_gfh7/pin_definition.png new file mode 100644 index 00000000000..855849aaf3c Binary files /dev/null and b/docs/assets/flight_controller/accton-godwit_gfh7/pin_definition.png differ diff --git a/docs/assets/flight_controller/accton-godwit_gfh7/radio.png b/docs/assets/flight_controller/accton-godwit_gfh7/radio.png new file mode 100644 index 00000000000..d997d321851 Binary files /dev/null and b/docs/assets/flight_controller/accton-godwit_gfh7/radio.png differ diff --git a/docs/assets/flight_controller/accton-godwit_gfh7/sdcard.png b/docs/assets/flight_controller/accton-godwit_gfh7/sdcard.png new file mode 100644 index 00000000000..22f2b50a209 Binary files /dev/null and b/docs/assets/flight_controller/accton-godwit_gfh7/sdcard.png differ diff --git a/docs/assets/flight_controller/accton-godwit_gfh7/wiring_1.png b/docs/assets/flight_controller/accton-godwit_gfh7/wiring_1.png new file mode 100644 index 00000000000..ca40758f7b3 Binary files /dev/null and b/docs/assets/flight_controller/accton-godwit_gfh7/wiring_1.png differ diff --git a/docs/assets/flight_controller/accton-godwit_gfh7/wiring_2.png b/docs/assets/flight_controller/accton-godwit_gfh7/wiring_2.png new file mode 100644 index 00000000000..f364e49e20f Binary files /dev/null and b/docs/assets/flight_controller/accton-godwit_gfh7/wiring_2.png differ diff --git a/docs/en/SUMMARY.md b/docs/en/SUMMARY.md index 7a77ba4f226..7bf9c524183 100644 --- a/docs/en/SUMMARY.md +++ b/docs/en/SUMMARY.md @@ -158,12 +158,13 @@ - [Wiring Quickstart](assembly/quick_start_pixhawk4.md) - [mRo Pixracer (FMUv4)](flight_controller/pixracer.md) - [Wiring Quickstart](assembly/quick_start_pixracer.md) - - [Hex Cube Black (FMUv3)](flight_controller/pixhawk-2.md) + - [Cube Black (FMUv3)](flight_controller/pixhawk-2.md) - [mRo Pixhawk (FMUv3)](flight_controller/mro_pixhawk.md) - [mRo (3DR) Pixhawk Wiring Quickstart](assembly/quick_start_pixhawk.md) - [Manufacturer-Supported Autopilots](flight_controller/autopilot_manufacturer_supported.md) - [3DR Control N1](flight_controller/3dr_ctrl-n1.md) - [Accton Godwit GA1](flight_controller/accton-godwit_ga1.md) + - [Accton Godwit G-FH7](flight_controller/accton-godwit_gfh7.md) - [AEDROX AEDROXH7](flight_controller/aedrox_aedroxh7.md) - [Agam Autopilot v6X-RT](flight_controller/agam_v6xrt.md) - [AirMind MindPX](flight_controller/mindpx.md) @@ -273,7 +274,7 @@ - [CUAV NEO 3X GPS (CAN)](gps_compass/gps_cuav_neo_3x.md) - [Holybro DroneCAN M8N GPS (CAN)](dronecan/holybro_m8n_gps.md) - [LOCOSYS Hawk A1 GNSS](gps_compass/gps_locosys_hawk_a1.md) - - [✘ Hex Here2](gps_compass/gps_hex_here2.md) + - [✘ CubePilot Here2](gps_compass/gps_cubepilot_here2.md) - [Holybro M8N & M9N GPS](gps_compass/gps_holybro_m8n_m9n.md) - [Sky-Drones SmartAP GPS](gps_compass/gps_smartap.md) - [RTK GNSS](gps_compass/rtk_gps.md) @@ -287,6 +288,7 @@ - [CUAV C-RTK](gps_compass/rtk_gps_cuav_c-rtk.md) - [CUAV C-RTK2 PPK/RTK GNSS](gps_compass/rtk_gps_cuav_c-rtk2.md) - [CUAV C-RTK 9Ps](gps_compass/rtk_gps_cuav_c-rtk-9ps.md) + - [CubePilot Here4 (CAN)](dronecan/cubepilot_here4.md) - [DATAGNSS NANO HRTK GNSS](gps_compass/rtk_gps_datagnss_nano_hrtk.md) - [DATAGNSS GEM1305 RTK GNSS](gps_compass/rtk_gps_gem1305.md) - [Femtones MINI2 Receiver](gps_compass/rtk_gps_fem_mini2.md) @@ -301,7 +303,7 @@ - [Septentrio AsteRx-m3 Pro](gps_compass/septentrio_asterx-rib.md) - [Septentrio mosaic-go](gps_compass/septentrio_mosaic-go.md) - [Trimble MB-Two](gps_compass/rtk_gps_trimble_mb_two.md) - - [✘ CubePilot Here+](gps_compass/rtk_gps_hex_hereplus.md) + - [✘ CubePilot Here+](gps_compass/rtk_gps_cubepilot_hereplus.md) - [INS (Inertial Navigation/GNSS)](sensor/inertial_navigation_systems.md) - [InertialLabs](sensor/inertiallabs.md) - [MicroStrain](sensor/microstrain.md) diff --git a/docs/en/advanced/parameters_and_configurations.md b/docs/en/advanced/parameters_and_configurations.md index d9442af6cab..9b4f258ffa8 100644 --- a/docs/en/advanced/parameters_and_configurations.md +++ b/docs/en/advanced/parameters_and_configurations.md @@ -162,6 +162,8 @@ First include the required needed headers in the class header for your module or Derive your class from `ModuleParams`, and use `DEFINE_PARAMETERS` to specify a list of parameters and their associated parameter attributes. The names of the parameters must be the same as their parameter metadata definitions. +Name each parameter attribute `_param_` followed by the lower case parameter name (e.g. `_param_sys_autostart` for `SYS_AUTOSTART`), so that searching for a parameter name also finds the code that uses it. +`make check_format` enforces this convention, and `make format` renames attributes that do not follow it. ```cpp class MyModule : ..., public ModuleParams @@ -177,8 +179,8 @@ private: void parameters_update(); DEFINE_PARAMETERS( - (ParamInt) _sys_autostart, /**< example parameter */ - (ParamFloat) _att_bias_max /**< another parameter */ + (ParamInt) _param_sys_autostart, /**< example parameter */ + (ParamFloat) _param_att_bias_max /**< another parameter */ ) // Subscriptions @@ -212,7 +214,7 @@ In the above method: - Then we call `ModuleParams::updateParams()`. This "under the hood" updates all parameter attributes listed in our `DEFINE_PARAMETERS` list. -The parameter attributes (`_sys_autostart` and `_att_bias_max` in this case) can then be used to represent the parameters, and will be updated whenever the parameter value changes. +The parameter attributes (`_param_sys_autostart` and `_param_att_bias_max` in this case) can then be used to represent the parameters, and will be updated whenever the parameter value changes. :::tip The [Application/Module Template](../modules/module_template.md) uses the new-style C++ API but does not include [parameter metadata](#parameter-metadata). diff --git a/docs/en/advanced_config/parameter_reference.md b/docs/en/advanced_config/parameter_reference.md index ba9efdc0019..d6b58d15c88 100644 --- a/docs/en/advanced_config/parameter_reference.md +++ b/docs/en/advanced_config/parameter_reference.md @@ -29034,6 +29034,7 @@ Triggers when the active GNSS count drops below SYS_HAS_NUM_GNSS (disabled when SYS_HAS_NUM_GNSS=0), or when two receivers report positions inconsistent with their reported accuracy and SYS_HAS_NUM_GNSS=2 (otherwise warning only). The reported accuracy of each receiver is floored with EKF2_GPS_P_NOISE. +Return and Land are skipped if the failure clears during the COM_FAIL_ACT_T Hold. Any value above Warning also blocks arming. @@ -30889,7 +30890,7 @@ Reboot | minValue | maxValue | increment | default | unit | Read-Only ## EKF2 -
+
@@ -32502,11 +32503,11 @@ Reboot | minValue | maxValue | increment | default | unit | Read-Only
-### EKF2_OF_CTRL (`INT32`) {#EKF2_OF_CTRL} +### EKF2_OF0_CTRL (`INT32`) {#EKF2_OF0_CTRL} -Optical flow aiding. +Optical flow sensor 0 aiding. -Enable optical flow fusion. +Enable optical flow fusion for sensor slot 0. **Values:** @@ -32522,26 +32523,9 @@ Reboot | minValue | maxValue | increment | default | unit | Read-Only
-### EKF2_OF_DELAY (`FLOAT`) {#EKF2_OF_DELAY} +### EKF2_OF0_GATE (`FLOAT`) {#EKF2_OF0_GATE} -Optical flow measurement delay relative to IMU measurements. - -Assumes measurement is timestamped at trailing edge of integration -period. The default matches a DroneCAN flow node, whose frame reaches -the flight controller about 7 ms after its integration window closes. - - -Reboot | minValue | maxValue | increment | default | unit | Read-Only ---- | --- | --- | --- | --- | --- | --- -✓ | 0 | 300 | | 7 | ms |   - -
- -
- -### EKF2_OF_GATE (`FLOAT`) {#EKF2_OF_GATE} - -Gate size for optical flow fusion. +Gate size for optical flow sensor 0 fusion. Sets the number of standard deviations used by the innovation consistency test. @@ -32554,9 +32538,9 @@ Reboot | minValue | maxValue | increment | default | unit | Read-Only
-### EKF2_OF_GYR_SRC (`INT32`) {#EKF2_OF_GYR_SRC} +### EKF2_OF0_GYR_SRC (`INT32`) {#EKF2_OF0_GYR_SRC} -Optical flow angular rate compensation source. +Optical flow sensor 0 angular rate compensation source. Auto: use gyro from optical flow message if available, internal gyro otherwise. Internal: always use internal gyro @@ -32575,9 +32559,9 @@ Reboot | minValue | maxValue | increment | default | unit | Read-Only
-### EKF2_OF_N_MAX (`FLOAT`) {#EKF2_OF_N_MAX} +### EKF2_OF0_N_MAX (`FLOAT`) {#EKF2_OF0_N_MAX} -Optical flow maximum noise. +Optical flow sensor 0 maximum noise. Measurement noise for the optical flow sensor when it's reported quality metric is at the minimum @@ -32590,9 +32574,9 @@ Reboot | minValue | maxValue | increment | default | unit | Read-Only
-### EKF2_OF_N_MIN (`FLOAT`) {#EKF2_OF_N_MIN} +### EKF2_OF0_N_MIN (`FLOAT`) {#EKF2_OF0_N_MIN} -Optical flow minimum noise. +Optical flow sensor 0 minimum noise. Measurement noise for the optical flow sensor when it's reported quality metric is at the maximum @@ -32605,56 +32589,11 @@ Reboot | minValue | maxValue | increment | default | unit | Read-Only
-### EKF2_OF_POS_X (`FLOAT`) {#EKF2_OF_POS_X} +### EKF2_OF0_QMIN (`INT32`) {#EKF2_OF0_QMIN} -X position of optical flow focal point in body frame. +In air optical flow sensor 0 minimum quality. -Forward axis with origin relative to vehicle centre of gravity - - -Reboot | minValue | maxValue | increment | default | unit | Read-Only ---- | --- | --- | --- | --- | --- | --- -  | | | | 0.0 | m |   - -
- -
- -### EKF2_OF_POS_Y (`FLOAT`) {#EKF2_OF_POS_Y} - -Y position of optical flow focal point in body frame. - -Forward axis with origin relative to vehicle centre of gravity - - -Reboot | minValue | maxValue | increment | default | unit | Read-Only ---- | --- | --- | --- | --- | --- | --- -  | | | | 0.0 | m |   - -
- -
- -### EKF2_OF_POS_Z (`FLOAT`) {#EKF2_OF_POS_Z} - -Z position of optical flow focal point in body frame. - -Forward axis with origin relative to vehicle centre of gravity - - -Reboot | minValue | maxValue | increment | default | unit | Read-Only ---- | --- | --- | --- | --- | --- | --- -  | | | | 0.0 | m |   - -
- -
- -### EKF2_OF_QMIN (`INT32`) {#EKF2_OF_QMIN} - -In air optical flow minimum quality. - -Optical Flow data will only be used in air if the sensor reports a quality metric >= EKF2_OF_QMIN +Optical Flow data will only be used in air if the sensor reports a quality metric >= EKF2_OF0_QMIN Reboot | minValue | maxValue | increment | default | unit | Read-Only @@ -32665,11 +32604,127 @@ Reboot | minValue | maxValue | increment | default | unit | Read-Only
-### EKF2_OF_QMIN_GND (`INT32`) {#EKF2_OF_QMIN_GND} +### EKF2_OF0_QMINGND (`INT32`) {#EKF2_OF0_QMINGND} -On ground optical flow minimum quality. +On ground optical flow sensor 0 minimum quality. -Optical Flow data will only be used on the ground if the sensor reports a quality metric >= EKF2_OF_QMIN_GND +Optical Flow data will only be used on the ground if the sensor reports a quality metric >= EKF2_OF0_QMINGND + + +Reboot | minValue | maxValue | increment | default | unit | Read-Only +--- | --- | --- | --- | --- | --- | --- +  | 0 | 255 | | 0 | |   + +
+ +
+ +### EKF2_OF1_CTRL (`INT32`) {#EKF2_OF1_CTRL} + +Optical flow sensor 1 aiding. + +Enable optical flow fusion for sensor slot 1. + + +**Values:** + +- `0`: Disabled +- `1`: Enabled + +Reboot | minValue | maxValue | increment | default | unit | Read-Only +--- | --- | --- | --- | --- | --- | --- +  | | | | Disabled (0) | |   + +
+ +
+ +### EKF2_OF1_GATE (`FLOAT`) {#EKF2_OF1_GATE} + +Gate size for optical flow sensor 1 fusion. + +Sets the number of standard deviations used by the innovation consistency test. + + +Reboot | minValue | maxValue | increment | default | unit | Read-Only +--- | --- | --- | --- | --- | --- | --- +  | 1.0 | | | 3.0 | SD |   + +
+ +
+ +### EKF2_OF1_GYR_SRC (`INT32`) {#EKF2_OF1_GYR_SRC} + +Optical flow sensor 1 angular rate compensation source. + +Auto: use gyro from optical flow message if available, internal gyro otherwise. Internal: always use internal gyro + + +**Values:** + +- `0`: Auto +- `1`: Internal + + +Reboot | minValue | maxValue | increment | default | unit | Read-Only +--- | --- | --- | --- | --- | --- | --- +  | | | | 0 | |   + +
+ +
+ +### EKF2_OF1_N_MAX (`FLOAT`) {#EKF2_OF1_N_MAX} + +Optical flow sensor 1 maximum noise. + +Measurement noise for the optical flow sensor when it's reported quality metric is at the minimum + + +Reboot | minValue | maxValue | increment | default | unit | Read-Only +--- | --- | --- | --- | --- | --- | --- +  | 0.05 | | | 0.5 | rad/s |   + +
+ +
+ +### EKF2_OF1_N_MIN (`FLOAT`) {#EKF2_OF1_N_MIN} + +Optical flow sensor 1 minimum noise. + +Measurement noise for the optical flow sensor when it's reported quality metric is at the maximum + + +Reboot | minValue | maxValue | increment | default | unit | Read-Only +--- | --- | --- | --- | --- | --- | --- +  | 0.05 | | | 0.15 | rad/s |   + +
+ +
+ +### EKF2_OF1_QMIN (`INT32`) {#EKF2_OF1_QMIN} + +In air optical flow sensor 1 minimum quality. + +Optical Flow data will only be used in air if the sensor reports a quality metric >= EKF2_OF1_QMIN + + +Reboot | minValue | maxValue | increment | default | unit | Read-Only +--- | --- | --- | --- | --- | --- | --- +  | 0 | 255 | | 1 | |   + +
+ +
+ +### EKF2_OF1_QMINGND (`INT32`) {#EKF2_OF1_QMINGND} + +On ground optical flow sensor 1 minimum quality. + +Optical Flow data will only be used on the ground if the sensor reports a quality metric >= EKF2_OF1_QMINGND Reboot | minValue | maxValue | increment | default | unit | Read-Only @@ -35660,7 +35715,7 @@ Reboot | minValue | maxValue | increment | default | unit | Read-Only ## Failure Detector -
+
@@ -35734,78 +35789,6 @@ Reboot | minValue | maxValue | increment | default | unit | Read-Only
-### FD_FAIL_P (`INT32`) {#FD_FAIL_P} - -FailureDetector Max Pitch. - -Maximum pitch angle before FailureDetector triggers the attitude_failure flag. -The flag triggers flight termination (if @CBRK_FLIGHTTERM = 0), -which sets outputs to their failsafe values. -On takeoff the flag triggers lockdown (irrespective of @CBRK_FLIGHTTERM), -which disarms motors but does not set outputs to failsafe values. - -Setting this parameter to 0 disables the check - - -Reboot | minValue | maxValue | increment | default | unit | Read-Only ---- | --- | --- | --- | --- | --- | --- -  | 0 | 180 | | 60 | deg |   - -
- -
- -### FD_FAIL_P_TTRI (`FLOAT`) {#FD_FAIL_P_TTRI} - -Pitch failure trigger time. - -Seconds (decimal) that pitch has to exceed FD_FAIL_P before being considered as a failure. - - -Reboot | minValue | maxValue | increment | default | unit | Read-Only ---- | --- | --- | --- | --- | --- | --- -  | 0.02 | 5 | | 0.3 | s |   - -
- -
- -### FD_FAIL_R (`INT32`) {#FD_FAIL_R} - -FailureDetector Max Roll. - -Maximum roll angle before FailureDetector triggers the attitude_failure flag. -The flag triggers flight termination (if @CBRK_FLIGHTTERM = 0), -which sets outputs to their failsafe values. -On takeoff the flag triggers lockdown (irrespective of @CBRK_FLIGHTTERM), -which disarms motors but does not set outputs to failsafe values. - -Setting this parameter to 0 disables the check - - -Reboot | minValue | maxValue | increment | default | unit | Read-Only ---- | --- | --- | --- | --- | --- | --- -  | 0 | 180 | | 60 | deg |   - -
- -
- -### FD_FAIL_R_TTRI (`FLOAT`) {#FD_FAIL_R_TTRI} - -Roll failure trigger time. - -Seconds (decimal) that roll has to exceed FD_FAIL_R before being considered as a failure. - - -Reboot | minValue | maxValue | increment | default | unit | Read-Only ---- | --- | --- | --- | --- | --- | --- -  | 0.02 | 5 | | 0.3 | s |   - -
- -
- ### FD_IMB_PROP_THR (`INT32`) {#FD_IMB_PROP_THR} Imbalanced propeller check threshold. @@ -35822,6 +35805,44 @@ Reboot | minValue | maxValue | increment | default | unit | Read-Only
+
+ +### FD_TILT_ERROR (`FLOAT`) {#FD_TILT_ERROR} + +FailureDetector Max Tilt Error. + +Maximum angle between the vehicle tilt and the attitude setpoint tilt before FailureDetector triggers the attitude_failure flag. +Without a recent attitude setpoint, e.g. on rovers, the tilt from level is checked instead. +The flag triggers flight termination (if @CBRK_FLIGHTTERM = 0), +which sets outputs to their failsafe values. +On takeoff the flag triggers lockdown (irrespective of @CBRK_FLIGHTTERM), +which disarms motors but does not set outputs to failsafe values. +The check is paused for the first 5 s after a VTOL quad-chute or aborted front transition. + +Set to -1 to disable. + + +Reboot | minValue | maxValue | increment | default | unit | Read-Only +--- | --- | --- | --- | --- | --- | --- +  | -1 | 180 | | 60 | deg |   + +
+ +
+ +### FD_TILT_ERROR_T (`FLOAT`) {#FD_TILT_ERROR_T} + +Tilt failure trigger time. + +Seconds (decimal) that the tilt error has to exceed FD_TILT_ERROR before being considered as a failure. + + +Reboot | minValue | maxValue | increment | default | unit | Read-Only +--- | --- | --- | --- | --- | --- | --- +  | 0.02 | 5 | | 1.0 | s |   + +
+
## Failure Injection @@ -44004,7 +44025,7 @@ before takeoff using gyro data. Reboot | minValue | maxValue | increment | default | unit | Read-Only --- | --- | --- | --- | --- | --- | --- -✓ | | | | Enabled (1) | |   +✓ | | | | Disabled (0) | |  
@@ -50639,7 +50660,7 @@ Return mode destination and flight path (home location, rally point, mission lan - 5 (Direct to rally point only): Return directly to safe landing point (do not consider mission landing and Home). -- 6 (Home if battery allows, else rally point): Return to home if time estimate to home is less than battery remaining estimate, else return to the closest rally point. If battery remaining estimate is not available, return to the closest safe point (home or rally point). +- 6 (Home if battery allows, else rally point): Return to home if time estimate to home is less than battery remaining estimate. Otherwise, or if battery remaining estimate is not available, return to the closest safe point (home or rally point). **Values:** @@ -51911,7 +51932,7 @@ Reboot | minValue | maxValue | increment | default | unit | Read-Only ## Sensor Calibration -
+
@@ -54816,9 +54837,27 @@ Reboot | minValue | maxValue | increment | default | unit | Read-Only
-### SENS_FLOW_MAXHGT (`FLOAT`) {#SENS_FLOW_MAXHGT} +### SENS_FLOW0_DELAY (`FLOAT`) {#SENS_FLOW0_DELAY} -Maximum height above ground when reliant on optical flow. +Optical flow sensor 0 measurement delay relative to IMU. + +Assumes measurement is timestamped at trailing edge of integration +period. Applied to timestamp_sample of the published data. The default +matches a DroneCAN flow node, whose frame reaches the flight controller +about 7 ms after its integration window closes. + + +Reboot | minValue | maxValue | increment | default | unit | Read-Only +--- | --- | --- | --- | --- | --- | --- +✓ | 0 | 300 | | 7.0 | ms |   + +
+ +
+ +### SENS_FLOW0_HMAX (`FLOAT`) {#SENS_FLOW0_HMAX} + +Maximum height above ground when reliant on optical flow 0. This parameter defines the maximum distance from ground at which the optical flow sensor operates reliably. The height setpoint will be limited to be no greater than this value when the navigation system @@ -54834,9 +54873,40 @@ Reboot | minValue | maxValue | increment | default | unit | Read-Only
-### SENS_FLOW_MAXR (`FLOAT`) {#SENS_FLOW_MAXR} +### SENS_FLOW0_HMIN (`FLOAT`) {#SENS_FLOW0_HMIN} -Max angular flow rate measurable by sensor. +Minimum height above ground when reliant on optical flow 0. + +This parameter defines the minimum distance from ground at which the optical flow sensor operates reliably. +The sensor may be usable below this height, but accuracy will progressively reduce to loss of focus. + + +Reboot | minValue | maxValue | increment | default | unit | Read-Only +--- | --- | --- | --- | --- | --- | --- +  | 0.0 | 1.0 | 0.1 | 0.08 | m |   + +
+ +
+ +### SENS_FLOW0_ID (`INT32`) {#SENS_FLOW0_ID} + +Optical flow sensor 0 ID. + +Device ID of the flow sensor configured by the SENS_FLOW0_* parameters. Set to 0 to automatically bind the first unbound sensor reporting data. + + +Reboot | minValue | maxValue | increment | default | unit | Read-Only +--- | --- | --- | --- | --- | --- | --- +✓ | | | | 0 | |   + +
+ +
+ +### SENS_FLOW0_MAXR (`FLOAT`) {#SENS_FLOW0_MAXR} + +Max angular flow rate measurable by sensor 0. Magnitude of maximum angular flow rate reliably measurable by the optical flow sensor @@ -54853,9 +54923,90 @@ Reboot | minValue | maxValue | increment | default | unit | Read-Only
-### SENS_FLOW_MINHGT (`FLOAT`) {#SENS_FLOW_MINHGT} +### SENS_FLOW0_POS_X (`FLOAT`) {#SENS_FLOW0_POS_X} -Minimum height above ground when reliant on optical flow. +X position of optical flow sensor 0 focal point in body frame. + +Forward axis with origin relative to vehicle centre of gravity + + +Reboot | minValue | maxValue | increment | default | unit | Read-Only +--- | --- | --- | --- | --- | --- | --- +  | | | | 0.0 | m |   + +
+ +
+ +### SENS_FLOW0_POS_Y (`FLOAT`) {#SENS_FLOW0_POS_Y} + +Y position of optical flow sensor 0 focal point in body frame. + +Right axis with origin relative to vehicle centre of gravity + + +Reboot | minValue | maxValue | increment | default | unit | Read-Only +--- | --- | --- | --- | --- | --- | --- +  | | | | 0.0 | m |   + +
+ +
+ +### SENS_FLOW0_POS_Z (`FLOAT`) {#SENS_FLOW0_POS_Z} + +Z position of optical flow sensor 0 focal point in body frame. + +Down axis with origin relative to vehicle centre of gravity + + +Reboot | minValue | maxValue | increment | default | unit | Read-Only +--- | --- | --- | --- | --- | --- | --- +  | | | | 0.0 | m |   + +
+ +
+ +### SENS_FLOW1_DELAY (`FLOAT`) {#SENS_FLOW1_DELAY} + +Optical flow sensor 1 measurement delay relative to IMU. + +Assumes measurement is timestamped at trailing edge of integration +period. Applied to timestamp_sample of the published data. The default +matches a DroneCAN flow node, whose frame reaches the flight controller +about 7 ms after its integration window closes. + + +Reboot | minValue | maxValue | increment | default | unit | Read-Only +--- | --- | --- | --- | --- | --- | --- +✓ | 0 | 300 | | 7.0 | ms |   + +
+ +
+ +### SENS_FLOW1_HMAX (`FLOAT`) {#SENS_FLOW1_HMAX} + +Maximum height above ground when reliant on optical flow 1. + +This parameter defines the maximum distance from ground at which the optical flow sensor operates reliably. +The height setpoint will be limited to be no greater than this value when the navigation system +is completely reliant on optical flow data and the height above ground estimate is valid. +The sensor may be usable above this height, but accuracy will progressively degrade. + + +Reboot | minValue | maxValue | increment | default | unit | Read-Only +--- | --- | --- | --- | --- | --- | --- +  | 1.0 | 100.0 | 0.1 | 100.0 | m |   + +
+ +
+ +### SENS_FLOW1_HMIN (`FLOAT`) {#SENS_FLOW1_HMIN} + +Minimum height above ground when reliant on optical flow 1. This parameter defines the minimum distance from ground at which the optical flow sensor operates reliably. The sensor may be usable below this height, but accuracy will progressively reduce to loss of focus. @@ -54867,11 +55018,90 @@ Reboot | minValue | maxValue | increment | default | unit | Read-Only
+
+ +### SENS_FLOW1_ID (`INT32`) {#SENS_FLOW1_ID} + +Optical flow sensor 1 ID. + +Device ID of the flow sensor configured by the SENS_FLOW1_* parameters. Set to 0 to automatically bind the first unbound sensor reporting data. + + +Reboot | minValue | maxValue | increment | default | unit | Read-Only +--- | --- | --- | --- | --- | --- | --- +✓ | | | | 0 | |   + +
+ +
+ +### SENS_FLOW1_MAXR (`FLOAT`) {#SENS_FLOW1_MAXR} + +Max angular flow rate measurable by sensor 1. + +Magnitude of maximum angular flow rate reliably measurable by the optical flow sensor + +Optical flow data will not fused by the estimators if the magnitude of the flow rate exceeds this value and +control loops will be instructed to limit ground speed such that the flow rate produced by movement over ground +is less than 50% of this value. + + +Reboot | minValue | maxValue | increment | default | unit | Read-Only +--- | --- | --- | --- | --- | --- | --- +  | 1.0 | | | 8.0 | rad/s |   + +
+ +
+ +### SENS_FLOW1_POS_X (`FLOAT`) {#SENS_FLOW1_POS_X} + +X position of optical flow sensor 1 focal point in body frame. + +Forward axis with origin relative to vehicle centre of gravity + + +Reboot | minValue | maxValue | increment | default | unit | Read-Only +--- | --- | --- | --- | --- | --- | --- +  | | | | 0.0 | m |   + +
+ +
+ +### SENS_FLOW1_POS_Y (`FLOAT`) {#SENS_FLOW1_POS_Y} + +Y position of optical flow sensor 1 focal point in body frame. + +Right axis with origin relative to vehicle centre of gravity + + +Reboot | minValue | maxValue | increment | default | unit | Read-Only +--- | --- | --- | --- | --- | --- | --- +  | | | | 0.0 | m |   + +
+ +
+ +### SENS_FLOW1_POS_Z (`FLOAT`) {#SENS_FLOW1_POS_Z} + +Z position of optical flow sensor 1 focal point in body frame. + +Down axis with origin relative to vehicle centre of gravity + + +Reboot | minValue | maxValue | increment | default | unit | Read-Only +--- | --- | --- | --- | --- | --- | --- +  | | | | 0.0 | m |   + +
+
## Sensors -
+
@@ -57332,7 +57562,8 @@ Reboot | minValue | maxValue | increment | default | unit | Read-Only Barometer auto calibration. -Automatically calibrate barometer based on the GNSS height +Automatically calibrate barometer based on the GNSS height. +Keeps recalibrating while landed and disarmed when the baro drifts away from the GNSS height. **Values:** @@ -58429,9 +58660,9 @@ Reboot | minValue | maxValue | increment | default | unit | Read-Only
-### SENS_FLOW_RATE (`FLOAT`) {#SENS_FLOW_RATE} +### SENS_FLOW0_RATE (`FLOAT`) {#SENS_FLOW0_RATE} -Optical flow max rate. +Optical flow 0 max rate. Optical flow data maximum publication rate. This is an upper bound, actual optical flow data rate is still dependent on the sensor. @@ -58445,9 +58676,9 @@ Reboot | minValue | maxValue | increment | default | unit | Read-Only
-### SENS_FLOW_ROT (`INT32`) {#SENS_FLOW_ROT} +### SENS_FLOW0_ROT (`INT32`) {#SENS_FLOW0_ROT} -Optical flow rotation. +Optical flow 0 rotation. This parameter defines the yaw rotation of the optical flow relative to the vehicle body frame. Zero rotation is defined as X on flow board pointing towards front of vehicle. @@ -58473,9 +58704,65 @@ Reboot | minValue | maxValue | increment | default | unit | Read-Only
-### SENS_FLOW_SCALE (`FLOAT`) {#SENS_FLOW_SCALE} +### SENS_FLOW0_SCALE (`FLOAT`) {#SENS_FLOW0_SCALE} -Optical flow scale factor. +Optical flow 0 scale factor. + +Reboot | minValue | maxValue | increment | default | unit | Read-Only +--- | --- | --- | --- | --- | --- | --- +  | 0.5 | 1.5 | | 1.0 | |   + +
+ +
+ +### SENS_FLOW1_RATE (`FLOAT`) {#SENS_FLOW1_RATE} + +Optical flow 1 max rate. + +Optical flow data maximum publication rate. This is an upper bound, +actual optical flow data rate is still dependent on the sensor. + + +Reboot | minValue | maxValue | increment | default | unit | Read-Only +--- | --- | --- | --- | --- | --- | --- +✓ | 1 | 200 | | 70.0 | Hz |   + +
+ +
+ +### SENS_FLOW1_ROT (`INT32`) {#SENS_FLOW1_ROT} + +Optical flow 1 rotation. + +This parameter defines the yaw rotation of the optical flow relative to the vehicle body frame. +Zero rotation is defined as X on flow board pointing towards front of vehicle. + + +**Values:** + +- `0`: No rotation +- `1`: Yaw 45° +- `2`: Yaw 90° +- `3`: Yaw 135° +- `4`: Yaw 180° +- `5`: Yaw 225° +- `6`: Yaw 270° +- `7`: Yaw 315° + + +Reboot | minValue | maxValue | increment | default | unit | Read-Only +--- | --- | --- | --- | --- | --- | --- +  | | | | 0 | |   + +
+ +
+ +### SENS_FLOW1_SCALE (`FLOAT`) {#SENS_FLOW1_SCALE} + +Optical flow 1 scale factor. Reboot | minValue | maxValue | increment | default | unit | Read-Only --- | --- | --- | --- | --- | --- | --- @@ -59027,7 +59314,7 @@ Reboot | minValue | maxValue | increment | default | unit | Read-Only Magnetometer auto calibration. -Automatically initialize magnetometer calibration from bias estimate if available. The estimate only captures hard-iron offsets, so a full calibration is still recommended. Mainly intended for remote nodes (e.g. CAN GPS units) that cannot be calibrated from a ground station. +Automatically initialize magnetometer calibration from bias estimate if available. The estimate only captures hard-iron offsets, so a full calibration is still recommended. **Values:** @@ -62150,6 +62437,7 @@ Vehicle type. - `3`: Standard VTOL - `4`: Hexacopter - `5`: Rover Ackermann +- `6`: Rover Differential Reboot | minValue | maxValue | increment | default | unit | Read-Only @@ -69420,7 +69708,7 @@ Reboot | minValue | maxValue | increment | default | unit | Read-Only ## VTOL Attitude Control -
+
@@ -69527,6 +69815,51 @@ Reboot | minValue | maxValue | increment | default | unit | Read-Only
+### VT_EF_THROT (`FLOAT`) {#VT_EF_THROT} + +Pusher failure detection throttle threshold. + +Has to be below the highest pusher assist throttle, which VT_FWD_THRUST_SC, VT_PITCH_MIN and MPC_TILTMAX_AIR set. + + +Reboot | minValue | maxValue | increment | default | unit | Read-Only +--- | --- | --- | --- | --- | --- | --- +  | 0.0 | 0.9 | 0.01 | 0.4 | |   + +
+ +
+ +### VT_EF_TIME (`FLOAT`) {#VT_EF_TIME} + +Pusher failure detection time. + +A pusher failure is detected in multicopter mode when, for this time, the pusher assist throttle is above VT_EF_THROT, but the forward velocity stays more than VT_EF_VEL_ERR below its setpoint. It is handled as a quad-chute that blocks front transitions until reboot or until disabled. Only used by standard VTOLs when VT_FWD_THRUST_EN is enabled. Set to 0 to disable. + + +Reboot | minValue | maxValue | increment | default | unit | Read-Only +--- | --- | --- | --- | --- | --- | --- +  | 0.0 | 20.0 | 0.1 | 5.0 | s |   + +
+ +
+ +### VT_EF_VEL_ERR (`FLOAT`) {#VT_EF_VEL_ERR} + +Pusher failure detection forward velocity error. + +Forward velocity setpoint minus forward velocity above which pusher assist above VT_EF_THROT is considered ineffective, see VT_EF_TIME. + + +Reboot | minValue | maxValue | increment | default | unit | Read-Only +--- | --- | --- | --- | --- | --- | --- +  | 0.5 | 10.0 | 0.1 | 3.5 | m/s |   + +
+ +
+ ### VT_ELEV_MC_LOCK (`INT32`) {#VT_ELEV_MC_LOCK} Lock control surfaces in hover. diff --git a/docs/en/advanced_config/tuning_the_ecl_ekf.md b/docs/en/advanced_config/tuning_the_ecl_ekf.md index 39d6bcda5c5..817a005b9ae 100644 --- a/docs/en/advanced_config/tuning_the_ecl_ekf.md +++ b/docs/en/advanced_config/tuning_the_ecl_ekf.md @@ -529,11 +529,13 @@ A good tuning is obtained as follows: [Optical flow](../sensor/optical_flow.md) data will be used if the following conditions are met: - Valid range finder data is available. -- [EKF2_OF_CTRL](../advanced_config/parameter_reference.md#EKF2_OF_CTRL) is set. -- The quality metric returned by the flow sensor is greater than the minimum requirement set by the [EKF2_OF_QMIN](../advanced_config/parameter_reference.md#EKF2_OF_QMIN) parameter. +- [EKF2_OF0_CTRL](../advanced_config/parameter_reference.md#EKF2_OF0_CTRL) is set. +- The quality metric returned by the flow sensor is greater than the minimum requirement set by the [EKF2_OF0_QMIN](../advanced_config/parameter_reference.md#EKF2_OF0_QMIN) parameter. +- For a second flow sensor [EKF2_OF1_CTRL](../advanced_config/parameter_reference.md#EKF2_OF1_CTRL) is set and the quality metric is greater than [EKF2_OF1_QMIN](../advanced_config/parameter_reference.md#EKF2_OF1_QMIN). -For better performance, set the location of the optical flow sensor as described [here](../sensor/optical_flow.md#ekf2). +Up to two optical flow sensors can be fused at the same time, each with its own set of `EKF2_OFn_*` parameters (see [Optical Flow > Multiple Optical Flow Sensors](../sensor/optical_flow.md#multiple-flow-sensors)). +For better performance, set the location of the optical flow sensor as described in [Optical Flow > EKF2](../sensor/optical_flow.md#ekf2). If a stable hover can be achieved at low altitude above ground (< 10m) but slow oscillations occur at higher altitude, consider adjusting the [optical flow scale factor](../sensor/optical_flow.md#scale-factor). ### External Vision System diff --git a/docs/en/assembly/quick_start_cube.md b/docs/en/assembly/quick_start_cube.md index 1bca1fbf51a..3ef8deb0384 100644 --- a/docs/en/assembly/quick_start_cube.md +++ b/docs/en/assembly/quick_start_cube.md @@ -66,12 +66,12 @@ Customized screws are supposed to be M2.5 with thread length inside Cube in rang ## GPS + Compass + Safety Switch + LED -The recommended GPS modules are the _Here_ and [Here+](../gps_compass/rtk_gps_hex_hereplus.md), both of which incorporate a GPS module, Compass, Safety Switch and [LEDs](../getting_started/led_meanings.md). +The recommended GPS modules are the _Here_ and [Here+](../gps_compass/rtk_gps_cubepilot_hereplus.md), both of which incorporate a GPS module, Compass, Safety Switch and [LEDs](../getting_started/led_meanings.md). The difference between the modules is that _Here+_ supports centimeter level positioning via [RTK](../gps_compass/rtk_gps.md). Otherwise they are used/connected in the same way. :::warning -The [Here+](../gps_compass/rtk_gps_hex_hereplus.md) has been superseded by the [Here3](https://www.cubepilot.org/#/here/here3) a [DroneCAN](../dronecan/index.md) RTK-GNSS that incorporate a compass and [LEDs](../getting_started/led_meanings.md) (but no safety switch). -See [DroneCAN](../dronecan/index.md) for _Here3_ wiring and PX4 configuration information. +The [Here+](../gps_compass/rtk_gps_cubepilot_hereplus.md) has been superseded by [DroneCAN](../dronecan/index.md) RTK GNSS modules such as the [Here4](../dronecan/cubepilot_here4.md) and [HerePro](https://docs.cubepilot.org/herepro/herepro-manual), which incorporate a compass and [LEDs](../getting_started/led_meanings.md) (but no safety switch). +See [DroneCAN](../dronecan/index.md) for wiring and PX4 configuration information, and [RTK GNSS](../gps_compass/rtk_gps.md#supported-devices) for other CubePilot modules. ::: The module should be mounted on the frame as far away from other electronics as possible, with the direction marker towards the front of the vehicle (separating the compass from other electronics will reduce interference). It must be connected to the `GPS1` port using the supplied 8-pin cable. @@ -129,7 +129,7 @@ Spektrum DSM, DSM2, and DSM-X Satellite RC receivers connect to the **SPKT/DSM** The Cube cannot directly connect to PPM or PWM receivers that have an _individual wire for each channel_. PWM receivers must therefore connect to the **RCIN** port _via_ a PPM encoder module, -which may be purchased from hex.aero or proficnc.com. +which may be purchased from [CubePilot](https://www.cubepilot.org/). ## Power diff --git a/docs/en/config/safety.md b/docs/en/config/safety.md index 19783cbb41f..3487d4a3023 100644 --- a/docs/en/config/safety.md +++ b/docs/en/config/safety.md @@ -316,6 +316,8 @@ Loss of a single GPS when none are required is handled by other GPS health check When `COM_GNSSLOSS_ACT` is set to `Warning`, both triggers produce a warning only and never block arming. When set to `Warning, block arming`, both triggers block arming and only produce a warning in flight. When set to `Return`, `Land`, or `Terminate`, both triggers block arming and fire the configured in-flight failsafe action (subject to the `SYS_HAS_NUM_GNSS` condition above). +If the failure clears during the [COM_FAIL_ACT_T](#COM_FAIL_ACT_T) Hold, `Return` and `Land` are skipped and the vehicle continues in its previous mode (e.g. the mission resumes). +Once `Return` or `Land` has started, it continues even if the GNSS failure clears. | Parameter | Description | | ----------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | @@ -398,6 +400,31 @@ The parameters that control when the quad-chute will trigger are listed in the t | [VT_FW_MIN_ALT](../advanced_config/parameter_reference.md#VT_FW_MIN_ALT) | Minimum altitude above Home for fixed-wing flight. When the altitude drops below this value in fixed-wing flight the vehicle a quad-chute is triggered. | | [VT_FW_QC_R](../advanced_config/parameter_reference.md#VT_FW_QC_R) | Absolute roll threshold for quad-chute triggering in FW mode. | | [VT_FW_QC_P](../advanced_config/parameter_reference.md#VT_FW_QC_P) | Absolute pitch threshold for quad-chute triggering in FW mode. | +| [VT_EF_TIME](../advanced_config/parameter_reference.md#VT_EF_TIME) | Pusher failure detection time for standard VTOLs using pusher assist ([VT_FWD_THRUST_EN]). In multicopter mode, the failure detection triggers if, for this time, the pusher assist throttle is above [VT_EF_THROT] but the forward velocity stays more than [VT_EF_VEL_ERR] below its setpoint. It blocks front transitions until reboot. A working pusher that cannot keep up, as in a strong headwind, may be reported too. A failure is only detected once pusher assist is needed. Prior to detection, a front transition will still be executed but fail. Set to 0 to disable; in flight this allows front transitions again. | + +[VT_FWD_THRUST_EN]: ../advanced_config/parameter_reference.md#VT_FWD_THRUST_EN +[VT_EF_THROT]: ../advanced_config/parameter_reference.md#VT_EF_THROT +[VT_EF_VEL_ERR]: ../advanced_config/parameter_reference.md#VT_EF_VEL_ERR + +### Pusher Failure Detection Tuning + +First estimates for the pusher failure detection parameters: + +- [VT_EF_THROT]: about 80% of the highest pusher assist throttle, `VT_FWD_THRUST_SC * (sin(VT_PITCH_MIN) + sin(MPC_TILTMAX_AIR))` (at most 0.9). + With the defaults this is `0.7 * (sin(0°) + sin(45°)) = 0.49`, which gives the default of 0.4. +- [VT_EF_VEL_ERR]: below the speed of your multicopter legs, as a failed pusher leaves the vehicle far below its velocity setpoint. +- [VT_EF_TIME](#VT_EF_TIME): longer than the gusts and accelerations of normal flight. + +To check them in flight: + +1. Set [SYS_FAILURE_EN](../advanced_config/parameter_reference.md#SYS_FAILURE_EN) and [CA_FAILURE_MODE](../advanced_config/parameter_reference.md#CA_FAILURE_MODE) to 1 for the test (motor failure injection requires both), and back to 0 afterwards. +2. Fly a multicopter leg with pusher assist at your usual speed and at a safe altitude, for example in a mission. +3. Stop the pusher with `failure motor wrong -i ` (see [System Failure Injection](../debug/failure_injection.md)), where `` is the motor number of the pusher in the [actuator configuration](../config/actuators.md). + A pusher failure should be reported `VT_EF_TIME` after the vehicle has slowed down. +4. In the [flight log](../log/flight_log_analysis.md), check that after the failure the pusher assist throttle (`vehicle_thrust_setpoint` instance 0, `xyz[0]`) rises above `VT_EF_THROT`, and the forward velocity (along the heading) falls more than `VT_EF_VEL_ERR` below its setpoint (`vx` and `vy` of `vehicle_local_position` and `vehicle_local_position_setpoint`). + The position controller does not always demand the full `MPC_TILTMAX_AIR` tilt, especially when it is large, so the pusher assist throttle can stay below the estimate. + +In the logs of normal flights, including flights in the strongest wind you fly in, both conditions should only hold together for much less than `VT_EF_TIME`. ## High Wind Failsafe @@ -446,17 +473,19 @@ The reference altitude depends on what the vehicle is commanded to do: ### Attitude Trigger -The failure detector can be configured to trigger if the vehicle attitude exceeds predefined pitch and roll values for longer than a specified time. +The failure detector can be configured to trigger if the vehicle tilt deviates from the attitude setpoint by more than a predefined angle, in any direction, for longer than a specified time. +Without a recent attitude setpoint, for example on rovers, the tilt away from level is checked instead. +Before arming the attitude setpoint is level, so a vehicle lying on its side or upside down cannot arm. +The check only runs in modes that control attitude, so it is not active in [Acro mode](../flight_modes_mc/acro.md). +It is paused for the first 5 seconds after a VTOL switches to multicopter mode without back-transition, i.e. a [quad-chute](#quad-chute-failsafe) or an aborted front transition, while the vehicle recovers from fixed-wing flight. The relevant parameters are shown below: | Parameter | Description | | -------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------- | | [CBRK_FLIGHTTERM](../advanced_config/parameter_reference.md#CBRK_FLIGHTTERM) | Flight termination circuit breaker. Unset from 121212 (default) to enable flight termination due to FailureDetector or FMU loss. | -| [FD_FAIL_P](../advanced_config/parameter_reference.md#FD_FAIL_P) | Maximum allowed pitch (in degrees). | -| [FD_FAIL_R](../advanced_config/parameter_reference.md#FD_FAIL_R) | Maximum allowed roll (in degrees). | -| [FD_FAIL_P_TTRI](../advanced_config/parameter_reference.md#FD_FAIL_P_TTRI) | Time to exceed [FD_FAIL_P](#FD_FAIL_P) for failure detection (default 0.3s). | -| [FD_FAIL_R_TTRI](../advanced_config/parameter_reference.md#FD_FAIL_R_TTRI) | Time to exceed [FD_FAIL_R](#FD_FAIL_R) for failure detection (default 0.3s). | +| [FD_TILT_ERROR](../advanced_config/parameter_reference.md#FD_TILT_ERROR) | Maximum allowed tilt error (in degrees). | +| [FD_TILT_ERROR_T](../advanced_config/parameter_reference.md#FD_TILT_ERROR_T) | Time to exceed [FD_TILT_ERROR](#FD_TILT_ERROR) for failure detection (default 1s). | ### Motor Failure Trigger diff --git a/docs/en/debug/failure_injection.md b/docs/en/debug/failure_injection.md index 9b740f6f8a8..8fdb1e81fcb 100644 --- a/docs/en/debug/failure_injection.md +++ b/docs/en/debug/failure_injection.md @@ -37,7 +37,7 @@ A `—` means the module still accepts the command, but no consumer applies it i - `gps off | stuck | wrong` on Gazebo (Gz): applied to the GNSS data from the simulator's own sensor as well as to the simulated-GPS module ([SIM_GZ_EN_GPS](../advanced_config/parameter_reference.md#SIM_GZ_EN_GPS) `0`). - `gyro wrong | garbage | drift` and `accel wrong | garbage | drift` corrupt the addressed sensor's samples on all three axes: `wrong` adds a constant bias ([SYS_FAIL_G_BIAS](../advanced_config/parameter_reference.md#SYS_FAIL_G_BIAS) / [SYS_FAIL_A_BIAS](../advanced_config/parameter_reference.md#SYS_FAIL_A_BIAS)), `garbage` adds uniform noise within ±[SYS_FAIL_G_NOISE](../advanced_config/parameter_reference.md#SYS_FAIL_G_NOISE) / ±[SYS_FAIL_A_NOISE](../advanced_config/parameter_reference.md#SYS_FAIL_A_NOISE), and `drift` adds a bias that grows by [SYS_FAIL_G_DRIFT](../advanced_config/parameter_reference.md#SYS_FAIL_G_DRIFT) / [SYS_FAIL_A_DRIFT](../advanced_config/parameter_reference.md#SYS_FAIL_A_DRIFT) per second since injection. -- `airspeed off | stuck | wrong` on Gazebo (Gz): only injectable when airspeed is provided by the simulated-airspeed module ([SENS_EN_ARSPDSIM](../advanced_config/parameter_reference.md#SENS_EN_ARSPDSIM)); worlds that model an airspeed sensor directly are not injected. +- `airspeed off | stuck | wrong` on Gazebo (Gz): applied to the differential pressure data from the simulator's own sensor as well as to the simulated-airspeed module ([SIM_GZ_EN_ASPD](../advanced_config/parameter_reference.md#SIM_GZ_EN_ASPD) `0`). - `vio off | stuck` on Gazebo (Gz): applied to the external-vision odometry that the bridge publishes from the model's odometry topic (for example `x500_vision`); `stuck` keeps publishing the last good sample with fresh timestamps. - `battery wrong` reports the remaining charge just below the [SYS_FAIL_BAT_LVL](../advanced_config/parameter_reference.md#SYS_FAIL_BAT_LVL) warning threshold to trigger the battery failsafe; `off` stops publishing the battery status entirely. - `traffic off` suppresses incoming reports and marks the ADS-B/FLARM link unhealthy. diff --git a/docs/en/dronecan/agam_florange.md b/docs/en/dronecan/agam_florange.md index 23a8b4c6c45..0ea473b743f 100644 --- a/docs/en/dronecan/agam_florange.md +++ b/docs/en/dronecan/agam_florange.md @@ -69,7 +69,7 @@ Twist the VCC/GND and CAN_H/CAN_L wires as pairs to reduce electromagnetic inter ### Mounting Mount the module with the sensors facing down and the X arrow on the enclosure pointing towards the front of the vehicle. -This corresponds to the default value (`0`) of the parameter [SENS_FLOW_ROT](../advanced_config/parameter_reference.md#SENS_FLOW_ROT). +This corresponds to the default value (`0`) of the parameter [SENS_FLOW0_ROT](../advanced_config/parameter_reference.md#SENS_FLOW0_ROT). Change the parameter appropriately if using a different orientation. ## Firmware Setup @@ -103,15 +103,15 @@ DroneCAN configuration in PX4 is explained in more detail in [DroneCAN > Enablin Set the following parameters in _QGroundControl_, depending on which functions of the module you use: -- Enable optical flow fusion with [EKF2_OF_CTRL](../advanced_config/parameter_reference.md#EKF2_OF_CTRL) (enabled by default). +- Enable optical flow fusion with [EKF2_OF0_CTRL](../advanced_config/parameter_reference.md#EKF2_OF0_CTRL) (enabled by default). - To optionally disable GPS aiding, set [EKF2_GPS_CTRL](../advanced_config/parameter_reference.md#EKF2_GPS_CTRL) to `0`. - Enable [UAVCAN_SUB_FLOW](../advanced_config/parameter_reference.md#UAVCAN_SUB_FLOW). - Enable [UAVCAN_SUB_RNG](../advanced_config/parameter_reference.md#UAVCAN_SUB_RNG). - Set [UAVCAN_RNG_MIN](../advanced_config/parameter_reference.md#UAVCAN_RNG_MIN) to `0.08`, the minimum working distance of the flow sensor, and [UAVCAN_RNG_MAX](../advanced_config/parameter_reference.md#UAVCAN_RNG_MAX) to `30`, the maximum range of the distance sensor. - If using the distance sensor for height aiding, enable [EKF2_RNG_CTRL](../advanced_config/parameter_reference.md#EKF2_RNG_CTRL) and set [EKF2_RNG_A_HMAX](../advanced_config/parameter_reference.md#EKF2_RNG_A_HMAX) to `10` and [EKF2_RNG_QLTY_T](../advanced_config/parameter_reference.md#EKF2_RNG_QLTY_T) to `0.2`. -- Set [SENS_FLOW_MINHGT](../advanced_config/parameter_reference.md#SENS_FLOW_MINHGT) to `0.08`, the minimum height of the flow sensor, and [SENS_FLOW_MAXHGT](../advanced_config/parameter_reference.md#SENS_FLOW_MAXHGT) to `30`, the maximum range of the distance sensor. -- Set [SENS_FLOW_MAXR](../advanced_config/parameter_reference.md#SENS_FLOW_MAXR) to `7.4` to match the PAA3905 maximum angular flow rate. -- The parameters [EKF2_OF_POS_X](../advanced_config/parameter_reference.md#EKF2_OF_POS_X), [EKF2_OF_POS_Y](../advanced_config/parameter_reference.md#EKF2_OF_POS_Y), [EKF2_OF_POS_Z](../advanced_config/parameter_reference.md#EKF2_OF_POS_Z) and [EKF2_RNG_POS_X](../advanced_config/parameter_reference.md#EKF2_RNG_POS_X), [EKF2_RNG_POS_Y](../advanced_config/parameter_reference.md#EKF2_RNG_POS_Y), [EKF2_RNG_POS_Z](../advanced_config/parameter_reference.md#EKF2_RNG_POS_Z) can be set to account for the offset of the module from the vehicle centre of gravity. +- Set [SENS_FLOW0_HMIN](../advanced_config/parameter_reference.md#SENS_FLOW0_HMIN) to `0.08`, the minimum height of the flow sensor, and [SENS_FLOW0_HMAX](../advanced_config/parameter_reference.md#SENS_FLOW0_HMAX) to `30`, the maximum range of the distance sensor. +- Set [SENS_FLOW0_MAXR](../advanced_config/parameter_reference.md#SENS_FLOW0_MAXR) to `7.4` to match the PAA3905 maximum angular flow rate. +- The parameters [SENS_FLOW0_POS_X](../advanced_config/parameter_reference.md#SENS_FLOW0_POS_X), [SENS_FLOW0_POS_Y](../advanced_config/parameter_reference.md#SENS_FLOW0_POS_Y), [SENS_FLOW0_POS_Z](../advanced_config/parameter_reference.md#SENS_FLOW0_POS_Z) and [EKF2_RNG_POS_X](../advanced_config/parameter_reference.md#EKF2_RNG_POS_X), [EKF2_RNG_POS_Y](../advanced_config/parameter_reference.md#EKF2_RNG_POS_Y), [EKF2_RNG_POS_Z](../advanced_config/parameter_reference.md#EKF2_RNG_POS_Z) can be set to account for the offset of the module from the vehicle centre of gravity. When optical flow is the only source of horizontal position/velocity, reduce the horizontal position gain [MPC_XY_P](../advanced_config/parameter_reference.md#MPC_XY_P) (for example to `0.5`) to reduce oscillations. diff --git a/docs/en/dronecan/ark_flow.md b/docs/en/dronecan/ark_flow.md index 0e0a309e3b1..0d9ab218fd6 100644 --- a/docs/en/dronecan/ark_flow.md +++ b/docs/en/dronecan/ark_flow.md @@ -49,7 +49,7 @@ The recommended mounting orientation is with the connectors on the board pointin ![ARK Flow align with Pixhawk](../../assets/hardware/sensors/optical_flow/ark_flow_orientation.png) -This corresponds to the default value (`0`) of the parameter [SENS_FLOW_ROT](../advanced_config/parameter_reference.md#SENS_FLOW_ROT). +This corresponds to the default value (`0`) of the parameter [SENS_FLOW0_ROT](../advanced_config/parameter_reference.md#SENS_FLOW0_ROT). Change the parameter appropriately if using a different orientation. The sensor can be mounted anywhere on the frame, but you will need to specify the focal point position, relative to vehicle centre of gravity, during [PX4 configuration](#px4-configuration). @@ -90,7 +90,7 @@ Then set the EKF optical flow parameters to enable fusing optical flow measureme Set the following parameters in _QGroundControl_: -- Enable optical flow fusion by setting [EKF2_OF_CTRL](../advanced_config/parameter_reference.md#EKF2_OF_CTRL). +- Enable optical flow fusion by setting [EKF2_OF0_CTRL](../advanced_config/parameter_reference.md#EKF2_OF0_CTRL). - To optionally disable GPS aiding, set [EKF2_GPS_CTRL](../advanced_config/parameter_reference.md#EKF2_GPS_CTRL) to `0`. - Enable [UAVCAN_SUB_FLOW](../advanced_config/parameter_reference.md#UAVCAN_SUB_FLOW). - Enable [UAVCAN_SUB_RNG](../advanced_config/parameter_reference.md#UAVCAN_SUB_RNG). @@ -98,10 +98,10 @@ Set the following parameters in _QGroundControl_: - Set [EKF2_RNG_QLTY_T](../advanced_config/parameter_reference.md#EKF2_RNG_QLTY_T) to `0.2`. - Set [UAVCAN_RNG_MIN](../advanced_config/parameter_reference.md#UAVCAN_RNG_MIN) to `0.08`. - Set [UAVCAN_RNG_MAX](../advanced_config/parameter_reference.md#UAVCAN_RNG_MAX) to `30`. -- Set [SENS_FLOW_MINHGT](../advanced_config/parameter_reference.md#SENS_FLOW_MINHGT) to `0.08`. -- Set [SENS_FLOW_MAXHGT](../advanced_config/parameter_reference.md#SENS_FLOW_MAXHGT) to `25`. -- Set [SENS_FLOW_MAXR](../advanced_config/parameter_reference.md#SENS_FLOW_MAXR) to `7.4` to match the PAW3902 maximum angular flow rate. -- The parameters [EKF2_OF_POS_X](../advanced_config/parameter_reference.md#EKF2_OF_POS_X), [EKF2_OF_POS_Y](../advanced_config/parameter_reference.md#EKF2_OF_POS_Y) and [EKF2_OF_POS_Z](../advanced_config/parameter_reference.md#EKF2_OF_POS_Z) can be set to account for the offset of the Ark Flow from the vehicle centre of gravity. +- Set [SENS_FLOW0_HMIN](../advanced_config/parameter_reference.md#SENS_FLOW0_HMIN) to `0.08`. +- Set [SENS_FLOW0_HMAX](../advanced_config/parameter_reference.md#SENS_FLOW0_HMAX) to `25`. +- Set [SENS_FLOW0_MAXR](../advanced_config/parameter_reference.md#SENS_FLOW0_MAXR) to `7.4` to match the PAW3902 maximum angular flow rate. +- The parameters [SENS_FLOW0_POS_X](../advanced_config/parameter_reference.md#SENS_FLOW0_POS_X), [SENS_FLOW0_POS_Y](../advanced_config/parameter_reference.md#SENS_FLOW0_POS_Y) and [SENS_FLOW0_POS_Z](../advanced_config/parameter_reference.md#SENS_FLOW0_POS_Z) can be set to account for the offset of the Ark Flow from the vehicle centre of gravity. When optical flow is the only source of horizontal position/velocity, then lowering the gain for controller response to horizontal position error [MPC_XY_P](../advanced_config/parameter_reference.md#MPC_XY_P) (e.g. to 0.5) is recommended to reduce oscillations. diff --git a/docs/en/dronecan/ark_flow_mr.md b/docs/en/dronecan/ark_flow_mr.md index ef525ff456d..34919ad098f 100644 --- a/docs/en/dronecan/ark_flow_mr.md +++ b/docs/en/dronecan/ark_flow_mr.md @@ -47,7 +47,7 @@ The recommended mounting orientation is with the connectors on the board pointin ![ARK Flow MR align with Pixhawk](../../assets/hardware/sensors/optical_flow/ark_flow_orientation.png) -This corresponds to the default value (`0`) of the parameter [SENS_FLOW_ROT](../advanced_config/parameter_reference.md#SENS_FLOW_ROT). +This corresponds to the default value (`0`) of the parameter [SENS_FLOW0_ROT](../advanced_config/parameter_reference.md#SENS_FLOW0_ROT). Change the parameter appropriately if using a different orientation. The sensor can be mounted anywhere on the frame, but you will need to specify the focal point position, relative to vehicle centre of gravity, during [PX4 configuration](#px4-configuration). @@ -87,7 +87,7 @@ You need to set the EKF optical flow parameters to enable fusing optical flow me Set the following parameters in _QGroundControl_: -- Enable optical flow fusion by setting [EKF2_OF_CTRL](../advanced_config/parameter_reference.md#EKF2_OF_CTRL). +- Enable optical flow fusion by setting [EKF2_OF0_CTRL](../advanced_config/parameter_reference.md#EKF2_OF0_CTRL). - To optionally disable GPS aiding, set [EKF2_GPS_CTRL](../advanced_config/parameter_reference.md#EKF2_GPS_CTRL) to `0`. - Enable [UAVCAN_SUB_FLOW](../advanced_config/parameter_reference.md#UAVCAN_SUB_FLOW). - Enable [UAVCAN_SUB_RNG](../advanced_config/parameter_reference.md#UAVCAN_SUB_RNG). @@ -95,10 +95,10 @@ Set the following parameters in _QGroundControl_: - Set [EKF2_RNG_QLTY_T](../advanced_config/parameter_reference.md#EKF2_RNG_QLTY_T) to `0.2`. - Set [UAVCAN_RNG_MIN](../advanced_config/parameter_reference.md#UAVCAN_RNG_MIN) to `0.08`. - Set [UAVCAN_RNG_MAX](../advanced_config/parameter_reference.md#UAVCAN_RNG_MAX) to `50`. -- Set [SENS_FLOW_MINHGT](../advanced_config/parameter_reference.md#SENS_FLOW_MINHGT) to `0.08`. -- Set [SENS_FLOW_MAXHGT](../advanced_config/parameter_reference.md#SENS_FLOW_MAXHGT) to `25`. -- Set [SENS_FLOW_MAXR](../advanced_config/parameter_reference.md#SENS_FLOW_MAXR) to `7.4` to match the PAW3902 maximum angular flow rate. -- The parameters [EKF2_OF_POS_X](../advanced_config/parameter_reference.md#EKF2_OF_POS_X), [EKF2_OF_POS_Y](../advanced_config/parameter_reference.md#EKF2_OF_POS_Y) and [EKF2_OF_POS_Z](../advanced_config/parameter_reference.md#EKF2_OF_POS_Z) can be set to account for the offset of the Ark Flow MR from the vehicle centre of gravity. +- Set [SENS_FLOW0_HMIN](../advanced_config/parameter_reference.md#SENS_FLOW0_HMIN) to `0.08`. +- Set [SENS_FLOW0_HMAX](../advanced_config/parameter_reference.md#SENS_FLOW0_HMAX) to `25`. +- Set [SENS_FLOW0_MAXR](../advanced_config/parameter_reference.md#SENS_FLOW0_MAXR) to `7.4` to match the PAW3902 maximum angular flow rate. +- The parameters [SENS_FLOW0_POS_X](../advanced_config/parameter_reference.md#SENS_FLOW0_POS_X), [SENS_FLOW0_POS_Y](../advanced_config/parameter_reference.md#SENS_FLOW0_POS_Y) and [SENS_FLOW0_POS_Z](../advanced_config/parameter_reference.md#SENS_FLOW0_POS_Z) can be set to account for the offset of the Ark Flow MR from the vehicle centre of gravity. ## Ark Flow MR Configuration diff --git a/docs/en/dronecan/cubepilot_here4.md b/docs/en/dronecan/cubepilot_here4.md new file mode 100644 index 00000000000..9be6372e0af --- /dev/null +++ b/docs/en/dronecan/cubepilot_here4.md @@ -0,0 +1,94 @@ +# CubePilot Here4 RTK GNSS (DroneCAN) + +The [CubePilot Here4](https://docs.cubepilot.org/here-4/here-4-manual) is a dual-band (L1/L5) [RTK GNSS](../gps_compass/rtk_gps.md) module that connects to the flight controller via [DroneCAN](../dronecan/index.md). +It integrates a u-blox NEO-F9P receiver, an RM3100 compass, a barometer, an IMU and RGB LEDs. + +::: warning +CubePilot has issued safety service bulletins for the Here4, including a [mandatory bootloader update before further flight](https://docs.cubepilot.org/service-bulletins-and-critical-notices/safety-service-bulletins/sb_0000010-mandatory-here4-bootloader-update-before-further-flight) (SB_0000010). +Check the bulletins before flying (see [Firmware](#firmware)). +::: + +## Variants + +- [Here4 Base](https://docs.cubepilot.org/here-4/here-4-base): RTK base station with an external antenna connector, for use with _QGroundControl_. +- [Here4 Blue](https://docs.cubepilot.org/here-4/here-4-blue): Here4 with integrated Bluetooth Remote ID (CubeID). + +## Where to Buy + +- [CubePilot Resellers](https://cubepilot.org/#/reseller/list) + +## Hardware Specifications + +From the [CubePilot Here4 manual](https://docs.cubepilot.org/here-4/here-4-manual): + +- GNSS receiver: u-blox NEO-F9P, dual-band (L1/L5) + - Constellations: GPS, GLONASS, Galileo, BeiDou, QZSS +- Processor: STM32H757, running CubePilot's AP_Periph based firmware +- Compass: RM3100 +- IMU: ICM42688 +- Barometer: MS5611 +- Interface: DroneCAN, two CAN ports (only one supported by the current firmware, see [Wiring](#wiring)) +- Working temperature: -40 °C to +85 °C +- Size: 16 x 68 mm +- Weight: 60 g (with cable) + +## Hardware Setup + +### Wiring + +Connect the Here4 to the `CAN1` or `CAN2` port of the flight controller using the supplied 4-pin CAN cable. +For more information, refer to the [CAN Wiring](../can/index.md#wiring) instructions. + +::: warning +The Here4 has two CAN ports, but the current firmware only supports one of them: the port whose cable has green, blue, white and grey wires. +If the other port is used, the Here4 does not appear on the bus. +`uavcan status` then reports TX frames and an equally growing number of HW errors, with no RX frames and no online nodes. +::: + +### Mounting + +Mount the module as far away from other electronics as possible, with its direction marker pointing towards the front of the vehicle. + +## PX4 Configuration + +1. Set [UAVCAN_ENABLE](../advanced_config/parameter_reference.md#UAVCAN_ENABLE) to `2` (_Sensors Automatic Config_), or `3` if you also use [DroneCAN ESCs](../dronecan/escs.md), and reboot. +2. The Here4 is assigned a node ID via dynamic node allocation, and its GNSS and compass are used without further configuration. +3. To also use the Here4 barometer: + - Enable [UAVCAN_SUB_BARO](../advanced_config/parameter_reference.md#UAVCAN_SUB_BARO) in PX4. + - Enable the barometer on the Here4 itself, where it is disabled by default. + Set its `BARO_ENABLE` parameter to `1` and save it to the node, either in the _QGroundControl_ parameters of the Here4 component, or from the [MAVLink Shell](../debug/mavlink_shell.md): + + ```sh + uavcan param set BARO_ENABLE 1 + uavcan param save + ``` + + Then power cycle the Here4. + +You can check that everything is detected with `uavcan status`. +The Here4 should be listed under _Online nodes_ with mode `OPERAT`, and the `gnss`, `mag` and (if enabled) `baro` sensors should each show a channel bound to its node ID. + +DroneCAN configuration in PX4 is explained in more detail in [DroneCAN > PX4 Configuration](../dronecan/index.md#px4-configuration). +For RTK setup see [RTK GNSS](../gps_compass/rtk_gps.md#positioning-setup-configuration). + +## Firmware + +CubePilot publishes the Here4 firmware and release notes at [GNSSPeriph-release](https://github.com/CubePilot/GNSSPeriph-release/releases). + +PX4 can update the Here4 from the SD card, as described in [DroneCAN > Firmware Update](../dronecan/index.md#firmware-update): + +1. Copy `Here4_FW.bin` from the release archive to the SD card. +2. Reboot with the Here4 connected. + PX4 moves the file to `/fs/microsd/ufw/1043.bin` (1043 is the Here4 board ID) and updates the Here4 if its firmware differs. + During the update `uavcan status` shows the Here4 with mode `SW_UPD`, and then `OPERAT` again once it has completed. + +You can check the installed version with `listener device_information`: `firmware_version` shows the major and minor version followed by the git hash of the build in decimal (DroneCAN does not report the patch version). + +If the Here4 stays in `SW_UPD` without completing, remove the file from `/fs/microsd/ufw/` and update the Here4 with CubePilot's tools instead (see the bulletin below). + +According to [SB_0000010](https://docs.cubepilot.org/service-bulletins-and-critical-notices/safety-service-bulletins/sb_0000010-mandatory-here4-bootloader-update-before-further-flight), a Here4 with the updated bootloader breathes blue at boot. +If yours does not, follow the bulletin: update the firmware, then set the Here4 parameter `FLASH_BOOTLOADER` to `1` to update the bootloader. + +## See Also + +- [CubePilot Here4 Manual](https://docs.cubepilot.org/here-4/here-4-manual) (docs.cubepilot.org) diff --git a/docs/en/dronecan/index.md b/docs/en/dronecan/index.md index f85cb2a0981..96ac022ec88 100644 --- a/docs/en/dronecan/index.md +++ b/docs/en/dronecan/index.md @@ -44,7 +44,9 @@ Supported hardware includes (this is not an exhaustive list): - GNSS receivers for GNSS (GPS, GLONASS, BeiDou, and so on) - [ARK GPS](../dronecan/ark_gps.md) - [ARK RTK GPS](../dronecan/ark_rtk_gps.md) - - [CubePilot Here3](https://www.cubepilot.org/#/here/here3) + - [CubePilot Here3/Here3+](https://docs.cubepilot.org/here-3-3+/here-3-manual) + - [CubePilot Here4](../dronecan/cubepilot_here4.md) + - [CubePilot HerePro](https://docs.cubepilot.org/herepro/herepro-manual) - [CUAV NEO v2 Pro GNSS](https://doc.cuav.net/gps/neo-series-gnss/en/neo-v2-pro.html) - [CUAV NEO 3 Pro GPS](../gps_compass/gps_cuav_neo_3pro.md) - [CUAV NEO 3X GPS](../gps_compass/gps_cuav_neo_3x.md) @@ -141,7 +143,7 @@ Instead you must enable publication or subscription to the messages associated w ::: info Sensor parameters may not exist (be visible in QGC) until you have enabled the associated DroneCAN [sensor subscription](#sensors)! -For example, [SENS_FLOW_MINHGT](../advanced_config/parameter_reference.md#SENS_FLOW_MINHGT) does not exist until [UAVCAN_SUB_FLOW](../advanced_config/parameter_reference.md#UAVCAN_SUB_FLOW) is enabled. +For example, [SENS_FLOW0_HMIN](../advanced_config/parameter_reference.md#SENS_FLOW0_HMIN) does not exist until [UAVCAN_SUB_FLOW](../advanced_config/parameter_reference.md#UAVCAN_SUB_FLOW) is enabled. ::: For example, to use a connected DroneCAN smart battery you would enable the [UAVCAN_SUB_BAT](../advanced_config/parameter_reference.md#UAVCAN_SUB_BAT) parameter, which would subscribe PX4 to receive [BatteryInfo](https://dronecan.github.io/Specification/7._List_of_standard_data_types/#batteryinfo) DroneCAN messages. @@ -262,11 +264,11 @@ PX4 DroneCAN parameters: Other PX4 parameters: -- Set [SENS_FLOW_MINHGT](../advanced_config/parameter_reference.md#SENS_FLOW_MINHGT) and [SENS_FLOW_MAXHGT](../advanced_config/parameter_reference.md#SENS_FLOW_MAXHGT), the minimum and maximum height of the flow sensor. -- Set [SENS_FLOW_MAXR](../advanced_config/parameter_reference.md#SENS_FLOW_MAXR) the maximum angular flow rate of the sensor. -- Enable optical flow fusion by setting [EKF2_OF_CTRL](../advanced_config/parameter_reference.md#EKF2_OF_CTRL). +- Set [SENS_FLOW0_HMIN](../advanced_config/parameter_reference.md#SENS_FLOW0_HMIN) and [SENS_FLOW0_HMAX](../advanced_config/parameter_reference.md#SENS_FLOW0_HMAX), the minimum and maximum height of the flow sensor. +- Set [SENS_FLOW0_MAXR](../advanced_config/parameter_reference.md#SENS_FLOW0_MAXR) the maximum angular flow rate of the sensor. +- Enable optical flow fusion by setting [EKF2_OF0_CTRL](../advanced_config/parameter_reference.md#EKF2_OF0_CTRL). - To disable GPS aiding (optional), set [EKF2_GPS_CTRL](../advanced_config/parameter_reference.md#EKF2_GPS_CTRL) to `0`. -- If the optical flow unit is not positioned at the vehicle centre of gravity you can account for the offset using [EKF2_OF_POS_X](../advanced_config/parameter_reference.md#EKF2_OF_POS_X), [EKF2_OF_POS_Y](../advanced_config/parameter_reference.md#EKF2_OF_POS_Y) and [EKF2_OF_POS_Z](../advanced_config/parameter_reference.md#EKF2_OF_POS_Z). +- If the optical flow unit is not positioned at the vehicle centre of gravity you can account for the offset using [SENS_FLOW0_POS_X](../advanced_config/parameter_reference.md#SENS_FLOW0_POS_X), [SENS_FLOW0_POS_Y](../advanced_config/parameter_reference.md#SENS_FLOW0_POS_Y) and [SENS_FLOW0_POS_Z](../advanced_config/parameter_reference.md#SENS_FLOW0_POS_Z). Optical flow sensors require rangefinder data. However the rangefinder need not be part of the same module, and if not, may not be connected via DroneCAN. diff --git a/docs/en/flight_controller/accton-godwit_gfh7.md b/docs/en/flight_controller/accton-godwit_gfh7.md new file mode 100644 index 00000000000..7176923b120 --- /dev/null +++ b/docs/en/flight_controller/accton-godwit_gfh7.md @@ -0,0 +1,315 @@ +# Accton Godwit G-FH7 + + + +::: warning +PX4 does not manufacture this (or any) autopilot. +Contact the [manufacturer](https://www.accton-iot.com/godwit/) for hardware support or compliance issues. +::: + +The [Godwit G-FH7](https://www.accton-iot.com/godwit/g-fh7.html) is a compact flight controller from Accton, designed for fixed-wing, VTOL, and other UAV applications. +It uses an STM32H753 flight-management processor, dual IMUs, an integrated barometer and compass, and solder-free connectors for flexible system integration. +The board supports PX4, ArduPilot, Betaflight, and iNAV flight-control software. + +![Accton Godwit G-FH7](../../assets/flight_controller/accton-godwit_gfh7/outlook.png "Accton Godwit G-FH7") + +![Accton Godwit G-FH7 Front View](../../assets/flight_controller/accton-godwit_gfh7/orientation_front.png "Accton Godwit G-FH7 Front View") + +![Accton Godwit G-FH7 Back View](../../assets/flight_controller/accton-godwit_gfh7/orientation_back.png "Accton Godwit G-FH7 Back View") + +::: info +This flight controller is [manufacturer supported](../flight_controller/autopilot_manufacturer_supported.md). +::: + +## Specifications {#specifications} + +### Processor {#processor} + +- **Main FMU processor:** [STM32H753VIH6](https://www.st.com/en/microcontrollers-microprocessors/stm32h753vi.html) (Arm® Cortex®-M7 at 480MHz, 2MB flash, 1MB RAM) + +### Sensors {#sensors} + +- **IMU:** [TDK InvenSense ICM-42688-P](https://invensense.tdk.com/products/motion-tracking/6-axis/icm-42688-p/) (SPI4), [STMicroelectronics LSM6DSK320X](https://www.st.com/en/mems-and-sensors/lsm6dsk320x.html) (SPI2) +- **Barometer:** [Infineon DPS368](https://www.infineon.com/cms/en/product/sensor/pressure-sensors/pressure-sensors-for-iot/dps368/) (I2C1) +- **Magnetometer:** [iSentek IST8310](https://assets.isentek.com/public/documents/datasheet/HFH0n8I7hQ-IST8310_Datasheet_V1.8_Web.pdf) (I2C1) +- **Heater:** resistive IMU heater, off by default (see [IMU Heater](#imu_heater)) + +### Interfaces {#interfaces} + +- **PWM outputs:** 8 (plus `PWM9` for a NeoPixel LED strip) +- **Serial ports:** 7: `TELEM`, `GPS`, `ELRS`, `SBUS`, `D-VTX`, `ESC` (ESC telemetry, RX only), and the `T2`/`R2` solder pads +- **I2C buses:** 2 (1 external, 1 internal) +- **SPI buses:** 3, all internal (both IMUs and the OSD) +- **CAN buses:** 1 +- **Ethernet:** RMII and pulse-per-second (PPS) signals on a connector (reserved for future use; not enabled in PX4) +- **USB:** USB Type-C, with `BOOT` button for [DFU mode](../advanced_config/bootloader_update_from_betaflight.md#dfu-mode) +- **RC input:** Yes (serial, on the `SBUS` and `ELRS` connectors) +- **Parameter storage:** processor flash +- **SD card:** microSD slot +- **ADC inputs:** 3 (battery voltage, battery current, and analog RSSI, which PX4 doesn't read) +- **OSD:** analog (AT7456-compatible) +- **Other:** 2 LED indicators, active buzzer output, video input, and video output + +### Electrical Data {#electrical_data} + +- **Input voltage:** Up to 12S LiPo +- **Current draw:** 110mA at 5V (static), plus about 67mA (0.33W, calculated) with the IMU heater on +- **BEC output:** 5V/3A and 12V/3A (12V output [switchable](#power)) +- **Power monitoring:** 1 battery, analog voltage and current (current needs [setup](#power)) + +### Mechanical Data {#mechanical_data} + +- **Dimensions:** 36 x 42 x 8.63mm +- **Weight:** 10.6g +- **Mounting hole spacing:** 30.5 x 30.5mm, M4 + +## Where to Buy {#store} + +Product information and availability are provided on the [Accton-IoT Godwit G-FH7 product page](https://www.accton-iot.com/godwit/g-fh7.html). + +## Pinouts {#pinouts} + +Refer to the [Godwit G-FH7 product page](https://www.accton-iot.com/godwit/g-fh7.html) and the [Godwit G-FH7 datasheet](https://www.accton-iot.com/godwit/assets/doc/DS-Godwit%20FPV%20G-FH7.pdf) for the latest board information and interface definition. + +![G-FH7 Pin Definition](../../assets/flight_controller/accton-godwit_gfh7/pin_definition.png "Accton Godwit G-FH7 Pin Definition") + +### Interface Summary {#interface_summary} + +| Interface | Function | +| ----------------- | ----------------------------------------------- | +| `ESC` / `Ext ESC` | Connect the ESC and motor system. | +| `GPS` | Connect a GPS module. | +| `SBUS` / `ELRS` | Connect an RC receiver. | +| `TELEM` | Connect a telemetry radio or MAVLink device. | +| `CAN` | Connect CAN peripherals. | +| `I2C` | Connect external I2C sensors. | +| `BZ` | Connect an external active buzzer. | +| `VIDEO-IN` | Connect an analog camera. | +| `A-VTX` / `D-VTX` | Connect an analog or digital video transmitter. | + +### Block Diagram {#block_diagram} + +The block diagram below shows the main components (sensors and power supply) and how they connect to the STM32H753 FMU. + +![Accton Godwit G-FH7 block diagram: the STM32H753 FMU with its IMUs, barometer, magnetometer, OSD co-processor, power supply (battery input, 12V and 5V BECs, 3.3V LDO), and connectors](../../assets/flight_controller/accton-godwit_gfh7/block_diagram.svg "Accton Godwit G-FH7 Block Diagram") + +## Power {#power} + +The board is powered from the battery through the `VBAT` pins on the `ESC` connector (JST-SH 10P), which also carries the ESC's battery current signal (`CURRENT` pin). +Onboard BECs supply 5V/3A and 12V/3A to peripherals. + +The 12V output is on at boot. +To switch it from your transmitter, [assign](../advanced_config/parameters.md) an RC switch to [RC_MAP_PAY_SW](../advanced_config/parameter_reference.md#RC_MAP_PAY_SW): the 12V output then stays off until the switch is set to on. + +Battery voltage monitoring is configured by default ([BAT1_V_DIV](../advanced_config/parameter_reference.md#BAT1_V_DIV) is set to `17.0`). +Current monitoring depends on the ESC's current sensor, so you must set [BAT1_A_PER_V](../advanced_config/parameter_reference.md#BAT1_A_PER_V) as described in [Battery and Power Module Setup](../config/battery.md). + +## Voltage Ratings {#voltage_ratings} + +The board can be powered from the battery input (`VBAT` pins on the `ESC` connector) or from USB. + +### Normal Operation Maximum Ratings + +Under these conditions all power sources will be used in this order to power the system: + +1. **Battery** input (up to 12S LiPo, 50.4V maximum) +2. **USB** input (4.75V to 5.25V) + +### Absolute Maximum Ratings + +Under these conditions the system will not draw any power (will not be operational), but will remain intact. + +1. **Battery** input (65V) + +::: info +The flight controller keeps working below 13V on the battery input. +The 12V output for the camera and video transmitter (VTX) is generated from the battery input and needs about 13V or more to stay at 12V. +Below that, the camera and VTX lose power. +::: + +## PWM Outputs {#pwm_outputs} + +The board has 8 PWM outputs, on the `MOTOR1`-`MOTOR8` pins of the `ESC` and `Ext ESC` connectors. +All 8 outputs support [DShot](../peripherals/dshot.md) and [bidirectional DShot](../peripherals/dshot.md#bidirectional-dshot-telemetry). + +The outputs are in 2 groups: + +- Outputs 1-4 in group 1 (Timer1) +- Outputs 5-8 in group 2 (Timer8) + +All outputs within the same group must use the same output protocol and rate. + +The `PWM9` pin on the `Ext ESC` connector drives a NeoPixel (WS2812-compatible) LED strip of up to 8 LEDs, and can't be used as an actuator output. + +## SD Card (Optional) {#sd_card} + +The board has a microSD card slot, which PX4 uses for flight logs and other data. +See [SD Cards](../getting_started/px4_basic_concepts.md#sd-cards-removable-memory) for more information. + +![Godwit G-FH7 SD Card](../../assets/flight_controller/accton-godwit_gfh7/sdcard.png "Godwit G-FH7 SD Card") + +## IMU Heater {#imu_heater} + +The board has a resistive IMU heater, which draws about 67mA (0.33W, calculated from the heater resistor value) from the 5V supply. + +The heater is off by default. +To enable it, set [SENS_EN_THERMAL](../advanced_config/parameter_reference.md#SENS_EN_THERMAL) to `1` and reboot. +The target temperature is set by [HEATER1_TEMP](../advanced_config/parameter_reference.md#HEATER1_TEMP), which this board sets to 45°C. + +If you enable the heater, run the [accelerometer calibration](../config/accelerometer.md) only after `heater status` (in the [MAVLink Shell](../debug/mavlink_shell.md)) shows that the sensor temperature has reached the target temperature. + +## Serial Port Mapping {#serial_port_mapping} + +| UART | Device | Port | Connector | +| ------ | ---------- | ---------------- | -------------------------------------------------------------------- | +| USART1 | /dev/ttyS0 | EXT2 | `ESC` (ESC telemetry, RX only) | +| USART2 | /dev/ttyS1 | TELEM 2 | `T2`/`R2` solder pads | +| USART3 | /dev/ttyS2 | GPS 1 | `GPS` | +| UART4 | /dev/ttyS3 | TELEM/SERIAL 4 | `ELRS` (CRSF by default) | +| UART5 | /dev/ttyS4 | Radio Controller | `SBUS` (RX and TX), `A-VTX` (TX, not used), `D-VTX` (`SBUS` pin, RX) | +| UART7 | /dev/ttyS5 | TELEM 1 | `TELEM` | +| UART8 | /dev/ttyS6 | TELEM 3 | `D-VTX` | + +`EXT2` is receive-only, so it can't be used for MAVLink or other two-way protocols. +It reads [ESC telemetry](../peripherals/dshot.md#esc-telemetry) from the `ESC` connector ([DSHOT_TEL_CFG](../advanced_config/parameter_reference.md#DSHOT_TEL_CFG) is set to `EXT2` by default). + +No ports have flow control. + +::: info +The bootloader enables only UART7 (the `TELEM` connector), so `TELEM` is the only serial port [px4_uploader.py](https://github.com/PX4/PX4-Autopilot/blob/main/Tools/px4_uploader.py) can flash firmware over. +::: + +## Assembly {#assembly} + +### Wiring Diagrams {#wiring_diagram} + +Refer to the [Godwit G-FH7 product page](https://www.accton-iot.com/godwit/g-fh7.html) and the [Godwit G-FH7 datasheet](https://www.accton-iot.com/godwit/assets/doc/DS-Godwit%20FPV%20G-FH7.pdf) for the latest wiring and connector information. + +![Godwit G-FH7 Wiring (1 of 2)](../../assets/flight_controller/accton-godwit_gfh7/wiring_1.png "Accton Godwit G-FH7 Wiring (1 of 2)") + +![Godwit G-FH7 Wiring (2 of 2)](../../assets/flight_controller/accton-godwit_gfh7/wiring_2.png "Accton Godwit G-FH7 Wiring (2 of 2)") + +The diagram below shows how to connect a 4-in-1 ESC and its motors to the `ESC` connector. + +![Godwit G-FH7 Motor/ESC Wiring](../../assets/flight_controller/accton-godwit_gfh7/motor_esc_wiring.png "Accton Godwit G-FH7 Motor/ESC Wiring") + +### Radio Control {#radio_control} + +A remote control (RC) radio system is required if you want to manually control your vehicle (PX4 does not require a radio system for autonomous flight modes). +See [Radio Control Systems](../getting_started/rc_transmitter_receiver.md) for how to select a transmitter/receiver. + +The board has two receiver connectors (JST-SH 4P), both wired to FMU UARTs: + +- `ELRS` (UART4, PX4 port `TELEM/SERIAL 4`): CRSF/ExpressLRS is enabled on this port by default ([RC_CRSF_PRT_CFG](../advanced_config/parameter_reference.md#RC_CRSF_PRT_CFG) is set to `TELEM/SERIAL 4`). + [CRSF telemetry](../telemetry/crsf_telemetry.md) to the transmitter is also enabled by default ([RC_CRSF_TEL_EN](../advanced_config/parameter_reference.md#RC_CRSF_TEL_EN)). +- `SBUS` (UART5, PX4 port `Radio Controller`): for S.BUS receivers. + To use it, set [RC_SBUS_PRT_CFG](../advanced_config/parameter_reference.md#RC_SBUS_PRT_CFG) to `Radio Controller` and `RC_CRSF_PRT_CFG` to `Disabled`. + The connector is wired to both `UART5_RX` and `UART5_TX`. + The `SBUS` pin on the `D-VTX` connector shares the `UART5_RX` line, for digital video systems that output S.BUS. + The TX pin on the `A-VTX` connector shares the `UART5_TX` line, but PX4 doesn't use this pin. + +The other built-in protocols, DSM and GHST (TBS Ghost), are enabled by setting [RC_DSM_PRT_CFG](../advanced_config/parameter_reference.md#RC_DSM_PRT_CFG) or [RC_GHST_PRT_CFG](../advanced_config/parameter_reference.md#RC_GHST_PRT_CFG) to the port the receiver is connected to, and `RC_CRSF_PRT_CFG` to `Disabled`. +DSM receivers can't be bound from PX4 or _QGroundControl_ on this board, so bind the receiver using its own bind procedure. +The `ELRS` and `SBUS` connectors supply 5V, so power a 3.3V DSM receiver from a separate 3.3V supply. +Only one protocol can be active on a port. +PPM receivers are not supported, so PWM receivers can't be used either, even with a PPM encoder. + +The vehicle boots in Stabilized mode ([multicopter](../flight_modes_mc/manual_stabilized.md), [fixed-wing](../flight_modes_fw/stabilized.md)) instead of the PX4 default of Hold mode ([COM_FLTMODE_BOOT](../advanced_config/parameter_reference.md#COM_FLTMODE_BOOT) is set to `Stabilized`). +A flight mode switch, if you assign one with [RC_MAP_FLTMODE](../advanced_config/parameter_reference.md#RC_MAP_FLTMODE), overrides this. + +![G-FH7 RC receiver connections](../../assets/flight_controller/accton-godwit_gfh7/radio.png "Accton Godwit G-FH7 Radio") + +### GPS & Compass {#gps_compass} + +Connect a [GPS/compass module](../gps_compass/index.md) to the `GPS` connector (JST-SH 6P), which carries USART3 (PX4 port `GPS 1`) and the external I2C bus (I2C4) for the compass. +See [Mounting the GPS/Compass](../assembly/mount_gps_compass.md) for placement. + +An external compass (usually built into the GPS module) is recommended over the onboard [iSentek IST8310](https://assets.isentek.com/public/documents/datasheet/HFH0n8I7hQ-IST8310_Datasheet_V1.8_Web.pdf), because it can be mounted away from motors and power wiring. + +![G-FH7 GPS/compass connections](../../assets/flight_controller/accton-godwit_gfh7/gps.png "Accton Godwit G-FH7 GPS") + +### Telemetry Radios (Optional) {#telemetry} + +Connect the radio to the `TELEM` connector (PX4 port `TELEM 1`), which is configured for MAVLink by default. + +Telemetry radios are used to provide a wireless data link between the vehicle and a ground control station (GCS) such as _QGroundControl_. +This allows you to monitor flight data, change missions in real time, and receive in-flight status updates. +See [Telemetry Radios](../telemetry/index.md). + +### CAN {#can} + +The `CAN` connector (JST-SH 4P) is used for [DroneCAN](../dronecan/index.md) peripherals such as GPS modules, ESCs, and sensors. +DroneCAN is disabled by default: enable it by setting [UAVCAN_ENABLE](../advanced_config/parameter_reference.md#UAVCAN_ENABLE). + +### OSD {#osd} + +The board has an [analog OSD](../peripherals/osd.md#atxxxx-analog-osd) co-processor (AT7456-compatible), which is enabled by default in NTSC mode. +Connect the camera to `VIDEO-IN` and the analog video transmitter to `A-VTX`. +PX4 doesn't use the TX pin on the `A-VTX` connector, so [VTX control](../vtx/index.md) (SmartAudio/Tramp) is not supported on this board. +Set [OSD_ATXXXX_CFG](../advanced_config/parameter_reference.md#OSD_ATXXXX_CFG) to `2` for PAL, or `0` to disable the OSD, and reboot. + +For a digital video transmitter on the `D-VTX` connector, set [MSP_OSD_CONFIG](../advanced_config/parameter_reference.md#MSP_OSD_CONFIG) to `TELEM 3` to enable [MSP OSD](../peripherals/osd.md#msp-osd). + +## Building Firmware {#building_firmware} + +::: tip +From PX4 v2.0, most users will not need to build this firmware! +It is pre-built and automatically installed by _QGroundControl_ when appropriate hardware is connected. +::: + +The board ships with the PX4 bootloader. + +To [build PX4](../dev_setup/building_px4.md) for this target from source: + +```sh +make accton-godwit_gfh7_default +``` + +For a debug build with the system console enabled (`accton-godwit_gfh7_debug`), see [Debug Port](#debug_port). + +## Debug Port {#debug_port} + +The top face has two unpopulated five-pad test/debug groups for manufacturing, debugging, or hardware verification. +They don't follow the [Pixhawk Debug](../debug/swd_debug.md#pixhawk-standard-debug-ports) connector standards, so a debug probe must be wired to the pads directly. + +The `R V G C D` pad group is the [SWD interface](../debug/swd_debug.md) of the STM32H753 FMU: + +| Pad | Signal | Voltage | +| --- | --------- | ------- | +| `R` | ST_RST_L | 3.3V | +| `V` | VDD3V3 | 3.3V | +| `G` | GND | GND | +| `C` | FMU_SWCLK | 3.3V | +| `D` | FMU_SWDIO | 3.3V | + +The `R C D G V` pad group is the SWD interface of the OSD co-processor (STM32G431), which PX4 doesn't use: + +| Pad | Signal | Voltage | +| --- | ---------- | ------- | +| `R` | OSD_NRST | 3.3V | +| `C` | G431_SWCLK | 3.3V | +| `D` | G431_SWDIO | 3.3V | +| `G` | GND | GND | +| `V` | VDD3V3 | 3.3V | + +These pads are not general user interfaces: only connect an SWD debug probe to them, and do not apply power to them or use them as GPIO, UART, or I2C interfaces. + +The default firmware does not provide a serial [System Console](../debug/system_console.md). +Use the [MAVLink Shell](../debug/mavlink_shell.md) over USB or a telemetry link instead. + +The debug build enables the system console on UART4 (the `ELRS` connector): + +```sh +make accton-godwit_gfh7_debug +``` + +`TELEM/SERIAL 4` is not available in that build, so the `ELRS` connector can't be used for a receiver. +To use an S.BUS receiver on the `SBUS` connector instead, set [RC_SBUS_PRT_CFG](../advanced_config/parameter_reference.md#RC_SBUS_PRT_CFG) to `Radio Controller`. + +## Further Information {#further_information} + +- [Accton-IoT Godwit G-FH7](https://www.accton-iot.com/godwit/g-fh7.html) (product page) +- [Godwit G-FH7 documentation](https://www.accton-iot.com/godwitdoc/g-fh7doc.html) +- [Godwit G-FH7 datasheet](https://www.accton-iot.com/godwit/assets/doc/DS-Godwit%20FPV%20G-FH7.pdf) +- Sales: [sales@accton-iot.com](mailto:sales@accton-iot.com) +- Support: [support@accton-iot.com](mailto:support@accton-iot.com) diff --git a/docs/en/flight_controller/agam_v6xrt.md b/docs/en/flight_controller/agam_v6xrt.md index 3f3aa46d4b1..db733828832 100644 --- a/docs/en/flight_controller/agam_v6xrt.md +++ b/docs/en/flight_controller/agam_v6xrt.md @@ -135,6 +135,8 @@ Notes: | LPUART10 | /dev/ttyS6 | TELEM3 | | LPUART11 | /dev/ttyS7 | EXT2 | +The board has five [MAVLink instances](../peripherals/mavlink_peripherals.md#mavlink-instances) (`MAV_0_CONFIG` to `MAV_4_CONFIG`) rather than the usual three. + ## Radio Control {#radio_control} A remote control (RC) radio system is required if you want to _manually_ control your vehicle (PX4 does not require a radio system for autonomous flight modes). diff --git a/docs/en/flight_controller/autopilot_manufacturer_supported.md b/docs/en/flight_controller/autopilot_manufacturer_supported.md index 03762209ae5..8d694d3715e 100644 --- a/docs/en/flight_controller/autopilot_manufacturer_supported.md +++ b/docs/en/flight_controller/autopilot_manufacturer_supported.md @@ -18,6 +18,7 @@ The boards in this category are: - [3DR Control N1](../flight_controller/3dr_ctrl-n1.md) - [Accton Godwit GA1](../flight_controller/accton-godwit_ga1.md) +- [Accton Godwit G-FH7](../flight_controller/accton-godwit_gfh7.md) - [AEDROX AEDROXH7](../flight_controller/aedrox_aedroxh7.md) - [Agam Autopilot v6X-RT](../flight_controller/agam_v6xrt.md) - [AirMind MindPX](../flight_controller/mindpx.md) diff --git a/docs/en/flight_controller/autopilot_pixhawk_standard.md b/docs/en/flight_controller/autopilot_pixhawk_standard.md index ef028e3e5a7..81e617cd8e1 100644 --- a/docs/en/flight_controller/autopilot_pixhawk_standard.md +++ b/docs/en/flight_controller/autopilot_pixhawk_standard.md @@ -21,7 +21,7 @@ The boards in this category are: - [Holybro Pix32 v6](../flight_controller/holybro_pix32_v6.md) (FMUv6C) - [Holybro Pixhawk 5X](../flight_controller/pixhawk5x.md) (FMUv5X) - [mRo Pixracer](../flight_controller/pixracer.md) (FMUv4) -- [Hex Cube Black](../flight_controller/pixhawk-2.md) (FMUv3) +- [CubePilot Cube Black](../flight_controller/pixhawk-2.md) (FMUv3) - [mRo Pixhawk](../flight_controller/mro_pixhawk.md) (FMUv3) ## Discontinued diff --git a/docs/en/flight_controller/pixhawk-2.md b/docs/en/flight_controller/pixhawk-2.md index e4a152e61bb..bd2287ab77d 100644 --- a/docs/en/flight_controller/pixhawk-2.md +++ b/docs/en/flight_controller/pixhawk-2.md @@ -1,4 +1,4 @@ -# Hex Cube Black Flight Controller +# CubePilot Cube Black Flight Controller ::: warning PX4 does not manufacture this (or any) autopilot. @@ -6,12 +6,10 @@ Contact the [manufacturer](https://cubepilot.org/#/home) for hardware support or ::: ::: tip -The [Cube Orange](cubepilot_cube_orange.md) is the successor to this product. -We recommend however to consider products built on industry standards, such as the [Pixhawk Standards](autopilot_pixhawk_standard.md). -This flight controller is not following the standard and uses a patented connector. +The [CubePilot Cube Orange](cubepilot_cube_orange.md) and [CubePilot Cube Orange+](cubepilot_cube_orangeplus.md) are successors to this product. ::: -The [Hex Cube Black](https://docs.cubepilot.org/autopilot/the-cube) flight controller (previously known as Pixhawk 2.1) is a flexible autopilot intended primarily for manufacturers of commercial systems. +The [CubePilot Cube Black](https://docs.cubepilot.org/autopilot/the-cube) flight controller (previously known as Pixhawk 2.1) is a flexible autopilot intended primarily for manufacturers of commercial systems. It is based on the [Pixhawk-project](https://pixhawk.org/) **FMUv3** open hardware design and runs PX4 on the [NuttX](https://nuttx.apache.org/) OS. ![Cube Black](../../assets/flight_controller/cube/cube_black_hero.png) diff --git a/docs/en/flight_controller/pixhawk_series.md b/docs/en/flight_controller/pixhawk_series.md index 7ff13be6ff2..cd3451d9fb0 100644 --- a/docs/en/flight_controller/pixhawk_series.md +++ b/docs/en/flight_controller/pixhawk_series.md @@ -72,7 +72,7 @@ PX4 _developers_ need to know the FMU version of their board, as this is require At very high level, the main differences are: - **FMUv2:** Single board with STM32427VI processor (Pixhawk 1 (discontinued), Holybro pix32 (discontinued), Pixfalcon (discontinued), Drotek DroPix (discontinued)) -- **FMUv3:** Identical to FMUv2, but usable flash doubled to 2MB ([Hex Cube Black](../flight_controller/pixhawk-2.md),[CUAV Pixhack v3](../flight_controller/pixhack_v3.md),[mRo Pixhawk](../flight_controller/mro_pixhawk.md), [Pixhawk Mini (Discontinued)](../flight_controller/pixhawk_mini.md)) +- **FMUv3:** Identical to FMUv2, but usable flash doubled to 2MB ([CubePilot Cube Black](../flight_controller/pixhawk-2.md),[CUAV Pixhack v3](../flight_controller/pixhack_v3.md),[mRo Pixhawk](../flight_controller/mro_pixhawk.md), [Pixhawk Mini (Discontinued)](../flight_controller/pixhawk_mini.md)) - **FMUv4:** Increased RAM. Faster CPU. More serial ports. No IO processor ([Pixracer](../flight_controller/pixracer.md)) - **FMUv4-PRO:** Slightly increased RAM. More serial ports. IO processor ([Pixhawk 3 Pro](../flight_controller/pixhawk3_pro.md)) - **FMUv5:** New processor (F7). diff --git a/docs/en/flight_modes/return.md b/docs/en/flight_modes/return.md index 5ffb6f26cff..dc8862a9adb 100644 --- a/docs/en/flight_modes/return.md +++ b/docs/en/flight_modes/return.md @@ -58,7 +58,7 @@ At high level these are: Rally points are not considered. - [Rally point return](#rtl_type_5) (`RTL_TYPE=5`): Return directly to the closest rally point, ignoring home and mission landing. If no rally point is defined, land at the current position (a fixed-wing vehicle circles there instead). -- [Battery-aware home priority return](#rtl_type_6) (`RTL_TYPE=6`): Return to home if the estimated flight time is within the remaining battery time, otherwise return to the closest rally point. +- [Battery-aware home priority return](#rtl_type_6) (`RTL_TYPE=6`): Return to home if the estimated flight time is within the remaining battery time, otherwise return to the closest rally point if it is closer than home. Falls back to the closest safe point (home or rally) if the remaining battery time is unknown/unavailable. More detailed explanations for each of the types are provided in the following sections. @@ -334,17 +334,17 @@ For this reason fixed-wing vehicles are configured to use [Mission landing/reall The Return parameters are listed in [Parameter Reference > Return Mode](../advanced_config/parameter_reference.md#return-mode) (and summarised below). -| Parameter | Description | -| ----------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | -| [RTL_TYPE](../advanced_config/parameter_reference.md#RTL_TYPE) | Return mechanism (path and destination).
`0`: Return to a rally point or home (whichever is closest) via direct path.
`1`: Return to a rally point or the mission landing pattern start point (whichever is closest), via direct path. If neither mission landing or rally points are defined return home via a direct path. If the destination is a mission landing pattern, follow the pattern to land.
`2`: Use the mission path to landing while skipping DO_JUMP and other non-position mission items if a landing pattern is defined, otherwise fast-reverse to home with the same traversal rules. Ignore rally points. Fly direct to home if no mission plan is defined.
`3`: Return via direct path to closest destination: home, start of mission landing pattern or safe point. If the destination is a mission landing pattern, follow the pattern to land.
`4`: Like type 2, but selects between mission landing (fast-forward) and reverse mission path based on which requires fewer waypoints from the current position. Rally points not considered. Fly direct to home if no mission is defined.
`5`: Return via direct path to closest rally point. If no rally points are defined, land at current position (a fixed-wing vehicle circles there).
`6`: Return to home if estimated flight time to home is less than remaining battery time, otherwise return to closest rally point. Falls back to closest safe point (home or rally) if battery time remaining is unavailable. | -| [RTL_RETURN_ALT](../advanced_config/parameter_reference.md#RTL_RETURN_ALT) | Return altitude in meters (default: 60m) when [RTL_CONE_ANG](../advanced_config/parameter_reference.md#RTL_CONE_ANG) is 0. If already above this value the vehicle will return at its current altitude. | -| [RTL_DESCEND_ALT](../advanced_config/parameter_reference.md#RTL_DESCEND_ALT) | Altitude above the destination used for the final descent before landing or loitering (default: 30m). | -| [RTL_LAND_DELAY](../advanced_config/parameter_reference.md#RTL_LAND_DELAY) | Time to wait at `RTL_DESCEND_ALT` before landing (default: 0 s, -1 on fixed-wing airframes). If set to -1 the system will loiter at `RTL_DESCEND_ALT` rather than landing. The delay is provided to allow you to configure time for landing gear to be deployed (triggered automatically). | -| [RTL_MIN_DIST](../advanced_config/parameter_reference.md#RTL_MIN_DIST) | Within this distance from the return destination, the return altitude is calculated from the "cone" rather than directly from `RTL_RETURN_ALT`. | -| [RTL_CONE_ANG](../advanced_config/parameter_reference.md#RTL_CONE_ANG) | Half-angle of the cone that defines the vehicle return altitude. Values (in degrees): `0`, `25`, `45`, `65`, `80`, `90`. Note that `0` is "no cone" (always return at `RTL_RETURN_ALT` or higher), while `90` indicates an almost vertical cone, so the vehicle generally returns at its current altitude when close to the destination. The return altitude may still be constrained to avoid flying too low while approaching the destination. | -| [RTL_APPR_FORCE](../advanced_config/parameter_reference.md#RTL_APPR_FORCE) | [VTOL FW only] If set, home or rally-point return destinations are only considered when a valid VTOL approach loiter is defined for that landing location. Mission landing patterns are unaffected. | -| [MAN_OVERRIDE_SPD](../advanced_config/parameter_reference.md#MAN_OVERRIDE_SPD) | Speed (normalized stick travel per second) above which moving the sticks controlling a multicopter (or VTOL in hover) gives control back to the pilot by switching to [Position mode](../flight_modes_mc/position.md) (or Altitude mode if position is unavailable). At the default 1 a half-stick movement in ~0.5 s triggers it; lower is more sensitive. A stick held statically has zero speed and will not trigger. Set to -1 to disable. | -| [RTL_LOITER_RAD](../advanced_config/parameter_reference.md#RTL_LOITER_RAD) | [Fixed-wing Only] The radius of the loiter circle (at [RTL_LAND_DELAY](#RTL_LAND_DELAY)). | -| [MIS_TKO_LAND_REQ](../advanced_config/parameter_reference.md#MIS_TKO_LAND_REQ) | Specify whether a mission landing or takeoff pattern is _required_. Generally fixed-wing vehicles set this to require a landing pattern but VTOL do not. | -| [RTL_TIME_FACTOR](../advanced_config/parameter_reference.md#RTL_TIME_FACTOR) | Return time estimate safety factor. | -| [RTL_TIME_MARGIN](../advanced_config/parameter_reference.md#RTL_TIME_MARGIN) | Return time estimate safety margin. | +| Parameter | Description | +| ----------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| [RTL_TYPE](../advanced_config/parameter_reference.md#RTL_TYPE) | Return mechanism (path and destination).
`0`: Return to a rally point or home (whichever is closest) via direct path.
`1`: Return to a rally point or the mission landing pattern start point (whichever is closest), via direct path. If neither mission landing or rally points are defined return home via a direct path. If the destination is a mission landing pattern, follow the pattern to land.
`2`: Use the mission path to landing while skipping DO_JUMP and other non-position mission items if a landing pattern is defined, otherwise fast-reverse to home with the same traversal rules. Ignore rally points. Fly direct to home if no mission plan is defined.
`3`: Return via direct path to closest destination: home, start of mission landing pattern or safe point. If the destination is a mission landing pattern, follow the pattern to land.
`4`: Like type 2, but selects between mission landing (fast-forward) and reverse mission path based on which requires fewer waypoints from the current position. Rally points not considered. Fly direct to home if no mission is defined.
`5`: Return via direct path to closest rally point. If no rally points are defined, land at current position (a fixed-wing vehicle circles there).
`6`: Return to home if estimated flight time to home is less than remaining battery time, otherwise return to closest rally point if it is closer than home. Falls back to closest safe point (home or rally) if battery time remaining is unavailable. | +| [RTL_RETURN_ALT](../advanced_config/parameter_reference.md#RTL_RETURN_ALT) | Return altitude in meters (default: 60m) when [RTL_CONE_ANG](../advanced_config/parameter_reference.md#RTL_CONE_ANG) is 0. If already above this value the vehicle will return at its current altitude. | +| [RTL_DESCEND_ALT](../advanced_config/parameter_reference.md#RTL_DESCEND_ALT) | Altitude above the destination used for the final descent before landing or loitering (default: 30m). | +| [RTL_LAND_DELAY](../advanced_config/parameter_reference.md#RTL_LAND_DELAY) | Time to wait at `RTL_DESCEND_ALT` before landing (default: 0 s, -1 on fixed-wing airframes). If set to -1 the system will loiter at `RTL_DESCEND_ALT` rather than landing. The delay is provided to allow you to configure time for landing gear to be deployed (triggered automatically). | +| [RTL_MIN_DIST](../advanced_config/parameter_reference.md#RTL_MIN_DIST) | Within this distance from the return destination, the return altitude is calculated from the "cone" rather than directly from `RTL_RETURN_ALT`. | +| [RTL_CONE_ANG](../advanced_config/parameter_reference.md#RTL_CONE_ANG) | Half-angle of the cone that defines the vehicle return altitude. Values (in degrees): `0`, `25`, `45`, `65`, `80`, `90`. Note that `0` is "no cone" (always return at `RTL_RETURN_ALT` or higher), while `90` indicates an almost vertical cone, so the vehicle generally returns at its current altitude when close to the destination. The return altitude may still be constrained to avoid flying too low while approaching the destination. | +| [RTL_APPR_FORCE](../advanced_config/parameter_reference.md#RTL_APPR_FORCE) | [VTOL FW only] If set, home or rally-point return destinations are only considered when a valid VTOL approach loiter is defined for that landing location. Mission landing patterns are unaffected. | +| [MAN_OVERRIDE_SPD](../advanced_config/parameter_reference.md#MAN_OVERRIDE_SPD) | Speed (normalized stick travel per second) above which moving the sticks controlling a multicopter (or VTOL in hover) gives control back to the pilot by switching to [Position mode](../flight_modes_mc/position.md) (or Altitude mode if position is unavailable). At the default 1 a half-stick movement in ~0.5 s triggers it; lower is more sensitive. A stick held statically has zero speed and will not trigger. Set to -1 to disable. | +| [RTL_LOITER_RAD](../advanced_config/parameter_reference.md#RTL_LOITER_RAD) | [Fixed-wing Only] The radius of the loiter circle (at [RTL_LAND_DELAY](#RTL_LAND_DELAY)). | +| [MIS_TKO_LAND_REQ](../advanced_config/parameter_reference.md#MIS_TKO_LAND_REQ) | Specify whether a mission landing or takeoff pattern is _required_. Generally fixed-wing vehicles set this to require a landing pattern but VTOL do not. | +| [RTL_TIME_FACTOR](../advanced_config/parameter_reference.md#RTL_TIME_FACTOR) | Return time estimate safety factor. | +| [RTL_TIME_MARGIN](../advanced_config/parameter_reference.md#RTL_TIME_MARGIN) | Return time estimate safety margin. | diff --git a/docs/en/frames_multicopter/omnicopter.md b/docs/en/frames_multicopter/omnicopter.md index c3a9637daf9..d5a3ff930e0 100644 --- a/docs/en/frames_multicopter/omnicopter.md +++ b/docs/en/frames_multicopter/omnicopter.md @@ -114,7 +114,6 @@ Make sure the motors do not overheat with the changed settings. Make sure to use the right props, as there is a CCW and a CW version. - Parameters: - Change the desaturation logic for better attitude tracking: set [CA_METHOD](../advanced_config/parameter_reference.md#CA_METHOD) to 0. - - Disable failure detection: set [FD_FAIL_P](../advanced_config/parameter_reference.md#FD_FAIL_P) and [FD_FAIL_R](../advanced_config/parameter_reference.md#FD_FAIL_R) to 0. - [This file](https://github.com/PX4/PX4-Autopilot/raw/main/docs/assets/airframes/multicopter/omnicopter/omnicopter.params) contains all the relevant parameters. ## Video diff --git a/docs/en/gps_compass/gps_cubepilot_here2.md b/docs/en/gps_compass/gps_cubepilot_here2.md new file mode 100644 index 00000000000..29c5cb162bf --- /dev/null +++ b/docs/en/gps_compass/gps_cubepilot_here2.md @@ -0,0 +1,89 @@ +# CubePilot Here2 GPS (Discontinued) + +::: warning +This has been superseded by newer CubePilot [DroneCAN](../dronecan/index.md) GNSS modules such as the [Here4](../dronecan/cubepilot_here4.md). +See [RTK GNSS](../gps_compass/rtk_gps.md#supported-devices) for the current CubePilot modules. +::: + +The _Here2 GPS receiver_ is an update to the Here GPS module from CubePilot. + +Main features include: + +- Concurrent reception of up to 3 GNSS (GPS, Galileo, GLOSNASS, BeiDou) +- Industry Leading -167 dBm navigation sensitivity +- Security and integrity protection +- Supports all satellite augmentation systems +- Advanced jamming and spoofing detection + + + +## Where to Buy + +- [Resellers](https://cubepilot.org/#/reseller/list) + +## Configuration + +Setup and use on PX4 is largely plug and play. + +::: info + +- If the GPS is _not detected_ then [update the Here2 firmware](https://docs.cubepilot.org/here-2/updating-here-2-firmware). +- If the GPS is detected but does not work, attempt the process outlined in [allocating node uavcan ID](https://docs.cubepilot.org/here-2/here-2-can-mode-instruction). + ::: + +## Wiring and Connections + +The Here2 GPS comes with an 8 pin connector that can be inserted directly into the Pixhawk 2 `GPS` UART port. + +The Pixhawk 3 Pro and Pixracer have a 6 pin GPS port connector. +For these controllers you can modify the GPS cable (as shown below) to remove pin 6 and 7. + + + +Pin 6 and 7 are for the safety button - these can be attached as well if needed. + +### Pinout + +The Here2 GPS pinout is provided below. This can be used to help modify the connector for other autopilot boards. + +| pin | Here2 GPS | pin | Pixhawk 3 Pro GPS | +| --- | ---------- | --- | ----------------- | +| 1 | VCC_5V | 1 | VCC | +| 2 | GPS_RX | 2 | GPS_TX | +| 3 | GPS_TX | 3 | GPS_RX | +| 4 | SCL | 4 | SCL | +| 5 | SDA | 5 | SDA | +| 6 | BUTTON | - | - | +| 7 | BUTTON_LED | - | - | +| 8 | GND | 6 | GND | + +## Specification + +- **Processor:** STM32F302 +- **Sensor** + - **Compass, Gyro, Accelerometer:** ICM20948 + - **Barometer:** MS5611 +- **Receiver Type:** 72-channel u-blox M8N engine, GPS/QZSS L2 C/A, GLONASS L10F, BeiDou B11, Galileo E1B/C, SBAS L1 C/A: WAAS, EGNOS, MSAS, GAGAN +- **Navigation Update Rate:** Max: 10 Hz +- **Positionaing Accuracy:** 3D Fix +- **Time to first fix:** + - **Cold start:** 26s + - **Aided start:** 2s + - **Reacquisition:** 1s +- **Sensitivity:** + - **Tracking & Navigation:** -167 dBm + - **Hot start:** -148 dBm + - **Cold start:** -157 dBm +- **Assisted GNSS** + - AssistNow GNSS Online + - AssistNow GNSS Offline (up to 35 days) + - AssistNow Autonomous (up to 6 days) + - OMA SUPL& 3GPP compliant +- **Oscillator:** TCXO (NEO-8MN/Q) +- **RTC crystal:** Build in +- **ROM:** Flash (NEO-8MN) +- **Available Antennas:** Active Antenna & Passive Antenna +- **Signal Integrity:** Signature feature with SHA 256 +- **Protocols & Interfaces:** + - **UART/I2C/CAN:** JST_GH Main interface, Switch internally. + - **STM32 Main Programming Interface:** JST_SUR diff --git a/docs/en/gps_compass/gps_hex_here2.md b/docs/en/gps_compass/gps_hex_here2.md index b87a1415b90..0afa109a8d3 100644 --- a/docs/en/gps_compass/gps_hex_here2.md +++ b/docs/en/gps_compass/gps_hex_here2.md @@ -1,88 +1 @@ -# HEX/ProfiCNC Here2 GPS (Discontinued) - -::: warning -This has been superseded by the [Cube Here 3](https://cubepilot.org/#/here/here3) -::: - -The _Here2 GPS receiver_ is an update to the Here GPS module from HEX. - -Main features include: - -- Concurrent reception of up to 3 GNSS (GPS, Galileo, GLOSNASS, BeiDou) -- Industry Leading -167 dBm navigation sensitivity -- Security and integrity protection -- Supports all satellite augmentation systems -- Advanced jamming and spoofing detection - - - -## Where to Buy - -- [Resellers](https://cubepilot.org/#/reseller/list) - -## Configuration - -Setup and use on PX4 is largely plug and play. - -::: info - -- If the GPS is _not detected_ then [update the Here2 firmware](https://docs.cubepilot.org/here-2/updating-here-2-firmware). -- If the GPS is detected but does not work, attempt the process outlined in [allocating node uavcan ID](https://docs.cubepilot.org/here-2/here-2-can-mode-instruction). - ::: - -## Wiring and Connections - -The Here2 GPS comes with an 8 pin connector that can be inserted directly into the Pixhawk 2 `GPS` UART port. - -The Pixhawk 3 Pro and Pixracer have a 6 pin GPS port connector. -For these controllers you can modify the GPS cable (as shown below) to remove pin 6 and 7. - - - -Pin 6 and 7 are for the safety button - these can be attached as well if needed. - -### Pinout - -The Here2 GPS pinout is provided below. This can be used to help modify the connector for other autopilot boards. - -| pin | Here2 GPS | pin | Pixhawk 3 Pro GPS | -| --- | ---------- | --- | ----------------- | -| 1 | VCC_5V | 1 | VCC | -| 2 | GPS_RX | 2 | GPS_TX | -| 3 | GPS_TX | 3 | GPS_RX | -| 4 | SCL | 4 | SCL | -| 5 | SDA | 5 | SDA | -| 6 | BUTTON | - | - | -| 7 | BUTTON_LED | - | - | -| 8 | GND | 6 | GND | - -## Specification - -- **Processor:** STM32F302 -- **Sensor** - - **Compass, Gyro, Accelerometer:** ICM20948 - - **Barometer:** MS5611 -- **Receiver Type:** 72-channel u-blox M8N engine, GPS/QZSS L2 C/A, GLONASS L10F, BeiDou B11, Galileo E1B/C, SBAS L1 C/A: WAAS, EGNOS, MSAS, GAGAN -- **Navigation Update Rate:** Max: 10 Hz -- **Positionaing Accuracy:** 3D Fix -- **Time to first fix:** - - **Cold start:** 26s - - **Aided start:** 2s - - **Reacquisition:** 1s -- **Sensitivity:** - - **Tracking & Navigation:** -167 dBm - - **Hot start:** -148 dBm - - **Cold start:** -157 dBm -- **Assisted GNSS** - - AssistNow GNSS Online - - AssistNow GNSS Offline (up to 35 days) - - AssistNow Autonomous (up to 6 days) - - OMA SUPL& 3GPP compliant -- **Oscillator:** TCXO (NEO-8MN/Q) -- **RTC crystal:** Build in -- **ROM:** Flash (NEO-8MN) -- **Available Antennas:** Active Antenna & Passive Antenna -- **Signal Integrity:** Signature feature with SHA 256 -- **Protocols & Interfaces:** - - **UART/I2C/CAN:** JST_GH Main interface, Switch internally. - - **STM32 Main Programming Interface:** JST_SUR + diff --git a/docs/en/gps_compass/index.md b/docs/en/gps_compass/index.md index 7bbda51d989..bef299fdaff 100644 --- a/docs/en/gps_compass/index.md +++ b/docs/en/gps_compass/index.md @@ -33,7 +33,7 @@ These have been tested by the PX4 dev team, or which are popular within the PX4 | [CUAV NEO 3 GPS](../gps_compass/gps_cuav_neo_3.md) | M9N | IST8310 | | ✓ | | | [CUAV NEO 3 Pro GPS](../gps_compass/gps_cuav_neo_3pro.md) | M9N | RM3100 | ✓ | ✓ | + Baro | | [CUAV NEO 3X GPS](../gps_compass/gps_cuav_neo_3x.md) | M9N | RM3100 | ✓ | ✘✓✓ | + Baro. | -| [CubePilot Here2 GNSS GPS (M8N)][CubePilot Here2] | M8N | ICM20948 | | ✓ | Superseded by HERE3 | +| [CubePilot Here2 GNSS GPS (M8N)][CubePilot Here2] | M8N | ICM20948 | | ✓ | Superseded by Here4 | | [Emlid Reach M+](https://emlid.com/reach/) | ✓ | ✘ | | ✘ | Supports PPK. RTK expected. | | [Holybro DroneCAN M8N GPS](../dronecan/holybro_m8n_gps.md) | M8N | BMM150 | ✓ | ✘ | + Baro | | [Holybro Micro M8N GPS][Hb Micro M8N] | M8N | IST8310 | | ✘ | | @@ -62,7 +62,7 @@ These have been tested by the PX4 dev team, or which are popular within the PX4 [RccnLabGNSS250]: https://docs.raccoonlab.co/guide/gps_mag_baro/gnss_v250.html [LOCOSYS Hawk A1]: ../gps_compass/gps_locosys_hawk_a1.md [Hb Micro M8N]: https://holybro.com/products/micro-m8n-gps -[CubePilot Here2]: ../gps_compass/gps_hex_here2.md +[CubePilot Here2]: ../gps_compass/gps_cubepilot_here2.md Notes: diff --git a/docs/en/gps_compass/rtk_gps.md b/docs/en/gps_compass/rtk_gps.md index c044f71f2aa..388311eb23a 100644 --- a/docs/en/gps_compass/rtk_gps.md +++ b/docs/en/gps_compass/rtk_gps.md @@ -32,8 +32,11 @@ It also highlights devices that connect via the CAN bus, and those which support | [CUAV C-RTK2](../gps_compass/rtk_gps_cuav_c-rtk2.md) | F9P | ✓ | | [Dual F9P] | | | [CUAV C-RTK 9Ps GPS](../gps_compass/rtk_gps_cuav_c-rtk-9ps.md) | F9P | RM3100 | | [Dual F9P] | | | [CUAV C-RTK2 PPK/RTK GNSS](../gps_compass/rtk_gps_cuav_c-rtk.md) | F9P | RM3100 | | | ✓ | -| [CubePilot Here+ RTK GPS](../gps_compass/rtk_gps_hex_hereplus.md) | M8P | HMC5983 | | | | -| [CubePilot Here3 CAN GNSS GPS (M8N)](https://www.cubepilot.org/#/here/here3) | M8P | ICM20948 | ✓ | | | +| [CubePilot Here+ RTK GPS](../gps_compass/rtk_gps_cubepilot_hereplus.md) | M8P | HMC5983 | | | | +| [CubePilot Here3][CubePilot Here3] | M8P | ICM20948 | ✓ | | | +| [CubePilot Here3+][CubePilot Here3] | M8P | RM3100 | ✓ | | | +| [CubePilot Here4][CubePilot Here4] | NEO-F9P | RM3100 | ✓ | | | +| [CubePilot HerePro][CubePilot HerePro] | F9P | ✓ | ✓ | | | | [Drotek SIRIUS RTK GNSS ROVER (F9P)](https://store-drotek.com/911-sirius-rtk-gnss-rover-f9p.html) | F9P | RM3100 | | [Dual F9P] | | | [DATAGNSS NANO HRTK Receiver](../gps_compass/rtk_gps_datagnss_nano_hrtk.md) | [D10P] | IST8310 | | ✘ | | | [DATAGNSS GEM1305 RTK Receiver](../gps_compass/rtk_gps_gem1305.md) | TAU951M | IST8310 | | ✘ | | @@ -69,6 +72,9 @@ It also highlights devices that connect via the CAN bus, and those which support [Unicore Dual Antenna]: ../gps_compass/rtk_gps_holybro_unicore_um982.md#enable-gps-heading-yaw [DATAGNSS GEM1305 RTK]: ../gps_compass/rtk_gps_gem1305.md [DroneCAN]: ../dronecan/index.md +[CubePilot Here3]: https://docs.cubepilot.org/here-3-3+/here-3-manual +[CubePilot Here4]: ../dronecan/cubepilot_here4.md +[CubePilot HerePro]: https://docs.cubepilot.org/herepro/herepro-manual [GPS Yaw]: #configuring-gps-as-yaw-heading-source [mosaic-G5 P3]: https://www.septentrio.com/en/products/gnss-receivers/gnss-receiver-modules/mosaic-G5-P3 [mosaic-G5 P3H]: https://www.septentrio.com/en/products/gnss-receivers/gnss-receiver-modules/mosaic-G5-P3H @@ -81,8 +87,9 @@ Notes: - Where possible and relevant the part name is used (i.e. ✓ in the GPS column indicates that a GPS module is present but the part is not known). - Some RTK modules can only be used in a particular role (base or rover), while others can be used interchangeably. - The list may omit some discontinued hardware that is still supported. - For example [CubePilot Here+ RTK GPS](../gps_compass/rtk_gps_hex_hereplus.md) is discontinued and may be removed from the list in a future release. + For example [CubePilot Here+ RTK GPS](../gps_compass/rtk_gps_cubepilot_hereplus.md) is discontinued and may be removed from the list in a future release. Check earlier versions if a discontinued module is not mentioned here. +- See [CubePilot Here4](../dronecan/cubepilot_here4.md) for the Here4 Base and Here4 Blue variants, and for CubePilot's mandatory Here4 bootloader update. ## Positioning Setup/Configuration diff --git a/docs/en/gps_compass/rtk_gps_cubepilot_hereplus.md b/docs/en/gps_compass/rtk_gps_cubepilot_hereplus.md new file mode 100644 index 00000000000..bdf62e1cf42 --- /dev/null +++ b/docs/en/gps_compass/rtk_gps_cubepilot_hereplus.md @@ -0,0 +1,13 @@ +# CubePilot Here+ RTK GPS (Discontinued) + + + +::: info +This GPS is no longer available for purchase but is still compatible with PX4. + +Usage documentation can be found in [PX4v1.11 docs](https://docs.px4.io/v1.11/en/gps_compass/rtk_gps_hex_hereplus) +::: + +The **Here+ RTK GPS receiver** is a small, light and energy efficient [RTK GPS module](../gps_compass/rtk_gps.md), based on the u-blox M8P. Using RTK, PX4 can get its position with centimetre-level accuracy, which is much more accurate than can be provided by a normal GPS. + + diff --git a/docs/en/gps_compass/rtk_gps_freefly.md b/docs/en/gps_compass/rtk_gps_freefly.md index f349fa19335..cf830e29ac7 100644 --- a/docs/en/gps_compass/rtk_gps_freefly.md +++ b/docs/en/gps_compass/rtk_gps_freefly.md @@ -42,7 +42,7 @@ For use as a base station, the module has a USB-C connector ### Pinout The Freefly GPS pinout is provided below. -For some autopilots, like the [Hex Cube](../flight_controller/pixhawk-2.md) and [PixRacer](../flight_controller/pixracer.md), all that is needed is a 1-1 8-pin JST-GH cable. +For some autopilots, like the [CubePilot Cube](../flight_controller/pixhawk-2.md) and [PixRacer](../flight_controller/pixracer.md), all that is needed is a 1-1 8-pin JST-GH cable. | Pin | Freefly GPS | | --- | ----------- | diff --git a/docs/en/gps_compass/rtk_gps_hex_hereplus.md b/docs/en/gps_compass/rtk_gps_hex_hereplus.md index c4b924b9fe2..786f4f0b3f6 100644 --- a/docs/en/gps_compass/rtk_gps_hex_hereplus.md +++ b/docs/en/gps_compass/rtk_gps_hex_hereplus.md @@ -1,13 +1 @@ -# HEX/ProfiCNC Here+ RTK GPS (Discontinued) - - - -::: info -This GPS is no longer available for purchase but is still compatible with PX4. - -Usage documentation can be found in [PX4v1.11 docs](https://docs.px4.io/v1.11/en/gps_compass/rtk_gps_hex_hereplus) -::: - -The **Here+ RTK GPS receiver** is a small, light and energy efficient [RTK GPS module](../gps_compass/rtk_gps.md), based on the u-blox M8P. Using RTK, PX4 can get its position with centimetre-level accuracy, which is much more accurate than can be provided by a normal GPS. - - + diff --git a/docs/en/gps_compass/rtk_gps_holybro_unicore_um982.md b/docs/en/gps_compass/rtk_gps_holybro_unicore_um982.md index e84c7c53518..dc8a5755e73 100644 --- a/docs/en/gps_compass/rtk_gps_holybro_unicore_um982.md +++ b/docs/en/gps_compass/rtk_gps_holybro_unicore_um982.md @@ -26,8 +26,8 @@ Additional technical information can be found at [Holybro Technical Documentatio The module comes with both GH 10-pin & 6-pin cables that are compatible with the GPS1 & GPS2 ports on flight controllers that use the [Pixhawk Connector Standard](https://github.com/pixhawk/Pixhawk-Standards/blob/master/DS-009%20Pixhawk%20Connector%20Standard.pdf), such as [Pixhawk 6x](../flight_controller/pixhawk6x.md) and [Pixhawk 6c](../flight_controller/pixhawk6c.md). -It can also be used with Cubepilot Flight Controller. -The 10Pin - 6Pin cable allows users to connect the UM982 to `GPS2` port on Cubepilot and Holybro Autopilots. +It can also be used with CubePilot Flight Controller. +The 10Pin - 6Pin cable allows users to connect the UM982 to `GPS2` port on CubePilot and Holybro Autopilots. The module can be used with one antenna or both antennas. If it is used with only one antenna, the right/primary antenna connector must be connected. diff --git a/docs/en/hardware/reference_design.md b/docs/en/hardware/reference_design.md index 7fa6a6c45c4..0026e015d06 100644 --- a/docs/en/hardware/reference_design.md +++ b/docs/en/hardware/reference_design.md @@ -14,7 +14,7 @@ FMU generations 1-3 were designed as open hardware, while FMU generations 4 and - FMUv1: Development board \(STM32F407, 128 KB RAM, 1MB flash, [schematics](https://github.com/pixhawk/Hardware/tree/master/FMUv1)\) (no longer supported by PX4) - FMUv2: Pixhawk \(STM32F427, 168 MHz, 192 KB RAM, 1MB flash, [schematics](https://github.com/pixhawk/Hardware/tree/master/FMUv2)\) -- FMUv3: Pixhawk variants with 2MB flash \(3DR Pixhawk 2 \(Solo\), Hex Pixhawk 2.1, Holybro Pixfalcon, 3DR Pixhawk Mini, STM32F427, 168 MHz, 256 KB RAM, 2 MB flash, [schematics](https://github.com/pixhawk/Hardware/tree/master/FMUv3_REV_D)\) +- FMUv3: Pixhawk variants with 2MB flash \(3DR Pixhawk 2 \(Solo\), CubePilot Pixhawk 2.1, Holybro Pixfalcon, 3DR Pixhawk Mini, STM32F427, 168 MHz, 256 KB RAM, 2 MB flash, [schematics](https://github.com/pixhawk/Hardware/tree/master/FMUv3_REV_D)\) - FMUv4: Pixracer \(STM32F427, 168 MHz, 256 KB RAM, 2 MB flash, [pinout](https://docs.google.com/spreadsheets/d/1raRRouNsveQz8cj-EneWG6iW0dqGfRAifI91I2Sr5E0/edit#gid=1585075739)\) - FMUv4 PRO: Drotek Pixhawk 3 PRO \(STM32F469, 180 MHz, 384 KB RAM, 2 MB flash, [pinout](https://docs.google.com/spreadsheets/d/1raRRouNsveQz8cj-EneWG6iW0dqGfRAifI91I2Sr5E0/edit#gid=1585075739)\) - FMUv5: Holybro Pixhawk 4 \(STM32F765, 216 MHz, 512 KB RAM, 2 MB flash, [pinout](https://docs.google.com/spreadsheets/d/1-n0__BYDedQrc_2NHqBenG1DNepAgnHpSGglke-QQwY/edit#gid=912976165)\) diff --git a/docs/en/middleware/dds_topics.md b/docs/en/middleware/dds_topics.md index 5b94174c9f9..2e69ce3cb4e 100644 --- a/docs/en/middleware/dds_topics.md +++ b/docs/en/middleware/dds_topics.md @@ -68,7 +68,6 @@ This document shows a markdown-rendered version of [dds_topics.yaml](https://git | `/fmu/in/onboard_computer_status` | [px4_msgs::msg::OnboardComputerStatus](../msg_docs/OnboardComputerStatus.md) | | `/fmu/in/register_ext_component_request` | [px4_msgs::msg::RegisterExtComponentRequest](../msg_docs/RegisterExtComponentRequest.md) | | `/fmu/in/sensor_gnss` | [px4_msgs::msg::SensorGnss](../msg_docs/SensorGnss.md) | -| `/fmu/in/sensor_optical_flow` | [px4_msgs::msg::SensorOpticalFlow](../msg_docs/SensorOpticalFlow.md) | | `/fmu/in/setpoint_config` | [px4_msgs::msg::SetpointConfig](../msg_docs/SetpointConfig.md) | | `/fmu/in/surface_vehicle_attitude_setpoint` | [px4_msgs::msg::SurfaceVehicleAttitudeSetpoint](../msg_docs/SurfaceVehicleAttitudeSetpoint.md) | | `/fmu/in/surface_vehicle_course_setpoint` | [px4_msgs::msg::SurfaceVehicleCourseSetpoint](../msg_docs/SurfaceVehicleCourseSetpoint.md) | @@ -95,6 +94,7 @@ This document shows a markdown-rendered version of [dds_topics.yaml](https://git | --------------------------- | -------------------------------------------------------------------- | ----------- | ------------- | | /fmu/in/aux_global_position | [px4_msgs::msg::AuxGlobalPosition](../msg_docs/AuxGlobalPosition.md) | `id` | 4 | | /fmu/in/rtcm_corrections | [px4_msgs::msg::RtcmData](../msg_docs/RtcmData.md) | `device_id` | 4 | +| /fmu/in/sensor_optical_flow | [px4_msgs::msg::SensorOpticalFlow](../msg_docs/SensorOpticalFlow.md) | `device_id` | 2 | ## Not Exported diff --git a/docs/en/msg_docs/FailureDetectorStatus.md b/docs/en/msg_docs/FailureDetectorStatus.md index 66ce842e645..44a1262c826 100644 --- a/docs/en/msg_docs/FailureDetectorStatus.md +++ b/docs/en/msg_docs/FailureDetectorStatus.md @@ -11,8 +11,7 @@ pageClass: is-wide-page | Name | Type | Unit [Frame] | Range/Enum | Description | | ------------------------------------------------------------- | --------- | ------------ | ---------- | --------------------------------------------------------------- | | timestamp | `uint64` | | | time since system start (microseconds) | -| fd_roll | `bool` | | | -| fd_pitch | `bool` | | | +| fd_tilt | `bool` | | | | fd_alt | `bool` | | | | fd_ext | `bool` | | | | fd_arm_escs | `bool` | | | @@ -33,8 +32,7 @@ pageClass: is-wide-page uint64 timestamp # time since system start (microseconds) # FailureDetector status -bool fd_roll -bool fd_pitch +bool fd_tilt bool fd_alt bool fd_ext bool fd_arm_escs diff --git a/docs/en/msg_docs/TelemetryStatus.md b/docs/en/msg_docs/TelemetryStatus.md index e22a4c54546..4f91e7af4cf 100644 --- a/docs/en/msg_docs/TelemetryStatus.md +++ b/docs/en/msg_docs/TelemetryStatus.md @@ -32,6 +32,7 @@ pageClass: is-wide-page | rx_packet_drop_count | `uint32` | | | number of packet drops | | rx_unknown_message_count | `uint32` | | | number of messages not in the dialect, not processed | | rx_bad_signature_count | `uint32` | | | number of messages with missing or invalid signature, not processed | +| rx_bad_crc_count | `uint32` | | | number of known messages dropped for a bad CRC | | rx_message_lost_rate | `float32` | | | fraction of messages lost (0 to 1) | | heartbeat_type_antenna_tracker | `bool` | | | MAV_TYPE_ANTENNA_TRACKER | | heartbeat_type_gcs | `bool` | | | MAV_TYPE_GCS | @@ -106,6 +107,7 @@ uint32 rx_parse_errors # number of parse errors uint32 rx_packet_drop_count # number of packet drops uint32 rx_unknown_message_count # number of messages not in the dialect, not processed uint32 rx_bad_signature_count # number of messages with missing or invalid signature, not processed +uint32 rx_bad_crc_count # number of known messages dropped for a bad CRC float32 rx_message_lost_rate # fraction of messages lost (0 to 1) diff --git a/docs/en/msg_docs/VehicleCommand.md b/docs/en/msg_docs/VehicleCommand.md index 01c3f7cf6d3..cfae64ec7a8 100644 --- a/docs/en/msg_docs/VehicleCommand.md +++ b/docs/en/msg_docs/VehicleCommand.md @@ -1627,7 +1627,7 @@ Change heading/course. param1: heading type (0=course-over-ground, 1=heading). p | MESSAGE_VERSION | `uint32` | 1 | | PREFLIGHT_CALIBRATION_TEMPERATURE_CALIBRATION | `uint16` | 3 | Param value for VEHICLE_CMD_PREFLIGHT_CALIBRATION to start temperature calibration. | | FUSION_SOURCE_GPS | `uint8` | 0 | GNSS (EKF2_GPS{i}\_CTRL, use instance param) | -| FUSION_SOURCE_OF | `uint8` | 1 | Optical Flow (EKF2_OF_CTRL) | +| FUSION_SOURCE_OF | `uint8` | 1 | Optical Flow (toggles all sensors, per-slot config via EKF2_OF{i}\_CTRL) | | FUSION_SOURCE_EV | `uint8` | 2 | External Vision (EKF2_EV_CTRL) | | FUSION_SOURCE_AGP | `uint8` | 3 | Auxiliary Global Position (EKF2_AGP{i}\_CTRL, use instance param) | | FUSION_SOURCE_BARO | `uint8` | 4 | Barometer (EKF2_BARO_CTRL) | @@ -1819,7 +1819,7 @@ uint16 VEHICLE_CMD_EXTERNAL_WIND_ESTIMATE = 43004 uint16 VEHICLE_CMD_ESTIMATOR_SENSOR_ENABLE = 43006 # Enable/disable estimator sensor fusion. |Source (FUSION_SOURCE_*)|Sensor instance (0-based)|Enable (1) or Disable (0)|Estimator Instance (NaN: not used)|Empty|Empty|Empty| # Sensor fusion source types for VEHICLE_CMD_ESTIMATOR_SENSOR_ENABLE uint8 FUSION_SOURCE_GPS = 0 # GNSS (EKF2_GPS{i}_CTRL, use instance param) -uint8 FUSION_SOURCE_OF = 1 # Optical Flow (EKF2_OF_CTRL) +uint8 FUSION_SOURCE_OF = 1 # Optical Flow (toggles all sensors, per-slot config via EKF2_OF{i}_CTRL) uint8 FUSION_SOURCE_EV = 2 # External Vision (EKF2_EV_CTRL) uint8 FUSION_SOURCE_AGP = 3 # Auxiliary Global Position (EKF2_AGP{i}_CTRL, use instance param) uint8 FUSION_SOURCE_BARO = 4 # Barometer (EKF2_BARO_CTRL) diff --git a/docs/en/msg_docs/VehicleOpticalFlow.md b/docs/en/msg_docs/VehicleOpticalFlow.md index a3e4277318c..0bafa95cdc5 100644 --- a/docs/en/msg_docs/VehicleOpticalFlow.md +++ b/docs/en/msg_docs/VehicleOpticalFlow.md @@ -23,6 +23,7 @@ Optical flow in XYZ body frame in SI units. | max_flow_rate | `float32` | | | (radians/s) Magnitude of maximum angular which the optical flow sensor can measure reliably | | min_ground_distance | `float32` | | | (meters) Minimum distance from ground at which the optical flow sensor operates reliably | | max_ground_distance | `float32` | | | (meters) Maximum distance from ground at which the optical flow sensor operates reliably | +| position_offset | `float32[3]` | | | (meters) Position of the sensor focal point in body FRD frame, relative to the vehicle centre of gravity | ## Source Message @@ -52,6 +53,8 @@ float32 max_flow_rate # (radians/s) Magnitude of maximum angular which float32 min_ground_distance # (meters) Minimum distance from ground at which the optical flow sensor operates reliably float32 max_ground_distance # (meters) Maximum distance from ground at which the optical flow sensor operates reliably + +float32[3] position_offset # (meters) Position of the sensor focal point in body FRD frame, relative to the vehicle centre of gravity ``` ::: diff --git a/docs/en/peripherals/mavlink_peripherals.md b/docs/en/peripherals/mavlink_peripherals.md index 4ad2b8d1f22..b882dfb97a1 100644 --- a/docs/en/peripherals/mavlink_peripherals.md +++ b/docs/en/peripherals/mavlink_peripherals.md @@ -12,7 +12,13 @@ The most relevant parameters are described below (the full set are listed in the In order to assign a particular peripheral to a serial port we use the concept of a _MAVLink instance_. Each MAVLink instance represents a particular MAVLink configuration that you can apply to a particular port. -At time of writing three MAVLink _instances_ are defined, each represented by a parameter [MAV_X_CONFIG](#MAV_X_CONFIG), where X is 0, 1, 2. +Most boards define three MAVLink instances, each represented by a parameter [MAV_X_CONFIG](#MAV_X_CONFIG), where X is 0, 1, 2. +A few boards define more, such as [Agam Autopilot v6X-RT](../flight_controller/agam_v6xrt.md), which has five (X is 0 to 4). + +::: info +The number of instances is set at build time by the [Kconfig](../hardware/porting_guide_config.md) symbol `CONFIG_MAVLINK_NUM_CONFIG_INSTANCES`. +At most 6 MAVLink instances can run at once (4 on constrained-memory boards), and USB uses one of them. +::: Each instance has associated parameters that you can use to define the properties of the instance on that port, such as the set of streamed messages (see [MAV_X_MODE](#MAV_X_MODE) below), data rate ([MAV_X_RATE](#MAV_X_RATE)), whether incoming traffic is forwarded to other MAVLink instances ([MAV_X_FORWARD](#MAV_X_FORWARD)), and so on. @@ -23,7 +29,7 @@ The number in the name means nothing; you can assign any instance to any port. The parameters for each instance are: -- [MAV_X_CONFIG](../advanced_config/parameter_reference.md#MAV_0_CONFIG) - Set the serial port (UART) for this instance "X", where X is 0, 1, 2. +- [MAV_X_CONFIG](../advanced_config/parameter_reference.md#MAV_0_CONFIG) - Set the serial port (UART) for this instance "X". It can be any unused port, e.g.: `TELEM2`, `TELEM3`, `GPS2` etc. For more information see [Serial Port Configuration](../peripherals/serial_configuration.md). - [MAV_X_MODE](../advanced_config/parameter_reference.md#MAV_0_MODE) - Specify the [MAVLink profile](../mavlink/mavlink_profiles.md) for the instance, such as _Normal_ or _OSD_. diff --git a/docs/en/releases/1.14.md b/docs/en/releases/1.14.md index ed77848d914..9545222cb3c 100644 --- a/docs/en/releases/1.14.md +++ b/docs/en/releases/1.14.md @@ -104,10 +104,10 @@ For more information see [Fast-RTPS to uXRCE-DDS Migration Guidelines](../middle ### Hardware Support -- Cubepilot Cube Orange+ - [PX4-Autopilot#20304](https://github.com/PX4/PX4-Autopilot/pull/20304) +- CubePilot Cube Orange+ - [PX4-Autopilot#20304](https://github.com/PX4/PX4-Autopilot/pull/20304) - Unicore GPS: Support for Holybro Unicore UM982 GPS - [PX4-Autopilot#21214](https://github.com/PX4/PX4-Autopilot/pull/21214)) - VOXL2 Improved support - [PX4-Autopilot#21426](https://github.com/PX4/PX4-Autopilot/pull/21426) -- Cubepilot Cube Black detection: Fixed Cube Black vs. Pixhawk 2 detection with CAN1 connected - [PX4-Autopilot#21342](https://github.com/PX4/PX4-Autopilot/pull/21342) +- CubePilot Cube Black detection: Fixed Cube Black vs. Pixhawk 2 detection with CAN1 connected - [PX4-Autopilot#21342](https://github.com/PX4/PX4-Autopilot/pull/21342) ### Common diff --git a/docs/en/releases/1.15.md b/docs/en/releases/1.15.md index 5306a7587e6..eb09766bab0 100644 --- a/docs/en/releases/1.15.md +++ b/docs/en/releases/1.15.md @@ -54,7 +54,7 @@ Please continue reading for [upgrade instructions](#upgrade-guide). - **[Feature]** Add power module selector for Auterion power modules ([PX4-Autopilot#22073](https://github.com/PX4/PX4-Autopilot/pull/22073)) - **[Lights]** Add LP5562 RGBLED driver ([PX4-Autopilot#21649](https://github.com/PX4/PX4-Autopilot/pull/21649)) - **[Holybro]** Enable EKF2 on KakuteH7 / KakuteH7v2 / KakuteH7mini ([PX4-Autopilot#21961](https://github.com/PX4/PX4-Autopilot/pull/21961)) -- **[Cubepilot]** Add support for 4. variant of Orange+ ([PX4-Autopilot#22039](https://github.com/PX4/PX4-Autopilot/pull/22039)) +- **[CubePilot]** Add support for 4. variant of Orange+ ([PX4-Autopilot#22039](https://github.com/PX4/PX4-Autopilot/pull/22039)) - **[3DR]** Control Zero Classic Support Improvements ([PX4-Autopilot#22971](https://github.com/PX4/PX4-Autopilot/pull/22971)) ### Common diff --git a/docs/en/releases/main.md b/docs/en/releases/main.md index 191ec322637..db65a6ed5f9 100644 --- a/docs/en/releases/main.md +++ b/docs/en/releases/main.md @@ -88,6 +88,15 @@ Please continue reading for [upgrade instructions](#upgrade-guide). In flight the primary receiver is now also left when it has failed the strict checks for 10 s while the other receiver passed them. ([PX4-Autopilot#28798](https://github.com/PX4/PX4-Autopilot/pull/28798)) - **Re-check the motor failure trigger thresholds.** `MOTFAIL_OFF` and `MOTFAIL_TIME` are replaced by a separate band and trigger time per direction ([MOTFAIL_OVER](../advanced_config/parameter_reference.md#MOTFAIL_OVER)/[MOTFAIL_OVR_TIME](../advanced_config/parameter_reference.md#MOTFAIL_OVR_TIME) and [MOTFAIL_UNDER](../advanced_config/parameter_reference.md#MOTFAIL_UNDER)/[MOTFAIL_UND_TIME](../advanced_config/parameter_reference.md#MOTFAIL_UND_TIME)), and are not migrated: the new parameters start at their defaults. The check now compares a low-pass filtered current residual instead of the instantaneous value, so the thresholds are worth re-deriving: see [Motor Failure Detection > Upgrading from PX4 v1.18](../config/motor_failure_detection.md#upgrading-from-px4-v1-18). ([PX4-Autopilot#27917](https://github.com/PX4/PX4-Autopilot/pull/27917)) +- **The failure detector attitude trigger checks the tilt error instead of roll and pitch separately.** + [FD_TILT_ERROR](../advanced_config/parameter_reference.md#FD_TILT_ERROR) replaces `FD_FAIL_R` and `FD_FAIL_P` and is the maximum angle between the vehicle tilt and the attitude setpoint tilt, in any direction. [FD_TILT_ERROR_T](../advanced_config/parameter_reference.md#FD_TILT_ERROR_T) replaces `FD_FAIL_R_TTRI` and `FD_FAIL_P_TTRI` and is the time it has to be exceeded (default now 1 s instead of 0.3 s). + The old values are not migrated because their meaning changed: the new parameters start at their defaults, except that a check disabled for both roll and pitch stays disabled. + Without a recent attitude setpoint, for example on rovers, the tilt from level is checked instead. + Vehicles may now fly at any tilt their attitude setpoint asks for, and a large tracking error triggers the check at any tilt. + The check is paused for the first 5 s after a VTOL switches to multicopter mode without back-transition, i.e. a quad-chute or an aborted front transition, while the vehicle recovers from fixed-wing flight. + Limits raised or disabled to allow large tilts, for example roll on fixed-wing vehicles, are no longer needed. + The check is disabled with `FD_TILT_ERROR` set to -1. + The `fd_roll` and `fd_pitch` fields of [FailureDetectorStatus](../msg_docs/FailureDetectorStatus.md) are replaced by `fd_tilt`. ## Other changes @@ -108,6 +117,7 @@ Please continue reading for [upgrade instructions](#upgrade-guide). ### Hardware Support +- [Accton Godwit G-FH7](../flight_controller/accton-godwit_gfh7.md): compact STM32H753 flight controller with dual IMUs (ICM-42688-P, LSM6DSK320X), a DPS368 barometer, an IST8310 magnetometer, 8 bidirectional DShot outputs, and an analog OSD. ([PX4-Autopilot#28817](https://github.com/PX4/PX4-Autopilot/pull/28817)) - [AIFoundry Erbium](../flight_controller/aifoundry_erbium.md): new experimental target for the AIFoundry Erbium RISC-V (ET-Minion) chip, which runs the SIH quadcopter on the `erbium_emu` emulator until silicon is available. ([PX4-Autopilot#29094](https://github.com/PX4/PX4-Autopilot/pull/29094)) - [DroneCAN ESCs](../dronecan/escs.md) no longer need to set `UAVCAN_PUB_ARM` as `ArmingStatus` is published automatically whenever `UAVCAN_ENABLE` is `3` (ESC output enabled). ([PX4-Autopilot#28364](https://github.com/PX4/PX4-Autopilot/pull/28364)) - [DroneCAN ESC](../dronecan/escs.md) channels assigned a non-motor function (e.g. _Peripheral via Actuator Set_) can be driven bidirectionally via `UAVCAN_EC_SIGNED` (signed RawCommand, 0 = neutral). Motors continue to use `CA_R_REV`. ([PX4-Autopilot#26903](https://github.com/PX4/PX4-Autopilot/pull/26903)) @@ -142,7 +152,7 @@ Please continue reading for [upgrade instructions](#upgrade-guide). - [Motor failure recovery](../config/motor_failure_recovery.md) for hexarotors: on a single motor failure the control allocator removes the failed motor and additionally stops ([CA_FAILURE_MODE](../advanced_config/parameter_reference.md#CA_FAILURE_MODE) = `1`) or reverses (`2`) the motor opposite it to recover the lost yaw authority. Mode `2` requires a reverse-capable ESC and models the reverse thrust of a forward propeller with the new [CA_REV_THR_FRAC](../advanced_config/parameter_reference.md#CA_REV_THR_FRAC) (default `0.4`). Reversible motor outputs on DroneCAN are now sent as signed `RawCommand` values (negative is reverse). ([PX4-Autopilot#28078](https://github.com/PX4/PX4-Autopilot/pull/28078)) - [Distance-aware return failsafe](../config/safety.md#distance-aware-return-failsafe) (also known as "bingo fuel"): engaging Return mode when the remaining flight time is only just enough to return is now part of [COM_LOW_BAT_ACT](../advanced_config/parameter_reference.md#COM_LOW_BAT_ACT) `3` and `4` (the new options `5` and `6` opt out), instead of with the separate `COM_FLTT_LOW_ACT`. See the [Upgrade Guide](#upgrade-guide). ([PX4-Autopilot#26955](https://github.com/PX4/PX4-Autopilot/pull/26955)) - Added `RTL_TYPE=6` for battery-aware home priority return ([PX4-Autopilot#26968](https://github.com/PX4/PX4-Autopilot/pull/26968)). - Returns to home if the estimated flight time to home is within the remaining battery time; otherwise returns to the closest rally point. + Returns to home if the estimated flight time to home is within the remaining battery time; otherwise returns to the closest rally point if it is closer than home. Falls back to the closest safe point (home or rally) if battery time remaining is unavailable. - [Secure boot](../advanced_config/bootloader_secure_boot.md#multi-part-signed-images) now supports applications that can boot securely from SD card or eMMC. ([PX4-Autopilot#28228](https://github.com/PX4/PX4-Autopilot/pull/28228)) - [Motor failure detection](../config/motor_failure_detection.md) now compares a low-pass filtered current residual against a separate trip band and trigger time for the undercurrent and overcurrent directions, instead of one symmetric band on the instantaneous current, and the current model gains an offset term. See [Upgrading from PX4 v1.18](../config/motor_failure_detection.md#upgrading-from-px4-v1-18). ([PX4-Autopilot#27711](https://github.com/PX4/PX4-Autopilot/pull/27711), [PX4-Autopilot#27917](https://github.com/PX4/PX4-Autopilot/pull/27917)) @@ -182,6 +192,7 @@ Please continue reading for [upgrade instructions](#upgrade-guide). - [SYS_STATUS](https://mavlink.io/en/messages/common.html#SYS_STATUS) now sets the [MAV_SYS_STATUS_EXTENSION_USED](https://mavlink.io/en/messages/common.html#MAV_SYS_STATUS_EXTENSION_USED) flag in `onboard_control_sensors_present` when extended sensor fields are used. - [TIME_ESTIMATE_TO_TARGET](https://mavlink.io/en/messages/common.html#TIME_ESTIMATE_TO_TARGET) reports `safe_return` as `-1` (landed or no estimate) when Return has no time estimate: before Home is set, on the ground unless Return would follow a mission landing, and with [RTL_TYPE](../advanced_config/parameter_reference.md#RTL_TYPE) = 2 or 4 and a valid mission. It used to send `0`, or an undefined value with `RTL_TYPE` 2 and 4. +- The number of [MAVLink instances](../peripherals/mavlink_peripherals.md#mavlink-instances) can now be set per board, and the [Agam Autopilot v6X-RT](../flight_controller/agam_v6xrt.md) has five (`MAV_0_CONFIG` to `MAV_4_CONFIG`). ([PX4-Autopilot#29573](https://github.com/PX4/PX4-Autopilot/pull/29573)) ### RC @@ -198,6 +209,7 @@ Please continue reading for [upgrade instructions](#upgrade-guide). - After a [quad-chute](../config/safety.md#quad-chute-failsafe), Mission and VTOL Takeoff mode no longer command forward transitions and continue in multicopter mode. Before, a resumed mission commanded the next transition again, which also cleared the quad-chute, and with [COM_QC_ACT](../advanced_config/parameter_reference.md#COM_QC_ACT) set to Warning a quad-chute during a mission transition left the mission waiting at that item. - A [quad-chute](../config/safety.md#quad-chute-failsafe) commanded with `MAV_CMD_DO_VTOL_TRANSITION` (`param2` = 1) now only switches to multicopter mode, as it is not caused by a failure. It no longer executes [COM_QC_ACT](../advanced_config/parameter_reference.md#COM_QC_ACT) or requires a reboot before the next arming. +- Standard VTOLs using pusher assist ([VT_FWD_THRUST_EN](../advanced_config/parameter_reference.md#VT_FWD_THRUST_EN)) now detect a pusher failure in multicopter mode, when the forward velocity stays well below its setpoint although the pusher assist throttle is above [VT_EF_THROT](../advanced_config/parameter_reference.md#VT_EF_THROT). A detected failure is handled as a [quad-chute](../config/safety.md#quad-chute-failsafe) that blocks front transitions until reboot. Setting [VT_EF_TIME](../advanced_config/parameter_reference.md#VT_EF_TIME) to 0 disables the detection and, in flight, allows front transitions again. ### Fixed-wing diff --git a/docs/en/sensor/barometer.md b/docs/en/sensor/barometer.md index 369c4d531ee..200a8a7bc6b 100644 --- a/docs/en/sensor/barometer.md +++ b/docs/en/sensor/barometer.md @@ -63,15 +63,22 @@ GNSS-baro calibration adjusts baro sensor offsets to align with absolute altitud This calibration is controlled by the [SENS_BAR_AUTOCAL](../advanced_config/parameter_reference.md#SENS_BAR_AUTOCAL) parameter (enabled by default). The algorithm monitors GNSS quality, collects altitude differences over a 2-second filtered window, and verifies stability within 4m tolerance. -Once stable, it uses binary search to calculate pressure offsets that align baro altitude with GNSS altitude (0.1m precision), then applies the offset to all sensors and saves the parameters. +Once stable, it uses binary search to calculate pressure offsets that align the baro altitude with the filtered GNSS altitude (0.1m precision), then applies the offset to all sensors and saves the parameters. + +While the vehicle stays on the ground and disarmed, the calibration keeps running: a baro drifting away from the GNSS altitude (for example from sensor warm-up or weather changes between boot and takeoff) is recalibrated once its offset, filtered over 5 seconds, exceeds 0.5 m. +This tracking stops on arming and resumes after landing and disarming. +It also stops until the next reboot once the altitude is set externally (`VEHICLE_CMD_EXTERNAL_POSITION_ESTIMATE`, for example the manual position reset of a ground station), as the GNSS altitude is then not trusted. Notes: -- **EKF Independence**: GNSS-baro calibration operates independently of EKF2 altitude fusion settings. -- **Execution Timing**: Calibration runs even when [EKF2_GPS_CTRL](../advanced_config/parameter_reference.md#EKF2_GPS_CTRL) altitude fusion is disabled. -- **One-Time Process**: Each calibration session completes once per system startup. +- **GNSS Height Fusion**: Calibration requires GNSS height fusion to be active ([EKF2_GPS_CTRL](../advanced_config/parameter_reference.md#EKF2_GPS_CTRL)). +- **Ground Only**: Calibration only runs while landed. + The first calibration after boot also completes while armed, so arming early does not leave the baro uncalibrated. + After that the baro is only recalibrated while disarmed. +- **Height Reset**: EKF2 resets its height to each new baro calibration when the baro is the height reference ([EKF2_HGT_REF](../advanced_config/parameter_reference.md#EKF2_HGT_REF)), so the estimated altitude follows the GNSS altitude until arming. - **Persistence**: Calibration offsets are saved to parameters and persist across reboots. -- **Faulty GNSS Vulnerability**: If GNSS data is faulty during boot, the calibration will use incorrect altitude reference. +- **Faulty GNSS Vulnerability**: The baro follows the GNSS altitude for as long as the vehicle is landed and disarmed. + A wrong GNSS altitude during boot is corrected once the GNSS altitude recovers, but a GNSS altitude that is still faulty at arming is the reference for the flight. See [Faulty GNSS Data During Boot](../advanced_config/tuning_the_ecl_ekf.md#faulty-gnss-data-during-boot) for mitigation strategies. ## See Also diff --git a/docs/en/sensor/microstrain.md b/docs/en/sensor/microstrain.md index c987130b04f..1fab8c497df 100644 --- a/docs/en/sensor/microstrain.md +++ b/docs/en/sensor/microstrain.md @@ -106,7 +106,7 @@ To use the MicroStrain driver: - [MS_OFLW_OFF_X](../advanced_config/parameter_reference.md#MS_OFLW_OFF_X) - [MS_OFLW_OFF_Y](../advanced_config/parameter_reference.md#MS_OFLW_OFF_Y) - [MS_OFLW_OFF_Z](../advanced_config/parameter_reference.md#MS_OFLW_OFF_Z) - - [SENS_FLOW_ROT](../advanced_config/parameter_reference.md#SENS_FLOW_ROT) + - [SENS_FLOW0_ROT](../advanced_config/parameter_reference.md#SENS_FLOW0_ROT) - The uncertainty for optical flow and external magnetometer aiding must be specified using the following parameters: - [MS_EMAG_UNCERT](../advanced_config/parameter_reference.md#MS_EMAG_UNCERT) diff --git a/docs/en/sensor/optical_flow.md b/docs/en/sensor/optical_flow.md index c49c07765f1..e069213bba5 100644 --- a/docs/en/sensor/optical_flow.md +++ b/docs/en/sensor/optical_flow.md @@ -19,6 +19,7 @@ An Optical Flow setup requires a downward facing camera and a downward facing [d These can be combined in a single product, such as the [ARK Flow](../dronecan/ark_flow.md), [ARK Flow MR](../dronecan/ark_flow_mr.md) and [Holybro H-Flow](https://holybro.com/products/h-flow), or they may be separate sensors. The sensor(s) can be connected via MAVLink, I2C or any other bus that supports the peripheral. +Up to two optical flow sensors can be used at the same time (see [Multiple Optical Flow Sensors](#multiple-flow-sensors)). ::: info If connected to PX4 via MAVLink the Optical Flow camera sensor must publish the [OPTICAL_FLOW_RAD](https://mavlink.io/en/messages/common.html#OPTICAL_FLOW_RAD) message, and the distance sensor must publish the [DISTANCE_SENSOR](https://mavlink.io/en/messages/common.html#DISTANCE_SENSOR) message. @@ -46,7 +47,7 @@ The approach used for fusing sensor data and any offsets from the center of the ### Scale Factor For pure rotations the `OPTICAL_FLOW_RAD.integrated_xgyro` and `OPTICAL_FLOW_RAD.integrated_x` (respectively `integrated_ygyro` and `integrated_y`) have to be the same. -If this is not the case, the optical flow scale factor can be adjusted using [SENS_FLOW_SCALE](../advanced_config/parameter_reference.md#SENS_FLOW_SCALE). +If this is not the case, the optical flow scale factor can be adjusted using [SENS_FLOW0_SCALE](../advanced_config/parameter_reference.md#SENS_FLOW0_SCALE). :::tip The low resolution of common optical flow sensors can cause slow oscillations when hovering at a high altitude above ground (> 20m). @@ -77,7 +78,7 @@ An all-in-one design that simplifies installation, with an onboard infrared LED ### PMW3901-Based Sensors [PMW3901](../sensor/pmw3901.md) is an optical flow tracking sensor similar to what you would find in a computer mouse, but adapted to work between 80 mm and infinity. -It is used in a number of products, including some from: Bitcraze, Tindie, Hex, Thone and Alientek. +It is used in a number of products, including some from: Bitcraze, Tindie, CubePilot, Thone and Alientek. ### Other Cameras/Sensors @@ -102,18 +103,51 @@ Optical Flow based navigation is enabled by both [EKF2](#ekf2) and LPE (deprecat ### Extended Kalman Filter (EKF2) {#ekf2} -For optical flow fusion using EKF2, set [EKF2_OF_CTRL](../advanced_config/parameter_reference.md#EKF2_OF_CTRL). +For optical flow fusion using EKF2, set [EKF2_OF0_CTRL](../advanced_config/parameter_reference.md#EKF2_OF0_CTRL). If your optical flow sensor is offset from the vehicle centre, you can set this using the following parameters. -| Parameter | Description | -| -------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------- | -| [EKF2_OF_POS_X](../advanced_config/parameter_reference.md#EKF2_OF_POS_X) | X position of optical flow focal point in body frame (default is 0.0m). | -| [EKF2_OF_POS_Y](../advanced_config/parameter_reference.md#EKF2_OF_POS_Y) | Y position of optical flow focal point in body frame (default is 0.0m). | -| [EKF2_OF_POS_Z](../advanced_config/parameter_reference.md#EKF2_OF_POS_Z) | Z position of optical flow focal point in body frame (default is 0.0m). | +| Parameter | Description | +| ----------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------- | +| [SENS_FLOW0_POS_X](../advanced_config/parameter_reference.md#SENS_FLOW0_POS_X) | X position of optical flow focal point in body frame (default is 0.0m). | +| [SENS_FLOW0_POS_Y](../advanced_config/parameter_reference.md#SENS_FLOW0_POS_Y) | Y position of optical flow focal point in body frame (default is 0.0m). | +| [SENS_FLOW0_POS_Z](../advanced_config/parameter_reference.md#SENS_FLOW0_POS_Z) | Z position of optical flow focal point in body frame (default is 0.0m). | See [Using PX4's Navigation Filter (EKF2) > Optical flow](../advanced_config/tuning_the_ecl_ekf.md#optical-flow) for more information. +## Multiple Optical Flow Sensors {#multiple-flow-sensors} + + + +PX4 supports up to two optical flow sensors at the same time. +A second sensor can add redundancy, or extend the usable envelope by combining sensors with different operating ranges. +Both sensors are fused, each at its own measurement rate. +A sensor that temporarily cannot be fused (for example when it leaves its operating range) keeps being processed for monitoring, and its data is used again as soon as it recovers. +A sensor whose measurements are rejected while the other sensor is still fused is considered faulty: it never resets the velocity or height above ground estimate, it is stopped and retried later. + +Each sensor is bound to a parameter "slot" `n` (`0` or `1`) using its device ID: + +- [SENS_FLOW0_ID](../advanced_config/parameter_reference.md#SENS_FLOW0_ID) and [SENS_FLOW1_ID](../advanced_config/parameter_reference.md#SENS_FLOW1_ID) record the device ID of the sensor bound to the `SENS_FLOWn_*` parameters. + While an ID parameter is `0` (default), the first unbound sensor that delivers data is bound to it, and the assignment is saved so that it remains stable across reboots. + The EKF uses the same slot numbering: `EKF2_OFn_*` parameters apply to the sensor bound to `SENS_FLOWn_ID`. +- Fusion is enabled per slot using [EKF2_OF0_CTRL](../advanced_config/parameter_reference.md#EKF2_OF0_CTRL) and [EKF2_OF1_CTRL](../advanced_config/parameter_reference.md#EKF2_OF1_CTRL). + Only slot 0 is enabled by default. + A slot can be enabled or disabled at runtime. +- When a sensor is replaced, the new sensor has a different device ID and is bound to the next free slot, which is not fused by default. + To bind the new sensor to the old slot, set its `SENS_FLOWn_ID` parameter to `0` and reboot. +- All other optical flow parameters exist once per sensor: sensor properties such as delay, rotation, and mounting position in `SENS_FLOW0_*`/`SENS_FLOW1_*`, and fusion tuning such as noise and quality thresholds in `EKF2_OF0_*`/`EKF2_OF1_*`, so each sensor can be configured independently. + +Note the following requirements and behaviour: + +- All flow sensors must be mounted facing downwards. + The sensors do not need to have the same yaw orientation (set individually using `SENS_FLOWn_ROT`), and each sensor has its own position offset (`SENS_FLOWn_POS_X` and so on). +- Flow sensors are not paired with specific [distance sensors](../sensor/rangefinders.md). + The EKF estimates a single height above ground that is used for all flow sensors, corrected for each sensor's position offset. + The minimum and maximum operating distance reported by each sensor is applied individually. +- A distance measurement provided by a flow sensor itself (as on the [ARK Flow](../dronecan/ark_flow.md)) can substitute for a missing distance sensor. + Only the measurement from the first sensor that reports a distance is used for this purpose. +- The preflight check enabled by [SYS_HAS_NUM_OF](../advanced_config/parameter_reference.md#SYS_HAS_NUM_OF) passes when at least one sensor delivers valid data. + ## Simulation Optical flow can be simulated with [SIH](../sim_sih/index.md), which computes the flow from the simulated vehicle motion instead of rendering a camera image. diff --git a/docs/en/sensor/pmw3901.md b/docs/en/sensor/pmw3901.md index 076fa66e4f5..40a2fb3f2da 100644 --- a/docs/en/sensor/pmw3901.md +++ b/docs/en/sensor/pmw3901.md @@ -2,7 +2,7 @@ PMW3901 is an [optical flow](../sensor/optical_flow.md) ASIC that computes the flow internally and provides a difference in pixels between each frame. It uses a tracking sensor that is similar to what you would find in a computer mouse, but adapted to work between 80 mm and infinity. -The PMW3901 is used in several products, including some from Bitcraze, Tindie, Hex, Thone, and Alientek +The PMW3901 is used in several products, including some from Bitcraze, Tindie, CubePilot, Thone, and Alientek ![Bitcraze Flow Deck](../../assets/hardware/sensors/pmw3901/bitcraze-flow.jpg) @@ -13,14 +13,14 @@ This topic provides links to sensors that have been tested, along with informati The following table shows some of the boards that use this sensor, listing the number of interfaces, the number of sensors, the input voltage, and the size. The board name links to board-specific sections that include wiring and purchase information. -| Manufacture | Board | Interface | Flow | Range Finder | Gyro | Voltage (V) | Size (mm) | Max Height (m) | -| ----------- | --------------------------------------------------------------------------------- | --------- | ---- | ------------ | ---- | ----------- | --------- | -------------- | -| Bitcraze | [Flow breakout](#bitcraze-flow-breakout) | SPI | Y | Y | - | 3 - 5 | 21x20 | 1 | -| Tindie | [PMW3901 Optical Flow Sensor](#tindie-pmw3901-optical-flow-sensor) | SPI | Y | - | - | 3 - 5 | AxB | - | -| Hex | [HereFlow PMW3901 Optical Flow Sensor](#hex-hereflow-pmw3901-optical-flow-sensor) | CAN | Y | Y | Y | 3 - 5 | AxB | 4 | -| Holybro | [Holybro PMW3901 Optical Flow Sensor](#holybro-pmw3901-optical-flow-sensor) | UART | Y | - | - | 3 - 5 | AxB | - | -| Thone | [ThoneFlow-3901U](#thone-thoneflow-3901u) | UART | Y | - | - | 3 - 5 | AxB | - | -| Alientek | [ATK-PMW3901](#alientek-atk-pmw3901) | SPI | Y | - | - | 3.3 - 4.2 | 27.5x16.5 | 1 | +| Manufacture | Board | Interface | Flow | Range Finder | Gyro | Voltage (V) | Size (mm) | Max Height (m) | +| ----------- | --------------------------------------------------------------------------------------- | --------- | ---- | ------------ | ---- | ----------- | --------- | -------------- | +| Bitcraze | [Flow breakout](#bitcraze-flow-breakout) | SPI | Y | Y | - | 3 - 5 | 21x20 | 1 | +| Tindie | [PMW3901 Optical Flow Sensor](#tindie-pmw3901-optical-flow-sensor) | SPI | Y | - | - | 3 - 5 | AxB | - | +| CubePilot | [HereFlow PMW3901 Optical Flow Sensor](#cubepilot-hereflow-pmw3901-optical-flow-sensor) | CAN | Y | Y | Y | 3 - 5 | AxB | 4 | +| Holybro | [Holybro PMW3901 Optical Flow Sensor](#holybro-pmw3901-optical-flow-sensor) | UART | Y | - | - | 3 - 5 | AxB | - | +| Thone | [ThoneFlow-3901U](#thone-thoneflow-3901u) | UART | Y | - | - | 3 - 5 | AxB | - | +| Alientek | [ATK-PMW3901](#alientek-atk-pmw3901) | SPI | Y | - | - | 3.3 - 4.2 | 27.5x16.5 | 1 | ## External Rangefinders @@ -43,12 +43,12 @@ The PX4 team mainly tested using the [Lidar Lite V3](../sensor/lidar_lite.md) on Flow modules are typically mounted near the centre of the vehicle. If mounted off-centre you will need to set offsets: [Optical Flow > EKF2](../sensor/optical_flow.md#ekf2). -The flow modules may be mounted with any yaw orientation relative to the vehicle body frame, but you must set the value used in [SENS_FLOW_ROT](../advanced_config/parameter_reference.md#SENS_FLOW_ROT). +The flow modules may be mounted with any yaw orientation relative to the vehicle body frame, but you must set the value used in [SENS_FLOW0_ROT](../advanced_config/parameter_reference.md#SENS_FLOW0_ROT). The "zero" rotation is when the sensor board and [vehicle](../getting_started/px4_basic_concepts.md#heading-and-directions) X-axes are aligned (i.e. the "front" of the vehicle and the board are in the same direction), with rotations increasing in a clockwise direction. PMW3901 modules have a small notch indicating the direction of the **back** of the board. -The diagram shows the relative board and vehicle orientations that correspond to `SENS_FLOW_ROT=0` (note the notch at the back). +The diagram shows the relative board and vehicle orientations that correspond to `SENS_FLOW0_ROT=0` (note the notch at the back). ![PMW3901 PH4 Rotation](../../assets/hardware/sensors/pmw3901/ph4-pmw3901-rotation.png) @@ -57,7 +57,7 @@ You can use the notch to find the orientation of the other boards in the same wa |   |   | | ---------------------------------------------------- | ----------------------------------------------------------------------------------------------- | -| Tindie
![PMW3901 Tindie Notch][tindie_notch] | Hex Hereflow
![PMW3901 Hereflow Notch][hereflow_notch] | +| Tindie
![PMW3901 Tindie Notch][tindie_notch] | CubePilot Hereflow
![PMW3901 Hereflow Notch][hereflow_notch] | | Thone
![PMW3901 Thoneflow Notch][thoneflow_notch] | Alientek (also has an arrow indicating the front!)
![PMW3901 Alientek Notch][alientek_notch] | [tindie_notch]: ../../assets/hardware/sensors/pmw3901/tindie_notch.jpg @@ -70,7 +70,7 @@ You can use the notch to find the orientation of the other boards in the same wa The PX4 configuration that is common to all PMW3901-based boards: - [Optical Flow > EKF2](../sensor/optical_flow.md#ekf2) explains how to fuse optical flow data in the EKF2 estimator and set position offsets for the mounting position of the flow sensor. -- [SENS_FLOW_ROT](../advanced_config/parameter_reference.md#SENS_FLOW_ROT) sets the orientation of the flow sensor relative to vehicle heading. +- [SENS_FLOW0_ROT](../advanced_config/parameter_reference.md#SENS_FLOW0_ROT) sets the orientation of the flow sensor relative to vehicle heading. In addition for: @@ -148,9 +148,9 @@ A screenshot showing the I2C pins (SLA, SLC, GND, and VCC) is provided below. [PX4 configuration](#px4-configuration) and [mounting/orientation](#mounting-orientation) instructions are provided above. -## Hex HereFlow PMW3901 Optical Flow Sensor +## CubePilot HereFlow PMW3901 Optical Flow Sensor -The Hex [HereFlow PMW3901 Optical Flow Sensor](https://docs.cubepilot.org/flow-senor/here-flow) is a tiny board containing the PMW3901 flow module, VL53L1X distance sensor, and an IMU (used to synchronize the flow data with the gyro data). +The CubePilot [HereFlow PMW3901 Optical Flow Sensor](https://docs.cubepilot.org/flow-senor/here-flow) is a tiny board containing the PMW3901 flow module, VL53L1X distance sensor, and an IMU (used to synchronize the flow data with the gyro data). An onboard microcontroller samples the three sensors and publishes two DroneCAN messages containing all the information needed for the flow and distance sensor calculations. @@ -164,7 +164,7 @@ As for the other optical flow boards, we recommend that you use an [external dis The diagram below shows how to connect the sensor to the Pixhawk 4 CAN bus. -![Hex PH4 Pinout](../../assets/hardware/sensors/pmw3901/ph4-hex-optical-flow.png) +![CubePilot PH4 Pinout](../../assets/hardware/sensors/pmw3901/ph4-hex-optical-flow.png) In addition to any other configuration, you will need to set the parameter [UAVCAN_ENABLE](../advanced_config/parameter_reference.md#UAVCAN_ENABLE) to either 2 or 3, depending on your system: diff --git a/docs/en/sim_sih/index.md b/docs/en/sim_sih/index.md index 5bd45febfda..23fe48cb5a7 100644 --- a/docs/en/sim_sih/index.md +++ b/docs/en/sim_sih/index.md @@ -39,6 +39,7 @@ The following vehicle types are supported: | Tailsitter VTOL | `make px4_sitl_sih sihsim_xvert` | Experimental | | Standard VTOL (QuadPlane) | `make px4_sitl_sih sihsim_standard_vtol` | Experimental | | Ackermann Rover | `make px4_sitl_sih sihsim_rover_ackermann` | Experimental | +| Differential Rover | `make px4_sitl_sih sihsim_rover_differential` | Experimental | | Quadrotor X with optical flow | `make px4_sitl_sih sihsim_quadx_flow` | Experimental | | Standard VTOL with optical flow | `make px4_sitl_sih sihsim_standard_vtol_flow` | Experimental | @@ -184,7 +185,7 @@ The terrain is then used for: - The `dist_bottom` field of the `vehicle_local_position_groundtruth` topic. Outside the area covered by the DEM, or over cells without data, the ground is flat at `SIH_LOC_H0` and a warning is printed. -Terrain is supported for multicopters, VTOLs and fixed-wing vehicles; with any other vehicle type (such as Ackermann rovers), setting `PX4_SIH_TERRAIN` stops SIH from starting with an error. +Terrain is supported for multicopters, VTOLs and fixed-wing vehicles; with any other vehicle type (such as rovers), setting `PX4_SIH_TERRAIN` stops SIH from starting with an error. `simulator_sih status` shows the loaded DEM and whether the vehicle is inside it. The DEM must be a single-band GeoTIFF whose coordinate reference system has an [EPSG code](https://epsg.io/), either geographic (such as WGS84, `EPSG:4326`) or projected (such as UTM or the Swiss `EPSG:2056`). @@ -298,7 +299,7 @@ See [SIH on Flight Controller Hardware](hardware.md) for setup instructions. You still need to configure your vehicle type and [geometry](../config/actuators.md) (`CA_` parameters) and start any other defaults for that specific vehicle. ::: warning -Not every vehicle can be simulated with SIH — there are currently [six supported vehicle types](../advanced_config/parameter_reference.md#SIH_VEHICLE_TYPE) (quadcopter, fixed-wing, tailsitter, standard VTOL, hexacopter, rover), each of which has a relatively rigid implementation in [`sih.cpp`](https://github.com/PX4/PX4-Autopilot/blob/main/src/modules/simulation/simulator_sih/sih.cpp). +Not every vehicle can be simulated with SIH — there are currently [seven supported vehicle types](../advanced_config/parameter_reference.md#SIH_VEHICLE_TYPE) (quadcopter, fixed-wing, tailsitter, standard VTOL, hexacopter, Ackermann rover, differential rover), each of which has a relatively rigid implementation in [`sih.cpp`](https://github.com/PX4/PX4-Autopilot/blob/main/src/modules/simulation/simulator_sih/sih.cpp). ::: The specific differences for SIH simulation airframes are listed in the sections below. @@ -350,7 +351,8 @@ The dynamic models for the various vehicles are: - Quadrotor: [pdf](https://github.com/PX4/PX4-Autopilot/raw/main/docs/assets/simulation/SIH_dynamic_model.pdf) - Fixed-wing: based on Khan (2016), see references below - Tailsitter: based on Chiappinelli (2018), see references below -- Rover: bicycle model with linear tire model +- Ackermann rover: bicycle model with linear tire model +- Differential rover: unicycle model, each wheel is driven towards its commanded speed up to the traction limit and the wheels do not slip sideways **Propeller model with advance ratio** diff --git a/docs/en/test_and_ci/docker.md b/docs/en/test_and_ci/docker.md index 82308fe62f0..c8942eef73f 100644 --- a/docs/en/test_and_ci/docker.md +++ b/docs/en/test_and_ci/docker.md @@ -256,7 +256,7 @@ The bug is not reproducible, so it is likely a hardware or OS problem. c++: internal compiler error: Killed (program cc1plus) ``` -Try disabling parallel builds. +Try disabling parallel builds, e.g. `make px4_fmu-v5x_default -j1`. **Allow Docker Control from the VM Host** diff --git a/docs/en/test_cards/mc_06_optical_flow.md b/docs/en/test_cards/mc_06_optical_flow.md index 22877115e6c..719752d3ee6 100644 --- a/docs/en/test_cards/mc_06_optical_flow.md +++ b/docs/en/test_cards/mc_06_optical_flow.md @@ -10,7 +10,7 @@ Disconnect all GPS / compasses and ensure vehicle is using optical flow for navi Ensure there are no other sources of positioning besides optical flow: -- [EKF2_OF_CTRL](../advanced_config/parameter_reference.md#EKF2_OF_CTRL): `1` +- [EKF2_OF0_CTRL](../advanced_config/parameter_reference.md#EKF2_OF0_CTRL): `1` - [EKF2_GPS_CTRL](../advanced_config/parameter_reference.md#EKF2_GPS_CTRL): `0` - [EKF2_EV_CTRL](../advanced_config/parameter_reference.md#EKF2_EV_CTRL): `0` diff --git a/docs/en/test_cards/mc_07_optical_flow_low_mount.md b/docs/en/test_cards/mc_07_optical_flow_low_mount.md index 73c06f4e4a2..888cfe6b182 100644 --- a/docs/en/test_cards/mc_07_optical_flow_low_mount.md +++ b/docs/en/test_cards/mc_07_optical_flow_low_mount.md @@ -15,7 +15,7 @@ Disconnect all GPS / compasses and ensure vehicle is using optical flow for navi Ensure there are no other sources of positioning besides optical flow -- [EKF2_OF_CTRL](../advanced_config/parameter_reference.md#EKF2_OF_CTRL): `1` +- [EKF2_OF0_CTRL](../advanced_config/parameter_reference.md#EKF2_OF0_CTRL): `1` - [EKF2_GPS_CTRL](../advanced_config/parameter_reference.md#EKF2_GPS_CTRL): `0` - [EKF2_EV_CTRL](../advanced_config/parameter_reference.md#EKF2_EV_CTRL): `0` diff --git a/docs/en/test_cards/mc_09_vio.md b/docs/en/test_cards/mc_09_vio.md index 994fa9e4cf6..ac9f7eab1c5 100644 --- a/docs/en/test_cards/mc_09_vio.md +++ b/docs/en/test_cards/mc_09_vio.md @@ -12,7 +12,7 @@ Ensure that the drone can go into [Altitude](../flight_modes_mc/altitude.md) / [ Ensure there are no other sources of positioning besides VIO: -- [EKF2_OF_CTRL](../advanced_config/parameter_reference.md#EKF2_OF_CTRL): `0` +- [EKF2_OF0_CTRL](../advanced_config/parameter_reference.md#EKF2_OF0_CTRL): `0` - [EKF2_GPS_CTRL](../advanced_config/parameter_reference.md#EKF2_GPS_CTRL): `0` - [EKF2_EV_CTRL](../advanced_config/parameter_reference.md#EKF2_EV_CTRL): `15` - [SYS_HAS_MAG](../advanced_config/parameter_reference.md#SYS_HAS_MAG): `0` diff --git a/docs/en/test_cards/mc_10_optical_flow_gps_mixed.md b/docs/en/test_cards/mc_10_optical_flow_gps_mixed.md index 7cb13a1308c..48f51e3e305 100644 --- a/docs/en/test_cards/mc_10_optical_flow_gps_mixed.md +++ b/docs/en/test_cards/mc_10_optical_flow_gps_mixed.md @@ -10,7 +10,7 @@ Test that optical flow mixed with GPS works as expected Ensure there are no other sources of positioning besides optical flow -- [EKF2_OF_CTRL](../advanced_config/parameter_reference.md#EKF2_OF_CTRL): `1` +- [EKF2_OF0_CTRL](../advanced_config/parameter_reference.md#EKF2_OF0_CTRL): `1` - [EKF2_GPS_CTRL](../advanced_config/parameter_reference.md#EKF2_GPS_CTRL): `7` - [EKF2_EV_CTRL](../advanced_config/parameter_reference.md#EKF2_EV_CTRL): `0` - [SYS_HAS_MAG](../advanced_config/parameter_reference.md#SYS_HAS_MAG): `1` diff --git a/docs/public/config/failsafe/index.js b/docs/public/config/failsafe/index.js index 4fd7227b422..d7dde8762f1 100644 --- a/docs/public/config/failsafe/index.js +++ b/docs/public/config/failsafe/index.js @@ -1 +1 @@ -var Module=typeof Module!="undefined"?Module:{};var ENVIRONMENT_IS_WEB=typeof window=="object";var ENVIRONMENT_IS_WORKER=typeof importScripts=="function";var ENVIRONMENT_IS_NODE=typeof process=="object"&&typeof process.versions=="object"&&typeof process.versions.node=="string";if(ENVIRONMENT_IS_NODE){}var moduleOverrides=Object.assign({},Module);var arguments_=[];var thisProgram="./this.program";var quit_=(status,toThrow)=>{throw toThrow};var scriptDirectory="";function locateFile(path){if(Module["locateFile"]){return Module["locateFile"](path,scriptDirectory)}return scriptDirectory+path}var readAsync,readBinary;if(ENVIRONMENT_IS_NODE){var fs=require("fs");var nodePath=require("path");scriptDirectory=__dirname+"/";readBinary=filename=>{filename=isFileURI(filename)?new URL(filename):nodePath.normalize(filename);var ret=fs.readFileSync(filename);return ret};readAsync=(filename,binary=true)=>{filename=isFileURI(filename)?new URL(filename):nodePath.normalize(filename);return new Promise((resolve,reject)=>{fs.readFile(filename,binary?undefined:"utf8",(err,data)=>{if(err)reject(err);else resolve(binary?data.buffer:data)})})};if(!Module["thisProgram"]&&process.argv.length>1){thisProgram=process.argv[1].replace(/\\/g,"/")}arguments_=process.argv.slice(2);if(typeof module!="undefined"){module["exports"]=Module}process.on("uncaughtException",ex=>{if(ex!=="unwind"&&!(ex instanceof ExitStatus)&&!(ex.context instanceof ExitStatus)){throw ex}});quit_=(status,toThrow)=>{process.exitCode=status;throw toThrow}}else if(ENVIRONMENT_IS_WEB||ENVIRONMENT_IS_WORKER){if(ENVIRONMENT_IS_WORKER){scriptDirectory=self.location.href}else if(typeof document!="undefined"&&document.currentScript){scriptDirectory=document.currentScript.src}if(scriptDirectory.startsWith("blob:")){scriptDirectory=""}else{scriptDirectory=scriptDirectory.substr(0,scriptDirectory.replace(/[?#].*/,"").lastIndexOf("/")+1)}{if(ENVIRONMENT_IS_WORKER){readBinary=url=>{var xhr=new XMLHttpRequest;xhr.open("GET",url,false);xhr.responseType="arraybuffer";xhr.send(null);return new Uint8Array(xhr.response)}}readAsync=url=>{if(isFileURI(url)){return new Promise((reject,resolve)=>{var xhr=new XMLHttpRequest;xhr.open("GET",url,true);xhr.responseType="arraybuffer";xhr.onload=()=>{if(xhr.status==200||xhr.status==0&&xhr.response){resolve(xhr.response)}reject(xhr.status)};xhr.onerror=reject;xhr.send(null)})}return fetch(url,{credentials:"same-origin"}).then(response=>{if(response.ok){return response.arrayBuffer()}return Promise.reject(new Error(response.status+" : "+response.url))})}}}else{}var out=Module["print"]||console.log.bind(console);var err=Module["printErr"]||console.error.bind(console);Object.assign(Module,moduleOverrides);moduleOverrides=null;if(Module["arguments"])arguments_=Module["arguments"];if(Module["thisProgram"])thisProgram=Module["thisProgram"];if(Module["quit"])quit_=Module["quit"];var wasmBinary;if(Module["wasmBinary"])wasmBinary=Module["wasmBinary"];var wasmMemory;var ABORT=false;var EXITSTATUS;var HEAP8,HEAPU8,HEAP16,HEAPU16,HEAP32,HEAPU32,HEAPF32,HEAPF64;function updateMemoryViews(){var b=wasmMemory.buffer;Module["HEAP8"]=HEAP8=new Int8Array(b);Module["HEAP16"]=HEAP16=new Int16Array(b);Module["HEAPU8"]=HEAPU8=new Uint8Array(b);Module["HEAPU16"]=HEAPU16=new Uint16Array(b);Module["HEAP32"]=HEAP32=new Int32Array(b);Module["HEAPU32"]=HEAPU32=new Uint32Array(b);Module["HEAPF32"]=HEAPF32=new Float32Array(b);Module["HEAPF64"]=HEAPF64=new Float64Array(b)}var __ATPRERUN__=[];var __ATINIT__=[];var __ATPOSTRUN__=[];var runtimeInitialized=false;function preRun(){if(Module["preRun"]){if(typeof Module["preRun"]=="function")Module["preRun"]=[Module["preRun"]];while(Module["preRun"].length){addOnPreRun(Module["preRun"].shift())}}callRuntimeCallbacks(__ATPRERUN__)}function initRuntime(){runtimeInitialized=true;callRuntimeCallbacks(__ATINIT__)}function postRun(){if(Module["postRun"]){if(typeof Module["postRun"]=="function")Module["postRun"]=[Module["postRun"]];while(Module["postRun"].length){addOnPostRun(Module["postRun"].shift())}}callRuntimeCallbacks(__ATPOSTRUN__)}function addOnPreRun(cb){__ATPRERUN__.unshift(cb)}function addOnInit(cb){__ATINIT__.unshift(cb)}function addOnPostRun(cb){__ATPOSTRUN__.unshift(cb)}var runDependencies=0;var runDependencyWatcher=null;var dependenciesFulfilled=null;function addRunDependency(id){runDependencies++;Module["monitorRunDependencies"]?.(runDependencies)}function removeRunDependency(id){runDependencies--;Module["monitorRunDependencies"]?.(runDependencies);if(runDependencies==0){if(runDependencyWatcher!==null){clearInterval(runDependencyWatcher);runDependencyWatcher=null}if(dependenciesFulfilled){var callback=dependenciesFulfilled;dependenciesFulfilled=null;callback()}}}function abort(what){Module["onAbort"]?.(what);what="Aborted("+what+")";err(what);ABORT=true;EXITSTATUS=1;what+=". Build with -sASSERTIONS for more info.";var e=new WebAssembly.RuntimeError(what);throw e}var dataURIPrefix="data:application/octet-stream;base64,";var isDataURI=filename=>filename.startsWith(dataURIPrefix);var isFileURI=filename=>filename.startsWith("file://");function findWasmBinary(){var f="index.wasm";if(!isDataURI(f)){return locateFile(f)}return f}var wasmBinaryFile;function getBinarySync(file){if(file==wasmBinaryFile&&wasmBinary){return new Uint8Array(wasmBinary)}if(readBinary){return readBinary(file)}throw"both async and sync fetching of the wasm failed"}function getBinaryPromise(binaryFile){if(!wasmBinary){return readAsync(binaryFile).then(response=>new Uint8Array(response),()=>getBinarySync(binaryFile))}return Promise.resolve().then(()=>getBinarySync(binaryFile))}function instantiateArrayBuffer(binaryFile,imports,receiver){return getBinaryPromise(binaryFile).then(binary=>WebAssembly.instantiate(binary,imports)).then(receiver,reason=>{err(`failed to asynchronously prepare wasm: ${reason}`);abort(reason)})}function instantiateAsync(binary,binaryFile,imports,callback){if(!binary&&typeof WebAssembly.instantiateStreaming=="function"&&!isDataURI(binaryFile)&&!isFileURI(binaryFile)&&!ENVIRONMENT_IS_NODE&&typeof fetch=="function"){return fetch(binaryFile,{credentials:"same-origin"}).then(response=>{var result=WebAssembly.instantiateStreaming(response,imports);return result.then(callback,function(reason){err(`wasm streaming compile failed: ${reason}`);err("falling back to ArrayBuffer instantiation");return instantiateArrayBuffer(binaryFile,imports,callback)})})}return instantiateArrayBuffer(binaryFile,imports,callback)}function getWasmImports(){return{a:wasmImports}}function createWasm(){var info=getWasmImports();function receiveInstance(instance,module){wasmExports=instance.exports;wasmMemory=wasmExports["w"];updateMemoryViews();wasmTable=wasmExports["D"];addOnInit(wasmExports["x"]);removeRunDependency("wasm-instantiate");return wasmExports}addRunDependency("wasm-instantiate");function receiveInstantiationResult(result){receiveInstance(result["instance"])}if(Module["instantiateWasm"]){try{return Module["instantiateWasm"](info,receiveInstance)}catch(e){err(`Module.instantiateWasm callback failed with error: ${e}`);return false}}if(!wasmBinaryFile)wasmBinaryFile=findWasmBinary();instantiateAsync(wasmBinary,wasmBinaryFile,info,receiveInstantiationResult);return{}}function ExitStatus(status){this.name="ExitStatus";this.message=`Program terminated with exit(${status})`;this.status=status}var callRuntimeCallbacks=callbacks=>{while(callbacks.length>0){callbacks.shift()(Module)}};var noExitRuntime=Module["noExitRuntime"]||true;class ExceptionInfo{constructor(excPtr){this.excPtr=excPtr;this.ptr=excPtr-24}set_type(type){HEAPU32[this.ptr+4>>2]=type}get_type(){return HEAPU32[this.ptr+4>>2]}set_destructor(destructor){HEAPU32[this.ptr+8>>2]=destructor}get_destructor(){return HEAPU32[this.ptr+8>>2]}set_caught(caught){caught=caught?1:0;HEAP8[this.ptr+12]=caught}get_caught(){return HEAP8[this.ptr+12]!=0}set_rethrown(rethrown){rethrown=rethrown?1:0;HEAP8[this.ptr+13]=rethrown}get_rethrown(){return HEAP8[this.ptr+13]!=0}init(type,destructor){this.set_adjusted_ptr(0);this.set_type(type);this.set_destructor(destructor)}set_adjusted_ptr(adjustedPtr){HEAPU32[this.ptr+16>>2]=adjustedPtr}get_adjusted_ptr(){return HEAPU32[this.ptr+16>>2]}get_exception_ptr(){var isPointer=___cxa_is_pointer_type(this.get_type());if(isPointer){return HEAPU32[this.excPtr>>2]}var adjusted=this.get_adjusted_ptr();if(adjusted!==0)return adjusted;return this.excPtr}}var exceptionLast=0;var uncaughtExceptionCount=0;var ___cxa_throw=(ptr,type,destructor)=>{var info=new ExceptionInfo(ptr);info.init(type,destructor);exceptionLast=ptr;uncaughtExceptionCount++;throw exceptionLast};var __abort_js=()=>{abort("")};var __embind_register_bigint=(primitiveType,name,size,minRange,maxRange)=>{};var embind_init_charCodes=()=>{var codes=new Array(256);for(var i=0;i<256;++i){codes[i]=String.fromCharCode(i)}embind_charCodes=codes};var embind_charCodes;var readLatin1String=ptr=>{var ret="";var c=ptr;while(HEAPU8[c]){ret+=embind_charCodes[HEAPU8[c++]]}return ret};var awaitingDependencies={};var registeredTypes={};var typeDependencies={};var BindingError;var throwBindingError=message=>{throw new BindingError(message)};var InternalError;var throwInternalError=message=>{throw new InternalError(message)};var whenDependentTypesAreResolved=(myTypes,dependentTypes,getTypeConverters)=>{myTypes.forEach(function(type){typeDependencies[type]=dependentTypes});function onComplete(typeConverters){var myTypeConverters=getTypeConverters(typeConverters);if(myTypeConverters.length!==myTypes.length){throwInternalError("Mismatched type converter count")}for(var i=0;i{if(registeredTypes.hasOwnProperty(dt)){typeConverters[i]=registeredTypes[dt]}else{unregisteredTypes.push(dt);if(!awaitingDependencies.hasOwnProperty(dt)){awaitingDependencies[dt]=[]}awaitingDependencies[dt].push(()=>{typeConverters[i]=registeredTypes[dt];++registered;if(registered===unregisteredTypes.length){onComplete(typeConverters)}})}});if(0===unregisteredTypes.length){onComplete(typeConverters)}};function sharedRegisterType(rawType,registeredInstance,options={}){var name=registeredInstance.name;if(!rawType){throwBindingError(`type "${name}" must have a positive integer typeid pointer`)}if(registeredTypes.hasOwnProperty(rawType)){if(options.ignoreDuplicateRegistrations){return}else{throwBindingError(`Cannot register type '${name}' twice`)}}registeredTypes[rawType]=registeredInstance;delete typeDependencies[rawType];if(awaitingDependencies.hasOwnProperty(rawType)){var callbacks=awaitingDependencies[rawType];delete awaitingDependencies[rawType];callbacks.forEach(cb=>cb())}}function registerType(rawType,registeredInstance,options={}){if(!("argPackAdvance"in registeredInstance)){throw new TypeError("registerType registeredInstance requires argPackAdvance")}return sharedRegisterType(rawType,registeredInstance,options)}var GenericWireTypeSize=8;var __embind_register_bool=(rawType,name,trueValue,falseValue)=>{name=readLatin1String(name);registerType(rawType,{name:name,fromWireType:function(wt){return!!wt},toWireType:function(destructors,o){return o?trueValue:falseValue},argPackAdvance:GenericWireTypeSize,readValueFromPointer:function(pointer){return this["fromWireType"](HEAPU8[pointer])},destructorFunction:null})};var shallowCopyInternalPointer=o=>({count:o.count,deleteScheduled:o.deleteScheduled,preservePointerOnDelete:o.preservePointerOnDelete,ptr:o.ptr,ptrType:o.ptrType,smartPtr:o.smartPtr,smartPtrType:o.smartPtrType});var throwInstanceAlreadyDeleted=obj=>{function getInstanceTypeName(handle){return handle.$$.ptrType.registeredClass.name}throwBindingError(getInstanceTypeName(obj)+" instance already deleted")};var finalizationRegistry=false;var detachFinalizer=handle=>{};var runDestructor=$$=>{if($$.smartPtr){$$.smartPtrType.rawDestructor($$.smartPtr)}else{$$.ptrType.registeredClass.rawDestructor($$.ptr)}};var releaseClassHandle=$$=>{$$.count.value-=1;var toDelete=0===$$.count.value;if(toDelete){runDestructor($$)}};var downcastPointer=(ptr,ptrClass,desiredClass)=>{if(ptrClass===desiredClass){return ptr}if(undefined===desiredClass.baseClass){return null}var rv=downcastPointer(ptr,ptrClass,desiredClass.baseClass);if(rv===null){return null}return desiredClass.downcast(rv)};var registeredPointers={};var getInheritedInstanceCount=()=>Object.keys(registeredInstances).length;var getLiveInheritedInstances=()=>{var rv=[];for(var k in registeredInstances){if(registeredInstances.hasOwnProperty(k)){rv.push(registeredInstances[k])}}return rv};var deletionQueue=[];var flushPendingDeletes=()=>{while(deletionQueue.length){var obj=deletionQueue.pop();obj.$$.deleteScheduled=false;obj["delete"]()}};var delayFunction;var setDelayFunction=fn=>{delayFunction=fn;if(deletionQueue.length&&delayFunction){delayFunction(flushPendingDeletes)}};var init_embind=()=>{Module["getInheritedInstanceCount"]=getInheritedInstanceCount;Module["getLiveInheritedInstances"]=getLiveInheritedInstances;Module["flushPendingDeletes"]=flushPendingDeletes;Module["setDelayFunction"]=setDelayFunction};var registeredInstances={};var getBasestPointer=(class_,ptr)=>{if(ptr===undefined){throwBindingError("ptr should not be undefined")}while(class_.baseClass){ptr=class_.upcast(ptr);class_=class_.baseClass}return ptr};var getInheritedInstance=(class_,ptr)=>{ptr=getBasestPointer(class_,ptr);return registeredInstances[ptr]};var makeClassHandle=(prototype,record)=>{if(!record.ptrType||!record.ptr){throwInternalError("makeClassHandle requires ptr and ptrType")}var hasSmartPtrType=!!record.smartPtrType;var hasSmartPtr=!!record.smartPtr;if(hasSmartPtrType!==hasSmartPtr){throwInternalError("Both smartPtrType and smartPtr must be specified")}record.count={value:1};return attachFinalizer(Object.create(prototype,{$$:{value:record,writable:true}}))};function RegisteredPointer_fromWireType(ptr){var rawPointer=this.getPointee(ptr);if(!rawPointer){this.destructor(ptr);return null}var registeredInstance=getInheritedInstance(this.registeredClass,rawPointer);if(undefined!==registeredInstance){if(0===registeredInstance.$$.count.value){registeredInstance.$$.ptr=rawPointer;registeredInstance.$$.smartPtr=ptr;return registeredInstance["clone"]()}else{var rv=registeredInstance["clone"]();this.destructor(ptr);return rv}}function makeDefaultHandle(){if(this.isSmartPointer){return makeClassHandle(this.registeredClass.instancePrototype,{ptrType:this.pointeeType,ptr:rawPointer,smartPtrType:this,smartPtr:ptr})}else{return makeClassHandle(this.registeredClass.instancePrototype,{ptrType:this,ptr:ptr})}}var actualType=this.registeredClass.getActualType(rawPointer);var registeredPointerRecord=registeredPointers[actualType];if(!registeredPointerRecord){return makeDefaultHandle.call(this)}var toType;if(this.isConst){toType=registeredPointerRecord.constPointerType}else{toType=registeredPointerRecord.pointerType}var dp=downcastPointer(rawPointer,this.registeredClass,toType.registeredClass);if(dp===null){return makeDefaultHandle.call(this)}if(this.isSmartPointer){return makeClassHandle(toType.registeredClass.instancePrototype,{ptrType:toType,ptr:dp,smartPtrType:this,smartPtr:ptr})}else{return makeClassHandle(toType.registeredClass.instancePrototype,{ptrType:toType,ptr:dp})}}var attachFinalizer=handle=>{if("undefined"===typeof FinalizationRegistry){attachFinalizer=handle=>handle;return handle}finalizationRegistry=new FinalizationRegistry(info=>{releaseClassHandle(info.$$)});attachFinalizer=handle=>{var $$=handle.$$;var hasSmartPtr=!!$$.smartPtr;if(hasSmartPtr){var info={$$:$$};finalizationRegistry.register(handle,info,handle)}return handle};detachFinalizer=handle=>finalizationRegistry.unregister(handle);return attachFinalizer(handle)};var init_ClassHandle=()=>{Object.assign(ClassHandle.prototype,{isAliasOf(other){if(!(this instanceof ClassHandle)){return false}if(!(other instanceof ClassHandle)){return false}var leftClass=this.$$.ptrType.registeredClass;var left=this.$$.ptr;other.$$=other.$$;var rightClass=other.$$.ptrType.registeredClass;var right=other.$$.ptr;while(leftClass.baseClass){left=leftClass.upcast(left);leftClass=leftClass.baseClass}while(rightClass.baseClass){right=rightClass.upcast(right);rightClass=rightClass.baseClass}return leftClass===rightClass&&left===right},clone(){if(!this.$$.ptr){throwInstanceAlreadyDeleted(this)}if(this.$$.preservePointerOnDelete){this.$$.count.value+=1;return this}else{var clone=attachFinalizer(Object.create(Object.getPrototypeOf(this),{$$:{value:shallowCopyInternalPointer(this.$$)}}));clone.$$.count.value+=1;clone.$$.deleteScheduled=false;return clone}},delete(){if(!this.$$.ptr){throwInstanceAlreadyDeleted(this)}if(this.$$.deleteScheduled&&!this.$$.preservePointerOnDelete){throwBindingError("Object already scheduled for deletion")}detachFinalizer(this);releaseClassHandle(this.$$);if(!this.$$.preservePointerOnDelete){this.$$.smartPtr=undefined;this.$$.ptr=undefined}},isDeleted(){return!this.$$.ptr},deleteLater(){if(!this.$$.ptr){throwInstanceAlreadyDeleted(this)}if(this.$$.deleteScheduled&&!this.$$.preservePointerOnDelete){throwBindingError("Object already scheduled for deletion")}deletionQueue.push(this);if(deletionQueue.length===1&&delayFunction){delayFunction(flushPendingDeletes)}this.$$.deleteScheduled=true;return this}})};function ClassHandle(){}var createNamedFunction=(name,body)=>Object.defineProperty(body,"name",{value:name});var ensureOverloadTable=(proto,methodName,humanName)=>{if(undefined===proto[methodName].overloadTable){var prevFunc=proto[methodName];proto[methodName]=function(...args){if(!proto[methodName].overloadTable.hasOwnProperty(args.length)){throwBindingError(`Function '${humanName}' called with an invalid number of arguments (${args.length}) - expects one of (${proto[methodName].overloadTable})!`)}return proto[methodName].overloadTable[args.length].apply(this,args)};proto[methodName].overloadTable=[];proto[methodName].overloadTable[prevFunc.argCount]=prevFunc}};var exposePublicSymbol=(name,value,numArguments)=>{if(Module.hasOwnProperty(name)){if(undefined===numArguments||undefined!==Module[name].overloadTable&&undefined!==Module[name].overloadTable[numArguments]){throwBindingError(`Cannot register public name '${name}' twice`)}ensureOverloadTable(Module,name,name);if(Module.hasOwnProperty(numArguments)){throwBindingError(`Cannot register multiple overloads of a function with the same number of arguments (${numArguments})!`)}Module[name].overloadTable[numArguments]=value}else{Module[name]=value;if(undefined!==numArguments){Module[name].numArguments=numArguments}}};var char_0=48;var char_9=57;var makeLegalFunctionName=name=>{if(undefined===name){return"_unknown"}name=name.replace(/[^a-zA-Z0-9_]/g,"$");var f=name.charCodeAt(0);if(f>=char_0&&f<=char_9){return`_${name}`}return name};function RegisteredClass(name,constructor,instancePrototype,rawDestructor,baseClass,getActualType,upcast,downcast){this.name=name;this.constructor=constructor;this.instancePrototype=instancePrototype;this.rawDestructor=rawDestructor;this.baseClass=baseClass;this.getActualType=getActualType;this.upcast=upcast;this.downcast=downcast;this.pureVirtualFunctions=[]}var upcastPointer=(ptr,ptrClass,desiredClass)=>{while(ptrClass!==desiredClass){if(!ptrClass.upcast){throwBindingError(`Expected null or instance of ${desiredClass.name}, got an instance of ${ptrClass.name}`)}ptr=ptrClass.upcast(ptr);ptrClass=ptrClass.baseClass}return ptr};function constNoSmartPtrRawPointerToWireType(destructors,handle){if(handle===null){if(this.isReference){throwBindingError(`null is not a valid ${this.name}`)}return 0}if(!handle.$$){throwBindingError(`Cannot pass "${embindRepr(handle)}" as a ${this.name}`)}if(!handle.$$.ptr){throwBindingError(`Cannot pass deleted object as a pointer of type ${this.name}`)}var handleClass=handle.$$.ptrType.registeredClass;var ptr=upcastPointer(handle.$$.ptr,handleClass,this.registeredClass);return ptr}function genericPointerToWireType(destructors,handle){var ptr;if(handle===null){if(this.isReference){throwBindingError(`null is not a valid ${this.name}`)}if(this.isSmartPointer){ptr=this.rawConstructor();if(destructors!==null){destructors.push(this.rawDestructor,ptr)}return ptr}else{return 0}}if(!handle||!handle.$$){throwBindingError(`Cannot pass "${embindRepr(handle)}" as a ${this.name}`)}if(!handle.$$.ptr){throwBindingError(`Cannot pass deleted object as a pointer of type ${this.name}`)}if(!this.isConst&&handle.$$.ptrType.isConst){throwBindingError(`Cannot convert argument of type ${handle.$$.smartPtrType?handle.$$.smartPtrType.name:handle.$$.ptrType.name} to parameter type ${this.name}`)}var handleClass=handle.$$.ptrType.registeredClass;ptr=upcastPointer(handle.$$.ptr,handleClass,this.registeredClass);if(this.isSmartPointer){if(undefined===handle.$$.smartPtr){throwBindingError("Passing raw pointer to smart pointer is illegal")}switch(this.sharingPolicy){case 0:if(handle.$$.smartPtrType===this){ptr=handle.$$.smartPtr}else{throwBindingError(`Cannot convert argument of type ${handle.$$.smartPtrType?handle.$$.smartPtrType.name:handle.$$.ptrType.name} to parameter type ${this.name}`)}break;case 1:ptr=handle.$$.smartPtr;break;case 2:if(handle.$$.smartPtrType===this){ptr=handle.$$.smartPtr}else{var clonedHandle=handle["clone"]();ptr=this.rawShare(ptr,Emval.toHandle(()=>clonedHandle["delete"]()));if(destructors!==null){destructors.push(this.rawDestructor,ptr)}}break;default:throwBindingError("Unsupporting sharing policy")}}return ptr}function nonConstNoSmartPtrRawPointerToWireType(destructors,handle){if(handle===null){if(this.isReference){throwBindingError(`null is not a valid ${this.name}`)}return 0}if(!handle.$$){throwBindingError(`Cannot pass "${embindRepr(handle)}" as a ${this.name}`)}if(!handle.$$.ptr){throwBindingError(`Cannot pass deleted object as a pointer of type ${this.name}`)}if(handle.$$.ptrType.isConst){throwBindingError(`Cannot convert argument of type ${handle.$$.ptrType.name} to parameter type ${this.name}`)}var handleClass=handle.$$.ptrType.registeredClass;var ptr=upcastPointer(handle.$$.ptr,handleClass,this.registeredClass);return ptr}function readPointer(pointer){return this["fromWireType"](HEAPU32[pointer>>2])}var init_RegisteredPointer=()=>{Object.assign(RegisteredPointer.prototype,{getPointee(ptr){if(this.rawGetPointee){ptr=this.rawGetPointee(ptr)}return ptr},destructor(ptr){this.rawDestructor?.(ptr)},argPackAdvance:GenericWireTypeSize,readValueFromPointer:readPointer,fromWireType:RegisteredPointer_fromWireType})};function RegisteredPointer(name,registeredClass,isReference,isConst,isSmartPointer,pointeeType,sharingPolicy,rawGetPointee,rawConstructor,rawShare,rawDestructor){this.name=name;this.registeredClass=registeredClass;this.isReference=isReference;this.isConst=isConst;this.isSmartPointer=isSmartPointer;this.pointeeType=pointeeType;this.sharingPolicy=sharingPolicy;this.rawGetPointee=rawGetPointee;this.rawConstructor=rawConstructor;this.rawShare=rawShare;this.rawDestructor=rawDestructor;if(!isSmartPointer&®isteredClass.baseClass===undefined){if(isConst){this["toWireType"]=constNoSmartPtrRawPointerToWireType;this.destructorFunction=null}else{this["toWireType"]=nonConstNoSmartPtrRawPointerToWireType;this.destructorFunction=null}}else{this["toWireType"]=genericPointerToWireType}}var replacePublicSymbol=(name,value,numArguments)=>{if(!Module.hasOwnProperty(name)){throwInternalError("Replacing nonexistent public symbol")}if(undefined!==Module[name].overloadTable&&undefined!==numArguments){Module[name].overloadTable[numArguments]=value}else{Module[name]=value;Module[name].argCount=numArguments}};var dynCallLegacy=(sig,ptr,args)=>{sig=sig.replace(/p/g,"i");var f=Module["dynCall_"+sig];return f(ptr,...args)};var wasmTableMirror=[];var wasmTable;var getWasmTableEntry=funcPtr=>{var func=wasmTableMirror[funcPtr];if(!func){if(funcPtr>=wasmTableMirror.length)wasmTableMirror.length=funcPtr+1;wasmTableMirror[funcPtr]=func=wasmTable.get(funcPtr)}return func};var dynCall=(sig,ptr,args=[])=>{if(sig.includes("j")){return dynCallLegacy(sig,ptr,args)}var rtn=getWasmTableEntry(ptr)(...args);return rtn};var getDynCaller=(sig,ptr)=>(...args)=>dynCall(sig,ptr,args);var embind__requireFunction=(signature,rawFunction)=>{signature=readLatin1String(signature);function makeDynCaller(){if(signature.includes("j")){return getDynCaller(signature,rawFunction)}return getWasmTableEntry(rawFunction)}var fp=makeDynCaller();if(typeof fp!="function"){throwBindingError(`unknown function pointer with signature ${signature}: ${rawFunction}`)}return fp};var extendError=(baseErrorType,errorName)=>{var errorClass=createNamedFunction(errorName,function(message){this.name=errorName;this.message=message;var stack=new Error(message).stack;if(stack!==undefined){this.stack=this.toString()+"\n"+stack.replace(/^Error(:[^\n]*)?\n/,"")}});errorClass.prototype=Object.create(baseErrorType.prototype);errorClass.prototype.constructor=errorClass;errorClass.prototype.toString=function(){if(this.message===undefined){return this.name}else{return`${this.name}: ${this.message}`}};return errorClass};var UnboundTypeError;var getTypeName=type=>{var ptr=___getTypeName(type);var rv=readLatin1String(ptr);_free(ptr);return rv};var throwUnboundTypeError=(message,types)=>{var unboundTypes=[];var seen={};function visit(type){if(seen[type]){return}if(registeredTypes[type]){return}if(typeDependencies[type]){typeDependencies[type].forEach(visit);return}unboundTypes.push(type);seen[type]=true}types.forEach(visit);throw new UnboundTypeError(`${message}: `+unboundTypes.map(getTypeName).join([", "]))};var __embind_register_class=(rawType,rawPointerType,rawConstPointerType,baseClassRawType,getActualTypeSignature,getActualType,upcastSignature,upcast,downcastSignature,downcast,name,destructorSignature,rawDestructor)=>{name=readLatin1String(name);getActualType=embind__requireFunction(getActualTypeSignature,getActualType);upcast&&=embind__requireFunction(upcastSignature,upcast);downcast&&=embind__requireFunction(downcastSignature,downcast);rawDestructor=embind__requireFunction(destructorSignature,rawDestructor);var legalFunctionName=makeLegalFunctionName(name);exposePublicSymbol(legalFunctionName,function(){throwUnboundTypeError(`Cannot construct ${name} due to unbound types`,[baseClassRawType])});whenDependentTypesAreResolved([rawType,rawPointerType,rawConstPointerType],baseClassRawType?[baseClassRawType]:[],base=>{base=base[0];var baseClass;var basePrototype;if(baseClassRawType){baseClass=base.registeredClass;basePrototype=baseClass.instancePrototype}else{basePrototype=ClassHandle.prototype}var constructor=createNamedFunction(name,function(...args){if(Object.getPrototypeOf(this)!==instancePrototype){throw new BindingError("Use 'new' to construct "+name)}if(undefined===registeredClass.constructor_body){throw new BindingError(name+" has no accessible constructor")}var body=registeredClass.constructor_body[args.length];if(undefined===body){throw new BindingError(`Tried to invoke ctor of ${name} with invalid number of parameters (${args.length}) - expected (${Object.keys(registeredClass.constructor_body).toString()}) parameters instead!`)}return body.apply(this,args)});var instancePrototype=Object.create(basePrototype,{constructor:{value:constructor}});constructor.prototype=instancePrototype;var registeredClass=new RegisteredClass(name,constructor,instancePrototype,rawDestructor,baseClass,getActualType,upcast,downcast);if(registeredClass.baseClass){registeredClass.baseClass.__derivedClasses??=[];registeredClass.baseClass.__derivedClasses.push(registeredClass)}var referenceConverter=new RegisteredPointer(name,registeredClass,true,false,false);var pointerConverter=new RegisteredPointer(name+"*",registeredClass,false,false,false);var constPointerConverter=new RegisteredPointer(name+" const*",registeredClass,false,true,false);registeredPointers[rawType]={pointerType:pointerConverter,constPointerType:constPointerConverter};replacePublicSymbol(legalFunctionName,constructor);return[referenceConverter,pointerConverter,constPointerConverter]})};var heap32VectorToArray=(count,firstElement)=>{var array=[];for(var i=0;i>2])}return array};var runDestructors=destructors=>{while(destructors.length){var ptr=destructors.pop();var del=destructors.pop();del(ptr)}};function usesDestructorStack(argTypes){for(var i=1;i0?", ":"")+argsListWired}invokerFnBody+=(returns||isAsync?"var rv = ":"")+"invoker(fn"+(argsListWired.length>0?", ":"")+argsListWired+");\n";if(needsDestructorStack){invokerFnBody+="runDestructors(destructors);\n"}else{for(var i=isClassMethodFunc?1:2;i{var rawArgTypes=heap32VectorToArray(argCount,rawArgTypesAddr);invoker=embind__requireFunction(invokerSignature,invoker);whenDependentTypesAreResolved([],[rawClassType],classType=>{classType=classType[0];var humanName=`constructor ${classType.name}`;if(undefined===classType.registeredClass.constructor_body){classType.registeredClass.constructor_body=[]}if(undefined!==classType.registeredClass.constructor_body[argCount-1]){throw new BindingError(`Cannot register multiple constructors with identical number of parameters (${argCount-1}) for class '${classType.name}'! Overload resolution is currently only performed using the parameter count, not actual type info!`)}classType.registeredClass.constructor_body[argCount-1]=()=>{throwUnboundTypeError(`Cannot construct ${classType.name} due to unbound types`,rawArgTypes)};whenDependentTypesAreResolved([],rawArgTypes,argTypes=>{argTypes.splice(1,0,null);classType.registeredClass.constructor_body[argCount-1]=craftInvokerFunction(humanName,argTypes,null,invoker,rawConstructor);return[]});return[]})};var getFunctionName=signature=>{signature=signature.trim();const argsIndex=signature.indexOf("(");if(argsIndex!==-1){return signature.substr(0,argsIndex)}else{return signature}};var __embind_register_class_function=(rawClassType,methodName,argCount,rawArgTypesAddr,invokerSignature,rawInvoker,context,isPureVirtual,isAsync)=>{var rawArgTypes=heap32VectorToArray(argCount,rawArgTypesAddr);methodName=readLatin1String(methodName);methodName=getFunctionName(methodName);rawInvoker=embind__requireFunction(invokerSignature,rawInvoker);whenDependentTypesAreResolved([],[rawClassType],classType=>{classType=classType[0];var humanName=`${classType.name}.${methodName}`;if(methodName.startsWith("@@")){methodName=Symbol[methodName.substring(2)]}if(isPureVirtual){classType.registeredClass.pureVirtualFunctions.push(methodName)}function unboundTypesHandler(){throwUnboundTypeError(`Cannot call ${humanName} due to unbound types`,rawArgTypes)}var proto=classType.registeredClass.instancePrototype;var method=proto[methodName];if(undefined===method||undefined===method.overloadTable&&method.className!==classType.name&&method.argCount===argCount-2){unboundTypesHandler.argCount=argCount-2;unboundTypesHandler.className=classType.name;proto[methodName]=unboundTypesHandler}else{ensureOverloadTable(proto,methodName,humanName);proto[methodName].overloadTable[argCount-2]=unboundTypesHandler}whenDependentTypesAreResolved([],rawArgTypes,argTypes=>{var memberFunction=craftInvokerFunction(humanName,argTypes,classType,rawInvoker,context,isAsync);if(undefined===proto[methodName].overloadTable){memberFunction.argCount=argCount-2;proto[methodName]=memberFunction}else{proto[methodName].overloadTable[argCount-2]=memberFunction}return[]});return[]})};var validateThis=(this_,classType,humanName)=>{if(!(this_ instanceof Object)){throwBindingError(`${humanName} with invalid "this": ${this_}`)}if(!(this_ instanceof classType.registeredClass.constructor)){throwBindingError(`${humanName} incompatible with "this" of type ${this_.constructor.name}`)}if(!this_.$$.ptr){throwBindingError(`cannot call emscripten binding method ${humanName} on deleted object`)}return upcastPointer(this_.$$.ptr,this_.$$.ptrType.registeredClass,classType.registeredClass)};var __embind_register_class_property=(classType,fieldName,getterReturnType,getterSignature,getter,getterContext,setterArgumentType,setterSignature,setter,setterContext)=>{fieldName=readLatin1String(fieldName);getter=embind__requireFunction(getterSignature,getter);whenDependentTypesAreResolved([],[classType],classType=>{classType=classType[0];var humanName=`${classType.name}.${fieldName}`;var desc={get(){throwUnboundTypeError(`Cannot access ${humanName} due to unbound types`,[getterReturnType,setterArgumentType])},enumerable:true,configurable:true};if(setter){desc.set=()=>throwUnboundTypeError(`Cannot access ${humanName} due to unbound types`,[getterReturnType,setterArgumentType])}else{desc.set=v=>throwBindingError(humanName+" is a read-only property")}Object.defineProperty(classType.registeredClass.instancePrototype,fieldName,desc);whenDependentTypesAreResolved([],setter?[getterReturnType,setterArgumentType]:[getterReturnType],types=>{var getterReturnType=types[0];var desc={get(){var ptr=validateThis(this,classType,humanName+" getter");return getterReturnType["fromWireType"](getter(getterContext,ptr))},enumerable:true};if(setter){setter=embind__requireFunction(setterSignature,setter);var setterArgumentType=types[1];desc.set=function(v){var ptr=validateThis(this,classType,humanName+" setter");var destructors=[];setter(setterContext,ptr,setterArgumentType["toWireType"](destructors,v));runDestructors(destructors)}}Object.defineProperty(classType.registeredClass.instancePrototype,fieldName,desc);return[]});return[]})};var emval_freelist=[];var emval_handles=[];var __emval_decref=handle=>{if(handle>9&&0===--emval_handles[handle+1]){emval_handles[handle]=undefined;emval_freelist.push(handle)}};var count_emval_handles=()=>emval_handles.length/2-5-emval_freelist.length;var init_emval=()=>{emval_handles.push(0,1,undefined,1,null,1,true,1,false,1);Module["count_emval_handles"]=count_emval_handles};var Emval={toValue:handle=>{if(!handle){throwBindingError("Cannot use deleted val. handle = "+handle)}return emval_handles[handle]},toHandle:value=>{switch(value){case undefined:return 2;case null:return 4;case true:return 6;case false:return 8;default:{const handle=emval_freelist.pop()||emval_handles.length;emval_handles[handle]=value;emval_handles[handle+1]=1;return handle}}}};var EmValType={name:"emscripten::val",fromWireType:handle=>{var rv=Emval.toValue(handle);__emval_decref(handle);return rv},toWireType:(destructors,value)=>Emval.toHandle(value),argPackAdvance:GenericWireTypeSize,readValueFromPointer:readPointer,destructorFunction:null};var __embind_register_emval=rawType=>registerType(rawType,EmValType);var embindRepr=v=>{if(v===null){return"null"}var t=typeof v;if(t==="object"||t==="array"||t==="function"){return v.toString()}else{return""+v}};var floatReadValueFromPointer=(name,width)=>{switch(width){case 4:return function(pointer){return this["fromWireType"](HEAPF32[pointer>>2])};case 8:return function(pointer){return this["fromWireType"](HEAPF64[pointer>>3])};default:throw new TypeError(`invalid float width (${width}): ${name}`)}};var __embind_register_float=(rawType,name,size)=>{name=readLatin1String(name);registerType(rawType,{name:name,fromWireType:value=>value,toWireType:(destructors,value)=>value,argPackAdvance:GenericWireTypeSize,readValueFromPointer:floatReadValueFromPointer(name,size),destructorFunction:null})};var __embind_register_function=(name,argCount,rawArgTypesAddr,signature,rawInvoker,fn,isAsync)=>{var argTypes=heap32VectorToArray(argCount,rawArgTypesAddr);name=readLatin1String(name);name=getFunctionName(name);rawInvoker=embind__requireFunction(signature,rawInvoker);exposePublicSymbol(name,function(){throwUnboundTypeError(`Cannot call ${name} due to unbound types`,argTypes)},argCount-1);whenDependentTypesAreResolved([],argTypes,argTypes=>{var invokerArgsArray=[argTypes[0],null].concat(argTypes.slice(1));replacePublicSymbol(name,craftInvokerFunction(name,invokerArgsArray,null,rawInvoker,fn,isAsync),argCount-1);return[]})};var integerReadValueFromPointer=(name,width,signed)=>{switch(width){case 1:return signed?pointer=>HEAP8[pointer]:pointer=>HEAPU8[pointer];case 2:return signed?pointer=>HEAP16[pointer>>1]:pointer=>HEAPU16[pointer>>1];case 4:return signed?pointer=>HEAP32[pointer>>2]:pointer=>HEAPU32[pointer>>2];default:throw new TypeError(`invalid integer width (${width}): ${name}`)}};var __embind_register_integer=(primitiveType,name,size,minRange,maxRange)=>{name=readLatin1String(name);if(maxRange===-1){maxRange=4294967295}var fromWireType=value=>value;if(minRange===0){var bitshift=32-8*size;fromWireType=value=>value<>>bitshift}var isUnsignedType=name.includes("unsigned");var checkAssertions=(value,toTypeName)=>{};var toWireType;if(isUnsignedType){toWireType=function(destructors,value){checkAssertions(value,this.name);return value>>>0}}else{toWireType=function(destructors,value){checkAssertions(value,this.name);return value}}registerType(primitiveType,{name:name,fromWireType:fromWireType,toWireType:toWireType,argPackAdvance:GenericWireTypeSize,readValueFromPointer:integerReadValueFromPointer(name,size,minRange!==0),destructorFunction:null})};var __embind_register_memory_view=(rawType,dataTypeIndex,name)=>{var typeMapping=[Int8Array,Uint8Array,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array];var TA=typeMapping[dataTypeIndex];function decodeMemoryView(handle){var size=HEAPU32[handle>>2];var data=HEAPU32[handle+4>>2];return new TA(HEAP8.buffer,data,size)}name=readLatin1String(name);registerType(rawType,{name:name,fromWireType:decodeMemoryView,argPackAdvance:GenericWireTypeSize,readValueFromPointer:decodeMemoryView},{ignoreDuplicateRegistrations:true})};var __embind_register_optional=(rawOptionalType,rawType)=>{__embind_register_emval(rawOptionalType)};var stringToUTF8Array=(str,heap,outIdx,maxBytesToWrite)=>{if(!(maxBytesToWrite>0))return 0;var startIdx=outIdx;var endIdx=outIdx+maxBytesToWrite-1;for(var i=0;i=55296&&u<=57343){var u1=str.charCodeAt(++i);u=65536+((u&1023)<<10)|u1&1023}if(u<=127){if(outIdx>=endIdx)break;heap[outIdx++]=u}else if(u<=2047){if(outIdx+1>=endIdx)break;heap[outIdx++]=192|u>>6;heap[outIdx++]=128|u&63}else if(u<=65535){if(outIdx+2>=endIdx)break;heap[outIdx++]=224|u>>12;heap[outIdx++]=128|u>>6&63;heap[outIdx++]=128|u&63}else{if(outIdx+3>=endIdx)break;heap[outIdx++]=240|u>>18;heap[outIdx++]=128|u>>12&63;heap[outIdx++]=128|u>>6&63;heap[outIdx++]=128|u&63}}heap[outIdx]=0;return outIdx-startIdx};var stringToUTF8=(str,outPtr,maxBytesToWrite)=>stringToUTF8Array(str,HEAPU8,outPtr,maxBytesToWrite);var lengthBytesUTF8=str=>{var len=0;for(var i=0;i=55296&&c<=57343){len+=4;++i}else{len+=3}}return len};var UTF8Decoder=typeof TextDecoder!="undefined"?new TextDecoder:undefined;var UTF8ArrayToString=(heapOrArray,idx,maxBytesToRead)=>{var endIdx=idx+maxBytesToRead;var endPtr=idx;while(heapOrArray[endPtr]&&!(endPtr>=endIdx))++endPtr;if(endPtr-idx>16&&heapOrArray.buffer&&UTF8Decoder){return UTF8Decoder.decode(heapOrArray.subarray(idx,endPtr))}var str="";while(idx>10,56320|ch&1023)}}return str};var UTF8ToString=(ptr,maxBytesToRead)=>ptr?UTF8ArrayToString(HEAPU8,ptr,maxBytesToRead):"";var __embind_register_std_string=(rawType,name)=>{name=readLatin1String(name);var stdStringIsUTF8=name==="std::string";registerType(rawType,{name:name,fromWireType(value){var length=HEAPU32[value>>2];var payload=value+4;var str;if(stdStringIsUTF8){var decodeStartPtr=payload;for(var i=0;i<=length;++i){var currentBytePtr=payload+i;if(i==length||HEAPU8[currentBytePtr]==0){var maxRead=currentBytePtr-decodeStartPtr;var stringSegment=UTF8ToString(decodeStartPtr,maxRead);if(str===undefined){str=stringSegment}else{str+=String.fromCharCode(0);str+=stringSegment}decodeStartPtr=currentBytePtr+1}}}else{var a=new Array(length);for(var i=0;i>2]=length;if(stdStringIsUTF8&&valueIsOfTypeString){stringToUTF8(value,ptr,length+1)}else{if(valueIsOfTypeString){for(var i=0;i255){_free(ptr);throwBindingError("String has UTF-16 code units that do not fit in 8 bits")}HEAPU8[ptr+i]=charCode}}else{for(var i=0;i{var endPtr=ptr;var idx=endPtr>>1;var maxIdx=idx+maxBytesToRead/2;while(!(idx>=maxIdx)&&HEAPU16[idx])++idx;endPtr=idx<<1;if(endPtr-ptr>32&&UTF16Decoder)return UTF16Decoder.decode(HEAPU8.subarray(ptr,endPtr));var str="";for(var i=0;!(i>=maxBytesToRead/2);++i){var codeUnit=HEAP16[ptr+i*2>>1];if(codeUnit==0)break;str+=String.fromCharCode(codeUnit)}return str};var stringToUTF16=(str,outPtr,maxBytesToWrite)=>{maxBytesToWrite??=2147483647;if(maxBytesToWrite<2)return 0;maxBytesToWrite-=2;var startPtr=outPtr;var numCharsToWrite=maxBytesToWrite>1]=codeUnit;outPtr+=2}HEAP16[outPtr>>1]=0;return outPtr-startPtr};var lengthBytesUTF16=str=>str.length*2;var UTF32ToString=(ptr,maxBytesToRead)=>{var i=0;var str="";while(!(i>=maxBytesToRead/4)){var utf32=HEAP32[ptr+i*4>>2];if(utf32==0)break;++i;if(utf32>=65536){var ch=utf32-65536;str+=String.fromCharCode(55296|ch>>10,56320|ch&1023)}else{str+=String.fromCharCode(utf32)}}return str};var stringToUTF32=(str,outPtr,maxBytesToWrite)=>{maxBytesToWrite??=2147483647;if(maxBytesToWrite<4)return 0;var startPtr=outPtr;var endPtr=startPtr+maxBytesToWrite-4;for(var i=0;i=55296&&codeUnit<=57343){var trailSurrogate=str.charCodeAt(++i);codeUnit=65536+((codeUnit&1023)<<10)|trailSurrogate&1023}HEAP32[outPtr>>2]=codeUnit;outPtr+=4;if(outPtr+4>endPtr)break}HEAP32[outPtr>>2]=0;return outPtr-startPtr};var lengthBytesUTF32=str=>{var len=0;for(var i=0;i=55296&&codeUnit<=57343)++i;len+=4}return len};var __embind_register_std_wstring=(rawType,charSize,name)=>{name=readLatin1String(name);var decodeString,encodeString,readCharAt,lengthBytesUTF;if(charSize===2){decodeString=UTF16ToString;encodeString=stringToUTF16;lengthBytesUTF=lengthBytesUTF16;readCharAt=pointer=>HEAPU16[pointer>>1]}else if(charSize===4){decodeString=UTF32ToString;encodeString=stringToUTF32;lengthBytesUTF=lengthBytesUTF32;readCharAt=pointer=>HEAPU32[pointer>>2]}registerType(rawType,{name:name,fromWireType:value=>{var length=HEAPU32[value>>2];var str;var decodeStartPtr=value+4;for(var i=0;i<=length;++i){var currentBytePtr=value+4+i*charSize;if(i==length||readCharAt(currentBytePtr)==0){var maxReadBytes=currentBytePtr-decodeStartPtr;var stringSegment=decodeString(decodeStartPtr,maxReadBytes);if(str===undefined){str=stringSegment}else{str+=String.fromCharCode(0);str+=stringSegment}decodeStartPtr=currentBytePtr+charSize}}_free(value);return str},toWireType:(destructors,value)=>{if(!(typeof value=="string")){throwBindingError(`Cannot pass non-string to C++ string type ${name}`)}var length=lengthBytesUTF(value);var ptr=_malloc(4+length+charSize);HEAPU32[ptr>>2]=length/charSize;encodeString(value,ptr+4,length+charSize);if(destructors!==null){destructors.push(_free,ptr)}return ptr},argPackAdvance:GenericWireTypeSize,readValueFromPointer:readPointer,destructorFunction(ptr){_free(ptr)}})};var __embind_register_void=(rawType,name)=>{name=readLatin1String(name);registerType(rawType,{isVoid:true,name:name,argPackAdvance:0,fromWireType:()=>undefined,toWireType:(destructors,o)=>undefined})};var __emscripten_memcpy_js=(dest,src,num)=>HEAPU8.copyWithin(dest,src,src+num);var requireRegisteredType=(rawType,humanName)=>{var impl=registeredTypes[rawType];if(undefined===impl){throwBindingError(`${humanName} has unknown type ${getTypeName(rawType)}`)}return impl};var __emval_take_value=(type,arg)=>{type=requireRegisteredType(type,"_emval_take_value");var v=type["readValueFromPointer"](arg);return Emval.toHandle(v)};var _emscripten_date_now=()=>Date.now();var abortOnCannotGrowMemory=requestedSize=>{abort("OOM")};var _emscripten_resize_heap=requestedSize=>{var oldSize=HEAPU8.length;requestedSize>>>=0;abortOnCannotGrowMemory(requestedSize)};var printCharBuffers=[null,[],[]];var printChar=(stream,curr)=>{var buffer=printCharBuffers[stream];if(curr===0||curr===10){(stream===1?out:err)(UTF8ArrayToString(buffer,0));buffer.length=0}else{buffer.push(curr)}};var _fd_write=(fd,iov,iovcnt,pnum)=>{var num=0;for(var i=0;i>2];var len=HEAPU32[iov+4>>2];iov+=8;for(var j=0;j>2]=num;return 0};embind_init_charCodes();BindingError=Module["BindingError"]=class BindingError extends Error{constructor(message){super(message);this.name="BindingError"}};InternalError=Module["InternalError"]=class InternalError extends Error{constructor(message){super(message);this.name="InternalError"}};init_ClassHandle();init_embind();init_RegisteredPointer();UnboundTypeError=Module["UnboundTypeError"]=extendError(Error,"UnboundTypeError");init_emval();var wasmImports={f:___cxa_throw,q:__abort_js,p:__embind_register_bigint,u:__embind_register_bool,l:__embind_register_class,h:__embind_register_class_constructor,e:__embind_register_class_function,a:__embind_register_class_property,t:__embind_register_emval,k:__embind_register_float,c:__embind_register_function,d:__embind_register_integer,b:__embind_register_memory_view,o:__embind_register_optional,j:__embind_register_std_string,g:__embind_register_std_wstring,m:__embind_register_void,s:__emscripten_memcpy_js,n:__emval_take_value,v:_emscripten_date_now,r:_emscripten_resize_heap,i:_fd_write};var wasmExports=createWasm();var ___wasm_call_ctors=()=>(___wasm_call_ctors=wasmExports["x"])();var _param_get=Module["_param_get"]=(a0,a1)=>(_param_get=Module["_param_get"]=wasmExports["y"])(a0,a1);var _param_set_used=Module["_param_set_used"]=a0=>(_param_set_used=Module["_param_set_used"]=wasmExports["z"])(a0);var __Znwm=Module["__Znwm"]=a0=>(__Znwm=Module["__Znwm"]=wasmExports["A"])(a0);var _param_get_mark_used=Module["_param_get_mark_used"]=(a0,a1)=>(_param_get_mark_used=Module["_param_get_mark_used"]=wasmExports["B"])(a0,a1);var __ZdlPvm=Module["__ZdlPvm"]=(a0,a1)=>(__ZdlPvm=Module["__ZdlPvm"]=wasmExports["C"])(a0,a1);var _malloc=a0=>(_malloc=wasmExports["E"])(a0);var __ZNSt12length_errorD1Ev=Module["__ZNSt12length_errorD1Ev"]=a0=>(__ZNSt12length_errorD1Ev=Module["__ZNSt12length_errorD1Ev"]=wasmExports["F"])(a0);var ___cxa_allocate_exception=Module["___cxa_allocate_exception"]=a0=>(___cxa_allocate_exception=Module["___cxa_allocate_exception"]=wasmExports["G"])(a0);var __ZNSt20bad_array_new_lengthD1Ev=Module["__ZNSt20bad_array_new_lengthD1Ev"]=a0=>(__ZNSt20bad_array_new_lengthD1Ev=Module["__ZNSt20bad_array_new_lengthD1Ev"]=wasmExports["H"])(a0);var __ZNSt20bad_array_new_lengthC1Ev=Module["__ZNSt20bad_array_new_lengthC1Ev"]=a0=>(__ZNSt20bad_array_new_lengthC1Ev=Module["__ZNSt20bad_array_new_lengthC1Ev"]=wasmExports["I"])(a0);var __ZNSt12out_of_rangeD1Ev=Module["__ZNSt12out_of_rangeD1Ev"]=a0=>(__ZNSt12out_of_rangeD1Ev=Module["__ZNSt12out_of_rangeD1Ev"]=wasmExports["J"])(a0);var ___cxa_pure_virtual=Module["___cxa_pure_virtual"]=()=>(___cxa_pure_virtual=Module["___cxa_pure_virtual"]=wasmExports["K"])();var ___getTypeName=a0=>(___getTypeName=wasmExports["L"])(a0);var __ZNSt9exceptionD2Ev=Module["__ZNSt9exceptionD2Ev"]=a0=>(__ZNSt9exceptionD2Ev=Module["__ZNSt9exceptionD2Ev"]=wasmExports["M"])(a0);var _free=a0=>(_free=wasmExports["N"])(a0);var _getTempRet0=Module["_getTempRet0"]=()=>(_getTempRet0=Module["_getTempRet0"]=wasmExports["O"])();var _setTempRet0=Module["_setTempRet0"]=a0=>(_setTempRet0=Module["_setTempRet0"]=wasmExports["P"])(a0);var __ZSt15get_new_handlerv=Module["__ZSt15get_new_handlerv"]=()=>(__ZSt15get_new_handlerv=Module["__ZSt15get_new_handlerv"]=wasmExports["Q"])();var __Znam=Module["__Znam"]=a0=>(__Znam=Module["__Znam"]=wasmExports["R"])(a0);var __ZdlPv=Module["__ZdlPv"]=a0=>(__ZdlPv=Module["__ZdlPv"]=wasmExports["S"])(a0);var __ZdaPv=Module["__ZdaPv"]=a0=>(__ZdaPv=Module["__ZdaPv"]=wasmExports["T"])(a0);var __ZdaPvm=Module["__ZdaPvm"]=(a0,a1)=>(__ZdaPvm=Module["__ZdaPvm"]=wasmExports["U"])(a0,a1);var __ZnwmSt11align_val_t=Module["__ZnwmSt11align_val_t"]=(a0,a1)=>(__ZnwmSt11align_val_t=Module["__ZnwmSt11align_val_t"]=wasmExports["V"])(a0,a1);var __ZnamSt11align_val_t=Module["__ZnamSt11align_val_t"]=(a0,a1)=>(__ZnamSt11align_val_t=Module["__ZnamSt11align_val_t"]=wasmExports["W"])(a0,a1);var __ZdlPvSt11align_val_t=Module["__ZdlPvSt11align_val_t"]=(a0,a1)=>(__ZdlPvSt11align_val_t=Module["__ZdlPvSt11align_val_t"]=wasmExports["X"])(a0,a1);var __ZdlPvmSt11align_val_t=Module["__ZdlPvmSt11align_val_t"]=(a0,a1,a2)=>(__ZdlPvmSt11align_val_t=Module["__ZdlPvmSt11align_val_t"]=wasmExports["Y"])(a0,a1,a2);var __ZdaPvSt11align_val_t=Module["__ZdaPvSt11align_val_t"]=(a0,a1)=>(__ZdaPvSt11align_val_t=Module["__ZdaPvSt11align_val_t"]=wasmExports["Z"])(a0,a1);var __ZdaPvmSt11align_val_t=Module["__ZdaPvmSt11align_val_t"]=(a0,a1,a2)=>(__ZdaPvmSt11align_val_t=Module["__ZdaPvmSt11align_val_t"]=wasmExports["_"])(a0,a1,a2);var __ZSt14set_unexpectedPFvvE=Module["__ZSt14set_unexpectedPFvvE"]=a0=>(__ZSt14set_unexpectedPFvvE=Module["__ZSt14set_unexpectedPFvvE"]=wasmExports["$"])(a0);var __ZSt13set_terminatePFvvE=Module["__ZSt13set_terminatePFvvE"]=a0=>(__ZSt13set_terminatePFvvE=Module["__ZSt13set_terminatePFvvE"]=wasmExports["aa"])(a0);var __ZSt15set_new_handlerPFvvE=Module["__ZSt15set_new_handlerPFvvE"]=a0=>(__ZSt15set_new_handlerPFvvE=Module["__ZSt15set_new_handlerPFvvE"]=wasmExports["ba"])(a0);var __ZSt14get_unexpectedv=Module["__ZSt14get_unexpectedv"]=()=>(__ZSt14get_unexpectedv=Module["__ZSt14get_unexpectedv"]=wasmExports["ca"])();var __ZSt10unexpectedv=Module["__ZSt10unexpectedv"]=()=>(__ZSt10unexpectedv=Module["__ZSt10unexpectedv"]=wasmExports["da"])();var __ZSt13get_terminatev=Module["__ZSt13get_terminatev"]=()=>(__ZSt13get_terminatev=Module["__ZSt13get_terminatev"]=wasmExports["ea"])();var __ZSt9terminatev=Module["__ZSt9terminatev"]=()=>(__ZSt9terminatev=Module["__ZSt9terminatev"]=wasmExports["fa"])();var ___cxa_current_primary_exception=Module["___cxa_current_primary_exception"]=()=>(___cxa_current_primary_exception=Module["___cxa_current_primary_exception"]=wasmExports["ga"])();var ___cxa_rethrow_primary_exception=Module["___cxa_rethrow_primary_exception"]=a0=>(___cxa_rethrow_primary_exception=Module["___cxa_rethrow_primary_exception"]=wasmExports["ha"])(a0);var ___cxa_uncaught_exception=Module["___cxa_uncaught_exception"]=()=>(___cxa_uncaught_exception=Module["___cxa_uncaught_exception"]=wasmExports["ia"])();var ___cxa_uncaught_exceptions=Module["___cxa_uncaught_exceptions"]=()=>(___cxa_uncaught_exceptions=Module["___cxa_uncaught_exceptions"]=wasmExports["ja"])();var ___cxa_free_exception=Module["___cxa_free_exception"]=a0=>(___cxa_free_exception=Module["___cxa_free_exception"]=wasmExports["ka"])(a0);var ___cxa_init_primary_exception=Module["___cxa_init_primary_exception"]=(a0,a1,a2)=>(___cxa_init_primary_exception=Module["___cxa_init_primary_exception"]=wasmExports["la"])(a0,a1,a2);var ___cxa_deleted_virtual=Module["___cxa_deleted_virtual"]=()=>(___cxa_deleted_virtual=Module["___cxa_deleted_virtual"]=wasmExports["ma"])();var ___dynamic_cast=Module["___dynamic_cast"]=(a0,a1,a2,a3)=>(___dynamic_cast=Module["___dynamic_cast"]=wasmExports["na"])(a0,a1,a2,a3);var __ZNSt9type_infoD2Ev=Module["__ZNSt9type_infoD2Ev"]=a0=>(__ZNSt9type_infoD2Ev=Module["__ZNSt9type_infoD2Ev"]=wasmExports["oa"])(a0);var ___cxa_is_pointer_type=a0=>(___cxa_is_pointer_type=wasmExports["pa"])(a0);var __ZNSt9exceptionD0Ev=Module["__ZNSt9exceptionD0Ev"]=a0=>(__ZNSt9exceptionD0Ev=Module["__ZNSt9exceptionD0Ev"]=wasmExports["qa"])(a0);var __ZNSt9exceptionD1Ev=Module["__ZNSt9exceptionD1Ev"]=a0=>(__ZNSt9exceptionD1Ev=Module["__ZNSt9exceptionD1Ev"]=wasmExports["ra"])(a0);var __ZNKSt9exception4whatEv=Module["__ZNKSt9exception4whatEv"]=a0=>(__ZNKSt9exception4whatEv=Module["__ZNKSt9exception4whatEv"]=wasmExports["sa"])(a0);var __ZNSt13bad_exceptionD0Ev=Module["__ZNSt13bad_exceptionD0Ev"]=a0=>(__ZNSt13bad_exceptionD0Ev=Module["__ZNSt13bad_exceptionD0Ev"]=wasmExports["ta"])(a0);var __ZNSt13bad_exceptionD1Ev=Module["__ZNSt13bad_exceptionD1Ev"]=a0=>(__ZNSt13bad_exceptionD1Ev=Module["__ZNSt13bad_exceptionD1Ev"]=wasmExports["ua"])(a0);var __ZNKSt13bad_exception4whatEv=Module["__ZNKSt13bad_exception4whatEv"]=a0=>(__ZNKSt13bad_exception4whatEv=Module["__ZNKSt13bad_exception4whatEv"]=wasmExports["va"])(a0);var __ZNSt9bad_allocC2Ev=Module["__ZNSt9bad_allocC2Ev"]=a0=>(__ZNSt9bad_allocC2Ev=Module["__ZNSt9bad_allocC2Ev"]=wasmExports["wa"])(a0);var __ZNSt9bad_allocD0Ev=Module["__ZNSt9bad_allocD0Ev"]=a0=>(__ZNSt9bad_allocD0Ev=Module["__ZNSt9bad_allocD0Ev"]=wasmExports["xa"])(a0);var __ZNSt9bad_allocD1Ev=Module["__ZNSt9bad_allocD1Ev"]=a0=>(__ZNSt9bad_allocD1Ev=Module["__ZNSt9bad_allocD1Ev"]=wasmExports["ya"])(a0);var __ZNKSt9bad_alloc4whatEv=Module["__ZNKSt9bad_alloc4whatEv"]=a0=>(__ZNKSt9bad_alloc4whatEv=Module["__ZNKSt9bad_alloc4whatEv"]=wasmExports["za"])(a0);var __ZNSt20bad_array_new_lengthC2Ev=Module["__ZNSt20bad_array_new_lengthC2Ev"]=a0=>(__ZNSt20bad_array_new_lengthC2Ev=Module["__ZNSt20bad_array_new_lengthC2Ev"]=wasmExports["Aa"])(a0);var __ZNSt20bad_array_new_lengthD0Ev=Module["__ZNSt20bad_array_new_lengthD0Ev"]=a0=>(__ZNSt20bad_array_new_lengthD0Ev=Module["__ZNSt20bad_array_new_lengthD0Ev"]=wasmExports["Ba"])(a0);var __ZNKSt20bad_array_new_length4whatEv=Module["__ZNKSt20bad_array_new_length4whatEv"]=a0=>(__ZNKSt20bad_array_new_length4whatEv=Module["__ZNKSt20bad_array_new_length4whatEv"]=wasmExports["Ca"])(a0);var __ZNSt13bad_exceptionD2Ev=Module["__ZNSt13bad_exceptionD2Ev"]=a0=>(__ZNSt13bad_exceptionD2Ev=Module["__ZNSt13bad_exceptionD2Ev"]=wasmExports["Da"])(a0);var __ZNSt9bad_allocC1Ev=Module["__ZNSt9bad_allocC1Ev"]=a0=>(__ZNSt9bad_allocC1Ev=Module["__ZNSt9bad_allocC1Ev"]=wasmExports["Ea"])(a0);var __ZNSt9bad_allocD2Ev=Module["__ZNSt9bad_allocD2Ev"]=a0=>(__ZNSt9bad_allocD2Ev=Module["__ZNSt9bad_allocD2Ev"]=wasmExports["Fa"])(a0);var __ZNSt20bad_array_new_lengthD2Ev=Module["__ZNSt20bad_array_new_lengthD2Ev"]=a0=>(__ZNSt20bad_array_new_lengthD2Ev=Module["__ZNSt20bad_array_new_lengthD2Ev"]=wasmExports["Ga"])(a0);var __ZNSt11logic_errorD2Ev=Module["__ZNSt11logic_errorD2Ev"]=a0=>(__ZNSt11logic_errorD2Ev=Module["__ZNSt11logic_errorD2Ev"]=wasmExports["Ha"])(a0);var __ZNSt11logic_errorD0Ev=Module["__ZNSt11logic_errorD0Ev"]=a0=>(__ZNSt11logic_errorD0Ev=Module["__ZNSt11logic_errorD0Ev"]=wasmExports["Ia"])(a0);var __ZNSt11logic_errorD1Ev=Module["__ZNSt11logic_errorD1Ev"]=a0=>(__ZNSt11logic_errorD1Ev=Module["__ZNSt11logic_errorD1Ev"]=wasmExports["Ja"])(a0);var __ZNKSt11logic_error4whatEv=Module["__ZNKSt11logic_error4whatEv"]=a0=>(__ZNKSt11logic_error4whatEv=Module["__ZNKSt11logic_error4whatEv"]=wasmExports["Ka"])(a0);var __ZNSt13runtime_errorD2Ev=Module["__ZNSt13runtime_errorD2Ev"]=a0=>(__ZNSt13runtime_errorD2Ev=Module["__ZNSt13runtime_errorD2Ev"]=wasmExports["La"])(a0);var __ZNSt13runtime_errorD0Ev=Module["__ZNSt13runtime_errorD0Ev"]=a0=>(__ZNSt13runtime_errorD0Ev=Module["__ZNSt13runtime_errorD0Ev"]=wasmExports["Ma"])(a0);var __ZNSt13runtime_errorD1Ev=Module["__ZNSt13runtime_errorD1Ev"]=a0=>(__ZNSt13runtime_errorD1Ev=Module["__ZNSt13runtime_errorD1Ev"]=wasmExports["Na"])(a0);var __ZNKSt13runtime_error4whatEv=Module["__ZNKSt13runtime_error4whatEv"]=a0=>(__ZNKSt13runtime_error4whatEv=Module["__ZNKSt13runtime_error4whatEv"]=wasmExports["Oa"])(a0);var __ZNSt12domain_errorD0Ev=Module["__ZNSt12domain_errorD0Ev"]=a0=>(__ZNSt12domain_errorD0Ev=Module["__ZNSt12domain_errorD0Ev"]=wasmExports["Pa"])(a0);var __ZNSt12domain_errorD1Ev=Module["__ZNSt12domain_errorD1Ev"]=a0=>(__ZNSt12domain_errorD1Ev=Module["__ZNSt12domain_errorD1Ev"]=wasmExports["Qa"])(a0);var __ZNSt16invalid_argumentD0Ev=Module["__ZNSt16invalid_argumentD0Ev"]=a0=>(__ZNSt16invalid_argumentD0Ev=Module["__ZNSt16invalid_argumentD0Ev"]=wasmExports["Ra"])(a0);var __ZNSt16invalid_argumentD1Ev=Module["__ZNSt16invalid_argumentD1Ev"]=a0=>(__ZNSt16invalid_argumentD1Ev=Module["__ZNSt16invalid_argumentD1Ev"]=wasmExports["Sa"])(a0);var __ZNSt12length_errorD0Ev=Module["__ZNSt12length_errorD0Ev"]=a0=>(__ZNSt12length_errorD0Ev=Module["__ZNSt12length_errorD0Ev"]=wasmExports["Ta"])(a0);var __ZNSt12out_of_rangeD0Ev=Module["__ZNSt12out_of_rangeD0Ev"]=a0=>(__ZNSt12out_of_rangeD0Ev=Module["__ZNSt12out_of_rangeD0Ev"]=wasmExports["Ua"])(a0);var __ZNSt11range_errorD0Ev=Module["__ZNSt11range_errorD0Ev"]=a0=>(__ZNSt11range_errorD0Ev=Module["__ZNSt11range_errorD0Ev"]=wasmExports["Va"])(a0);var __ZNSt11range_errorD1Ev=Module["__ZNSt11range_errorD1Ev"]=a0=>(__ZNSt11range_errorD1Ev=Module["__ZNSt11range_errorD1Ev"]=wasmExports["Wa"])(a0);var __ZNSt14overflow_errorD0Ev=Module["__ZNSt14overflow_errorD0Ev"]=a0=>(__ZNSt14overflow_errorD0Ev=Module["__ZNSt14overflow_errorD0Ev"]=wasmExports["Xa"])(a0);var __ZNSt14overflow_errorD1Ev=Module["__ZNSt14overflow_errorD1Ev"]=a0=>(__ZNSt14overflow_errorD1Ev=Module["__ZNSt14overflow_errorD1Ev"]=wasmExports["Ya"])(a0);var __ZNSt15underflow_errorD0Ev=Module["__ZNSt15underflow_errorD0Ev"]=a0=>(__ZNSt15underflow_errorD0Ev=Module["__ZNSt15underflow_errorD0Ev"]=wasmExports["Za"])(a0);var __ZNSt15underflow_errorD1Ev=Module["__ZNSt15underflow_errorD1Ev"]=a0=>(__ZNSt15underflow_errorD1Ev=Module["__ZNSt15underflow_errorD1Ev"]=wasmExports["_a"])(a0);var __ZNSt12domain_errorD2Ev=Module["__ZNSt12domain_errorD2Ev"]=a0=>(__ZNSt12domain_errorD2Ev=Module["__ZNSt12domain_errorD2Ev"]=wasmExports["$a"])(a0);var __ZNSt16invalid_argumentD2Ev=Module["__ZNSt16invalid_argumentD2Ev"]=a0=>(__ZNSt16invalid_argumentD2Ev=Module["__ZNSt16invalid_argumentD2Ev"]=wasmExports["ab"])(a0);var __ZNSt12length_errorD2Ev=Module["__ZNSt12length_errorD2Ev"]=a0=>(__ZNSt12length_errorD2Ev=Module["__ZNSt12length_errorD2Ev"]=wasmExports["bb"])(a0);var __ZNSt12out_of_rangeD2Ev=Module["__ZNSt12out_of_rangeD2Ev"]=a0=>(__ZNSt12out_of_rangeD2Ev=Module["__ZNSt12out_of_rangeD2Ev"]=wasmExports["cb"])(a0);var __ZNSt11range_errorD2Ev=Module["__ZNSt11range_errorD2Ev"]=a0=>(__ZNSt11range_errorD2Ev=Module["__ZNSt11range_errorD2Ev"]=wasmExports["db"])(a0);var __ZNSt14overflow_errorD2Ev=Module["__ZNSt14overflow_errorD2Ev"]=a0=>(__ZNSt14overflow_errorD2Ev=Module["__ZNSt14overflow_errorD2Ev"]=wasmExports["eb"])(a0);var __ZNSt15underflow_errorD2Ev=Module["__ZNSt15underflow_errorD2Ev"]=a0=>(__ZNSt15underflow_errorD2Ev=Module["__ZNSt15underflow_errorD2Ev"]=wasmExports["fb"])(a0);var __ZNSt9type_infoD0Ev=Module["__ZNSt9type_infoD0Ev"]=a0=>(__ZNSt9type_infoD0Ev=Module["__ZNSt9type_infoD0Ev"]=wasmExports["gb"])(a0);var __ZNSt9type_infoD1Ev=Module["__ZNSt9type_infoD1Ev"]=a0=>(__ZNSt9type_infoD1Ev=Module["__ZNSt9type_infoD1Ev"]=wasmExports["hb"])(a0);var __ZNSt8bad_castC2Ev=Module["__ZNSt8bad_castC2Ev"]=a0=>(__ZNSt8bad_castC2Ev=Module["__ZNSt8bad_castC2Ev"]=wasmExports["ib"])(a0);var __ZNSt8bad_castD2Ev=Module["__ZNSt8bad_castD2Ev"]=a0=>(__ZNSt8bad_castD2Ev=Module["__ZNSt8bad_castD2Ev"]=wasmExports["jb"])(a0);var __ZNSt8bad_castD0Ev=Module["__ZNSt8bad_castD0Ev"]=a0=>(__ZNSt8bad_castD0Ev=Module["__ZNSt8bad_castD0Ev"]=wasmExports["kb"])(a0);var __ZNSt8bad_castD1Ev=Module["__ZNSt8bad_castD1Ev"]=a0=>(__ZNSt8bad_castD1Ev=Module["__ZNSt8bad_castD1Ev"]=wasmExports["lb"])(a0);var __ZNKSt8bad_cast4whatEv=Module["__ZNKSt8bad_cast4whatEv"]=a0=>(__ZNKSt8bad_cast4whatEv=Module["__ZNKSt8bad_cast4whatEv"]=wasmExports["mb"])(a0);var __ZNSt10bad_typeidC2Ev=Module["__ZNSt10bad_typeidC2Ev"]=a0=>(__ZNSt10bad_typeidC2Ev=Module["__ZNSt10bad_typeidC2Ev"]=wasmExports["nb"])(a0);var __ZNSt10bad_typeidD2Ev=Module["__ZNSt10bad_typeidD2Ev"]=a0=>(__ZNSt10bad_typeidD2Ev=Module["__ZNSt10bad_typeidD2Ev"]=wasmExports["ob"])(a0);var __ZNSt10bad_typeidD0Ev=Module["__ZNSt10bad_typeidD0Ev"]=a0=>(__ZNSt10bad_typeidD0Ev=Module["__ZNSt10bad_typeidD0Ev"]=wasmExports["pb"])(a0);var __ZNSt10bad_typeidD1Ev=Module["__ZNSt10bad_typeidD1Ev"]=a0=>(__ZNSt10bad_typeidD1Ev=Module["__ZNSt10bad_typeidD1Ev"]=wasmExports["qb"])(a0);var __ZNKSt10bad_typeid4whatEv=Module["__ZNKSt10bad_typeid4whatEv"]=a0=>(__ZNKSt10bad_typeid4whatEv=Module["__ZNKSt10bad_typeid4whatEv"]=wasmExports["rb"])(a0);var __ZNSt8bad_castC1Ev=Module["__ZNSt8bad_castC1Ev"]=a0=>(__ZNSt8bad_castC1Ev=Module["__ZNSt8bad_castC1Ev"]=wasmExports["sb"])(a0);var __ZNSt10bad_typeidC1Ev=Module["__ZNSt10bad_typeidC1Ev"]=a0=>(__ZNSt10bad_typeidC1Ev=Module["__ZNSt10bad_typeidC1Ev"]=wasmExports["tb"])(a0);var dynCall_jiji=Module["dynCall_jiji"]=(a0,a1,a2,a3,a4)=>(dynCall_jiji=Module["dynCall_jiji"]=wasmExports["ub"])(a0,a1,a2,a3,a4);var __ZTIPK16failsafe_flags_s=Module["__ZTIPK16failsafe_flags_s"]=52152;var __ZTIP16failsafe_flags_s=Module["__ZTIP16failsafe_flags_s"]=52136;var __ZTI16failsafe_flags_s=Module["__ZTI16failsafe_flags_s"]=52128;var __ZTIb=Module["__ZTIb"]=33688;var __ZTIh=Module["__ZTIh"]=33844;var __ZTINSt3__212basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEE=Module["__ZTINSt3__212basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEE"]=52224;var __ZTINSt3__28optionalINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEEEE=Module["__ZTINSt3__28optionalINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEEEE"]=52372;var __ZTIPKNSt3__26vectorINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEENS4_IS6_EEEE=Module["__ZTIPKNSt3__26vectorINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEENS4_IS6_EEEE"]=52428;var __ZTIPNSt3__26vectorINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEENS4_IS6_EEEE=Module["__ZTIPNSt3__26vectorINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEENS4_IS6_EEEE"]=52412;var __ZTINSt3__26vectorINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEENS4_IS6_EEEE=Module["__ZTINSt3__26vectorINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEENS4_IS6_EEEE"]=52236;var __ZTISt12length_error=Module["__ZTISt12length_error"]=35804;var __ZTVSt12length_error=Module["__ZTVSt12length_error"]=35764;var __ZTISt20bad_array_new_length=Module["__ZTISt20bad_array_new_length"]=35576;var __ZTISt12out_of_range=Module["__ZTISt12out_of_range"]=35856;var __ZTVSt12out_of_range=Module["__ZTVSt12out_of_range"]=35816;var __ZTVN10__cxxabiv117__class_type_infoE=Module["__ZTVN10__cxxabiv117__class_type_infoE"]=35076;var __ZTVN10__cxxabiv121__vmi_class_type_infoE=Module["__ZTVN10__cxxabiv121__vmi_class_type_infoE"]=35208;var __ZTVN10__cxxabiv120__si_class_type_infoE=Module["__ZTVN10__cxxabiv120__si_class_type_infoE"]=35116;var __ZTS16failsafe_flags_s=Module["__ZTS16failsafe_flags_s"]=30588;var __ZTSP16failsafe_flags_s=Module["__ZTSP16failsafe_flags_s"]=30607;var __ZTVN10__cxxabiv119__pointer_type_infoE=Module["__ZTVN10__cxxabiv119__pointer_type_infoE"]=35328;var __ZTSPK16failsafe_flags_s=Module["__ZTSPK16failsafe_flags_s"]=30627;var __ZTIi=Module["__ZTIi"]=34052;var __ZTSNSt3__212basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEE=Module["__ZTSNSt3__212basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEE"]=30677;var __ZTSNSt3__26vectorINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEENS4_IS6_EEEE=Module["__ZTSNSt3__26vectorINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEENS4_IS6_EEEE"]=30744;var __ZTIv=Module["__ZTIv"]=33580;var __ZTIf=Module["__ZTIf"]=34524;var __ZTSNSt3__28optionalINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEEEE=Module["__ZTSNSt3__28optionalINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEEEE"]=30842;var __ZTSNSt3__227__optional_move_assign_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE=Module["__ZTSNSt3__227__optional_move_assign_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE"]=30920;var __ZTSNSt3__227__optional_copy_assign_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE=Module["__ZTSNSt3__227__optional_copy_assign_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE"]=31022;var __ZTSNSt3__220__optional_move_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE=Module["__ZTSNSt3__220__optional_move_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE"]=31124;var __ZTSNSt3__220__optional_copy_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE=Module["__ZTSNSt3__220__optional_copy_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE"]=31219;var __ZTSNSt3__223__optional_storage_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE=Module["__ZTSNSt3__223__optional_storage_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE"]=31314;var __ZTSNSt3__224__optional_destruct_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE=Module["__ZTSNSt3__224__optional_destruct_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE"]=31412;var __ZTINSt3__224__optional_destruct_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE=Module["__ZTINSt3__224__optional_destruct_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE"]=52288;var __ZTINSt3__223__optional_storage_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE=Module["__ZTINSt3__223__optional_storage_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE"]=52296;var __ZTINSt3__220__optional_copy_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE=Module["__ZTINSt3__220__optional_copy_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE"]=52308;var __ZTINSt3__220__optional_move_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE=Module["__ZTINSt3__220__optional_move_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE"]=52320;var __ZTINSt3__227__optional_copy_assign_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE=Module["__ZTINSt3__227__optional_copy_assign_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE"]=52332;var __ZTINSt3__227__optional_move_assign_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE=Module["__ZTINSt3__227__optional_move_assign_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE"]=52344;var __ZTSNSt3__218__sfinae_ctor_baseILb1ELb1EEE=Module["__ZTSNSt3__218__sfinae_ctor_baseILb1ELb1EEE"]=31511;var __ZTINSt3__218__sfinae_ctor_baseILb1ELb1EEE=Module["__ZTINSt3__218__sfinae_ctor_baseILb1ELb1EEE"]=52356;var __ZTSNSt3__220__sfinae_assign_baseILb1ELb1EEE=Module["__ZTSNSt3__220__sfinae_assign_baseILb1ELb1EEE"]=31550;var __ZTINSt3__220__sfinae_assign_baseILb1ELb1EEE=Module["__ZTINSt3__220__sfinae_assign_baseILb1ELb1EEE"]=52364;var __ZTSPNSt3__26vectorINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEENS4_IS6_EEEE=Module["__ZTSPNSt3__26vectorINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEENS4_IS6_EEEE"]=31591;var __ZTSPKNSt3__26vectorINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEENS4_IS6_EEEE=Module["__ZTSPKNSt3__26vectorINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEENS4_IS6_EEEE"]=31678;var __ZTIm=Module["__ZTIm"]=34208;var __ZTIc=Module["__ZTIc"]=33792;var __ZTIa=Module["__ZTIa"]=33896;var __ZTIs=Module["__ZTIs"]=33948;var __ZTIt=Module["__ZTIt"]=34e3;var __ZTIj=Module["__ZTIj"]=34104;var __ZTIl=Module["__ZTIl"]=34156;var __ZTIx=Module["__ZTIx"]=34260;var __ZTIy=Module["__ZTIy"]=34312;var __ZTId=Module["__ZTId"]=34576;var __ZTINSt3__212basic_stringIhNS_11char_traitsIhEENS_9allocatorIhEEEE=Module["__ZTINSt3__212basic_stringIhNS_11char_traitsIhEENS_9allocatorIhEEEE"]=31880;var __ZTINSt3__212basic_stringIwNS_11char_traitsIwEENS_9allocatorIwEEEE=Module["__ZTINSt3__212basic_stringIwNS_11char_traitsIwEENS_9allocatorIwEEEE"]=31952;var __ZTINSt3__212basic_stringIDsNS_11char_traitsIDsEENS_9allocatorIDsEEEE=Module["__ZTINSt3__212basic_stringIDsNS_11char_traitsIDsEENS_9allocatorIDsEEEE"]=32028;var __ZTINSt3__212basic_stringIDiNS_11char_traitsIDiEENS_9allocatorIDiEEEE=Module["__ZTINSt3__212basic_stringIDiNS_11char_traitsIDiEENS_9allocatorIDiEEEE"]=32104;var __ZTSNSt3__212basic_stringIhNS_11char_traitsIhEENS_9allocatorIhEEEE=Module["__ZTSNSt3__212basic_stringIhNS_11char_traitsIhEENS_9allocatorIhEEEE"]=31816;var __ZTSNSt3__212basic_stringIwNS_11char_traitsIwEENS_9allocatorIwEEEE=Module["__ZTSNSt3__212basic_stringIwNS_11char_traitsIwEENS_9allocatorIwEEEE"]=31888;var __ZTSNSt3__212basic_stringIDsNS_11char_traitsIDsEENS_9allocatorIDsEEEE=Module["__ZTSNSt3__212basic_stringIDsNS_11char_traitsIDsEENS_9allocatorIDsEEEE"]=31960;var __ZTSNSt3__212basic_stringIDiNS_11char_traitsIDiEENS_9allocatorIDiEEEE=Module["__ZTSNSt3__212basic_stringIDiNS_11char_traitsIDiEENS_9allocatorIDiEEEE"]=32036;var __ZTVSt11logic_error=Module["__ZTVSt11logic_error"]=35588;var __ZTVSt9exception=Module["__ZTVSt9exception"]=35424;var __ZTVSt13runtime_error=Module["__ZTVSt13runtime_error"]=35608;var __ZTISt9exception=Module["__ZTISt9exception"]=35460;var ___cxa_unexpected_handler=Module["___cxa_unexpected_handler"]=52728;var ___cxa_terminate_handler=Module["___cxa_terminate_handler"]=52724;var ___cxa_new_handler=Module["___cxa_new_handler"]=55004;var __ZTIN10__cxxabiv116__shim_type_infoE=Module["__ZTIN10__cxxabiv116__shim_type_infoE"]=33188;var __ZTIN10__cxxabiv117__class_type_infoE=Module["__ZTIN10__cxxabiv117__class_type_infoE"]=33236;var __ZTIN10__cxxabiv117__pbase_type_infoE=Module["__ZTIN10__cxxabiv117__pbase_type_infoE"]=33284;var __ZTIDn=Module["__ZTIDn"]=33632;var __ZTIN10__cxxabiv119__pointer_type_infoE=Module["__ZTIN10__cxxabiv119__pointer_type_infoE"]=33332;var __ZTIN10__cxxabiv120__function_type_infoE=Module["__ZTIN10__cxxabiv120__function_type_infoE"]=33384;var __ZTIN10__cxxabiv129__pointer_to_member_type_infoE=Module["__ZTIN10__cxxabiv129__pointer_to_member_type_infoE"]=33444;var __ZTSN10__cxxabiv116__shim_type_infoE=Module["__ZTSN10__cxxabiv116__shim_type_infoE"]=33152;var __ZTISt9type_info=Module["__ZTISt9type_info"]=36124;var __ZTSN10__cxxabiv117__class_type_infoE=Module["__ZTSN10__cxxabiv117__class_type_infoE"]=33200;var __ZTSN10__cxxabiv117__pbase_type_infoE=Module["__ZTSN10__cxxabiv117__pbase_type_infoE"]=33248;var __ZTSN10__cxxabiv119__pointer_type_infoE=Module["__ZTSN10__cxxabiv119__pointer_type_infoE"]=33296;var __ZTSN10__cxxabiv120__function_type_infoE=Module["__ZTSN10__cxxabiv120__function_type_infoE"]=33344;var __ZTSN10__cxxabiv129__pointer_to_member_type_infoE=Module["__ZTSN10__cxxabiv129__pointer_to_member_type_infoE"]=33396;var __ZTVN10__cxxabiv116__shim_type_infoE=Module["__ZTVN10__cxxabiv116__shim_type_infoE"]=33468;var __ZTVN10__cxxabiv123__fundamental_type_infoE=Module["__ZTVN10__cxxabiv123__fundamental_type_infoE"]=33496;var __ZTIN10__cxxabiv123__fundamental_type_infoE=Module["__ZTIN10__cxxabiv123__fundamental_type_infoE"]=33564;var __ZTSN10__cxxabiv123__fundamental_type_infoE=Module["__ZTSN10__cxxabiv123__fundamental_type_infoE"]=33524;var __ZTSv=Module["__ZTSv"]=33576;var __ZTSPv=Module["__ZTSPv"]=33588;var __ZTIPv=Module["__ZTIPv"]=33592;var __ZTSPKv=Module["__ZTSPKv"]=33608;var __ZTIPKv=Module["__ZTIPKv"]=33612;var __ZTSDn=Module["__ZTSDn"]=33628;var __ZTSPDn=Module["__ZTSPDn"]=33640;var __ZTIPDn=Module["__ZTIPDn"]=33644;var __ZTSPKDn=Module["__ZTSPKDn"]=33660;var __ZTIPKDn=Module["__ZTIPKDn"]=33668;var __ZTSb=Module["__ZTSb"]=33684;var __ZTSPb=Module["__ZTSPb"]=33696;var __ZTIPb=Module["__ZTIPb"]=33700;var __ZTSPKb=Module["__ZTSPKb"]=33716;var __ZTIPKb=Module["__ZTIPKb"]=33720;var __ZTSw=Module["__ZTSw"]=33736;var __ZTIw=Module["__ZTIw"]=33740;var __ZTSPw=Module["__ZTSPw"]=33748;var __ZTIPw=Module["__ZTIPw"]=33752;var __ZTSPKw=Module["__ZTSPKw"]=33768;var __ZTIPKw=Module["__ZTIPKw"]=33772;var __ZTSc=Module["__ZTSc"]=33788;var __ZTSPc=Module["__ZTSPc"]=33800;var __ZTIPc=Module["__ZTIPc"]=33804;var __ZTSPKc=Module["__ZTSPKc"]=33820;var __ZTIPKc=Module["__ZTIPKc"]=33824;var __ZTSh=Module["__ZTSh"]=33840;var __ZTSPh=Module["__ZTSPh"]=33852;var __ZTIPh=Module["__ZTIPh"]=33856;var __ZTSPKh=Module["__ZTSPKh"]=33872;var __ZTIPKh=Module["__ZTIPKh"]=33876;var __ZTSa=Module["__ZTSa"]=33892;var __ZTSPa=Module["__ZTSPa"]=33904;var __ZTIPa=Module["__ZTIPa"]=33908;var __ZTSPKa=Module["__ZTSPKa"]=33924;var __ZTIPKa=Module["__ZTIPKa"]=33928;var __ZTSs=Module["__ZTSs"]=33944;var __ZTSPs=Module["__ZTSPs"]=33956;var __ZTIPs=Module["__ZTIPs"]=33960;var __ZTSPKs=Module["__ZTSPKs"]=33976;var __ZTIPKs=Module["__ZTIPKs"]=33980;var __ZTSt=Module["__ZTSt"]=33996;var __ZTSPt=Module["__ZTSPt"]=34008;var __ZTIPt=Module["__ZTIPt"]=34012;var __ZTSPKt=Module["__ZTSPKt"]=34028;var __ZTIPKt=Module["__ZTIPKt"]=34032;var __ZTSi=Module["__ZTSi"]=34048;var __ZTSPi=Module["__ZTSPi"]=34060;var __ZTIPi=Module["__ZTIPi"]=34064;var __ZTSPKi=Module["__ZTSPKi"]=34080;var __ZTIPKi=Module["__ZTIPKi"]=34084;var __ZTSj=Module["__ZTSj"]=34100;var __ZTSPj=Module["__ZTSPj"]=34112;var __ZTIPj=Module["__ZTIPj"]=34116;var __ZTSPKj=Module["__ZTSPKj"]=34132;var __ZTIPKj=Module["__ZTIPKj"]=34136;var __ZTSl=Module["__ZTSl"]=34152;var __ZTSPl=Module["__ZTSPl"]=34164;var __ZTIPl=Module["__ZTIPl"]=34168;var __ZTSPKl=Module["__ZTSPKl"]=34184;var __ZTIPKl=Module["__ZTIPKl"]=34188;var __ZTSm=Module["__ZTSm"]=34204;var __ZTSPm=Module["__ZTSPm"]=34216;var __ZTIPm=Module["__ZTIPm"]=34220;var __ZTSPKm=Module["__ZTSPKm"]=34236;var __ZTIPKm=Module["__ZTIPKm"]=34240;var __ZTSx=Module["__ZTSx"]=34256;var __ZTSPx=Module["__ZTSPx"]=34268;var __ZTIPx=Module["__ZTIPx"]=34272;var __ZTSPKx=Module["__ZTSPKx"]=34288;var __ZTIPKx=Module["__ZTIPKx"]=34292;var __ZTSy=Module["__ZTSy"]=34308;var __ZTSPy=Module["__ZTSPy"]=34320;var __ZTIPy=Module["__ZTIPy"]=34324;var __ZTSPKy=Module["__ZTSPKy"]=34340;var __ZTIPKy=Module["__ZTIPKy"]=34344;var __ZTSn=Module["__ZTSn"]=34360;var __ZTIn=Module["__ZTIn"]=34364;var __ZTSPn=Module["__ZTSPn"]=34372;var __ZTIPn=Module["__ZTIPn"]=34376;var __ZTSPKn=Module["__ZTSPKn"]=34392;var __ZTIPKn=Module["__ZTIPKn"]=34396;var __ZTSo=Module["__ZTSo"]=34412;var __ZTIo=Module["__ZTIo"]=34416;var __ZTSPo=Module["__ZTSPo"]=34424;var __ZTIPo=Module["__ZTIPo"]=34428;var __ZTSPKo=Module["__ZTSPKo"]=34444;var __ZTIPKo=Module["__ZTIPKo"]=34448;var __ZTSDh=Module["__ZTSDh"]=34464;var __ZTIDh=Module["__ZTIDh"]=34468;var __ZTSPDh=Module["__ZTSPDh"]=34476;var __ZTIPDh=Module["__ZTIPDh"]=34480;var __ZTSPKDh=Module["__ZTSPKDh"]=34496;var __ZTIPKDh=Module["__ZTIPKDh"]=34504;var __ZTSf=Module["__ZTSf"]=34520;var __ZTSPf=Module["__ZTSPf"]=34532;var __ZTIPf=Module["__ZTIPf"]=34536;var __ZTSPKf=Module["__ZTSPKf"]=34552;var __ZTIPKf=Module["__ZTIPKf"]=34556;var __ZTSd=Module["__ZTSd"]=34572;var __ZTSPd=Module["__ZTSPd"]=34584;var __ZTIPd=Module["__ZTIPd"]=34588;var __ZTSPKd=Module["__ZTSPKd"]=34604;var __ZTIPKd=Module["__ZTIPKd"]=34608;var __ZTSe=Module["__ZTSe"]=34624;var __ZTIe=Module["__ZTIe"]=34628;var __ZTSPe=Module["__ZTSPe"]=34636;var __ZTIPe=Module["__ZTIPe"]=34640;var __ZTSPKe=Module["__ZTSPKe"]=34656;var __ZTIPKe=Module["__ZTIPKe"]=34660;var __ZTSg=Module["__ZTSg"]=34676;var __ZTIg=Module["__ZTIg"]=34680;var __ZTSPg=Module["__ZTSPg"]=34688;var __ZTIPg=Module["__ZTIPg"]=34692;var __ZTSPKg=Module["__ZTSPKg"]=34708;var __ZTIPKg=Module["__ZTIPKg"]=34712;var __ZTSDu=Module["__ZTSDu"]=34728;var __ZTIDu=Module["__ZTIDu"]=34732;var __ZTSPDu=Module["__ZTSPDu"]=34740;var __ZTIPDu=Module["__ZTIPDu"]=34744;var __ZTSPKDu=Module["__ZTSPKDu"]=34760;var __ZTIPKDu=Module["__ZTIPKDu"]=34768;var __ZTSDs=Module["__ZTSDs"]=34784;var __ZTIDs=Module["__ZTIDs"]=34788;var __ZTSPDs=Module["__ZTSPDs"]=34796;var __ZTIPDs=Module["__ZTIPDs"]=34800;var __ZTSPKDs=Module["__ZTSPKDs"]=34816;var __ZTIPKDs=Module["__ZTIPKDs"]=34824;var __ZTSDi=Module["__ZTSDi"]=34840;var __ZTIDi=Module["__ZTIDi"]=34844;var __ZTSPDi=Module["__ZTSPDi"]=34852;var __ZTIPDi=Module["__ZTIPDi"]=34856;var __ZTSPKDi=Module["__ZTSPKDi"]=34872;var __ZTIPKDi=Module["__ZTIPKDi"]=34880;var __ZTVN10__cxxabiv117__array_type_infoE=Module["__ZTVN10__cxxabiv117__array_type_infoE"]=34896;var __ZTIN10__cxxabiv117__array_type_infoE=Module["__ZTIN10__cxxabiv117__array_type_infoE"]=34960;var __ZTSN10__cxxabiv117__array_type_infoE=Module["__ZTSN10__cxxabiv117__array_type_infoE"]=34924;var __ZTVN10__cxxabiv120__function_type_infoE=Module["__ZTVN10__cxxabiv120__function_type_infoE"]=34972;var __ZTVN10__cxxabiv116__enum_type_infoE=Module["__ZTVN10__cxxabiv116__enum_type_infoE"]=35e3;var __ZTIN10__cxxabiv116__enum_type_infoE=Module["__ZTIN10__cxxabiv116__enum_type_infoE"]=35064;var __ZTSN10__cxxabiv116__enum_type_infoE=Module["__ZTSN10__cxxabiv116__enum_type_infoE"]=35028;var __ZTIN10__cxxabiv120__si_class_type_infoE=Module["__ZTIN10__cxxabiv120__si_class_type_infoE"]=35196;var __ZTSN10__cxxabiv120__si_class_type_infoE=Module["__ZTSN10__cxxabiv120__si_class_type_infoE"]=35156;var __ZTIN10__cxxabiv121__vmi_class_type_infoE=Module["__ZTIN10__cxxabiv121__vmi_class_type_infoE"]=35288;var __ZTSN10__cxxabiv121__vmi_class_type_infoE=Module["__ZTSN10__cxxabiv121__vmi_class_type_infoE"]=35248;var __ZTVN10__cxxabiv117__pbase_type_infoE=Module["__ZTVN10__cxxabiv117__pbase_type_infoE"]=35300;var __ZTVN10__cxxabiv129__pointer_to_member_type_infoE=Module["__ZTVN10__cxxabiv129__pointer_to_member_type_infoE"]=35356;var __ZTVSt9bad_alloc=Module["__ZTVSt9bad_alloc"]=35384;var __ZTVSt20bad_array_new_length=Module["__ZTVSt20bad_array_new_length"]=35404;var __ZTISt9bad_alloc=Module["__ZTISt9bad_alloc"]=35536;var __ZTSSt9exception=Module["__ZTSSt9exception"]=35444;var __ZTVSt13bad_exception=Module["__ZTVSt13bad_exception"]=35468;var __ZTISt13bad_exception=Module["__ZTISt13bad_exception"]=35508;var __ZTSSt13bad_exception=Module["__ZTSSt13bad_exception"]=35488;var __ZTSSt9bad_alloc=Module["__ZTSSt9bad_alloc"]=35520;var __ZTSSt20bad_array_new_length=Module["__ZTSSt20bad_array_new_length"]=35548;var __ZTISt11logic_error=Module["__ZTISt11logic_error"]=35684;var __ZTISt13runtime_error=Module["__ZTISt13runtime_error"]=35924;var __ZTVSt12domain_error=Module["__ZTVSt12domain_error"]=35628;var __ZTISt12domain_error=Module["__ZTISt12domain_error"]=35696;var __ZTSSt12domain_error=Module["__ZTSSt12domain_error"]=35648;var __ZTSSt11logic_error=Module["__ZTSSt11logic_error"]=35665;var __ZTVSt16invalid_argument=Module["__ZTVSt16invalid_argument"]=35708;var __ZTISt16invalid_argument=Module["__ZTISt16invalid_argument"]=35752;var __ZTSSt16invalid_argument=Module["__ZTSSt16invalid_argument"]=35728;var __ZTSSt12length_error=Module["__ZTSSt12length_error"]=35784;var __ZTSSt12out_of_range=Module["__ZTSSt12out_of_range"]=35836;var __ZTVSt11range_error=Module["__ZTVSt11range_error"]=35868;var __ZTISt11range_error=Module["__ZTISt11range_error"]=35936;var __ZTSSt11range_error=Module["__ZTSSt11range_error"]=35888;var __ZTSSt13runtime_error=Module["__ZTSSt13runtime_error"]=35904;var __ZTVSt14overflow_error=Module["__ZTVSt14overflow_error"]=35948;var __ZTISt14overflow_error=Module["__ZTISt14overflow_error"]=35988;var __ZTSSt14overflow_error=Module["__ZTSSt14overflow_error"]=35968;var __ZTVSt15underflow_error=Module["__ZTVSt15underflow_error"]=36e3;var __ZTISt15underflow_error=Module["__ZTISt15underflow_error"]=36040;var __ZTSSt15underflow_error=Module["__ZTSSt15underflow_error"]=36020;var __ZTVSt8bad_cast=Module["__ZTVSt8bad_cast"]=36052;var __ZTVSt10bad_typeid=Module["__ZTVSt10bad_typeid"]=36072;var __ZTISt8bad_cast=Module["__ZTISt8bad_cast"]=36144;var __ZTISt10bad_typeid=Module["__ZTISt10bad_typeid"]=36172;var __ZTVSt9type_info=Module["__ZTVSt9type_info"]=36092;var __ZTSSt9type_info=Module["__ZTSSt9type_info"]=36108;var __ZTSSt8bad_cast=Module["__ZTSSt8bad_cast"]=36132;var __ZTSSt10bad_typeid=Module["__ZTSSt10bad_typeid"]=36156;var calledRun;dependenciesFulfilled=function runCaller(){if(!calledRun)run();if(!calledRun)dependenciesFulfilled=runCaller};function run(){if(runDependencies>0){return}preRun();if(runDependencies>0){return}function doRun(){if(calledRun)return;calledRun=true;Module["calledRun"]=true;if(ABORT)return;initRuntime();Module["onRuntimeInitialized"]?.();postRun()}if(Module["setStatus"]){Module["setStatus"]("Running...");setTimeout(function(){setTimeout(function(){Module["setStatus"]("")},1);doRun()},1)}else{doRun()}}if(Module["preInit"]){if(typeof Module["preInit"]=="function")Module["preInit"]=[Module["preInit"]];while(Module["preInit"].length>0){Module["preInit"].pop()()}}run(); +var Module=typeof Module!="undefined"?Module:{};var ENVIRONMENT_IS_WEB=typeof window=="object";var ENVIRONMENT_IS_WORKER=typeof importScripts=="function";var ENVIRONMENT_IS_NODE=typeof process=="object"&&typeof process.versions=="object"&&typeof process.versions.node=="string";if(ENVIRONMENT_IS_NODE){}var moduleOverrides=Object.assign({},Module);var arguments_=[];var thisProgram="./this.program";var quit_=(status,toThrow)=>{throw toThrow};var scriptDirectory="";function locateFile(path){if(Module["locateFile"]){return Module["locateFile"](path,scriptDirectory)}return scriptDirectory+path}var readAsync,readBinary;if(ENVIRONMENT_IS_NODE){var fs=require("fs");var nodePath=require("path");scriptDirectory=__dirname+"/";readBinary=filename=>{filename=isFileURI(filename)?new URL(filename):nodePath.normalize(filename);var ret=fs.readFileSync(filename);return ret};readAsync=(filename,binary=true)=>{filename=isFileURI(filename)?new URL(filename):nodePath.normalize(filename);return new Promise((resolve,reject)=>{fs.readFile(filename,binary?undefined:"utf8",(err,data)=>{if(err)reject(err);else resolve(binary?data.buffer:data)})})};if(!Module["thisProgram"]&&process.argv.length>1){thisProgram=process.argv[1].replace(/\\/g,"/")}arguments_=process.argv.slice(2);if(typeof module!="undefined"){module["exports"]=Module}process.on("uncaughtException",ex=>{if(ex!=="unwind"&&!(ex instanceof ExitStatus)&&!(ex.context instanceof ExitStatus)){throw ex}});quit_=(status,toThrow)=>{process.exitCode=status;throw toThrow}}else if(ENVIRONMENT_IS_WEB||ENVIRONMENT_IS_WORKER){if(ENVIRONMENT_IS_WORKER){scriptDirectory=self.location.href}else if(typeof document!="undefined"&&document.currentScript){scriptDirectory=document.currentScript.src}if(scriptDirectory.startsWith("blob:")){scriptDirectory=""}else{scriptDirectory=scriptDirectory.substr(0,scriptDirectory.replace(/[?#].*/,"").lastIndexOf("/")+1)}{if(ENVIRONMENT_IS_WORKER){readBinary=url=>{var xhr=new XMLHttpRequest;xhr.open("GET",url,false);xhr.responseType="arraybuffer";xhr.send(null);return new Uint8Array(xhr.response)}}readAsync=url=>{if(isFileURI(url)){return new Promise((reject,resolve)=>{var xhr=new XMLHttpRequest;xhr.open("GET",url,true);xhr.responseType="arraybuffer";xhr.onload=()=>{if(xhr.status==200||xhr.status==0&&xhr.response){resolve(xhr.response)}reject(xhr.status)};xhr.onerror=reject;xhr.send(null)})}return fetch(url,{credentials:"same-origin"}).then(response=>{if(response.ok){return response.arrayBuffer()}return Promise.reject(new Error(response.status+" : "+response.url))})}}}else{}var out=Module["print"]||console.log.bind(console);var err=Module["printErr"]||console.error.bind(console);Object.assign(Module,moduleOverrides);moduleOverrides=null;if(Module["arguments"])arguments_=Module["arguments"];if(Module["thisProgram"])thisProgram=Module["thisProgram"];if(Module["quit"])quit_=Module["quit"];var wasmBinary;if(Module["wasmBinary"])wasmBinary=Module["wasmBinary"];var wasmMemory;var ABORT=false;var EXITSTATUS;var HEAP8,HEAPU8,HEAP16,HEAPU16,HEAP32,HEAPU32,HEAPF32,HEAPF64;function updateMemoryViews(){var b=wasmMemory.buffer;Module["HEAP8"]=HEAP8=new Int8Array(b);Module["HEAP16"]=HEAP16=new Int16Array(b);Module["HEAPU8"]=HEAPU8=new Uint8Array(b);Module["HEAPU16"]=HEAPU16=new Uint16Array(b);Module["HEAP32"]=HEAP32=new Int32Array(b);Module["HEAPU32"]=HEAPU32=new Uint32Array(b);Module["HEAPF32"]=HEAPF32=new Float32Array(b);Module["HEAPF64"]=HEAPF64=new Float64Array(b)}var __ATPRERUN__=[];var __ATINIT__=[];var __ATPOSTRUN__=[];var runtimeInitialized=false;function preRun(){if(Module["preRun"]){if(typeof Module["preRun"]=="function")Module["preRun"]=[Module["preRun"]];while(Module["preRun"].length){addOnPreRun(Module["preRun"].shift())}}callRuntimeCallbacks(__ATPRERUN__)}function initRuntime(){runtimeInitialized=true;callRuntimeCallbacks(__ATINIT__)}function postRun(){if(Module["postRun"]){if(typeof Module["postRun"]=="function")Module["postRun"]=[Module["postRun"]];while(Module["postRun"].length){addOnPostRun(Module["postRun"].shift())}}callRuntimeCallbacks(__ATPOSTRUN__)}function addOnPreRun(cb){__ATPRERUN__.unshift(cb)}function addOnInit(cb){__ATINIT__.unshift(cb)}function addOnPostRun(cb){__ATPOSTRUN__.unshift(cb)}var runDependencies=0;var runDependencyWatcher=null;var dependenciesFulfilled=null;function addRunDependency(id){runDependencies++;Module["monitorRunDependencies"]?.(runDependencies)}function removeRunDependency(id){runDependencies--;Module["monitorRunDependencies"]?.(runDependencies);if(runDependencies==0){if(runDependencyWatcher!==null){clearInterval(runDependencyWatcher);runDependencyWatcher=null}if(dependenciesFulfilled){var callback=dependenciesFulfilled;dependenciesFulfilled=null;callback()}}}function abort(what){Module["onAbort"]?.(what);what="Aborted("+what+")";err(what);ABORT=true;EXITSTATUS=1;what+=". Build with -sASSERTIONS for more info.";var e=new WebAssembly.RuntimeError(what);throw e}var dataURIPrefix="data:application/octet-stream;base64,";var isDataURI=filename=>filename.startsWith(dataURIPrefix);var isFileURI=filename=>filename.startsWith("file://");function findWasmBinary(){var f="index.wasm";if(!isDataURI(f)){return locateFile(f)}return f}var wasmBinaryFile;function getBinarySync(file){if(file==wasmBinaryFile&&wasmBinary){return new Uint8Array(wasmBinary)}if(readBinary){return readBinary(file)}throw"both async and sync fetching of the wasm failed"}function getBinaryPromise(binaryFile){if(!wasmBinary){return readAsync(binaryFile).then(response=>new Uint8Array(response),()=>getBinarySync(binaryFile))}return Promise.resolve().then(()=>getBinarySync(binaryFile))}function instantiateArrayBuffer(binaryFile,imports,receiver){return getBinaryPromise(binaryFile).then(binary=>WebAssembly.instantiate(binary,imports)).then(receiver,reason=>{err(`failed to asynchronously prepare wasm: ${reason}`);abort(reason)})}function instantiateAsync(binary,binaryFile,imports,callback){if(!binary&&typeof WebAssembly.instantiateStreaming=="function"&&!isDataURI(binaryFile)&&!isFileURI(binaryFile)&&!ENVIRONMENT_IS_NODE&&typeof fetch=="function"){return fetch(binaryFile,{credentials:"same-origin"}).then(response=>{var result=WebAssembly.instantiateStreaming(response,imports);return result.then(callback,function(reason){err(`wasm streaming compile failed: ${reason}`);err("falling back to ArrayBuffer instantiation");return instantiateArrayBuffer(binaryFile,imports,callback)})})}return instantiateArrayBuffer(binaryFile,imports,callback)}function getWasmImports(){return{a:wasmImports}}function createWasm(){var info=getWasmImports();function receiveInstance(instance,module){wasmExports=instance.exports;wasmMemory=wasmExports["w"];updateMemoryViews();wasmTable=wasmExports["D"];addOnInit(wasmExports["x"]);removeRunDependency("wasm-instantiate");return wasmExports}addRunDependency("wasm-instantiate");function receiveInstantiationResult(result){receiveInstance(result["instance"])}if(Module["instantiateWasm"]){try{return Module["instantiateWasm"](info,receiveInstance)}catch(e){err(`Module.instantiateWasm callback failed with error: ${e}`);return false}}if(!wasmBinaryFile)wasmBinaryFile=findWasmBinary();instantiateAsync(wasmBinary,wasmBinaryFile,info,receiveInstantiationResult);return{}}function ExitStatus(status){this.name="ExitStatus";this.message=`Program terminated with exit(${status})`;this.status=status}var callRuntimeCallbacks=callbacks=>{while(callbacks.length>0){callbacks.shift()(Module)}};var noExitRuntime=Module["noExitRuntime"]||true;class ExceptionInfo{constructor(excPtr){this.excPtr=excPtr;this.ptr=excPtr-24}set_type(type){HEAPU32[this.ptr+4>>2]=type}get_type(){return HEAPU32[this.ptr+4>>2]}set_destructor(destructor){HEAPU32[this.ptr+8>>2]=destructor}get_destructor(){return HEAPU32[this.ptr+8>>2]}set_caught(caught){caught=caught?1:0;HEAP8[this.ptr+12]=caught}get_caught(){return HEAP8[this.ptr+12]!=0}set_rethrown(rethrown){rethrown=rethrown?1:0;HEAP8[this.ptr+13]=rethrown}get_rethrown(){return HEAP8[this.ptr+13]!=0}init(type,destructor){this.set_adjusted_ptr(0);this.set_type(type);this.set_destructor(destructor)}set_adjusted_ptr(adjustedPtr){HEAPU32[this.ptr+16>>2]=adjustedPtr}get_adjusted_ptr(){return HEAPU32[this.ptr+16>>2]}get_exception_ptr(){var isPointer=___cxa_is_pointer_type(this.get_type());if(isPointer){return HEAPU32[this.excPtr>>2]}var adjusted=this.get_adjusted_ptr();if(adjusted!==0)return adjusted;return this.excPtr}}var exceptionLast=0;var uncaughtExceptionCount=0;var ___cxa_throw=(ptr,type,destructor)=>{var info=new ExceptionInfo(ptr);info.init(type,destructor);exceptionLast=ptr;uncaughtExceptionCount++;throw exceptionLast};var __abort_js=()=>{abort("")};var __embind_register_bigint=(primitiveType,name,size,minRange,maxRange)=>{};var embind_init_charCodes=()=>{var codes=new Array(256);for(var i=0;i<256;++i){codes[i]=String.fromCharCode(i)}embind_charCodes=codes};var embind_charCodes;var readLatin1String=ptr=>{var ret="";var c=ptr;while(HEAPU8[c]){ret+=embind_charCodes[HEAPU8[c++]]}return ret};var awaitingDependencies={};var registeredTypes={};var typeDependencies={};var BindingError;var throwBindingError=message=>{throw new BindingError(message)};var InternalError;var throwInternalError=message=>{throw new InternalError(message)};var whenDependentTypesAreResolved=(myTypes,dependentTypes,getTypeConverters)=>{myTypes.forEach(function(type){typeDependencies[type]=dependentTypes});function onComplete(typeConverters){var myTypeConverters=getTypeConverters(typeConverters);if(myTypeConverters.length!==myTypes.length){throwInternalError("Mismatched type converter count")}for(var i=0;i{if(registeredTypes.hasOwnProperty(dt)){typeConverters[i]=registeredTypes[dt]}else{unregisteredTypes.push(dt);if(!awaitingDependencies.hasOwnProperty(dt)){awaitingDependencies[dt]=[]}awaitingDependencies[dt].push(()=>{typeConverters[i]=registeredTypes[dt];++registered;if(registered===unregisteredTypes.length){onComplete(typeConverters)}})}});if(0===unregisteredTypes.length){onComplete(typeConverters)}};function sharedRegisterType(rawType,registeredInstance,options={}){var name=registeredInstance.name;if(!rawType){throwBindingError(`type "${name}" must have a positive integer typeid pointer`)}if(registeredTypes.hasOwnProperty(rawType)){if(options.ignoreDuplicateRegistrations){return}else{throwBindingError(`Cannot register type '${name}' twice`)}}registeredTypes[rawType]=registeredInstance;delete typeDependencies[rawType];if(awaitingDependencies.hasOwnProperty(rawType)){var callbacks=awaitingDependencies[rawType];delete awaitingDependencies[rawType];callbacks.forEach(cb=>cb())}}function registerType(rawType,registeredInstance,options={}){if(!("argPackAdvance"in registeredInstance)){throw new TypeError("registerType registeredInstance requires argPackAdvance")}return sharedRegisterType(rawType,registeredInstance,options)}var GenericWireTypeSize=8;var __embind_register_bool=(rawType,name,trueValue,falseValue)=>{name=readLatin1String(name);registerType(rawType,{name:name,fromWireType:function(wt){return!!wt},toWireType:function(destructors,o){return o?trueValue:falseValue},argPackAdvance:GenericWireTypeSize,readValueFromPointer:function(pointer){return this["fromWireType"](HEAPU8[pointer])},destructorFunction:null})};var shallowCopyInternalPointer=o=>({count:o.count,deleteScheduled:o.deleteScheduled,preservePointerOnDelete:o.preservePointerOnDelete,ptr:o.ptr,ptrType:o.ptrType,smartPtr:o.smartPtr,smartPtrType:o.smartPtrType});var throwInstanceAlreadyDeleted=obj=>{function getInstanceTypeName(handle){return handle.$$.ptrType.registeredClass.name}throwBindingError(getInstanceTypeName(obj)+" instance already deleted")};var finalizationRegistry=false;var detachFinalizer=handle=>{};var runDestructor=$$=>{if($$.smartPtr){$$.smartPtrType.rawDestructor($$.smartPtr)}else{$$.ptrType.registeredClass.rawDestructor($$.ptr)}};var releaseClassHandle=$$=>{$$.count.value-=1;var toDelete=0===$$.count.value;if(toDelete){runDestructor($$)}};var downcastPointer=(ptr,ptrClass,desiredClass)=>{if(ptrClass===desiredClass){return ptr}if(undefined===desiredClass.baseClass){return null}var rv=downcastPointer(ptr,ptrClass,desiredClass.baseClass);if(rv===null){return null}return desiredClass.downcast(rv)};var registeredPointers={};var getInheritedInstanceCount=()=>Object.keys(registeredInstances).length;var getLiveInheritedInstances=()=>{var rv=[];for(var k in registeredInstances){if(registeredInstances.hasOwnProperty(k)){rv.push(registeredInstances[k])}}return rv};var deletionQueue=[];var flushPendingDeletes=()=>{while(deletionQueue.length){var obj=deletionQueue.pop();obj.$$.deleteScheduled=false;obj["delete"]()}};var delayFunction;var setDelayFunction=fn=>{delayFunction=fn;if(deletionQueue.length&&delayFunction){delayFunction(flushPendingDeletes)}};var init_embind=()=>{Module["getInheritedInstanceCount"]=getInheritedInstanceCount;Module["getLiveInheritedInstances"]=getLiveInheritedInstances;Module["flushPendingDeletes"]=flushPendingDeletes;Module["setDelayFunction"]=setDelayFunction};var registeredInstances={};var getBasestPointer=(class_,ptr)=>{if(ptr===undefined){throwBindingError("ptr should not be undefined")}while(class_.baseClass){ptr=class_.upcast(ptr);class_=class_.baseClass}return ptr};var getInheritedInstance=(class_,ptr)=>{ptr=getBasestPointer(class_,ptr);return registeredInstances[ptr]};var makeClassHandle=(prototype,record)=>{if(!record.ptrType||!record.ptr){throwInternalError("makeClassHandle requires ptr and ptrType")}var hasSmartPtrType=!!record.smartPtrType;var hasSmartPtr=!!record.smartPtr;if(hasSmartPtrType!==hasSmartPtr){throwInternalError("Both smartPtrType and smartPtr must be specified")}record.count={value:1};return attachFinalizer(Object.create(prototype,{$$:{value:record,writable:true}}))};function RegisteredPointer_fromWireType(ptr){var rawPointer=this.getPointee(ptr);if(!rawPointer){this.destructor(ptr);return null}var registeredInstance=getInheritedInstance(this.registeredClass,rawPointer);if(undefined!==registeredInstance){if(0===registeredInstance.$$.count.value){registeredInstance.$$.ptr=rawPointer;registeredInstance.$$.smartPtr=ptr;return registeredInstance["clone"]()}else{var rv=registeredInstance["clone"]();this.destructor(ptr);return rv}}function makeDefaultHandle(){if(this.isSmartPointer){return makeClassHandle(this.registeredClass.instancePrototype,{ptrType:this.pointeeType,ptr:rawPointer,smartPtrType:this,smartPtr:ptr})}else{return makeClassHandle(this.registeredClass.instancePrototype,{ptrType:this,ptr:ptr})}}var actualType=this.registeredClass.getActualType(rawPointer);var registeredPointerRecord=registeredPointers[actualType];if(!registeredPointerRecord){return makeDefaultHandle.call(this)}var toType;if(this.isConst){toType=registeredPointerRecord.constPointerType}else{toType=registeredPointerRecord.pointerType}var dp=downcastPointer(rawPointer,this.registeredClass,toType.registeredClass);if(dp===null){return makeDefaultHandle.call(this)}if(this.isSmartPointer){return makeClassHandle(toType.registeredClass.instancePrototype,{ptrType:toType,ptr:dp,smartPtrType:this,smartPtr:ptr})}else{return makeClassHandle(toType.registeredClass.instancePrototype,{ptrType:toType,ptr:dp})}}var attachFinalizer=handle=>{if("undefined"===typeof FinalizationRegistry){attachFinalizer=handle=>handle;return handle}finalizationRegistry=new FinalizationRegistry(info=>{releaseClassHandle(info.$$)});attachFinalizer=handle=>{var $$=handle.$$;var hasSmartPtr=!!$$.smartPtr;if(hasSmartPtr){var info={$$:$$};finalizationRegistry.register(handle,info,handle)}return handle};detachFinalizer=handle=>finalizationRegistry.unregister(handle);return attachFinalizer(handle)};var init_ClassHandle=()=>{Object.assign(ClassHandle.prototype,{isAliasOf(other){if(!(this instanceof ClassHandle)){return false}if(!(other instanceof ClassHandle)){return false}var leftClass=this.$$.ptrType.registeredClass;var left=this.$$.ptr;other.$$=other.$$;var rightClass=other.$$.ptrType.registeredClass;var right=other.$$.ptr;while(leftClass.baseClass){left=leftClass.upcast(left);leftClass=leftClass.baseClass}while(rightClass.baseClass){right=rightClass.upcast(right);rightClass=rightClass.baseClass}return leftClass===rightClass&&left===right},clone(){if(!this.$$.ptr){throwInstanceAlreadyDeleted(this)}if(this.$$.preservePointerOnDelete){this.$$.count.value+=1;return this}else{var clone=attachFinalizer(Object.create(Object.getPrototypeOf(this),{$$:{value:shallowCopyInternalPointer(this.$$)}}));clone.$$.count.value+=1;clone.$$.deleteScheduled=false;return clone}},delete(){if(!this.$$.ptr){throwInstanceAlreadyDeleted(this)}if(this.$$.deleteScheduled&&!this.$$.preservePointerOnDelete){throwBindingError("Object already scheduled for deletion")}detachFinalizer(this);releaseClassHandle(this.$$);if(!this.$$.preservePointerOnDelete){this.$$.smartPtr=undefined;this.$$.ptr=undefined}},isDeleted(){return!this.$$.ptr},deleteLater(){if(!this.$$.ptr){throwInstanceAlreadyDeleted(this)}if(this.$$.deleteScheduled&&!this.$$.preservePointerOnDelete){throwBindingError("Object already scheduled for deletion")}deletionQueue.push(this);if(deletionQueue.length===1&&delayFunction){delayFunction(flushPendingDeletes)}this.$$.deleteScheduled=true;return this}})};function ClassHandle(){}var createNamedFunction=(name,body)=>Object.defineProperty(body,"name",{value:name});var ensureOverloadTable=(proto,methodName,humanName)=>{if(undefined===proto[methodName].overloadTable){var prevFunc=proto[methodName];proto[methodName]=function(...args){if(!proto[methodName].overloadTable.hasOwnProperty(args.length)){throwBindingError(`Function '${humanName}' called with an invalid number of arguments (${args.length}) - expects one of (${proto[methodName].overloadTable})!`)}return proto[methodName].overloadTable[args.length].apply(this,args)};proto[methodName].overloadTable=[];proto[methodName].overloadTable[prevFunc.argCount]=prevFunc}};var exposePublicSymbol=(name,value,numArguments)=>{if(Module.hasOwnProperty(name)){if(undefined===numArguments||undefined!==Module[name].overloadTable&&undefined!==Module[name].overloadTable[numArguments]){throwBindingError(`Cannot register public name '${name}' twice`)}ensureOverloadTable(Module,name,name);if(Module.hasOwnProperty(numArguments)){throwBindingError(`Cannot register multiple overloads of a function with the same number of arguments (${numArguments})!`)}Module[name].overloadTable[numArguments]=value}else{Module[name]=value;if(undefined!==numArguments){Module[name].numArguments=numArguments}}};var char_0=48;var char_9=57;var makeLegalFunctionName=name=>{if(undefined===name){return"_unknown"}name=name.replace(/[^a-zA-Z0-9_]/g,"$");var f=name.charCodeAt(0);if(f>=char_0&&f<=char_9){return`_${name}`}return name};function RegisteredClass(name,constructor,instancePrototype,rawDestructor,baseClass,getActualType,upcast,downcast){this.name=name;this.constructor=constructor;this.instancePrototype=instancePrototype;this.rawDestructor=rawDestructor;this.baseClass=baseClass;this.getActualType=getActualType;this.upcast=upcast;this.downcast=downcast;this.pureVirtualFunctions=[]}var upcastPointer=(ptr,ptrClass,desiredClass)=>{while(ptrClass!==desiredClass){if(!ptrClass.upcast){throwBindingError(`Expected null or instance of ${desiredClass.name}, got an instance of ${ptrClass.name}`)}ptr=ptrClass.upcast(ptr);ptrClass=ptrClass.baseClass}return ptr};function constNoSmartPtrRawPointerToWireType(destructors,handle){if(handle===null){if(this.isReference){throwBindingError(`null is not a valid ${this.name}`)}return 0}if(!handle.$$){throwBindingError(`Cannot pass "${embindRepr(handle)}" as a ${this.name}`)}if(!handle.$$.ptr){throwBindingError(`Cannot pass deleted object as a pointer of type ${this.name}`)}var handleClass=handle.$$.ptrType.registeredClass;var ptr=upcastPointer(handle.$$.ptr,handleClass,this.registeredClass);return ptr}function genericPointerToWireType(destructors,handle){var ptr;if(handle===null){if(this.isReference){throwBindingError(`null is not a valid ${this.name}`)}if(this.isSmartPointer){ptr=this.rawConstructor();if(destructors!==null){destructors.push(this.rawDestructor,ptr)}return ptr}else{return 0}}if(!handle||!handle.$$){throwBindingError(`Cannot pass "${embindRepr(handle)}" as a ${this.name}`)}if(!handle.$$.ptr){throwBindingError(`Cannot pass deleted object as a pointer of type ${this.name}`)}if(!this.isConst&&handle.$$.ptrType.isConst){throwBindingError(`Cannot convert argument of type ${handle.$$.smartPtrType?handle.$$.smartPtrType.name:handle.$$.ptrType.name} to parameter type ${this.name}`)}var handleClass=handle.$$.ptrType.registeredClass;ptr=upcastPointer(handle.$$.ptr,handleClass,this.registeredClass);if(this.isSmartPointer){if(undefined===handle.$$.smartPtr){throwBindingError("Passing raw pointer to smart pointer is illegal")}switch(this.sharingPolicy){case 0:if(handle.$$.smartPtrType===this){ptr=handle.$$.smartPtr}else{throwBindingError(`Cannot convert argument of type ${handle.$$.smartPtrType?handle.$$.smartPtrType.name:handle.$$.ptrType.name} to parameter type ${this.name}`)}break;case 1:ptr=handle.$$.smartPtr;break;case 2:if(handle.$$.smartPtrType===this){ptr=handle.$$.smartPtr}else{var clonedHandle=handle["clone"]();ptr=this.rawShare(ptr,Emval.toHandle(()=>clonedHandle["delete"]()));if(destructors!==null){destructors.push(this.rawDestructor,ptr)}}break;default:throwBindingError("Unsupporting sharing policy")}}return ptr}function nonConstNoSmartPtrRawPointerToWireType(destructors,handle){if(handle===null){if(this.isReference){throwBindingError(`null is not a valid ${this.name}`)}return 0}if(!handle.$$){throwBindingError(`Cannot pass "${embindRepr(handle)}" as a ${this.name}`)}if(!handle.$$.ptr){throwBindingError(`Cannot pass deleted object as a pointer of type ${this.name}`)}if(handle.$$.ptrType.isConst){throwBindingError(`Cannot convert argument of type ${handle.$$.ptrType.name} to parameter type ${this.name}`)}var handleClass=handle.$$.ptrType.registeredClass;var ptr=upcastPointer(handle.$$.ptr,handleClass,this.registeredClass);return ptr}function readPointer(pointer){return this["fromWireType"](HEAPU32[pointer>>2])}var init_RegisteredPointer=()=>{Object.assign(RegisteredPointer.prototype,{getPointee(ptr){if(this.rawGetPointee){ptr=this.rawGetPointee(ptr)}return ptr},destructor(ptr){this.rawDestructor?.(ptr)},argPackAdvance:GenericWireTypeSize,readValueFromPointer:readPointer,fromWireType:RegisteredPointer_fromWireType})};function RegisteredPointer(name,registeredClass,isReference,isConst,isSmartPointer,pointeeType,sharingPolicy,rawGetPointee,rawConstructor,rawShare,rawDestructor){this.name=name;this.registeredClass=registeredClass;this.isReference=isReference;this.isConst=isConst;this.isSmartPointer=isSmartPointer;this.pointeeType=pointeeType;this.sharingPolicy=sharingPolicy;this.rawGetPointee=rawGetPointee;this.rawConstructor=rawConstructor;this.rawShare=rawShare;this.rawDestructor=rawDestructor;if(!isSmartPointer&®isteredClass.baseClass===undefined){if(isConst){this["toWireType"]=constNoSmartPtrRawPointerToWireType;this.destructorFunction=null}else{this["toWireType"]=nonConstNoSmartPtrRawPointerToWireType;this.destructorFunction=null}}else{this["toWireType"]=genericPointerToWireType}}var replacePublicSymbol=(name,value,numArguments)=>{if(!Module.hasOwnProperty(name)){throwInternalError("Replacing nonexistent public symbol")}if(undefined!==Module[name].overloadTable&&undefined!==numArguments){Module[name].overloadTable[numArguments]=value}else{Module[name]=value;Module[name].argCount=numArguments}};var dynCallLegacy=(sig,ptr,args)=>{sig=sig.replace(/p/g,"i");var f=Module["dynCall_"+sig];return f(ptr,...args)};var wasmTableMirror=[];var wasmTable;var getWasmTableEntry=funcPtr=>{var func=wasmTableMirror[funcPtr];if(!func){if(funcPtr>=wasmTableMirror.length)wasmTableMirror.length=funcPtr+1;wasmTableMirror[funcPtr]=func=wasmTable.get(funcPtr)}return func};var dynCall=(sig,ptr,args=[])=>{if(sig.includes("j")){return dynCallLegacy(sig,ptr,args)}var rtn=getWasmTableEntry(ptr)(...args);return rtn};var getDynCaller=(sig,ptr)=>(...args)=>dynCall(sig,ptr,args);var embind__requireFunction=(signature,rawFunction)=>{signature=readLatin1String(signature);function makeDynCaller(){if(signature.includes("j")){return getDynCaller(signature,rawFunction)}return getWasmTableEntry(rawFunction)}var fp=makeDynCaller();if(typeof fp!="function"){throwBindingError(`unknown function pointer with signature ${signature}: ${rawFunction}`)}return fp};var extendError=(baseErrorType,errorName)=>{var errorClass=createNamedFunction(errorName,function(message){this.name=errorName;this.message=message;var stack=new Error(message).stack;if(stack!==undefined){this.stack=this.toString()+"\n"+stack.replace(/^Error(:[^\n]*)?\n/,"")}});errorClass.prototype=Object.create(baseErrorType.prototype);errorClass.prototype.constructor=errorClass;errorClass.prototype.toString=function(){if(this.message===undefined){return this.name}else{return`${this.name}: ${this.message}`}};return errorClass};var UnboundTypeError;var getTypeName=type=>{var ptr=___getTypeName(type);var rv=readLatin1String(ptr);_free(ptr);return rv};var throwUnboundTypeError=(message,types)=>{var unboundTypes=[];var seen={};function visit(type){if(seen[type]){return}if(registeredTypes[type]){return}if(typeDependencies[type]){typeDependencies[type].forEach(visit);return}unboundTypes.push(type);seen[type]=true}types.forEach(visit);throw new UnboundTypeError(`${message}: `+unboundTypes.map(getTypeName).join([", "]))};var __embind_register_class=(rawType,rawPointerType,rawConstPointerType,baseClassRawType,getActualTypeSignature,getActualType,upcastSignature,upcast,downcastSignature,downcast,name,destructorSignature,rawDestructor)=>{name=readLatin1String(name);getActualType=embind__requireFunction(getActualTypeSignature,getActualType);upcast&&=embind__requireFunction(upcastSignature,upcast);downcast&&=embind__requireFunction(downcastSignature,downcast);rawDestructor=embind__requireFunction(destructorSignature,rawDestructor);var legalFunctionName=makeLegalFunctionName(name);exposePublicSymbol(legalFunctionName,function(){throwUnboundTypeError(`Cannot construct ${name} due to unbound types`,[baseClassRawType])});whenDependentTypesAreResolved([rawType,rawPointerType,rawConstPointerType],baseClassRawType?[baseClassRawType]:[],base=>{base=base[0];var baseClass;var basePrototype;if(baseClassRawType){baseClass=base.registeredClass;basePrototype=baseClass.instancePrototype}else{basePrototype=ClassHandle.prototype}var constructor=createNamedFunction(name,function(...args){if(Object.getPrototypeOf(this)!==instancePrototype){throw new BindingError("Use 'new' to construct "+name)}if(undefined===registeredClass.constructor_body){throw new BindingError(name+" has no accessible constructor")}var body=registeredClass.constructor_body[args.length];if(undefined===body){throw new BindingError(`Tried to invoke ctor of ${name} with invalid number of parameters (${args.length}) - expected (${Object.keys(registeredClass.constructor_body).toString()}) parameters instead!`)}return body.apply(this,args)});var instancePrototype=Object.create(basePrototype,{constructor:{value:constructor}});constructor.prototype=instancePrototype;var registeredClass=new RegisteredClass(name,constructor,instancePrototype,rawDestructor,baseClass,getActualType,upcast,downcast);if(registeredClass.baseClass){registeredClass.baseClass.__derivedClasses??=[];registeredClass.baseClass.__derivedClasses.push(registeredClass)}var referenceConverter=new RegisteredPointer(name,registeredClass,true,false,false);var pointerConverter=new RegisteredPointer(name+"*",registeredClass,false,false,false);var constPointerConverter=new RegisteredPointer(name+" const*",registeredClass,false,true,false);registeredPointers[rawType]={pointerType:pointerConverter,constPointerType:constPointerConverter};replacePublicSymbol(legalFunctionName,constructor);return[referenceConverter,pointerConverter,constPointerConverter]})};var heap32VectorToArray=(count,firstElement)=>{var array=[];for(var i=0;i>2])}return array};var runDestructors=destructors=>{while(destructors.length){var ptr=destructors.pop();var del=destructors.pop();del(ptr)}};function usesDestructorStack(argTypes){for(var i=1;i0?", ":"")+argsListWired}invokerFnBody+=(returns||isAsync?"var rv = ":"")+"invoker(fn"+(argsListWired.length>0?", ":"")+argsListWired+");\n";if(needsDestructorStack){invokerFnBody+="runDestructors(destructors);\n"}else{for(var i=isClassMethodFunc?1:2;i{var rawArgTypes=heap32VectorToArray(argCount,rawArgTypesAddr);invoker=embind__requireFunction(invokerSignature,invoker);whenDependentTypesAreResolved([],[rawClassType],classType=>{classType=classType[0];var humanName=`constructor ${classType.name}`;if(undefined===classType.registeredClass.constructor_body){classType.registeredClass.constructor_body=[]}if(undefined!==classType.registeredClass.constructor_body[argCount-1]){throw new BindingError(`Cannot register multiple constructors with identical number of parameters (${argCount-1}) for class '${classType.name}'! Overload resolution is currently only performed using the parameter count, not actual type info!`)}classType.registeredClass.constructor_body[argCount-1]=()=>{throwUnboundTypeError(`Cannot construct ${classType.name} due to unbound types`,rawArgTypes)};whenDependentTypesAreResolved([],rawArgTypes,argTypes=>{argTypes.splice(1,0,null);classType.registeredClass.constructor_body[argCount-1]=craftInvokerFunction(humanName,argTypes,null,invoker,rawConstructor);return[]});return[]})};var getFunctionName=signature=>{signature=signature.trim();const argsIndex=signature.indexOf("(");if(argsIndex!==-1){return signature.substr(0,argsIndex)}else{return signature}};var __embind_register_class_function=(rawClassType,methodName,argCount,rawArgTypesAddr,invokerSignature,rawInvoker,context,isPureVirtual,isAsync)=>{var rawArgTypes=heap32VectorToArray(argCount,rawArgTypesAddr);methodName=readLatin1String(methodName);methodName=getFunctionName(methodName);rawInvoker=embind__requireFunction(invokerSignature,rawInvoker);whenDependentTypesAreResolved([],[rawClassType],classType=>{classType=classType[0];var humanName=`${classType.name}.${methodName}`;if(methodName.startsWith("@@")){methodName=Symbol[methodName.substring(2)]}if(isPureVirtual){classType.registeredClass.pureVirtualFunctions.push(methodName)}function unboundTypesHandler(){throwUnboundTypeError(`Cannot call ${humanName} due to unbound types`,rawArgTypes)}var proto=classType.registeredClass.instancePrototype;var method=proto[methodName];if(undefined===method||undefined===method.overloadTable&&method.className!==classType.name&&method.argCount===argCount-2){unboundTypesHandler.argCount=argCount-2;unboundTypesHandler.className=classType.name;proto[methodName]=unboundTypesHandler}else{ensureOverloadTable(proto,methodName,humanName);proto[methodName].overloadTable[argCount-2]=unboundTypesHandler}whenDependentTypesAreResolved([],rawArgTypes,argTypes=>{var memberFunction=craftInvokerFunction(humanName,argTypes,classType,rawInvoker,context,isAsync);if(undefined===proto[methodName].overloadTable){memberFunction.argCount=argCount-2;proto[methodName]=memberFunction}else{proto[methodName].overloadTable[argCount-2]=memberFunction}return[]});return[]})};var validateThis=(this_,classType,humanName)=>{if(!(this_ instanceof Object)){throwBindingError(`${humanName} with invalid "this": ${this_}`)}if(!(this_ instanceof classType.registeredClass.constructor)){throwBindingError(`${humanName} incompatible with "this" of type ${this_.constructor.name}`)}if(!this_.$$.ptr){throwBindingError(`cannot call emscripten binding method ${humanName} on deleted object`)}return upcastPointer(this_.$$.ptr,this_.$$.ptrType.registeredClass,classType.registeredClass)};var __embind_register_class_property=(classType,fieldName,getterReturnType,getterSignature,getter,getterContext,setterArgumentType,setterSignature,setter,setterContext)=>{fieldName=readLatin1String(fieldName);getter=embind__requireFunction(getterSignature,getter);whenDependentTypesAreResolved([],[classType],classType=>{classType=classType[0];var humanName=`${classType.name}.${fieldName}`;var desc={get(){throwUnboundTypeError(`Cannot access ${humanName} due to unbound types`,[getterReturnType,setterArgumentType])},enumerable:true,configurable:true};if(setter){desc.set=()=>throwUnboundTypeError(`Cannot access ${humanName} due to unbound types`,[getterReturnType,setterArgumentType])}else{desc.set=v=>throwBindingError(humanName+" is a read-only property")}Object.defineProperty(classType.registeredClass.instancePrototype,fieldName,desc);whenDependentTypesAreResolved([],setter?[getterReturnType,setterArgumentType]:[getterReturnType],types=>{var getterReturnType=types[0];var desc={get(){var ptr=validateThis(this,classType,humanName+" getter");return getterReturnType["fromWireType"](getter(getterContext,ptr))},enumerable:true};if(setter){setter=embind__requireFunction(setterSignature,setter);var setterArgumentType=types[1];desc.set=function(v){var ptr=validateThis(this,classType,humanName+" setter");var destructors=[];setter(setterContext,ptr,setterArgumentType["toWireType"](destructors,v));runDestructors(destructors)}}Object.defineProperty(classType.registeredClass.instancePrototype,fieldName,desc);return[]});return[]})};var emval_freelist=[];var emval_handles=[];var __emval_decref=handle=>{if(handle>9&&0===--emval_handles[handle+1]){emval_handles[handle]=undefined;emval_freelist.push(handle)}};var count_emval_handles=()=>emval_handles.length/2-5-emval_freelist.length;var init_emval=()=>{emval_handles.push(0,1,undefined,1,null,1,true,1,false,1);Module["count_emval_handles"]=count_emval_handles};var Emval={toValue:handle=>{if(!handle){throwBindingError("Cannot use deleted val. handle = "+handle)}return emval_handles[handle]},toHandle:value=>{switch(value){case undefined:return 2;case null:return 4;case true:return 6;case false:return 8;default:{const handle=emval_freelist.pop()||emval_handles.length;emval_handles[handle]=value;emval_handles[handle+1]=1;return handle}}}};var EmValType={name:"emscripten::val",fromWireType:handle=>{var rv=Emval.toValue(handle);__emval_decref(handle);return rv},toWireType:(destructors,value)=>Emval.toHandle(value),argPackAdvance:GenericWireTypeSize,readValueFromPointer:readPointer,destructorFunction:null};var __embind_register_emval=rawType=>registerType(rawType,EmValType);var embindRepr=v=>{if(v===null){return"null"}var t=typeof v;if(t==="object"||t==="array"||t==="function"){return v.toString()}else{return""+v}};var floatReadValueFromPointer=(name,width)=>{switch(width){case 4:return function(pointer){return this["fromWireType"](HEAPF32[pointer>>2])};case 8:return function(pointer){return this["fromWireType"](HEAPF64[pointer>>3])};default:throw new TypeError(`invalid float width (${width}): ${name}`)}};var __embind_register_float=(rawType,name,size)=>{name=readLatin1String(name);registerType(rawType,{name:name,fromWireType:value=>value,toWireType:(destructors,value)=>value,argPackAdvance:GenericWireTypeSize,readValueFromPointer:floatReadValueFromPointer(name,size),destructorFunction:null})};var __embind_register_function=(name,argCount,rawArgTypesAddr,signature,rawInvoker,fn,isAsync)=>{var argTypes=heap32VectorToArray(argCount,rawArgTypesAddr);name=readLatin1String(name);name=getFunctionName(name);rawInvoker=embind__requireFunction(signature,rawInvoker);exposePublicSymbol(name,function(){throwUnboundTypeError(`Cannot call ${name} due to unbound types`,argTypes)},argCount-1);whenDependentTypesAreResolved([],argTypes,argTypes=>{var invokerArgsArray=[argTypes[0],null].concat(argTypes.slice(1));replacePublicSymbol(name,craftInvokerFunction(name,invokerArgsArray,null,rawInvoker,fn,isAsync),argCount-1);return[]})};var integerReadValueFromPointer=(name,width,signed)=>{switch(width){case 1:return signed?pointer=>HEAP8[pointer]:pointer=>HEAPU8[pointer];case 2:return signed?pointer=>HEAP16[pointer>>1]:pointer=>HEAPU16[pointer>>1];case 4:return signed?pointer=>HEAP32[pointer>>2]:pointer=>HEAPU32[pointer>>2];default:throw new TypeError(`invalid integer width (${width}): ${name}`)}};var __embind_register_integer=(primitiveType,name,size,minRange,maxRange)=>{name=readLatin1String(name);if(maxRange===-1){maxRange=4294967295}var fromWireType=value=>value;if(minRange===0){var bitshift=32-8*size;fromWireType=value=>value<>>bitshift}var isUnsignedType=name.includes("unsigned");var checkAssertions=(value,toTypeName)=>{};var toWireType;if(isUnsignedType){toWireType=function(destructors,value){checkAssertions(value,this.name);return value>>>0}}else{toWireType=function(destructors,value){checkAssertions(value,this.name);return value}}registerType(primitiveType,{name:name,fromWireType:fromWireType,toWireType:toWireType,argPackAdvance:GenericWireTypeSize,readValueFromPointer:integerReadValueFromPointer(name,size,minRange!==0),destructorFunction:null})};var __embind_register_memory_view=(rawType,dataTypeIndex,name)=>{var typeMapping=[Int8Array,Uint8Array,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array];var TA=typeMapping[dataTypeIndex];function decodeMemoryView(handle){var size=HEAPU32[handle>>2];var data=HEAPU32[handle+4>>2];return new TA(HEAP8.buffer,data,size)}name=readLatin1String(name);registerType(rawType,{name:name,fromWireType:decodeMemoryView,argPackAdvance:GenericWireTypeSize,readValueFromPointer:decodeMemoryView},{ignoreDuplicateRegistrations:true})};var __embind_register_optional=(rawOptionalType,rawType)=>{__embind_register_emval(rawOptionalType)};var stringToUTF8Array=(str,heap,outIdx,maxBytesToWrite)=>{if(!(maxBytesToWrite>0))return 0;var startIdx=outIdx;var endIdx=outIdx+maxBytesToWrite-1;for(var i=0;i=55296&&u<=57343){var u1=str.charCodeAt(++i);u=65536+((u&1023)<<10)|u1&1023}if(u<=127){if(outIdx>=endIdx)break;heap[outIdx++]=u}else if(u<=2047){if(outIdx+1>=endIdx)break;heap[outIdx++]=192|u>>6;heap[outIdx++]=128|u&63}else if(u<=65535){if(outIdx+2>=endIdx)break;heap[outIdx++]=224|u>>12;heap[outIdx++]=128|u>>6&63;heap[outIdx++]=128|u&63}else{if(outIdx+3>=endIdx)break;heap[outIdx++]=240|u>>18;heap[outIdx++]=128|u>>12&63;heap[outIdx++]=128|u>>6&63;heap[outIdx++]=128|u&63}}heap[outIdx]=0;return outIdx-startIdx};var stringToUTF8=(str,outPtr,maxBytesToWrite)=>stringToUTF8Array(str,HEAPU8,outPtr,maxBytesToWrite);var lengthBytesUTF8=str=>{var len=0;for(var i=0;i=55296&&c<=57343){len+=4;++i}else{len+=3}}return len};var UTF8Decoder=typeof TextDecoder!="undefined"?new TextDecoder:undefined;var UTF8ArrayToString=(heapOrArray,idx,maxBytesToRead)=>{var endIdx=idx+maxBytesToRead;var endPtr=idx;while(heapOrArray[endPtr]&&!(endPtr>=endIdx))++endPtr;if(endPtr-idx>16&&heapOrArray.buffer&&UTF8Decoder){return UTF8Decoder.decode(heapOrArray.subarray(idx,endPtr))}var str="";while(idx>10,56320|ch&1023)}}return str};var UTF8ToString=(ptr,maxBytesToRead)=>ptr?UTF8ArrayToString(HEAPU8,ptr,maxBytesToRead):"";var __embind_register_std_string=(rawType,name)=>{name=readLatin1String(name);var stdStringIsUTF8=name==="std::string";registerType(rawType,{name:name,fromWireType(value){var length=HEAPU32[value>>2];var payload=value+4;var str;if(stdStringIsUTF8){var decodeStartPtr=payload;for(var i=0;i<=length;++i){var currentBytePtr=payload+i;if(i==length||HEAPU8[currentBytePtr]==0){var maxRead=currentBytePtr-decodeStartPtr;var stringSegment=UTF8ToString(decodeStartPtr,maxRead);if(str===undefined){str=stringSegment}else{str+=String.fromCharCode(0);str+=stringSegment}decodeStartPtr=currentBytePtr+1}}}else{var a=new Array(length);for(var i=0;i>2]=length;if(stdStringIsUTF8&&valueIsOfTypeString){stringToUTF8(value,ptr,length+1)}else{if(valueIsOfTypeString){for(var i=0;i255){_free(ptr);throwBindingError("String has UTF-16 code units that do not fit in 8 bits")}HEAPU8[ptr+i]=charCode}}else{for(var i=0;i{var endPtr=ptr;var idx=endPtr>>1;var maxIdx=idx+maxBytesToRead/2;while(!(idx>=maxIdx)&&HEAPU16[idx])++idx;endPtr=idx<<1;if(endPtr-ptr>32&&UTF16Decoder)return UTF16Decoder.decode(HEAPU8.subarray(ptr,endPtr));var str="";for(var i=0;!(i>=maxBytesToRead/2);++i){var codeUnit=HEAP16[ptr+i*2>>1];if(codeUnit==0)break;str+=String.fromCharCode(codeUnit)}return str};var stringToUTF16=(str,outPtr,maxBytesToWrite)=>{maxBytesToWrite??=2147483647;if(maxBytesToWrite<2)return 0;maxBytesToWrite-=2;var startPtr=outPtr;var numCharsToWrite=maxBytesToWrite>1]=codeUnit;outPtr+=2}HEAP16[outPtr>>1]=0;return outPtr-startPtr};var lengthBytesUTF16=str=>str.length*2;var UTF32ToString=(ptr,maxBytesToRead)=>{var i=0;var str="";while(!(i>=maxBytesToRead/4)){var utf32=HEAP32[ptr+i*4>>2];if(utf32==0)break;++i;if(utf32>=65536){var ch=utf32-65536;str+=String.fromCharCode(55296|ch>>10,56320|ch&1023)}else{str+=String.fromCharCode(utf32)}}return str};var stringToUTF32=(str,outPtr,maxBytesToWrite)=>{maxBytesToWrite??=2147483647;if(maxBytesToWrite<4)return 0;var startPtr=outPtr;var endPtr=startPtr+maxBytesToWrite-4;for(var i=0;i=55296&&codeUnit<=57343){var trailSurrogate=str.charCodeAt(++i);codeUnit=65536+((codeUnit&1023)<<10)|trailSurrogate&1023}HEAP32[outPtr>>2]=codeUnit;outPtr+=4;if(outPtr+4>endPtr)break}HEAP32[outPtr>>2]=0;return outPtr-startPtr};var lengthBytesUTF32=str=>{var len=0;for(var i=0;i=55296&&codeUnit<=57343)++i;len+=4}return len};var __embind_register_std_wstring=(rawType,charSize,name)=>{name=readLatin1String(name);var decodeString,encodeString,readCharAt,lengthBytesUTF;if(charSize===2){decodeString=UTF16ToString;encodeString=stringToUTF16;lengthBytesUTF=lengthBytesUTF16;readCharAt=pointer=>HEAPU16[pointer>>1]}else if(charSize===4){decodeString=UTF32ToString;encodeString=stringToUTF32;lengthBytesUTF=lengthBytesUTF32;readCharAt=pointer=>HEAPU32[pointer>>2]}registerType(rawType,{name:name,fromWireType:value=>{var length=HEAPU32[value>>2];var str;var decodeStartPtr=value+4;for(var i=0;i<=length;++i){var currentBytePtr=value+4+i*charSize;if(i==length||readCharAt(currentBytePtr)==0){var maxReadBytes=currentBytePtr-decodeStartPtr;var stringSegment=decodeString(decodeStartPtr,maxReadBytes);if(str===undefined){str=stringSegment}else{str+=String.fromCharCode(0);str+=stringSegment}decodeStartPtr=currentBytePtr+charSize}}_free(value);return str},toWireType:(destructors,value)=>{if(!(typeof value=="string")){throwBindingError(`Cannot pass non-string to C++ string type ${name}`)}var length=lengthBytesUTF(value);var ptr=_malloc(4+length+charSize);HEAPU32[ptr>>2]=length/charSize;encodeString(value,ptr+4,length+charSize);if(destructors!==null){destructors.push(_free,ptr)}return ptr},argPackAdvance:GenericWireTypeSize,readValueFromPointer:readPointer,destructorFunction(ptr){_free(ptr)}})};var __embind_register_void=(rawType,name)=>{name=readLatin1String(name);registerType(rawType,{isVoid:true,name:name,argPackAdvance:0,fromWireType:()=>undefined,toWireType:(destructors,o)=>undefined})};var __emscripten_memcpy_js=(dest,src,num)=>HEAPU8.copyWithin(dest,src,src+num);var requireRegisteredType=(rawType,humanName)=>{var impl=registeredTypes[rawType];if(undefined===impl){throwBindingError(`${humanName} has unknown type ${getTypeName(rawType)}`)}return impl};var __emval_take_value=(type,arg)=>{type=requireRegisteredType(type,"_emval_take_value");var v=type["readValueFromPointer"](arg);return Emval.toHandle(v)};var _emscripten_date_now=()=>Date.now();var abortOnCannotGrowMemory=requestedSize=>{abort("OOM")};var _emscripten_resize_heap=requestedSize=>{var oldSize=HEAPU8.length;requestedSize>>>=0;abortOnCannotGrowMemory(requestedSize)};var printCharBuffers=[null,[],[]];var printChar=(stream,curr)=>{var buffer=printCharBuffers[stream];if(curr===0||curr===10){(stream===1?out:err)(UTF8ArrayToString(buffer,0));buffer.length=0}else{buffer.push(curr)}};var _fd_write=(fd,iov,iovcnt,pnum)=>{var num=0;for(var i=0;i>2];var len=HEAPU32[iov+4>>2];iov+=8;for(var j=0;j>2]=num;return 0};embind_init_charCodes();BindingError=Module["BindingError"]=class BindingError extends Error{constructor(message){super(message);this.name="BindingError"}};InternalError=Module["InternalError"]=class InternalError extends Error{constructor(message){super(message);this.name="InternalError"}};init_ClassHandle();init_embind();init_RegisteredPointer();UnboundTypeError=Module["UnboundTypeError"]=extendError(Error,"UnboundTypeError");init_emval();var wasmImports={f:___cxa_throw,q:__abort_js,p:__embind_register_bigint,u:__embind_register_bool,l:__embind_register_class,h:__embind_register_class_constructor,e:__embind_register_class_function,a:__embind_register_class_property,t:__embind_register_emval,k:__embind_register_float,c:__embind_register_function,d:__embind_register_integer,b:__embind_register_memory_view,o:__embind_register_optional,j:__embind_register_std_string,g:__embind_register_std_wstring,m:__embind_register_void,s:__emscripten_memcpy_js,n:__emval_take_value,v:_emscripten_date_now,r:_emscripten_resize_heap,i:_fd_write};var wasmExports=createWasm();var ___wasm_call_ctors=()=>(___wasm_call_ctors=wasmExports["x"])();var _param_get=Module["_param_get"]=(a0,a1)=>(_param_get=Module["_param_get"]=wasmExports["y"])(a0,a1);var _param_set_used=Module["_param_set_used"]=a0=>(_param_set_used=Module["_param_set_used"]=wasmExports["z"])(a0);var __Znwm=Module["__Znwm"]=a0=>(__Znwm=Module["__Znwm"]=wasmExports["A"])(a0);var _param_get_mark_used=Module["_param_get_mark_used"]=(a0,a1)=>(_param_get_mark_used=Module["_param_get_mark_used"]=wasmExports["B"])(a0,a1);var __ZdlPvm=Module["__ZdlPvm"]=(a0,a1)=>(__ZdlPvm=Module["__ZdlPvm"]=wasmExports["C"])(a0,a1);var _malloc=a0=>(_malloc=wasmExports["E"])(a0);var __ZNSt12length_errorD1Ev=Module["__ZNSt12length_errorD1Ev"]=a0=>(__ZNSt12length_errorD1Ev=Module["__ZNSt12length_errorD1Ev"]=wasmExports["F"])(a0);var ___cxa_allocate_exception=Module["___cxa_allocate_exception"]=a0=>(___cxa_allocate_exception=Module["___cxa_allocate_exception"]=wasmExports["G"])(a0);var __ZNSt20bad_array_new_lengthD1Ev=Module["__ZNSt20bad_array_new_lengthD1Ev"]=a0=>(__ZNSt20bad_array_new_lengthD1Ev=Module["__ZNSt20bad_array_new_lengthD1Ev"]=wasmExports["H"])(a0);var __ZNSt20bad_array_new_lengthC1Ev=Module["__ZNSt20bad_array_new_lengthC1Ev"]=a0=>(__ZNSt20bad_array_new_lengthC1Ev=Module["__ZNSt20bad_array_new_lengthC1Ev"]=wasmExports["I"])(a0);var __ZNSt12out_of_rangeD1Ev=Module["__ZNSt12out_of_rangeD1Ev"]=a0=>(__ZNSt12out_of_rangeD1Ev=Module["__ZNSt12out_of_rangeD1Ev"]=wasmExports["J"])(a0);var ___cxa_pure_virtual=Module["___cxa_pure_virtual"]=()=>(___cxa_pure_virtual=Module["___cxa_pure_virtual"]=wasmExports["K"])();var ___getTypeName=a0=>(___getTypeName=wasmExports["L"])(a0);var __ZNSt9exceptionD2Ev=Module["__ZNSt9exceptionD2Ev"]=a0=>(__ZNSt9exceptionD2Ev=Module["__ZNSt9exceptionD2Ev"]=wasmExports["M"])(a0);var _free=a0=>(_free=wasmExports["N"])(a0);var _getTempRet0=Module["_getTempRet0"]=()=>(_getTempRet0=Module["_getTempRet0"]=wasmExports["O"])();var _setTempRet0=Module["_setTempRet0"]=a0=>(_setTempRet0=Module["_setTempRet0"]=wasmExports["P"])(a0);var __ZSt15get_new_handlerv=Module["__ZSt15get_new_handlerv"]=()=>(__ZSt15get_new_handlerv=Module["__ZSt15get_new_handlerv"]=wasmExports["Q"])();var __Znam=Module["__Znam"]=a0=>(__Znam=Module["__Znam"]=wasmExports["R"])(a0);var __ZdlPv=Module["__ZdlPv"]=a0=>(__ZdlPv=Module["__ZdlPv"]=wasmExports["S"])(a0);var __ZdaPv=Module["__ZdaPv"]=a0=>(__ZdaPv=Module["__ZdaPv"]=wasmExports["T"])(a0);var __ZdaPvm=Module["__ZdaPvm"]=(a0,a1)=>(__ZdaPvm=Module["__ZdaPvm"]=wasmExports["U"])(a0,a1);var __ZnwmSt11align_val_t=Module["__ZnwmSt11align_val_t"]=(a0,a1)=>(__ZnwmSt11align_val_t=Module["__ZnwmSt11align_val_t"]=wasmExports["V"])(a0,a1);var __ZnamSt11align_val_t=Module["__ZnamSt11align_val_t"]=(a0,a1)=>(__ZnamSt11align_val_t=Module["__ZnamSt11align_val_t"]=wasmExports["W"])(a0,a1);var __ZdlPvSt11align_val_t=Module["__ZdlPvSt11align_val_t"]=(a0,a1)=>(__ZdlPvSt11align_val_t=Module["__ZdlPvSt11align_val_t"]=wasmExports["X"])(a0,a1);var __ZdlPvmSt11align_val_t=Module["__ZdlPvmSt11align_val_t"]=(a0,a1,a2)=>(__ZdlPvmSt11align_val_t=Module["__ZdlPvmSt11align_val_t"]=wasmExports["Y"])(a0,a1,a2);var __ZdaPvSt11align_val_t=Module["__ZdaPvSt11align_val_t"]=(a0,a1)=>(__ZdaPvSt11align_val_t=Module["__ZdaPvSt11align_val_t"]=wasmExports["Z"])(a0,a1);var __ZdaPvmSt11align_val_t=Module["__ZdaPvmSt11align_val_t"]=(a0,a1,a2)=>(__ZdaPvmSt11align_val_t=Module["__ZdaPvmSt11align_val_t"]=wasmExports["_"])(a0,a1,a2);var __ZSt14set_unexpectedPFvvE=Module["__ZSt14set_unexpectedPFvvE"]=a0=>(__ZSt14set_unexpectedPFvvE=Module["__ZSt14set_unexpectedPFvvE"]=wasmExports["$"])(a0);var __ZSt13set_terminatePFvvE=Module["__ZSt13set_terminatePFvvE"]=a0=>(__ZSt13set_terminatePFvvE=Module["__ZSt13set_terminatePFvvE"]=wasmExports["aa"])(a0);var __ZSt15set_new_handlerPFvvE=Module["__ZSt15set_new_handlerPFvvE"]=a0=>(__ZSt15set_new_handlerPFvvE=Module["__ZSt15set_new_handlerPFvvE"]=wasmExports["ba"])(a0);var __ZSt14get_unexpectedv=Module["__ZSt14get_unexpectedv"]=()=>(__ZSt14get_unexpectedv=Module["__ZSt14get_unexpectedv"]=wasmExports["ca"])();var __ZSt10unexpectedv=Module["__ZSt10unexpectedv"]=()=>(__ZSt10unexpectedv=Module["__ZSt10unexpectedv"]=wasmExports["da"])();var __ZSt13get_terminatev=Module["__ZSt13get_terminatev"]=()=>(__ZSt13get_terminatev=Module["__ZSt13get_terminatev"]=wasmExports["ea"])();var __ZSt9terminatev=Module["__ZSt9terminatev"]=()=>(__ZSt9terminatev=Module["__ZSt9terminatev"]=wasmExports["fa"])();var ___cxa_current_primary_exception=Module["___cxa_current_primary_exception"]=()=>(___cxa_current_primary_exception=Module["___cxa_current_primary_exception"]=wasmExports["ga"])();var ___cxa_rethrow_primary_exception=Module["___cxa_rethrow_primary_exception"]=a0=>(___cxa_rethrow_primary_exception=Module["___cxa_rethrow_primary_exception"]=wasmExports["ha"])(a0);var ___cxa_uncaught_exception=Module["___cxa_uncaught_exception"]=()=>(___cxa_uncaught_exception=Module["___cxa_uncaught_exception"]=wasmExports["ia"])();var ___cxa_uncaught_exceptions=Module["___cxa_uncaught_exceptions"]=()=>(___cxa_uncaught_exceptions=Module["___cxa_uncaught_exceptions"]=wasmExports["ja"])();var ___cxa_free_exception=Module["___cxa_free_exception"]=a0=>(___cxa_free_exception=Module["___cxa_free_exception"]=wasmExports["ka"])(a0);var ___cxa_init_primary_exception=Module["___cxa_init_primary_exception"]=(a0,a1,a2)=>(___cxa_init_primary_exception=Module["___cxa_init_primary_exception"]=wasmExports["la"])(a0,a1,a2);var ___cxa_deleted_virtual=Module["___cxa_deleted_virtual"]=()=>(___cxa_deleted_virtual=Module["___cxa_deleted_virtual"]=wasmExports["ma"])();var ___dynamic_cast=Module["___dynamic_cast"]=(a0,a1,a2,a3)=>(___dynamic_cast=Module["___dynamic_cast"]=wasmExports["na"])(a0,a1,a2,a3);var __ZNSt9type_infoD2Ev=Module["__ZNSt9type_infoD2Ev"]=a0=>(__ZNSt9type_infoD2Ev=Module["__ZNSt9type_infoD2Ev"]=wasmExports["oa"])(a0);var ___cxa_is_pointer_type=a0=>(___cxa_is_pointer_type=wasmExports["pa"])(a0);var __ZNSt9exceptionD0Ev=Module["__ZNSt9exceptionD0Ev"]=a0=>(__ZNSt9exceptionD0Ev=Module["__ZNSt9exceptionD0Ev"]=wasmExports["qa"])(a0);var __ZNSt9exceptionD1Ev=Module["__ZNSt9exceptionD1Ev"]=a0=>(__ZNSt9exceptionD1Ev=Module["__ZNSt9exceptionD1Ev"]=wasmExports["ra"])(a0);var __ZNKSt9exception4whatEv=Module["__ZNKSt9exception4whatEv"]=a0=>(__ZNKSt9exception4whatEv=Module["__ZNKSt9exception4whatEv"]=wasmExports["sa"])(a0);var __ZNSt13bad_exceptionD0Ev=Module["__ZNSt13bad_exceptionD0Ev"]=a0=>(__ZNSt13bad_exceptionD0Ev=Module["__ZNSt13bad_exceptionD0Ev"]=wasmExports["ta"])(a0);var __ZNSt13bad_exceptionD1Ev=Module["__ZNSt13bad_exceptionD1Ev"]=a0=>(__ZNSt13bad_exceptionD1Ev=Module["__ZNSt13bad_exceptionD1Ev"]=wasmExports["ua"])(a0);var __ZNKSt13bad_exception4whatEv=Module["__ZNKSt13bad_exception4whatEv"]=a0=>(__ZNKSt13bad_exception4whatEv=Module["__ZNKSt13bad_exception4whatEv"]=wasmExports["va"])(a0);var __ZNSt9bad_allocC2Ev=Module["__ZNSt9bad_allocC2Ev"]=a0=>(__ZNSt9bad_allocC2Ev=Module["__ZNSt9bad_allocC2Ev"]=wasmExports["wa"])(a0);var __ZNSt9bad_allocD0Ev=Module["__ZNSt9bad_allocD0Ev"]=a0=>(__ZNSt9bad_allocD0Ev=Module["__ZNSt9bad_allocD0Ev"]=wasmExports["xa"])(a0);var __ZNSt9bad_allocD1Ev=Module["__ZNSt9bad_allocD1Ev"]=a0=>(__ZNSt9bad_allocD1Ev=Module["__ZNSt9bad_allocD1Ev"]=wasmExports["ya"])(a0);var __ZNKSt9bad_alloc4whatEv=Module["__ZNKSt9bad_alloc4whatEv"]=a0=>(__ZNKSt9bad_alloc4whatEv=Module["__ZNKSt9bad_alloc4whatEv"]=wasmExports["za"])(a0);var __ZNSt20bad_array_new_lengthC2Ev=Module["__ZNSt20bad_array_new_lengthC2Ev"]=a0=>(__ZNSt20bad_array_new_lengthC2Ev=Module["__ZNSt20bad_array_new_lengthC2Ev"]=wasmExports["Aa"])(a0);var __ZNSt20bad_array_new_lengthD0Ev=Module["__ZNSt20bad_array_new_lengthD0Ev"]=a0=>(__ZNSt20bad_array_new_lengthD0Ev=Module["__ZNSt20bad_array_new_lengthD0Ev"]=wasmExports["Ba"])(a0);var __ZNKSt20bad_array_new_length4whatEv=Module["__ZNKSt20bad_array_new_length4whatEv"]=a0=>(__ZNKSt20bad_array_new_length4whatEv=Module["__ZNKSt20bad_array_new_length4whatEv"]=wasmExports["Ca"])(a0);var __ZNSt13bad_exceptionD2Ev=Module["__ZNSt13bad_exceptionD2Ev"]=a0=>(__ZNSt13bad_exceptionD2Ev=Module["__ZNSt13bad_exceptionD2Ev"]=wasmExports["Da"])(a0);var __ZNSt9bad_allocC1Ev=Module["__ZNSt9bad_allocC1Ev"]=a0=>(__ZNSt9bad_allocC1Ev=Module["__ZNSt9bad_allocC1Ev"]=wasmExports["Ea"])(a0);var __ZNSt9bad_allocD2Ev=Module["__ZNSt9bad_allocD2Ev"]=a0=>(__ZNSt9bad_allocD2Ev=Module["__ZNSt9bad_allocD2Ev"]=wasmExports["Fa"])(a0);var __ZNSt20bad_array_new_lengthD2Ev=Module["__ZNSt20bad_array_new_lengthD2Ev"]=a0=>(__ZNSt20bad_array_new_lengthD2Ev=Module["__ZNSt20bad_array_new_lengthD2Ev"]=wasmExports["Ga"])(a0);var __ZNSt11logic_errorD2Ev=Module["__ZNSt11logic_errorD2Ev"]=a0=>(__ZNSt11logic_errorD2Ev=Module["__ZNSt11logic_errorD2Ev"]=wasmExports["Ha"])(a0);var __ZNSt11logic_errorD0Ev=Module["__ZNSt11logic_errorD0Ev"]=a0=>(__ZNSt11logic_errorD0Ev=Module["__ZNSt11logic_errorD0Ev"]=wasmExports["Ia"])(a0);var __ZNSt11logic_errorD1Ev=Module["__ZNSt11logic_errorD1Ev"]=a0=>(__ZNSt11logic_errorD1Ev=Module["__ZNSt11logic_errorD1Ev"]=wasmExports["Ja"])(a0);var __ZNKSt11logic_error4whatEv=Module["__ZNKSt11logic_error4whatEv"]=a0=>(__ZNKSt11logic_error4whatEv=Module["__ZNKSt11logic_error4whatEv"]=wasmExports["Ka"])(a0);var __ZNSt13runtime_errorD2Ev=Module["__ZNSt13runtime_errorD2Ev"]=a0=>(__ZNSt13runtime_errorD2Ev=Module["__ZNSt13runtime_errorD2Ev"]=wasmExports["La"])(a0);var __ZNSt13runtime_errorD0Ev=Module["__ZNSt13runtime_errorD0Ev"]=a0=>(__ZNSt13runtime_errorD0Ev=Module["__ZNSt13runtime_errorD0Ev"]=wasmExports["Ma"])(a0);var __ZNSt13runtime_errorD1Ev=Module["__ZNSt13runtime_errorD1Ev"]=a0=>(__ZNSt13runtime_errorD1Ev=Module["__ZNSt13runtime_errorD1Ev"]=wasmExports["Na"])(a0);var __ZNKSt13runtime_error4whatEv=Module["__ZNKSt13runtime_error4whatEv"]=a0=>(__ZNKSt13runtime_error4whatEv=Module["__ZNKSt13runtime_error4whatEv"]=wasmExports["Oa"])(a0);var __ZNSt12domain_errorD0Ev=Module["__ZNSt12domain_errorD0Ev"]=a0=>(__ZNSt12domain_errorD0Ev=Module["__ZNSt12domain_errorD0Ev"]=wasmExports["Pa"])(a0);var __ZNSt12domain_errorD1Ev=Module["__ZNSt12domain_errorD1Ev"]=a0=>(__ZNSt12domain_errorD1Ev=Module["__ZNSt12domain_errorD1Ev"]=wasmExports["Qa"])(a0);var __ZNSt16invalid_argumentD0Ev=Module["__ZNSt16invalid_argumentD0Ev"]=a0=>(__ZNSt16invalid_argumentD0Ev=Module["__ZNSt16invalid_argumentD0Ev"]=wasmExports["Ra"])(a0);var __ZNSt16invalid_argumentD1Ev=Module["__ZNSt16invalid_argumentD1Ev"]=a0=>(__ZNSt16invalid_argumentD1Ev=Module["__ZNSt16invalid_argumentD1Ev"]=wasmExports["Sa"])(a0);var __ZNSt12length_errorD0Ev=Module["__ZNSt12length_errorD0Ev"]=a0=>(__ZNSt12length_errorD0Ev=Module["__ZNSt12length_errorD0Ev"]=wasmExports["Ta"])(a0);var __ZNSt12out_of_rangeD0Ev=Module["__ZNSt12out_of_rangeD0Ev"]=a0=>(__ZNSt12out_of_rangeD0Ev=Module["__ZNSt12out_of_rangeD0Ev"]=wasmExports["Ua"])(a0);var __ZNSt11range_errorD0Ev=Module["__ZNSt11range_errorD0Ev"]=a0=>(__ZNSt11range_errorD0Ev=Module["__ZNSt11range_errorD0Ev"]=wasmExports["Va"])(a0);var __ZNSt11range_errorD1Ev=Module["__ZNSt11range_errorD1Ev"]=a0=>(__ZNSt11range_errorD1Ev=Module["__ZNSt11range_errorD1Ev"]=wasmExports["Wa"])(a0);var __ZNSt14overflow_errorD0Ev=Module["__ZNSt14overflow_errorD0Ev"]=a0=>(__ZNSt14overflow_errorD0Ev=Module["__ZNSt14overflow_errorD0Ev"]=wasmExports["Xa"])(a0);var __ZNSt14overflow_errorD1Ev=Module["__ZNSt14overflow_errorD1Ev"]=a0=>(__ZNSt14overflow_errorD1Ev=Module["__ZNSt14overflow_errorD1Ev"]=wasmExports["Ya"])(a0);var __ZNSt15underflow_errorD0Ev=Module["__ZNSt15underflow_errorD0Ev"]=a0=>(__ZNSt15underflow_errorD0Ev=Module["__ZNSt15underflow_errorD0Ev"]=wasmExports["Za"])(a0);var __ZNSt15underflow_errorD1Ev=Module["__ZNSt15underflow_errorD1Ev"]=a0=>(__ZNSt15underflow_errorD1Ev=Module["__ZNSt15underflow_errorD1Ev"]=wasmExports["_a"])(a0);var __ZNSt12domain_errorD2Ev=Module["__ZNSt12domain_errorD2Ev"]=a0=>(__ZNSt12domain_errorD2Ev=Module["__ZNSt12domain_errorD2Ev"]=wasmExports["$a"])(a0);var __ZNSt16invalid_argumentD2Ev=Module["__ZNSt16invalid_argumentD2Ev"]=a0=>(__ZNSt16invalid_argumentD2Ev=Module["__ZNSt16invalid_argumentD2Ev"]=wasmExports["ab"])(a0);var __ZNSt12length_errorD2Ev=Module["__ZNSt12length_errorD2Ev"]=a0=>(__ZNSt12length_errorD2Ev=Module["__ZNSt12length_errorD2Ev"]=wasmExports["bb"])(a0);var __ZNSt12out_of_rangeD2Ev=Module["__ZNSt12out_of_rangeD2Ev"]=a0=>(__ZNSt12out_of_rangeD2Ev=Module["__ZNSt12out_of_rangeD2Ev"]=wasmExports["cb"])(a0);var __ZNSt11range_errorD2Ev=Module["__ZNSt11range_errorD2Ev"]=a0=>(__ZNSt11range_errorD2Ev=Module["__ZNSt11range_errorD2Ev"]=wasmExports["db"])(a0);var __ZNSt14overflow_errorD2Ev=Module["__ZNSt14overflow_errorD2Ev"]=a0=>(__ZNSt14overflow_errorD2Ev=Module["__ZNSt14overflow_errorD2Ev"]=wasmExports["eb"])(a0);var __ZNSt15underflow_errorD2Ev=Module["__ZNSt15underflow_errorD2Ev"]=a0=>(__ZNSt15underflow_errorD2Ev=Module["__ZNSt15underflow_errorD2Ev"]=wasmExports["fb"])(a0);var __ZNSt9type_infoD0Ev=Module["__ZNSt9type_infoD0Ev"]=a0=>(__ZNSt9type_infoD0Ev=Module["__ZNSt9type_infoD0Ev"]=wasmExports["gb"])(a0);var __ZNSt9type_infoD1Ev=Module["__ZNSt9type_infoD1Ev"]=a0=>(__ZNSt9type_infoD1Ev=Module["__ZNSt9type_infoD1Ev"]=wasmExports["hb"])(a0);var __ZNSt8bad_castC2Ev=Module["__ZNSt8bad_castC2Ev"]=a0=>(__ZNSt8bad_castC2Ev=Module["__ZNSt8bad_castC2Ev"]=wasmExports["ib"])(a0);var __ZNSt8bad_castD2Ev=Module["__ZNSt8bad_castD2Ev"]=a0=>(__ZNSt8bad_castD2Ev=Module["__ZNSt8bad_castD2Ev"]=wasmExports["jb"])(a0);var __ZNSt8bad_castD0Ev=Module["__ZNSt8bad_castD0Ev"]=a0=>(__ZNSt8bad_castD0Ev=Module["__ZNSt8bad_castD0Ev"]=wasmExports["kb"])(a0);var __ZNSt8bad_castD1Ev=Module["__ZNSt8bad_castD1Ev"]=a0=>(__ZNSt8bad_castD1Ev=Module["__ZNSt8bad_castD1Ev"]=wasmExports["lb"])(a0);var __ZNKSt8bad_cast4whatEv=Module["__ZNKSt8bad_cast4whatEv"]=a0=>(__ZNKSt8bad_cast4whatEv=Module["__ZNKSt8bad_cast4whatEv"]=wasmExports["mb"])(a0);var __ZNSt10bad_typeidC2Ev=Module["__ZNSt10bad_typeidC2Ev"]=a0=>(__ZNSt10bad_typeidC2Ev=Module["__ZNSt10bad_typeidC2Ev"]=wasmExports["nb"])(a0);var __ZNSt10bad_typeidD2Ev=Module["__ZNSt10bad_typeidD2Ev"]=a0=>(__ZNSt10bad_typeidD2Ev=Module["__ZNSt10bad_typeidD2Ev"]=wasmExports["ob"])(a0);var __ZNSt10bad_typeidD0Ev=Module["__ZNSt10bad_typeidD0Ev"]=a0=>(__ZNSt10bad_typeidD0Ev=Module["__ZNSt10bad_typeidD0Ev"]=wasmExports["pb"])(a0);var __ZNSt10bad_typeidD1Ev=Module["__ZNSt10bad_typeidD1Ev"]=a0=>(__ZNSt10bad_typeidD1Ev=Module["__ZNSt10bad_typeidD1Ev"]=wasmExports["qb"])(a0);var __ZNKSt10bad_typeid4whatEv=Module["__ZNKSt10bad_typeid4whatEv"]=a0=>(__ZNKSt10bad_typeid4whatEv=Module["__ZNKSt10bad_typeid4whatEv"]=wasmExports["rb"])(a0);var __ZNSt8bad_castC1Ev=Module["__ZNSt8bad_castC1Ev"]=a0=>(__ZNSt8bad_castC1Ev=Module["__ZNSt8bad_castC1Ev"]=wasmExports["sb"])(a0);var __ZNSt10bad_typeidC1Ev=Module["__ZNSt10bad_typeidC1Ev"]=a0=>(__ZNSt10bad_typeidC1Ev=Module["__ZNSt10bad_typeidC1Ev"]=wasmExports["tb"])(a0);var dynCall_jiji=Module["dynCall_jiji"]=(a0,a1,a2,a3,a4)=>(dynCall_jiji=Module["dynCall_jiji"]=wasmExports["ub"])(a0,a1,a2,a3,a4);var __ZTIPK16failsafe_flags_s=Module["__ZTIPK16failsafe_flags_s"]=52648;var __ZTIP16failsafe_flags_s=Module["__ZTIP16failsafe_flags_s"]=52632;var __ZTI16failsafe_flags_s=Module["__ZTI16failsafe_flags_s"]=52624;var __ZTIb=Module["__ZTIb"]=34024;var __ZTIh=Module["__ZTIh"]=34180;var __ZTINSt3__212basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEE=Module["__ZTINSt3__212basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEE"]=52720;var __ZTINSt3__28optionalINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEEEE=Module["__ZTINSt3__28optionalINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEEEE"]=52868;var __ZTIPKNSt3__26vectorINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEENS4_IS6_EEEE=Module["__ZTIPKNSt3__26vectorINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEENS4_IS6_EEEE"]=52924;var __ZTIPNSt3__26vectorINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEENS4_IS6_EEEE=Module["__ZTIPNSt3__26vectorINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEENS4_IS6_EEEE"]=52908;var __ZTINSt3__26vectorINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEENS4_IS6_EEEE=Module["__ZTINSt3__26vectorINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEENS4_IS6_EEEE"]=52732;var __ZTISt12length_error=Module["__ZTISt12length_error"]=36140;var __ZTVSt12length_error=Module["__ZTVSt12length_error"]=36100;var __ZTISt20bad_array_new_length=Module["__ZTISt20bad_array_new_length"]=35912;var __ZTISt12out_of_range=Module["__ZTISt12out_of_range"]=36192;var __ZTVSt12out_of_range=Module["__ZTVSt12out_of_range"]=36152;var __ZTVN10__cxxabiv117__class_type_infoE=Module["__ZTVN10__cxxabiv117__class_type_infoE"]=35412;var __ZTVN10__cxxabiv121__vmi_class_type_infoE=Module["__ZTVN10__cxxabiv121__vmi_class_type_infoE"]=35544;var __ZTVN10__cxxabiv120__si_class_type_infoE=Module["__ZTVN10__cxxabiv120__si_class_type_infoE"]=35452;var __ZTS16failsafe_flags_s=Module["__ZTS16failsafe_flags_s"]=30923;var __ZTSP16failsafe_flags_s=Module["__ZTSP16failsafe_flags_s"]=30942;var __ZTVN10__cxxabiv119__pointer_type_infoE=Module["__ZTVN10__cxxabiv119__pointer_type_infoE"]=35664;var __ZTSPK16failsafe_flags_s=Module["__ZTSPK16failsafe_flags_s"]=30962;var __ZTIi=Module["__ZTIi"]=34388;var __ZTSNSt3__212basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEE=Module["__ZTSNSt3__212basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEE"]=31012;var __ZTSNSt3__26vectorINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEENS4_IS6_EEEE=Module["__ZTSNSt3__26vectorINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEENS4_IS6_EEEE"]=31079;var __ZTIv=Module["__ZTIv"]=33916;var __ZTIf=Module["__ZTIf"]=34860;var __ZTSNSt3__28optionalINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEEEE=Module["__ZTSNSt3__28optionalINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEEEE"]=31177;var __ZTSNSt3__227__optional_move_assign_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE=Module["__ZTSNSt3__227__optional_move_assign_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE"]=31255;var __ZTSNSt3__227__optional_copy_assign_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE=Module["__ZTSNSt3__227__optional_copy_assign_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE"]=31357;var __ZTSNSt3__220__optional_move_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE=Module["__ZTSNSt3__220__optional_move_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE"]=31459;var __ZTSNSt3__220__optional_copy_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE=Module["__ZTSNSt3__220__optional_copy_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE"]=31554;var __ZTSNSt3__223__optional_storage_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE=Module["__ZTSNSt3__223__optional_storage_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE"]=31649;var __ZTSNSt3__224__optional_destruct_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE=Module["__ZTSNSt3__224__optional_destruct_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE"]=31747;var __ZTINSt3__224__optional_destruct_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE=Module["__ZTINSt3__224__optional_destruct_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE"]=52784;var __ZTINSt3__223__optional_storage_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE=Module["__ZTINSt3__223__optional_storage_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE"]=52792;var __ZTINSt3__220__optional_copy_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE=Module["__ZTINSt3__220__optional_copy_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE"]=52804;var __ZTINSt3__220__optional_move_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE=Module["__ZTINSt3__220__optional_move_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE"]=52816;var __ZTINSt3__227__optional_copy_assign_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE=Module["__ZTINSt3__227__optional_copy_assign_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE"]=52828;var __ZTINSt3__227__optional_move_assign_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE=Module["__ZTINSt3__227__optional_move_assign_baseINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEELb0EEE"]=52840;var __ZTSNSt3__218__sfinae_ctor_baseILb1ELb1EEE=Module["__ZTSNSt3__218__sfinae_ctor_baseILb1ELb1EEE"]=31846;var __ZTINSt3__218__sfinae_ctor_baseILb1ELb1EEE=Module["__ZTINSt3__218__sfinae_ctor_baseILb1ELb1EEE"]=52852;var __ZTSNSt3__220__sfinae_assign_baseILb1ELb1EEE=Module["__ZTSNSt3__220__sfinae_assign_baseILb1ELb1EEE"]=31885;var __ZTINSt3__220__sfinae_assign_baseILb1ELb1EEE=Module["__ZTINSt3__220__sfinae_assign_baseILb1ELb1EEE"]=52860;var __ZTSPNSt3__26vectorINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEENS4_IS6_EEEE=Module["__ZTSPNSt3__26vectorINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEENS4_IS6_EEEE"]=31926;var __ZTSPKNSt3__26vectorINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEENS4_IS6_EEEE=Module["__ZTSPKNSt3__26vectorINS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEENS4_IS6_EEEE"]=32013;var __ZTIm=Module["__ZTIm"]=34544;var __ZTIc=Module["__ZTIc"]=34128;var __ZTIa=Module["__ZTIa"]=34232;var __ZTIs=Module["__ZTIs"]=34284;var __ZTIt=Module["__ZTIt"]=34336;var __ZTIj=Module["__ZTIj"]=34440;var __ZTIl=Module["__ZTIl"]=34492;var __ZTIx=Module["__ZTIx"]=34596;var __ZTIy=Module["__ZTIy"]=34648;var __ZTId=Module["__ZTId"]=34912;var __ZTINSt3__212basic_stringIhNS_11char_traitsIhEENS_9allocatorIhEEEE=Module["__ZTINSt3__212basic_stringIhNS_11char_traitsIhEENS_9allocatorIhEEEE"]=32216;var __ZTINSt3__212basic_stringIwNS_11char_traitsIwEENS_9allocatorIwEEEE=Module["__ZTINSt3__212basic_stringIwNS_11char_traitsIwEENS_9allocatorIwEEEE"]=32288;var __ZTINSt3__212basic_stringIDsNS_11char_traitsIDsEENS_9allocatorIDsEEEE=Module["__ZTINSt3__212basic_stringIDsNS_11char_traitsIDsEENS_9allocatorIDsEEEE"]=32364;var __ZTINSt3__212basic_stringIDiNS_11char_traitsIDiEENS_9allocatorIDiEEEE=Module["__ZTINSt3__212basic_stringIDiNS_11char_traitsIDiEENS_9allocatorIDiEEEE"]=32440;var __ZTSNSt3__212basic_stringIhNS_11char_traitsIhEENS_9allocatorIhEEEE=Module["__ZTSNSt3__212basic_stringIhNS_11char_traitsIhEENS_9allocatorIhEEEE"]=32152;var __ZTSNSt3__212basic_stringIwNS_11char_traitsIwEENS_9allocatorIwEEEE=Module["__ZTSNSt3__212basic_stringIwNS_11char_traitsIwEENS_9allocatorIwEEEE"]=32224;var __ZTSNSt3__212basic_stringIDsNS_11char_traitsIDsEENS_9allocatorIDsEEEE=Module["__ZTSNSt3__212basic_stringIDsNS_11char_traitsIDsEENS_9allocatorIDsEEEE"]=32296;var __ZTSNSt3__212basic_stringIDiNS_11char_traitsIDiEENS_9allocatorIDiEEEE=Module["__ZTSNSt3__212basic_stringIDiNS_11char_traitsIDiEENS_9allocatorIDiEEEE"]=32372;var __ZTVSt11logic_error=Module["__ZTVSt11logic_error"]=35924;var __ZTVSt9exception=Module["__ZTVSt9exception"]=35760;var __ZTVSt13runtime_error=Module["__ZTVSt13runtime_error"]=35944;var __ZTISt9exception=Module["__ZTISt9exception"]=35796;var ___cxa_unexpected_handler=Module["___cxa_unexpected_handler"]=53224;var ___cxa_terminate_handler=Module["___cxa_terminate_handler"]=53220;var ___cxa_new_handler=Module["___cxa_new_handler"]=55500;var __ZTIN10__cxxabiv116__shim_type_infoE=Module["__ZTIN10__cxxabiv116__shim_type_infoE"]=33524;var __ZTIN10__cxxabiv117__class_type_infoE=Module["__ZTIN10__cxxabiv117__class_type_infoE"]=33572;var __ZTIN10__cxxabiv117__pbase_type_infoE=Module["__ZTIN10__cxxabiv117__pbase_type_infoE"]=33620;var __ZTIDn=Module["__ZTIDn"]=33968;var __ZTIN10__cxxabiv119__pointer_type_infoE=Module["__ZTIN10__cxxabiv119__pointer_type_infoE"]=33668;var __ZTIN10__cxxabiv120__function_type_infoE=Module["__ZTIN10__cxxabiv120__function_type_infoE"]=33720;var __ZTIN10__cxxabiv129__pointer_to_member_type_infoE=Module["__ZTIN10__cxxabiv129__pointer_to_member_type_infoE"]=33780;var __ZTSN10__cxxabiv116__shim_type_infoE=Module["__ZTSN10__cxxabiv116__shim_type_infoE"]=33488;var __ZTISt9type_info=Module["__ZTISt9type_info"]=36460;var __ZTSN10__cxxabiv117__class_type_infoE=Module["__ZTSN10__cxxabiv117__class_type_infoE"]=33536;var __ZTSN10__cxxabiv117__pbase_type_infoE=Module["__ZTSN10__cxxabiv117__pbase_type_infoE"]=33584;var __ZTSN10__cxxabiv119__pointer_type_infoE=Module["__ZTSN10__cxxabiv119__pointer_type_infoE"]=33632;var __ZTSN10__cxxabiv120__function_type_infoE=Module["__ZTSN10__cxxabiv120__function_type_infoE"]=33680;var __ZTSN10__cxxabiv129__pointer_to_member_type_infoE=Module["__ZTSN10__cxxabiv129__pointer_to_member_type_infoE"]=33732;var __ZTVN10__cxxabiv116__shim_type_infoE=Module["__ZTVN10__cxxabiv116__shim_type_infoE"]=33804;var __ZTVN10__cxxabiv123__fundamental_type_infoE=Module["__ZTVN10__cxxabiv123__fundamental_type_infoE"]=33832;var __ZTIN10__cxxabiv123__fundamental_type_infoE=Module["__ZTIN10__cxxabiv123__fundamental_type_infoE"]=33900;var __ZTSN10__cxxabiv123__fundamental_type_infoE=Module["__ZTSN10__cxxabiv123__fundamental_type_infoE"]=33860;var __ZTSv=Module["__ZTSv"]=33912;var __ZTSPv=Module["__ZTSPv"]=33924;var __ZTIPv=Module["__ZTIPv"]=33928;var __ZTSPKv=Module["__ZTSPKv"]=33944;var __ZTIPKv=Module["__ZTIPKv"]=33948;var __ZTSDn=Module["__ZTSDn"]=33964;var __ZTSPDn=Module["__ZTSPDn"]=33976;var __ZTIPDn=Module["__ZTIPDn"]=33980;var __ZTSPKDn=Module["__ZTSPKDn"]=33996;var __ZTIPKDn=Module["__ZTIPKDn"]=34004;var __ZTSb=Module["__ZTSb"]=34020;var __ZTSPb=Module["__ZTSPb"]=34032;var __ZTIPb=Module["__ZTIPb"]=34036;var __ZTSPKb=Module["__ZTSPKb"]=34052;var __ZTIPKb=Module["__ZTIPKb"]=34056;var __ZTSw=Module["__ZTSw"]=34072;var __ZTIw=Module["__ZTIw"]=34076;var __ZTSPw=Module["__ZTSPw"]=34084;var __ZTIPw=Module["__ZTIPw"]=34088;var __ZTSPKw=Module["__ZTSPKw"]=34104;var __ZTIPKw=Module["__ZTIPKw"]=34108;var __ZTSc=Module["__ZTSc"]=34124;var __ZTSPc=Module["__ZTSPc"]=34136;var __ZTIPc=Module["__ZTIPc"]=34140;var __ZTSPKc=Module["__ZTSPKc"]=34156;var __ZTIPKc=Module["__ZTIPKc"]=34160;var __ZTSh=Module["__ZTSh"]=34176;var __ZTSPh=Module["__ZTSPh"]=34188;var __ZTIPh=Module["__ZTIPh"]=34192;var __ZTSPKh=Module["__ZTSPKh"]=34208;var __ZTIPKh=Module["__ZTIPKh"]=34212;var __ZTSa=Module["__ZTSa"]=34228;var __ZTSPa=Module["__ZTSPa"]=34240;var __ZTIPa=Module["__ZTIPa"]=34244;var __ZTSPKa=Module["__ZTSPKa"]=34260;var __ZTIPKa=Module["__ZTIPKa"]=34264;var __ZTSs=Module["__ZTSs"]=34280;var __ZTSPs=Module["__ZTSPs"]=34292;var __ZTIPs=Module["__ZTIPs"]=34296;var __ZTSPKs=Module["__ZTSPKs"]=34312;var __ZTIPKs=Module["__ZTIPKs"]=34316;var __ZTSt=Module["__ZTSt"]=34332;var __ZTSPt=Module["__ZTSPt"]=34344;var __ZTIPt=Module["__ZTIPt"]=34348;var __ZTSPKt=Module["__ZTSPKt"]=34364;var __ZTIPKt=Module["__ZTIPKt"]=34368;var __ZTSi=Module["__ZTSi"]=34384;var __ZTSPi=Module["__ZTSPi"]=34396;var __ZTIPi=Module["__ZTIPi"]=34400;var __ZTSPKi=Module["__ZTSPKi"]=34416;var __ZTIPKi=Module["__ZTIPKi"]=34420;var __ZTSj=Module["__ZTSj"]=34436;var __ZTSPj=Module["__ZTSPj"]=34448;var __ZTIPj=Module["__ZTIPj"]=34452;var __ZTSPKj=Module["__ZTSPKj"]=34468;var __ZTIPKj=Module["__ZTIPKj"]=34472;var __ZTSl=Module["__ZTSl"]=34488;var __ZTSPl=Module["__ZTSPl"]=34500;var __ZTIPl=Module["__ZTIPl"]=34504;var __ZTSPKl=Module["__ZTSPKl"]=34520;var __ZTIPKl=Module["__ZTIPKl"]=34524;var __ZTSm=Module["__ZTSm"]=34540;var __ZTSPm=Module["__ZTSPm"]=34552;var __ZTIPm=Module["__ZTIPm"]=34556;var __ZTSPKm=Module["__ZTSPKm"]=34572;var __ZTIPKm=Module["__ZTIPKm"]=34576;var __ZTSx=Module["__ZTSx"]=34592;var __ZTSPx=Module["__ZTSPx"]=34604;var __ZTIPx=Module["__ZTIPx"]=34608;var __ZTSPKx=Module["__ZTSPKx"]=34624;var __ZTIPKx=Module["__ZTIPKx"]=34628;var __ZTSy=Module["__ZTSy"]=34644;var __ZTSPy=Module["__ZTSPy"]=34656;var __ZTIPy=Module["__ZTIPy"]=34660;var __ZTSPKy=Module["__ZTSPKy"]=34676;var __ZTIPKy=Module["__ZTIPKy"]=34680;var __ZTSn=Module["__ZTSn"]=34696;var __ZTIn=Module["__ZTIn"]=34700;var __ZTSPn=Module["__ZTSPn"]=34708;var __ZTIPn=Module["__ZTIPn"]=34712;var __ZTSPKn=Module["__ZTSPKn"]=34728;var __ZTIPKn=Module["__ZTIPKn"]=34732;var __ZTSo=Module["__ZTSo"]=34748;var __ZTIo=Module["__ZTIo"]=34752;var __ZTSPo=Module["__ZTSPo"]=34760;var __ZTIPo=Module["__ZTIPo"]=34764;var __ZTSPKo=Module["__ZTSPKo"]=34780;var __ZTIPKo=Module["__ZTIPKo"]=34784;var __ZTSDh=Module["__ZTSDh"]=34800;var __ZTIDh=Module["__ZTIDh"]=34804;var __ZTSPDh=Module["__ZTSPDh"]=34812;var __ZTIPDh=Module["__ZTIPDh"]=34816;var __ZTSPKDh=Module["__ZTSPKDh"]=34832;var __ZTIPKDh=Module["__ZTIPKDh"]=34840;var __ZTSf=Module["__ZTSf"]=34856;var __ZTSPf=Module["__ZTSPf"]=34868;var __ZTIPf=Module["__ZTIPf"]=34872;var __ZTSPKf=Module["__ZTSPKf"]=34888;var __ZTIPKf=Module["__ZTIPKf"]=34892;var __ZTSd=Module["__ZTSd"]=34908;var __ZTSPd=Module["__ZTSPd"]=34920;var __ZTIPd=Module["__ZTIPd"]=34924;var __ZTSPKd=Module["__ZTSPKd"]=34940;var __ZTIPKd=Module["__ZTIPKd"]=34944;var __ZTSe=Module["__ZTSe"]=34960;var __ZTIe=Module["__ZTIe"]=34964;var __ZTSPe=Module["__ZTSPe"]=34972;var __ZTIPe=Module["__ZTIPe"]=34976;var __ZTSPKe=Module["__ZTSPKe"]=34992;var __ZTIPKe=Module["__ZTIPKe"]=34996;var __ZTSg=Module["__ZTSg"]=35012;var __ZTIg=Module["__ZTIg"]=35016;var __ZTSPg=Module["__ZTSPg"]=35024;var __ZTIPg=Module["__ZTIPg"]=35028;var __ZTSPKg=Module["__ZTSPKg"]=35044;var __ZTIPKg=Module["__ZTIPKg"]=35048;var __ZTSDu=Module["__ZTSDu"]=35064;var __ZTIDu=Module["__ZTIDu"]=35068;var __ZTSPDu=Module["__ZTSPDu"]=35076;var __ZTIPDu=Module["__ZTIPDu"]=35080;var __ZTSPKDu=Module["__ZTSPKDu"]=35096;var __ZTIPKDu=Module["__ZTIPKDu"]=35104;var __ZTSDs=Module["__ZTSDs"]=35120;var __ZTIDs=Module["__ZTIDs"]=35124;var __ZTSPDs=Module["__ZTSPDs"]=35132;var __ZTIPDs=Module["__ZTIPDs"]=35136;var __ZTSPKDs=Module["__ZTSPKDs"]=35152;var __ZTIPKDs=Module["__ZTIPKDs"]=35160;var __ZTSDi=Module["__ZTSDi"]=35176;var __ZTIDi=Module["__ZTIDi"]=35180;var __ZTSPDi=Module["__ZTSPDi"]=35188;var __ZTIPDi=Module["__ZTIPDi"]=35192;var __ZTSPKDi=Module["__ZTSPKDi"]=35208;var __ZTIPKDi=Module["__ZTIPKDi"]=35216;var __ZTVN10__cxxabiv117__array_type_infoE=Module["__ZTVN10__cxxabiv117__array_type_infoE"]=35232;var __ZTIN10__cxxabiv117__array_type_infoE=Module["__ZTIN10__cxxabiv117__array_type_infoE"]=35296;var __ZTSN10__cxxabiv117__array_type_infoE=Module["__ZTSN10__cxxabiv117__array_type_infoE"]=35260;var __ZTVN10__cxxabiv120__function_type_infoE=Module["__ZTVN10__cxxabiv120__function_type_infoE"]=35308;var __ZTVN10__cxxabiv116__enum_type_infoE=Module["__ZTVN10__cxxabiv116__enum_type_infoE"]=35336;var __ZTIN10__cxxabiv116__enum_type_infoE=Module["__ZTIN10__cxxabiv116__enum_type_infoE"]=35400;var __ZTSN10__cxxabiv116__enum_type_infoE=Module["__ZTSN10__cxxabiv116__enum_type_infoE"]=35364;var __ZTIN10__cxxabiv120__si_class_type_infoE=Module["__ZTIN10__cxxabiv120__si_class_type_infoE"]=35532;var __ZTSN10__cxxabiv120__si_class_type_infoE=Module["__ZTSN10__cxxabiv120__si_class_type_infoE"]=35492;var __ZTIN10__cxxabiv121__vmi_class_type_infoE=Module["__ZTIN10__cxxabiv121__vmi_class_type_infoE"]=35624;var __ZTSN10__cxxabiv121__vmi_class_type_infoE=Module["__ZTSN10__cxxabiv121__vmi_class_type_infoE"]=35584;var __ZTVN10__cxxabiv117__pbase_type_infoE=Module["__ZTVN10__cxxabiv117__pbase_type_infoE"]=35636;var __ZTVN10__cxxabiv129__pointer_to_member_type_infoE=Module["__ZTVN10__cxxabiv129__pointer_to_member_type_infoE"]=35692;var __ZTVSt9bad_alloc=Module["__ZTVSt9bad_alloc"]=35720;var __ZTVSt20bad_array_new_length=Module["__ZTVSt20bad_array_new_length"]=35740;var __ZTISt9bad_alloc=Module["__ZTISt9bad_alloc"]=35872;var __ZTSSt9exception=Module["__ZTSSt9exception"]=35780;var __ZTVSt13bad_exception=Module["__ZTVSt13bad_exception"]=35804;var __ZTISt13bad_exception=Module["__ZTISt13bad_exception"]=35844;var __ZTSSt13bad_exception=Module["__ZTSSt13bad_exception"]=35824;var __ZTSSt9bad_alloc=Module["__ZTSSt9bad_alloc"]=35856;var __ZTSSt20bad_array_new_length=Module["__ZTSSt20bad_array_new_length"]=35884;var __ZTISt11logic_error=Module["__ZTISt11logic_error"]=36020;var __ZTISt13runtime_error=Module["__ZTISt13runtime_error"]=36260;var __ZTVSt12domain_error=Module["__ZTVSt12domain_error"]=35964;var __ZTISt12domain_error=Module["__ZTISt12domain_error"]=36032;var __ZTSSt12domain_error=Module["__ZTSSt12domain_error"]=35984;var __ZTSSt11logic_error=Module["__ZTSSt11logic_error"]=36001;var __ZTVSt16invalid_argument=Module["__ZTVSt16invalid_argument"]=36044;var __ZTISt16invalid_argument=Module["__ZTISt16invalid_argument"]=36088;var __ZTSSt16invalid_argument=Module["__ZTSSt16invalid_argument"]=36064;var __ZTSSt12length_error=Module["__ZTSSt12length_error"]=36120;var __ZTSSt12out_of_range=Module["__ZTSSt12out_of_range"]=36172;var __ZTVSt11range_error=Module["__ZTVSt11range_error"]=36204;var __ZTISt11range_error=Module["__ZTISt11range_error"]=36272;var __ZTSSt11range_error=Module["__ZTSSt11range_error"]=36224;var __ZTSSt13runtime_error=Module["__ZTSSt13runtime_error"]=36240;var __ZTVSt14overflow_error=Module["__ZTVSt14overflow_error"]=36284;var __ZTISt14overflow_error=Module["__ZTISt14overflow_error"]=36324;var __ZTSSt14overflow_error=Module["__ZTSSt14overflow_error"]=36304;var __ZTVSt15underflow_error=Module["__ZTVSt15underflow_error"]=36336;var __ZTISt15underflow_error=Module["__ZTISt15underflow_error"]=36376;var __ZTSSt15underflow_error=Module["__ZTSSt15underflow_error"]=36356;var __ZTVSt8bad_cast=Module["__ZTVSt8bad_cast"]=36388;var __ZTVSt10bad_typeid=Module["__ZTVSt10bad_typeid"]=36408;var __ZTISt8bad_cast=Module["__ZTISt8bad_cast"]=36480;var __ZTISt10bad_typeid=Module["__ZTISt10bad_typeid"]=36508;var __ZTVSt9type_info=Module["__ZTVSt9type_info"]=36428;var __ZTSSt9type_info=Module["__ZTSSt9type_info"]=36444;var __ZTSSt8bad_cast=Module["__ZTSSt8bad_cast"]=36468;var __ZTSSt10bad_typeid=Module["__ZTSSt10bad_typeid"]=36492;var calledRun;dependenciesFulfilled=function runCaller(){if(!calledRun)run();if(!calledRun)dependenciesFulfilled=runCaller};function run(){if(runDependencies>0){return}preRun();if(runDependencies>0){return}function doRun(){if(calledRun)return;calledRun=true;Module["calledRun"]=true;if(ABORT)return;initRuntime();Module["onRuntimeInitialized"]?.();postRun()}if(Module["setStatus"]){Module["setStatus"]("Running...");setTimeout(function(){setTimeout(function(){Module["setStatus"]("")},1);doRun()},1)}else{doRun()}}if(Module["preInit"]){if(typeof Module["preInit"]=="function")Module["preInit"]=[Module["preInit"]];while(Module["preInit"].length>0){Module["preInit"].pop()()}}run(); diff --git a/docs/public/config/failsafe/index.wasm b/docs/public/config/failsafe/index.wasm index 83a8219879a..f1bd08ca910 100644 Binary files a/docs/public/config/failsafe/index.wasm and b/docs/public/config/failsafe/index.wasm differ diff --git a/docs/public/config/failsafe/parameters.json b/docs/public/config/failsafe/parameters.json index 68944c33f31..dd8e216fa2c 100644 --- a/docs/public/config/failsafe/parameters.json +++ b/docs/public/config/failsafe/parameters.json @@ -1 +1 @@ -{"parameters": [{"category": "Standard", "default": 0, "group": "ADSB", "longDesc": "Sets first 4 characters of a total of 8. Valid characters are A-Z, 0-9, \" \". Example \"PX4 \" -> 1347957792\nFor CALLSIGN shorter than 8 characters use the null terminator at the end '\\0'.\n", "name": "ADSB_CALLSIGN_1", "rebootRequired": true, "shortDesc": "First 4 characters of CALLSIGN", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "ADSB", "longDesc": "Sets second 4 characters of a total of 8. Valid characters are A-Z, 0-9, \" \" only. Example \"TEST\" -> 1413829460\nFor CALLSIGN shorter than 8 characters use the null terminator at the end '\\0'.\n", "name": "ADSB_CALLSIGN_2", "rebootRequired": true, "shortDesc": "Second 4 characters of CALLSIGN", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "ADSB", "longDesc": "Sets the vehicle emergency state\n", "max": 6, "min": 0, "name": "ADSB_EMERGC", "shortDesc": "ADSB-Out Emergency State", "type": "Int32", "values": [{"description": "NoEmergency", "value": 0}, {"description": "General", "value": 1}, {"description": "Medical", "value": 2}, {"description": "LowFuel", "value": 3}, {"description": "NoCommunications", "value": 4}, {"description": "Interference", "value": 5}, {"description": "Downed", "value": 6}]}, {"category": "Standard", "default": 14, "group": "ADSB", "longDesc": "Configure the emitter type of the vehicle.\n", "max": 19, "min": 0, "name": "ADSB_EMIT_TYPE", "rebootRequired": true, "shortDesc": "ADSB-Out Vehicle Emitter Type", "type": "Int32", "values": [{"description": "Unknown", "value": 0}, {"description": "Light", "value": 1}, {"description": "Small", "value": 2}, {"description": "Large", "value": 3}, {"description": "HighVortex", "value": 4}, {"description": "Heavy", "value": 5}, {"description": "Performance", "value": 6}, {"description": "Rotorcraft", "value": 7}, {"description": "RESERVED", "value": 8}, {"description": "Glider", "value": 9}, {"description": "LightAir", "value": 10}, {"description": "Parachute", "value": 11}, {"description": "UltraLight", "value": 12}, {"description": "RESERVED", "value": 13}, {"description": "UAV", "value": 14}, {"description": "Space", "value": 15}, {"description": "RESERVED", "value": 16}, {"description": "EmergencySurf", "value": 17}, {"description": "ServiceSurf", "value": 18}, {"description": "PointObstacle", "value": 19}]}, {"category": "Standard", "default": 0, "group": "ADSB", "longDesc": "Sets GPS lataral offset encoding\n", "max": 7, "min": 0, "name": "ADSB_GPS_OFF_LAT", "shortDesc": "ADSB-Out GPS Offset lat", "type": "Int32", "values": [{"description": "NoData", "value": 0}, {"description": "LatLeft2M", "value": 1}, {"description": "LatLeft4M", "value": 2}, {"description": "LatLeft6M", "value": 3}, {"description": "LatRight0M", "value": 4}, {"description": "LatRight2M", "value": 5}, {"description": "LatRight4M", "value": 6}, {"description": "LatRight6M", "value": 7}]}, {"category": "Standard", "default": 0, "group": "ADSB", "longDesc": "Sets GPS longitudinal offset encoding\n", "max": 1, "min": 0, "name": "ADSB_GPS_OFF_LON", "shortDesc": "ADSB-Out GPS Offset lon", "type": "Int32", "values": [{"description": "NoData", "value": 0}, {"description": "AppliedBySensor", "value": 1}]}, {"category": "Standard", "default": -1, "group": "ADSB", "longDesc": "Vehicle ICAO ID. Use -1 to disable.\n", "max": 16777215, "min": -1, "name": "ADSB_ICAO_ID", "rebootRequired": true, "shortDesc": "ADSB-Out ICAO ID", "type": "Int32"}, {"category": "Standard", "default": -1, "group": "ADSB", "longDesc": "Optional second ownship ICAO ID used to filter self-detections. Use -1 to disable.\n", "max": 16777215, "min": -1, "name": "ADSB_ICAO_ID_2", "rebootRequired": true, "shortDesc": "Secondary ownship ICAO ID", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "ADSB", "longDesc": "This vehicle is always tracked. Use 0 to disable.\n", "max": 16777215, "min": 0, "name": "ADSB_ICAO_SPECL", "shortDesc": "ADSB-In Special ICAO configuration", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "ADSB", "longDesc": "Enable Identification of Position feature\n", "name": "ADSB_IDENT", "shortDesc": "ADSB-Out Ident Configuration", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 1, "group": "ADSB", "longDesc": "Report the length and width of the vehicle in meters. In most cases, use '1' for the smallest vehicle size.\n", "max": 15, "min": 0, "name": "ADSB_LEN_WIDTH", "rebootRequired": true, "shortDesc": "ADSB-Out Vehicle Size Configuration", "type": "Int32", "values": [{"description": "SizeUnknown", "value": 0}, {"description": "Len15_Wid23", "value": 1}, {"description": "Len25_Wid28", "value": 2}, {"description": "Len25_Wid34", "value": 3}, {"description": "Len35_Wid33", "value": 4}, {"description": "Len35_Wid38", "value": 5}, {"description": "Len45_Wid39", "value": 6}, {"description": "Len45_Wid45", "value": 7}, {"description": "Len55_Wid45", "value": 8}, {"description": "Len55_Wid52", "value": 9}, {"description": "Len65_Wid59", "value": 10}, {"description": "Len65_Wid67", "value": 11}, {"description": "Len75_Wid72", "value": 12}, {"description": "Len75_Wid80", "value": 13}, {"description": "Len85_Wid80", "value": 14}, {"description": "Len85_Wid90", "value": 15}]}, {"category": "Standard", "default": 25, "group": "ADSB", "longDesc": "Change number of targets to track\n", "max": 50, "min": 0, "name": "ADSB_LIST_MAX", "rebootRequired": true, "shortDesc": "ADSB-In Vehicle List Size", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "ADSB", "longDesc": "Informs ADSB vehicles of this vehicle's max speed capability\n", "max": 6, "min": 0, "name": "ADSB_MAX_SPEED", "rebootRequired": true, "shortDesc": "ADSB-Out Vehicle Max Speed", "type": "Int32", "values": [{"description": "UnknownMaxSpeed", "value": 0}, {"description": "75Kts", "value": 1}, {"description": "150Kts", "value": 2}, {"description": "300Kts", "value": 3}, {"description": "600Kts", "value": 4}, {"description": "1200Kts", "value": 5}, {"description": "Over1200Kts", "value": 6}]}, {"category": "Standard", "default": 1200, "group": "ADSB", "longDesc": "This parameter defines the squawk code. Value should be between 0000 and 7777.\n", "max": 7777, "min": 0, "name": "ADSB_SQUAWK", "shortDesc": "ADSB-Out squawk code configuration", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Select what should be output on SIM Channel 1.\n\nThe default failsafe value is set according to the selected function:\n- 'Min' for ConstantMin\n- 'Max' for ConstantMax\n- 'Max' for Parachute\n- ('Max'+'Min')/2 for Servos\n- 'Disarmed' for the rest\n\n", "name": "PWM_MAIN_FUNC1", "shortDesc": "SIM Channel 1 Output Function", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Constant Min", "value": 1}, {"description": "Constant Max", "value": 2}, {"description": "Motor 1", "value": 101}, {"description": "Motor 2", "value": 102}, {"description": "Motor 3", "value": 103}, {"description": "Motor 4", "value": 104}, {"description": "Motor 5", "value": 105}, {"description": "Motor 6", "value": 106}, {"description": "Motor 7", "value": 107}, {"description": "Motor 8", "value": 108}, {"description": "Motor 9", "value": 109}, {"description": "Motor 10", "value": 110}, {"description": "Motor 11", "value": 111}, {"description": "Motor 12", "value": 112}, {"description": "Servo 1", "value": 201}, {"description": "Servo 2", "value": 202}, {"description": "Servo 3", "value": 203}, {"description": "Servo 4", "value": 204}, {"description": "Servo 5", "value": 205}, {"description": "Servo 6", "value": 206}, {"description": "Servo 7", "value": 207}, {"description": "Servo 8", "value": 208}, {"description": "Servo 9", "value": 209}, {"description": "Servo 10", "value": 210}, {"description": "Servo 11", "value": 211}, {"description": "Servo 12", "value": 212}, {"description": "Servo 13", "value": 213}, {"description": "Servo 14", "value": 214}, {"description": "Servo 15", "value": 215}, {"description": "Peripheral via Actuator Set 1", "value": 301}, {"description": "Peripheral via Actuator Set 2", "value": 302}, {"description": "Peripheral via Actuator Set 3", "value": 303}, {"description": "Peripheral via Actuator Set 4", "value": 304}, {"description": "Peripheral via Actuator Set 5", "value": 305}, {"description": "Peripheral via Actuator Set 6", "value": 306}, {"description": "Landing Gear", "value": 400}, {"description": "Parachute", "value": 401}, {"description": "RC Roll", "value": 402}, {"description": "RC Pitch", "value": 403}, {"description": "RC Throttle", "value": 404}, {"description": "RC Yaw", "value": 405}, {"description": "RC Flaps", "value": 406}, {"description": "RC AUX 1", "value": 407}, {"description": "RC AUX 2", "value": 408}, {"description": "RC AUX 3", "value": 409}, {"description": "RC AUX 4", "value": 410}, {"description": "RC AUX 5", "value": 411}, {"description": "RC AUX 6", "value": 412}, {"description": "Gimbal Roll", "value": 420}, {"description": "Gimbal Pitch", "value": 421}, {"description": "Gimbal Yaw", "value": 422}, {"description": "Gripper", "value": 430}, {"description": "Landing Gear Wheel", "value": 440}, {"description": "IC Engine Ignition", "value": 450}, {"description": "IC Engine Throttle", "value": 451}, {"description": "IC Engine Choke", "value": 452}, {"description": "IC Engine Starter", "value": 453}]}, {"category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Select what should be output on SIM Channel 10.\n\nThe default failsafe value is set according to the selected function:\n- 'Min' for ConstantMin\n- 'Max' for ConstantMax\n- 'Max' for Parachute\n- ('Max'+'Min')/2 for Servos\n- 'Disarmed' for the rest\n\n", "name": "PWM_MAIN_FUNC10", "shortDesc": "SIM Channel 10 Output Function", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Constant Min", "value": 1}, {"description": "Constant Max", "value": 2}, {"description": "Motor 1", "value": 101}, {"description": "Motor 2", "value": 102}, {"description": "Motor 3", "value": 103}, {"description": "Motor 4", "value": 104}, {"description": "Motor 5", "value": 105}, {"description": "Motor 6", "value": 106}, {"description": "Motor 7", "value": 107}, {"description": "Motor 8", "value": 108}, {"description": "Motor 9", "value": 109}, {"description": "Motor 10", "value": 110}, {"description": "Motor 11", "value": 111}, {"description": "Motor 12", "value": 112}, {"description": "Servo 1", "value": 201}, {"description": "Servo 2", "value": 202}, {"description": "Servo 3", "value": 203}, {"description": "Servo 4", "value": 204}, {"description": "Servo 5", "value": 205}, {"description": "Servo 6", "value": 206}, {"description": "Servo 7", "value": 207}, {"description": "Servo 8", "value": 208}, {"description": "Servo 9", "value": 209}, {"description": "Servo 10", "value": 210}, {"description": "Servo 11", "value": 211}, {"description": "Servo 12", "value": 212}, {"description": "Servo 13", "value": 213}, {"description": "Servo 14", "value": 214}, {"description": "Servo 15", "value": 215}, {"description": "Peripheral via Actuator Set 1", "value": 301}, {"description": "Peripheral via Actuator Set 2", "value": 302}, {"description": "Peripheral via Actuator Set 3", "value": 303}, {"description": "Peripheral via Actuator Set 4", "value": 304}, {"description": "Peripheral via Actuator Set 5", "value": 305}, {"description": "Peripheral via Actuator Set 6", "value": 306}, {"description": "Landing Gear", "value": 400}, {"description": "Parachute", "value": 401}, {"description": "RC Roll", "value": 402}, {"description": "RC Pitch", "value": 403}, {"description": "RC Throttle", "value": 404}, {"description": "RC Yaw", "value": 405}, {"description": "RC Flaps", "value": 406}, {"description": "RC AUX 1", "value": 407}, {"description": "RC AUX 2", "value": 408}, {"description": "RC AUX 3", "value": 409}, {"description": "RC AUX 4", "value": 410}, {"description": "RC AUX 5", "value": 411}, {"description": "RC AUX 6", "value": 412}, {"description": "Gimbal Roll", "value": 420}, {"description": "Gimbal Pitch", "value": 421}, {"description": "Gimbal Yaw", "value": 422}, {"description": "Gripper", "value": 430}, {"description": "Landing Gear Wheel", "value": 440}, {"description": "IC Engine Ignition", "value": 450}, {"description": "IC Engine Throttle", "value": 451}, {"description": "IC Engine Choke", "value": 452}, {"description": "IC Engine Starter", "value": 453}]}, {"category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Select what should be output on SIM Channel 11.\n\nThe default failsafe value is set according to the selected function:\n- 'Min' for ConstantMin\n- 'Max' for ConstantMax\n- 'Max' for Parachute\n- ('Max'+'Min')/2 for Servos\n- 'Disarmed' for the rest\n\n", "name": "PWM_MAIN_FUNC11", "shortDesc": "SIM Channel 11 Output Function", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Constant Min", "value": 1}, {"description": "Constant Max", "value": 2}, {"description": "Motor 1", "value": 101}, {"description": "Motor 2", "value": 102}, {"description": "Motor 3", "value": 103}, {"description": "Motor 4", "value": 104}, {"description": "Motor 5", "value": 105}, {"description": "Motor 6", "value": 106}, {"description": "Motor 7", "value": 107}, {"description": "Motor 8", "value": 108}, {"description": "Motor 9", "value": 109}, {"description": "Motor 10", "value": 110}, {"description": "Motor 11", "value": 111}, {"description": "Motor 12", "value": 112}, {"description": "Servo 1", "value": 201}, {"description": "Servo 2", "value": 202}, {"description": "Servo 3", "value": 203}, {"description": "Servo 4", "value": 204}, {"description": "Servo 5", "value": 205}, {"description": "Servo 6", "value": 206}, {"description": "Servo 7", "value": 207}, {"description": "Servo 8", "value": 208}, {"description": "Servo 9", "value": 209}, {"description": "Servo 10", "value": 210}, {"description": "Servo 11", "value": 211}, {"description": "Servo 12", "value": 212}, {"description": "Servo 13", "value": 213}, {"description": "Servo 14", "value": 214}, {"description": "Servo 15", "value": 215}, {"description": "Peripheral via Actuator Set 1", "value": 301}, {"description": "Peripheral via Actuator Set 2", "value": 302}, {"description": "Peripheral via Actuator Set 3", "value": 303}, {"description": "Peripheral via Actuator Set 4", "value": 304}, {"description": "Peripheral via Actuator Set 5", "value": 305}, {"description": "Peripheral via Actuator Set 6", "value": 306}, {"description": "Landing Gear", "value": 400}, {"description": "Parachute", "value": 401}, {"description": "RC Roll", "value": 402}, {"description": "RC Pitch", "value": 403}, {"description": "RC Throttle", "value": 404}, {"description": "RC Yaw", "value": 405}, {"description": "RC Flaps", "value": 406}, {"description": "RC AUX 1", "value": 407}, {"description": "RC AUX 2", "value": 408}, {"description": "RC AUX 3", "value": 409}, {"description": "RC AUX 4", "value": 410}, {"description": "RC AUX 5", "value": 411}, {"description": "RC AUX 6", "value": 412}, {"description": "Gimbal Roll", "value": 420}, {"description": "Gimbal Pitch", "value": 421}, {"description": "Gimbal Yaw", "value": 422}, {"description": "Gripper", "value": 430}, {"description": "Landing Gear Wheel", "value": 440}, {"description": "IC Engine Ignition", "value": 450}, {"description": "IC Engine Throttle", "value": 451}, {"description": "IC Engine Choke", "value": 452}, {"description": "IC Engine Starter", "value": 453}]}, {"category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Select what should be output on SIM Channel 12.\n\nThe default failsafe value is set according to the selected function:\n- 'Min' for ConstantMin\n- 'Max' for ConstantMax\n- 'Max' for Parachute\n- ('Max'+'Min')/2 for Servos\n- 'Disarmed' for the rest\n\n", "name": "PWM_MAIN_FUNC12", "shortDesc": "SIM Channel 12 Output Function", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Constant Min", "value": 1}, {"description": "Constant Max", "value": 2}, {"description": "Motor 1", "value": 101}, {"description": "Motor 2", "value": 102}, {"description": "Motor 3", "value": 103}, {"description": "Motor 4", "value": 104}, {"description": "Motor 5", "value": 105}, {"description": "Motor 6", "value": 106}, {"description": "Motor 7", "value": 107}, {"description": "Motor 8", "value": 108}, {"description": "Motor 9", "value": 109}, {"description": "Motor 10", "value": 110}, {"description": "Motor 11", "value": 111}, {"description": "Motor 12", "value": 112}, {"description": "Servo 1", "value": 201}, {"description": "Servo 2", "value": 202}, {"description": "Servo 3", "value": 203}, {"description": "Servo 4", "value": 204}, {"description": "Servo 5", "value": 205}, {"description": "Servo 6", "value": 206}, {"description": "Servo 7", "value": 207}, {"description": "Servo 8", "value": 208}, {"description": "Servo 9", "value": 209}, {"description": "Servo 10", "value": 210}, {"description": "Servo 11", "value": 211}, {"description": "Servo 12", "value": 212}, {"description": "Servo 13", "value": 213}, {"description": "Servo 14", "value": 214}, {"description": "Servo 15", "value": 215}, {"description": "Peripheral via Actuator Set 1", "value": 301}, {"description": "Peripheral via Actuator Set 2", "value": 302}, {"description": "Peripheral via Actuator Set 3", "value": 303}, {"description": "Peripheral via Actuator Set 4", "value": 304}, {"description": "Peripheral via Actuator Set 5", "value": 305}, {"description": "Peripheral via Actuator Set 6", "value": 306}, {"description": "Landing Gear", "value": 400}, {"description": "Parachute", "value": 401}, {"description": "RC Roll", "value": 402}, {"description": "RC Pitch", "value": 403}, {"description": "RC Throttle", "value": 404}, {"description": "RC Yaw", "value": 405}, {"description": "RC Flaps", "value": 406}, {"description": "RC AUX 1", "value": 407}, {"description": "RC AUX 2", "value": 408}, {"description": "RC AUX 3", "value": 409}, {"description": "RC AUX 4", "value": 410}, {"description": "RC AUX 5", "value": 411}, {"description": "RC AUX 6", "value": 412}, {"description": "Gimbal Roll", "value": 420}, {"description": "Gimbal Pitch", "value": 421}, {"description": "Gimbal Yaw", "value": 422}, {"description": "Gripper", "value": 430}, {"description": "Landing Gear Wheel", "value": 440}, {"description": "IC Engine Ignition", "value": 450}, {"description": "IC Engine Throttle", "value": 451}, {"description": "IC Engine Choke", "value": 452}, {"description": "IC Engine Starter", "value": 453}]}, {"category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Select what should be output on SIM Channel 13.\n\nThe default failsafe value is set according to the selected function:\n- 'Min' for ConstantMin\n- 'Max' for ConstantMax\n- 'Max' for Parachute\n- ('Max'+'Min')/2 for Servos\n- 'Disarmed' for the rest\n\n", "name": "PWM_MAIN_FUNC13", "shortDesc": "SIM Channel 13 Output Function", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Constant Min", "value": 1}, {"description": "Constant Max", "value": 2}, {"description": "Motor 1", "value": 101}, {"description": "Motor 2", "value": 102}, {"description": "Motor 3", "value": 103}, {"description": "Motor 4", "value": 104}, {"description": "Motor 5", "value": 105}, {"description": "Motor 6", "value": 106}, {"description": "Motor 7", "value": 107}, {"description": "Motor 8", "value": 108}, {"description": "Motor 9", "value": 109}, {"description": "Motor 10", "value": 110}, {"description": "Motor 11", "value": 111}, {"description": "Motor 12", "value": 112}, {"description": "Servo 1", "value": 201}, {"description": "Servo 2", "value": 202}, {"description": "Servo 3", "value": 203}, {"description": "Servo 4", "value": 204}, {"description": "Servo 5", "value": 205}, {"description": "Servo 6", "value": 206}, {"description": "Servo 7", "value": 207}, {"description": "Servo 8", "value": 208}, {"description": "Servo 9", "value": 209}, {"description": "Servo 10", "value": 210}, {"description": "Servo 11", "value": 211}, {"description": "Servo 12", "value": 212}, {"description": "Servo 13", "value": 213}, {"description": "Servo 14", "value": 214}, {"description": "Servo 15", "value": 215}, {"description": "Peripheral via Actuator Set 1", "value": 301}, {"description": "Peripheral via Actuator Set 2", "value": 302}, {"description": "Peripheral via Actuator Set 3", "value": 303}, {"description": "Peripheral via Actuator Set 4", "value": 304}, {"description": "Peripheral via Actuator Set 5", "value": 305}, {"description": "Peripheral via Actuator Set 6", "value": 306}, {"description": "Landing Gear", "value": 400}, {"description": "Parachute", "value": 401}, {"description": "RC Roll", "value": 402}, {"description": "RC Pitch", "value": 403}, {"description": "RC Throttle", "value": 404}, {"description": "RC Yaw", "value": 405}, {"description": "RC Flaps", "value": 406}, {"description": "RC AUX 1", "value": 407}, {"description": "RC AUX 2", "value": 408}, {"description": "RC AUX 3", "value": 409}, {"description": "RC AUX 4", "value": 410}, {"description": "RC AUX 5", "value": 411}, {"description": "RC AUX 6", "value": 412}, {"description": "Gimbal Roll", "value": 420}, {"description": "Gimbal Pitch", "value": 421}, {"description": "Gimbal Yaw", "value": 422}, {"description": "Gripper", "value": 430}, {"description": "Landing Gear Wheel", "value": 440}, {"description": "IC Engine Ignition", "value": 450}, {"description": "IC Engine Throttle", "value": 451}, {"description": "IC Engine Choke", "value": 452}, {"description": "IC Engine Starter", "value": 453}]}, {"category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Select what should be output on SIM Channel 14.\n\nThe default failsafe value is set according to the selected function:\n- 'Min' for ConstantMin\n- 'Max' for ConstantMax\n- 'Max' for Parachute\n- ('Max'+'Min')/2 for Servos\n- 'Disarmed' for the rest\n\n", "name": "PWM_MAIN_FUNC14", "shortDesc": "SIM Channel 14 Output Function", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Constant Min", "value": 1}, {"description": "Constant Max", "value": 2}, {"description": "Motor 1", "value": 101}, {"description": "Motor 2", "value": 102}, {"description": "Motor 3", "value": 103}, {"description": "Motor 4", "value": 104}, {"description": "Motor 5", "value": 105}, {"description": "Motor 6", "value": 106}, {"description": "Motor 7", "value": 107}, {"description": "Motor 8", "value": 108}, {"description": "Motor 9", "value": 109}, {"description": "Motor 10", "value": 110}, {"description": "Motor 11", "value": 111}, {"description": "Motor 12", "value": 112}, {"description": "Servo 1", "value": 201}, {"description": "Servo 2", "value": 202}, {"description": "Servo 3", "value": 203}, {"description": "Servo 4", "value": 204}, {"description": "Servo 5", "value": 205}, {"description": "Servo 6", "value": 206}, {"description": "Servo 7", "value": 207}, {"description": "Servo 8", "value": 208}, {"description": "Servo 9", "value": 209}, {"description": "Servo 10", "value": 210}, {"description": "Servo 11", "value": 211}, {"description": "Servo 12", "value": 212}, {"description": "Servo 13", "value": 213}, {"description": "Servo 14", "value": 214}, {"description": "Servo 15", "value": 215}, {"description": "Peripheral via Actuator Set 1", "value": 301}, {"description": "Peripheral via Actuator Set 2", "value": 302}, {"description": "Peripheral via Actuator Set 3", "value": 303}, {"description": "Peripheral via Actuator Set 4", "value": 304}, {"description": "Peripheral via Actuator Set 5", "value": 305}, {"description": "Peripheral via Actuator Set 6", "value": 306}, {"description": "Landing Gear", "value": 400}, {"description": "Parachute", "value": 401}, {"description": "RC Roll", "value": 402}, {"description": "RC Pitch", "value": 403}, {"description": "RC Throttle", "value": 404}, {"description": "RC Yaw", "value": 405}, {"description": "RC Flaps", "value": 406}, {"description": "RC AUX 1", "value": 407}, {"description": "RC AUX 2", "value": 408}, {"description": "RC AUX 3", "value": 409}, {"description": "RC AUX 4", "value": 410}, {"description": "RC AUX 5", "value": 411}, {"description": "RC AUX 6", "value": 412}, {"description": "Gimbal Roll", "value": 420}, {"description": "Gimbal Pitch", "value": 421}, {"description": "Gimbal Yaw", "value": 422}, {"description": "Gripper", "value": 430}, {"description": "Landing Gear Wheel", "value": 440}, {"description": "IC Engine Ignition", "value": 450}, {"description": "IC Engine Throttle", "value": 451}, {"description": "IC Engine Choke", "value": 452}, {"description": "IC Engine Starter", "value": 453}]}, {"category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Select what should be output on SIM Channel 15.\n\nThe default failsafe value is set according to the selected function:\n- 'Min' for ConstantMin\n- 'Max' for ConstantMax\n- 'Max' for Parachute\n- ('Max'+'Min')/2 for Servos\n- 'Disarmed' for the rest\n\n", "name": "PWM_MAIN_FUNC15", "shortDesc": "SIM Channel 15 Output Function", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Constant Min", "value": 1}, {"description": "Constant Max", "value": 2}, {"description": "Motor 1", "value": 101}, {"description": "Motor 2", "value": 102}, {"description": "Motor 3", "value": 103}, {"description": "Motor 4", "value": 104}, {"description": "Motor 5", "value": 105}, {"description": "Motor 6", "value": 106}, {"description": "Motor 7", "value": 107}, {"description": "Motor 8", "value": 108}, {"description": "Motor 9", "value": 109}, {"description": "Motor 10", "value": 110}, {"description": "Motor 11", "value": 111}, {"description": "Motor 12", "value": 112}, {"description": "Servo 1", "value": 201}, {"description": "Servo 2", "value": 202}, {"description": "Servo 3", "value": 203}, {"description": "Servo 4", "value": 204}, {"description": "Servo 5", "value": 205}, {"description": "Servo 6", "value": 206}, {"description": "Servo 7", "value": 207}, {"description": "Servo 8", "value": 208}, {"description": "Servo 9", "value": 209}, {"description": "Servo 10", "value": 210}, {"description": "Servo 11", "value": 211}, {"description": "Servo 12", "value": 212}, {"description": "Servo 13", "value": 213}, {"description": "Servo 14", "value": 214}, {"description": "Servo 15", "value": 215}, {"description": "Peripheral via Actuator Set 1", "value": 301}, {"description": "Peripheral via Actuator Set 2", "value": 302}, {"description": "Peripheral via Actuator Set 3", "value": 303}, {"description": "Peripheral via Actuator Set 4", "value": 304}, {"description": "Peripheral via Actuator Set 5", "value": 305}, {"description": "Peripheral via Actuator Set 6", "value": 306}, {"description": "Landing Gear", "value": 400}, {"description": "Parachute", "value": 401}, {"description": "RC Roll", "value": 402}, {"description": "RC Pitch", "value": 403}, {"description": "RC Throttle", "value": 404}, {"description": "RC Yaw", "value": 405}, {"description": "RC Flaps", "value": 406}, {"description": "RC AUX 1", "value": 407}, {"description": "RC AUX 2", "value": 408}, {"description": "RC AUX 3", "value": 409}, {"description": "RC AUX 4", "value": 410}, {"description": "RC AUX 5", "value": 411}, {"description": "RC AUX 6", "value": 412}, {"description": "Gimbal Roll", "value": 420}, {"description": "Gimbal Pitch", "value": 421}, {"description": "Gimbal Yaw", "value": 422}, {"description": "Gripper", "value": 430}, {"description": "Landing Gear Wheel", "value": 440}, {"description": "IC Engine Ignition", "value": 450}, {"description": "IC Engine Throttle", "value": 451}, {"description": "IC Engine Choke", "value": 452}, {"description": "IC Engine Starter", "value": 453}]}, {"category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Select what should be output on SIM Channel 16.\n\nThe default failsafe value is set according to the selected function:\n- 'Min' for ConstantMin\n- 'Max' for ConstantMax\n- 'Max' for Parachute\n- ('Max'+'Min')/2 for Servos\n- 'Disarmed' for the rest\n\n", "name": "PWM_MAIN_FUNC16", "shortDesc": "SIM Channel 16 Output Function", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Constant Min", "value": 1}, {"description": "Constant Max", "value": 2}, {"description": "Motor 1", "value": 101}, {"description": "Motor 2", "value": 102}, {"description": "Motor 3", "value": 103}, {"description": "Motor 4", "value": 104}, {"description": "Motor 5", "value": 105}, {"description": "Motor 6", "value": 106}, {"description": "Motor 7", "value": 107}, {"description": "Motor 8", "value": 108}, {"description": "Motor 9", "value": 109}, {"description": "Motor 10", "value": 110}, {"description": "Motor 11", "value": 111}, {"description": "Motor 12", "value": 112}, {"description": "Servo 1", "value": 201}, {"description": "Servo 2", "value": 202}, {"description": "Servo 3", "value": 203}, {"description": "Servo 4", "value": 204}, {"description": "Servo 5", "value": 205}, {"description": "Servo 6", "value": 206}, {"description": "Servo 7", "value": 207}, {"description": "Servo 8", "value": 208}, {"description": "Servo 9", "value": 209}, {"description": "Servo 10", "value": 210}, {"description": "Servo 11", "value": 211}, {"description": "Servo 12", "value": 212}, {"description": "Servo 13", "value": 213}, {"description": "Servo 14", "value": 214}, {"description": "Servo 15", "value": 215}, {"description": "Peripheral via Actuator Set 1", "value": 301}, {"description": "Peripheral via Actuator Set 2", "value": 302}, {"description": "Peripheral via Actuator Set 3", "value": 303}, {"description": "Peripheral via Actuator Set 4", "value": 304}, {"description": "Peripheral via Actuator Set 5", "value": 305}, {"description": "Peripheral via Actuator Set 6", "value": 306}, {"description": "Landing Gear", "value": 400}, {"description": "Parachute", "value": 401}, {"description": "RC Roll", "value": 402}, {"description": "RC Pitch", "value": 403}, {"description": "RC Throttle", "value": 404}, {"description": "RC Yaw", "value": 405}, {"description": "RC Flaps", "value": 406}, {"description": "RC AUX 1", "value": 407}, {"description": "RC AUX 2", "value": 408}, {"description": "RC AUX 3", "value": 409}, {"description": "RC AUX 4", "value": 410}, {"description": "RC AUX 5", "value": 411}, {"description": "RC AUX 6", "value": 412}, {"description": "Gimbal Roll", "value": 420}, {"description": "Gimbal Pitch", "value": 421}, {"description": "Gimbal Yaw", "value": 422}, {"description": "Gripper", "value": 430}, {"description": "Landing Gear Wheel", "value": 440}, {"description": "IC Engine Ignition", "value": 450}, {"description": "IC Engine Throttle", "value": 451}, {"description": "IC Engine Choke", "value": 452}, {"description": "IC Engine Starter", "value": 453}]}, {"category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Select what should be output on SIM Channel 2.\n\nThe default failsafe value is set according to the selected function:\n- 'Min' for ConstantMin\n- 'Max' for ConstantMax\n- 'Max' for Parachute\n- ('Max'+'Min')/2 for Servos\n- 'Disarmed' for the rest\n\n", "name": "PWM_MAIN_FUNC2", "shortDesc": "SIM Channel 2 Output Function", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Constant Min", "value": 1}, {"description": "Constant Max", "value": 2}, {"description": "Motor 1", "value": 101}, {"description": "Motor 2", "value": 102}, {"description": "Motor 3", "value": 103}, {"description": "Motor 4", "value": 104}, {"description": "Motor 5", "value": 105}, {"description": "Motor 6", "value": 106}, {"description": "Motor 7", "value": 107}, {"description": "Motor 8", "value": 108}, {"description": "Motor 9", "value": 109}, {"description": "Motor 10", "value": 110}, {"description": "Motor 11", "value": 111}, {"description": "Motor 12", "value": 112}, {"description": "Servo 1", "value": 201}, {"description": "Servo 2", "value": 202}, {"description": "Servo 3", "value": 203}, {"description": "Servo 4", "value": 204}, {"description": "Servo 5", "value": 205}, {"description": "Servo 6", "value": 206}, {"description": "Servo 7", "value": 207}, {"description": "Servo 8", "value": 208}, {"description": "Servo 9", "value": 209}, {"description": "Servo 10", "value": 210}, {"description": "Servo 11", "value": 211}, {"description": "Servo 12", "value": 212}, {"description": "Servo 13", "value": 213}, {"description": "Servo 14", "value": 214}, {"description": "Servo 15", "value": 215}, {"description": "Peripheral via Actuator Set 1", "value": 301}, {"description": "Peripheral via Actuator Set 2", "value": 302}, {"description": "Peripheral via Actuator Set 3", "value": 303}, {"description": "Peripheral via Actuator Set 4", "value": 304}, {"description": "Peripheral via Actuator Set 5", "value": 305}, {"description": "Peripheral via Actuator Set 6", "value": 306}, {"description": "Landing Gear", "value": 400}, {"description": "Parachute", "value": 401}, {"description": "RC Roll", "value": 402}, {"description": "RC Pitch", "value": 403}, {"description": "RC Throttle", "value": 404}, {"description": "RC Yaw", "value": 405}, {"description": "RC Flaps", "value": 406}, {"description": "RC AUX 1", "value": 407}, {"description": "RC AUX 2", "value": 408}, {"description": "RC AUX 3", "value": 409}, {"description": "RC AUX 4", "value": 410}, {"description": "RC AUX 5", "value": 411}, {"description": "RC AUX 6", "value": 412}, {"description": "Gimbal Roll", "value": 420}, {"description": "Gimbal Pitch", "value": 421}, {"description": "Gimbal Yaw", "value": 422}, {"description": "Gripper", "value": 430}, {"description": "Landing Gear Wheel", "value": 440}, {"description": "IC Engine Ignition", "value": 450}, {"description": "IC Engine Throttle", "value": 451}, {"description": "IC Engine Choke", "value": 452}, {"description": "IC Engine Starter", "value": 453}]}, {"category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Select what should be output on SIM Channel 3.\n\nThe default failsafe value is set according to the selected function:\n- 'Min' for ConstantMin\n- 'Max' for ConstantMax\n- 'Max' for Parachute\n- ('Max'+'Min')/2 for Servos\n- 'Disarmed' for the rest\n\n", "name": "PWM_MAIN_FUNC3", "shortDesc": "SIM Channel 3 Output Function", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Constant Min", "value": 1}, {"description": "Constant Max", "value": 2}, {"description": "Motor 1", "value": 101}, {"description": "Motor 2", "value": 102}, {"description": "Motor 3", "value": 103}, {"description": "Motor 4", "value": 104}, {"description": "Motor 5", "value": 105}, {"description": "Motor 6", "value": 106}, {"description": "Motor 7", "value": 107}, {"description": "Motor 8", "value": 108}, {"description": "Motor 9", "value": 109}, {"description": "Motor 10", "value": 110}, {"description": "Motor 11", "value": 111}, {"description": "Motor 12", "value": 112}, {"description": "Servo 1", "value": 201}, {"description": "Servo 2", "value": 202}, {"description": "Servo 3", "value": 203}, {"description": "Servo 4", "value": 204}, {"description": "Servo 5", "value": 205}, {"description": "Servo 6", "value": 206}, {"description": "Servo 7", "value": 207}, {"description": "Servo 8", "value": 208}, {"description": "Servo 9", "value": 209}, {"description": "Servo 10", "value": 210}, {"description": "Servo 11", "value": 211}, {"description": "Servo 12", "value": 212}, {"description": "Servo 13", "value": 213}, {"description": "Servo 14", "value": 214}, {"description": "Servo 15", "value": 215}, {"description": "Peripheral via Actuator Set 1", "value": 301}, {"description": "Peripheral via Actuator Set 2", "value": 302}, {"description": "Peripheral via Actuator Set 3", "value": 303}, {"description": "Peripheral via Actuator Set 4", "value": 304}, {"description": "Peripheral via Actuator Set 5", "value": 305}, {"description": "Peripheral via Actuator Set 6", "value": 306}, {"description": "Landing Gear", "value": 400}, {"description": "Parachute", "value": 401}, {"description": "RC Roll", "value": 402}, {"description": "RC Pitch", "value": 403}, {"description": "RC Throttle", "value": 404}, {"description": "RC Yaw", "value": 405}, {"description": "RC Flaps", "value": 406}, {"description": "RC AUX 1", "value": 407}, {"description": "RC AUX 2", "value": 408}, {"description": "RC AUX 3", "value": 409}, {"description": "RC AUX 4", "value": 410}, {"description": "RC AUX 5", "value": 411}, {"description": "RC AUX 6", "value": 412}, {"description": "Gimbal Roll", "value": 420}, {"description": "Gimbal Pitch", "value": 421}, {"description": "Gimbal Yaw", "value": 422}, {"description": "Gripper", "value": 430}, {"description": "Landing Gear Wheel", "value": 440}, {"description": "IC Engine Ignition", "value": 450}, {"description": "IC Engine Throttle", "value": 451}, {"description": "IC Engine Choke", "value": 452}, {"description": "IC Engine Starter", "value": 453}]}, {"category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Select what should be output on SIM Channel 4.\n\nThe default failsafe value is set according to the selected function:\n- 'Min' for ConstantMin\n- 'Max' for ConstantMax\n- 'Max' for Parachute\n- ('Max'+'Min')/2 for Servos\n- 'Disarmed' for the rest\n\n", "name": "PWM_MAIN_FUNC4", "shortDesc": "SIM Channel 4 Output Function", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Constant Min", "value": 1}, {"description": "Constant Max", "value": 2}, {"description": "Motor 1", "value": 101}, {"description": "Motor 2", "value": 102}, {"description": "Motor 3", "value": 103}, {"description": "Motor 4", "value": 104}, {"description": "Motor 5", "value": 105}, {"description": "Motor 6", "value": 106}, {"description": "Motor 7", "value": 107}, {"description": "Motor 8", "value": 108}, {"description": "Motor 9", "value": 109}, {"description": "Motor 10", "value": 110}, {"description": "Motor 11", "value": 111}, {"description": "Motor 12", "value": 112}, {"description": "Servo 1", "value": 201}, {"description": "Servo 2", "value": 202}, {"description": "Servo 3", "value": 203}, {"description": "Servo 4", "value": 204}, {"description": "Servo 5", "value": 205}, {"description": "Servo 6", "value": 206}, {"description": "Servo 7", "value": 207}, {"description": "Servo 8", "value": 208}, {"description": "Servo 9", "value": 209}, {"description": "Servo 10", "value": 210}, {"description": "Servo 11", "value": 211}, {"description": "Servo 12", "value": 212}, {"description": "Servo 13", "value": 213}, {"description": "Servo 14", "value": 214}, {"description": "Servo 15", "value": 215}, {"description": "Peripheral via Actuator Set 1", "value": 301}, {"description": "Peripheral via Actuator Set 2", "value": 302}, {"description": "Peripheral via Actuator Set 3", "value": 303}, {"description": "Peripheral via Actuator Set 4", "value": 304}, {"description": "Peripheral via Actuator Set 5", "value": 305}, {"description": "Peripheral via Actuator Set 6", "value": 306}, {"description": "Landing Gear", "value": 400}, {"description": "Parachute", "value": 401}, {"description": "RC Roll", "value": 402}, {"description": "RC Pitch", "value": 403}, {"description": "RC Throttle", "value": 404}, {"description": "RC Yaw", "value": 405}, {"description": "RC Flaps", "value": 406}, {"description": "RC AUX 1", "value": 407}, {"description": "RC AUX 2", "value": 408}, {"description": "RC AUX 3", "value": 409}, {"description": "RC AUX 4", "value": 410}, {"description": "RC AUX 5", "value": 411}, {"description": "RC AUX 6", "value": 412}, {"description": "Gimbal Roll", "value": 420}, {"description": "Gimbal Pitch", "value": 421}, {"description": "Gimbal Yaw", "value": 422}, {"description": "Gripper", "value": 430}, {"description": "Landing Gear Wheel", "value": 440}, {"description": "IC Engine Ignition", "value": 450}, {"description": "IC Engine Throttle", "value": 451}, {"description": "IC Engine Choke", "value": 452}, {"description": "IC Engine Starter", "value": 453}]}, {"category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Select what should be output on SIM Channel 5.\n\nThe default failsafe value is set according to the selected function:\n- 'Min' for ConstantMin\n- 'Max' for ConstantMax\n- 'Max' for Parachute\n- ('Max'+'Min')/2 for Servos\n- 'Disarmed' for the rest\n\n", "name": "PWM_MAIN_FUNC5", "shortDesc": "SIM Channel 5 Output Function", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Constant Min", "value": 1}, {"description": "Constant Max", "value": 2}, {"description": "Motor 1", "value": 101}, {"description": "Motor 2", "value": 102}, {"description": "Motor 3", "value": 103}, {"description": "Motor 4", "value": 104}, {"description": "Motor 5", "value": 105}, {"description": "Motor 6", "value": 106}, {"description": "Motor 7", "value": 107}, {"description": "Motor 8", "value": 108}, {"description": "Motor 9", "value": 109}, {"description": "Motor 10", "value": 110}, {"description": "Motor 11", "value": 111}, {"description": "Motor 12", "value": 112}, {"description": "Servo 1", "value": 201}, {"description": "Servo 2", "value": 202}, {"description": "Servo 3", "value": 203}, {"description": "Servo 4", "value": 204}, {"description": "Servo 5", "value": 205}, {"description": "Servo 6", "value": 206}, {"description": "Servo 7", "value": 207}, {"description": "Servo 8", "value": 208}, {"description": "Servo 9", "value": 209}, {"description": "Servo 10", "value": 210}, {"description": "Servo 11", "value": 211}, {"description": "Servo 12", "value": 212}, {"description": "Servo 13", "value": 213}, {"description": "Servo 14", "value": 214}, {"description": "Servo 15", "value": 215}, {"description": "Peripheral via Actuator Set 1", "value": 301}, {"description": "Peripheral via Actuator Set 2", "value": 302}, {"description": "Peripheral via Actuator Set 3", "value": 303}, {"description": "Peripheral via Actuator Set 4", "value": 304}, {"description": "Peripheral via Actuator Set 5", "value": 305}, {"description": "Peripheral via Actuator Set 6", "value": 306}, {"description": "Landing Gear", "value": 400}, {"description": "Parachute", "value": 401}, {"description": "RC Roll", "value": 402}, {"description": "RC Pitch", "value": 403}, {"description": "RC Throttle", "value": 404}, {"description": "RC Yaw", "value": 405}, {"description": "RC Flaps", "value": 406}, {"description": "RC AUX 1", "value": 407}, {"description": "RC AUX 2", "value": 408}, {"description": "RC AUX 3", "value": 409}, {"description": "RC AUX 4", "value": 410}, {"description": "RC AUX 5", "value": 411}, {"description": "RC AUX 6", "value": 412}, {"description": "Gimbal Roll", "value": 420}, {"description": "Gimbal Pitch", "value": 421}, {"description": "Gimbal Yaw", "value": 422}, {"description": "Gripper", "value": 430}, {"description": "Landing Gear Wheel", "value": 440}, {"description": "IC Engine Ignition", "value": 450}, {"description": "IC Engine Throttle", "value": 451}, {"description": "IC Engine Choke", "value": 452}, {"description": "IC Engine Starter", "value": 453}]}, {"category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Select what should be output on SIM Channel 6.\n\nThe default failsafe value is set according to the selected function:\n- 'Min' for ConstantMin\n- 'Max' for ConstantMax\n- 'Max' for Parachute\n- ('Max'+'Min')/2 for Servos\n- 'Disarmed' for the rest\n\n", "name": "PWM_MAIN_FUNC6", "shortDesc": "SIM Channel 6 Output Function", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Constant Min", "value": 1}, {"description": "Constant Max", "value": 2}, {"description": "Motor 1", "value": 101}, {"description": "Motor 2", "value": 102}, {"description": "Motor 3", "value": 103}, {"description": "Motor 4", "value": 104}, {"description": "Motor 5", "value": 105}, {"description": "Motor 6", "value": 106}, {"description": "Motor 7", "value": 107}, {"description": "Motor 8", "value": 108}, {"description": "Motor 9", "value": 109}, {"description": "Motor 10", "value": 110}, {"description": "Motor 11", "value": 111}, {"description": "Motor 12", "value": 112}, {"description": "Servo 1", "value": 201}, {"description": "Servo 2", "value": 202}, {"description": "Servo 3", "value": 203}, {"description": "Servo 4", "value": 204}, {"description": "Servo 5", "value": 205}, {"description": "Servo 6", "value": 206}, {"description": "Servo 7", "value": 207}, {"description": "Servo 8", "value": 208}, {"description": "Servo 9", "value": 209}, {"description": "Servo 10", "value": 210}, {"description": "Servo 11", "value": 211}, {"description": "Servo 12", "value": 212}, {"description": "Servo 13", "value": 213}, {"description": "Servo 14", "value": 214}, {"description": "Servo 15", "value": 215}, {"description": "Peripheral via Actuator Set 1", "value": 301}, {"description": "Peripheral via Actuator Set 2", "value": 302}, {"description": "Peripheral via Actuator Set 3", "value": 303}, {"description": "Peripheral via Actuator Set 4", "value": 304}, {"description": "Peripheral via Actuator Set 5", "value": 305}, {"description": "Peripheral via Actuator Set 6", "value": 306}, {"description": "Landing Gear", "value": 400}, {"description": "Parachute", "value": 401}, {"description": "RC Roll", "value": 402}, {"description": "RC Pitch", "value": 403}, {"description": "RC Throttle", "value": 404}, {"description": "RC Yaw", "value": 405}, {"description": "RC Flaps", "value": 406}, {"description": "RC AUX 1", "value": 407}, {"description": "RC AUX 2", "value": 408}, {"description": "RC AUX 3", "value": 409}, {"description": "RC AUX 4", "value": 410}, {"description": "RC AUX 5", "value": 411}, {"description": "RC AUX 6", "value": 412}, {"description": "Gimbal Roll", "value": 420}, {"description": "Gimbal Pitch", "value": 421}, {"description": "Gimbal Yaw", "value": 422}, {"description": "Gripper", "value": 430}, {"description": "Landing Gear Wheel", "value": 440}, {"description": "IC Engine Ignition", "value": 450}, {"description": "IC Engine Throttle", "value": 451}, {"description": "IC Engine Choke", "value": 452}, {"description": "IC Engine Starter", "value": 453}]}, {"category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Select what should be output on SIM Channel 7.\n\nThe default failsafe value is set according to the selected function:\n- 'Min' for ConstantMin\n- 'Max' for ConstantMax\n- 'Max' for Parachute\n- ('Max'+'Min')/2 for Servos\n- 'Disarmed' for the rest\n\n", "name": "PWM_MAIN_FUNC7", "shortDesc": "SIM Channel 7 Output Function", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Constant Min", "value": 1}, {"description": "Constant Max", "value": 2}, {"description": "Motor 1", "value": 101}, {"description": "Motor 2", "value": 102}, {"description": "Motor 3", "value": 103}, {"description": "Motor 4", "value": 104}, {"description": "Motor 5", "value": 105}, {"description": "Motor 6", "value": 106}, {"description": "Motor 7", "value": 107}, {"description": "Motor 8", "value": 108}, {"description": "Motor 9", "value": 109}, {"description": "Motor 10", "value": 110}, {"description": "Motor 11", "value": 111}, {"description": "Motor 12", "value": 112}, {"description": "Servo 1", "value": 201}, {"description": "Servo 2", "value": 202}, {"description": "Servo 3", "value": 203}, {"description": "Servo 4", "value": 204}, {"description": "Servo 5", "value": 205}, {"description": "Servo 6", "value": 206}, {"description": "Servo 7", "value": 207}, {"description": "Servo 8", "value": 208}, {"description": "Servo 9", "value": 209}, {"description": "Servo 10", "value": 210}, {"description": "Servo 11", "value": 211}, {"description": "Servo 12", "value": 212}, {"description": "Servo 13", "value": 213}, {"description": "Servo 14", "value": 214}, {"description": "Servo 15", "value": 215}, {"description": "Peripheral via Actuator Set 1", "value": 301}, {"description": "Peripheral via Actuator Set 2", "value": 302}, {"description": "Peripheral via Actuator Set 3", "value": 303}, {"description": "Peripheral via Actuator Set 4", "value": 304}, {"description": "Peripheral via Actuator Set 5", "value": 305}, {"description": "Peripheral via Actuator Set 6", "value": 306}, {"description": "Landing Gear", "value": 400}, {"description": "Parachute", "value": 401}, {"description": "RC Roll", "value": 402}, {"description": "RC Pitch", "value": 403}, {"description": "RC Throttle", "value": 404}, {"description": "RC Yaw", "value": 405}, {"description": "RC Flaps", "value": 406}, {"description": "RC AUX 1", "value": 407}, {"description": "RC AUX 2", "value": 408}, {"description": "RC AUX 3", "value": 409}, {"description": "RC AUX 4", "value": 410}, {"description": "RC AUX 5", "value": 411}, {"description": "RC AUX 6", "value": 412}, {"description": "Gimbal Roll", "value": 420}, {"description": "Gimbal Pitch", "value": 421}, {"description": "Gimbal Yaw", "value": 422}, {"description": "Gripper", "value": 430}, {"description": "Landing Gear Wheel", "value": 440}, {"description": "IC Engine Ignition", "value": 450}, {"description": "IC Engine Throttle", "value": 451}, {"description": "IC Engine Choke", "value": 452}, {"description": "IC Engine Starter", "value": 453}]}, {"category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Select what should be output on SIM Channel 8.\n\nThe default failsafe value is set according to the selected function:\n- 'Min' for ConstantMin\n- 'Max' for ConstantMax\n- 'Max' for Parachute\n- ('Max'+'Min')/2 for Servos\n- 'Disarmed' for the rest\n\n", "name": "PWM_MAIN_FUNC8", "shortDesc": "SIM Channel 8 Output Function", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Constant Min", "value": 1}, {"description": "Constant Max", "value": 2}, {"description": "Motor 1", "value": 101}, {"description": "Motor 2", "value": 102}, {"description": "Motor 3", "value": 103}, {"description": "Motor 4", "value": 104}, {"description": "Motor 5", "value": 105}, {"description": "Motor 6", "value": 106}, {"description": "Motor 7", "value": 107}, {"description": "Motor 8", "value": 108}, {"description": "Motor 9", "value": 109}, {"description": "Motor 10", "value": 110}, {"description": "Motor 11", "value": 111}, {"description": "Motor 12", "value": 112}, {"description": "Servo 1", "value": 201}, {"description": "Servo 2", "value": 202}, {"description": "Servo 3", "value": 203}, {"description": "Servo 4", "value": 204}, {"description": "Servo 5", "value": 205}, {"description": "Servo 6", "value": 206}, {"description": "Servo 7", "value": 207}, {"description": "Servo 8", "value": 208}, {"description": "Servo 9", "value": 209}, {"description": "Servo 10", "value": 210}, {"description": "Servo 11", "value": 211}, {"description": "Servo 12", "value": 212}, {"description": "Servo 13", "value": 213}, {"description": "Servo 14", "value": 214}, {"description": "Servo 15", "value": 215}, {"description": "Peripheral via Actuator Set 1", "value": 301}, {"description": "Peripheral via Actuator Set 2", "value": 302}, {"description": "Peripheral via Actuator Set 3", "value": 303}, {"description": "Peripheral via Actuator Set 4", "value": 304}, {"description": "Peripheral via Actuator Set 5", "value": 305}, {"description": "Peripheral via Actuator Set 6", "value": 306}, {"description": "Landing Gear", "value": 400}, {"description": "Parachute", "value": 401}, {"description": "RC Roll", "value": 402}, {"description": "RC Pitch", "value": 403}, {"description": "RC Throttle", "value": 404}, {"description": "RC Yaw", "value": 405}, {"description": "RC Flaps", "value": 406}, {"description": "RC AUX 1", "value": 407}, {"description": "RC AUX 2", "value": 408}, {"description": "RC AUX 3", "value": 409}, {"description": "RC AUX 4", "value": 410}, {"description": "RC AUX 5", "value": 411}, {"description": "RC AUX 6", "value": 412}, {"description": "Gimbal Roll", "value": 420}, {"description": "Gimbal Pitch", "value": 421}, {"description": "Gimbal Yaw", "value": 422}, {"description": "Gripper", "value": 430}, {"description": "Landing Gear Wheel", "value": 440}, {"description": "IC Engine Ignition", "value": 450}, {"description": "IC Engine Throttle", "value": 451}, {"description": "IC Engine Choke", "value": 452}, {"description": "IC Engine Starter", "value": 453}]}, {"category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Select what should be output on SIM Channel 9.\n\nThe default failsafe value is set according to the selected function:\n- 'Min' for ConstantMin\n- 'Max' for ConstantMax\n- 'Max' for Parachute\n- ('Max'+'Min')/2 for Servos\n- 'Disarmed' for the rest\n\n", "name": "PWM_MAIN_FUNC9", "shortDesc": "SIM Channel 9 Output Function", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Constant Min", "value": 1}, {"description": "Constant Max", "value": 2}, {"description": "Motor 1", "value": 101}, {"description": "Motor 2", "value": 102}, {"description": "Motor 3", "value": 103}, {"description": "Motor 4", "value": 104}, {"description": "Motor 5", "value": 105}, {"description": "Motor 6", "value": 106}, {"description": "Motor 7", "value": 107}, {"description": "Motor 8", "value": 108}, {"description": "Motor 9", "value": 109}, {"description": "Motor 10", "value": 110}, {"description": "Motor 11", "value": 111}, {"description": "Motor 12", "value": 112}, {"description": "Servo 1", "value": 201}, {"description": "Servo 2", "value": 202}, {"description": "Servo 3", "value": 203}, {"description": "Servo 4", "value": 204}, {"description": "Servo 5", "value": 205}, {"description": "Servo 6", "value": 206}, {"description": "Servo 7", "value": 207}, {"description": "Servo 8", "value": 208}, {"description": "Servo 9", "value": 209}, {"description": "Servo 10", "value": 210}, {"description": "Servo 11", "value": 211}, {"description": "Servo 12", "value": 212}, {"description": "Servo 13", "value": 213}, {"description": "Servo 14", "value": 214}, {"description": "Servo 15", "value": 215}, {"description": "Peripheral via Actuator Set 1", "value": 301}, {"description": "Peripheral via Actuator Set 2", "value": 302}, {"description": "Peripheral via Actuator Set 3", "value": 303}, {"description": "Peripheral via Actuator Set 4", "value": 304}, {"description": "Peripheral via Actuator Set 5", "value": 305}, {"description": "Peripheral via Actuator Set 6", "value": 306}, {"description": "Landing Gear", "value": 400}, {"description": "Parachute", "value": 401}, {"description": "RC Roll", "value": 402}, {"description": "RC Pitch", "value": 403}, {"description": "RC Throttle", "value": 404}, {"description": "RC Yaw", "value": 405}, {"description": "RC Flaps", "value": 406}, {"description": "RC AUX 1", "value": 407}, {"description": "RC AUX 2", "value": 408}, {"description": "RC AUX 3", "value": 409}, {"description": "RC AUX 4", "value": 410}, {"description": "RC AUX 5", "value": 411}, {"description": "RC AUX 6", "value": 412}, {"description": "Gimbal Roll", "value": 420}, {"description": "Gimbal Pitch", "value": 421}, {"description": "Gimbal Yaw", "value": 422}, {"description": "Gripper", "value": 430}, {"description": "Landing Gear Wheel", "value": 440}, {"description": "IC Engine Ignition", "value": 450}, {"description": "IC Engine Throttle", "value": 451}, {"description": "IC Engine Choke", "value": 452}, {"description": "IC Engine Starter", "value": 453}]}, {"bitmask": [{"description": "SIM Channel 1", "index": 0}, {"description": "SIM Channel 2", "index": 1}, {"description": "SIM Channel 3", "index": 2}, {"description": "SIM Channel 4", "index": 3}, {"description": "SIM Channel 5", "index": 4}, {"description": "SIM Channel 6", "index": 5}, {"description": "SIM Channel 7", "index": 6}, {"description": "SIM Channel 8", "index": 7}, {"description": "SIM Channel 9", "index": 8}, {"description": "SIM Channel 10", "index": 9}, {"description": "SIM Channel 11", "index": 10}, {"description": "SIM Channel 12", "index": 11}, {"description": "SIM Channel 13", "index": 12}, {"description": "SIM Channel 14", "index": 13}, {"description": "SIM Channel 15", "index": 14}, {"description": "SIM Channel 16", "index": 15}], "category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Allows to reverse the output range for each channel.\nNote: this is only useful for servos.\n\n", "max": 65535, "min": 0, "name": "PWM_MAIN_REV", "shortDesc": "Reverse Output Range for SIM", "type": "Int32"}, {"bitmask": [{"description": "Only data missing check (triggers if more than 1s no data)", "index": 0}, {"description": "Data stuck (triggers if data is exactly constant for 2s in FW mode)", "index": 1}, {"description": "Innovation check (see ASPD_FS_INNOV)", "index": 2}, {"description": "Load factor check (triggers if measurement is below stall speed)", "index": 3}, {"description": "First principle check (airspeed change vs. throttle and pitch)", "index": 4}], "category": "Standard", "default": 7, "group": "Airspeed Validator", "longDesc": "Controls which checks are run to check airspeed data for validity. Only applied if ASPD_PRIMARY > 0.\n\nNote: The missing data check (bit 0) is implicitly always enabled when ASPD_DO_CHECKS > 0, even if bit 0 is not explicitly set.\n", "max": 31, "min": 0, "name": "ASPD_DO_CHECKS", "shortDesc": "Enable checks on airspeed sensors", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "Airspeed Validator", "name": "ASPD_FALLBACK", "shortDesc": "Fallback options", "type": "Int32", "values": [{"description": "Fallback only to other airspeed sensors", "value": 0}, {"description": "Fallback to groundspeed-minus-windspeed airspeed estimation", "value": 1}, {"description": "Fallback to thrust based airspeed estimation", "value": 2}]}, {"category": "Standard", "decimalPlaces": 1, "default": 2.0, "group": "Airspeed Validator", "longDesc": "Window for comparing airspeed change to throttle and pitch change.\nTriggers when the airspeed change within this window is negative while throttle increases\nand the vehicle pitches down.\nIs meant to catch degrading airspeed blockages as can happen when flying through icing conditions.\nRelies on FW_THR_TRIM being set accurately.\n", "min": 0.0, "name": "ASPD_FP_T_WINDOW", "shortDesc": "First principle airspeed check time window", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "Airspeed Validator", "longDesc": "This specifies the minimum airspeed innovation required to trigger a failsafe. Larger values make the check less sensitive,\nsmaller values make it more sensitive. Large innovations indicate an inconsistency between predicted (groundspeed - windspeeed)\nand measured airspeed.\nThe time required to detect a fault when the threshold is exceeded depends on the size of the exceedance and is controlled by the ASPD_FS_INTEG parameter.\n", "max": 10.0, "min": 0.5, "name": "ASPD_FS_INNOV", "shortDesc": "Airspeed failure innovation threshold", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 10.0, "group": "Airspeed Validator", "longDesc": "This sets the time integral of airspeed innovation exceedance above ASPD_FS_INNOV required to trigger a failsafe.\nLarger values make the check less sensitive, smaller positive values make it more sensitive.\n", "max": 50.0, "min": 0.0, "name": "ASPD_FS_INTEG", "shortDesc": "Airspeed failure innovation integral threshold", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": -1.0, "group": "Airspeed Validator", "longDesc": "Delay before switching back to using airspeed sensor if checks indicate sensor is good.\nSet to a negative value to disable the re-enabling in flight.\n", "min": -1.0, "name": "ASPD_FS_T_START", "shortDesc": "Airspeed failsafe start delay", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.0, "group": "Airspeed Validator", "longDesc": "Delay before stopping use of airspeed sensor if checks indicate sensor is bad.\n", "min": 0.0, "name": "ASPD_FS_T_STOP", "shortDesc": "Airspeed failsafe stop delay", "type": "Float", "units": "s"}, {"category": "Standard", "default": 1, "group": "Airspeed Validator", "name": "ASPD_PRIMARY", "rebootRequired": true, "shortDesc": "Index or primary airspeed measurement source", "type": "Int32", "values": [{"description": "Groundspeed minus windspeed", "value": 0}, {"description": "First airspeed sensor", "value": 1}, {"description": "Second airspeed sensor", "value": 2}, {"description": "Third airspeed sensor", "value": 3}, {"description": "Thrust based airspeed", "value": 4}]}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Airspeed Validator", "longDesc": "This is the scale IAS --> CAS of the first airspeed sensor instance\n", "max": 2.0, "min": 0.5, "name": "ASPD_SCALE_1", "shortDesc": "Scale of airspeed sensor 1", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Airspeed Validator", "longDesc": "This is the scale IAS --> CAS of the second airspeed sensor instance\n", "max": 2.0, "min": 0.5, "name": "ASPD_SCALE_2", "shortDesc": "Scale of airspeed sensor 2", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Airspeed Validator", "longDesc": "This is the scale IAS --> CAS of the third airspeed sensor instance\n", "max": 2.0, "min": 0.5, "name": "ASPD_SCALE_3", "shortDesc": "Scale of airspeed sensor 3", "type": "Float"}, {"category": "Standard", "default": 2, "group": "Airspeed Validator", "name": "ASPD_SCALE_APPLY", "shortDesc": "Controls when to apply the new estimated airspeed scale(s)", "type": "Int32", "values": [{"description": "Do not automatically apply the estimated scale", "value": 0}, {"description": "Apply the estimated scale after disarm", "value": 1}, {"description": "Apply the estimated scale in air", "value": 2}]}, {"category": "Standard", "decimalPlaces": 1, "default": 1.4, "group": "Airspeed Validator", "longDesc": "True airspeed measurement noise of the internal wind estimator(s) of the airspeed selector.\n", "max": 4.0, "min": 0.0, "name": "ASPD_TAS_NOISE", "shortDesc": "Wind estimator true airspeed measurement noise", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 2.0, "group": "Airspeed Validator", "longDesc": "The airspeed alternative derived from groundspeed and heading will be declared valid\nas soon and as long the horizontal wind uncertainty is below this value.\n", "max": 5.0, "min": 0.01, "name": "ASPD_WERR_THR", "shortDesc": "Horizontal wind uncertainty threshold for valid ground-minus-wind", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "Airspeed Validator", "longDesc": "Wind process noise of the internal wind estimator(s) of the airspeed selector.\nWhen unaided, the wind estimate uncertainty (1-sigma, in m/s) increases by this amount every second.\n", "max": 1.0, "min": 0.0, "name": "ASPD_WIND_NSD", "shortDesc": "Wind estimator wind process noise spectral density", "type": "Float", "units": "m/s^2/sqrt(Hz)"}, {"category": "Standard", "default": 0, "group": "Attitude Q estimator", "name": "ATT_ACC_COMP", "shortDesc": "Acceleration compensation based on GPS velocity", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "Attitude Q estimator", "max": 2.0, "min": 0.0, "name": "ATT_BIAS_MAX", "shortDesc": "Gyro bias limit", "type": "Float", "units": "rad/s"}, {"category": "Standard", "default": 0, "group": "Attitude Q estimator", "longDesc": "Enable standalone quaternion based attitude estimator.\n", "name": "ATT_EN", "shortDesc": "standalone attitude estimator enable (unsupported)", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Attitude Q estimator", "longDesc": "Set to 1 to use heading estimate from vision.\nSet to 2 to use heading from motion capture.\n", "max": 2, "min": 0, "name": "ATT_EXT_HDG_M", "shortDesc": "External heading usage mode (from Motion capture/Vision)", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Vision", "value": 1}, {"description": "Motion Capture", "value": 2}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Attitude Q estimator", "longDesc": "This parameter is not used in normal operation,\nas the declination is looked up based on the\nGPS coordinates of the vehicle.\n", "name": "ATT_MAG_DECL", "shortDesc": "Magnetic declination, in degrees", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 1, "group": "Attitude Q estimator", "name": "ATT_MAG_DECL_A", "shortDesc": "Automatic GPS based declination compensation", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.2, "group": "Attitude Q estimator", "max": 1.0, "min": 0.0, "name": "ATT_W_ACC", "shortDesc": "Complementary filter accelerometer weight", "type": "Float"}, {"category": "Standard", "default": 0.1, "group": "Attitude Q estimator", "max": 1.0, "min": 0.0, "name": "ATT_W_EXT_HDG", "shortDesc": "Complementary filter external heading weight", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "Attitude Q estimator", "max": 1.0, "min": 0.0, "name": "ATT_W_GYRO_BIAS", "shortDesc": "Complementary filter gyroscope bias weight", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "Attitude Q estimator", "longDesc": "Set to 0 to avoid using the magnetometer.\n", "max": 1.0, "min": 0.0, "name": "ATT_W_MAG", "shortDesc": "Complementary filter magnetometer weight", "type": "Float"}, {"category": "Standard", "default": 2, "group": "Autotune", "longDesc": "After the auto-tuning sequence is completed,\na new set of gains is available and can be applied\nimmediately or after landing.\n", "name": "FW_AT_APPLY", "shortDesc": "Controls when to apply the new gains", "type": "Int32", "values": [{"description": "Do not apply the new gains (logging only)", "value": 0}, {"description": "Apply the new gains after disarm", "value": 1}, {"description": "Apply the new gains in air", "value": 2}]}, {"bitmask": [{"description": "roll", "index": 0}, {"description": "pitch", "index": 1}, {"description": "yaw", "index": 2}], "category": "Standard", "default": 3, "group": "Autotune", "longDesc": "Defines which axes will be tuned during the auto-tuning sequence\n\nSet bits in the following positions to enable:\n0 : Roll\n1 : Pitch\n2 : Yaw\n", "max": 7, "min": 1, "name": "FW_AT_AXES", "shortDesc": "Tuning axes selection", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "Autotune", "longDesc": "Defines which RC_MAP_AUXn parameter maps the manual control channel used to enable/disable auto tuning.\n", "max": 6, "min": 0, "name": "FW_AT_MAN_AUX", "shortDesc": "Enable/disable auto tuning using a manual control AUX input", "type": "Int32", "values": [{"description": "Disable", "value": 0}, {"description": "Aux1", "value": 1}, {"description": "Aux2", "value": 2}, {"description": "Aux3", "value": 3}, {"description": "Aux4", "value": 4}, {"description": "Aux5", "value": 5}, {"description": "Aux6", "value": 6}]}, {"category": "Standard", "decimalPlaces": 1, "default": 1.0, "group": "Autotune", "longDesc": "Can be set lower or higher than the end frequency\n", "max": 30.0, "min": 0.1, "name": "FW_AT_SYSID_F0", "shortDesc": "Start frequency of the injected signal", "type": "Float", "units": "Hz"}, {"category": "Standard", "decimalPlaces": 1, "default": 10.0, "group": "Autotune", "longDesc": "Can be set lower or higher than the start frequency\n", "max": 30.0, "min": 0.1, "name": "FW_AT_SYSID_F1", "shortDesc": "End frequency of the injected signal", "type": "Float", "units": "Hz"}, {"category": "Standard", "decimalPlaces": 0, "default": 10.0, "group": "Autotune", "longDesc": "Duration of the input signal sent on each axis during system identification\n", "max": 120.0, "min": 5.0, "name": "FW_AT_SYSID_TIME", "shortDesc": "Maneuver time for each axis", "type": "Float", "units": "s"}, {"category": "Standard", "default": 1, "group": "Autotune", "longDesc": "Type of signal used during system identification to excite the system.\n", "name": "FW_AT_SYSID_TYPE", "shortDesc": "Input signal type", "type": "Int32", "values": [{"description": "Step", "value": 0}, {"description": "Linear sine sweep", "value": 1}, {"description": "Logarithmic sine sweep", "value": 2}]}, {"category": "Standard", "default": 1, "group": "Autotune", "longDesc": "After the auto-tuning sequence is completed,\na new set of gains is available and can be applied\nimmediately or after landing.\n\nWARNING Applying the gains in air is dangerous as there is no\nguarantee that those new gains will be able to stabilize\nthe drone properly.\n", "name": "MC_AT_APPLY", "shortDesc": "Controls when to apply the new gains", "type": "Int32", "values": [{"description": "Do not apply the new gains (logging only)", "value": 0}, {"description": "Apply the new gains after disarm", "value": 1}, {"description": "WARNING Apply the new gains in air", "value": 2}]}, {"category": "Standard", "default": 0, "group": "Autotune", "name": "MC_AT_EN", "shortDesc": "Multicopter autotune module enable", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.14, "group": "Autotune", "max": 0.5, "min": 0.01, "name": "MC_AT_RISE_TIME", "shortDesc": "Desired angular rate closed-loop rise time", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.7, "group": "Autotune", "max": 6.0, "min": 0.1, "name": "MC_AT_SYSID_AMP", "shortDesc": "Amplitude of the injected signal", "type": "Float"}, {"category": "Standard", "decimalPlaces": 0, "default": -1.0, "group": "Battery Calibration", "increment": 50.0, "longDesc": "Defines the capacity of battery 1 in mAh.\n\n", "max": 100000.0, "min": -1.0, "name": "BAT1_CAPACITY", "rebootRequired": true, "shortDesc": "Battery 1 capacity", "type": "Float", "units": "mAh"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Battery Calibration", "longDesc": "While disarmed, replaces the measured current with this value, for ESCs that measure current inaccurately at no load. Set to 0 or less to disable.\n", "name": "BAT1_I_OVERWRITE", "shortDesc": "Battery 1 idle current overwrite", "type": "Float", "units": "A"}, {"category": "Standard", "default": 0, "group": "Battery Calibration", "longDesc": "Defines the number of cells the attached battery consists of.\n\n", "name": "BAT1_N_CELLS", "shortDesc": "Number of cells for battery 1", "type": "Int32", "values": [{"description": "Unknown", "value": 0}, {"description": "1S Battery", "value": 1}, {"description": "2S Battery", "value": 2}, {"description": "3S Battery", "value": 3}, {"description": "4S Battery", "value": 4}, {"description": "5S Battery", "value": 5}, {"description": "6S Battery", "value": 6}, {"description": "7S Battery", "value": 7}, {"description": "8S Battery", "value": 8}, {"description": "9S Battery", "value": 9}, {"description": "10S Battery", "value": 10}, {"description": "11S Battery", "value": 11}, {"description": "12S Battery", "value": 12}, {"description": "13S Battery", "value": 13}, {"description": "14S Battery", "value": 14}, {"description": "15S Battery", "value": 15}, {"description": "16S Battery", "value": 16}]}, {"category": "Standard", "decimalPlaces": 4, "default": -1.0, "group": "Battery Calibration", "increment": 0.0005, "longDesc": "If non-negative, then this will be used instead of the online estimated internal resistance.\n\n", "max": 0.2, "min": -1.0, "name": "BAT1_R_INTERNAL", "rebootRequired": true, "shortDesc": "Explicitly defines the per cell internal resistance for battery 1", "type": "Float", "units": "Ohm"}, {"category": "Standard", "default": 0, "group": "Battery Calibration", "longDesc": "Power Module / Analog: board ADC inputs (onboard or external analog power module) or an I2C power monitor (e.g. INA226).\nExternal: MAVLink or CAN battery status messages, or an external driver.\nESCs: esc_status from ESC telemetry; requires voltage and current.\n", "name": "BAT1_SOURCE", "rebootRequired": true, "shortDesc": "Battery 1 monitoring source", "type": "Int32", "values": [{"description": "Disabled", "value": -1}, {"description": "Power Module / Analog", "value": 0}, {"description": "External", "value": 1}, {"description": "ESCs", "value": 2}]}, {"category": "Standard", "decimalPlaces": 2, "default": 4.2, "group": "Battery Calibration", "increment": 0.01, "longDesc": "Defines the voltage where a single cell of the battery is considered full.\n\n", "name": "BAT1_V_CHARGED", "rebootRequired": true, "shortDesc": "Full cell voltage", "type": "Float", "units": "V"}, {"category": "Standard", "decimalPlaces": 2, "default": 3.6, "group": "Battery Calibration", "increment": 0.01, "longDesc": "Defines the voltage where a single cell of the battery is considered empty.\nThe voltage should be chosen above the steep dropoff at 3.5V. A typical\nlithium battery can only be discharged under high load down to 10% before\nit drops off to a voltage level damaging the cells.\n\n", "name": "BAT1_V_EMPTY", "rebootRequired": true, "shortDesc": "Empty cell voltage", "type": "Float", "units": "V"}, {"category": "Standard", "decimalPlaces": 0, "default": -1.0, "group": "Battery Calibration", "increment": 50.0, "longDesc": "Defines the capacity of battery 2 in mAh.\n\n", "max": 100000.0, "min": -1.0, "name": "BAT2_CAPACITY", "rebootRequired": true, "shortDesc": "Battery 2 capacity", "type": "Float", "units": "mAh"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Battery Calibration", "longDesc": "While disarmed, replaces the measured current with this value, for ESCs that measure current inaccurately at no load. Set to 0 or less to disable.\n", "name": "BAT2_I_OVERWRITE", "shortDesc": "Battery 2 idle current overwrite", "type": "Float", "units": "A"}, {"category": "Standard", "default": 0, "group": "Battery Calibration", "longDesc": "Defines the number of cells the attached battery consists of.\n\n", "name": "BAT2_N_CELLS", "shortDesc": "Number of cells for battery 2", "type": "Int32", "values": [{"description": "Unknown", "value": 0}, {"description": "1S Battery", "value": 1}, {"description": "2S Battery", "value": 2}, {"description": "3S Battery", "value": 3}, {"description": "4S Battery", "value": 4}, {"description": "5S Battery", "value": 5}, {"description": "6S Battery", "value": 6}, {"description": "7S Battery", "value": 7}, {"description": "8S Battery", "value": 8}, {"description": "9S Battery", "value": 9}, {"description": "10S Battery", "value": 10}, {"description": "11S Battery", "value": 11}, {"description": "12S Battery", "value": 12}, {"description": "13S Battery", "value": 13}, {"description": "14S Battery", "value": 14}, {"description": "15S Battery", "value": 15}, {"description": "16S Battery", "value": 16}]}, {"category": "Standard", "decimalPlaces": 4, "default": -1.0, "group": "Battery Calibration", "increment": 0.0005, "longDesc": "If non-negative, then this will be used instead of the online estimated internal resistance.\n\n", "max": 0.2, "min": -1.0, "name": "BAT2_R_INTERNAL", "rebootRequired": true, "shortDesc": "Explicitly defines the per cell internal resistance for battery 2", "type": "Float", "units": "Ohm"}, {"category": "Standard", "default": -1, "group": "Battery Calibration", "longDesc": "Power Module / Analog: board ADC inputs (onboard or external analog power module) or an I2C power monitor (e.g. INA226).\nExternal: MAVLink or CAN battery status messages, or an external driver.\nESCs: esc_status from ESC telemetry; requires voltage and current.\n", "name": "BAT2_SOURCE", "rebootRequired": true, "shortDesc": "Battery 2 monitoring source", "type": "Int32", "values": [{"description": "Disabled", "value": -1}, {"description": "Power Module / Analog", "value": 0}, {"description": "External", "value": 1}, {"description": "ESCs", "value": 2}]}, {"category": "Standard", "decimalPlaces": 2, "default": 4.2, "group": "Battery Calibration", "increment": 0.01, "longDesc": "Defines the voltage where a single cell of the battery is considered full.\n\n", "name": "BAT2_V_CHARGED", "rebootRequired": true, "shortDesc": "Full cell voltage", "type": "Float", "units": "V"}, {"category": "Standard", "decimalPlaces": 2, "default": 3.6, "group": "Battery Calibration", "increment": 0.01, "longDesc": "Defines the voltage where a single cell of the battery is considered empty.\nThe voltage should be chosen above the steep dropoff at 3.5V. A typical\nlithium battery can only be discharged under high load down to 10% before\nit drops off to a voltage level damaging the cells.\n\n", "name": "BAT2_V_EMPTY", "rebootRequired": true, "shortDesc": "Empty cell voltage", "type": "Float", "units": "V"}, {"category": "Standard", "decimalPlaces": 0, "default": -1.0, "group": "Battery Calibration", "increment": 50.0, "longDesc": "Defines the capacity of battery 3 in mAh.\n\n", "max": 100000.0, "min": -1.0, "name": "BAT3_CAPACITY", "rebootRequired": true, "shortDesc": "Battery 3 capacity", "type": "Float", "units": "mAh"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Battery Calibration", "longDesc": "While disarmed, replaces the measured current with this value, for ESCs that measure current inaccurately at no load. Set to 0 or less to disable.\n", "name": "BAT3_I_OVERWRITE", "shortDesc": "Battery 3 idle current overwrite", "type": "Float", "units": "A"}, {"category": "Standard", "default": 0, "group": "Battery Calibration", "longDesc": "Defines the number of cells the attached battery consists of.\n\n", "name": "BAT3_N_CELLS", "shortDesc": "Number of cells for battery 3", "type": "Int32", "values": [{"description": "Unknown", "value": 0}, {"description": "1S Battery", "value": 1}, {"description": "2S Battery", "value": 2}, {"description": "3S Battery", "value": 3}, {"description": "4S Battery", "value": 4}, {"description": "5S Battery", "value": 5}, {"description": "6S Battery", "value": 6}, {"description": "7S Battery", "value": 7}, {"description": "8S Battery", "value": 8}, {"description": "9S Battery", "value": 9}, {"description": "10S Battery", "value": 10}, {"description": "11S Battery", "value": 11}, {"description": "12S Battery", "value": 12}, {"description": "13S Battery", "value": 13}, {"description": "14S Battery", "value": 14}, {"description": "15S Battery", "value": 15}, {"description": "16S Battery", "value": 16}]}, {"category": "Standard", "decimalPlaces": 4, "default": -1.0, "group": "Battery Calibration", "increment": 0.0005, "longDesc": "If non-negative, then this will be used instead of the online estimated internal resistance.\n\n", "max": 0.2, "min": -1.0, "name": "BAT3_R_INTERNAL", "rebootRequired": true, "shortDesc": "Explicitly defines the per cell internal resistance for battery 3", "type": "Float", "units": "Ohm"}, {"category": "Standard", "default": -1, "group": "Battery Calibration", "longDesc": "Power Module / Analog: board ADC inputs (onboard or external analog power module) or an I2C power monitor (e.g. INA226).\nExternal: MAVLink or CAN battery status messages, or an external driver.\nESCs: esc_status from ESC telemetry; requires voltage and current.\n", "name": "BAT3_SOURCE", "rebootRequired": true, "shortDesc": "Battery 3 monitoring source", "type": "Int32", "values": [{"description": "Disabled", "value": -1}, {"description": "Power Module / Analog", "value": 0}, {"description": "External", "value": 1}, {"description": "ESCs", "value": 2}]}, {"category": "Standard", "decimalPlaces": 2, "default": 4.2, "group": "Battery Calibration", "increment": 0.01, "longDesc": "Defines the voltage where a single cell of the battery is considered full.\n\n", "name": "BAT3_V_CHARGED", "rebootRequired": true, "shortDesc": "Full cell voltage", "type": "Float", "units": "V"}, {"category": "Standard", "decimalPlaces": 2, "default": 3.6, "group": "Battery Calibration", "increment": 0.01, "longDesc": "Defines the voltage where a single cell of the battery is considered empty.\nThe voltage should be chosen above the steep dropoff at 3.5V. A typical\nlithium battery can only be discharged under high load down to 10% before\nit drops off to a voltage level damaging the cells.\n\n", "name": "BAT3_V_EMPTY", "rebootRequired": true, "shortDesc": "Empty cell voltage", "type": "Float", "units": "V"}, {"category": "Standard", "decimalPlaces": 2, "default": 15.0, "group": "Battery Calibration", "increment": 0.1, "longDesc": "This value is used to initialize the in-flight average current estimation,\nwhich in turn is used for estimating remaining flight time and Return triggering.\n\n", "max": 500.0, "min": 0.0, "name": "BAT_AVRG_CURRENT", "shortDesc": "Expected battery current in flight", "type": "Float", "units": "A"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.07, "group": "Battery Calibration", "increment": 0.01, "longDesc": "Sets the threshold when the battery will be reported as critically low.\nThis has to be lower than the low threshold. This threshold commonly\nwill trigger Return.\n\n", "max": 0.5, "min": 0.05, "name": "BAT_CRIT_THR", "shortDesc": "Critical threshold", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.05, "group": "Battery Calibration", "increment": 0.01, "longDesc": "Sets the threshold when the battery will be reported as dangerously low.\nThis has to be lower than the critical threshold. This threshold commonly\nwill trigger landing.\n\n", "max": 0.5, "min": 0.03, "name": "BAT_EMERGEN_THR", "shortDesc": "Emergency threshold", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.15, "group": "Battery Calibration", "increment": 0.01, "longDesc": "Sets the threshold when the battery will be reported as low.\nThis has to be higher than the critical threshold.\n\n", "max": 0.5, "min": 0.12, "name": "BAT_LOW_THR", "shortDesc": "Low threshold", "type": "Float", "units": "norm"}, {"category": "Standard", "default": 1, "group": "Camera Control", "longDesc": "Whether the autopilot reports captures to the ground station by emitting\nCAMERA_IMAGE_CAPTURED.\n\nDisable for cameras that report captures themselves (e.g. cameras\nimplementing the MAVLink Camera Protocol) to avoid duplicate\nCAMERA_IMAGE_CAPTURED messages. Capture events are still published on the\ncamera_capture topic and logged for geotagging regardless of this setting.\n\n", "name": "CAM_CAP_REPORT", "shortDesc": "Report captures to the ground station", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 40.0, "group": "Camera trigger", "longDesc": "This parameter sets the time the trigger needs to pulled high or low.\n", "max": 3000.0, "min": 0.1, "name": "TRIG_ACT_TIME", "rebootRequired": true, "shortDesc": "Camera trigger activation time", "type": "Float", "units": "ms"}, {"category": "Standard", "decimalPlaces": 1, "default": 25.0, "group": "Camera trigger", "increment": 1.0, "longDesc": "Sets the distance at which to trigger the camera.\n", "min": 0.0, "name": "TRIG_DISTANCE", "rebootRequired": true, "shortDesc": "Camera trigger distance", "type": "Float", "units": "m"}, {"category": "Standard", "default": 4, "group": "Camera trigger", "longDesc": "Selects the trigger interface\n", "name": "TRIG_INTERFACE", "rebootRequired": true, "shortDesc": "Camera trigger Interface", "type": "Int32", "values": [{"description": "GPIO", "value": 1}, {"description": "Seagull MAP2 (over PWM)", "value": 2}, {"description": "MAVLink (Camera Protocol v1)", "value": 3}, {"description": "Generic PWM (IR trigger, servo)", "value": 4}]}, {"category": "Standard", "decimalPlaces": 1, "default": 40.0, "group": "Camera trigger", "longDesc": "This parameter sets the time between two consecutive trigger events\n", "max": 10000.0, "min": 4.0, "name": "TRIG_INTERVAL", "rebootRequired": true, "shortDesc": "Camera trigger interval", "type": "Float", "units": "ms"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.0, "group": "Camera trigger", "longDesc": "This parameter sets the minimum time between two consecutive trigger events\nthe specific camera setup is supporting.\n", "max": 10000.0, "min": 1.0, "name": "TRIG_MIN_INTERVA", "rebootRequired": true, "shortDesc": "Minimum camera trigger interval", "type": "Float", "units": "ms"}, {"category": "Standard", "default": 0, "group": "Camera trigger", "max": 4, "min": 0, "name": "TRIG_MODE", "rebootRequired": true, "shortDesc": "Camera trigger mode", "type": "Int32", "values": [{"description": "Disable", "value": 0}, {"description": "Time based, on command", "value": 1}, {"description": "Time based, always on", "value": 2}, {"description": "Distance based, always on", "value": 3}, {"description": "Distance based, on command (Survey mode)", "value": 4}]}, {"category": "Standard", "default": 0, "group": "Camera trigger", "longDesc": "This parameter sets the polarity of the trigger (0 = active low, 1 = active high )\n", "max": 1, "min": 0, "name": "TRIG_POLARITY", "rebootRequired": true, "shortDesc": "Camera trigger polarity", "type": "Int32", "values": [{"description": "Active low", "value": 0}, {"description": "Active high", "value": 1}]}, {"category": "Standard", "default": 1500, "group": "Camera trigger", "max": 2000, "min": 1000, "name": "TRIG_PWM_NEUTRAL", "rebootRequired": true, "shortDesc": "PWM neutral output on trigger pin", "type": "Int32", "units": "us"}, {"category": "Standard", "default": 1900, "group": "Camera trigger", "max": 2000, "min": 1000, "name": "TRIG_PWM_SHOOT", "rebootRequired": true, "shortDesc": "PWM output to trigger shot", "type": "Int32", "units": "us"}, {"category": "Developer", "default": 0, "group": "Circuit Breaker", "longDesc": "Setting this parameter to 782097 will disable the buzzer audio notification.\n\nSetting this parameter to 782090 will disable the startup tune, while keeping\nall others enabled.\n", "max": 782097, "min": 0, "name": "CBRK_BUZZER", "rebootRequired": true, "shortDesc": "Circuit breaker for disabling buzzer", "type": "Int32"}, {"category": "Developer", "default": 121212, "group": "Circuit Breaker", "longDesc": "Setting this parameter to 121212 will disable the flight termination action if triggered\nby the FailureDetector logic or if FMU is lost.\nThis circuit breaker does not affect the RC loss, data link loss, geofence,\nand takeoff failure detection safety logic.\n", "max": 121212, "min": 0, "name": "CBRK_FLIGHTTERM", "rebootRequired": true, "shortDesc": "Circuit breaker for flight termination", "type": "Int32"}, {"category": "Developer", "default": 0, "group": "Circuit Breaker", "longDesc": "Setting this parameter to 894281 will disable the power valid\nchecks in the commander.\nWARNING: ENABLING THIS CIRCUIT BREAKER IS AT OWN RISK\n", "max": 894281, "min": 0, "name": "CBRK_SUPPLY_CHK", "shortDesc": "Circuit breaker for power supply check", "type": "Int32"}, {"category": "Developer", "default": 0, "group": "Circuit Breaker", "longDesc": "Setting this parameter to 5318008 will allow arming even when a UAVCAN\nnode firmware update is pending or a node went offline mid-update.\nWARNING: ENABLING THIS CIRCUIT BREAKER IS AT OWN RISK\n", "max": 5318008, "min": 0, "name": "CBRK_UAVCAN_FW", "shortDesc": "Circuit breaker for UAVCAN firmware update arming check", "type": "Int32"}, {"category": "Developer", "default": 197848, "group": "Circuit Breaker", "longDesc": "Setting this parameter to 197848 will disable the USB connected\nchecks in the commander, setting it to 0 keeps them enabled (recommended).\n\nWe are generally recommending to not fly with the USB link\nconnected and production vehicles should set this parameter to\nzero to prevent users from flying USB powered. However, for R&D purposes\nit has proven over the years to work just fine.\n", "max": 197848, "min": 0, "name": "CBRK_USB_CHK", "shortDesc": "Circuit breaker for USB link check", "type": "Int32"}, {"category": "Developer", "default": 0, "group": "Circuit Breaker", "longDesc": "Setting this parameter to 159753 will enable arming in fixed-wing\nmode for VTOLs.\nWARNING: ENABLING THIS CIRCUIT BREAKER IS AT OWN RISK\n", "max": 159753, "min": 0, "name": "CBRK_VTOLARMING", "shortDesc": "Circuit breaker for arming in fixed-wing mode check", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "Note: actuator failure needs to be enabled and configured via FD_ACT_*\nparameters.\n", "name": "COM_ACT_FAIL_ACT", "shortDesc": "Set the actuator failure failsafe mode", "type": "Int32", "values": [{"description": "Warning only", "value": 0}, {"description": "Hold mode", "value": 1}, {"description": "Land mode", "value": 2}, {"description": "Return mode", "value": 3}, {"description": "Terminate", "value": 4}]}, {"category": "Standard", "default": 1, "group": "Commander", "longDesc": "Set 0 to prevent accidental use of the vehicle e.g. for safety or maintenance reasons.\n", "name": "COM_ARMABLE", "shortDesc": "Flag to allow arming", "type": "Int32", "values": [{"description": "Disallow arming", "value": 0}, {"description": "Allow arming", "value": 1}]}, {"category": "Standard", "default": 10, "group": "Commander", "longDesc": "Used if arm authorization is requested by COM_ARM_AUTH_REQ.\n", "name": "COM_ARM_AUTH_ID", "shortDesc": "Arm authorizer system id", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "Methods:\n- one arm: request authorization and arm when authorization is received\n- two step arm: 1st arm command request an authorization and\n2nd arm command arm the drone if authorized\n\nUsed if arm authorization is requested by COM_ARM_AUTH_REQ.\n", "name": "COM_ARM_AUTH_MET", "shortDesc": "Arm authorization method", "type": "Int32", "values": [{"description": "one arm", "value": 0}, {"description": "two step arm", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "By default off. The default allows to arm the vehicle without a arm authorization.\n", "name": "COM_ARM_AUTH_REQ", "shortDesc": "Require arm authorization to arm", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 1.0, "group": "Commander", "increment": 0.1, "longDesc": "Timeout for authorizer answer.\nUsed if arm authorization is requested by COM_ARM_AUTH_REQ.\n", "name": "COM_ARM_AUTH_TO", "shortDesc": "Arm authorization timeout", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Commander", "increment": 0.01, "longDesc": "Threshold for battery percentage below arming is prohibited.\n\nA negative value means BAT_CRIT_THR is the threshold.\n", "max": 0.9, "min": -1.0, "name": "COM_ARM_BAT_MIN", "shortDesc": "Minimum battery level for arming", "type": "Float", "units": "norm"}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "If this parameter is set, the system will check ESC's online status and failures.\nThis param is specific for ESCs reporting status. It shall be used only if ESCs support telemetry.\n", "name": "COM_ARM_CHK_ESCS", "shortDesc": "Enable checks on ESCs that report telemetry", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 1, "group": "Commander", "longDesc": "This check detects if there are hardfault / watchdog files present on the\nSD card. If so, and the parameter is enabled, arming is prevented.\n", "name": "COM_ARM_HFLT_CHK", "shortDesc": "Enable FMU SD card hardfault / watchdog detection check", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.7, "group": "Commander", "increment": 0.05, "longDesc": "Maximum accelerometer inconsistency between IMU units that will allow arming\n", "max": 1.0, "min": 0.1, "name": "COM_ARM_IMU_ACC", "shortDesc": "Max accelerometer inconsistency for arming", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.25, "group": "Commander", "increment": 0.01, "longDesc": "Maximum rate gyro inconsistency between IMU units that will allow arming\n", "max": 0.3, "min": 0.02, "name": "COM_ARM_IMU_GYR", "shortDesc": "Max rate gyro inconsistency for arming", "type": "Float", "units": "rad/s"}, {"category": "Standard", "default": 60, "group": "Commander", "longDesc": "Maximum magnetic field inconsistency between units that will allow arming\n\nSet -1 to disable the check.\n", "max": 180, "min": 3, "name": "COM_ARM_MAG_ANG", "shortDesc": "Max magnetic field inconsistency for arming", "type": "Int32", "units": "deg"}, {"category": "Standard", "default": 2, "group": "Commander", "longDesc": "Check if the estimator detects a strong magnetic\ndisturbance (check enabled by EKF2_MAG_CHECK)\n", "name": "COM_ARM_MAG_STR", "shortDesc": "Enable mag strength preflight check", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Deny arming", "value": 1}, {"description": "Warning only", "value": 2}]}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "The default allows to arm the vehicle without a valid mission.\n", "name": "COM_ARM_MIS_REQ", "shortDesc": "Require valid mission to arm", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "Actions other than warning also prevent arming.\n", "name": "COM_ARM_ODID", "shortDesc": "Open Drone ID system check and in-flight failsafe", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Warning only", "value": 1}, {"description": "Error only", "value": 2}, {"description": "Return", "value": 3}, {"description": "Land", "value": 4}, {"description": "Terminate", "value": 5}]}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "When enabled, the vehicle arms automatically once all preflight checks pass after boot.\nThe vehicle will not re-arm after a manual disarm.\nHas no effect if COM_ARMABLE is 0.\n", "name": "COM_ARM_ON_BOOT", "rebootRequired": true, "shortDesc": "Arm automatically on boot", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "0: Arming/disarming triggers on switch transition.\n1: Arming/disarming triggers when holding the momentary button down like the stick gesture.\n", "name": "COM_ARM_SWISBTN", "shortDesc": "Arm switch is a momentary button", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 1, "group": "Commander", "longDesc": "Configures whether arming is allowed without GNSS, for modes that require a global position\n(specifically, in those modes when a check defined by GNSS_CHECK fails).\nThe settings deny arming and warn, allow arming and warn, or silently allow arming.\n", "name": "COM_ARM_WO_GPS", "shortDesc": "Arming without GNSS configuration", "type": "Int32", "values": [{"description": "Deny arming", "value": 0}, {"description": "Allow arming (with warning)", "value": 1}, {"description": "Allow arming (no warning)", "value": 2}]}, {"category": "Standard", "decimalPlaces": 0, "default": 80.0, "group": "Commander", "increment": 1.0, "longDesc": "Arming is not prevented as the temperature typically drops in flight.\n\nSet to -1 to disable.\n", "max": 127.0, "min": -1.0, "name": "COM_CC_TEMP_WARN", "shortDesc": "Companion computer high-temperature warning threshold", "type": "Float", "units": "celcius"}, {"category": "Standard", "default": 95.0, "group": "Commander", "increment": 1.0, "longDesc": "The check fails if the CPU load is above this threshold for 2s.\n\nA negative value disables the check.\n", "max": 100.0, "min": -1.0, "name": "COM_CPU_MAX", "shortDesc": "Maximum allowed CPU load to still arm", "type": "Float", "units": "%"}, {"category": "Standard", "decimalPlaces": 1, "default": 2.0, "group": "Commander", "increment": 0.1, "longDesc": "A non-zero, positive value specifies the time-out period in seconds after which the vehicle will be\nautomatically disarmed in case a landing situation has been detected during this period.\n\nA zero or negative value means that automatic disarming triggered by landing detection is disabled.\n", "name": "COM_DISARM_LAND", "shortDesc": "Time-out for auto disarm after landing", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 10.0, "group": "Commander", "increment": 0.1, "longDesc": "A non-zero, positive value specifies the time in seconds, within which the\nvehicle is expected to take off after arming. In case the vehicle didn't takeoff\nwithin the timeout it disarms again.\n\nA negative value disables autmoatic disarming triggered by a pre-takeoff timeout.\n", "name": "COM_DISARM_PRFLT", "shortDesc": "Time-out for auto disarm if not taking off", "type": "Float", "units": "s"}, {"bitmask": [{"description": "Mission", "index": 0}, {"description": "Auto modes", "index": 1}, {"description": "Offboard", "index": 2}, {"description": "External Mode", "index": 3}, {"description": "Altitude Cruise", "index": 4}], "category": "Standard", "default": 0, "group": "Commander", "longDesc": "Specify modes in which ground control station connection loss is ignored and no failsafe action is triggered.\nSee also COM_RCL_EXCEPT.\n", "max": 31, "min": 0, "name": "COM_DLL_EXCEPT", "shortDesc": "Datalink loss exceptions", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 1, "default": 10, "group": "Commander", "increment": 1, "longDesc": "After this amount of seconds without datalink, the GCS connection lost mode triggers\n", "max": 300, "min": 5, "name": "COM_DL_LOSS_T", "shortDesc": "GCS connection loss time threshold", "type": "Int32", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "Commander", "longDesc": "Before entering failsafe (Return, Land, Hold), wait COM_FAIL_ACT_T seconds in Hold mode\nfor the user to realize.\nDuring that time the user can switch modes, but cannot take over control via the manual control override feature (see MAN_OVERRIDE_SPD).\nAfterwards the configured failsafe action is triggered and the user may use manual control override.\n\nA zero value disables the delay.\n", "max": 25.0, "min": 0.0, "name": "COM_FAIL_ACT_T", "shortDesc": "Delay between failsafe condition triggered and failsafe reaction", "type": "Float", "units": "s"}, {"category": "System", "default": 0, "group": "Commander", "longDesc": "This number is incremented automatically after every flight on\ndisarming in order to remember the next flight UUID.\nThe first flight is 0.\n", "min": 0, "name": "COM_FLIGHT_UUID", "shortDesc": "Next flight UUID", "type": "Int32", "volatile": true}, {"category": "Standard", "default": -1, "group": "Commander", "longDesc": "If the main switch channel is in this range the\nselected flight mode will be applied.\n\n", "name": "COM_FLTMODE1", "shortDesc": "Mode slot 1", "type": "Int32", "values": [{"description": "Unassigned", "value": -1}, {"description": "Manual", "value": 0}, {"description": "Altitude", "value": 1}, {"description": "Position / Cruise", "value": 2}, {"description": "Mission", "value": 3}, {"description": "Hold", "value": 4}, {"description": "Return", "value": 5}, {"description": "Acro", "value": 6}, {"description": "Offboard", "value": 7}, {"description": "Stabilized", "value": 8}, {"description": "Position Slow", "value": 9}, {"description": "Takeoff", "value": 10}, {"description": "Land", "value": 11}, {"description": "Follow Me", "value": 12}, {"description": "Precision Land", "value": 13}, {"description": "Altitude Cruise", "value": 16}, {"description": "Manual Parking", "value": 17}, {"description": "External Mode 1", "value": 100}, {"description": "External Mode 2", "value": 101}, {"description": "External Mode 3", "value": 102}, {"description": "External Mode 4", "value": 103}, {"description": "External Mode 5", "value": 104}, {"description": "External Mode 6", "value": 105}, {"description": "External Mode 7", "value": 106}, {"description": "External Mode 8", "value": 107}]}, {"category": "Standard", "default": -1, "group": "Commander", "longDesc": "If the main switch channel is in this range the\nselected flight mode will be applied.\n\n", "name": "COM_FLTMODE2", "shortDesc": "Mode slot 2", "type": "Int32", "values": [{"description": "Unassigned", "value": -1}, {"description": "Manual", "value": 0}, {"description": "Altitude", "value": 1}, {"description": "Position / Cruise", "value": 2}, {"description": "Mission", "value": 3}, {"description": "Hold", "value": 4}, {"description": "Return", "value": 5}, {"description": "Acro", "value": 6}, {"description": "Offboard", "value": 7}, {"description": "Stabilized", "value": 8}, {"description": "Position Slow", "value": 9}, {"description": "Takeoff", "value": 10}, {"description": "Land", "value": 11}, {"description": "Follow Me", "value": 12}, {"description": "Precision Land", "value": 13}, {"description": "Altitude Cruise", "value": 16}, {"description": "Manual Parking", "value": 17}, {"description": "External Mode 1", "value": 100}, {"description": "External Mode 2", "value": 101}, {"description": "External Mode 3", "value": 102}, {"description": "External Mode 4", "value": 103}, {"description": "External Mode 5", "value": 104}, {"description": "External Mode 6", "value": 105}, {"description": "External Mode 7", "value": 106}, {"description": "External Mode 8", "value": 107}]}, {"category": "Standard", "default": -1, "group": "Commander", "longDesc": "If the main switch channel is in this range the\nselected flight mode will be applied.\n\n", "name": "COM_FLTMODE3", "shortDesc": "Mode slot 3", "type": "Int32", "values": [{"description": "Unassigned", "value": -1}, {"description": "Manual", "value": 0}, {"description": "Altitude", "value": 1}, {"description": "Position / Cruise", "value": 2}, {"description": "Mission", "value": 3}, {"description": "Hold", "value": 4}, {"description": "Return", "value": 5}, {"description": "Acro", "value": 6}, {"description": "Offboard", "value": 7}, {"description": "Stabilized", "value": 8}, {"description": "Position Slow", "value": 9}, {"description": "Takeoff", "value": 10}, {"description": "Land", "value": 11}, {"description": "Follow Me", "value": 12}, {"description": "Precision Land", "value": 13}, {"description": "Altitude Cruise", "value": 16}, {"description": "Manual Parking", "value": 17}, {"description": "External Mode 1", "value": 100}, {"description": "External Mode 2", "value": 101}, {"description": "External Mode 3", "value": 102}, {"description": "External Mode 4", "value": 103}, {"description": "External Mode 5", "value": 104}, {"description": "External Mode 6", "value": 105}, {"description": "External Mode 7", "value": 106}, {"description": "External Mode 8", "value": 107}]}, {"category": "Standard", "default": -1, "group": "Commander", "longDesc": "If the main switch channel is in this range the\nselected flight mode will be applied.\n\n", "name": "COM_FLTMODE4", "shortDesc": "Mode slot 4", "type": "Int32", "values": [{"description": "Unassigned", "value": -1}, {"description": "Manual", "value": 0}, {"description": "Altitude", "value": 1}, {"description": "Position / Cruise", "value": 2}, {"description": "Mission", "value": 3}, {"description": "Hold", "value": 4}, {"description": "Return", "value": 5}, {"description": "Acro", "value": 6}, {"description": "Offboard", "value": 7}, {"description": "Stabilized", "value": 8}, {"description": "Position Slow", "value": 9}, {"description": "Takeoff", "value": 10}, {"description": "Land", "value": 11}, {"description": "Follow Me", "value": 12}, {"description": "Precision Land", "value": 13}, {"description": "Altitude Cruise", "value": 16}, {"description": "Manual Parking", "value": 17}, {"description": "External Mode 1", "value": 100}, {"description": "External Mode 2", "value": 101}, {"description": "External Mode 3", "value": 102}, {"description": "External Mode 4", "value": 103}, {"description": "External Mode 5", "value": 104}, {"description": "External Mode 6", "value": 105}, {"description": "External Mode 7", "value": 106}, {"description": "External Mode 8", "value": 107}]}, {"category": "Standard", "default": -1, "group": "Commander", "longDesc": "If the main switch channel is in this range the\nselected flight mode will be applied.\n\n", "name": "COM_FLTMODE5", "shortDesc": "Mode slot 5", "type": "Int32", "values": [{"description": "Unassigned", "value": -1}, {"description": "Manual", "value": 0}, {"description": "Altitude", "value": 1}, {"description": "Position / Cruise", "value": 2}, {"description": "Mission", "value": 3}, {"description": "Hold", "value": 4}, {"description": "Return", "value": 5}, {"description": "Acro", "value": 6}, {"description": "Offboard", "value": 7}, {"description": "Stabilized", "value": 8}, {"description": "Position Slow", "value": 9}, {"description": "Takeoff", "value": 10}, {"description": "Land", "value": 11}, {"description": "Follow Me", "value": 12}, {"description": "Precision Land", "value": 13}, {"description": "Altitude Cruise", "value": 16}, {"description": "Manual Parking", "value": 17}, {"description": "External Mode 1", "value": 100}, {"description": "External Mode 2", "value": 101}, {"description": "External Mode 3", "value": 102}, {"description": "External Mode 4", "value": 103}, {"description": "External Mode 5", "value": 104}, {"description": "External Mode 6", "value": 105}, {"description": "External Mode 7", "value": 106}, {"description": "External Mode 8", "value": 107}]}, {"category": "Standard", "default": -1, "group": "Commander", "longDesc": "If the main switch channel is in this range the\nselected flight mode will be applied.\n\n", "name": "COM_FLTMODE6", "shortDesc": "Mode slot 6", "type": "Int32", "values": [{"description": "Unassigned", "value": -1}, {"description": "Manual", "value": 0}, {"description": "Altitude", "value": 1}, {"description": "Position / Cruise", "value": 2}, {"description": "Mission", "value": 3}, {"description": "Hold", "value": 4}, {"description": "Return", "value": 5}, {"description": "Acro", "value": 6}, {"description": "Offboard", "value": 7}, {"description": "Stabilized", "value": 8}, {"description": "Position Slow", "value": 9}, {"description": "Takeoff", "value": 10}, {"description": "Land", "value": 11}, {"description": "Follow Me", "value": 12}, {"description": "Precision Land", "value": 13}, {"description": "Altitude Cruise", "value": 16}, {"description": "Manual Parking", "value": 17}, {"description": "External Mode 1", "value": 100}, {"description": "External Mode 2", "value": 101}, {"description": "External Mode 3", "value": 102}, {"description": "External Mode 4", "value": 103}, {"description": "External Mode 5", "value": 104}, {"description": "External Mode 6", "value": 105}, {"description": "External Mode 7", "value": 106}, {"description": "External Mode 8", "value": 107}]}, {"category": "Standard", "default": 4, "group": "Commander", "longDesc": "Flight mode set on boot and after a power cycle, before any RC input or\nmode command is received.\n", "name": "COM_FLTMODE_BOOT", "shortDesc": "Flight mode on boot", "type": "Int32", "values": [{"description": "Manual", "value": 0}, {"description": "Altitude", "value": 1}, {"description": "Position / Cruise", "value": 2}, {"description": "Mission", "value": 3}, {"description": "Hold", "value": 4}, {"description": "Position Slow", "value": 6}, {"description": "Altitude Cruise", "value": 8}, {"description": "Acro", "value": 10}, {"description": "Offboard", "value": 14}, {"description": "Stabilized", "value": 15}, {"description": "Takeoff", "value": 17}, {"description": "External 1", "value": 23}, {"description": "External 2", "value": 24}, {"description": "External 3", "value": 25}, {"description": "External 4", "value": 26}, {"description": "External 5", "value": 27}, {"description": "External 6", "value": 28}, {"description": "External 7", "value": 29}, {"description": "External 8", "value": 30}]}, {"category": "Standard", "default": -1, "group": "Commander", "longDesc": "The vehicle aborts the current operation and switches to Return mode when\nthe time since takeoff is above this value. It is not possible to resume the\nmission or switch to any auto mode other than Return or Land. Taking over in any manual\nmode is still possible.\n\nStarting from 90% of the maximum flight time, a warning message will be sent\nevery 1 minute with the remaining time until automatic Return.\n\nSet to -1 to disable.\n", "min": -1, "name": "COM_FLT_TIME_MAX", "shortDesc": "Maximum allowed flight time", "type": "Int32", "units": "s"}, {"category": "Standard", "default": 0, "group": "Commander", "name": "COM_FORCE_SAFETY", "shortDesc": "Re-enable safety when the vehicle disarms", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "Action the system takes when a GNSS failure is detected during flight.\nTriggers when the active GNSS count drops below SYS_HAS_NUM_GNSS (disabled\nwhen SYS_HAS_NUM_GNSS=0), or when two receivers report positions inconsistent\nwith their reported accuracy and SYS_HAS_NUM_GNSS=2 (otherwise warning only).\nThe reported accuracy of each receiver is floored with EKF2_GPS_P_NOISE.\nAny value above Warning also blocks arming.\n", "name": "COM_GNSSLOSS_ACT", "shortDesc": "GNSS loss failsafe mode", "type": "Int32", "values": [{"description": "Warning", "value": 0}, {"description": "Return", "value": 1}, {"description": "Land", "value": 2}, {"description": "Terminate", "value": 3}, {"description": "Warning, block arming", "value": 4}]}, {"category": "Standard", "default": 120, "group": "Commander", "longDesc": "After this amount of seconds without datalink the data link lost mode triggers\n", "max": 3600, "min": 60, "name": "COM_HLDL_LOSS_T", "shortDesc": "High Latency Datalink loss time threshold", "type": "Int32", "units": "s"}, {"category": "Standard", "default": 1, "group": "Commander", "longDesc": "Set home position automatically if possible.\n\nIf disabled, home is only set manually with MAV_CMD_DO_SET_HOME.\n\nDuring missions, the latitude/longitude of the home position is locked and will not reset during intermediate landings.\nIt will only update once the mission is complete or landed outside of a mission.\nHowever, the altitude is still being adjusted to correct for GNSS vertical drift in the first 2 minutes after takeoff.\n", "name": "COM_HOME_EN", "rebootRequired": true, "shortDesc": "Home position enabled", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "If set to true, the autopilot is allowed to set its home position after takeoff\nThe true home position is back-computed if a local position is estimate if available.\nIf no local position is available, home is set to the current position.\n", "name": "COM_HOME_IN_AIR", "shortDesc": "Allows setting the home position after takeoff", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "Action when the battery drops below the critical (BAT_CRIT_THR) or emergency (BAT_EMERGEN_THR) level.\n\nOptions 3 and 4 also engage Return mode when the remaining flight time is only just enough to return (distance-aware return, with the margin set by RTL_TIME_FACTOR and RTL_TIME_MARGIN).\nThis needs a remaining flight time estimate, such as from BATn_CAPACITY or a smart battery.\nThe other options only warn.\n", "name": "COM_LOW_BAT_ACT", "shortDesc": "Battery failsafe mode", "type": "Int32", "values": [{"description": "Warning", "value": 0}, {"description": "Land mode", "value": 2}, {"description": "Distance-aware return, Critical level return, Emergency level land", "value": 3}, {"description": "Distance-aware return, Critical level return, Emergency level terminate", "value": 4}, {"description": "Critical level return, Emergency level land", "value": 5}, {"description": "Critical level return, Emergency level terminate", "value": 6}]}, {"category": "System", "default": 0, "group": "Commander", "longDesc": "This parameter is automatically set to identify external modes. It ensures that modes\nget assigned to the same index independent from their startup order,\nwhich is required when mapping an external mode to an RC switch.\n\n", "name": "COM_MODE0_HASH", "shortDesc": "External mode identifier 0", "type": "Int32", "volatile": true}, {"category": "System", "default": 0, "group": "Commander", "longDesc": "This parameter is automatically set to identify external modes. It ensures that modes\nget assigned to the same index independent from their startup order,\nwhich is required when mapping an external mode to an RC switch.\n\n", "name": "COM_MODE1_HASH", "shortDesc": "External mode identifier 1", "type": "Int32", "volatile": true}, {"category": "System", "default": 0, "group": "Commander", "longDesc": "This parameter is automatically set to identify external modes. It ensures that modes\nget assigned to the same index independent from their startup order,\nwhich is required when mapping an external mode to an RC switch.\n\n", "name": "COM_MODE2_HASH", "shortDesc": "External mode identifier 2", "type": "Int32", "volatile": true}, {"category": "System", "default": 0, "group": "Commander", "longDesc": "This parameter is automatically set to identify external modes. It ensures that modes\nget assigned to the same index independent from their startup order,\nwhich is required when mapping an external mode to an RC switch.\n\n", "name": "COM_MODE3_HASH", "shortDesc": "External mode identifier 3", "type": "Int32", "volatile": true}, {"category": "System", "default": 0, "group": "Commander", "longDesc": "This parameter is automatically set to identify external modes. It ensures that modes\nget assigned to the same index independent from their startup order,\nwhich is required when mapping an external mode to an RC switch.\n\n", "name": "COM_MODE4_HASH", "shortDesc": "External mode identifier 4", "type": "Int32", "volatile": true}, {"category": "System", "default": 0, "group": "Commander", "longDesc": "This parameter is automatically set to identify external modes. It ensures that modes\nget assigned to the same index independent from their startup order,\nwhich is required when mapping an external mode to an RC switch.\n\n", "name": "COM_MODE5_HASH", "shortDesc": "External mode identifier 5", "type": "Int32", "volatile": true}, {"category": "System", "default": 0, "group": "Commander", "longDesc": "This parameter is automatically set to identify external modes. It ensures that modes\nget assigned to the same index independent from their startup order,\nwhich is required when mapping an external mode to an RC switch.\n\n", "name": "COM_MODE6_HASH", "shortDesc": "External mode identifier 6", "type": "Int32", "volatile": true}, {"category": "System", "default": 0, "group": "Commander", "longDesc": "This parameter is automatically set to identify external modes. It ensures that modes\nget assigned to the same index independent from their startup order,\nwhich is required when mapping an external mode to an RC switch.\n\n", "name": "COM_MODE7_HASH", "shortDesc": "External mode identifier 7", "type": "Int32", "volatile": true}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "By default disabled for safety reasons\n", "name": "COM_MODE_ARM_CHK", "shortDesc": "Allow external mode registration while armed", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "The offboard loss failsafe will only be entered after a timeout,\nset by COM_OF_LOSS_T in seconds.\n", "name": "COM_OBL_RC_ACT", "shortDesc": "Set offboard loss failsafe mode", "type": "Int32", "values": [{"description": "Position mode", "value": 0}, {"description": "Altitude mode", "value": 1}, {"description": "Stabilized", "value": 2}, {"description": "Return mode", "value": 3}, {"description": "Land mode", "value": 4}, {"description": "Hold mode", "value": 5}, {"description": "Terminate", "value": 6}, {"description": "Disarm", "value": 7}]}, {"category": "Standard", "default": 1.0, "group": "Commander", "increment": 0.01, "longDesc": "Time-out to wait when offboard connection is lost before triggering offboard lost action\n\nSee COM_OBL_RC_ACT to configure action.\n", "max": 60.0, "min": 0.0, "name": "COM_OF_LOSS_T", "shortDesc": "Offboard connection loss timeout", "type": "Float", "units": "s"}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "Require a MAVLink parachute system for arming and the failsafe action when missing or unhealthy.\n\nWarning only warns without preventing arming. Actions other than Warning also prevent arming.\n", "name": "COM_PARACHUTE", "shortDesc": "Parachute requirement and failsafe", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Warning", "value": 1}, {"description": "Error", "value": 2}, {"description": "Return", "value": 3}, {"description": "Land", "value": 4}]}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "Final fallback failsafe action for loss of horizontal position in autonomous modes:\n- Descend (potential for horizontal drift on landing)\n- Flight termination (allows parachute landing)\n", "name": "COM_POS_FS_ACT", "shortDesc": "Loss of position failsafe action", "type": "Int32", "values": [{"description": "Descend mode", "value": 0}, {"description": "Terminate", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "Commander", "longDesc": "This is the horizontal position error (EPH) threshold that will trigger a failsafe.\nIf the previous position error was below this threshold, there is an additional\nfactor of 2.5 applied (threshold for invalidation 2.5 times the one for validation).\nOnly used for multicopters and VTOLs in hover mode.\nIndependent from estimator positioning data timeout threshold (see EKF2_NOAID_TOUT).\n\nSet to -1 to disable.\n", "max": 400.0, "min": -1.0, "name": "COM_POS_FS_EPH", "shortDesc": "Horizontal position error threshold for hovering systems", "type": "Float", "units": "m"}, {"category": "Standard", "default": 3, "group": "Commander", "increment": 1, "longDesc": "Action the system takes when the estimated position has an accuracy below the specified threshold.\nSee COM_POS_LOW_EPH to set the failsafe threshold.\nThe failsafe action is only executed if the vehicle is in auto mission or auto loiter mode,\notherwise it is only a warning.\n", "name": "COM_POS_LOW_ACT", "shortDesc": "Low position accuracy action", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Warning", "value": 1}, {"description": "Hold", "value": 2}, {"description": "Return", "value": 3}, {"description": "Terminate", "value": 4}, {"description": "Land", "value": 5}]}, {"category": "Standard", "default": -1.0, "group": "Commander", "longDesc": "This triggers the action specified in COM_POS_LOW_ACT if the estimated position accuracy is below this threshold.\nLocal position has to be still declared valid, which requires some kind of velocity aiding or large dead-reckoning time (EKF2_NOAID_TOUT),\nand a high failsafe threshold (COM_POS_FS_EPH).\n\nSet to -1 to disable.\n", "max": 1000.0, "min": -1.0, "name": "COM_POS_LOW_EPH", "shortDesc": "Low position accuracy failsafe threshold", "type": "Float", "units": "m"}, {"category": "Standard", "default": 1, "group": "Commander", "longDesc": "This configures a check to verify the expected number of 5V rail power supplies are present. By default only one is expected.\nNote: CBRK_SUPPLY_CHK disables all power checks including this one.\n", "max": 4, "min": 0, "name": "COM_POWER_COUNT", "shortDesc": "Required number of redundant power modules", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "Condition to enter the prearmed state, an intermediate state between disarmed and armed\nin which non-throttling actuators are active.\n\n0: Never prearmed.\n1: Prearmed when safety is off (COM_SAFETY_MODE)\n2: Always prearmed.\n", "name": "COM_PREARM_MODE", "shortDesc": "Condition to enter prearmed mode", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "When safety off", "value": 1}, {"description": "Always", "value": 2}]}, {"category": "Standard", "default": 0, "group": "Commander", "name": "COM_QC_ACT", "shortDesc": "Set action after a quadchute", "type": "Int32", "values": [{"description": "Warning only", "value": -1}, {"description": "Return mode", "value": 0}, {"description": "Land mode", "value": 1}, {"description": "Hold mode", "value": 2}]}, {"category": "Standard", "default": 95.0, "group": "Commander", "increment": 1.0, "longDesc": "The check fails if the RAM usage is above this threshold.\n\nA negative value disables the check.\n", "max": 100.0, "min": -1.0, "name": "COM_RAM_MAX", "shortDesc": "Maximum allowed RAM usage to pass checks", "type": "Float", "units": "%"}, {"bitmask": [{"description": "Mission", "index": 0}, {"description": "Auto modes", "index": 1}, {"description": "Offboard", "index": 2}, {"description": "External Mode", "index": 3}, {"description": "Altitude Cruise", "index": 4}], "category": "Standard", "default": 0, "group": "Commander", "longDesc": "Specify modes in which stick input is ignored and no failsafe action is triggered.\nExternal modes requiring stick input will still failsafe.\nAuto modes are: Hold, Takeoff, Land, Return, Descend, Follow Target, Precland, Orbit.\n", "max": 31, "min": 0, "name": "COM_RCL_EXCEPT", "shortDesc": "Manual control loss exceptions", "type": "Int32"}, {"category": "Standard", "default": 3, "group": "Commander", "longDesc": "RC receiver or MAVLink joystick (MANUAL_CONTROL). Priority modes switch to a higher-priority source as soon as it becomes valid. MAVL 1 is the lower MAVLink instance.\n", "name": "COM_RC_IN_MODE", "shortDesc": "Manual control input source configuration", "type": "Int32", "values": [{"description": "RC only (requires RC calibration)", "value": 0}, {"description": "MAVLink only (disables RC checks)", "value": 1}, {"description": "RC or MAVLink with fallback", "value": 2}, {"description": "RC or MAVLink keep first until reboot", "value": 3}, {"description": "Disable manual control", "value": 4}, {"description": "Prio: RC > MAVL 1 > MAVL 2", "value": 5}, {"description": "Prio: MAVL 1 > MAVL 2 > RC", "value": 6}, {"description": "Prio: RC > MAVL 2 > MAVL 1", "value": 7}, {"description": "Prio: MAVL 2 > MAVL 1 > RC", "value": 8}]}, {"category": "Standard", "decimalPlaces": 1, "default": 0.5, "group": "Commander", "increment": 0.1, "longDesc": "The time in seconds without a new setpoint from RC or Joystick, after which the connection is considered lost.\nThis must be kept short as the vehicle will use the last supplied setpoint until the timeout triggers.\nEnsure the value is not set lower than the update interval of the RC or Joystick.\n", "max": 35.0, "min": 0.0, "name": "COM_RC_LOSS_T", "shortDesc": "Manual control loss timeout", "type": "Float", "units": "s"}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "Condition to turn safety off. Vehicle arming is prevented for as long as safety is on.\n\n0: Always off.\n1: Safety can be turned off either by pressing a physical safety switch, or by sending a MAV_CMD_DO_SET_SAFETY_SWITCH_STATE command.\n2: Safety can only be turned off by pressing a physical safety switch. MAV_CMD_DO_SET_SAFETY_SWITCH_STATE commands are rejected.\n3: Safety can only be turned off by sending a MAV_CMD_DO_SET_SAFETY_SWITCH_STATE command. Any physical switch is ignored.\n", "name": "COM_SAFETY_MODE", "rebootRequired": true, "shortDesc": "Condition to turn safety off", "type": "Int32", "values": [{"description": "Always off", "value": 0}, {"description": "Safety switch (physical or virtual via MAVLink)", "value": 1}, {"description": "Physical safety switch only", "value": 2}, {"description": "MAVLink only", "value": 3}]}, {"category": "Standard", "decimalPlaces": 1, "default": 1.0, "group": "Commander", "increment": 0.1, "longDesc": "The minimal time from arming the motors until moving the vehicle is possible is COM_SPOOLUP_TIME seconds.\nGoal:\n- Motors and propellers spool up to idle speed before getting commanded to spin faster\n- Timeout for ESCs and smart batteries to successfulyy do failure checks\ne.g. for stuck rotors before the vehicle is off the ground\n", "max": 30.0, "min": 0.0, "name": "COM_SPOOLUP_TIME", "shortDesc": "Enforced delay between arming and further navigation", "type": "Float", "units": "s"}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "Allows to start the vehicle by throwing it into the air.\n", "name": "COM_THROW_EN", "shortDesc": "Enable throw-start", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "Commander", "increment": 0.1, "longDesc": "When the throw launch is enabled, the drone will only allow motors to spin after this speed\nis exceeded before detecting the freefall. This is a safety feature to ensure the drone does\nnot turn on after accidental drop or a rapid movement before the throw.\n\nSet to 0 to disable.\n", "min": 0.0, "name": "COM_THROW_SPEED", "shortDesc": "Minimum speed for the throw start", "type": "Float", "units": "m/s"}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "Warn about, and optionally require, a traffic avoidance system (ADS-B/FLARM\ntransponder, detected via MAVLink heartbeats with a 3 second timeout), and\ntrigger a failsafe action when it is missing or lost in flight.\n", "name": "COM_TRAFF_AVOID", "shortDesc": "Traffic avoidance system requirement and failsafe", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Warning", "value": 1}, {"description": "Error", "value": 2}, {"description": "Return", "value": 3}, {"description": "Land", "value": 4}]}, {"category": "Standard", "decimalPlaces": 1, "default": 1.0, "group": "Commander", "longDesc": "This is the horizontal velocity error (EVH) threshold that will trigger a failsafe.\nThe default is appropriate for a multicopter. Can be increased for a fixed-wing.\nIf the previous velocity error was below this threshold, there is an additional\nfactor of 2.5 applied (threshold for invalidation 2.5 times the one for validation).\n", "min": 0.0, "name": "COM_VEL_FS_EVH", "shortDesc": "Horizontal velocity error threshold", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": -1.0, "group": "Commander", "increment": 0.1, "longDesc": "Wind speed threshold above which an automatic failsafe action is triggered.\nFailsafe action can be specified with COM_WIND_MAX_ACT.\n", "min": -1.0, "name": "COM_WIND_MAX", "shortDesc": "High wind speed failsafe threshold", "type": "Float", "units": "m/s"}, {"category": "Standard", "default": 0, "group": "Commander", "increment": 1, "longDesc": "Action the system takes when a wind speed above the specified threshold is detected.\nSee COM_WIND_MAX to set the failsafe threshold.\nIf enabled, it is not possible to resume the mission or switch to any auto mode other than\nReturn or Land if this threshold is exceeded. Taking over in any manual\nmode is still possible.\n", "name": "COM_WIND_MAX_ACT", "shortDesc": "High wind failsafe mode", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Warning", "value": 1}, {"description": "Hold", "value": 2}, {"description": "Return", "value": 3}, {"description": "Terminate", "value": 4}, {"description": "Land", "value": 5}]}, {"category": "Standard", "decimalPlaces": 1, "default": -1.0, "group": "Commander", "increment": 0.1, "longDesc": "A warning is triggered if the currently estimated wind speed is above this value.\nWarning is sent periodically (every 1 minute).\n\nSet to -1 to disable.\n", "min": -1.0, "name": "COM_WIND_WARN", "shortDesc": "Wind speed warning threshold", "type": "Float", "units": "m/s"}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "The GCS connection loss failsafe will only be entered after a timeout,\nset by COM_DL_LOSS_T in seconds. Once the timeout occurs the selected\naction will be executed.\n", "name": "NAV_DLL_ACT", "shortDesc": "Set GCS connection loss failsafe mode", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Hold mode", "value": 1}, {"description": "Return mode", "value": 2}, {"description": "Land mode", "value": 3}, {"description": "Terminate", "value": 5}, {"description": "Disarm", "value": 6}]}, {"category": "Standard", "default": 2, "group": "Commander", "longDesc": "The manual control loss failsafe will only be entered after a timeout,\nset by COM_RC_LOSS_T in seconds.\n\n\"Hold mode (no failsafe)\" does not trigger the failsafe: instead, if manual control\nis lost while actively flying a manual mode, the vehicle switches to Hold as a regular\nmode change (no failsafe state, no alarming notification). If Hold cannot be entered\n(e.g. without a valid position estimate), the normal failsafe takes over and escalates\nfrom there (Return/Land/Descend/Terminate as applicable).\n", "name": "NAV_RCL_ACT", "shortDesc": "Set manual control loss failsafe mode", "type": "Int32", "values": [{"description": "Hold mode", "value": 1}, {"description": "Return mode", "value": 2}, {"description": "Land mode", "value": 3}, {"description": "Terminate", "value": 5}, {"description": "Disarm", "value": 6}, {"description": "Hold mode (no failsafe)", "value": 7}]}, {"category": "Standard", "default": 1, "group": "Detect and Avoid", "name": "DAA_EN", "shortDesc": "Enable DAA", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 20, "group": "Detect and Avoid", "longDesc": "Time between notifications for the most urgent conflict. Set to 0 to disable the periodic status notification.\n", "max": 600, "min": 0, "name": "DAA_NOTIF_STATE", "shortDesc": "DAA status notification period", "type": "Int32", "units": "s"}, {"category": "Standard", "default": 20, "group": "Detect and Avoid", "longDesc": "Conflict age before removal.\n", "max": 120, "min": 1, "name": "DAA_TRAFF_TOUT", "shortDesc": "DAA stale conflict timeout", "type": "Int32", "units": "s"}, {"category": "Standard", "default": 10.0, "group": "Detect and Avoid F3442 Standard", "longDesc": "Used when DAA_EN_DFLT_VEL is enabled. Specific to the F3442 DAA standard.\n", "min": 0.0, "name": "DAA_DFLT_VEL", "shortDesc": "Default vertical speed of other aircraft", "type": "Float", "units": "m/s"}, {"category": "Standard", "default": 1, "group": "Detect and Avoid F3442 Standard", "longDesc": "Use DAA_DFLT_VEL instead of reported traffic vertical speed. Specific to the F3442 DAA standard.\n", "name": "DAA_EN_DFLT_VEL", "shortDesc": "Ignore reported vertical speed of other aircraft", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 1, "group": "Detect and Avoid F3442 Standard", "longDesc": "Action requested when the critical conflict level is reached.\nRuntime changes apply on later conflict level transitions.\nSpecific to the F3442 DAA standard.\n", "max": 5, "min": 0, "name": "DAA_LVL_CRIT_ACT", "shortDesc": "Critical conflict action", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Warn only", "value": 1}, {"description": "Return mode", "value": 2}, {"description": "Land mode", "value": 3}, {"description": "Position Hold mode", "value": 4}, {"description": "Terminate", "value": 5}]}, {"category": "Standard", "default": 16.0, "group": "Detect and Avoid F3442 Standard", "longDesc": "Per-aircraft half-zone. Specific to the F3442 DAA standard.\n", "min": 10.0, "name": "DAA_LVL_CRIT_HGT", "shortDesc": "Critical conflict zone cylinder height (NMAC)", "type": "Float", "units": "m"}, {"category": "Standard", "default": 77.0, "group": "Detect and Avoid F3442 Standard", "longDesc": "Per-aircraft half-zone. Specific to the F3442 DAA standard.\n", "min": 10.0, "name": "DAA_LVL_CRIT_RAD", "shortDesc": "Critical conflict zone cylinder radius (NMAC)", "type": "Float", "units": "m"}, {"category": "Standard", "default": 1, "group": "Detect and Avoid F3442 Standard", "longDesc": "Action requested when the high conflict level is reached.\nRuntime changes apply on later conflict level transitions.\nSpecific to the F3442 DAA standard.\n", "max": 5, "min": 0, "name": "DAA_LVL_HIGH_ACT", "shortDesc": "High conflict action", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Warn only", "value": 1}, {"description": "Return mode", "value": 2}, {"description": "Land mode", "value": 3}, {"description": "Position Hold mode", "value": 4}, {"description": "Terminate", "value": 5}]}, {"category": "Standard", "default": 39.0, "group": "Detect and Avoid F3442 Standard", "longDesc": "Per-aircraft half-zone. Specific to the F3442 DAA standard.\n", "min": 10.0, "name": "DAA_LVL_HIGH_HGT", "shortDesc": "High conflict zone cylinder height (WC)", "type": "Float", "units": "m"}, {"category": "Standard", "default": 305.0, "group": "Detect and Avoid F3442 Standard", "longDesc": "Per-aircraft half-zone. Specific to the F3442 DAA standard.\n", "min": 10.0, "name": "DAA_LVL_HIGH_RAD", "shortDesc": "High conflict zone cylinder radius (WC)", "type": "Float", "units": "m"}, {"category": "Standard", "default": 1, "group": "Detect and Avoid F3442 Standard", "longDesc": "Action requested when the low conflict level is reached.\nRuntime changes apply on later conflict level transitions.\nSpecific to the F3442 DAA standard.\n", "max": 5, "min": 0, "name": "DAA_LVL_LOW_ACT", "shortDesc": "Low conflict action", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Warn only", "value": 1}, {"description": "Return mode", "value": 2}, {"description": "Land mode", "value": 3}, {"description": "Position Hold mode", "value": 4}, {"description": "Terminate", "value": 5}]}, {"category": "Standard", "default": 33, "group": "Detect and Avoid F3442 Standard", "longDesc": "Expands well-clear bounds by aircraft speed times this value. Specific to the F3442 DAA standard.\n", "min": 0, "name": "DAA_LVL_LOW_TIME", "shortDesc": "Low conflict latency time", "type": "Int32", "units": "s"}, {"category": "Standard", "default": 1, "group": "Detect and Avoid F3442 Standard", "longDesc": "Action requested when the medium conflict level is reached.\nRuntime changes apply on later conflict level transitions.\nSpecific to the F3442 DAA standard.\n", "max": 5, "min": 0, "name": "DAA_LVL_MED_ACT", "shortDesc": "Medium conflict action", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Warn only", "value": 1}, {"description": "Return mode", "value": 2}, {"description": "Land mode", "value": 3}, {"description": "Position Hold mode", "value": 4}, {"description": "Terminate", "value": 5}]}, {"category": "Standard", "default": 33, "group": "Detect and Avoid F3442 Standard", "longDesc": "Expands NMAC bounds by aircraft speed times this value. Specific to the F3442 DAA standard.\n", "min": 0, "name": "DAA_LVL_MED_TIME", "shortDesc": "Medium conflict latency time", "type": "Int32", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.2, "group": "EKF2", "max": 0.5, "min": 0.0, "name": "EKF2_ABIAS_INIT", "rebootRequired": true, "shortDesc": "1-sigma IMU accelerometer switch-on bias", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "decimalPlaces": 1, "default": 25.0, "group": "EKF2", "longDesc": "If the magnitude of the IMU accelerometer vector exceeds this value, the EKF accel bias state estimation will be inhibited. This reduces the adverse effect of high manoeuvre accelerations and IMU nonlinerity and scale factor errors on the accel bias estimates.\n", "max": 200.0, "min": 20.0, "name": "EKF2_ABL_ACCLIM", "shortDesc": "Maximum IMU accel magnitude that allows IMU bias learning", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "EKF2", "longDesc": "If the magnitude of the IMU angular rate vector exceeds this value, the EKF accel bias state estimation will be inhibited. This reduces the adverse effect of rapid rotation rates and associated errors on the accel bias estimates.\n", "max": 20.0, "min": 2.0, "name": "EKF2_ABL_GYRLIM", "shortDesc": "Maximum IMU gyro angular rate magnitude that allows IMU bias learning", "type": "Float", "units": "rad/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.4, "group": "EKF2", "longDesc": "The ekf accel bias states will be limited to within a range equivalent to +- of this value.\n", "max": 0.8, "min": 0.0, "name": "EKF2_ABL_LIM", "shortDesc": "Accelerometer bias learning limit", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.5, "group": "EKF2", "longDesc": "The vector magnitude of angular rate and acceleration used to check if learning should be inhibited has a peak hold filter applied to it with an exponential decay. This parameter controls the time constant of the decay.\n", "max": 1.0, "min": 0.1, "name": "EKF2_ABL_TAU", "shortDesc": "Accel bias learning inhibit time constant", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 6, "default": 0.003, "group": "EKF2", "max": 0.01, "min": 0.0, "name": "EKF2_ACC_B_NOISE", "shortDesc": "Process noise for IMU accelerometer bias prediction", "type": "Float", "units": "m/s^3"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.35, "group": "EKF2", "max": 1.0, "min": 0.01, "name": "EKF2_ACC_NOISE", "shortDesc": "Accelerometer noise for covariance prediction", "type": "Float", "units": "m/s^2"}, {"bitmask": [{"description": "Horizontal position", "index": 0}, {"description": "Vertical position (reserved, not implemented)", "index": 1}], "category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Set bit 0 to enable the horizontal position fusion. Bit 1 is reserved for vertical position fusion, which is not implemented: the altitude is not fused, it only takes part when the global origin is first set from this source.\n", "max": 3, "min": 0, "name": "EKF2_AGP0_CTRL", "shortDesc": "Auxiliary global position sensor 0 aiding", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "EKF2", "max": 1000.0, "min": 0.0, "name": "EKF2_AGP0_DELAY", "rebootRequired": true, "shortDesc": "Auxiliary global position sensor 0 delay (to IMU)", "type": "Float", "units": "ms"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "EKF2", "longDesc": "Sets the number of standard deviations used by the innovation consistency test.\n", "min": 1.0, "name": "EKF2_AGP0_GATE", "shortDesc": "Gate size for auxiliary global position sensor 0 fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Sensor ID for slot 0. Set to 0 to disable this slot.\n", "max": 255, "min": 0, "name": "EKF2_AGP0_ID", "rebootRequired": true, "shortDesc": "Auxiliary global position sensor 0 ID", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Automatic: reset on fusion timeout if no other source of position is available Dead-reckoning: reset on fusion timeout if no source of velocity is available\n", "name": "EKF2_AGP0_MODE", "shortDesc": "Fusion reset mode for sensor 0", "type": "Int32", "values": [{"description": "Automatic", "value": 0}, {"description": "Dead-reckoning", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "EKF2", "longDesc": "Used to lower bound or replace the uncertainty included in the message\n", "min": 0.01, "name": "EKF2_AGP0_NOISE", "shortDesc": "Measurement noise for auxiliary global position sensor 0", "type": "Float", "units": "m"}, {"bitmask": [{"description": "Horizontal position", "index": 0}, {"description": "Vertical position (reserved, not implemented)", "index": 1}], "category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Set bit 0 to enable the horizontal position fusion. Bit 1 is reserved for vertical position fusion, which is not implemented: the altitude is not fused, it only takes part when the global origin is first set from this source.\n", "max": 3, "min": 0, "name": "EKF2_AGP1_CTRL", "shortDesc": "Auxiliary global position sensor 1 aiding", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "EKF2", "max": 1000.0, "min": 0.0, "name": "EKF2_AGP1_DELAY", "rebootRequired": true, "shortDesc": "Auxiliary global position sensor 1 delay (to IMU)", "type": "Float", "units": "ms"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "EKF2", "longDesc": "Sets the number of standard deviations used by the innovation consistency test.\n", "min": 1.0, "name": "EKF2_AGP1_GATE", "shortDesc": "Gate size for auxiliary global position sensor 1 fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Sensor ID for slot 1. Set to 0 to disable this slot.\n", "max": 255, "min": 0, "name": "EKF2_AGP1_ID", "rebootRequired": true, "shortDesc": "Auxiliary global position sensor 1 ID", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Automatic: reset on fusion timeout if no other source of position is available Dead-reckoning: reset on fusion timeout if no source of velocity is available\n", "name": "EKF2_AGP1_MODE", "shortDesc": "Fusion reset mode for sensor 1", "type": "Int32", "values": [{"description": "Automatic", "value": 0}, {"description": "Dead-reckoning", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "EKF2", "longDesc": "Used to lower bound or replace the uncertainty included in the message\n", "min": 0.01, "name": "EKF2_AGP1_NOISE", "shortDesc": "Measurement noise for auxiliary global position sensor 1", "type": "Float", "units": "m"}, {"bitmask": [{"description": "Horizontal position", "index": 0}, {"description": "Vertical position (reserved, not implemented)", "index": 1}], "category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Set bit 0 to enable the horizontal position fusion. Bit 1 is reserved for vertical position fusion, which is not implemented: the altitude is not fused, it only takes part when the global origin is first set from this source.\n", "max": 3, "min": 0, "name": "EKF2_AGP2_CTRL", "shortDesc": "Auxiliary global position sensor 2 aiding", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "EKF2", "max": 1000.0, "min": 0.0, "name": "EKF2_AGP2_DELAY", "rebootRequired": true, "shortDesc": "Auxiliary global position sensor 2 delay (to IMU)", "type": "Float", "units": "ms"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "EKF2", "longDesc": "Sets the number of standard deviations used by the innovation consistency test.\n", "min": 1.0, "name": "EKF2_AGP2_GATE", "shortDesc": "Gate size for auxiliary global position sensor 2 fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Sensor ID for slot 2. Set to 0 to disable this slot.\n", "max": 255, "min": 0, "name": "EKF2_AGP2_ID", "rebootRequired": true, "shortDesc": "Auxiliary global position sensor 2 ID", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Automatic: reset on fusion timeout if no other source of position is available Dead-reckoning: reset on fusion timeout if no source of velocity is available\n", "name": "EKF2_AGP2_MODE", "shortDesc": "Fusion reset mode for sensor 2", "type": "Int32", "values": [{"description": "Automatic", "value": 0}, {"description": "Dead-reckoning", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "EKF2", "longDesc": "Used to lower bound or replace the uncertainty included in the message\n", "min": 0.01, "name": "EKF2_AGP2_NOISE", "shortDesc": "Measurement noise for auxiliary global position sensor 2", "type": "Float", "units": "m"}, {"bitmask": [{"description": "Horizontal position", "index": 0}, {"description": "Vertical position (reserved, not implemented)", "index": 1}], "category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Set bit 0 to enable the horizontal position fusion. Bit 1 is reserved for vertical position fusion, which is not implemented: the altitude is not fused, it only takes part when the global origin is first set from this source.\n", "max": 3, "min": 0, "name": "EKF2_AGP3_CTRL", "shortDesc": "Auxiliary global position sensor 3 aiding", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "EKF2", "max": 1000.0, "min": 0.0, "name": "EKF2_AGP3_DELAY", "rebootRequired": true, "shortDesc": "Auxiliary global position sensor 3 delay (to IMU)", "type": "Float", "units": "ms"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "EKF2", "longDesc": "Sets the number of standard deviations used by the innovation consistency test.\n", "min": 1.0, "name": "EKF2_AGP3_GATE", "shortDesc": "Gate size for auxiliary global position sensor 3 fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Sensor ID for slot 3. Set to 0 to disable this slot.\n", "max": 255, "min": 0, "name": "EKF2_AGP3_ID", "rebootRequired": true, "shortDesc": "Auxiliary global position sensor 3 ID", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Automatic: reset on fusion timeout if no other source of position is available Dead-reckoning: reset on fusion timeout if no source of velocity is available\n", "name": "EKF2_AGP3_MODE", "shortDesc": "Fusion reset mode for sensor 3", "type": "Int32", "values": [{"description": "Automatic", "value": 0}, {"description": "Dead-reckoning", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "EKF2", "longDesc": "Used to lower bound or replace the uncertainty included in the message\n", "min": 0.01, "name": "EKF2_AGP3_NOISE", "shortDesc": "Measurement noise for auxiliary global position sensor 3", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.1, "group": "EKF2", "max": 0.5, "min": 0.0, "name": "EKF2_ANGERR_INIT", "rebootRequired": true, "shortDesc": "1-sigma tilt angle uncertainty after gravity vector alignment", "type": "Float", "units": "rad"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "EKF2", "longDesc": "Airspeed data is fused for wind estimation if above this threshold. Set to 0 to disable airspeed fusion. For reliable wind estimation both sideslip (see EKF2_FUSE_BETA) and airspeed fusion should be enabled. Only applies to fixed-wing vehicles (or VTOLs in fixed-wing mode).\n", "min": 0.0, "name": "EKF2_ARSP_THR", "shortDesc": "Airspeed fusion threshold", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 20.0, "group": "EKF2", "max": 50.0, "min": 5.0, "name": "EKF2_ASPD_MAX", "shortDesc": "Maximum airspeed used for baro static pressure compensation", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 100.0, "group": "EKF2", "max": 300.0, "min": 0.0, "name": "EKF2_ASP_DELAY", "rebootRequired": true, "shortDesc": "Airspeed measurement delay relative to IMU measurements", "type": "Float", "units": "ms"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "EKF2", "max": 300.0, "min": 0.0, "name": "EKF2_AVEL_DELAY", "rebootRequired": true, "shortDesc": "Auxiliary Velocity Estimate delay relative to IMU measurements", "type": "Float", "units": "ms"}, {"category": "Standard", "default": 1, "group": "EKF2", "longDesc": "When enabled, EKF2 fuses the relative velocity published in landing_target_pose\n(vx_rel, vy_rel) as a horizontal auxiliary velocity measurement. The data is\nonly fused when landing_target_pose.rel_vel_ekf2_valid is true.\n", "name": "EKF2_AVEL_EN", "shortDesc": "Fuse the landing-target relative velocity as auxiliary velocity", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 1, "group": "EKF2", "longDesc": "If this parameter is enabled then the estimator will make use of the barometric height measurements to estimate its height in addition to other height sources (if activated).\n", "name": "EKF2_BARO_CTRL", "shortDesc": "Barometric sensor height aiding", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "EKF2", "max": 300.0, "min": 0.0, "name": "EKF2_BARO_DELAY", "rebootRequired": true, "shortDesc": "Barometer measurement delay relative to IMU measurements", "type": "Float", "units": "ms"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "EKF2", "longDesc": "Sets the number of standard deviations used by the innovation consistency test.\n", "min": 1.0, "name": "EKF2_BARO_GATE", "shortDesc": "Gate size for barometric and GPS height fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "decimalPlaces": 2, "default": 3.5, "group": "EKF2", "max": 15.0, "min": 0.01, "name": "EKF2_BARO_NOISE", "shortDesc": "Measurement noise for barometric altitude", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 100.0, "group": "EKF2", "longDesc": "Bluff body drag along the forward/reverse axis, which scales with speed squared. Rotor drag is set by EKF2_MCOEF. Only used when EKF2_DRAG_CTRL is enabled. Set to 0 to disable for this axis.\n", "max": 200.0, "min": 0.0, "name": "EKF2_BCOEF_X", "shortDesc": "X-axis ballistic coefficient used for multi-rotor wind estimation", "type": "Float", "units": "kg/m^2"}, {"category": "Standard", "decimalPlaces": 1, "default": 100.0, "group": "EKF2", "longDesc": "Bluff body drag along the right/left axis, which scales with speed squared. Rotor drag is set by EKF2_MCOEF. Only used when EKF2_DRAG_CTRL is enabled. Set to 0 to disable for this axis.\n", "max": 200.0, "min": 0.0, "name": "EKF2_BCOEF_Y", "shortDesc": "Y-axis ballistic coefficient used for multi-rotor wind estimation", "type": "Float", "units": "kg/m^2"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "EKF2", "longDesc": "Sets the number of standard deviations used by the innovation consistency test.\n", "min": 1.0, "name": "EKF2_BETA_GATE", "shortDesc": "Gate size for synthetic sideslip fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "EKF2", "max": 1.0, "min": 0.1, "name": "EKF2_BETA_NOISE", "shortDesc": "Noise for synthetic sideslip fusion", "type": "Float", "units": "m/s"}, {"bitmask": [{"description": "use geo_lookup declination", "index": 0}, {"description": "save EKF2_MAG_DECL on disarm", "index": 1}], "category": "Standard", "default": 3, "group": "EKF2", "longDesc": "Set bits in the following positions to enable functions. 0 : Set to true to use the declination from the geo_lookup library when the GPS position becomes available, set to false to always use the EKF2_MAG_DECL value. 1 : Set to true to save the EKF2_MAG_DECL parameter to the value returned by the EKF when the vehicle disarms.\n", "max": 3, "min": 0, "name": "EKF2_DECL_TYPE", "rebootRequired": true, "shortDesc": "Integer bitmask controlling handling of magnetic declination", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 1, "default": 200.0, "group": "EKF2", "longDesc": "Defines the delay between the current time and the delayed-time horizon. This value should be at least as large as the largest EKF2_XXX_DELAY parameter.\n", "max": 1000.0, "min": 0.0, "name": "EKF2_DELAY_MAX", "rebootRequired": true, "shortDesc": "Maximum delay of all the aiding sensors", "type": "Float", "units": "ms"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Activate wind speed estimation using specific-force measurements and a drag model defined by EKF2_BCOEF_[XY] and EKF2_MCOEF. Only use on vehicles that have their thrust aligned with the Z axis and no thrust in the XY plane.\n", "name": "EKF2_DRAG_CTRL", "shortDesc": "Multirotor wind estimation selection", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 2.5, "group": "EKF2", "longDesc": "Used by the multi-rotor specific drag force model. Increasing this makes the multi-rotor wind estimates adjust more slowly.\n", "max": 10.0, "min": 0.5, "name": "EKF2_DRAG_NOISE", "shortDesc": "Specific drag force observation noise variance", "type": "Float", "units": "(m/s^2)^2"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.4, "group": "EKF2", "max": 5.0, "min": 0.5, "name": "EKF2_EAS_NOISE", "shortDesc": "Measurement noise for airspeed fusion", "type": "Float", "units": "m/s"}, {"category": "Standard", "default": 1, "group": "EKF2", "name": "EKF2_EN", "shortDesc": "EKF2 enable", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "EKF2", "longDesc": "Used to lower bound or replace the uncertainty included in the message\n", "min": 0.05, "name": "EKF2_EVA_NOISE", "shortDesc": "Measurement noise for vision angle measurements", "type": "Float", "units": "rad"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "EKF2", "longDesc": "Sets the number of standard deviations used by the innovation consistency test.\n", "min": 1.0, "name": "EKF2_EVP_GATE", "shortDesc": "Gate size for vision position fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "EKF2", "longDesc": "Used to lower bound or replace the uncertainty included in the message\n", "min": 0.01, "name": "EKF2_EVP_NOISE", "shortDesc": "Measurement noise for vision position measurements", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "EKF2", "longDesc": "Sets the number of standard deviations used by the innovation consistency test.\n", "min": 1.0, "name": "EKF2_EVV_GATE", "shortDesc": "Gate size for vision velocity estimate fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "EKF2", "longDesc": "Used to lower bound or replace the uncertainty included in the message\n", "min": 0.01, "name": "EKF2_EVV_NOISE", "shortDesc": "Measurement noise for vision velocity measurements", "type": "Float", "units": "m/s"}, {"bitmask": [{"description": "Horizontal position", "index": 0}, {"description": "Vertical position", "index": 1}, {"description": "3D velocity", "index": 2}, {"description": "Yaw", "index": 3}], "category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Set bits in the following positions to enable: 0 : Horizontal position fusion 1 : Vertical position fusion 2 : 3D velocity fusion 3 : Yaw\n", "max": 15, "min": 0, "name": "EKF2_EV_CTRL", "shortDesc": "External vision (EV) sensor aiding", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "EKF2", "max": 300.0, "min": 0.0, "name": "EKF2_EV_DELAY", "rebootRequired": true, "shortDesc": "Vision Position Estimator delay relative to IMU measurements", "type": "Float", "units": "ms"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "If set to 0 (default) the measurement noise is taken from the vision message and the EV noise parameters are used as a lower bound. If set to 1 the observation noise is set from the parameters directly,\n", "name": "EKF2_EV_NOISE_MD", "shortDesc": "External vision (EV) noise mode", "type": "Int32", "values": [{"description": "EV reported variance (parameter lower bound)", "value": 0}, {"description": "EV noise parameters", "value": 1}]}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "EKF2", "longDesc": "Forward axis with origin relative to vehicle centre of gravity\n", "name": "EKF2_EV_POS_X", "shortDesc": "X position of VI sensor focal point in body frame", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "EKF2", "longDesc": "Forward axis with origin relative to vehicle centre of gravity\n", "name": "EKF2_EV_POS_Y", "shortDesc": "Y position of VI sensor focal point in body frame", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "EKF2", "longDesc": "Forward axis with origin relative to vehicle centre of gravity\n", "name": "EKF2_EV_POS_Z", "shortDesc": "Z position of VI sensor focal point in body frame", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 0, "group": "EKF2", "longDesc": "External vision will only be started and fused if the quality metric is above this threshold. The quality metric is a completely optional field provided by some VIO systems.\n", "max": 100, "min": 0, "name": "EKF2_EV_QMIN", "shortDesc": "External vision (EV) minimum quality (optional)", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "For reliable wind estimation both sideslip and airspeed fusion (see EKF2_ARSP_THR) should be enabled. Only applies to vehicles in fixed-wing mode or with airspeed fusion active. Note: side slip fusion is currently not supported for tailsitters.\n", "name": "EKF2_FUSE_BETA", "shortDesc": "Enable synthetic sideslip fusion", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "EKF2", "max": 0.2, "min": 0.0, "name": "EKF2_GBIAS_INIT", "rebootRequired": true, "shortDesc": "1-sigma IMU gyro switch-on bias", "type": "Float", "units": "rad/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 4.0, "group": "EKF2", "longDesc": "Sets the value of deadzone applied to negative baro innovations. Deadzone is enabled when EKF2_GND_EFF_DZ > 0.\n", "max": 10.0, "min": 0.0, "name": "EKF2_GND_EFF_DZ", "shortDesc": "Baro deadzone range for height fusion", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.5, "group": "EKF2", "longDesc": "Sets the maximum distance to the ground level where negative baro innovations are expected.\n", "max": 5.0, "min": 0.0, "name": "EKF2_GND_MAX_HGT", "shortDesc": "Height above ground level for ground effect zone", "type": "Float", "units": "m"}, {"bitmask": [{"description": "Lon/lat", "index": 0}, {"description": "Altitude", "index": 1}, {"description": "3D velocity", "index": 2}, {"description": "Dual antenna heading", "index": 3}], "category": "Standard", "default": 7, "group": "EKF2", "longDesc": "Set bits in the following positions to enable: 0 : Longitude and latitude fusion 1 : Altitude fusion 2 : 3D velocity fusion 3 : Dual antenna heading fusion\n", "max": 15, "min": 0, "name": "EKF2_GPS_CTRL", "shortDesc": "GNSS sensor aiding", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Automatic: reset on fusion timeout if no other source of position is available. Dead-reckoning: reset on fusion timeout if no source of velocity is available.\n", "name": "EKF2_GPS_MODE", "shortDesc": "Fusion reset mode", "type": "Int32", "values": [{"description": "Automatic", "value": 0}, {"description": "Dead-reckoning", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "EKF2", "longDesc": "Sets the number of standard deviations used by the innovation consistency test.\n", "min": 1.0, "name": "EKF2_GPS_P_GATE", "shortDesc": "Gate size for GNSS position fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.5, "group": "EKF2", "max": 10.0, "min": 0.01, "name": "EKF2_GPS_P_NOISE", "shortDesc": "Measurement noise for GNSS position", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "EKF2", "longDesc": "Sets the number of standard deviations used by the innovation consistency test.\n", "min": 1.0, "name": "EKF2_GPS_V_GATE", "shortDesc": "Gate size for GNSS velocity fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "EKF2", "max": 5.0, "min": 0.01, "name": "EKF2_GPS_V_NOISE", "shortDesc": "Measurement noise for GNSS velocity", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 10.0, "group": "EKF2", "longDesc": "After GNSS heading fusion fails, or the heading receiver reports spoofing or jamming, EKF2 waits this long before resetting yaw to the GNSS heading.\n", "min": 0.1, "name": "EKF2_GPS_YAW_RST", "shortDesc": "GNSS heading reset wait", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "EKF2", "max": 10.0, "min": 0.1, "name": "EKF2_GRAV_NOISE", "shortDesc": "Accelerometer measurement noise for gravity based observations", "type": "Float", "units": "g0"}, {"category": "Standard", "decimalPlaces": 1, "default": 15.0, "group": "EKF2", "longDesc": "If no airspeed measurements are available, the EKF-GSF AHRS calculation will assume this value of true airspeed when compensating for centripetal acceleration during turns. Set to zero to disable centripetal acceleration compensation during fixed wing flight modes.\n", "max": 100.0, "min": 0.0, "name": "EKF2_GSF_TAS", "shortDesc": "Default value of true airspeed used in EKF-GSF AHRS calculation", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.15, "group": "EKF2", "longDesc": "The ekf gyro bias states will be limited to within a range equivalent to +- of this value.\n", "max": 0.4, "min": 0.0, "name": "EKF2_GYR_B_LIM", "shortDesc": "Gyro bias learning limit", "type": "Float", "units": "rad/s"}, {"category": "Standard", "decimalPlaces": 6, "default": 0.001, "group": "EKF2", "max": 0.01, "min": 0.0, "name": "EKF2_GYR_B_NOISE", "shortDesc": "Process noise for IMU rate gyro bias prediction", "type": "Float", "units": "rad/s^2"}, {"category": "Standard", "decimalPlaces": 4, "default": 0.015, "group": "EKF2", "max": 0.1, "min": 0.0001, "name": "EKF2_GYR_NOISE", "shortDesc": "Rate gyro noise for covariance prediction", "type": "Float", "units": "rad/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 2.6, "group": "EKF2", "longDesc": "Sets the number of standard deviations used by the innovation consistency test.\n", "min": 1.0, "name": "EKF2_HDG_GATE", "shortDesc": "Gate size for heading fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "EKF2", "max": 1.0, "min": 0.01, "name": "EKF2_HEAD_NOISE", "shortDesc": "Measurement noise for magnetic heading fusion", "type": "Float", "units": "rad"}, {"category": "Standard", "default": 1, "group": "EKF2", "longDesc": "When multiple height sources are enabled at the same time, the height estimate will always converge towards the reference height source selected by this parameter. The range sensor and vision options should only be used when for operation over a flat surface as the local NED origin will move up and down with ground level.\nIf GPS is set as reference and EKF2_GPS_CTRL is not 0, the GPS altitude is still used to initiaize the bias of the other height sensors, regardless of the altitude fusion bit in EKF2_GPS_CTRL.\n", "name": "EKF2_HGT_REF", "rebootRequired": true, "shortDesc": "Determines the reference source of height data used by the EKF", "type": "Int32", "values": [{"description": "Barometric pressure", "value": 0}, {"description": "GPS", "value": 1}, {"description": "Range sensor", "value": 2}, {"description": "Vision", "value": 3}]}, {"bitmask": [{"description": "Gyro Bias", "index": 0}, {"description": "Accel Bias", "index": 1}, {"description": "Gravity vector fusion", "index": 2}], "category": "Standard", "default": 7, "group": "EKF2", "max": 7, "min": 0, "name": "EKF2_IMU_CTRL", "shortDesc": "IMU control", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "EKF2", "longDesc": "Forward axis with origin relative to vehicle centre of gravity\n", "name": "EKF2_IMU_POS_X", "shortDesc": "X position of IMU in body frame", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "EKF2", "longDesc": "Forward axis with origin relative to vehicle centre of gravity\n", "name": "EKF2_IMU_POS_Y", "shortDesc": "Y position of IMU in body frame", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "EKF2", "longDesc": "Forward axis with origin relative to vehicle centre of gravity\n", "name": "EKF2_IMU_POS_Z", "shortDesc": "Z position of IMU in body frame", "type": "Float", "units": "m"}, {"category": "Standard", "default": 1, "group": "EKF2", "name": "EKF2_LOG_VERBOSE", "shortDesc": "Verbose logging", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.5, "group": "EKF2", "longDesc": "The heading is assumed to be observable when the body acceleration is greater than this parameter when a global position/velocity aiding source is active.\n", "max": 5.0, "min": 0.0, "name": "EKF2_MAG_ACCLIM", "shortDesc": "Horizontal acceleration threshold used for heading observability check", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "decimalPlaces": 6, "default": 0.0001, "group": "EKF2", "max": 0.1, "min": 0.0, "name": "EKF2_MAG_B_NOISE", "shortDesc": "Process noise for body magnetic field prediction", "type": "Float", "units": "gauss/s"}, {"bitmask": [{"description": "Strength (EKF2_MAG_CHK_STR)", "index": 0}, {"description": "Inclination (EKF2_MAG_CHK_INC)", "index": 1}, {"description": "Wait for WMM", "index": 2}], "category": "Standard", "default": 1, "group": "EKF2", "longDesc": "Bitmask to set which check is used to decide whether the magnetometer data is valid. If GNSS data is received, the magnetic field is compared to a World Magnetic Model (WMM), otherwise an average value is used. This check is useful to reject occasional hard iron disturbance. Set bits to 1 to enable checks. Checks enabled by the following bit positions 0 : Magnetic field strength. Set tolerance using EKF2_MAG_CHK_STR 1 : Magnetic field inclination. Set tolerance using EKF2_MAG_CHK_INC 2 : Wait for GNSS to find the theoretical strength and inclination using the WMM\n", "max": 7, "min": 0, "name": "EKF2_MAG_CHECK", "shortDesc": "Magnetic field strength test selection", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 1, "default": 20.0, "group": "EKF2", "longDesc": "Maximum allowed deviation from the expected magnetic field inclination to pass the check.\n", "max": 90.0, "min": 0.0, "name": "EKF2_MAG_CHK_INC", "shortDesc": "Magnetic field inclination check tolerance", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.2, "group": "EKF2", "longDesc": "Maximum allowed deviation from the expected magnetic field strength to pass the check.\n", "max": 1.0, "min": 0.0, "name": "EKF2_MAG_CHK_STR", "shortDesc": "Magnetic field strength check tolerance", "type": "Float", "units": "gauss"}, {"category": "System", "decimalPlaces": 1, "default": 0.0, "group": "EKF2", "name": "EKF2_MAG_DECL", "shortDesc": "Magnetic declination", "type": "Float", "units": "deg", "volatile": true}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "EKF2", "max": 300.0, "min": 0.0, "name": "EKF2_MAG_DELAY", "rebootRequired": true, "shortDesc": "Magnetometer measurement delay relative to IMU measurements", "type": "Float", "units": "ms"}, {"category": "Standard", "decimalPlaces": 6, "default": 0.001, "group": "EKF2", "max": 0.1, "min": 0.0, "name": "EKF2_MAG_E_NOISE", "shortDesc": "Process noise for earth magnetic field prediction", "type": "Float", "units": "gauss/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "EKF2", "longDesc": "Sets the number of standard deviations used by the innovation consistency test.\n", "min": 1.0, "name": "EKF2_MAG_GATE", "shortDesc": "Gate size for magnetometer XYZ component fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "EKF2", "max": 1.0, "min": 0.001, "name": "EKF2_MAG_NOISE", "shortDesc": "Measurement noise for magnetometer 3-axis fusion", "type": "Float", "units": "gauss"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Integer controlling the type of magnetometer fusion used - magnetic heading or 3-component vector. The fusion of magnetometer data as a three component vector enables vehicle body fixed hard iron errors to be learned, but requires a stable earth field. If set to 'Automatic' magnetic heading fusion is used when on-ground and 3-axis magnetic field fusion in-flight. If set to 'Magnetic heading' magnetic heading fusion is used at all times. If set to 'None' the magnetometer will not be used under any circumstance. If no external source of yaw is available, it is possible to use post-takeoff horizontal movement combined with GNSS velocity measurements to align the yaw angle. If set to 'Init' the magnetometer is only used to initialize the heading.\n", "name": "EKF2_MAG_TYPE", "rebootRequired": true, "shortDesc": "Type of magnetometer fusion", "type": "Int32", "values": [{"description": "Automatic", "value": 0}, {"description": "Magnetic heading", "value": 1}, {"description": "None", "value": 5}, {"description": "Init", "value": 6}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.15, "group": "EKF2", "longDesc": "Propeller momentum drag, which scales with speed, not speed squared. For unducted propellers of equal diameter, roughly proportional to blade area seen side-on; much higher for ducted rotors. Body drag is set by EKF2_BCOEF_X and EKF2_BCOEF_Y. Only used when EKF2_DRAG_CTRL is enabled. Set to 0 to disable for both axes.\n", "max": 1.0, "min": 0.0, "name": "EKF2_MCOEF", "shortDesc": "Propeller momentum drag coefficient for multi-rotor wind estimation", "type": "Float", "units": "1/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.01, "group": "EKF2", "longDesc": "If the vehicle is on ground, is not moving as determined by the motion test and the range finder is returning invalid or no data, then an assumed range value of EKF2_MIN_RNG will be used by the terrain estimator so that a terrain height estimate is available at the start of flight in situations where the range finder may be inside its minimum measurements distance when on ground.\n", "min": 0.01, "name": "EKF2_MIN_RNG", "shortDesc": "Expected range finder reading when on ground", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Maximum number of IMUs to use for Multi-EKF. Set 0 to disable. Requires SENS_IMU_MODE 0.\n", "max": 4, "min": 0, "name": "EKF2_MULTI_IMU", "rebootRequired": true, "shortDesc": "Multi-EKF IMUs", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Maximum number of magnetometers to use for Multi-EKF. Set 0 to disable. Requires SENS_MAG_MODE 0.\n", "max": 4, "min": 0, "name": "EKF2_MULTI_MAG", "rebootRequired": true, "shortDesc": "Multi-EKF Magnetometers", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 1, "default": 10.0, "group": "EKF2", "max": 50.0, "min": 0.5, "name": "EKF2_NOAID_NOISE", "shortDesc": "Measurement noise for non-aiding position hold", "type": "Float", "units": "m"}, {"category": "Standard", "default": 5000000, "group": "EKF2", "longDesc": "Maximum lapsed time from last fusion of measurements that constrain velocity drift before the EKF will report the horizontal nav solution as invalid\n", "max": 10000000, "min": 500000, "name": "EKF2_NOAID_TOUT", "shortDesc": "Maximum inertial dead-reckoning time", "type": "Int32", "units": "us"}, {"category": "Standard", "default": 1, "group": "EKF2", "longDesc": "Enable optical flow fusion.\n", "name": "EKF2_OF_CTRL", "shortDesc": "Optical flow aiding", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 7.0, "group": "EKF2", "longDesc": "Assumes measurement is timestamped at trailing edge of integration\nperiod. The default matches a DroneCAN flow node, whose frame reaches\nthe flight controller about 7 ms after its integration window closes.\n", "max": 300.0, "min": 0.0, "name": "EKF2_OF_DELAY", "rebootRequired": true, "shortDesc": "Optical flow measurement delay relative to IMU measurements", "type": "Float", "units": "ms"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "EKF2", "longDesc": "Sets the number of standard deviations used by the innovation consistency test.\n", "min": 1.0, "name": "EKF2_OF_GATE", "shortDesc": "Gate size for optical flow fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Auto: use gyro from optical flow message if available, internal gyro otherwise. Internal: always use internal gyro\n", "name": "EKF2_OF_GYR_SRC", "shortDesc": "Optical flow angular rate compensation source", "type": "Int32", "values": [{"description": "Auto", "value": 0}, {"description": "Internal", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.5, "group": "EKF2", "longDesc": "Measurement noise for the optical flow sensor when it's reported quality metric is at the minimum\n", "min": 0.05, "name": "EKF2_OF_N_MAX", "shortDesc": "Optical flow maximum noise", "type": "Float", "units": "rad/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.15, "group": "EKF2", "longDesc": "Measurement noise for the optical flow sensor when it's reported quality metric is at the maximum\n", "min": 0.05, "name": "EKF2_OF_N_MIN", "shortDesc": "Optical flow minimum noise", "type": "Float", "units": "rad/s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "EKF2", "longDesc": "Forward axis with origin relative to vehicle centre of gravity\n", "name": "EKF2_OF_POS_X", "shortDesc": "X position of optical flow focal point in body frame", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "EKF2", "longDesc": "Forward axis with origin relative to vehicle centre of gravity\n", "name": "EKF2_OF_POS_Y", "shortDesc": "Y position of optical flow focal point in body frame", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "EKF2", "longDesc": "Forward axis with origin relative to vehicle centre of gravity\n", "name": "EKF2_OF_POS_Z", "shortDesc": "Z position of optical flow focal point in body frame", "type": "Float", "units": "m"}, {"category": "Standard", "default": 1, "group": "EKF2", "longDesc": "Optical Flow data will only be used in air if the sensor reports a quality metric >= EKF2_OF_QMIN\n", "max": 255, "min": 0, "name": "EKF2_OF_QMIN", "shortDesc": "In air optical flow minimum quality", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Optical Flow data will only be used on the ground if the sensor reports a quality metric >= EKF2_OF_QMIN_GND\n", "max": 255, "min": 0, "name": "EKF2_OF_QMIN_GND", "shortDesc": "On ground optical flow minimum quality", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "EKF2", "longDesc": "This is the ratio of static pressure error to dynamic pressure generated by a negative wind relative velocity along the X body axis. If the baro height estimate rises during backwards flight, then this will be a negative number.\n", "max": 0.5, "min": -0.5, "name": "EKF2_PCOEF_XN", "shortDesc": "Static pressure position error coefficient for the negative X axis", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "EKF2", "longDesc": "This is the ratio of static pressure error to dynamic pressure generated by a positive wind relative velocity along the X body axis. If the baro height estimate rises during forward flight, then this will be a negative number.\n", "max": 0.5, "min": -0.5, "name": "EKF2_PCOEF_XP", "shortDesc": "Static pressure position error coefficient for the positive X axis", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "EKF2", "longDesc": "This is the ratio of static pressure error to dynamic pressure generated by a wind relative velocity along the negative Y (LH) body axis. If the baro height estimate rises during sideways flight to the left, then this will be a negative number.\n", "max": 0.5, "min": -0.5, "name": "EKF2_PCOEF_YN", "shortDesc": "Pressure position error coefficient for the negative Y axis", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "EKF2", "longDesc": "This is the ratio of static pressure error to dynamic pressure generated by a wind relative velocity along the positive Y (RH) body axis. If the baro height estimate rises during sideways flight to the right, then this will be a negative number.\n", "max": 0.5, "min": -0.5, "name": "EKF2_PCOEF_YP", "shortDesc": "Pressure position error coefficient for the positive Y axis", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "EKF2", "longDesc": "This is the ratio of static pressure error to dynamic pressure generated by a wind relative velocity along the Z body axis.\n", "max": 0.5, "min": -0.5, "name": "EKF2_PCOEF_Z", "shortDesc": "Static pressure position error coefficient for the Z axis", "type": "Float"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "When enabled, constant position fusion is enabled when the vehicle is landeded if position has been initialized but has currently no vel/pos aiding.\n", "name": "EKF2_POS_LOCK", "shortDesc": "Enable constant position fusion while on ground", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 10000, "group": "EKF2", "longDesc": "EKF prediction period in microseconds. This should ideally be an integer multiple of the IMU time delta. Actual filter update will be an integer multiple of IMU update.\n", "max": 20000, "min": 1000, "name": "EKF2_PREDICT_US", "shortDesc": "EKF prediction period", "type": "Int32", "units": "us"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Enable/disable ranging beacon fusion.\n", "name": "EKF2_RNGBC_CTRL", "shortDesc": "Ranging beacon fusion control", "type": "Int32", "values": [{"description": "Disable ranging beacon fusion", "value": 0}, {"description": "Enable ranging beacon fusion", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "EKF2", "max": 1000.0, "min": 0.0, "name": "EKF2_RNGBC_DELAY", "rebootRequired": true, "shortDesc": "Ranging beacon measurement delay relative to IMU measurements", "type": "Float", "units": "ms"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "EKF2", "longDesc": "Sets the number of standard deviations used by the innovation consistency test.\n", "min": 1.0, "name": "EKF2_RNGBC_GATE", "shortDesc": "Gate size for ranging beacon fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "decimalPlaces": 1, "default": 30.0, "group": "EKF2", "longDesc": "Used to lower bound or replace the uncertainty included in the message\n", "max": 500.0, "min": 0.1, "name": "EKF2_RNGBC_NOISE", "shortDesc": "Measurement noise for ranging beacon fusion", "type": "Float", "units": "m"}, {"category": "Standard", "default": 5.0, "group": "EKF2", "longDesc": "If the vehicle absolute altitude exceeds this value then the estimator will not fuse range measurements to estimate its height. This only applies when conditional range aid mode is activated (EKF2_RNG_CTRL = 1).\n", "max": 10.0, "min": 1.0, "name": "EKF2_RNG_A_HMAX", "shortDesc": "Maximum height above ground allowed for conditional range aid mode", "type": "Float", "units": "m"}, {"category": "Standard", "default": 1.0, "group": "EKF2", "longDesc": "If the vehicle horizontal speed exceeds this value then the estimator will not fuse range measurements to estimate its height. This only applies when conditional range aid mode is activated (EKF2_RNG_CTRL = 1).\n", "max": 2.0, "min": 0.1, "name": "EKF2_RNG_A_VMAX", "shortDesc": "Maximum horizontal velocity allowed for conditional range aid mode", "type": "Float", "units": "m/s"}, {"category": "Standard", "default": 1, "group": "EKF2", "longDesc": "WARNING: range finders are less reliable and can have unexpected errors. For accurate height above ground, use MPC_ALT_MODE instead, unless baro errors cause problems at takeoff and landing. Fuses range as an additional height source. Conditional mode only fuses it below EKF2_RNG_A_VMAX speed and EKF2_RNG_A_HMAX height, where rotor wash corrupts the baro; for vertical takeoff and landing with no horizontal flight below EKF2_RNG_A_HMAX.\n", "name": "EKF2_RNG_CTRL", "shortDesc": "Range sensor height aiding", "type": "Int32", "values": [{"description": "Disable range fusion", "value": 0}, {"description": "Enabled (conditional mode)", "value": 1}, {"description": "Enabled", "value": 2}]}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "EKF2", "max": 300.0, "min": 0.0, "name": "EKF2_RNG_DELAY", "rebootRequired": true, "shortDesc": "Range finder measurement delay relative to IMU measurements", "type": "Float", "units": "ms"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "EKF2", "longDesc": "Limit for fog detection. If the range finder measures a distance greater than this value, the measurement is considered to not be blocked by fog or rain. If there's a jump from larger than RNG_FOG to smaller than EKF2_RNG_FOG, the measurement may gets rejected. 0 - disabled\n", "max": 20.0, "min": 0.0, "name": "EKF2_RNG_FOG", "shortDesc": "Maximum distance at which the range finder could detect fog (m)", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "EKF2", "longDesc": "Sets the number of standard deviations used by the innovation consistency test.\n", "min": 1.0, "name": "EKF2_RNG_GATE", "shortDesc": "Gate size for range finder fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "default": 1.0, "group": "EKF2", "longDesc": "To be used, the time derivative of the distance sensor measurements projected on the vertical axis needs to be statistically consistent with the estimated vertical velocity of the drone. Decrease this value to make the filter more robust against range finder faulty data (stuck, reflections, ...). Note: tune the range finder noise parameters (EKF2_RNG_NOISE and EKF2_RNG_SFE) before tuning this gate.\n", "max": 5.0, "min": 0.1, "name": "EKF2_RNG_K_GATE", "shortDesc": "Gate size used for range finder kinematic consistency check", "type": "Float", "units": "SD"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "EKF2", "min": 0.01, "name": "EKF2_RNG_NOISE", "shortDesc": "Measurement noise for range finder fusion", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "EKF2", "max": 0.75, "min": -0.75, "name": "EKF2_RNG_PITCH", "shortDesc": "Range sensor pitch offset", "type": "Float", "units": "rad"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "EKF2", "longDesc": "Forward axis with origin relative to vehicle centre of gravity\n", "name": "EKF2_RNG_POS_X", "shortDesc": "X position of range finder origin in body frame", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "EKF2", "longDesc": "Forward axis with origin relative to vehicle centre of gravity\n", "name": "EKF2_RNG_POS_Y", "shortDesc": "Y position of range finder origin in body frame", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "EKF2", "longDesc": "Forward axis with origin relative to vehicle centre of gravity\n", "name": "EKF2_RNG_POS_Z", "shortDesc": "Z position of range finder origin in body frame", "type": "Float", "units": "m"}, {"category": "Standard", "default": 1.0, "group": "EKF2", "longDesc": "Minimum duration during which the reported range finder signal quality needs to be non-zero in order to be declared valid (s)\n", "max": 5.0, "min": 0.1, "name": "EKF2_RNG_QLTY_T", "shortDesc": "Minimum range validity period", "type": "Float", "units": "s"}, {"category": "Standard", "default": 0.05, "group": "EKF2", "longDesc": "Specifies the increase in range finder noise with range.\n", "max": 0.2, "min": 0.0, "name": "EKF2_RNG_SFE", "shortDesc": "Range finder range dependent noise scaler", "type": "Float", "units": "m/m"}, {"category": "Standard", "default": 0.2, "group": "EKF2", "longDesc": "EKF2 instances have to be better than the selected by at least this amount before their relative score can be reduced.\n", "name": "EKF2_SEL_ERR_RED", "shortDesc": "Selector error reduce threshold", "type": "Float"}, {"category": "Standard", "default": 1.0, "group": "EKF2", "longDesc": "EKF2 selector acceleration error threshold for comparing accelerometers. Acceleration vector differences larger than this will result in accumulated velocity error.\n", "name": "EKF2_SEL_IMU_ACC", "shortDesc": "Selector acceleration threshold", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "default": 15.0, "group": "EKF2", "longDesc": "EKF2 selector maximum accumulated angular error threshold for comparing gyros. Accumulated angular error larger than this will result in the sensor being declared faulty.\n", "name": "EKF2_SEL_IMU_ANG", "shortDesc": "Selector angular threshold", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 7.0, "group": "EKF2", "longDesc": "EKF2 selector angular rate error threshold for comparing gyros. Angular rate vector differences larger than this will result in accumulated angular error.\n", "name": "EKF2_SEL_IMU_RAT", "shortDesc": "Selector angular rate threshold", "type": "Float", "units": "deg/s"}, {"category": "Standard", "default": 2.0, "group": "EKF2", "longDesc": "EKF2 selector maximum accumulated velocity threshold for comparing accelerometers. Accumulated velocity error larger than this will result in the sensor being declared faulty.\n", "name": "EKF2_SEL_IMU_VEL", "shortDesc": "Selector angular threshold", "type": "Float", "units": "m/s"}, {"bitmask": [{"description": "GNSS 0", "index": 0}, {"description": "GNSS 1", "index": 1}, {"description": "Optical flow", "index": 2}, {"description": "External vision", "index": 3}, {"description": "Aux global position 0", "index": 4}, {"description": "Aux global position 1", "index": 5}, {"description": "Aux global position 2", "index": 6}, {"description": "Aux global position 3", "index": 7}, {"description": "Barometer", "index": 8}, {"description": "Range finder", "index": 9}, {"description": "Magnetometer", "index": 10}, {"description": "Airspeed", "index": 11}, {"description": "Ranging beacon", "index": 12}], "category": "Standard", "default": 8191, "group": "EKF2", "longDesc": "Bitmask to control which sensor fusion sources are enabled. Sources whose bit is cleared will be disabled. Only applied while disarmed. For in-flight changes use the MAVLink command VEHICLE_CMD_ESTIMATOR_SENSOR_ENABLE or the individual CTRL params (e.g. EKF2_GPS_CTRL, EKF2_BARO_CTRL).\n", "max": 8191, "min": 0, "name": "EKF2_SENS_EN", "shortDesc": "Sensor fusion enable bitmask", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Use for vehicles where the measured body Z magnetic field is subject to strong magnetic interference. For magnetic heading fusion the magnetometer Z measurement will be replaced by a synthetic value calculated using the knowledge of the 3D magnetic field vector at the location of the drone. Therefore, this parameter will only have an effect if the global position of the drone is known. For 3D mag fusion the magnetometer Z measurement will simply be ignored instead of fusing the synthetic value.\n", "name": "EKF2_SYNT_MAG_Z", "shortDesc": "Enable synthetic magnetometer Z component measurement", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "EKF2", "longDesc": "Sets the number of standard deviations used by the innovation consistency test.\n", "min": 1.0, "name": "EKF2_TAS_GATE", "shortDesc": "Gate size for TAS fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.25, "group": "EKF2", "longDesc": "Controls how tightly the output track the EKF states\n", "max": 1.0, "min": 0.1, "name": "EKF2_TAU_POS", "shortDesc": "Output predictor position time constant", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.25, "group": "EKF2", "max": 1.0, "name": "EKF2_TAU_VEL", "shortDesc": "Time constant of the velocity output prediction and smoothing filter", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.5, "group": "EKF2", "min": 0.0, "name": "EKF2_TERR_GRAD", "shortDesc": "Magnitude of terrain gradient", "type": "Float", "units": "m/m"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "EKF2", "min": 0.5, "name": "EKF2_TERR_NOISE", "shortDesc": "Terrain altitude process noise", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 100.0, "group": "EKF2", "longDesc": "Each axis of the velocity state is constrained to this magnitude. GNSS and external vision velocity samples beyond it are not fused.\n", "max": 299792458.0, "name": "EKF2_VEL_LIM", "shortDesc": "Velocity limit", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "EKF2", "longDesc": "When unaided, the wind estimate uncertainty (1-sigma, in m/s) increases by this amount every second.\n", "max": 1.0, "min": 0.0, "name": "EKF2_WIND_NSD", "shortDesc": "Process noise spectral density for wind velocity prediction", "type": "Float", "units": "m/s^2/sqrt(Hz)"}, {"category": "Standard", "decimalPlaces": 1, "default": 90.0, "group": "ESC", "increment": 1.0, "longDesc": "Warning only, no failsafe or arming blocked.\n-1 disables the check.\n", "max": 150.0, "min": -1.0, "name": "ESC_TEMP_WARN_TH", "shortDesc": "ESC temperature warning threshold", "type": "Float", "units": "celcius"}, {"category": "Standard", "default": 0, "group": "Events", "longDesc": "Enable/disable event task for RC Loss. When enabled, an alarm tune will be\nplayed via buzzer or ESCs, if supported. The alarm will sound after a disarm,\nif the vehicle was previously armed and only if the vehicle had RC signal at\nsome point. Particularly useful for locating crashed drones without a GPS\nsensor.\n", "name": "EV_TSK_RC_LOSS", "rebootRequired": true, "shortDesc": "RC Loss Alarm", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Events", "longDesc": "Enable/disable event task for displaying the vehicle status using arm-mounted\nLEDs. When enabled and if the vehicle supports it, LEDs will flash\nindicating various vehicle status changes. Currently PX4 has not implemented\nany specific status events.\n", "name": "EV_TSK_STAT_DIS", "rebootRequired": true, "shortDesc": "Status Display", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 30.0, "group": "FW Attitude Control", "increment": 0.5, "longDesc": "Pitch angle commanded by full stick deflection, relative to FW_PSP_OFF (the centred-stick pitch).\nThe resulting pitch setpoint is additionally limited to this angle around level,\nso with a non-zero FW_PSP_OFF the range is not symmetric.\nApplies in all manual modes with attitude stabilization but without altitude control.\n", "max": 90.0, "min": 0.0, "name": "FW_MAN_P_MAX", "shortDesc": "Maximum manual pitch angle", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 1, "default": 45.0, "group": "FW Attitude Control", "increment": 0.5, "longDesc": "Applies to both directions in all manual modes with attitude stabilization\n", "max": 90.0, "min": 0.0, "name": "FW_MAN_R_MAX", "shortDesc": "Maximum manual roll angle", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 1, "default": 30.0, "group": "FW Attitude Control", "increment": 0.5, "longDesc": "This is the maximally added yaw rate setpoint from the yaw stick in any attitude controlled flight mode.\nIt is added to the yaw rate setpoint generated by the controller for turn coordination.\n", "min": 0.0, "name": "FW_MAN_YR_MAX", "shortDesc": "Maximum manually added yaw rate", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "FW Attitude Control", "increment": 0.5, "longDesc": "Pitch angle of the body x-axis above the horizon in level flight at trim airspeed (FW_AIRSPD_TRIM).\n\nThe altitude and airspeed controller (TECS) uses it as the pitch at zero climb angle,\nand in Stabilized mode the centred pitch stick commands it.\nPitch setpoints and pitch limits set elsewhere, for example FW_P_LIM_MIN and FW_P_LIM_MAX,\nare absolute and do not include it.\n", "max": 90.0, "min": -90.0, "name": "FW_PSP_OFF", "shortDesc": "Pitch setpoint offset (pitch at level flight)", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 1, "default": 60.0, "group": "FW Attitude Control", "increment": 0.5, "max": 180.0, "min": 0.0, "name": "FW_P_RMAX_NEG", "shortDesc": "Maximum negative / down pitch rate setpoint", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 60.0, "group": "FW Attitude Control", "increment": 0.5, "max": 180.0, "min": 0.0, "name": "FW_P_RMAX_POS", "shortDesc": "Maximum positive / up pitch rate setpoint", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.4, "group": "FW Attitude Control", "increment": 0.05, "longDesc": "This defines the latency between a pitch step input and the achieved setpoint\n(inverse to a P gain). Smaller systems may require smaller values.\n", "max": 1.0, "min": 0.2, "name": "FW_P_TC", "shortDesc": "Attitude pitch time constant", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 70.0, "group": "FW Attitude Control", "increment": 0.5, "max": 180.0, "min": 0.0, "name": "FW_R_RMAX", "shortDesc": "Maximum roll rate setpoint", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.4, "group": "FW Attitude Control", "increment": 0.05, "longDesc": "This defines the latency between a roll step input and the achieved setpoint\n(inverse to a P gain). Smaller systems may require smaller values.\n", "max": 1.0, "min": 0.2, "name": "FW_R_TC", "shortDesc": "Attitude Roll Time Constant", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.2, "group": "FW Attitude Control", "increment": 0.05, "max": 10.0, "min": 0.0, "name": "FW_WR_FF", "shortDesc": "Wheel steering rate feed forward", "type": "Float", "units": "%/rad/s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.1, "group": "FW Attitude Control", "increment": 0.005, "longDesc": "This gain defines how much control response will result out of a steady\nstate error. It trims any constant error.\n", "max": 10.0, "min": 0.0, "name": "FW_WR_I", "shortDesc": "Wheel steering rate integrator gain", "type": "Float", "units": "%/rad"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.4, "group": "FW Attitude Control", "increment": 0.05, "max": 1.0, "min": 0.0, "name": "FW_WR_IMAX", "shortDesc": "Wheel steering rate integrator limit", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.5, "group": "FW Attitude Control", "increment": 0.005, "longDesc": "This defines how much the wheel steering input will be commanded depending on the\ncurrent body angular rate error.\n", "max": 10.0, "min": 0.0, "name": "FW_WR_P", "shortDesc": "Wheel steering rate proportional gain", "type": "Float", "units": "%/rad/s"}, {"category": "Standard", "default": 0, "group": "FW Attitude Control", "longDesc": "Only enabled during automatic runway takeoff and landing.\nIn all manual modes the wheel is directly controlled with yaw stick.\n", "name": "FW_W_EN", "shortDesc": "Enable wheel steering controller", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 30.0, "group": "FW Attitude Control", "increment": 0.5, "longDesc": "This limits the maximum wheel steering rate the controller will output (in degrees per\nsecond).\n", "max": 90.0, "min": 0.0, "name": "FW_W_RMAX", "shortDesc": "Maximum wheel steering rate", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 50.0, "group": "FW Attitude Control", "increment": 0.5, "max": 180.0, "min": 0.0, "name": "FW_Y_RMAX", "shortDesc": "Maximum yaw rate setpoint", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "FW Auto Landing", "increment": 0.01, "longDesc": "Sets a fraction of full flaps during landing.\nAlso applies to flaperons if enabled in the mixer/allocation.\n", "max": 1.0, "min": 0.0, "name": "FW_FLAPS_LND_SCL", "shortDesc": "Flaps setting during landing", "type": "Float", "units": "norm"}, {"bitmask": [{"description": "Abort if terrain is not found (only applies to mission landings)", "index": 0}, {"description": "Abort if terrain times out (after a first successful measurement)", "index": 1}], "category": "Standard", "default": 3, "group": "FW Auto Landing", "longDesc": "Terrain estimation:\nbit 0: Abort if terrain is not found\nbit 1: Abort if terrain times out (after a first successful measurement)\n\nThe last estimate is always used as ground, whether the last valid measurement or the land waypoint, depending on the\nselected abort criteria, until an abort condition is entered. If FW_LND_USETER == 0, these bits are ignored.\n\nTODO: Extend automatic abort conditions\ne.g. glide slope tracking error (horizontal and vertical)\n", "max": 3, "min": 0, "name": "FW_LND_ABORT", "shortDesc": "Bit mask to set the automatic landing abort conditions", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 1, "default": -1.0, "group": "FW Auto Landing", "increment": 0.1, "longDesc": "The calibrated airspeed setpoint during landing.\n\nIf set <= 0, landing airspeed = FW_AIRSPD_MIN by default.\n", "min": -1.0, "name": "FW_LND_AIRSPD", "shortDesc": "Landing airspeed", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "FW Auto Landing", "increment": 0.5, "longDesc": "Typically the desired landing slope angle when landing configuration (flaps, airspeed) is enabled.\nSet this value within the vehicle's performance limits.\n", "max": 45.0, "min": 1.0, "name": "FW_LND_ANG", "shortDesc": "Maximum landing slope angle", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 0, "group": "FW Auto Landing", "longDesc": "Allows to deploy the landing configuration (flaps, landing airspeed, etc.) already in\nthe loiter-down waypoint before the final approach.\nOtherwise is enabled only in the final approach.\n", "name": "FW_LND_EARLYCFG", "shortDesc": "Early landing configuration deployment", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 0.5, "group": "FW Auto Landing", "increment": 0.5, "longDesc": "NOTE: max(FW_LND_FLALT, FW_LND_FL_TIME * |z-velocity|) is taken as the flare altitude\n\nSet FW_LND_FLALT or FW_LND_FL_TIME to -1 to disable the flare (land on the glide slope at landing airspeed).\n", "min": -1.0, "name": "FW_LND_FLALT", "shortDesc": "Landing flare altitude (relative to landing altitude)", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 15.0, "group": "FW Auto Landing", "increment": 0.5, "longDesc": "Maximum pitch during landing flare.\n", "max": 45.0, "min": 0.0, "name": "FW_LND_FL_PMAX", "shortDesc": "Flare, maximum absolute pitch", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 1, "default": 2.5, "group": "FW Auto Landing", "increment": 0.5, "longDesc": "Minimum pitch during landing flare.\n", "max": 15.0, "min": -5.0, "name": "FW_LND_FL_PMIN", "shortDesc": "Flare, minimum absolute pitch", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.25, "group": "FW Auto Landing", "increment": 0.1, "longDesc": "TECS will attempt to control the aircraft to this sink rate via pitch angle (throttle killed during flare)\n", "max": 2.0, "min": 0.0, "name": "FW_LND_FL_SINK", "shortDesc": "Landing flare sink rate", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.0, "group": "FW Auto Landing", "increment": 0.1, "longDesc": "Multiplied by the descent rate to calculate a dynamic altitude at which\nto trigger the flare.\n\nNOTE: max(FW_LND_FLALT, FW_LND_FL_TIME * descent rate) is taken as the flare altitude\n\nSet FW_LND_FLALT or FW_LND_FL_TIME to -1 to disable the flare (land on the glide slope at landing airspeed).\n", "max": 5.0, "min": -1.0, "name": "FW_LND_FL_TIME", "shortDesc": "Landing flare time", "type": "Float", "units": "s"}, {"category": "Standard", "default": 2, "group": "FW Auto Landing", "longDesc": "Approach angle nudging: shifts the touchdown point laterally while keeping the approach entrance point constant\nApproach path nudging: shifts the touchdown point laterally along with the entire approach path\n\nThis is useful for manually adjusting the landing point in real time when map or GNSS errors cause an offset from the\ndesired landing vector. Nudging is done with yaw stick, constrained to FW_LND_TD_OFF (in meters) and the direction is\nrelative to the vehicle heading (stick deflection to the right = land point moves to the right as seen by the vehicle).\n", "max": 2, "min": 0, "name": "FW_LND_NUDGE", "shortDesc": "Landing touchdown nudging option", "type": "Int32", "values": [{"description": "Disable nudging", "value": 0}, {"description": "Nudge approach angle", "value": 1}, {"description": "Nudge approach path", "value": 2}]}, {"category": "Standard", "decimalPlaces": 1, "default": 20.0, "group": "FW Auto Landing", "increment": 0.5, "longDesc": "Altitude the vehicle descends to and holds for the release. The release happens\nhigher if the predicted touchdown point reaches the landing point while still on\nthe approach slope, or lower for a vehicle that cannot hold the altitude, but\nnever below 3 seconds of descent at FW_LND_PARA_SINK, so that the canopy has\nroom to open.\n\nLower values reduce the wind drift of the touchdown point.\n", "min": 1.0, "name": "FW_LND_PARA_ALT", "shortDesc": "Parachute landing release altitude above ground", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "FW Auto Landing", "longDesc": "If enabled, the vehicle follows the mission landing approach down to the release\naltitude (FW_LND_PARA_ALT) and releases the parachute by triggering flight\ntermination, such that the predicted touchdown point under canopy lies on the\nlanding point, accounting for ground speed, estimated wind drift during the descent\n(FW_LND_PARA_SINK) and the forward carry while the parachute deploys.\n\nThe parachute is released through the flight termination failsafe outputs, or an\nexternal parachute system (COM_PARACHUTE). Not supported on VTOL.\n", "name": "FW_LND_PARA_EN", "shortDesc": "Enable parachute landing on mission landing approach", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "FW Auto Landing", "increment": 0.1, "longDesc": "Expected steady-state sink rate under canopy. Used to predict the descent duration and\ntherewith the wind drift of the touchdown point.\n", "min": 0.1, "name": "FW_LND_PARA_SINK", "shortDesc": "Sink rate under the deployed parachute", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "FW Auto Landing", "increment": 1.0, "max": 10.0, "min": 0.0, "name": "FW_LND_TD_OFF", "shortDesc": "Maximum lateral position offset for the touchdown point", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": -1.0, "group": "FW Auto Landing", "increment": 0.1, "longDesc": "This is the time after the start of flaring that we expect the vehicle to touch the runway.\nAt this time, a 0.5s clamp down ramp will engage, constraining the pitch setpoint to RWTO_PSP.\nIf enabled, ensure that RWTO_PSP is configured appropriately for full gear contact on ground roll.\n\nSet to -1.0 to disable touchdown clamping. E.g. it may not be desirable to clamp on belly landings.\n\nThe touchdown time will be constrained to be greater than or equal to the flare time (FW_LND_FL_TIME).\n", "max": 5.0, "min": -1.0, "name": "FW_LND_TD_TIME", "shortDesc": "Landing touchdown time (since flare start)", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.0, "group": "FW Auto Landing", "increment": 0.1, "longDesc": "The TECS altitude time constant (FW_T_ALT_TC) is multiplied by this value.\n", "max": 1.0, "min": 0.2, "name": "FW_LND_THRTC_SC", "shortDesc": "Altitude time constant factor for landing and low-height flight", "type": "Float"}, {"category": "Standard", "default": 1, "group": "FW Auto Landing", "longDesc": "This is critical for detecting when to flare, and should be enabled if possible.\n\nIf enabled and no measurement is found within a given timeout, the landing waypoint altitude will be used OR the landing\nwill be aborted, depending on the criteria set in FW_LND_ABORT.\n\nIf disabled, FW_LND_ABORT terrain based criteria are ignored.\n", "max": 2, "min": 0, "name": "FW_LND_USETER", "shortDesc": "Use terrain estimation during landing", "type": "Int32", "values": [{"description": "Disable the terrain estimate", "value": 0}, {"description": "Use the terrain estimate to trigger the flare (only)", "value": 1}, {"description": "Calculate landing glide slope relative to the terrain estimate", "value": 2}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "FW Auto Landing", "increment": 0.01, "max": 1.0, "min": 0.0, "name": "FW_SPOILERS_LND", "shortDesc": "Spoiler landing setting", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "FW Auto Takeoff", "increment": 0.01, "longDesc": "Sets a fraction of full flaps during take-off.\nAlso applies to flaperons if enabled in the mixer/allocation.\n", "max": 1.0, "min": 0.0, "name": "FW_FLAPS_TO_SCL", "shortDesc": "Flaps setting during take-off", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.05, "group": "FW Auto Takeoff", "increment": 0.05, "longDesc": "Launch is detected when the norm of body acceleration is above FW_LAUN_AC_THLD for FW_LAUN_AC_T seconds.\n", "max": 5.0, "min": 0.0, "name": "FW_LAUN_AC_T", "shortDesc": "Trigger time", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 30.0, "group": "FW Auto Takeoff", "increment": 0.5, "longDesc": "Launch is detected when the norm of body acceleration is above FW_LAUN_AC_THLD for FW_LAUN_AC_T seconds.\n", "min": 0.0, "name": "FW_LAUN_AC_THLD", "shortDesc": "Trigger acceleration threshold", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "FW Auto Takeoff", "increment": 1.0, "longDesc": "Height above the launch point below which the vehicle holds the wind-compensated launch bearing\ninstead of the normal line-following guidance, and the roll limit is ramped linearly from 0 at\nthe launch point up to FW_R_LIM at this altitude, so that a poor heading estimate or a bad launch\ncannot induce a large bank close to the ground. Only relevant for hand- or catapult-launched\nvehicles (FW_LAUN_DETCN_ON).\n", "min": 0.0, "name": "FW_LAUN_CLR_ALT", "shortDesc": "Launch climbout clearance altitude", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "FW Auto Takeoff", "increment": 0.1, "longDesc": "Locks control surfaces during pre-launch (armed) and until this time since launch has passed.\nOnly affects control surfaces that have corresponding flag set, and not active for runway takeoff.\nSet to 0 to disable any surface locking after arming.\n", "min": 0.0, "name": "FW_LAUN_CS_LK_DY", "shortDesc": "Control surface launch delay", "type": "Float", "units": "s"}, {"category": "Standard", "default": 0, "group": "FW Auto Takeoff", "longDesc": "Enables automatic launch detection based on measured acceleration. Use for hand- or catapult-launched vehicles.\nNot compatible with runway takeoff.\n", "name": "FW_LAUN_DETCN_ON", "shortDesc": "Fixed-wing launch detection", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "FW Auto Takeoff", "increment": 0.5, "longDesc": "Start the motor(s) this amount of seconds after launch is detected.\n", "max": 10.0, "min": 0.0, "name": "FW_LAUN_MOT_DEL", "shortDesc": "Motor delay", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": -1.0, "group": "FW Auto Takeoff", "increment": 0.1, "longDesc": "The calibrated airspeed setpoint during the takeoff climbout.\n\nIf set <= 0, FW_AIRSPD_MIN will be set by default.\n", "min": -1.0, "name": "FW_TKO_AIRSPD", "shortDesc": "Takeoff Airspeed", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "FW Auto Takeoff", "increment": 1.0, "longDesc": "Ends the takeoff climbout this many seconds after the vehicle started climbing, instead of\nwhen the takeoff altitude is reached.\n\nIf set to 0, the climbout ends at the takeoff altitude.\n", "min": 0.0, "name": "FW_TKO_CLMB_T", "shortDesc": "Takeoff climbout duration", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 10.0, "group": "FW Auto Takeoff", "increment": 0.5, "max": 80.0, "min": -5.0, "name": "FW_TKO_PITCH_MIN", "shortDesc": "Minimum absolute pitch during takeoff", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 30, "group": "FW General", "longDesc": "The time the system should do open loop loiter and wait for GPS recovery\nbefore it starts descending. Set to 0 to disable. Roll angle is set to FW_GPSF_R.\nDoes only apply for fixed-wing vehicles or VTOLs with NAV_FORCE_VT set to 0.\n", "min": 0, "name": "FW_GPSF_LT", "shortDesc": "GPS failure loiter time", "type": "Int32", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 15.0, "group": "FW General", "increment": 0.5, "longDesc": "Roll angle in GPS failure loiter mode.\n", "max": 60.0, "min": 0.0, "name": "FW_GPSF_R", "shortDesc": "GPS failure fixed roll angle", "type": "Float", "units": "deg"}, {"bitmask": [{"description": "Alternative stick configuration (height rate on throttle stick, airspeed on pitch stick)", "index": 0}, {"description": "Enable airspeed setpoint via sticks in altitude and position flight mode", "index": 1}], "category": "Standard", "default": 2, "group": "FW General", "longDesc": "Applies in manual Position and Altitude flight modes.\n", "max": 3, "min": 0, "name": "FW_POS_STK_CONF", "shortDesc": "Custom stick configuration", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 1, "default": 30.0, "group": "FW General", "increment": 0.5, "longDesc": "Applies in any altitude controlled flight mode.\n", "max": 80.0, "min": 0.0, "name": "FW_P_LIM_MAX", "shortDesc": "Maximum absolute pitch angle setpoint", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 1, "default": -30.0, "group": "FW General", "increment": 0.5, "longDesc": "Applies in any altitude controlled flight mode.\n", "max": 0.0, "min": -60.0, "name": "FW_P_LIM_MIN", "shortDesc": "Minimum absolute pitch angle setpoint", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 1, "default": 50.0, "group": "FW General", "increment": 0.5, "longDesc": "Applies in any altitude controlled flight mode.\n", "max": 75.0, "min": 35.0, "name": "FW_R_LIM", "shortDesc": "Maximum roll angle setpoint", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "FW General", "increment": 0.01, "longDesc": "This is the minimum throttle while on the ground (\"landed\") in auto modes.\n", "max": 1.0, "min": 0.0, "name": "FW_THR_IDLE", "shortDesc": "Idle throttle", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "FW General", "increment": 0.01, "longDesc": "Applies in any altitude controlled flight mode.\nShould be set accordingly to achieve FW_T_CLMB_MAX.\n", "max": 1.0, "min": 0.0, "name": "FW_THR_MAX", "shortDesc": "Throttle limit max", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "FW General", "increment": 0.01, "longDesc": "Applies in any altitude controlled flight mode.\nUsually set to 0 but can be increased to prevent the motor from stopping when\ndescending, which can increase achievable descent rates.\n", "max": 1.0, "min": 0.0, "name": "FW_THR_MIN", "shortDesc": "Throttle limit min", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 2, "default": 3.0, "group": "FW General", "increment": 0.01, "longDesc": "In auto modes: default climb rate output by controller to achieve altitude setpoints.\nIn manual modes: maximum climb rate setpoint.\n", "min": 0.1, "name": "FW_T_CLMB_R_SP", "shortDesc": "Default target climbrate", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 2.0, "group": "FW General", "increment": 0.01, "longDesc": "In auto modes: default sink rate output by controller to achieve altitude setpoints.\nIn manual modes: maximum sink rate setpoint.\n", "min": 0.1, "name": "FW_T_SINK_R_SP", "shortDesc": "Default target sinkrate", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.0, "group": "FW General", "increment": 1.0, "longDesc": "Adjusts the amount of weighting that the pitch control\napplies to speed vs height errors.\n0 -> control height only\n2 -> control speed only (gliders)\nUp to a weight of 1, pitch only trades height for speed up to trim airspeed;\naccelerating above trim is left to the throttle. Between 1 and 2, pitch\nincreasingly tracks airspeed setpoints above trim as well.\n", "max": 2.0, "min": 0.0, "name": "FW_T_SPDWEIGHT", "shortDesc": "Speed <--> Altitude weight", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.5, "group": "FW General", "increment": 1.0, "longDesc": "This is used to constrain a minimum altitude below which we keep wings level to avoid wing tip strike. It's safer\nto give a slight margin here (> 0m)\n", "min": 0.0, "name": "FW_WING_HEIGHT", "shortDesc": "Height (AGL) of the wings when the aircraft is on the ground", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "FW General", "increment": 0.1, "longDesc": "This is used for limiting the roll setpoint near the ground. (if multiple wings, take the longest span)\n", "min": 0.1, "name": "FW_WING_SPAN", "shortDesc": "The aircraft's wing span (length from tip to tip)", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 0, "default": 90.0, "group": "FW Lateral Control", "increment": 1.0, "longDesc": "Maximum change in roll angle setpoint per second.\nApplied in all Auto modes, plus manual Position & Altitude modes.\n", "min": 0.0, "name": "FW_PN_R_SLEW_MAX", "shortDesc": "Path navigation roll slew rate limit", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "FW Longitudinal Control", "increment": 0.5, "longDesc": "The controller will increase the commanded airspeed to maintain\nthis minimum groundspeed to the next waypoint.\n", "max": 40.0, "min": 0.0, "name": "FW_GND_SPD_MIN", "shortDesc": "Minimum groundspeed", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "FW Longitudinal Control", "increment": 0.01, "longDesc": "Maximum slew rate for the commanded throttle\n", "max": 1.0, "min": 0.0, "name": "FW_THR_SLEW_MAX", "shortDesc": "Throttle max slew rate", "type": "Float", "units": "1/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 5.0, "group": "FW Longitudinal Control", "increment": 0.5, "min": 2.0, "name": "FW_T_ALT_TC", "shortDesc": "Altitude error time constant", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 0, "default": -1.0, "group": "FW Longitudinal Control", "longDesc": "Minimum altitude error needed to descend with max airspeed and minimal throttle.\nA negative value disables fast descend.\n", "min": -1.0, "name": "FW_T_F_ALT_ERR", "shortDesc": "Fast descend: minimum altitude error", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.5, "group": "FW Longitudinal Control", "increment": 0.05, "max": 1.0, "min": 0.0, "name": "FW_T_HRATE_FF", "shortDesc": "Height rate feed forward", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "FW Longitudinal Control", "increment": 0.05, "longDesc": "Increase it to trim out speed and height offsets faster,\nwith the downside of possible overshoots and oscillations.\n", "max": 2.0, "min": 0.0, "name": "FW_T_I_GAIN_PIT", "shortDesc": "Integrator gain pitch", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "FW Longitudinal Control", "increment": 0.1, "max": 2.0, "min": 0.0, "name": "FW_T_PTCH_DAMP", "shortDesc": "Pitch damping gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 15.0, "group": "FW Longitudinal Control", "increment": 0.5, "longDesc": "Is used to compensate for the additional drag created by turning.\nIncrease this gain if the aircraft initially loses energy in turns\nand reduce if the aircraft initially gains energy in turns.\n", "max": 20.0, "min": 0.0, "name": "FW_T_RLL2THR", "shortDesc": "Roll -> Throttle feedforward", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "FW Longitudinal Control", "increment": 0.01, "max": 3.0, "min": 0.5, "name": "FW_T_SEB_R_FF", "shortDesc": "Specific total energy balance rate feedforward gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "FW Longitudinal Control", "increment": 0.5, "max": 15.0, "min": 1.0, "name": "FW_T_SINK_MAX", "shortDesc": "Maximum descent rate", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.4, "group": "FW Longitudinal Control", "increment": 0.01, "longDesc": "This filter is applied to the specific total energy rate used for throttle damping.\n", "max": 2.0, "min": 0.0, "name": "FW_T_STE_R_TC", "shortDesc": "Specific total energy rate first order filter time constant", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 5.0, "group": "FW Longitudinal Control", "increment": 0.5, "min": 2.0, "name": "FW_T_TAS_TC", "shortDesc": "True airspeed error time constant", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "FW Longitudinal Control", "increment": 0.01, "longDesc": "This is the damping gain for the throttle demand loop.\n", "max": 1.0, "min": 0.0, "name": "FW_T_THR_DAMPING", "shortDesc": "Throttle damping factor", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.02, "group": "FW Longitudinal Control", "increment": 0.005, "longDesc": "Increase it to trim out speed and height offsets faster,\nwith the downside of possible overshoots and oscillations.\n", "max": 1.0, "min": 0.0, "name": "FW_T_THR_INTEG", "shortDesc": "Integrator gain throttle", "type": "Float"}, {"category": "Standard", "decimalPlaces": 0, "default": -1.0, "group": "FW Longitudinal Control", "increment": 1.0, "longDesc": "Height above ground threshold below which tighter altitude\ntracking gets enabled (see FW_LND_THRTC_SC). Below this height, TECS smoothly\n(1 sec / sec) transitions the altitude tracking time constant from FW_T_ALT_TC\nto FW_LND_THRTC_SC*FW_T_ALT_TC.\n\n-1 to disable.\n", "min": -1.0, "name": "FW_T_THR_LOW_HGT", "shortDesc": "Low-height threshold for tighter altitude tracking", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 7.0, "group": "FW Longitudinal Control", "increment": 0.5, "longDesc": "This is the maximum vertical acceleration\neither up or down that the controller will use to correct speed\nor height errors.\n", "max": 10.0, "min": 1.0, "name": "FW_T_VERT_ACC", "shortDesc": "Maximum vertical acceleration", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "FW Longitudinal Control", "increment": 0.01, "longDesc": "Multiplying this factor with the current absolute wind estimate gives the airspeed offset\nadded to the minimum airspeed setpoint limit. This helps to make the\nsystem more robust against disturbances (turbulence) in high wind.\n", "min": 0.0, "name": "FW_WIND_ARSP_SC", "shortDesc": "Wind-based airspeed scaling factor", "type": "Float"}, {"category": "Standard", "decimalPlaces": 0, "default": -1.0, "group": "FW NPFG Control", "increment": 1.0, "longDesc": "If a horizontal position reset larger than this occurs while flying between two\nwaypoints, fly directly to the current waypoint instead of rejoining the line.\n-1 to disable.\n", "max": 10000.0, "min": -1.0, "name": "FW_WP_RST_DIST", "shortDesc": "Max position reset distance", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.7, "group": "FW NPFG Control", "increment": 0.01, "longDesc": "Damping ratio of NPFG control law.\n", "max": 1.0, "min": 0.1, "name": "NPFG_DAMPING", "shortDesc": "NPFG damping ratio", "type": "Float"}, {"category": "Standard", "default": 1, "group": "FW NPFG Control", "longDesc": "Avoids limit cycling from a too aggressively tuned period/damping combination.\nIf false, also disables upper bound NPFG_PERIOD_UB.\n", "name": "NPFG_LB_PERIOD", "shortDesc": "Enable automatic lower bound on the NPFG period", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 10.0, "group": "FW NPFG Control", "increment": 0.1, "longDesc": "Period of NPFG control law.\n", "max": 100.0, "min": 1.0, "name": "NPFG_PERIOD", "shortDesc": "NPFG period", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.5, "group": "FW NPFG Control", "increment": 0.1, "longDesc": "Multiplied by period for conservative minimum period bounding (when period lower\nbounding is enabled). 1.0 bounds at marginal stability.\n", "max": 10.0, "min": 1.0, "name": "NPFG_PERIOD_SF", "shortDesc": "Period safety factor", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.5, "group": "FW NPFG Control", "increment": 0.05, "longDesc": "Time constant of roll controller command / response, modeled as first order delay.\nUsed to determine lower period bound. Setting zero disables automatic period bounding.\n", "max": 2.0, "min": 0.0, "name": "NPFG_ROLL_TC", "shortDesc": "Roll time constant", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.32, "group": "FW NPFG Control", "increment": 0.01, "longDesc": "Multiplied by the track error boundary to determine when the aircraft switches\nto the next waypoint and/or path segment. Should be less than 1.\n", "max": 1.0, "min": 0.1, "name": "NPFG_SW_DST_MLT", "shortDesc": "NPFG switch distance multiplier", "type": "Float"}, {"category": "Standard", "default": 1, "group": "FW NPFG Control", "longDesc": "Adapts period to maintain track keeping in variable winds and path curvature.\n", "name": "NPFG_UB_PERIOD", "shortDesc": "Enable automatic upper bound on the NPFG period", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "FW Performance", "increment": 0.01, "longDesc": "Factor applied to the minimum and stall airspeed when flaps are fully deployed.\n", "max": 1.0, "min": 0.5, "name": "FW_AIRSPD_FLP_SC", "shortDesc": "Airspeed scale with full flaps", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 20.0, "group": "FW Performance", "increment": 0.5, "longDesc": "The maximal airspeed (calibrated airspeed) the user is able to command.\n", "min": 0.5, "name": "FW_AIRSPD_MAX", "shortDesc": "Maximum Airspeed (CAS)", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 10.0, "group": "FW Performance", "increment": 0.5, "longDesc": "The minimal airspeed (calibrated airspeed) the user is able to command.\nFurther, if the airspeed falls below this value, the TECS controller will try to\nincrease airspeed more aggressively.\nHas to be set according to the vehicle's stall speed (which should be set in FW_AIRSPD_STALL),\nwith some margin between the stall speed and minimum airspeed.\nThis value corresponds to the desired minimum speed with the default load factor (level flight, default weight),\nand is automatically adpated to the current load factor (calculated from roll setpoint and WEIGHT_GROSS/WEIGHT_BASE).\n", "min": 0.5, "name": "FW_AIRSPD_MIN", "shortDesc": "Minimum Airspeed (CAS)", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 7.0, "group": "FW Performance", "increment": 0.5, "longDesc": "The stall airspeed (calibrated airspeed) of the vehicle.\nIt is used for airspeed sensor failure detection and for the control\nsurface scaling airspeed limits.\n", "min": 0.5, "name": "FW_AIRSPD_STALL", "shortDesc": "Stall Airspeed (CAS)", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 15.0, "group": "FW Performance", "increment": 0.5, "longDesc": "The trim CAS (calibrated airspeed) of the vehicle. If an airspeed controller is active,\nthis is the default airspeed setpoint that the controller will try to achieve.\nThis value corresponds to the trim airspeed with the default load factor (level flight, default weight).\n", "min": 0.5, "name": "FW_AIRSPD_TRIM", "shortDesc": "Trim (Cruise) Airspeed", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 0, "default": -1.0, "group": "FW Performance", "increment": 1.0, "longDesc": "Altitude in standard atmosphere at which the vehicle in normal configuration (WEIGHT_BASE) is still able to achieve a maximum climb rate of\n0.5m/s at maximum throttle (FW_THR_MAX). Used to compensate for air density in FW_T_CLMB_MAX.\nSet negative to disable.\n", "min": -1.0, "name": "FW_SERVICE_CEIL", "shortDesc": "Service ceiling", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "FW Performance", "increment": 0.01, "longDesc": "Required throttle (at sea level, standard atmosphere) for level flight at maximum airspeed FW_AIRSPD_MAX\n\nSet to 0 to disable mapping of airspeed to trim throttle.\n", "max": 1.0, "min": 0.0, "name": "FW_THR_ASPD_MAX", "shortDesc": "Throttle at max airspeed", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "FW Performance", "increment": 0.01, "longDesc": "Required throttle (at sea level, standard atmosphere) for level flight at minimum airspeed FW_AIRSPD_MIN\n\nSet to 0 to disable mapping of airspeed to trim throttle below FW_AIRSPD_TRIM.\n", "max": 1.0, "min": 0.0, "name": "FW_THR_ASPD_MIN", "shortDesc": "Throttle at min airspeed", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.6, "group": "FW Performance", "increment": 0.01, "longDesc": "Required throttle (at sea level, standard atmosphere) for level flight at FW_AIRSPD_TRIM\n", "max": 1.0, "min": 0.0, "name": "FW_THR_TRIM", "shortDesc": "Trim throttle", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "FW Performance", "increment": 0.5, "longDesc": "This is the maximum calibrated climb rate that the aircraft can achieve with\nthe throttle set to FW_THR_MAX and the airspeed set to the\ntrim value. For electric aircraft make sure this number can be\nachieved towards the end of flight when the battery voltage has reduced.\n", "min": 1.0, "name": "FW_T_CLMB_MAX", "shortDesc": "Maximum climb rate", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 2.0, "group": "FW Performance", "increment": 0.5, "longDesc": "This is the minimum calibrated sink rate of the aircraft with the throttle\nset to THR_MIN and flown at the same airspeed as used\nto measure FW_T_CLMB_MAX.\n", "min": 1.0, "name": "FW_T_SINK_MIN", "shortDesc": "Minimum descent rate", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": -1.0, "group": "FW Performance", "increment": 0.5, "longDesc": "This is the weight of the vehicle at which it's performance limits were derived. A zero or negative value\ndisables trim throttle and minimum airspeed compensation based on weight.\n", "name": "WEIGHT_BASE", "shortDesc": "Vehicle base weight", "type": "Float", "units": "kg"}, {"category": "Standard", "decimalPlaces": 1, "default": -1.0, "group": "FW Performance", "increment": 0.1, "longDesc": "If set together with WEIGHT_BASE and WEIGHT_GROSS, the weight used for\nperformance scaling is reduced by the burned fuel reported in the fuel tank status.\nOnly a single fuel tank is supported. A zero or negative value disables fuel-based weight compensation.\n", "name": "WEIGHT_FUEL", "shortDesc": "Mass of a full fuel load", "type": "Float", "units": "kg"}, {"category": "Standard", "decimalPlaces": 1, "default": -1.0, "group": "FW Performance", "increment": 0.1, "longDesc": "This is the actual weight of the vehicle at any time. This value will differ from WEIGHT_BASE in case weight was added\nor removed from the base weight. Examples are the addition of payloads or larger batteries. A zero or negative value\ndisables trim throttle and minimum airspeed compensation based on weight.\nIf fuel-based weight compensation is enabled (WEIGHT_FUEL), set this to the takeoff weight with a full fuel load.\n", "name": "WEIGHT_GROSS", "shortDesc": "Vehicle gross weight", "type": "Float", "units": "kg"}, {"category": "Standard", "default": 90.0, "group": "FW Rate Control", "max": 720.0, "min": 10.0, "name": "FW_ACRO_X_MAX", "shortDesc": "Acro body roll max rate setpoint", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 0, "group": "FW Rate Control", "longDesc": "If this parameter is set to 1, the yaw rate controller is enabled in Fixed-wing Acro mode.\nOtherwise the pilot commands directly the yaw actuator.\nIt is disabled by default because an active yaw rate controller will fight against the\nnatural turn coordination of the plane.\n", "name": "FW_ACRO_YAW_EN", "shortDesc": "Enable yaw rate controller in Acro", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 90.0, "group": "FW Rate Control", "max": 720.0, "min": 10.0, "name": "FW_ACRO_Y_MAX", "shortDesc": "Acro body pitch max rate setpoint", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 45.0, "group": "FW Rate Control", "max": 720.0, "min": 10.0, "name": "FW_ACRO_Z_MAX", "shortDesc": "Acro body yaw max rate setpoint", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 1, "group": "FW Rate Control", "longDesc": "This enables a logic that automatically adjusts the output of the rate controller to take\ninto account the real torque produced by an aerodynamic control surface given\nthe current deviation from the trim airspeed (FW_AIRSPD_TRIM).\n\nEnable when using aerodynamic control surfaces (e.g.: plane)\nDisable when using rotor wings (e.g.: autogyro)\n", "name": "FW_ARSP_SCALE_EN", "shortDesc": "Enable airspeed scaling", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "FW Rate Control", "longDesc": "This compensates for voltage drop of the battery over time by attempting to\nnormalize performance across the operating range of the battery.\n", "name": "FW_BAT_SCALE_EN", "shortDesc": "Enable throttle scale by battery level", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "FW Rate Control", "increment": 0.01, "longDesc": "This increment is added to TRIM_PITCH when airspeed is FW_AIRSPD_MAX.\n", "max": 0.5, "min": -0.5, "name": "FW_DTRIM_P_VMAX", "shortDesc": "Pitch trim increment at maximum airspeed", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "FW Rate Control", "increment": 0.01, "longDesc": "This increment is added to TRIM_PITCH when airspeed is FW_AIRSPD_MIN.\n", "max": 0.5, "min": -0.5, "name": "FW_DTRIM_P_VMIN", "shortDesc": "Pitch trim increment at minimum airspeed", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "FW Rate Control", "increment": 0.01, "longDesc": "This increment is added to TRIM_ROLL when airspeed is FW_AIRSPD_MAX.\n", "max": 0.5, "min": -0.5, "name": "FW_DTRIM_R_VMAX", "shortDesc": "Roll trim increment at maximum airspeed", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "FW Rate Control", "increment": 0.01, "longDesc": "This increment is added to TRIM_ROLL when airspeed is FW_AIRSPD_MIN.\n", "max": 0.5, "min": -0.5, "name": "FW_DTRIM_R_VMIN", "shortDesc": "Roll trim increment at minimum airspeed", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "FW Rate Control", "increment": 0.01, "longDesc": "This increment is added to TRIM_YAW when airspeed is FW_AIRSPD_MAX.\n", "max": 0.5, "min": -0.5, "name": "FW_DTRIM_Y_VMAX", "shortDesc": "Yaw trim increment at maximum airspeed", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "FW Rate Control", "increment": 0.01, "longDesc": "This increment is added to TRIM_YAW when airspeed is FW_AIRSPD_MIN.\n", "max": 0.5, "min": -0.5, "name": "FW_DTRIM_Y_VMIN", "shortDesc": "Yaw trim increment at minimum airspeed", "type": "Float"}, {"category": "Standard", "default": 0, "group": "FW Rate Control", "longDesc": "Chose source for manual setting of flaps in manual flight modes.\n", "name": "FW_FLAPS_MAN", "shortDesc": "Flap input in manual flight", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Aux1", "value": 1}, {"description": "Aux2", "value": 2}, {"description": "Aux3", "value": 3}, {"description": "Aux4", "value": 4}, {"description": "Aux5", "value": 5}, {"description": "Flaps channel", "value": 6}, {"description": "Aux6", "value": 7}]}, {"category": "Standard", "default": 1, "group": "FW Rate Control", "name": "FW_GC_EN", "shortDesc": "Enable rate gain compression", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "FW Rate Control", "increment": 0.01, "longDesc": "The range of the compression gain is between this parameter and 1.0\n", "max": 1.0, "min": 0.0, "name": "FW_GC_GAIN_MIN", "shortDesc": "Compression gain lower limit", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "FW Rate Control", "increment": 0.01, "longDesc": "Scale factor applied to the desired pitch actuator command in full manual mode. This parameter allows\nto adjust the throws of the control surfaces.\n", "min": 0.0, "name": "FW_MAN_P_SC", "shortDesc": "Manual pitch scale", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "FW Rate Control", "increment": 0.01, "longDesc": "Scale factor applied to the desired roll actuator command in full manual mode. This parameter allows\nto adjust the throws of the control surfaces.\n", "max": 1.0, "min": 0.0, "name": "FW_MAN_R_SC", "shortDesc": "Manual roll scale", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "FW Rate Control", "increment": 0.01, "longDesc": "Scale factor applied to the desired yaw actuator command in full manual mode. This parameter allows\nto adjust the throws of the control surfaces.\n", "min": 0.0, "name": "FW_MAN_Y_SC", "shortDesc": "Manual yaw scale", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "FW Rate Control", "increment": 0.005, "longDesc": "Pitch rate differential gain.\n", "max": 10.0, "min": 0.0, "name": "FW_PR_D", "shortDesc": "Pitch rate derivative gain", "type": "Float", "units": "%/rad/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.5, "group": "FW Rate Control", "increment": 0.05, "longDesc": "Direct feed forward from rate setpoint to torque setpoint.\nPositive values compensate aerodynamic damping (scaled linearly with airspeed).\nNegative values reduce setpoint tracking aggressiveness while preserving disturbance rejection (2-DOF controller, scaled quadratically with airspeed)\n\n", "max": 10.0, "min": -10.0, "name": "FW_PR_FF", "shortDesc": "Pitch rate feed forward", "type": "Float", "units": "%/rad/s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.1, "group": "FW Rate Control", "increment": 0.005, "max": 10.0, "min": 0.0, "name": "FW_PR_I", "shortDesc": "Pitch rate integrator gain", "type": "Float", "units": "%/rad"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.4, "group": "FW Rate Control", "increment": 0.05, "max": 1.0, "min": 0.0, "name": "FW_PR_IMAX", "shortDesc": "Pitch rate integrator limit", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.08, "group": "FW Rate Control", "increment": 0.005, "max": 10.0, "min": 0.0, "name": "FW_PR_P", "shortDesc": "Pitch rate proportional gain", "type": "Float", "units": "%/rad/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "FW Rate Control", "increment": 0.01, "longDesc": "This gain can be used to counteract the \"adverse yaw\" effect for fixed wings.\nWhen the plane enters a roll it will tend to yaw the nose out of the turn.\nThis gain enables the use of a yaw actuator to counteract this effect.\n", "min": 0.0, "name": "FW_RLL_TO_YAW_FF", "shortDesc": "Roll control to yaw control feedforward gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "FW Rate Control", "increment": 0.005, "max": 10.0, "min": 0.0, "name": "FW_RR_D", "shortDesc": "Roll rate derivative gain", "type": "Float", "units": "%/rad/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.5, "group": "FW Rate Control", "increment": 0.05, "longDesc": "Direct feed forward from rate setpoint to torque setpoint.\nPositive values compensate aerodynamic damping (scaled linearly with airspeed).\nNegative values reduce setpoint tracking aggressiveness while preserving disturbance rejection (2-DOF controller, scaled quadratically with airspeed)\n\n", "max": 10.0, "min": -10.0, "name": "FW_RR_FF", "shortDesc": "Roll rate feed forward", "type": "Float", "units": "%/rad/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "FW Rate Control", "increment": 0.01, "max": 10.0, "min": 0.0, "name": "FW_RR_I", "shortDesc": "Roll rate integrator gain", "type": "Float", "units": "%/rad"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.2, "group": "FW Rate Control", "increment": 0.05, "max": 1.0, "min": 0.0, "name": "FW_RR_IMAX", "shortDesc": "Roll integrator limit", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "FW Rate Control", "increment": 0.005, "max": 10.0, "min": 0.0, "name": "FW_RR_P", "shortDesc": "Roll rate proportional gain", "type": "Float", "units": "%/rad/s"}, {"category": "Standard", "default": 0, "group": "FW Rate Control", "longDesc": "Chose source for manual setting of spoilers in manual flight modes.\n", "name": "FW_SPOILERS_MAN", "shortDesc": "Spoiler input in manual flight", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Flaps channel", "value": 1}, {"description": "Aux1", "value": 2}, {"description": "Aux2", "value": 3}, {"description": "Aux3", "value": 4}, {"description": "Aux4", "value": 5}, {"description": "Aux5", "value": 6}, {"description": "Aux6", "value": 7}]}, {"category": "Standard", "default": 1, "group": "FW Rate Control", "longDesc": "If set to 1, the airspeed measurement data, if valid, is used in the following controllers:\n- Rate controller: output scaling\n- Attitude controller: coordinated turn controller\n- Position controller: airspeed setpoint tracking, takeoff logic\n- VTOL: transition logic\n", "name": "FW_USE_AIRSPD", "shortDesc": "Use airspeed for control", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "FW Rate Control", "increment": 0.005, "max": 10.0, "min": 0.0, "name": "FW_YR_D", "shortDesc": "Yaw rate derivative gain", "type": "Float", "units": "%/rad/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "FW Rate Control", "increment": 0.05, "longDesc": "Direct feed forward from rate setpoint to torque setpoint.\nPositive values compensate aerodynamic damping (scaled linearly with airspeed).\nNegative values reduce setpoint tracking aggressiveness while preserving disturbance rejection (2-DOF controller, scaled quadratically with airspeed)\n\n", "max": 10.0, "min": -10.0, "name": "FW_YR_FF", "shortDesc": "Yaw rate feed forward", "type": "Float", "units": "%/rad/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.1, "group": "FW Rate Control", "increment": 0.5, "max": 10.0, "min": 0.0, "name": "FW_YR_I", "shortDesc": "Yaw rate integrator gain", "type": "Float", "units": "%/rad"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.2, "group": "FW Rate Control", "increment": 0.05, "max": 1.0, "min": 0.0, "name": "FW_YR_IMAX", "shortDesc": "Yaw rate integrator limit", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "FW Rate Control", "increment": 0.005, "max": 10.0, "min": 0.0, "name": "FW_YR_P", "shortDesc": "Yaw rate proportional gain", "type": "Float", "units": "%/rad/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "Failure Detector", "increment": 0.5, "longDesc": "Maximum altitude loss allowed before the vehicle terminates and deploys the parachute. Set to 0 to disable.\n", "max": 200.0, "min": 0.0, "name": "FD_ALT_LOSS", "shortDesc": "Altitude loss threshold for termination and parachute deployment", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Failure Detector", "longDesc": "Seconds that the altitude loss threshold must be exceeded before the failure is declared.\n", "max": 5.0, "min": 0.02, "name": "FD_ALT_LOSS_T", "shortDesc": "Altitude loss failure trigger time", "type": "Float", "units": "s"}, {"category": "Standard", "default": 0, "group": "Failure Detector", "longDesc": "Enable PWM input on for engaging failsafe from an external automatic trigger system (ATS)\n\nEnabled on either AUX5 or MAIN5 depending on board.\nExternal ATS is required by ASTM F3322-18.\n", "name": "FD_EXT_ATS_EN", "rebootRequired": true, "shortDesc": "Enable PWM input from external ATS for failsafe", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 1900, "group": "Failure Detector", "longDesc": "The PWM threshold from external automatic trigger system for engaging failsafe\n\nExternal ATS is required by ASTM F3322-18.\n", "name": "FD_EXT_ATS_TRIG", "shortDesc": "External ATS PWM threshold for failsafe", "type": "Int32", "units": "us"}, {"category": "Standard", "default": 60, "group": "Failure Detector", "longDesc": "Maximum pitch angle before FailureDetector triggers the attitude_failure flag.\nThe flag triggers flight termination (if @CBRK_FLIGHTTERM = 0),\nwhich sets outputs to their failsafe values.\nOn takeoff the flag triggers lockdown (irrespective of @CBRK_FLIGHTTERM),\nwhich disarms motors but does not set outputs to failsafe values.\n\nSetting this parameter to 0 disables the check\n", "max": 180, "min": 0, "name": "FD_FAIL_P", "shortDesc": "FailureDetector Max Pitch", "type": "Int32", "units": "deg"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "Failure Detector", "longDesc": "Seconds (decimal) that pitch has to exceed FD_FAIL_P before being considered as a failure.\n", "max": 5.0, "min": 0.02, "name": "FD_FAIL_P_TTRI", "shortDesc": "Pitch failure trigger time", "type": "Float", "units": "s"}, {"category": "Standard", "default": 60, "group": "Failure Detector", "longDesc": "Maximum roll angle before FailureDetector triggers the attitude_failure flag.\nThe flag triggers flight termination (if @CBRK_FLIGHTTERM = 0),\nwhich sets outputs to their failsafe values.\nOn takeoff the flag triggers lockdown (irrespective of @CBRK_FLIGHTTERM),\nwhich disarms motors but does not set outputs to failsafe values.\n\nSetting this parameter to 0 disables the check\n", "max": 180, "min": 0, "name": "FD_FAIL_R", "shortDesc": "FailureDetector Max Roll", "type": "Int32", "units": "deg"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "Failure Detector", "longDesc": "Seconds (decimal) that roll has to exceed FD_FAIL_R before being considered as a failure.\n", "max": 5.0, "min": 0.02, "name": "FD_FAIL_R_TTRI", "shortDesc": "Roll failure trigger time", "type": "Float", "units": "s"}, {"category": "Standard", "default": 30, "group": "Failure Detector", "increment": 1, "longDesc": "Value at which the imbalanced propeller metric (based on horizontal and\nvertical acceleration variance) triggers a failure\n\nSetting this value to 0 disables the feature.\n", "max": 1000, "min": 0, "name": "FD_IMB_PROP_THR", "shortDesc": "Imbalanced propeller check threshold", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "Failure Injection", "longDesc": "If enabled allows Injection of Failures.\n\nWARNING: the failures can easily cause crashes and are to be used with caution!\n", "name": "SYS_FAILURE_EN", "rebootRequired": true, "shortDesc": "Enable failure injection", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.2, "group": "Failure Injection", "longDesc": "Constant offset added to every axis while an accel 'wrong' failure injection is active.\n", "name": "SYS_FAIL_A_BIAS", "shortDesc": "Accel bias failure injection offset", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.005, "group": "Failure Injection", "longDesc": "Rate at which the offset added to every axis grows while an accel 'drift' failure injection is active.\n", "name": "SYS_FAIL_A_DRIFT", "shortDesc": "Accel drift failure injection rate", "type": "Float", "units": "m/s^3"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Failure Injection", "longDesc": "Amplitude of the uniform noise added to every axis while an accel 'garbage' failure injection is active.\n", "min": 0.0, "name": "SYS_FAIL_A_NOISE", "shortDesc": "Accel noise failure injection magnitude", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "default": 3, "group": "Failure Injection", "longDesc": "Battery warning level reported while a battery 'wrong' failure\ninjection is active. The injected remaining charge is set just below\nthe matching threshold (BAT_LOW_THR, BAT_CRIT_THR or\nBAT_EMERGEN_THR).\n", "name": "SYS_FAIL_BAT_LVL", "shortDesc": "Battery failure injection severity", "type": "Int32", "values": [{"description": "Warn", "value": 1}, {"description": "Critical", "value": 2}, {"description": "Emergency", "value": 3}]}, {"category": "Standard", "default": 0, "group": "Failure Injection", "longDesc": "GNSS jamming state reported by the addressed receiver while a GPS 'wrong'\nfailure injection is active. The reported position is left untouched, so\n'Detected' simulates a receiver that still delivers a valid fix while\nreporting interference. Leave at 'Unchanged' to keep the simulated\nreceiver's own jamming state.\n", "name": "SYS_FAIL_GPS_JAM", "shortDesc": "GPS Wrong-failure jamming state", "type": "Int32", "values": [{"description": "Unchanged", "value": 0}, {"description": "OK", "value": 1}, {"description": "Mitigated", "value": 2}, {"description": "Detected", "value": 3}]}, {"category": "Standard", "default": 2, "group": "Failure Injection", "longDesc": "GNSS fix type reported by the addressed receiver while a GPS 'wrong'\nfailure injection is active. The reported position is left untouched.\nThe default 2D fix is rejected by the estimator, which requires a 3D\nfix, and makes the GNSS redundancy check report a lost fix. Values above\n3D fix report a better solution than the receiver really has.\n", "name": "SYS_FAIL_GPS_WRG", "shortDesc": "GPS Wrong-failure fix type", "type": "Int32", "values": [{"description": "Fix: None", "value": 1}, {"description": "Fix: 2D", "value": 2}, {"description": "Fix: 3D", "value": 3}, {"description": "Fix: RTK float", "value": 5}, {"description": "Fix: RTK fixed", "value": 6}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.01, "group": "Failure Injection", "longDesc": "Constant offset added to every axis while a gyro 'wrong' failure injection is active.\n", "name": "SYS_FAIL_G_BIAS", "shortDesc": "Gyro bias failure injection offset", "type": "Float", "units": "rad/s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.001, "group": "Failure Injection", "longDesc": "Rate at which the offset added to every axis grows while a gyro 'drift' failure injection is active.\n", "name": "SYS_FAIL_G_DRIFT", "shortDesc": "Gyro drift failure injection rate", "type": "Float", "units": "rad/s^2"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.05, "group": "Failure Injection", "longDesc": "Amplitude of the uniform noise added to every axis while a gyro 'garbage' failure injection is active.\n", "min": 0.0, "name": "SYS_FAIL_G_NOISE", "shortDesc": "Gyro noise failure injection magnitude", "type": "Float", "units": "rad/s"}, {"bitmask": [{"description": "Instance 1", "index": 0}, {"description": "Instance 2", "index": 1}, {"description": "Instance 3", "index": 2}, {"description": "Instance 4", "index": 3}, {"description": "Instance 5", "index": 4}, {"description": "Instance 6", "index": 5}, {"description": "Instance 7", "index": 6}, {"description": "Instance 8", "index": 7}, {"description": "Instance 9", "index": 8}, {"description": "Instance 10", "index": 9}, {"description": "Instance 11", "index": 10}, {"description": "Instance 12", "index": 11}, {"description": "Instance 13", "index": 12}, {"description": "Instance 14", "index": 13}, {"description": "Instance 15", "index": 14}, {"description": "Instance 16", "index": 15}], "category": "Standard", "default": 1, "group": "Failure Injection", "longDesc": "Bitmask of instances of SYS_FAIL_RC_UNIT that the SYS_FAIL_RC_SRC trigger\naffects (bit 0 = instance 1, motor number for motors). 0 = all instances.\n", "max": 65535, "min": 0, "name": "SYS_FAIL_RC_INST", "rebootRequired": true, "shortDesc": "Instances failed by the RC switch", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "Failure Injection", "longDesc": "How SYS_FAIL_RC_UNIT fails when the SYS_FAIL_RC_SRC trigger fires, on SYS_FAIL_RC_INST.\nunsupported (unit, type) pairs are ignored.\n", "name": "SYS_FAIL_RC_MODE", "rebootRequired": true, "shortDesc": "Failure type applied by the RC switch", "type": "Int32", "values": [{"description": "Ok (no failure)", "value": 0}, {"description": "Off", "value": 1}, {"description": "Stuck", "value": 2}, {"description": "Garbage", "value": 3}, {"description": "Wrong", "value": 4}, {"description": "Slow", "value": 5}, {"description": "Delayed", "value": 6}, {"description": "Intermittent", "value": 7}, {"description": "Drift", "value": 8}]}, {"category": "Standard", "default": 0, "group": "Failure Injection", "longDesc": "Defines the aux switch which injects the failure defined by SYS_FAIL_RC_UNIT,\nSYS_FAIL_RC_MODE and SYS_FAIL_RC_INST;\nMapped via RC_MAP_AUXn and gated by SYS_FAILURE_EN.\n", "max": 6, "min": 0, "name": "SYS_FAIL_RC_SRC", "rebootRequired": true, "shortDesc": "RC aux input that triggers failure injection", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "AUX1", "value": 1}, {"description": "AUX2", "value": 2}, {"description": "AUX3", "value": 3}, {"description": "AUX4", "value": 4}, {"description": "AUX5", "value": 5}, {"description": "AUX6", "value": 6}]}, {"category": "Standard", "default": 101, "group": "Failure Injection", "longDesc": "Which component the SYS_FAIL_RC_SRC trigger fails, with SYS_FAIL_RC_MODE on\nSYS_FAIL_RC_INST.\n", "name": "SYS_FAIL_RC_UNIT", "rebootRequired": true, "shortDesc": "Component failed by the RC switch", "type": "Int32", "values": [{"description": "Gyro", "value": 0}, {"description": "Accel", "value": 1}, {"description": "Mag", "value": 2}, {"description": "Baro", "value": 3}, {"description": "GPS", "value": 4}, {"description": "Distance sensor", "value": 7}, {"description": "Airspeed", "value": 8}, {"description": "Battery", "value": 100}, {"description": "Motor", "value": 101}, {"description": "Traffic avoidance", "value": 107}, {"description": "CAN bus", "value": 200}]}, {"category": "Standard", "decimalPlaces": 1, "default": 1000.0, "group": "Flight Task Orbit", "increment": 0.5, "max": 10000.0, "min": 1.0, "name": "MC_ORBIT_RAD_MAX", "shortDesc": "Maximum radius of orbit", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Flight Task Orbit", "name": "MC_ORBIT_YAW_MOD", "shortDesc": "Yaw behaviour during orbit flight", "type": "Int32", "values": [{"description": "Front to Circle Center", "value": 0}, {"description": "Hold Initial Heading", "value": 1}, {"description": "Uncontrolled", "value": 2}, {"description": "Hold Front Tangent to Circle", "value": 3}, {"description": "Manually (yaw stick) Controlled", "value": 4}]}, {"category": "Standard", "default": 0, "group": "Follow target", "longDesc": "Maintain altitude or track target's altitude. When maintaining the altitude,\nthe drone can crash into terrain when the target moves uphill. When tracking\nthe target's altitude, the follow altitude FLW_TGT_HT should be high enough\nto prevent terrain collisions due to GPS inaccuracies of the target.\n", "name": "FLW_TGT_ALT_M", "shortDesc": "Altitude control mode", "type": "Int32", "values": [{"description": "2D Tracking: Maintain constant altitude relative to home and track XY position only", "value": 0}, {"description": "2D + Terrain: Maintain constant altitude relative to terrain below and track XY position", "value": 1}, {"description": "3D Tracking: Track target's altitude (be aware that GPS altitude bias usually makes this useless)", "value": 2}]}, {"category": "Standard", "default": 8.0, "group": "Follow target", "longDesc": "The distance in meters to follow the target at\n", "min": 1.0, "name": "FLW_TGT_DST", "shortDesc": "Distance to follow target from", "type": "Float", "units": "m"}, {"category": "Standard", "default": 180.0, "group": "Follow target", "longDesc": "Angle to follow the target from. 0.0 Equals straight in front of the target's\ncourse (direction of motion) and the angle increases in clockwise direction,\nmeaning Right-side would be 90.0 degrees while Left-side is -90.0 degrees\n\nNote: When the user force sets the angle out of the min/max range, it will be\nwrapped (e.g. 480 -> 120) in the range to gracefully handle the out of range.\n", "max": 180.0, "min": -180.0, "name": "FLW_TGT_FA", "shortDesc": "Follow Angle setting", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 8.0, "group": "Follow target", "longDesc": "Following height above the target\n", "min": 8.0, "name": "FLW_TGT_HT", "shortDesc": "Follow target height", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "Follow target", "longDesc": "Maximum tangential velocity setting for generating the follow orbit trajectory\n\nThis is the maximum tangential velocity the drone will circle around the target whenever\nan orbit angle setpoint changes. Higher value means more aggressive follow behavior.\n", "max": 20.0, "min": 0.0, "name": "FLW_TGT_MAX_VEL", "shortDesc": "Max tangential velocity for follow orbit trajectory", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "Follow target", "longDesc": "lower values increase the responsiveness to changing position, but also ignore less noise\n", "max": 1.0, "min": 0.0, "name": "FLW_TGT_RS", "shortDesc": "Responsiveness to target movement in Target Estimator", "type": "Float"}, {"bitmask": [{"description": "GPS (with QZSS)", "index": 0}, {"description": "SBAS", "index": 1}, {"description": "Galileo", "index": 2}, {"description": "BeiDou", "index": 3}, {"description": "GLONASS", "index": 4}, {"description": "NAVIC", "index": 5}], "category": "Standard", "default": 0, "group": "GPS", "longDesc": "This integer bitmask controls the set of GNSS systems used by the receiver. Check your\nreceiver's documentation on how many systems are supported to be used in parallel.\n\nCurrently this functionality is just implemented for u-blox receivers.\n\nWhen no bits are set, the receiver's default configuration should be used.\n\nSet bits true to enable:\n0 : Use GPS (with QZSS)\n1 : Use SBAS (multiple GPS augmentation systems)\n2 : Use Galileo\n3 : Use BeiDou\n4 : Use GLONASS\n5 : Use NAVIC\n", "max": 63, "min": 0, "name": "GPS_1_GNSS", "rebootRequired": true, "shortDesc": "GNSS Systems for Primary GPS (integer bitmask)", "type": "Int32"}, {"category": "Standard", "default": 1, "group": "GPS", "longDesc": "Select the GPS protocol over serial.\n\nAuto-detection will probe all protocols, and thus is a bit slower.\n", "max": 7, "min": 0, "name": "GPS_1_PROTOCOL", "rebootRequired": true, "shortDesc": "Protocol for Main GPS", "type": "Int32", "values": [{"description": "Auto detect", "value": 0}, {"description": "u-blox", "value": 1}, {"description": "MTK", "value": 2}, {"description": "Ashtech / Trimble", "value": 3}, {"description": "Emlid Reach", "value": 4}, {"description": "Femtomes", "value": 5}, {"description": "NMEA (generic)", "value": 6}]}, {"bitmask": [{"description": "GPS (with QZSS)", "index": 0}, {"description": "SBAS", "index": 1}, {"description": "Galileo", "index": 2}, {"description": "BeiDou", "index": 3}, {"description": "GLONASS", "index": 4}, {"description": "NAVIC", "index": 5}], "category": "Standard", "default": 0, "group": "GPS", "longDesc": "This integer bitmask controls the set of GNSS systems used by the receiver. Check your\nreceiver's documentation on how many systems are supported to be used in parallel.\n\nCurrently this functionality is just implemented for u-blox receivers.\n\nWhen no bits are set, the receiver's default configuration should be used.\n\nSet bits true to enable:\n0 : Use GPS (with QZSS)\n1 : Use SBAS (multiple GPS augmentation systems)\n2 : Use Galileo\n3 : Use BeiDou\n4 : Use GLONASS\n5 : Use NAVIC\n", "max": 63, "min": 0, "name": "GPS_2_GNSS", "rebootRequired": true, "shortDesc": "GNSS Systems for Secondary GPS (integer bitmask)", "type": "Int32"}, {"category": "Standard", "default": 1, "group": "GPS", "longDesc": "Select the GPS protocol over serial.\n\nAuto-detection will probe all protocols, and thus is a bit slower.\n", "max": 6, "min": 0, "name": "GPS_2_PROTOCOL", "rebootRequired": true, "shortDesc": "Protocol for Secondary GPS", "type": "Int32", "values": [{"description": "Auto detect", "value": 0}, {"description": "u-blox", "value": 1}, {"description": "MTK", "value": 2}, {"description": "Ashtech / Trimble", "value": 3}, {"description": "Emlid Reach", "value": 4}, {"description": "Femtomes", "value": 5}, {"description": "NMEA (generic)", "value": 6}]}, {"category": "Standard", "default": 0, "group": "GPS", "longDesc": "Some UBX modules have a FLASH that allows to store persistent configuration that will be loaded on start.\nPX4 does override all configuration parameters it needs in RAM, which takes precedence over the values in FLASH.\nHowever, configuration parameters that are not overridden by PX4 can still cause unexpected problems during flight.\nTo avoid these kind of problems a clean config can be reached by wiping the FLASH on boot.\n\nNote: Currently only supported on UBX.\n", "name": "GPS_CFG_WIPE", "rebootRequired": true, "shortDesc": "Wipes the flash config of UBX modules", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "GPS", "longDesc": "If this is set to 1, all GPS communication data will be published via uORB,\nand written to the log file as gps_dump message.\n\nIf this is set to 2, the main GPS is configured to output RTCM data,\nwhich is then logged as gps_dump and can be used for PPK.\n", "max": 2, "min": 0, "name": "GPS_DUMP_COMM", "shortDesc": "Log GPS communication data", "type": "Int32", "values": [{"description": "Disable", "value": 0}, {"description": "Full communication", "value": 1}, {"description": "RTCM output (PPK)", "value": 2}]}, {"category": "Standard", "default": 0, "group": "GPS", "name": "GPS_SAT_INFO", "rebootRequired": true, "shortDesc": "Enable sat info (if available)", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "GPS", "longDesc": "Baudrate applied to the receiver UART1 after the link is auto-detected.\n0 keeps the driver default (115200). Modes that share UART1 with RTCM\n(GPS_UBX_MODE 3/4) may need a higher rate on short/reliable links.\n", "max": 3000000, "min": 0, "name": "GPS_UBX_BAUD1", "rebootRequired": true, "shortDesc": "u-blox UART1 target baudrate", "type": "Int32", "units": "B/s"}, {"category": "Standard", "default": 230400, "group": "GPS", "longDesc": "Baudrate for the receiver UART2 port. Only applied by GPS_UBX_MODE 1, 2, 5, 6 and 7;\nthe other modes leave UART2 untouched.\n", "min": 0, "name": "GPS_UBX_BAUD2", "rebootRequired": true, "shortDesc": "u-blox UART2 baudrate", "type": "Int32", "units": "B/s"}, {"bitmask": [{"description": "Enable I2C input protocol UBX", "index": 0}, {"description": "Enable I2C input protocol NMEA", "index": 1}, {"description": "Enable I2C input protocol RTCM3X", "index": 2}, {"description": "Enable I2C output protocol UBX", "index": 3}, {"description": "Enable I2C output protocol NMEA", "index": 4}, {"description": "Enable I2C output protocol RTCM3X", "index": 5}], "category": "Standard", "default": 0, "group": "GPS", "max": 63, "min": 0, "name": "GPS_UBX_CFG_INTF", "rebootRequired": true, "shortDesc": "u-blox protocol configuration for interfaces", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "GPS", "longDesc": "When set to 0 (default), default DGNSS timeout set by u-blox will be used.\n", "max": 255, "min": 0, "name": "GPS_UBX_DGNSS_TO", "rebootRequired": true, "shortDesc": "u-blox GPS DGNSS timeout", "type": "Int32", "units": "s"}, {"category": "Standard", "default": 7, "group": "GPS", "longDesc": "u-blox receivers support different dynamic platform models to adjust the navigation engine to\nthe expected application environment.\n", "max": 8, "min": 0, "name": "GPS_UBX_DYNMODEL", "rebootRequired": true, "shortDesc": "u-blox GPS dynamic platform model", "type": "Int32", "values": [{"description": "portable", "value": 0}, {"description": "stationary", "value": 2}, {"description": "pedestrian", "value": 3}, {"description": "automotive", "value": 4}, {"description": "sea", "value": 5}, {"description": "airborne with <1g acceleration", "value": 6}, {"description": "airborne with <2g acceleration", "value": 7}, {"description": "airborne with <4g acceleration", "value": 8}]}, {"category": "Standard", "default": 1, "group": "GPS", "longDesc": "Enables or disables the high sensitivity mode for the u-blox jamming detection\n(CFG-SEC-JAMDET_SENSITIVITY_HI). When enabled, the receiver uses a\nmore sensitive algorithm to detect jamming. Disabling this may reduce false\npositives in electrically noisy environments.\n", "name": "GPS_UBX_JAM_DET", "rebootRequired": true, "shortDesc": "u-blox GPS jamming detection high sensitivity mode", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "GPS", "longDesc": "When set to 0 (default), default minimum satellite signal level set by u-blox wll be used.\n", "max": 255, "min": 0, "name": "GPS_UBX_MIN_CNO", "rebootRequired": true, "shortDesc": "u-blox GPS minimum satellite signal level for navigation", "type": "Int32", "units": "dBHz"}, {"category": "Standard", "default": 0, "group": "GPS", "longDesc": "u-blox GPS minimum elevation for a GNSS satellite to be used in navigation\n\nWhen set to 0 (default), default minimum elevation set by u-blox will be used.\n", "max": 127, "min": 0, "name": "GPS_UBX_MIN_ELEV", "rebootRequired": true, "shortDesc": "u-blox GPS minimum satellite elevation angle", "type": "Int32", "units": "deg"}, {"category": "Standard", "default": 0, "group": "GPS", "longDesc": "Select the u-blox configuration setup. Most setups will use the default, including RTK and\ndual GPS without heading.\n\nIf rover has RTCM corrections from a static base (or other static correction source) coming in on UART2, then select Mode 5.\nThe Heading mode requires 2 F9P devices to be attached. The main GPS will act as rover and output\nheading information, whereas the secondary will act as moving base.\nModes 1 and 2 require each F9P UART1 to be connected to the Autopilot. In addition, UART2 on the\nF9P units are connected to each other.\nModes 3 and 4 only require UART1 on each F9P connected to the Autopilot or Can Node. UART RX DMA is required.\nRTK is still possible with this setup.\nMode 6 is intended for use with a ground control station (not necessarily an RTK correction base).\nMode 7 turns UART2 into a diagnostic port: the receiver keeps serving the autopilot on UART1\nwhile UART2 outputs UBX at GPS_UBX_BAUD2 for u-center. Keep GPS_UBX_BAUD2 at 115200 or above,\nthe diagnostic message set saturates a slower link. UBX input is left enabled on UART2, so\nanything attached there can also reconfigure the receiver.\nMode 8 uses the free Galileo HAS corrections broadcast on E6 (ZED-X20P with HPG 2.10 or\nlater) for a PPP solution of roughly 20 cm after a few minutes of convergence. The\nreceiver only processes HAS while host corrections are off, so RTCM and SPARTN from the\nautopilot are ignored in this mode; use mode 0 whenever a correction link is available.\n", "max": 8, "min": 0, "name": "GPS_UBX_MODE", "rebootRequired": true, "shortDesc": "u-blox GPS Mode", "type": "Int32", "values": [{"description": "Default", "value": 0}, {"description": "Heading (Rover With Moving Base UART1 Connected To Autopilot, UART2 Connected To Moving Base)", "value": 1}, {"description": "Moving Base (UART1 Connected To Autopilot, UART2 Connected To Rover)", "value": 2}, {"description": "Heading (Rover With Moving Base UART1 Connected to Autopilot Or Can Node)", "value": 3}, {"description": "Moving Base (Moving Base UART1 Connected to Autopilot Or Can Node)", "value": 4}, {"description": "Rover with Static Base on UART2 (similar to Default, except coming in on UART2)", "value": 5}, {"description": "Ground Control Station (UART2 outputs NMEA)", "value": 6}, {"description": "u-center on UART2 (UART2 outputs UBX diagnostics)", "value": 7}, {"description": "Galileo HAS (X20P, PPP from E6, RTCM/SPARTN input disabled)", "value": 8}]}, {"category": "Standard", "default": 0, "group": "GPS", "name": "GPS_UBX_PPK", "rebootRequired": true, "shortDesc": "Enable MSM7 message output for PPK workflow", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "GPS", "longDesc": "Configure the output rate of u-blox GPS receivers (protocol v27+).\nWhen set to 0, automatic rate selection is used based on the receiver model.\nDefault rates: M9N=8Hz, F9P L1L2=5Hz, F9P L1L5=5Hz, Others=10Hz.\n\nNote: Higher rates reduce satellite count (e.g., >8Hz limits to 16 SVs on M9N).\nMax rates vary by model and RTK mode: F9P L1L2=5-7Hz, F9P L1L5=7-8Hz, X20=25Hz.\nHigh rates at 115200 baud may cause dropouts.\n", "max": 25, "min": 0, "name": "GPS_UBX_RATE", "rebootRequired": true, "shortDesc": "u-blox GPS output rate", "type": "Int32", "units": "Hz"}, {"category": "Standard", "default": 0, "group": "GPS", "name": "GPS_UBX_SPECTRUM", "rebootRequired": true, "shortDesc": "Enable spectrum analyzer (if available)", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 2, "group": "Geofence", "longDesc": "Note: Setting this value to 4 enables flight termination,\nwhich will kill the vehicle on violation of the fence.\n", "max": 5, "min": 0, "name": "GF_ACTION", "shortDesc": "Geofence violation action", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Warning", "value": 1}, {"description": "Hold mode", "value": 2}, {"description": "Return mode", "value": 3}, {"description": "Terminate", "value": 4}, {"description": "Land mode", "value": 5}]}, {"category": "Standard", "default": 100, "group": "Geofence", "longDesc": "Maximum number of geofence vertices the Return geofence avoidance planner can use.\nCircles use 8 vertices each, polygons their vertex count plus extra vertices for sharp corners.\nIf the fence needs more vertices, Return flies directly and ignores the geofence.\nReplanning time (on geofence / safety margin change) is cubic, RAM usage quadratic in this number\n(about 2 * N^2 bytes, e.g. 20 kB for 100 nodes).\nThe maximum of 200 is sufficient for any fence that can be stored.\nSet to 0 to disable geofence avoidance in Return.\n", "max": 200, "min": 0, "name": "GF_AVOID_NODES", "rebootRequired": true, "shortDesc": "Max graph nodes for geofence avoidance in Return", "type": "Int32"}, {"category": "Standard", "default": 0.0, "group": "Geofence", "increment": 1.0, "longDesc": "Maximum horizontal distance in meters the vehicle can be from Home before triggering a geofence action.\nDisabled if 0.\n", "max": 10000.0, "min": 0.0, "name": "GF_MAX_HOR_DIST", "shortDesc": "Max horizontal distance from Home", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0.0, "group": "Geofence", "increment": 1.0, "longDesc": "Maximum vertical distance in meters the vehicle can be from Home before triggering a geofence action.\nDisabled if 0.\n", "max": 10000.0, "min": 0.0, "name": "GF_MAX_VER_DIST", "shortDesc": "Max vertical distance from Home", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Geofence", "longDesc": "Select which position source should be used. Selecting GPS instead of global position makes sure that there is\nno dependence on the position estimator\n0 = global position, 1 = GPS\n", "max": 1, "min": 0, "name": "GF_SOURCE", "shortDesc": "Geofence source", "type": "Int32", "values": [{"description": "GPOS", "value": 0}, {"description": "GPS", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "Defines which mixer implementation to use.\nSome are generic, while others are specifically fit to a certain vehicle with a fixed set of actuators.\n\n'Custom' should only be used if noting else can be used.\n\n", "name": "CA_AIRFRAME", "shortDesc": "Airframe selection", "type": "Int32", "values": [{"description": "Multirotor", "value": 0}, {"description": "Fixed-wing", "value": 1}, {"description": "Standard VTOL", "value": 2}, {"description": "Tiltrotor VTOL", "value": 3}, {"description": "Tailsitter VTOL", "value": 4}, {"description": "Rover (Ackermann)", "value": 5}, {"description": "Rover (Differential)", "value": 6}, {"description": "Motors (6DOF)", "value": 7}, {"description": "Multirotor with Tilt", "value": 8}, {"description": "Custom", "value": 9}, {"description": "Helicopter (tail ESC)", "value": 10}, {"description": "Helicopter (tail Servo)", "value": 11}, {"description": "Helicopter (Coaxial)", "value": 12}, {"description": "Rover (Mecanum)", "value": 13}, {"description": "Spacecraft 2D", "value": 14}, {"description": "Spacecraft 3D", "value": 15}]}, {"bitmask": [{"description": "Control Surface 1", "index": 0}, {"description": "Control Surface 2", "index": 1}, {"description": "Control Surface 3", "index": 2}, {"description": "Control Surface 4", "index": 3}, {"description": "Control Surface 5", "index": 4}, {"description": "Control Surface 6", "index": 5}, {"description": "Control Surface 7", "index": 6}, {"description": "Control Surface 8", "index": 7}], "category": "Standard", "default": 0, "group": "Geometry", "longDesc": "If actuator launch lock is enabled, this surface is kept at the disarmed value.\n", "max": 255, "min": 0, "name": "CA_CS_LAUN_LK", "shortDesc": "Control surface launch lock enabled", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "What to do on a single motor failure. Ignore disables this feature entirely. Otherwise\nthe failed motor is removed from the allocation, and on a hexarotor its geometric-opposite\nmotor is additionally stopped (mode 1) or reversed (mode 2) to recover the lost\nyaw/roll/pitch authority; on other airframes only the failed motor is removed. Mode 2\nneeds a reverse-capable ESC on the opposite motor.\n\n", "name": "CA_FAILURE_MODE", "shortDesc": "Motor failure handling mode", "type": "Int32", "values": [{"description": "Ignore", "value": 0}, {"description": "Remove failed motor and stop its opposite", "value": 1}, {"description": "Remove failed motor and reverse its opposite", "value": 2}]}, {"category": "Standard", "decimalPlaces": 3, "default": -0.05, "group": "Geometry", "increment": 0.1, "longDesc": "Defines the collective pitch at the interval position 0 for a given thrust setpoint.\n\nUse negative values if the swash plate needs to move down to provide upwards thrust.\n\n", "max": 1.0, "min": -1.0, "name": "CA_HELI_PITCH_C0", "shortDesc": "Collective pitch curve at position 0", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0725, "group": "Geometry", "increment": 0.1, "longDesc": "Defines the collective pitch at the interval position 1 for a given thrust setpoint.\n\nUse negative values if the swash plate needs to move down to provide upwards thrust.\n\n", "max": 1.0, "min": -1.0, "name": "CA_HELI_PITCH_C1", "shortDesc": "Collective pitch curve at position 1", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.2, "group": "Geometry", "increment": 0.1, "longDesc": "Defines the collective pitch at the interval position 2 for a given thrust setpoint.\n\nUse negative values if the swash plate needs to move down to provide upwards thrust.\n\n", "max": 1.0, "min": -1.0, "name": "CA_HELI_PITCH_C2", "shortDesc": "Collective pitch curve at position 2", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.325, "group": "Geometry", "increment": 0.1, "longDesc": "Defines the collective pitch at the interval position 3 for a given thrust setpoint.\n\nUse negative values if the swash plate needs to move down to provide upwards thrust.\n\n", "max": 1.0, "min": -1.0, "name": "CA_HELI_PITCH_C3", "shortDesc": "Collective pitch curve at position 3", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.45, "group": "Geometry", "increment": 0.1, "longDesc": "Defines the collective pitch at the interval position 4 for a given thrust setpoint.\n\nUse negative values if the swash plate needs to move down to provide upwards thrust.\n\n", "max": 1.0, "min": -1.0, "name": "CA_HELI_PITCH_C4", "shortDesc": "Collective pitch curve at position 4", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Same definition as the proportional gain but for integral.\n\n", "max": 10.0, "min": 0.0, "name": "CA_HELI_RPM_I", "shortDesc": "Integral gain for rpm control", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Ratio between rpm error devided by 1000 to how much normalized output gets added to correct for it.\n\nmotor_command = throttle_curve + CA_HELI_RPM_P * (rpm_setpoint - rpm_measurement) / 1000\n\n", "max": 10.0, "min": 0.0, "name": "CA_HELI_RPM_P", "shortDesc": "Proportional gain for rpm control", "type": "Float"}, {"category": "Standard", "decimalPlaces": 0, "default": 1500.0, "group": "Geometry", "increment": 1.0, "longDesc": "Requires rpm feedback for the controller.\n\n", "max": 10000.0, "min": 100.0, "name": "CA_HELI_RPM_SP", "shortDesc": "Setpoint for main rotor rpm", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Defines the output throttle at the interval position 0.\n\n", "max": 1.0, "min": 0.0, "name": "CA_HELI_THR_C0", "shortDesc": "Throttle curve at position 0", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Defines the output throttle at the interval position 1.\n\n", "max": 1.0, "min": 0.0, "name": "CA_HELI_THR_C1", "shortDesc": "Throttle curve at position 1", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Defines the output throttle at the interval position 2.\n\n", "max": 1.0, "min": 0.0, "name": "CA_HELI_THR_C2", "shortDesc": "Throttle curve at position 2", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Defines the output throttle at the interval position 3.\n\n", "max": 1.0, "min": 0.0, "name": "CA_HELI_THR_C3", "shortDesc": "Throttle curve at position 3", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Defines the output throttle at the interval position 4.\n\n", "max": 1.0, "min": 0.0, "name": "CA_HELI_THR_C4", "shortDesc": "Throttle curve at position 4", "type": "Float"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "Default configuration is for a clockwise turning main rotor and\npositive thrust of the tail rotor is expected to rotate the vehicle clockwise.\nSet this parameter to true if the tail rotor provides thrust in counter-clockwise direction\nwhich is mostly the case when the main rotor turns counter-clockwise.\n\n", "name": "CA_HELI_YAW_CCW", "shortDesc": "Main rotor turns counter-clockwise", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "This allows to specify which collective pitch command results in the least amount of rotor drag.\nThis is used to increase the accuracy of the yaw drag torque compensation based on collective pitch\nby aligning the lowest rotor drag with zero compensation.\nFor symmetric profile blades this is the command that results in exactly 0\u00b0 collective blade angle.\nFor lift profile blades this is typically a command resulting in slightly negative collective blade angle.\n\ntail_output += CA_HELI_YAW_CP_S * abs(collective_pitch - CA_HELI_YAW_CP_O)\n\n", "max": 2.0, "min": -2.0, "name": "CA_HELI_YAW_CP_O", "shortDesc": "Offset for yaw compensation based on collective pitch", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "This allows to add a proportional factor of the collective pitch command to the yaw command.\nA negative value is needed when positive thrust of the tail rotor rotates the vehicle opposite to the main rotor turn direction.\n\ntail_output += CA_HELI_YAW_CP_S * abs(collective_pitch - CA_HELI_YAW_CP_O)\n\n", "max": 2.0, "min": -2.0, "name": "CA_HELI_YAW_CP_S", "shortDesc": "Scale for yaw compensation based on collective pitch", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "This allows to add a proportional factor of the throttle command to the yaw command.\nA negative value is needed when positive thrust of the tail rotor rotates the vehicle opposite to the main rotor turn direction.\n\ntail_output += CA_HELI_YAW_TH_S * throttle\n\n", "max": 2.0, "min": -2.0, "name": "CA_HELI_YAW_TH_S", "shortDesc": "Scale for yaw compensation based on throttle", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Ice shedding prevents ice buildup in VTOL aircraft motors by periodically spinning inactive rotors.\nWhen enabled (period > 0), every cycle lasts for the defined period and includes a 2-second spin at 0.01 motor output.\nIf period <= 0, the feature is disabled.\n\n", "min": 0.0, "name": "CA_ICE_PERIOD", "shortDesc": "Ice shedding cycle period", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Used to linearize mechanical output of swashplate servos to avoid axis coupling and binding with 4 servo redundancy.\nThis requires a symmetric setup where the servo horn is exactly centered with a 0 command.\nSetting to zero disables feature.\n\n", "max": 75.0, "min": 0.0, "name": "CA_MAX_SVO_THROW", "shortDesc": "Throw angle of swashplate servo at maximum commands for linearization", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 2, "group": "Geometry", "longDesc": "Selects the algorithm and desaturation method.\nIf set to Automatic, the selection is based on the airframe (CA_AIRFRAME).\n\n", "name": "CA_METHOD", "shortDesc": "Control allocation method", "type": "Int32", "values": [{"description": "Pseudo-inverse with output clipping", "value": 0}, {"description": "Pseudo-inverse with sequential desaturation technique", "value": 1}, {"description": "Automatic", "value": 2}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.01, "longDesc": "Forces the motor output signal to take at least the configured time (in seconds)\nto traverse its full range (normally [0, 1], or if reversible [-1, 1]).\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_R0_SLEW", "shortDesc": "Motor 0 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.01, "longDesc": "Forces the motor output signal to take at least the configured time (in seconds)\nto traverse its full range (normally [0, 1], or if reversible [-1, 1]).\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_R10_SLEW", "shortDesc": "Motor 10 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.01, "longDesc": "Forces the motor output signal to take at least the configured time (in seconds)\nto traverse its full range (normally [0, 1], or if reversible [-1, 1]).\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_R11_SLEW", "shortDesc": "Motor 11 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.01, "longDesc": "Forces the motor output signal to take at least the configured time (in seconds)\nto traverse its full range (normally [0, 1], or if reversible [-1, 1]).\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_R1_SLEW", "shortDesc": "Motor 1 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.01, "longDesc": "Forces the motor output signal to take at least the configured time (in seconds)\nto traverse its full range (normally [0, 1], or if reversible [-1, 1]).\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_R2_SLEW", "shortDesc": "Motor 2 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.01, "longDesc": "Forces the motor output signal to take at least the configured time (in seconds)\nto traverse its full range (normally [0, 1], or if reversible [-1, 1]).\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_R3_SLEW", "shortDesc": "Motor 3 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.01, "longDesc": "Forces the motor output signal to take at least the configured time (in seconds)\nto traverse its full range (normally [0, 1], or if reversible [-1, 1]).\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_R4_SLEW", "shortDesc": "Motor 4 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.01, "longDesc": "Forces the motor output signal to take at least the configured time (in seconds)\nto traverse its full range (normally [0, 1], or if reversible [-1, 1]).\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_R5_SLEW", "shortDesc": "Motor 5 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.01, "longDesc": "Forces the motor output signal to take at least the configured time (in seconds)\nto traverse its full range (normally [0, 1], or if reversible [-1, 1]).\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_R6_SLEW", "shortDesc": "Motor 6 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.01, "longDesc": "Forces the motor output signal to take at least the configured time (in seconds)\nto traverse its full range (normally [0, 1], or if reversible [-1, 1]).\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_R7_SLEW", "shortDesc": "Motor 7 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.01, "longDesc": "Forces the motor output signal to take at least the configured time (in seconds)\nto traverse its full range (normally [0, 1], or if reversible [-1, 1]).\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_R8_SLEW", "shortDesc": "Motor 8 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.01, "longDesc": "Forces the motor output signal to take at least the configured time (in seconds)\nto traverse its full range (normally [0, 1], or if reversible [-1, 1]).\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_R9_SLEW", "shortDesc": "Motor 9 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "default": 0.4, "group": "Geometry", "longDesc": "Fraction of forward thrust a reversible motor produces in reverse (e.g. 0.4 = 40%).\nThis is mostly a property of the propeller.\n\n", "max": 1.0, "min": 0.1, "name": "CA_REV_THR_FRAC", "shortDesc": "Reverse thrust fraction for reversible motors", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR0_AX", "shortDesc": "Axis of rotor 0 thrust vector, X body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR0_AY", "shortDesc": "Axis of rotor 0 thrust vector, Y body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR0_AZ", "shortDesc": "Axis of rotor 0 thrust vector, Z body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 6.5, "group": "Geometry", "increment": 1.0, "longDesc": "The thrust coefficient if defined as Thrust = CT * u^2,\nwhere u (with value between actuator minimum and maximum)\nis the output signal sent to the motor controller.\n\n", "max": 100.0, "min": 0.0, "name": "CA_ROTOR0_CT", "shortDesc": "Thrust coefficient of rotor 0", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "Geometry", "increment": 0.01, "longDesc": "The moment coefficient if defined as Torque = KM * Thrust.\n\nUse a positive value for a rotor with CCW rotation.\nUse a negative value for a rotor with CW rotation.\n\n", "max": 1.0, "min": -1.0, "name": "CA_ROTOR0_KM", "shortDesc": "Moment coefficient of rotor 0", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR0_PX", "shortDesc": "Position of rotor 0 along X body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR0_PY", "shortDesc": "Position of rotor 0 along Y body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR0_PZ", "shortDesc": "Position of rotor 0 along Z body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "If not set to None, this motor is tilted by the configured tilt servo.\n", "name": "CA_ROTOR0_TILT", "shortDesc": "Rotor 0 tilt assignment", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Tilt 1", "value": 1}, {"description": "Tilt 2", "value": 2}, {"description": "Tilt 3", "value": 3}, {"description": "Tilt 4", "value": 4}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR10_AX", "shortDesc": "Axis of rotor 10 thrust vector, X body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR10_AY", "shortDesc": "Axis of rotor 10 thrust vector, Y body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR10_AZ", "shortDesc": "Axis of rotor 10 thrust vector, Z body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 6.5, "group": "Geometry", "increment": 1.0, "longDesc": "The thrust coefficient if defined as Thrust = CT * u^2,\nwhere u (with value between actuator minimum and maximum)\nis the output signal sent to the motor controller.\n\n", "max": 100.0, "min": 0.0, "name": "CA_ROTOR10_CT", "shortDesc": "Thrust coefficient of rotor 10", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "Geometry", "increment": 0.01, "longDesc": "The moment coefficient if defined as Torque = KM * Thrust.\n\nUse a positive value for a rotor with CCW rotation.\nUse a negative value for a rotor with CW rotation.\n\n", "max": 1.0, "min": -1.0, "name": "CA_ROTOR10_KM", "shortDesc": "Moment coefficient of rotor 10", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR10_PX", "shortDesc": "Position of rotor 10 along X body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR10_PY", "shortDesc": "Position of rotor 10 along Y body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR10_PZ", "shortDesc": "Position of rotor 10 along Z body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "If not set to None, this motor is tilted by the configured tilt servo.\n", "name": "CA_ROTOR10_TILT", "shortDesc": "Rotor 10 tilt assignment", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Tilt 1", "value": 1}, {"description": "Tilt 2", "value": 2}, {"description": "Tilt 3", "value": 3}, {"description": "Tilt 4", "value": 4}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR11_AX", "shortDesc": "Axis of rotor 11 thrust vector, X body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR11_AY", "shortDesc": "Axis of rotor 11 thrust vector, Y body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR11_AZ", "shortDesc": "Axis of rotor 11 thrust vector, Z body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 6.5, "group": "Geometry", "increment": 1.0, "longDesc": "The thrust coefficient if defined as Thrust = CT * u^2,\nwhere u (with value between actuator minimum and maximum)\nis the output signal sent to the motor controller.\n\n", "max": 100.0, "min": 0.0, "name": "CA_ROTOR11_CT", "shortDesc": "Thrust coefficient of rotor 11", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "Geometry", "increment": 0.01, "longDesc": "The moment coefficient if defined as Torque = KM * Thrust.\n\nUse a positive value for a rotor with CCW rotation.\nUse a negative value for a rotor with CW rotation.\n\n", "max": 1.0, "min": -1.0, "name": "CA_ROTOR11_KM", "shortDesc": "Moment coefficient of rotor 11", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR11_PX", "shortDesc": "Position of rotor 11 along X body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR11_PY", "shortDesc": "Position of rotor 11 along Y body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR11_PZ", "shortDesc": "Position of rotor 11 along Z body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "If not set to None, this motor is tilted by the configured tilt servo.\n", "name": "CA_ROTOR11_TILT", "shortDesc": "Rotor 11 tilt assignment", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Tilt 1", "value": 1}, {"description": "Tilt 2", "value": 2}, {"description": "Tilt 3", "value": 3}, {"description": "Tilt 4", "value": 4}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR1_AX", "shortDesc": "Axis of rotor 1 thrust vector, X body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR1_AY", "shortDesc": "Axis of rotor 1 thrust vector, Y body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR1_AZ", "shortDesc": "Axis of rotor 1 thrust vector, Z body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 6.5, "group": "Geometry", "increment": 1.0, "longDesc": "The thrust coefficient if defined as Thrust = CT * u^2,\nwhere u (with value between actuator minimum and maximum)\nis the output signal sent to the motor controller.\n\n", "max": 100.0, "min": 0.0, "name": "CA_ROTOR1_CT", "shortDesc": "Thrust coefficient of rotor 1", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "Geometry", "increment": 0.01, "longDesc": "The moment coefficient if defined as Torque = KM * Thrust.\n\nUse a positive value for a rotor with CCW rotation.\nUse a negative value for a rotor with CW rotation.\n\n", "max": 1.0, "min": -1.0, "name": "CA_ROTOR1_KM", "shortDesc": "Moment coefficient of rotor 1", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR1_PX", "shortDesc": "Position of rotor 1 along X body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR1_PY", "shortDesc": "Position of rotor 1 along Y body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR1_PZ", "shortDesc": "Position of rotor 1 along Z body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "If not set to None, this motor is tilted by the configured tilt servo.\n", "name": "CA_ROTOR1_TILT", "shortDesc": "Rotor 1 tilt assignment", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Tilt 1", "value": 1}, {"description": "Tilt 2", "value": 2}, {"description": "Tilt 3", "value": 3}, {"description": "Tilt 4", "value": 4}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR2_AX", "shortDesc": "Axis of rotor 2 thrust vector, X body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR2_AY", "shortDesc": "Axis of rotor 2 thrust vector, Y body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR2_AZ", "shortDesc": "Axis of rotor 2 thrust vector, Z body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 6.5, "group": "Geometry", "increment": 1.0, "longDesc": "The thrust coefficient if defined as Thrust = CT * u^2,\nwhere u (with value between actuator minimum and maximum)\nis the output signal sent to the motor controller.\n\n", "max": 100.0, "min": 0.0, "name": "CA_ROTOR2_CT", "shortDesc": "Thrust coefficient of rotor 2", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "Geometry", "increment": 0.01, "longDesc": "The moment coefficient if defined as Torque = KM * Thrust.\n\nUse a positive value for a rotor with CCW rotation.\nUse a negative value for a rotor with CW rotation.\n\n", "max": 1.0, "min": -1.0, "name": "CA_ROTOR2_KM", "shortDesc": "Moment coefficient of rotor 2", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR2_PX", "shortDesc": "Position of rotor 2 along X body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR2_PY", "shortDesc": "Position of rotor 2 along Y body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR2_PZ", "shortDesc": "Position of rotor 2 along Z body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "If not set to None, this motor is tilted by the configured tilt servo.\n", "name": "CA_ROTOR2_TILT", "shortDesc": "Rotor 2 tilt assignment", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Tilt 1", "value": 1}, {"description": "Tilt 2", "value": 2}, {"description": "Tilt 3", "value": 3}, {"description": "Tilt 4", "value": 4}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR3_AX", "shortDesc": "Axis of rotor 3 thrust vector, X body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR3_AY", "shortDesc": "Axis of rotor 3 thrust vector, Y body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR3_AZ", "shortDesc": "Axis of rotor 3 thrust vector, Z body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 6.5, "group": "Geometry", "increment": 1.0, "longDesc": "The thrust coefficient if defined as Thrust = CT * u^2,\nwhere u (with value between actuator minimum and maximum)\nis the output signal sent to the motor controller.\n\n", "max": 100.0, "min": 0.0, "name": "CA_ROTOR3_CT", "shortDesc": "Thrust coefficient of rotor 3", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "Geometry", "increment": 0.01, "longDesc": "The moment coefficient if defined as Torque = KM * Thrust.\n\nUse a positive value for a rotor with CCW rotation.\nUse a negative value for a rotor with CW rotation.\n\n", "max": 1.0, "min": -1.0, "name": "CA_ROTOR3_KM", "shortDesc": "Moment coefficient of rotor 3", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR3_PX", "shortDesc": "Position of rotor 3 along X body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR3_PY", "shortDesc": "Position of rotor 3 along Y body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR3_PZ", "shortDesc": "Position of rotor 3 along Z body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "If not set to None, this motor is tilted by the configured tilt servo.\n", "name": "CA_ROTOR3_TILT", "shortDesc": "Rotor 3 tilt assignment", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Tilt 1", "value": 1}, {"description": "Tilt 2", "value": 2}, {"description": "Tilt 3", "value": 3}, {"description": "Tilt 4", "value": 4}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR4_AX", "shortDesc": "Axis of rotor 4 thrust vector, X body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR4_AY", "shortDesc": "Axis of rotor 4 thrust vector, Y body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR4_AZ", "shortDesc": "Axis of rotor 4 thrust vector, Z body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 6.5, "group": "Geometry", "increment": 1.0, "longDesc": "The thrust coefficient if defined as Thrust = CT * u^2,\nwhere u (with value between actuator minimum and maximum)\nis the output signal sent to the motor controller.\n\n", "max": 100.0, "min": 0.0, "name": "CA_ROTOR4_CT", "shortDesc": "Thrust coefficient of rotor 4", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "Geometry", "increment": 0.01, "longDesc": "The moment coefficient if defined as Torque = KM * Thrust.\n\nUse a positive value for a rotor with CCW rotation.\nUse a negative value for a rotor with CW rotation.\n\n", "max": 1.0, "min": -1.0, "name": "CA_ROTOR4_KM", "shortDesc": "Moment coefficient of rotor 4", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR4_PX", "shortDesc": "Position of rotor 4 along X body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR4_PY", "shortDesc": "Position of rotor 4 along Y body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR4_PZ", "shortDesc": "Position of rotor 4 along Z body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "If not set to None, this motor is tilted by the configured tilt servo.\n", "name": "CA_ROTOR4_TILT", "shortDesc": "Rotor 4 tilt assignment", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Tilt 1", "value": 1}, {"description": "Tilt 2", "value": 2}, {"description": "Tilt 3", "value": 3}, {"description": "Tilt 4", "value": 4}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR5_AX", "shortDesc": "Axis of rotor 5 thrust vector, X body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR5_AY", "shortDesc": "Axis of rotor 5 thrust vector, Y body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR5_AZ", "shortDesc": "Axis of rotor 5 thrust vector, Z body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 6.5, "group": "Geometry", "increment": 1.0, "longDesc": "The thrust coefficient if defined as Thrust = CT * u^2,\nwhere u (with value between actuator minimum and maximum)\nis the output signal sent to the motor controller.\n\n", "max": 100.0, "min": 0.0, "name": "CA_ROTOR5_CT", "shortDesc": "Thrust coefficient of rotor 5", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "Geometry", "increment": 0.01, "longDesc": "The moment coefficient if defined as Torque = KM * Thrust.\n\nUse a positive value for a rotor with CCW rotation.\nUse a negative value for a rotor with CW rotation.\n\n", "max": 1.0, "min": -1.0, "name": "CA_ROTOR5_KM", "shortDesc": "Moment coefficient of rotor 5", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR5_PX", "shortDesc": "Position of rotor 5 along X body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR5_PY", "shortDesc": "Position of rotor 5 along Y body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR5_PZ", "shortDesc": "Position of rotor 5 along Z body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "If not set to None, this motor is tilted by the configured tilt servo.\n", "name": "CA_ROTOR5_TILT", "shortDesc": "Rotor 5 tilt assignment", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Tilt 1", "value": 1}, {"description": "Tilt 2", "value": 2}, {"description": "Tilt 3", "value": 3}, {"description": "Tilt 4", "value": 4}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR6_AX", "shortDesc": "Axis of rotor 6 thrust vector, X body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR6_AY", "shortDesc": "Axis of rotor 6 thrust vector, Y body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR6_AZ", "shortDesc": "Axis of rotor 6 thrust vector, Z body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 6.5, "group": "Geometry", "increment": 1.0, "longDesc": "The thrust coefficient if defined as Thrust = CT * u^2,\nwhere u (with value between actuator minimum and maximum)\nis the output signal sent to the motor controller.\n\n", "max": 100.0, "min": 0.0, "name": "CA_ROTOR6_CT", "shortDesc": "Thrust coefficient of rotor 6", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "Geometry", "increment": 0.01, "longDesc": "The moment coefficient if defined as Torque = KM * Thrust.\n\nUse a positive value for a rotor with CCW rotation.\nUse a negative value for a rotor with CW rotation.\n\n", "max": 1.0, "min": -1.0, "name": "CA_ROTOR6_KM", "shortDesc": "Moment coefficient of rotor 6", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR6_PX", "shortDesc": "Position of rotor 6 along X body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR6_PY", "shortDesc": "Position of rotor 6 along Y body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR6_PZ", "shortDesc": "Position of rotor 6 along Z body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "If not set to None, this motor is tilted by the configured tilt servo.\n", "name": "CA_ROTOR6_TILT", "shortDesc": "Rotor 6 tilt assignment", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Tilt 1", "value": 1}, {"description": "Tilt 2", "value": 2}, {"description": "Tilt 3", "value": 3}, {"description": "Tilt 4", "value": 4}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR7_AX", "shortDesc": "Axis of rotor 7 thrust vector, X body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR7_AY", "shortDesc": "Axis of rotor 7 thrust vector, Y body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR7_AZ", "shortDesc": "Axis of rotor 7 thrust vector, Z body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 6.5, "group": "Geometry", "increment": 1.0, "longDesc": "The thrust coefficient if defined as Thrust = CT * u^2,\nwhere u (with value between actuator minimum and maximum)\nis the output signal sent to the motor controller.\n\n", "max": 100.0, "min": 0.0, "name": "CA_ROTOR7_CT", "shortDesc": "Thrust coefficient of rotor 7", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "Geometry", "increment": 0.01, "longDesc": "The moment coefficient if defined as Torque = KM * Thrust.\n\nUse a positive value for a rotor with CCW rotation.\nUse a negative value for a rotor with CW rotation.\n\n", "max": 1.0, "min": -1.0, "name": "CA_ROTOR7_KM", "shortDesc": "Moment coefficient of rotor 7", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR7_PX", "shortDesc": "Position of rotor 7 along X body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR7_PY", "shortDesc": "Position of rotor 7 along Y body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR7_PZ", "shortDesc": "Position of rotor 7 along Z body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "If not set to None, this motor is tilted by the configured tilt servo.\n", "name": "CA_ROTOR7_TILT", "shortDesc": "Rotor 7 tilt assignment", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Tilt 1", "value": 1}, {"description": "Tilt 2", "value": 2}, {"description": "Tilt 3", "value": 3}, {"description": "Tilt 4", "value": 4}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR8_AX", "shortDesc": "Axis of rotor 8 thrust vector, X body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR8_AY", "shortDesc": "Axis of rotor 8 thrust vector, Y body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR8_AZ", "shortDesc": "Axis of rotor 8 thrust vector, Z body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 6.5, "group": "Geometry", "increment": 1.0, "longDesc": "The thrust coefficient if defined as Thrust = CT * u^2,\nwhere u (with value between actuator minimum and maximum)\nis the output signal sent to the motor controller.\n\n", "max": 100.0, "min": 0.0, "name": "CA_ROTOR8_CT", "shortDesc": "Thrust coefficient of rotor 8", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "Geometry", "increment": 0.01, "longDesc": "The moment coefficient if defined as Torque = KM * Thrust.\n\nUse a positive value for a rotor with CCW rotation.\nUse a negative value for a rotor with CW rotation.\n\n", "max": 1.0, "min": -1.0, "name": "CA_ROTOR8_KM", "shortDesc": "Moment coefficient of rotor 8", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR8_PX", "shortDesc": "Position of rotor 8 along X body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR8_PY", "shortDesc": "Position of rotor 8 along Y body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR8_PZ", "shortDesc": "Position of rotor 8 along Z body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "If not set to None, this motor is tilted by the configured tilt servo.\n", "name": "CA_ROTOR8_TILT", "shortDesc": "Rotor 8 tilt assignment", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Tilt 1", "value": 1}, {"description": "Tilt 2", "value": 2}, {"description": "Tilt 3", "value": 3}, {"description": "Tilt 4", "value": 4}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR9_AX", "shortDesc": "Axis of rotor 9 thrust vector, X body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR9_AY", "shortDesc": "Axis of rotor 9 thrust vector, Y body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR9_AZ", "shortDesc": "Axis of rotor 9 thrust vector, Z body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 6.5, "group": "Geometry", "increment": 1.0, "longDesc": "The thrust coefficient if defined as Thrust = CT * u^2,\nwhere u (with value between actuator minimum and maximum)\nis the output signal sent to the motor controller.\n\n", "max": 100.0, "min": 0.0, "name": "CA_ROTOR9_CT", "shortDesc": "Thrust coefficient of rotor 9", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "Geometry", "increment": 0.01, "longDesc": "The moment coefficient if defined as Torque = KM * Thrust.\n\nUse a positive value for a rotor with CCW rotation.\nUse a negative value for a rotor with CW rotation.\n\n", "max": 1.0, "min": -1.0, "name": "CA_ROTOR9_KM", "shortDesc": "Moment coefficient of rotor 9", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR9_PX", "shortDesc": "Position of rotor 9 along X body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR9_PY", "shortDesc": "Position of rotor 9 along Y body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR9_PZ", "shortDesc": "Position of rotor 9 along Z body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "If not set to None, this motor is tilted by the configured tilt servo.\n", "name": "CA_ROTOR9_TILT", "shortDesc": "Rotor 9 tilt assignment", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Tilt 1", "value": 1}, {"description": "Tilt 2", "value": 2}, {"description": "Tilt 3", "value": 3}, {"description": "Tilt 4", "value": 4}]}, {"category": "Standard", "default": 0, "group": "Geometry", "name": "CA_ROTOR_COUNT", "shortDesc": "Total number of rotors", "type": "Int32", "values": [{"description": "0", "value": 0}, {"description": "1", "value": 1}, {"description": "2", "value": 2}, {"description": "3", "value": 3}, {"description": "4", "value": 4}, {"description": "5", "value": 5}, {"description": "6", "value": 6}, {"description": "7", "value": 7}, {"description": "8", "value": 8}, {"description": "9", "value": 9}, {"description": "10", "value": 10}, {"description": "11", "value": 11}, {"description": "12", "value": 12}]}, {"bitmask": [{"description": "Motor 1", "index": 0}, {"description": "Motor 2", "index": 1}, {"description": "Motor 3", "index": 2}, {"description": "Motor 4", "index": 3}, {"description": "Motor 5", "index": 4}, {"description": "Motor 6", "index": 5}, {"description": "Motor 7", "index": 6}, {"description": "Motor 8", "index": 7}, {"description": "Motor 9", "index": 8}, {"description": "Motor 10", "index": 9}, {"description": "Motor 11", "index": 10}, {"description": "Motor 12", "index": 11}], "category": "Standard", "default": 0, "group": "Geometry", "longDesc": "Configure motors to be bidirectional/reversible. Note that the output driver needs to support this as well.\n\n", "max": 4095, "min": 0, "name": "CA_R_REV", "shortDesc": "Bidirectional/Reversible motors", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 0, "default": 0.0, "group": "Geometry", "increment": 10.0, "longDesc": "The angle is measured clockwise (as seen from top), with 0 pointing forwards (X axis).\n\n", "max": 360.0, "min": 0.0, "name": "CA_SP0_ANG0", "shortDesc": "Angle for swash plate servo 0", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 0, "default": 140.0, "group": "Geometry", "increment": 10.0, "longDesc": "The angle is measured clockwise (as seen from top), with 0 pointing forwards (X axis).\n\n", "max": 360.0, "min": 0.0, "name": "CA_SP0_ANG1", "shortDesc": "Angle for swash plate servo 1", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 0, "default": 220.0, "group": "Geometry", "increment": 10.0, "longDesc": "The angle is measured clockwise (as seen from top), with 0 pointing forwards (X axis).\n\n", "max": 360.0, "min": 0.0, "name": "CA_SP0_ANG2", "shortDesc": "Angle for swash plate servo 2", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 0, "default": 0.0, "group": "Geometry", "increment": 10.0, "longDesc": "The angle is measured clockwise (as seen from top), with 0 pointing forwards (X axis).\n\n", "max": 360.0, "min": 0.0, "name": "CA_SP0_ANG3", "shortDesc": "Angle for swash plate servo 3", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "Geometry", "increment": 0.1, "longDesc": "This is relative to the other arm lengths.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SP0_ARM_L0", "shortDesc": "Arm length for swash plate servo 0", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "Geometry", "increment": 0.1, "longDesc": "This is relative to the other arm lengths.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SP0_ARM_L1", "shortDesc": "Arm length for swash plate servo 1", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "Geometry", "increment": 0.1, "longDesc": "This is relative to the other arm lengths.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SP0_ARM_L2", "shortDesc": "Arm length for swash plate servo 2", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "Geometry", "increment": 0.1, "longDesc": "This is relative to the other arm lengths.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SP0_ARM_L3", "shortDesc": "Arm length for swash plate servo 3", "type": "Float"}, {"category": "Standard", "default": 3, "group": "Geometry", "name": "CA_SP0_COUNT", "shortDesc": "Number of swash plates servos", "type": "Int32", "values": [{"description": "2", "value": 2}, {"description": "3", "value": 3}, {"description": "4", "value": 4}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.05, "longDesc": "Forces the servo output signal to take at least the configured time (in seconds)\nto traverse its full range [-100%, 100%].\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SV0_SLEW", "shortDesc": "Servo 0 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.05, "longDesc": "Forces the servo output signal to take at least the configured time (in seconds)\nto traverse its full range [-100%, 100%].\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SV10_SLEW", "shortDesc": "Servo 10 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.05, "longDesc": "Forces the servo output signal to take at least the configured time (in seconds)\nto traverse its full range [-100%, 100%].\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SV11_SLEW", "shortDesc": "Servo 11 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.05, "longDesc": "Forces the servo output signal to take at least the configured time (in seconds)\nto traverse its full range [-100%, 100%].\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SV12_SLEW", "shortDesc": "Servo 12 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.05, "longDesc": "Forces the servo output signal to take at least the configured time (in seconds)\nto traverse its full range [-100%, 100%].\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SV13_SLEW", "shortDesc": "Servo 13 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.05, "longDesc": "Forces the servo output signal to take at least the configured time (in seconds)\nto traverse its full range [-100%, 100%].\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SV14_SLEW", "shortDesc": "Servo 14 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.05, "longDesc": "Forces the servo output signal to take at least the configured time (in seconds)\nto traverse its full range [-100%, 100%].\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SV1_SLEW", "shortDesc": "Servo 1 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.05, "longDesc": "Forces the servo output signal to take at least the configured time (in seconds)\nto traverse its full range [-100%, 100%].\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SV2_SLEW", "shortDesc": "Servo 2 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.05, "longDesc": "Forces the servo output signal to take at least the configured time (in seconds)\nto traverse its full range [-100%, 100%].\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SV3_SLEW", "shortDesc": "Servo 3 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.05, "longDesc": "Forces the servo output signal to take at least the configured time (in seconds)\nto traverse its full range [-100%, 100%].\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SV4_SLEW", "shortDesc": "Servo 4 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.05, "longDesc": "Forces the servo output signal to take at least the configured time (in seconds)\nto traverse its full range [-100%, 100%].\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SV5_SLEW", "shortDesc": "Servo 5 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.05, "longDesc": "Forces the servo output signal to take at least the configured time (in seconds)\nto traverse its full range [-100%, 100%].\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SV6_SLEW", "shortDesc": "Servo 6 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.05, "longDesc": "Forces the servo output signal to take at least the configured time (in seconds)\nto traverse its full range [-100%, 100%].\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SV7_SLEW", "shortDesc": "Servo 7 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.05, "longDesc": "Forces the servo output signal to take at least the configured time (in seconds)\nto traverse its full range [-100%, 100%].\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SV8_SLEW", "shortDesc": "Servo 8 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.05, "longDesc": "Forces the servo output signal to take at least the configured time (in seconds)\nto traverse its full range [-100%, 100%].\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SV9_SLEW", "shortDesc": "Servo 9 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "max": 1.0, "min": -1.0, "name": "CA_SV_CS0_FLAP", "shortDesc": "Control Surface 0 configuration as flap", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "max": 1.0, "min": -1.0, "name": "CA_SV_CS0_SPOIL", "shortDesc": "Control Surface 0 configuration as spoiler", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "longDesc": "Can be used to add an offset to the servo control.\n\nNOTE: Do not use for PWM servos. Use the PWM CENTER parameters instead (e.g., PWM_MAIN_CENT, PWM_AUX_CENT) instead.\nThis parameter can only be set if all PWM Center parameters are set to default.\n\n", "max": 1.0, "min": -1.0, "name": "CA_SV_CS0_TRIM", "shortDesc": "Control Surface 0 trim", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS0_TRQ_P", "shortDesc": "Control Surface 0 pitch torque scaling", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS0_TRQ_R", "shortDesc": "Control Surface 0 roll torque scaling", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS0_TRQ_Y", "shortDesc": "Control Surface 0 yaw torque scaling", "type": "Float"}, {"category": "Standard", "default": 0, "group": "Geometry", "name": "CA_SV_CS0_TYPE", "shortDesc": "Control Surface 0 type", "type": "Int32", "values": [{"description": "(Not set)", "value": 0}, {"description": "Left Aileron", "value": 1}, {"description": "Right Aileron", "value": 2}, {"description": "Elevator", "value": 3}, {"description": "Rudder", "value": 4}, {"description": "Left Elevon", "value": 5}, {"description": "Right Elevon", "value": 6}, {"description": "Left V-Tail", "value": 7}, {"description": "Right V-Tail", "value": 8}, {"description": "Left Flap", "value": 9}, {"description": "Right Flap", "value": 10}, {"description": "Airbrake", "value": 11}, {"description": "Custom", "value": 12}, {"description": "Left A-tail", "value": 13}, {"description": "Right A-tail", "value": 14}, {"description": "Single Channel Aileron", "value": 15}, {"description": "Steering Wheel", "value": 16}, {"description": "Left Spoiler", "value": 17}, {"description": "Right Spoiler", "value": 18}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "max": 1.0, "min": -1.0, "name": "CA_SV_CS1_FLAP", "shortDesc": "Control Surface 1 configuration as flap", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "max": 1.0, "min": -1.0, "name": "CA_SV_CS1_SPOIL", "shortDesc": "Control Surface 1 configuration as spoiler", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "longDesc": "Can be used to add an offset to the servo control.\n\nNOTE: Do not use for PWM servos. Use the PWM CENTER parameters instead (e.g., PWM_MAIN_CENT, PWM_AUX_CENT) instead.\nThis parameter can only be set if all PWM Center parameters are set to default.\n\n", "max": 1.0, "min": -1.0, "name": "CA_SV_CS1_TRIM", "shortDesc": "Control Surface 1 trim", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS1_TRQ_P", "shortDesc": "Control Surface 1 pitch torque scaling", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS1_TRQ_R", "shortDesc": "Control Surface 1 roll torque scaling", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS1_TRQ_Y", "shortDesc": "Control Surface 1 yaw torque scaling", "type": "Float"}, {"category": "Standard", "default": 0, "group": "Geometry", "name": "CA_SV_CS1_TYPE", "shortDesc": "Control Surface 1 type", "type": "Int32", "values": [{"description": "(Not set)", "value": 0}, {"description": "Left Aileron", "value": 1}, {"description": "Right Aileron", "value": 2}, {"description": "Elevator", "value": 3}, {"description": "Rudder", "value": 4}, {"description": "Left Elevon", "value": 5}, {"description": "Right Elevon", "value": 6}, {"description": "Left V-Tail", "value": 7}, {"description": "Right V-Tail", "value": 8}, {"description": "Left Flap", "value": 9}, {"description": "Right Flap", "value": 10}, {"description": "Airbrake", "value": 11}, {"description": "Custom", "value": 12}, {"description": "Left A-tail", "value": 13}, {"description": "Right A-tail", "value": 14}, {"description": "Single Channel Aileron", "value": 15}, {"description": "Steering Wheel", "value": 16}, {"description": "Left Spoiler", "value": 17}, {"description": "Right Spoiler", "value": 18}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "max": 1.0, "min": -1.0, "name": "CA_SV_CS2_FLAP", "shortDesc": "Control Surface 2 configuration as flap", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "max": 1.0, "min": -1.0, "name": "CA_SV_CS2_SPOIL", "shortDesc": "Control Surface 2 configuration as spoiler", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "longDesc": "Can be used to add an offset to the servo control.\n\nNOTE: Do not use for PWM servos. Use the PWM CENTER parameters instead (e.g., PWM_MAIN_CENT, PWM_AUX_CENT) instead.\nThis parameter can only be set if all PWM Center parameters are set to default.\n\n", "max": 1.0, "min": -1.0, "name": "CA_SV_CS2_TRIM", "shortDesc": "Control Surface 2 trim", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS2_TRQ_P", "shortDesc": "Control Surface 2 pitch torque scaling", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS2_TRQ_R", "shortDesc": "Control Surface 2 roll torque scaling", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS2_TRQ_Y", "shortDesc": "Control Surface 2 yaw torque scaling", "type": "Float"}, {"category": "Standard", "default": 0, "group": "Geometry", "name": "CA_SV_CS2_TYPE", "shortDesc": "Control Surface 2 type", "type": "Int32", "values": [{"description": "(Not set)", "value": 0}, {"description": "Left Aileron", "value": 1}, {"description": "Right Aileron", "value": 2}, {"description": "Elevator", "value": 3}, {"description": "Rudder", "value": 4}, {"description": "Left Elevon", "value": 5}, {"description": "Right Elevon", "value": 6}, {"description": "Left V-Tail", "value": 7}, {"description": "Right V-Tail", "value": 8}, {"description": "Left Flap", "value": 9}, {"description": "Right Flap", "value": 10}, {"description": "Airbrake", "value": 11}, {"description": "Custom", "value": 12}, {"description": "Left A-tail", "value": 13}, {"description": "Right A-tail", "value": 14}, {"description": "Single Channel Aileron", "value": 15}, {"description": "Steering Wheel", "value": 16}, {"description": "Left Spoiler", "value": 17}, {"description": "Right Spoiler", "value": 18}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "max": 1.0, "min": -1.0, "name": "CA_SV_CS3_FLAP", "shortDesc": "Control Surface 3 configuration as flap", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "max": 1.0, "min": -1.0, "name": "CA_SV_CS3_SPOIL", "shortDesc": "Control Surface 3 configuration as spoiler", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "longDesc": "Can be used to add an offset to the servo control.\n\nNOTE: Do not use for PWM servos. Use the PWM CENTER parameters instead (e.g., PWM_MAIN_CENT, PWM_AUX_CENT) instead.\nThis parameter can only be set if all PWM Center parameters are set to default.\n\n", "max": 1.0, "min": -1.0, "name": "CA_SV_CS3_TRIM", "shortDesc": "Control Surface 3 trim", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS3_TRQ_P", "shortDesc": "Control Surface 3 pitch torque scaling", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS3_TRQ_R", "shortDesc": "Control Surface 3 roll torque scaling", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS3_TRQ_Y", "shortDesc": "Control Surface 3 yaw torque scaling", "type": "Float"}, {"category": "Standard", "default": 0, "group": "Geometry", "name": "CA_SV_CS3_TYPE", "shortDesc": "Control Surface 3 type", "type": "Int32", "values": [{"description": "(Not set)", "value": 0}, {"description": "Left Aileron", "value": 1}, {"description": "Right Aileron", "value": 2}, {"description": "Elevator", "value": 3}, {"description": "Rudder", "value": 4}, {"description": "Left Elevon", "value": 5}, {"description": "Right Elevon", "value": 6}, {"description": "Left V-Tail", "value": 7}, {"description": "Right V-Tail", "value": 8}, {"description": "Left Flap", "value": 9}, {"description": "Right Flap", "value": 10}, {"description": "Airbrake", "value": 11}, {"description": "Custom", "value": 12}, {"description": "Left A-tail", "value": 13}, {"description": "Right A-tail", "value": 14}, {"description": "Single Channel Aileron", "value": 15}, {"description": "Steering Wheel", "value": 16}, {"description": "Left Spoiler", "value": 17}, {"description": "Right Spoiler", "value": 18}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "max": 1.0, "min": -1.0, "name": "CA_SV_CS4_FLAP", "shortDesc": "Control Surface 4 configuration as flap", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "max": 1.0, "min": -1.0, "name": "CA_SV_CS4_SPOIL", "shortDesc": "Control Surface 4 configuration as spoiler", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "longDesc": "Can be used to add an offset to the servo control.\n\nNOTE: Do not use for PWM servos. Use the PWM CENTER parameters instead (e.g., PWM_MAIN_CENT, PWM_AUX_CENT) instead.\nThis parameter can only be set if all PWM Center parameters are set to default.\n\n", "max": 1.0, "min": -1.0, "name": "CA_SV_CS4_TRIM", "shortDesc": "Control Surface 4 trim", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS4_TRQ_P", "shortDesc": "Control Surface 4 pitch torque scaling", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS4_TRQ_R", "shortDesc": "Control Surface 4 roll torque scaling", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS4_TRQ_Y", "shortDesc": "Control Surface 4 yaw torque scaling", "type": "Float"}, {"category": "Standard", "default": 0, "group": "Geometry", "name": "CA_SV_CS4_TYPE", "shortDesc": "Control Surface 4 type", "type": "Int32", "values": [{"description": "(Not set)", "value": 0}, {"description": "Left Aileron", "value": 1}, {"description": "Right Aileron", "value": 2}, {"description": "Elevator", "value": 3}, {"description": "Rudder", "value": 4}, {"description": "Left Elevon", "value": 5}, {"description": "Right Elevon", "value": 6}, {"description": "Left V-Tail", "value": 7}, {"description": "Right V-Tail", "value": 8}, {"description": "Left Flap", "value": 9}, {"description": "Right Flap", "value": 10}, {"description": "Airbrake", "value": 11}, {"description": "Custom", "value": 12}, {"description": "Left A-tail", "value": 13}, {"description": "Right A-tail", "value": 14}, {"description": "Single Channel Aileron", "value": 15}, {"description": "Steering Wheel", "value": 16}, {"description": "Left Spoiler", "value": 17}, {"description": "Right Spoiler", "value": 18}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "max": 1.0, "min": -1.0, "name": "CA_SV_CS5_FLAP", "shortDesc": "Control Surface 5 configuration as flap", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "max": 1.0, "min": -1.0, "name": "CA_SV_CS5_SPOIL", "shortDesc": "Control Surface 5 configuration as spoiler", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "longDesc": "Can be used to add an offset to the servo control.\n\nNOTE: Do not use for PWM servos. Use the PWM CENTER parameters instead (e.g., PWM_MAIN_CENT, PWM_AUX_CENT) instead.\nThis parameter can only be set if all PWM Center parameters are set to default.\n\n", "max": 1.0, "min": -1.0, "name": "CA_SV_CS5_TRIM", "shortDesc": "Control Surface 5 trim", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS5_TRQ_P", "shortDesc": "Control Surface 5 pitch torque scaling", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS5_TRQ_R", "shortDesc": "Control Surface 5 roll torque scaling", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS5_TRQ_Y", "shortDesc": "Control Surface 5 yaw torque scaling", "type": "Float"}, {"category": "Standard", "default": 0, "group": "Geometry", "name": "CA_SV_CS5_TYPE", "shortDesc": "Control Surface 5 type", "type": "Int32", "values": [{"description": "(Not set)", "value": 0}, {"description": "Left Aileron", "value": 1}, {"description": "Right Aileron", "value": 2}, {"description": "Elevator", "value": 3}, {"description": "Rudder", "value": 4}, {"description": "Left Elevon", "value": 5}, {"description": "Right Elevon", "value": 6}, {"description": "Left V-Tail", "value": 7}, {"description": "Right V-Tail", "value": 8}, {"description": "Left Flap", "value": 9}, {"description": "Right Flap", "value": 10}, {"description": "Airbrake", "value": 11}, {"description": "Custom", "value": 12}, {"description": "Left A-tail", "value": 13}, {"description": "Right A-tail", "value": 14}, {"description": "Single Channel Aileron", "value": 15}, {"description": "Steering Wheel", "value": 16}, {"description": "Left Spoiler", "value": 17}, {"description": "Right Spoiler", "value": 18}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "max": 1.0, "min": -1.0, "name": "CA_SV_CS6_FLAP", "shortDesc": "Control Surface 6 configuration as flap", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "max": 1.0, "min": -1.0, "name": "CA_SV_CS6_SPOIL", "shortDesc": "Control Surface 6 configuration as spoiler", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "longDesc": "Can be used to add an offset to the servo control.\n\nNOTE: Do not use for PWM servos. Use the PWM CENTER parameters instead (e.g., PWM_MAIN_CENT, PWM_AUX_CENT) instead.\nThis parameter can only be set if all PWM Center parameters are set to default.\n\n", "max": 1.0, "min": -1.0, "name": "CA_SV_CS6_TRIM", "shortDesc": "Control Surface 6 trim", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS6_TRQ_P", "shortDesc": "Control Surface 6 pitch torque scaling", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS6_TRQ_R", "shortDesc": "Control Surface 6 roll torque scaling", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS6_TRQ_Y", "shortDesc": "Control Surface 6 yaw torque scaling", "type": "Float"}, {"category": "Standard", "default": 0, "group": "Geometry", "name": "CA_SV_CS6_TYPE", "shortDesc": "Control Surface 6 type", "type": "Int32", "values": [{"description": "(Not set)", "value": 0}, {"description": "Left Aileron", "value": 1}, {"description": "Right Aileron", "value": 2}, {"description": "Elevator", "value": 3}, {"description": "Rudder", "value": 4}, {"description": "Left Elevon", "value": 5}, {"description": "Right Elevon", "value": 6}, {"description": "Left V-Tail", "value": 7}, {"description": "Right V-Tail", "value": 8}, {"description": "Left Flap", "value": 9}, {"description": "Right Flap", "value": 10}, {"description": "Airbrake", "value": 11}, {"description": "Custom", "value": 12}, {"description": "Left A-tail", "value": 13}, {"description": "Right A-tail", "value": 14}, {"description": "Single Channel Aileron", "value": 15}, {"description": "Steering Wheel", "value": 16}, {"description": "Left Spoiler", "value": 17}, {"description": "Right Spoiler", "value": 18}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "max": 1.0, "min": -1.0, "name": "CA_SV_CS7_FLAP", "shortDesc": "Control Surface 7 configuration as flap", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "max": 1.0, "min": -1.0, "name": "CA_SV_CS7_SPOIL", "shortDesc": "Control Surface 7 configuration as spoiler", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "longDesc": "Can be used to add an offset to the servo control.\n\nNOTE: Do not use for PWM servos. Use the PWM CENTER parameters instead (e.g., PWM_MAIN_CENT, PWM_AUX_CENT) instead.\nThis parameter can only be set if all PWM Center parameters are set to default.\n\n", "max": 1.0, "min": -1.0, "name": "CA_SV_CS7_TRIM", "shortDesc": "Control Surface 7 trim", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS7_TRQ_P", "shortDesc": "Control Surface 7 pitch torque scaling", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS7_TRQ_R", "shortDesc": "Control Surface 7 roll torque scaling", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS7_TRQ_Y", "shortDesc": "Control Surface 7 yaw torque scaling", "type": "Float"}, {"category": "Standard", "default": 0, "group": "Geometry", "name": "CA_SV_CS7_TYPE", "shortDesc": "Control Surface 7 type", "type": "Int32", "values": [{"description": "(Not set)", "value": 0}, {"description": "Left Aileron", "value": 1}, {"description": "Right Aileron", "value": 2}, {"description": "Elevator", "value": 3}, {"description": "Rudder", "value": 4}, {"description": "Left Elevon", "value": 5}, {"description": "Right Elevon", "value": 6}, {"description": "Left V-Tail", "value": 7}, {"description": "Right V-Tail", "value": 8}, {"description": "Left Flap", "value": 9}, {"description": "Right Flap", "value": 10}, {"description": "Airbrake", "value": 11}, {"description": "Custom", "value": 12}, {"description": "Left A-tail", "value": 13}, {"description": "Right A-tail", "value": 14}, {"description": "Single Channel Aileron", "value": 15}, {"description": "Steering Wheel", "value": 16}, {"description": "Left Spoiler", "value": 17}, {"description": "Right Spoiler", "value": 18}]}, {"category": "Standard", "default": 0, "group": "Geometry", "name": "CA_SV_CS_COUNT", "shortDesc": "Total number of Control Surfaces", "type": "Int32", "values": [{"description": "0", "value": 0}, {"description": "1", "value": 1}, {"description": "2", "value": 2}, {"description": "3", "value": 3}, {"description": "4", "value": 4}, {"description": "5", "value": 5}, {"description": "6", "value": 6}, {"description": "7", "value": 7}, {"description": "8", "value": 8}]}, {"category": "Standard", "decimalPlaces": 1, "default": 0.5, "group": "Geometry", "max": 5.0, "min": 0.0, "name": "CA_SV_FLAP_SLEW", "shortDesc": "Control Surface slew rate for normalized flaps setpoint", "type": "Float"}, {"category": "Standard", "default": 1, "group": "Geometry", "longDesc": "Define if this servo is used for additional control.\n", "name": "CA_SV_TL0_CT", "shortDesc": "Tilt 0 is used for control", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Yaw", "value": 1}, {"description": "Pitch", "value": 2}, {"description": "Yaw and Pitch", "value": 3}]}, {"category": "Standard", "decimalPlaces": 0, "default": 90.0, "group": "Geometry", "longDesc": "Defines the tilt angle when the servo is at the maximum.\nAn angle of zero means upwards.\n\n", "max": 90.0, "min": -90.0, "name": "CA_SV_TL0_MAXA", "shortDesc": "Tilt Servo 0 Tilt Angle at Maximum", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 0, "default": 0.0, "group": "Geometry", "longDesc": "Defines the tilt angle when the servo is at the minimum.\nAn angle of zero means upwards.\n\n", "max": 90.0, "min": -90.0, "name": "CA_SV_TL0_MINA", "shortDesc": "Tilt Servo 0 Tilt Angle at Minimum", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "Defines the direction the servo tilts towards when moving towards the maximum tilt angle.\nFor example if the minimum tilt angle is -90, the maximum 90, and the direction 'Towards Front',\nthe motor axis aligns with the XZ-plane, points towards -X at the minimum and +X at the maximum tilt.\n\n", "max": 359, "min": 0, "name": "CA_SV_TL0_TD", "shortDesc": "Tilt Servo 0 Tilt Direction", "type": "Int32", "values": [{"description": "Towards Front", "value": 0}, {"description": "Towards Right", "value": 90}]}, {"category": "Standard", "default": 1, "group": "Geometry", "longDesc": "Define if this servo is used for additional control.\n", "name": "CA_SV_TL1_CT", "shortDesc": "Tilt 1 is used for control", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Yaw", "value": 1}, {"description": "Pitch", "value": 2}, {"description": "Yaw and Pitch", "value": 3}]}, {"category": "Standard", "decimalPlaces": 0, "default": 90.0, "group": "Geometry", "longDesc": "Defines the tilt angle when the servo is at the maximum.\nAn angle of zero means upwards.\n\n", "max": 90.0, "min": -90.0, "name": "CA_SV_TL1_MAXA", "shortDesc": "Tilt Servo 1 Tilt Angle at Maximum", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 0, "default": 0.0, "group": "Geometry", "longDesc": "Defines the tilt angle when the servo is at the minimum.\nAn angle of zero means upwards.\n\n", "max": 90.0, "min": -90.0, "name": "CA_SV_TL1_MINA", "shortDesc": "Tilt Servo 1 Tilt Angle at Minimum", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "Defines the direction the servo tilts towards when moving towards the maximum tilt angle.\nFor example if the minimum tilt angle is -90, the maximum 90, and the direction 'Towards Front',\nthe motor axis aligns with the XZ-plane, points towards -X at the minimum and +X at the maximum tilt.\n\n", "max": 359, "min": 0, "name": "CA_SV_TL1_TD", "shortDesc": "Tilt Servo 1 Tilt Direction", "type": "Int32", "values": [{"description": "Towards Front", "value": 0}, {"description": "Towards Right", "value": 90}]}, {"category": "Standard", "default": 1, "group": "Geometry", "longDesc": "Define if this servo is used for additional control.\n", "name": "CA_SV_TL2_CT", "shortDesc": "Tilt 2 is used for control", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Yaw", "value": 1}, {"description": "Pitch", "value": 2}, {"description": "Yaw and Pitch", "value": 3}]}, {"category": "Standard", "decimalPlaces": 0, "default": 90.0, "group": "Geometry", "longDesc": "Defines the tilt angle when the servo is at the maximum.\nAn angle of zero means upwards.\n\n", "max": 90.0, "min": -90.0, "name": "CA_SV_TL2_MAXA", "shortDesc": "Tilt Servo 2 Tilt Angle at Maximum", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 0, "default": 0.0, "group": "Geometry", "longDesc": "Defines the tilt angle when the servo is at the minimum.\nAn angle of zero means upwards.\n\n", "max": 90.0, "min": -90.0, "name": "CA_SV_TL2_MINA", "shortDesc": "Tilt Servo 2 Tilt Angle at Minimum", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "Defines the direction the servo tilts towards when moving towards the maximum tilt angle.\nFor example if the minimum tilt angle is -90, the maximum 90, and the direction 'Towards Front',\nthe motor axis aligns with the XZ-plane, points towards -X at the minimum and +X at the maximum tilt.\n\n", "max": 359, "min": 0, "name": "CA_SV_TL2_TD", "shortDesc": "Tilt Servo 2 Tilt Direction", "type": "Int32", "values": [{"description": "Towards Front", "value": 0}, {"description": "Towards Right", "value": 90}]}, {"category": "Standard", "default": 1, "group": "Geometry", "longDesc": "Define if this servo is used for additional control.\n", "name": "CA_SV_TL3_CT", "shortDesc": "Tilt 3 is used for control", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Yaw", "value": 1}, {"description": "Pitch", "value": 2}, {"description": "Yaw and Pitch", "value": 3}]}, {"category": "Standard", "decimalPlaces": 0, "default": 90.0, "group": "Geometry", "longDesc": "Defines the tilt angle when the servo is at the maximum.\nAn angle of zero means upwards.\n\n", "max": 90.0, "min": -90.0, "name": "CA_SV_TL3_MAXA", "shortDesc": "Tilt Servo 3 Tilt Angle at Maximum", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 0, "default": 0.0, "group": "Geometry", "longDesc": "Defines the tilt angle when the servo is at the minimum.\nAn angle of zero means upwards.\n\n", "max": 90.0, "min": -90.0, "name": "CA_SV_TL3_MINA", "shortDesc": "Tilt Servo 3 Tilt Angle at Minimum", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "Defines the direction the servo tilts towards when moving towards the maximum tilt angle.\nFor example if the minimum tilt angle is -90, the maximum 90, and the direction 'Towards Front',\nthe motor axis aligns with the XZ-plane, points towards -X at the minimum and +X at the maximum tilt.\n\n", "max": 359, "min": 0, "name": "CA_SV_TL3_TD", "shortDesc": "Tilt Servo 3 Tilt Direction", "type": "Int32", "values": [{"description": "Towards Front", "value": 0}, {"description": "Towards Right", "value": 90}]}, {"category": "Standard", "default": 0, "group": "Geometry", "name": "CA_SV_TL_COUNT", "shortDesc": "Total number of Tilt Servos", "type": "Int32", "values": [{"description": "0", "value": 0}, {"description": "1", "value": 1}, {"description": "2", "value": 2}, {"description": "3", "value": 3}, {"description": "4", "value": 4}]}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "Hover Thrust Estimator", "longDesc": "Sets the number of standard deviations used\nby the innovation consistency test.\n", "max": 10.0, "min": 1.0, "name": "HTE_ACC_GATE", "shortDesc": "Gate size for acceleration fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.1, "group": "Hover Thrust Estimator", "longDesc": "Initial standard deviation of the hover thrust state estimate.\nLarger values allow the estimate to move farther from the initial\nhover thrust before process noise takes over.\n", "max": 1.0, "min": 0.0, "name": "HTE_HT_ERR_INIT", "shortDesc": "1-sigma initial hover thrust uncertainty", "type": "Float", "units": "normalized_thrust"}, {"category": "Standard", "decimalPlaces": 4, "default": 0.0036, "group": "Hover Thrust Estimator", "longDesc": "Reduce to make the hover thrust estimate\nmore stable, increase if the real hover thrust\nis expected to change quickly over time.\n", "max": 1.0, "min": 0.0001, "name": "HTE_HT_NOISE", "shortDesc": "Hover thrust process noise", "type": "Float", "units": "normalized_thrust/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.2, "group": "Hover Thrust Estimator", "longDesc": "Defines the range of the hover thrust estimate around MPC_THR_HOVER.\nA value of 0.2 with MPC_THR_HOVER at 0.5 results in a range of [0.3, 0.7].\n\nSet to a large value if the vehicle operates in varying physical conditions that\naffect the required hover thrust strongly (e.g. differently sized payloads).\n", "max": 0.4, "min": 0.01, "name": "HTE_THR_RANGE", "shortDesc": "Max deviation from MPC_THR_HOVER", "type": "Float", "units": "normalized_thrust"}, {"category": "Standard", "decimalPlaces": 1, "default": 10.0, "group": "Hover Thrust Estimator", "longDesc": "Above this speed, the measurement noise is linearly increased\nto reduce the sensitivity of the estimator from biased measurement.\n\nSet to a low value on vehicles with large lifting surfaces.\n", "max": 20.0, "min": 1.0, "name": "HTE_VXY_THR", "shortDesc": "Horizontal velocity threshold for sensitivity reduction", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 2.0, "group": "Hover Thrust Estimator", "longDesc": "Above this speed, the measurement noise is linearly increased\nto reduce the sensitivity of the estimator from biased measurement.\n\nSet to a low value on vehicles affected by air drag when climbing or descending.\n", "max": 10.0, "min": 1.0, "name": "HTE_VZ_THR", "shortDesc": "Vertical velocity threshold for sensitivity reduction", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 6.0, "group": "Land Detector", "longDesc": "Maximum airspeed allowed in the landed state\n", "max": 30.0, "min": 2.0, "name": "LNDFW_AIRSPD_MAX", "shortDesc": "Fixed-wing land detector: Max airspeed", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.5, "group": "Land Detector", "longDesc": "Maximum allowed norm of the angular velocity in the landed state.\nOnly used if neither airspeed nor groundspeed can be used for landing detection.\n", "name": "LNDFW_ROT_MAX", "shortDesc": "Fixed-wing land detector: max rotational speed", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 2.0, "group": "Land Detector", "longDesc": "Time the land conditions (speeds and acceleration) have to be satisfied to detect a landing.\n", "min": 0.1, "name": "LNDFW_TRIG_TIME", "rebootRequired": true, "shortDesc": "Fixed-wing land detection trigger time", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "Land Detector", "longDesc": "Maximum horizontal velocity allowed in the landed state.\nA factor of 0.7 is applied in case of airspeed-less flying\n(either because no sensor is present or sensor data got invalid in flight).\n", "max": 20.0, "min": 0.5, "name": "LNDFW_VEL_XY_MAX", "shortDesc": "Fixed-wing land detector: Max horizontal velocity threshold", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.0, "group": "Land Detector", "longDesc": "Maximum vertical velocity allowed in the landed state.\n", "max": 20.0, "min": 0.1, "name": "LNDFW_VEL_Z_MAX", "shortDesc": "Fixed-wing land detector: Max vertiacal velocity threshold", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 8.0, "group": "Land Detector", "longDesc": "Maximum gravity-compensated horizontal (earth frame) acceleration allowed in the landed state.\n", "max": 30.0, "min": 2.0, "name": "LNDFW_XYACC_MAX", "shortDesc": "Fixed-wing land detector: Max horizontal acceleration", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "decimalPlaces": 2, "default": 2.0, "group": "Land Detector", "longDesc": "The height above ground below which ground effect creates barometric altitude errors.\nA negative value indicates no ground effect.\n", "min": -1.0, "name": "LNDMC_ALT_GND", "shortDesc": "Ground effect altitude for multicopters", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 20.0, "group": "Land Detector", "longDesc": "Maximum allowed norm of the angular velocity (roll, pitch) in the landed state.\n", "name": "LNDMC_ROT_MAX", "shortDesc": "Multicopter max rotational speed", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.5, "group": "Land Detector", "longDesc": "Maximum horizontal velocity allowed in the landed state\n", "name": "LNDMC_XY_VEL_MAX", "shortDesc": "Multicopter max horizontal velocity", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.25, "group": "Land Detector", "longDesc": "Vertical velocity threshold to detect landing.\nHas to be set lower than the expected minimal speed for landing,\nwhich is either MPC_LAND_SPEED or MPC_LAND_CRWL.\nThis is enforced by an automatic check.\n", "min": 0.0, "name": "LNDMC_Z_VEL_MAX", "shortDesc": "Multicopter vertical velocity threshold", "type": "Float", "units": "m/s"}, {"category": "System", "default": 0, "group": "Land Detector", "longDesc": "Total flight time of this autopilot. Higher 32 bits of the value.\nFlight time in microseconds = (LND_FLIGHT_T_HI << 32) | LND_FLIGHT_T_LO.\n", "min": 0, "name": "LND_FLIGHT_T_HI", "shortDesc": "Total flight time in microseconds", "type": "Int32", "volatile": true}, {"category": "System", "default": 0, "group": "Land Detector", "longDesc": "Total flight time of this autopilot. Lower 32 bits of the value.\nFlight time in microseconds = (LND_FLIGHT_T_HI << 32) | LND_FLIGHT_T_LO.\n", "min": 0, "name": "LND_FLIGHT_T_LO", "shortDesc": "Total flight time in microseconds", "type": "Int32", "volatile": true}, {"category": "Standard", "decimalPlaces": 5, "default": 0.012, "group": "Local Position Estimator", "longDesc": "Data sheet noise density = 150ug/sqrt(Hz) = 0.0015 m/s^2/sqrt(Hz)\n\nLarger than data sheet to account for tilt error.\n", "max": 2.0, "min": 1e-05, "name": "LPE_ACC_XY", "shortDesc": "Accelerometer xy noise density", "type": "Float", "units": "m/s^2/sqrt(Hz)"}, {"category": "Standard", "decimalPlaces": 5, "default": 0.02, "group": "Local Position Estimator", "longDesc": "Data sheet noise density = 150ug/sqrt(Hz) = 0.0015 m/s^2/sqrt(Hz)\n", "max": 2.0, "min": 1e-05, "name": "LPE_ACC_Z", "shortDesc": "Accelerometer z noise density", "type": "Float", "units": "m/s^2/sqrt(Hz)"}, {"category": "Standard", "decimalPlaces": 2, "default": 3.0, "group": "Local Position Estimator", "max": 100.0, "min": 0.01, "name": "LPE_BAR_Z", "shortDesc": "Barometric pressure altitude z standard deviation", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Local Position Estimator", "name": "LPE_EN", "shortDesc": "Local position estimator enable (unsupported)", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 3, "default": 3.0, "group": "Local Position Estimator", "max": 5.0, "min": 1.0, "name": "LPE_EPH_MAX", "shortDesc": "Max EPH allowed for GPS initialization", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 5.0, "group": "Local Position Estimator", "max": 5.0, "min": 1.0, "name": "LPE_EPV_MAX", "shortDesc": "Max EPV allowed for GPS initialization", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Local Position Estimator", "longDesc": "Enable publishing of a fake global position (e.g for AUTO missions using Optical Flow)\n\nBy initializing the estimator to the LPE_LAT/LON parameters when global information is unavailable\n", "max": 1, "min": 0, "name": "LPE_FAKE_ORIGIN", "shortDesc": "Enable fake global position for optical flow", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.001, "group": "Local Position Estimator", "max": 2.0, "min": 0.0, "name": "LPE_FGYRO_HP", "shortDesc": "Flow gyro high pass filter cut off frequency", "type": "Float", "units": "Hz"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Local Position Estimator", "max": 1.0, "min": -1.0, "name": "LPE_FLW_OFF_Z", "shortDesc": "Optical flow z offset from center", "type": "Float", "units": "m"}, {"category": "Standard", "default": 150, "group": "Local Position Estimator", "max": 255, "min": 0, "name": "LPE_FLW_QMIN", "shortDesc": "Optical flow minimum quality threshold", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 3, "default": 7.0, "group": "Local Position Estimator", "max": 10.0, "min": 0.1, "name": "LPE_FLW_R", "shortDesc": "Optical flow rotation (roll/pitch) noise gain", "type": "Float", "units": "m/s/rad"}, {"category": "Standard", "decimalPlaces": 3, "default": 7.0, "group": "Local Position Estimator", "max": 10.0, "min": 0.0, "name": "LPE_FLW_RR", "shortDesc": "Optical flow angular velocity noise gain", "type": "Float", "units": "m/rad"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.3, "group": "Local Position Estimator", "max": 10.0, "min": 0.1, "name": "LPE_FLW_SCALE", "shortDesc": "Optical flow scale", "type": "Float", "units": "m"}, {"bitmask": [{"description": "fuse GPS, requires GPS for alt. init", "index": 0}, {"description": "fuse optical flow", "index": 1}, {"description": "fuse vision position", "index": 2}, {"description": "fuse landing target", "index": 3}, {"description": "fuse land detector", "index": 4}, {"description": "pub agl as lpos down", "index": 5}, {"description": "flow gyro compensation", "index": 6}, {"description": "fuse baro", "index": 7}], "category": "Standard", "default": 145, "group": "Local Position Estimator", "longDesc": "Set bits in the following positions to enable:\n0 : Set to true to fuse GPS data if available, also requires GPS for altitude init\n1 : Set to true to fuse optical flow data if available\n2 : Set to true to fuse vision position\n3 : Set to true to enable landing target\n4 : Set to true to fuse land detector\n5 : Set to true to publish AGL as local position down component\n6 : Set to true to enable flow gyro compensation\n7 : Set to true to enable baro fusion\n\ndefault (145 - GPS, baro, land detector)\n", "max": 255, "min": 0, "name": "LPE_FUSION", "shortDesc": "Integer bitmask controlling data fusion", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.29, "group": "Local Position Estimator", "max": 0.4, "min": 0.0, "name": "LPE_GPS_DELAY", "shortDesc": "GPS delay compensation", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.25, "group": "Local Position Estimator", "longDesc": "EPV used if greater than this value.\n", "max": 2.0, "min": 0.01, "name": "LPE_GPS_VXY", "shortDesc": "GPS xy velocity standard deviation", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.25, "group": "Local Position Estimator", "max": 2.0, "min": 0.01, "name": "LPE_GPS_VZ", "shortDesc": "GPS z velocity standard deviation", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Local Position Estimator", "max": 5.0, "min": 0.01, "name": "LPE_GPS_XY", "shortDesc": "Minimum GPS xy standard deviation, uses reported EPH if greater", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 3.0, "group": "Local Position Estimator", "max": 200.0, "min": 0.01, "name": "LPE_GPS_Z", "shortDesc": "Minimum GPS z standard deviation, uses reported EPV if greater", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "Local Position Estimator", "max": 10.0, "min": 0.01, "name": "LPE_LAND_VXY", "shortDesc": "Land detector xy velocity standard deviation", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.03, "group": "Local Position Estimator", "max": 10.0, "min": 0.001, "name": "LPE_LAND_Z", "shortDesc": "Land detector z standard deviation", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 8, "default": 47.397742, "group": "Local Position Estimator", "max": 90.0, "min": -90.0, "name": "LPE_LAT", "shortDesc": "Local origin latitude for nav w/o GPS", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Local Position Estimator", "max": 1.0, "min": -1.0, "name": "LPE_LDR_OFF_Z", "shortDesc": "Lidar z offset from center of vehicle +down", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.03, "group": "Local Position Estimator", "max": 1.0, "min": 0.01, "name": "LPE_LDR_Z", "shortDesc": "Lidar z standard deviation", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 8, "default": 8.545594, "group": "Local Position Estimator", "max": 180.0, "min": -180.0, "name": "LPE_LON", "shortDesc": "Local origin longitude for nav w/o GPS", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 4, "default": 0.0001, "group": "Local Position Estimator", "longDesc": "Minimum landing target standard covariance, uses reported covariance if greater\n", "max": 10.0, "min": 0.0, "name": "LPE_LT_COV", "shortDesc": "Minimum landing target standard covariance", "type": "Float", "units": "m^2"}, {"category": "Standard", "decimalPlaces": 8, "default": 0.001, "group": "Local Position Estimator", "max": 1.0, "min": 0.0, "name": "LPE_PN_B", "shortDesc": "Accel bias propagation noise density", "type": "Float", "units": "m/s^3/sqrt(Hz)"}, {"category": "Standard", "decimalPlaces": 8, "default": 0.1, "group": "Local Position Estimator", "longDesc": "Increase to trust measurements more.\nDecrease to trust model more.\n", "max": 1.0, "min": 0.0, "name": "LPE_PN_P", "shortDesc": "Position propagation noise density", "type": "Float", "units": "m/s/sqrt(Hz)"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.001, "group": "Local Position Estimator", "longDesc": "Terrain random walk noise density, hilly/outdoor (0.1), flat/Indoor (0.001)\n", "max": 1.0, "min": 0.0, "name": "LPE_PN_T", "shortDesc": "Terrain random walk noise density", "type": "Float", "units": "m/s/sqrt(Hz)"}, {"category": "Standard", "decimalPlaces": 8, "default": 0.1, "group": "Local Position Estimator", "longDesc": "Increase to trust measurements more.\nDecrease to trust model more.\n", "max": 1.0, "min": 0.0, "name": "LPE_PN_V", "shortDesc": "Velocity propagation noise density", "type": "Float", "units": "m/s^2/sqrt(Hz)"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Local Position Estimator", "max": 1.0, "min": -1.0, "name": "LPE_SNR_OFF_Z", "shortDesc": "Sonar z offset from center of vehicle +down", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "Local Position Estimator", "max": 1.0, "min": 0.01, "name": "LPE_SNR_Z", "shortDesc": "Sonar z standard deviation", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "Local Position Estimator", "longDesc": "Terrain maximum percent grade, hilly/outdoor (100 = 45 deg), flat/Indoor (0 = 0 deg)\n\nUsed to calculate increased terrain random walk noise due to movement.\n", "max": 100.0, "min": 0.0, "name": "LPE_T_MAX_GRADE", "shortDesc": "Terrain maximum percent grade", "type": "Float", "units": "%"}, {"category": "Standard", "decimalPlaces": 4, "default": 0.001, "group": "Local Position Estimator", "max": 1.0, "min": 0.0001, "name": "LPE_VIC_P", "shortDesc": "Vicon position standard deviation", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "Local Position Estimator", "longDesc": "Set to zero to enable automatic compensation from measurement timestamps\n", "max": 0.1, "min": 0.0, "name": "LPE_VIS_DELAY", "shortDesc": "Vision delay compensation", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.1, "group": "Local Position Estimator", "max": 1.0, "min": 0.01, "name": "LPE_VIS_XY", "shortDesc": "Vision xy standard deviation", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.5, "group": "Local Position Estimator", "max": 100.0, "min": 0.01, "name": "LPE_VIS_Z", "shortDesc": "Vision z standard deviation", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.3, "group": "Local Position Estimator", "max": 1.0, "min": 0.01, "name": "LPE_VXY_PUB", "shortDesc": "Required velocity xy standard deviation to publish position", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 0, "default": 5.0, "group": "Local Position Estimator", "max": 1000.0, "min": 5.0, "name": "LPE_X_LP", "shortDesc": "Cut frequency for state publication", "type": "Float", "units": "Hz"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.0, "group": "Local Position Estimator", "max": 5.0, "min": 0.3, "name": "LPE_Z_PUB", "shortDesc": "Required z standard deviation to publish altitude/ terrain", "type": "Float", "units": "m"}, {"category": "Standard", "default": 1, "group": "MAVLink", "longDesc": "This allows a ground control station to automatically find the drone\non the local network.\n\n", "name": "MAV_0_BROADCAST", "shortDesc": "Broadcast heartbeats on local network for MAVLink instance 0", "type": "Int32", "values": [{"description": "Never broadcast", "value": 0}, {"description": "Always broadcast", "value": 1}, {"description": "Only multicast", "value": 2}]}, {"category": "Standard", "default": 2, "group": "MAVLink", "longDesc": "This is used to force flow control on or off for the the mavlink\ninstance. By default it is auto detected. Use when auto detection fails.\n\n", "name": "MAV_0_FLOW_CTRL", "rebootRequired": true, "shortDesc": "Enable serial flow control for instance 0", "type": "Int32", "values": [{"description": "Force off", "value": 0}, {"description": "Force on", "value": 1}, {"description": "Auto-detected", "value": 2}]}, {"category": "Standard", "default": 1, "group": "MAVLink", "longDesc": "If enabled, forward incoming MAVLink messages to other MAVLink ports if the\nmessage is either broadcast or the target is not the autopilot.\n\nThis allows for example a GCS to talk to a camera that is connected to the\nautopilot via MAVLink (on a different link than the GCS).\n\n", "name": "MAV_0_FORWARD", "rebootRequired": true, "shortDesc": "Enable MAVLink Message forwarding for instance 0", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 3, "default": 0.015, "group": "MAVLink", "increment": 0.001, "longDesc": "Positive real value that configures the transmission frequency of the\nHIGH_LATENCY2 stream for instance 0, configured in iridium mode.\nThis parameter has no effect if the instance mode is different from iridium.\n\n", "max": 50.0, "min": 0.0, "name": "MAV_0_HL_FREQ", "rebootRequired": true, "shortDesc": "Configures the frequency of HIGH_LATENCY2 stream for instance 0", "type": "Float", "units": "Hz"}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "The MAVLink Mode defines the set of streamed messages (for example the\nvehicle's attitude) and their sending rates.\n\nUse ADS-B/Traffic for a traffic receiver such as an ADS-B or FLARM\ndevice. With message signing active, unsigned ADSB_VEHICLE and\nCOLLISION messages are only accepted on links in this mode.\n\n", "name": "MAV_0_MODE", "rebootRequired": true, "shortDesc": "MAVLink Mode for instance 0", "type": "Int32", "values": [{"description": "Normal", "value": 0}, {"description": "Custom", "value": 1}, {"description": "Onboard", "value": 2}, {"description": "OSD", "value": 3}, {"description": "Magic", "value": 4}, {"description": "Config", "value": 5}, {"description": "Minimal", "value": 7}, {"description": "External Vision", "value": 8}, {"description": "Gimbal", "value": 10}, {"description": "Onboard Low Bandwidth", "value": 11}, {"description": "ADS-B/Traffic (uAvionix)", "value": 12}, {"description": "Low Bandwidth", "value": 13}]}, {"category": "Standard", "default": 1, "group": "MAVLink", "longDesc": "If enabled, MAVLink messages will be throttled according to\n`txbuf` field reported by radio_status.\n\nRequires a radio to send the mavlink message RADIO_STATUS.\n\n", "name": "MAV_0_RADIO_CTL", "rebootRequired": true, "shortDesc": "Enable software throttling of mavlink on instance 0", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 2000, "group": "MAVLink", "longDesc": "Configure the maximum sending rate for the MAVLink streams in Bytes/sec.\nIf the configured streams exceed the maximum rate, the sending rate of\neach stream is automatically decreased.\n\nIf this is set to 0 a value of half of the theoretical maximum bandwidth is used.\nThis corresponds to baudrate/20 Bytes/s (baudrate/10 = maximum data rate on\n8N1-configured links). USB and UDP links have no baudrate, so for those 0\nmeans 100000 Bytes/s.\n\nNote that for a telemetry radio the serial baudrate says little about what\nthe link can actually carry over the air. A SiK radio at the common 57600\nbaud, 64 kbps air rate carries roughly 2000 B/s with error correction\nenabled and about twice that without, where baudrate/20 would suggest 2880.\nInstance 0 therefore defaults to a fixed value that is safe either way\nrather than to 0. Raise it if you know your link is better.\n\n", "min": 0, "name": "MAV_0_RATE", "rebootRequired": true, "shortDesc": "Maximum MAVLink sending rate for instance 0", "type": "Int32", "units": "B/s"}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "Messages go to this address at port MAV_0_REMOTE_PRT. Encoded as int32\nwith the first octet in the most significant byte, e.g. 192.168.1.2 is -1062731518.\nSet to 0 to discover the partner from received packets.\n\n", "name": "MAV_0_REMOTE_IP", "rebootRequired": true, "shortDesc": "MAVLink Partner IP for instance 0", "type": "Int32"}, {"category": "Standard", "default": 14550, "group": "MAVLink", "longDesc": "If ethernet enabled and selected as configuration for MAVLink instance 0,\nselected remote port will be set and used in MAVLink instance 0.\n\n", "name": "MAV_0_REMOTE_PRT", "rebootRequired": true, "shortDesc": "MAVLink Remote Port for instance 0", "type": "Int32"}, {"category": "Standard", "default": 14556, "group": "MAVLink", "longDesc": "If ethernet enabled and selected as configuration for MAVLink instance 0,\nselected udp port will be set and used in MAVLink instance 0.\n\n", "name": "MAV_0_UDP_PRT", "rebootRequired": true, "shortDesc": "MAVLink Network Port for instance 0", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "This allows a ground control station to automatically find the drone\non the local network.\n\n", "name": "MAV_1_BROADCAST", "shortDesc": "Broadcast heartbeats on local network for MAVLink instance 1", "type": "Int32", "values": [{"description": "Never broadcast", "value": 0}, {"description": "Always broadcast", "value": 1}, {"description": "Only multicast", "value": 2}]}, {"category": "Standard", "default": 2, "group": "MAVLink", "longDesc": "This is used to force flow control on or off for the the mavlink\ninstance. By default it is auto detected. Use when auto detection fails.\n\n", "name": "MAV_1_FLOW_CTRL", "rebootRequired": true, "shortDesc": "Enable serial flow control for instance 1", "type": "Int32", "values": [{"description": "Force off", "value": 0}, {"description": "Force on", "value": 1}, {"description": "Auto-detected", "value": 2}]}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "If enabled, forward incoming MAVLink messages to other MAVLink ports if the\nmessage is either broadcast or the target is not the autopilot.\n\nThis allows for example a GCS to talk to a camera that is connected to the\nautopilot via MAVLink (on a different link than the GCS).\n\n", "name": "MAV_1_FORWARD", "rebootRequired": true, "shortDesc": "Enable MAVLink Message forwarding for instance 1", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 3, "default": 0.015, "group": "MAVLink", "increment": 0.001, "longDesc": "Positive real value that configures the transmission frequency of the\nHIGH_LATENCY2 stream for instance 1, configured in iridium mode.\nThis parameter has no effect if the instance mode is different from iridium.\n\n", "max": 50.0, "min": 0.0, "name": "MAV_1_HL_FREQ", "rebootRequired": true, "shortDesc": "Configures the frequency of HIGH_LATENCY2 stream for instance 1", "type": "Float", "units": "Hz"}, {"category": "Standard", "default": 2, "group": "MAVLink", "longDesc": "The MAVLink Mode defines the set of streamed messages (for example the\nvehicle's attitude) and their sending rates.\n\nUse ADS-B/Traffic for a traffic receiver such as an ADS-B or FLARM\ndevice. With message signing active, unsigned ADSB_VEHICLE and\nCOLLISION messages are only accepted on links in this mode.\n\n", "name": "MAV_1_MODE", "rebootRequired": true, "shortDesc": "MAVLink Mode for instance 1", "type": "Int32", "values": [{"description": "Normal", "value": 0}, {"description": "Custom", "value": 1}, {"description": "Onboard", "value": 2}, {"description": "OSD", "value": 3}, {"description": "Magic", "value": 4}, {"description": "Config", "value": 5}, {"description": "Minimal", "value": 7}, {"description": "External Vision", "value": 8}, {"description": "Gimbal", "value": 10}, {"description": "Onboard Low Bandwidth", "value": 11}, {"description": "ADS-B/Traffic (uAvionix)", "value": 12}, {"description": "Low Bandwidth", "value": 13}]}, {"category": "Standard", "default": 1, "group": "MAVLink", "longDesc": "If enabled, MAVLink messages will be throttled according to\n`txbuf` field reported by radio_status.\n\nRequires a radio to send the mavlink message RADIO_STATUS.\n\n", "name": "MAV_1_RADIO_CTL", "rebootRequired": true, "shortDesc": "Enable software throttling of mavlink on instance 1", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "Configure the maximum sending rate for the MAVLink streams in Bytes/sec.\nIf the configured streams exceed the maximum rate, the sending rate of\neach stream is automatically decreased.\n\nIf this is set to 0 a value of half of the theoretical maximum bandwidth is used.\nThis corresponds to baudrate/20 Bytes/s (baudrate/10 = maximum data rate on\n8N1-configured links). USB and UDP links have no baudrate, so for those 0\nmeans 100000 Bytes/s.\n\nNote that for a telemetry radio the serial baudrate says little about what\nthe link can actually carry over the air. A SiK radio at the common 57600\nbaud, 64 kbps air rate carries roughly 2000 B/s with error correction\nenabled and about twice that without, where baudrate/20 would suggest 2880.\nInstance 0 therefore defaults to a fixed value that is safe either way\nrather than to 0. Raise it if you know your link is better.\n\n", "min": 0, "name": "MAV_1_RATE", "rebootRequired": true, "shortDesc": "Maximum MAVLink sending rate for instance 1", "type": "Int32", "units": "B/s"}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "Messages go to this address at port MAV_1_REMOTE_PRT. Encoded as int32\nwith the first octet in the most significant byte, e.g. 192.168.1.2 is -1062731518.\nSet to 0 to discover the partner from received packets.\n\n", "name": "MAV_1_REMOTE_IP", "rebootRequired": true, "shortDesc": "MAVLink Partner IP for instance 1", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "If ethernet enabled and selected as configuration for MAVLink instance 1,\nselected remote port will be set and used in MAVLink instance 1.\n\n", "name": "MAV_1_REMOTE_PRT", "rebootRequired": true, "shortDesc": "MAVLink Remote Port for instance 1", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "If ethernet enabled and selected as configuration for MAVLink instance 1,\nselected udp port will be set and used in MAVLink instance 1.\n\n", "name": "MAV_1_UDP_PRT", "rebootRequired": true, "shortDesc": "MAVLink Network Port for instance 1", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "This allows a ground control station to automatically find the drone\non the local network.\n\n", "name": "MAV_2_BROADCAST", "shortDesc": "Broadcast heartbeats on local network for MAVLink instance 2", "type": "Int32", "values": [{"description": "Never broadcast", "value": 0}, {"description": "Always broadcast", "value": 1}, {"description": "Only multicast", "value": 2}]}, {"category": "Standard", "default": 2, "group": "MAVLink", "longDesc": "This is used to force flow control on or off for the the mavlink\ninstance. By default it is auto detected. Use when auto detection fails.\n\n", "name": "MAV_2_FLOW_CTRL", "rebootRequired": true, "shortDesc": "Enable serial flow control for instance 2", "type": "Int32", "values": [{"description": "Force off", "value": 0}, {"description": "Force on", "value": 1}, {"description": "Auto-detected", "value": 2}]}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "If enabled, forward incoming MAVLink messages to other MAVLink ports if the\nmessage is either broadcast or the target is not the autopilot.\n\nThis allows for example a GCS to talk to a camera that is connected to the\nautopilot via MAVLink (on a different link than the GCS).\n\n", "name": "MAV_2_FORWARD", "rebootRequired": true, "shortDesc": "Enable MAVLink Message forwarding for instance 2", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 3, "default": 0.015, "group": "MAVLink", "increment": 0.001, "longDesc": "Positive real value that configures the transmission frequency of the\nHIGH_LATENCY2 stream for instance 2, configured in iridium mode.\nThis parameter has no effect if the instance mode is different from iridium.\n\n", "max": 50.0, "min": 0.0, "name": "MAV_2_HL_FREQ", "rebootRequired": true, "shortDesc": "Configures the frequency of HIGH_LATENCY2 stream for instance 2", "type": "Float", "units": "Hz"}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "The MAVLink Mode defines the set of streamed messages (for example the\nvehicle's attitude) and their sending rates.\n\nUse ADS-B/Traffic for a traffic receiver such as an ADS-B or FLARM\ndevice. With message signing active, unsigned ADSB_VEHICLE and\nCOLLISION messages are only accepted on links in this mode.\n\n", "name": "MAV_2_MODE", "rebootRequired": true, "shortDesc": "MAVLink Mode for instance 2", "type": "Int32", "values": [{"description": "Normal", "value": 0}, {"description": "Custom", "value": 1}, {"description": "Onboard", "value": 2}, {"description": "OSD", "value": 3}, {"description": "Magic", "value": 4}, {"description": "Config", "value": 5}, {"description": "Minimal", "value": 7}, {"description": "External Vision", "value": 8}, {"description": "Gimbal", "value": 10}, {"description": "Onboard Low Bandwidth", "value": 11}, {"description": "ADS-B/Traffic (uAvionix)", "value": 12}, {"description": "Low Bandwidth", "value": 13}]}, {"category": "Standard", "default": 1, "group": "MAVLink", "longDesc": "If enabled, MAVLink messages will be throttled according to\n`txbuf` field reported by radio_status.\n\nRequires a radio to send the mavlink message RADIO_STATUS.\n\n", "name": "MAV_2_RADIO_CTL", "rebootRequired": true, "shortDesc": "Enable software throttling of mavlink on instance 2", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "Configure the maximum sending rate for the MAVLink streams in Bytes/sec.\nIf the configured streams exceed the maximum rate, the sending rate of\neach stream is automatically decreased.\n\nIf this is set to 0 a value of half of the theoretical maximum bandwidth is used.\nThis corresponds to baudrate/20 Bytes/s (baudrate/10 = maximum data rate on\n8N1-configured links). USB and UDP links have no baudrate, so for those 0\nmeans 100000 Bytes/s.\n\nNote that for a telemetry radio the serial baudrate says little about what\nthe link can actually carry over the air. A SiK radio at the common 57600\nbaud, 64 kbps air rate carries roughly 2000 B/s with error correction\nenabled and about twice that without, where baudrate/20 would suggest 2880.\nInstance 0 therefore defaults to a fixed value that is safe either way\nrather than to 0. Raise it if you know your link is better.\n\n", "min": 0, "name": "MAV_2_RATE", "rebootRequired": true, "shortDesc": "Maximum MAVLink sending rate for instance 2", "type": "Int32", "units": "B/s"}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "Messages go to this address at port MAV_2_REMOTE_PRT. Encoded as int32\nwith the first octet in the most significant byte, e.g. 192.168.1.2 is -1062731518.\nSet to 0 to discover the partner from received packets.\n\n", "name": "MAV_2_REMOTE_IP", "rebootRequired": true, "shortDesc": "MAVLink Partner IP for instance 2", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "If ethernet enabled and selected as configuration for MAVLink instance 2,\nselected remote port will be set and used in MAVLink instance 2.\n\n", "name": "MAV_2_REMOTE_PRT", "rebootRequired": true, "shortDesc": "MAVLink Remote Port for instance 2", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "If ethernet enabled and selected as configuration for MAVLink instance 2,\nselected udp port will be set and used in MAVLink instance 2.\n\n", "name": "MAV_2_UDP_PRT", "rebootRequired": true, "shortDesc": "MAVLink Network Port for instance 2", "type": "Int32"}, {"category": "Standard", "default": 1, "group": "MAVLink", "max": 250, "min": 1, "name": "MAV_COMP_ID", "rebootRequired": true, "shortDesc": "MAVLink component ID", "type": "Int32"}, {"category": "Standard", "default": 1, "group": "MAVLink", "longDesc": "If set to 1 incoming external setpoint messages will be directly forwarded\nto the controllers if in offboard control mode\n", "name": "MAV_FWDEXTSP", "shortDesc": "Forward external setpoint messages", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 1, "group": "MAVLink", "longDesc": "Disabling the parameter hash check functionality will make the mavlink instance\nstream parameters continuously.\n", "name": "MAV_HASH_CHK_EN", "shortDesc": "Parameter hash check", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 1, "group": "MAVLink", "longDesc": "The mavlink heartbeat message will not be forwarded if this parameter is set to 'disabled'.\nThe main reason for disabling heartbeats to be forwarded is because they confuse dronekit.\n", "name": "MAV_HB_FORW_EN", "shortDesc": "Heartbeat message forwarding", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 2, "group": "MAVLink", "name": "MAV_PROTO_VER", "shortDesc": "MAVLink protocol version", "type": "Int32", "values": [{"description": "Version 1 with auto-upgrade to v2 if detected", "value": 1}, {"description": "Version 2", "value": 2}]}, {"category": "Standard", "default": 5, "group": "MAVLink", "longDesc": "If the connected radio stops reporting RADIO_STATUS for a certain time,\na warning is triggered and, if MAV_X_RADIO_CTL is enabled, the software-flow\ncontrol is reset.\n", "max": 250, "min": 1, "name": "MAV_RADIO_TOUT", "shortDesc": "Timeout in seconds for the RADIO_STATUS reports coming in", "type": "Int32", "units": "s"}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "When non-zero the MAVLink app will attempt to configure the\nSiK radio to this ID and re-set the parameter to 0. If the value\nis negative it will reset the complete radio config to\nfactory defaults. Only applies if this mavlink instance is going through a SiK radio\n", "max": 240, "min": -1, "name": "MAV_SIK_RADIO_ID", "shortDesc": "MAVLink SiK Radio ID", "type": "Int32"}, {"category": "Standard", "default": 1, "group": "MAVLink", "longDesc": "IDs above 255 use the 32-bit system ID extension of MAVLink 2,\nwhich forces MAV_PROTO_VER to 2. Every system on the network needs\nto support the extension to talk to such a system.\n\nOnly use IDs above 255 for vehicles, and keep ground stations and\nother controlling systems at 255 or below. The gimbal protocol and\nother messages that carry a system ID inside the payload, such as\nthe ID of the system in control, still only support IDs up to 255.\n", "max": 2147483647, "min": 1, "name": "MAV_SYS_ID", "rebootRequired": true, "shortDesc": "MAVLink system ID", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "TELEM2 on Skynode only.\n\n", "name": "MAV_S_FORWARD", "rebootRequired": true, "shortDesc": "Enable MAVLink forwarding on TELEM2", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 11, "group": "MAVLink", "longDesc": "The MAVLink Mode defines the set of streamed messages (for example the\nvehicle's attitude) and their sending rates.\n\n", "name": "MAV_S_MODE", "rebootRequired": true, "shortDesc": "MAVLink Mode for SOM to FMU communication channel", "type": "Int32", "values": [{"description": "Normal", "value": 0}, {"description": "Onboard", "value": 2}, {"description": "Config", "value": 5}, {"description": "Minimal", "value": 7}, {"description": "Onboard Low Bandwidth", "value": 11}, {"description": "Low Bandwidth", "value": 13}]}, {"category": "Standard", "default": 0, "group": "MAVLink", "max": 23, "min": 0, "name": "MAV_TYPE", "shortDesc": "MAVLink airframe type", "type": "Int32", "values": [{"description": "Generic micro air vehicle", "value": 0}, {"description": "Fixed wing aircraft", "value": 1}, {"description": "Quadrotor", "value": 2}, {"description": "Coaxial helicopter", "value": 3}, {"description": "Normal helicopter with tail rotor", "value": 4}, {"description": "Airship, controlled", "value": 7}, {"description": "Free balloon, uncontrolled", "value": 8}, {"description": "Ground rover", "value": 10}, {"description": "Surface vessel, boat, ship", "value": 11}, {"description": "Submarine", "value": 12}, {"description": "Hexarotor", "value": 13}, {"description": "Octorotor", "value": 14}, {"description": "Tricopter", "value": 15}, {"description": "VTOL Two-rotor Tailsitter", "value": 19}, {"description": "VTOL Quad-rotor Tailsitter", "value": 20}, {"description": "VTOL Tiltrotor", "value": 21}, {"description": "VTOL Standard (separate fixed rotors for hover and cruise flight)", "value": 22}, {"description": "VTOL Tailsitter", "value": 23}]}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "If set to 1 incoming HIL GPS messages are parsed.\n", "name": "MAV_USEHILGPS", "shortDesc": "Use/Accept HIL GPS message even if not in HIL mode", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 1, "group": "Magnetometer Bias Estimator", "longDesc": "This enables continuous calibration of the magnetometers\nbefore takeoff using gyro data.\n", "name": "MBE_ENABLE", "rebootRequired": true, "shortDesc": "Enable online mag bias calibration", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 18.0, "group": "Magnetometer Bias Estimator", "increment": 0.1, "longDesc": "Increase to make the estimator more responsive\nDecrease to make the estimator more robust to noise\n", "max": 100.0, "min": 0.1, "name": "MBE_LEARN_GAIN", "shortDesc": "Mag bias estimator learning gain", "type": "Float"}, {"category": "Standard", "default": 1, "group": "Manual Control", "longDesc": "This determines if moving the left stick to the lower right\narms and to the lower left disarms the vehicle.\n", "name": "MAN_ARM_GESTURE", "shortDesc": "Enable arm/disarm stick gesture", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "Manual Control", "increment": 0.01, "longDesc": "Range around stick center ignored to prevent\nvehicle drift from stick hardware inaccuracy.\n\nDoes not apply to any precise constant input like\nthrottle and attitude or rate piloting.\n", "max": 1.0, "min": 0.0, "name": "MAN_DEADZONE", "shortDesc": "Deadzone for sticks (only specific use cases)", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Manual Control", "longDesc": "The timeout for holding the left stick to the lower left\nand the right stick to the lower right at the same time until the gesture\nkills the actuators one-way.\n\nA negative value disables the feature.\n", "max": 15.0, "min": -1.0, "name": "MAN_KILL_GEST_T", "shortDesc": "Trigger time for kill stick gesture", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.0, "group": "Manual Control", "increment": 0.5, "longDesc": "Stick velocity above which the pilot regains control by switching to Position mode (or Altitude if position is unavailable). Unit: normalized stick travel per second \u2014 at 1.0, moving a stick half its range in ~0.5s triggers it. A negative value disables the feature. Only applies to multicopters and VTOLs in MC mode.\n", "max": 10.0, "min": -1.0, "name": "MAN_OVERRIDE_SPD", "shortDesc": "Manual control override speed threshold", "type": "Float", "units": "1/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "Mission", "longDesc": "Ensure:\ngripper: NAV_CMD_DO_GRIPPER\nhas released before continuing mission.\nwinch: CMD_DO_WINCH\nhas delivered before continuing mission.\ngimbal: CMD_DO_GIMBAL_MANAGER_PITCHYAW\nhas reached the commanded orientation before beginning to take pictures.\n", "min": 0.0, "name": "MIS_COMMAND_TOUT", "shortDesc": "Timeout to allow the payload to execute the mission command", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 10000.0, "group": "Mission", "increment": 100.0, "longDesc": "There will be a warning message if the current waypoint is more distant than MIS_DIST_1WP from Home.\nHas no effect on mission validity.\nSet a value of zero or less to disable.\n", "max": 100000.0, "min": -1.0, "name": "MIS_DIST_1WP", "shortDesc": "Maximal horizontal distance from Home to first waypoint", "type": "Float", "units": "m"}, {"category": "Standard", "default": 30, "group": "Mission", "longDesc": "Minimum altitude above landing point that the vehicle will climb to after an aborted landing.\nThen vehicle will loiter in this altitude until further command is received.\nUsed as the default when the landing mission item does not specify its own abort altitude\n(MAV_CMD_NAV_LAND param1).\nOnly applies to fixed-wing vehicles.\n", "min": 0, "name": "MIS_LND_ABRT_ALT", "shortDesc": "Landing abort min altitude", "type": "Int32", "units": "m"}, {"category": "Standard", "default": 0, "group": "Mission", "longDesc": "Enable yaw control of the mount. (Only affects multicopters with an active ROI)\n\nIf enabled, yaw commands will be sent to the mount and the vehicle will follow its heading towards the flight direction.\nIf disabled, the vehicle will yaw towards the ROI in Mission and Hold mode.\n", "max": 1, "min": 0, "name": "MIS_MNT_YAW_CTL", "shortDesc": "Enable gimbal yaw control in missions and Hold", "type": "Int32", "values": [{"description": "Disable", "value": 0}, {"description": "Enable", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 2.5, "group": "Mission", "increment": 0.5, "longDesc": "This is the relative altitude the system will take off to\nif not otherwise specified.\n", "min": 0.0, "name": "MIS_TAKEOFF_ALT", "shortDesc": "Default take-off altitude", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Mission", "longDesc": "Specifies if a mission has to contain a takeoff and/or mission landing.\nValidity of configured takeoffs/landings is checked independently of the setting here.\n", "name": "MIS_TKO_LAND_REQ", "shortDesc": "Mission takeoff/landing required", "type": "Int32", "values": [{"description": "No requirements", "value": 0}, {"description": "Require a takeoff", "value": 1}, {"description": "Require a landing", "value": 2}, {"description": "Require a takeoff and a landing", "value": 3}, {"description": "Require both a takeoff and a landing, or neither", "value": 4}, {"description": "Same as previous when landed, in-air require landing only if no valid VTOL approach is present", "value": 5}]}, {"category": "Standard", "default": 0, "group": "Mission", "longDesc": "Keep the vehicle over the landing target during vertical takeoffs (multicopter and VTOL in hover),\nusing the landing target estimate. Requires the vision target estimator with bit 2 of\nVTE_TASK_MASK set. Without a valid target estimate the takeoff is unchanged.\n", "name": "MIS_TKO_PREC", "shortDesc": "Precision takeoff", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 2.0, "group": "Mission", "increment": 0.1, "longDesc": "Time after the takeoff ramp is complete before a vertical takeoff setpoint may move\nsideways onto the landing target. Gives the vehicle time to clear the pad. Only used with MIS_TKO_PREC.\n", "max": 10.0, "min": 0.0, "name": "MIS_TKO_PREC_DLY", "shortDesc": "Precision takeoff correction delay", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 12.0, "group": "Mission", "increment": 1.0, "max": 90.0, "min": 0.0, "name": "MIS_YAW_ERR", "shortDesc": "Max yaw error in degrees needed for waypoint heading acceptance", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 1, "default": 10.0, "group": "Mission", "increment": 1.0, "longDesc": "Time from commanding a waypoint heading until a multicopter continues without reaching it,\nto not get stuck with low yaw authority.\n\nA forced heading (e.g. before a VTOL transition) is never skipped: a mission fails instead,\nother modes keep waiting.\nVTOLs only wait for forced headings.\n0: don't wait, -1: wait indefinitely\n", "max": 60.0, "min": -1.0, "name": "MIS_YAW_TMT", "shortDesc": "Waypoint heading timeout", "type": "Float", "units": "s"}, {"category": "Standard", "default": 0, "group": "Mission", "max": 5, "min": 0, "name": "MPC_YAW_MODE", "shortDesc": "Heading behavior in autonomous modes", "type": "Int32", "values": [{"description": "towards waypoint", "value": 0}, {"description": "towards home", "value": 1}, {"description": "away from home", "value": 2}, {"description": "along trajectory", "value": 3}, {"description": "towards waypoint (yaw first)", "value": 4}, {"description": "yaw fixed", "value": 5}]}, {"category": "Standard", "decimalPlaces": 2, "default": 10.0, "group": "Mission", "increment": 0.5, "longDesc": "Overridden by a waypoint's own acceptance radius, if set. For fixed-wing and rovers, the controller's acceptance radius is used instead when it is larger.\n", "max": 200.0, "min": 0.05, "name": "NAV_ACC_RAD", "shortDesc": "Acceptance radius", "type": "Float", "units": "m"}, {"category": "Standard", "default": 1, "group": "Mission", "name": "NAV_FORCE_VT", "shortDesc": "Force VTOL mode takeoff and land", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 5.0, "group": "Mission", "longDesc": "FW acceptance alt for last waypoint before landing. Usually smaller than NAV_FW_ALT_RAD; accuracy matters more near the ground.\n", "max": 200.0, "min": 0.05, "name": "NAV_FW_ALTL_RAD", "shortDesc": "FW Altitude acceptance radius before landing", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 10.0, "group": "Mission", "increment": 0.5, "max": 200.0, "min": 0.05, "name": "NAV_FW_ALT_RAD", "shortDesc": "FW Altitude acceptance radius", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 80.0, "group": "Mission", "increment": 0.5, "longDesc": "Default for fixed-wing loiters, e.g. in Hold mode. Positive values loiter clockwise, negative values counter-clockwise.\n", "max": 10000.0, "min": -10000.0, "name": "NAV_LOITER_RAD", "shortDesc": "FW Loiter radius", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Mission", "longDesc": "If disabled, the vehicle loiters at its current position. Only applies to Hold mode during failsafe actions.\n", "name": "NAV_LTR_LAST_DL", "shortDesc": "Loiter at last GCS heartbeat position on data link loss", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.8, "group": "Mission", "increment": 0.5, "max": 200.0, "min": 0.05, "name": "NAV_MC_ALT_RAD", "shortDesc": "MC Altitude acceptance radius", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": -1.0, "group": "Mission", "increment": 1.0, "longDesc": "Minimum height AGL in Return and Mission (excluding landing commands). Requires a distance sensor. Stops further descent but doesn't force a climb. Set to -1 to disable.\n", "min": -1.0, "name": "NAV_MIN_GND_DIST", "shortDesc": "Minimum height above ground during Mission and Return", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": -1.0, "group": "Mission", "increment": 0.5, "longDesc": "Altitude above Home used when Hold mode is entered without an altitude, e.g. from an RC switch. Doesn't apply to mission loiters or reposition (\"Go to\") setpoints. Set to -1 to disable.\n", "min": -1.0, "name": "NAV_MIN_LTR_ALT", "shortDesc": "Minimum loiter altitude", "type": "Float", "units": "m"}, {"category": "Standard", "default": 1, "group": "Mission", "longDesc": "Changes take effect at the next cross-track conflict level transition.\n", "max": 5, "min": 0, "name": "NAV_TRAFF_AVOID", "shortDesc": "Traffic avoidance action (Xtrack only)", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Warn only", "value": 1}, {"description": "Return mode", "value": 2}, {"description": "Land mode", "value": 3}, {"description": "Position Hold mode", "value": 4}, {"description": "Terminate", "value": 5}]}, {"category": "Standard", "default": 500.0, "group": "Mission", "longDesc": "Maximum absolute distance from the projected traffic track.\n", "min": 500.0, "name": "NAV_TRAFF_A_HOR", "shortDesc": "Crosstrack conflict distance threshold", "type": "Float", "units": "m"}, {"category": "Standard", "default": 500.0, "group": "Mission", "max": 500.0, "min": 10.0, "name": "NAV_TRAFF_A_VER", "shortDesc": "Crosstrack vertical separation threshold", "type": "Float", "units": "m"}, {"category": "Standard", "default": 60, "group": "Mission", "longDesc": "A conflict is raised when the time estimate is below this threshold.\nThe estimate is the current 3D separation divided by the sum of the ownship and traffic speed magnitudes.\n", "max": 900000000, "min": 1, "name": "NAV_TRAFF_COLL_T", "shortDesc": "Crosstrack collision time threshold", "type": "Int32", "units": "s"}, {"category": "Standard", "default": 0, "group": "Mixer Output", "longDesc": "The air-mode enables the mixer to increase the total thrust of the multirotor\nin order to keep attitude and rate control even at low and high throttle.\n\nThis function should be disabled during tuning as it will help the controller\nto diverge if the closed-loop is unstable (i.e. the vehicle is not tuned yet).\n\nEnabling air-mode for yaw requires the use of an arming switch.\n", "name": "MC_AIRMODE", "shortDesc": "Multicopter air-mode", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Roll/Pitch", "value": 1}, {"description": "Roll/Pitch/Yaw", "value": 2}]}, {"category": "Standard", "default": 0, "group": "Motor Failure", "longDesc": "If enabled, the HealthAndArmingChecks compare each motor's ESC current against the expected\ncurrent for the commanded throttle, and flag a motor whose current stays too far from that\nexpectation (too low or too high) for a set time.\nThis check only works for ESCs that report current consumption.\n", "name": "FD_ACT_EN", "shortDesc": "Enable Actuator Failure check", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 35.0, "group": "Motor Failure", "increment": 1.0, "max": 50.0, "min": 0.0, "name": "MOTFAIL_C2T", "shortDesc": "Motor failure model current-vs-command slope", "type": "Float", "units": "A/%"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Motor Failure", "increment": 1.0, "max": 20.0, "min": 0.0, "name": "MOTFAIL_IDLE", "shortDesc": "Motor failure model idle current", "type": "Float", "units": "A"}, {"category": "Standard", "decimalPlaces": 2, "default": 10.0, "group": "Motor Failure", "increment": 1.0, "longDesc": "Set 0 to disable overcurrent detection.\n", "max": 30.0, "min": 0.0, "name": "MOTFAIL_OVER", "shortDesc": "Motor failure overcurrent trip band", "type": "Float", "units": "A"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Motor Failure", "increment": 1.0, "longDesc": "Motor failure only triggers after MOTFAIL_OVER is exceeded for this time.\n", "max": 10.0, "min": 0.01, "name": "MOTFAIL_OVR_TIME", "shortDesc": "Motor failure overcurrent trigger time", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 10.0, "group": "Motor Failure", "increment": 1.0, "longDesc": "Set 0 to disable undercurrent detection.\n", "max": 30.0, "min": 0.0, "name": "MOTFAIL_UNDER", "shortDesc": "Motor failure undercurrent trip band", "type": "Float", "units": "A"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Motor Failure", "increment": 1.0, "longDesc": "Motor failure only triggers after MOTFAIL_UNDER is exceeded for this time.\n", "max": 10.0, "min": 0.0, "name": "MOTFAIL_UND_TIME", "shortDesc": "Motor failure undercurrent trigger time", "type": "Float", "units": "s"}, {"category": "Standard", "default": 0, "group": "Mount", "longDesc": "Set to true for servo gimbal, false for passthrough.\nThis is required for a gimbal which is not capable of stabilizing itself\nand relies on the IMU's attitude estimation.\n", "name": "MNT_DO_STAB", "shortDesc": "Stabilize the mount", "type": "Int32", "values": [{"description": "Disable", "value": 0}, {"description": "Stabilize all axis", "value": 1}, {"description": "Stabilize yaw for absolute/lock mode.", "value": 2}, {"description": "Stabilize pitch for absolute/lock mode.", "value": 3}]}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "Mount", "max": 90.0, "min": -90.0, "name": "MNT_FIXED_PITCH", "shortDesc": "Tracked pitch angle when in fixed mode (MNT_MODE_IN=5)", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 1, "default": 90.0, "group": "Mount", "max": 90.0, "min": -90.0, "name": "MNT_LND_P_MAX", "shortDesc": "Pitch maximum when landed", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 1, "default": -90.0, "group": "Mount", "max": 90.0, "min": -90.0, "name": "MNT_LND_P_MIN", "shortDesc": "Pitch minimum when landed", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 0, "group": "Mount", "max": 6, "min": 0, "name": "MNT_MAN_PITCH", "shortDesc": "Auxiliary channel to control pitch (in AUX input or manual mode)", "type": "Int32", "values": [{"description": "Disable", "value": 0}, {"description": "AUX1", "value": 1}, {"description": "AUX2", "value": 2}, {"description": "AUX3", "value": 3}, {"description": "AUX4", "value": 4}, {"description": "AUX5", "value": 5}, {"description": "AUX6", "value": 6}]}, {"category": "Standard", "default": 0, "group": "Mount", "max": 6, "min": 0, "name": "MNT_MAN_ROLL", "shortDesc": "Auxiliary channel to control roll (in AUX input or manual mode)", "type": "Int32", "values": [{"description": "Disable", "value": 0}, {"description": "AUX1", "value": 1}, {"description": "AUX2", "value": 2}, {"description": "AUX3", "value": 3}, {"description": "AUX4", "value": 4}, {"description": "AUX5", "value": 5}, {"description": "AUX6", "value": 6}]}, {"category": "Standard", "default": 0, "group": "Mount", "max": 6, "min": 0, "name": "MNT_MAN_YAW", "shortDesc": "Auxiliary channel to control yaw (in AUX input or manual mode)", "type": "Int32", "values": [{"description": "Disable", "value": 0}, {"description": "AUX1", "value": 1}, {"description": "AUX2", "value": 2}, {"description": "AUX3", "value": 3}, {"description": "AUX4", "value": 4}, {"description": "AUX5", "value": 5}, {"description": "AUX6", "value": 6}]}, {"category": "Standard", "default": 154, "group": "Mount", "longDesc": "If MNT_MODE_OUT is MAVLink protocol v2, mount configure/control commands will be sent with this component ID.\n", "name": "MNT_MAV_COMPID", "shortDesc": "Mavlink Component ID of the mount", "type": "Int32"}, {"category": "Standard", "default": 1, "group": "Mount", "longDesc": "If MNT_MODE_OUT is MAVLink gimbal protocol v1, mount configure/control commands will be sent with this target ID.\n", "name": "MNT_MAV_SYSID", "shortDesc": "Mavlink System ID of the mount", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 1, "default": 45.0, "group": "Mount", "longDesc": "Use output driver settings to calibrate (e.g. PWM_CENT/_MIN/_MAX).\n", "name": "MNT_MAX_PITCH", "shortDesc": "Max positive angle of pitch setpoint (only in MNT_MODE_OUT=AUX)", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 1, "default": -45.0, "group": "Mount", "longDesc": "Use output driver settings to calibrate (e.g. PWM_CENT/_MIN/_MAX).\n", "name": "MNT_MIN_PITCH", "shortDesc": "Min negative angle of pitch setpoint (only in MNT_MODE_OUT=AUX)", "type": "Float", "units": "deg"}, {"category": "Standard", "default": -1, "group": "Mount", "longDesc": "This is the protocol used between the ground station and the autopilot.\n\nRecommended is Auto, RC only or MAVLink gimbal protocol v2.\nThe rest will be deprecated.\n", "max": 5, "min": -1, "name": "MNT_MODE_IN", "rebootRequired": true, "shortDesc": "Mount input mode", "type": "Int32", "values": [{"description": "DISABLED", "value": -1}, {"description": "Auto (RC and MAVLink gimbal protocol v2)", "value": 0}, {"description": "RC", "value": 1}, {"description": "MAVLINK_ROI (protocol v1, to be deprecated)", "value": 2}, {"description": "MAVLINK_DO_MOUNT (protocol v1, to be deprecated)", "value": 3}, {"description": "MAVlink gimbal protocol v2", "value": 4}, {"description": "Fixed world-frame attitude, not user controllable", "value": 5}]}, {"category": "Standard", "default": 0, "group": "Mount", "longDesc": "This is the protocol used between the autopilot and a connected gimbal.\n\nRecommended is the MAVLink gimbal protocol v2 if the gimbal supports it.\n\nIn AUX mode, the gimbal (and hence the gimbal manager) is only made\navailable if at least one output channel is assigned a gimbal\nroll/pitch/yaw output function (checked once at startup, so newly\nassigned output functions require a reboot).\n", "max": 3, "min": 0, "name": "MNT_MODE_OUT", "rebootRequired": true, "shortDesc": "Mount output mode", "type": "Int32", "values": [{"description": "AUX", "value": 0}, {"description": "MAVLink gimbal protocol v1", "value": 1}, {"description": "MAVLink gimbal protocol v2", "value": 2}, {"description": "Forward to external gimbal manager", "value": 3}]}, {"category": "Standard", "default": -1, "group": "Mount", "longDesc": "Optional second output, driven in parallel to MNT_MODE_OUT with the\nsame setpoints. This allows the gimbal driver to talk to a second\ngimbal in addition to the primary one.\n\nSet to Disabled if not used. The two outputs must use different modes.\n", "max": 3, "min": -1, "name": "MNT_MODE_OUT2", "rebootRequired": true, "shortDesc": "Second mount output mode", "type": "Int32", "values": [{"description": "Disabled", "value": -1}, {"description": "AUX", "value": 0}, {"description": "MAVLink gimbal protocol v1", "value": 1}, {"description": "MAVLink gimbal protocol v2", "value": 2}, {"description": "Forward to external gimbal manager", "value": 3}]}, {"category": "Standard", "decimalPlaces": 1, "default": 90.0, "group": "Mount", "longDesc": "Use output driver settings to calibrate (e.g. PWM_CENT/_MIN/_MAX). Note that only symmetric angular ranges are supported.\n", "max": 720.0, "min": 1.0, "name": "MNT_RANGE_ROLL", "shortDesc": "Range of roll channel output (only in MNT_MODE_OUT=AUX)", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 1, "default": 360.0, "group": "Mount", "longDesc": "Use output driver settings to calibrate (e.g. PWM_CENT/_MIN/_MAX). Note that only symmetric angular ranges are supported.\n", "max": 720.0, "min": 1.0, "name": "MNT_RANGE_YAW", "shortDesc": "Range of yaw channel output (only in MNT_MODE_OUT=AUX)", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 30.0, "group": "Mount", "longDesc": "Full stick input [-1..1] translats to [-pitch rate..pitch rate].\n", "max": 90.0, "min": 1.0, "name": "MNT_RATE_PITCH", "shortDesc": "Angular pitch rate for manual input in degrees/second", "type": "Float", "units": "deg/s"}, {"category": "Standard", "default": 30.0, "group": "Mount", "longDesc": "Full stick input [-1..1] translats to [-yaw rate..yaw rate].\n", "max": 90.0, "min": 1.0, "name": "MNT_RATE_YAW", "shortDesc": "Angular yaw rate for manual input in degrees/second", "type": "Float", "units": "deg/s"}, {"category": "Standard", "default": 1, "group": "Mount", "max": 1, "min": 0, "name": "MNT_RC_IN_MODE", "shortDesc": "Input mode for RC gimbal input", "type": "Int32", "values": [{"description": "Angle", "value": 0}, {"description": "Angular rate", "value": 1}]}, {"category": "Standard", "default": 0.3, "group": "Mount", "longDesc": "Alpha filter time constant defining the convergence rate for open-loop AUX mount control\n\nUse when no angular position feedback is available.\nWith MNT_MODE_OUT set to AUX, the mount operates in open-loop and directly commands the servo output.\nParameters must be tuned for the specific servo to approximate its speed and response.\n", "min": 0.0, "name": "MNT_TAU", "shortDesc": "Time constant for open-loop AUX gimbal control", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Multicopter Acro Mode", "longDesc": "Exponential factor for tuning the input curve shape.\n\n0 Purely linear input curve\n1 Purely cubic input curve\n", "max": 1.0, "min": 0.0, "name": "MC_ACRO_EXPO", "shortDesc": "Acro mode roll, pitch expo factor", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Multicopter Acro Mode", "longDesc": "Exponential factor for tuning the input curve shape.\n\n0 Purely linear input curve\n1 Purely cubic input curve\n", "max": 1.0, "min": 0.0, "name": "MC_ACRO_EXPO_Y", "shortDesc": "Acro mode yaw expo factor", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 100.0, "group": "Multicopter Acro Mode", "increment": 5.0, "longDesc": "Full stick deflection leads to this rate.\n", "max": 1800.0, "min": 0.0, "name": "MC_ACRO_P_MAX", "shortDesc": "Acro mode maximum pitch rate", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 100.0, "group": "Multicopter Acro Mode", "increment": 5.0, "longDesc": "Full stick deflection leads to this rate.\n", "max": 1800.0, "min": 0.0, "name": "MC_ACRO_R_MAX", "shortDesc": "Acro mode maximum roll rate", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Multicopter Acro Mode", "longDesc": "\"Superexponential\" factor for refining the input curve shape tuned using MC_ACRO_EXPO.\n\n0 Pure Expo function\n0.7 reasonable shape enhancement for intuitive stick feel\n0.95 very strong bent input curve only near maxima have effect\n", "max": 0.95, "min": 0.0, "name": "MC_ACRO_SUPEXPO", "shortDesc": "Acro mode roll, pitch super expo factor", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Multicopter Acro Mode", "longDesc": "\"Superexponential\" factor for refining the input curve shape tuned using MC_ACRO_EXPO_Y.\n\n0 Pure Expo function\n0.7 reasonable shape enhancement for intuitive stick feel\n0.95 very strong bent input curve only near maxima have effect\n", "max": 0.95, "min": 0.0, "name": "MC_ACRO_SUPEXPOY", "shortDesc": "Acro mode yaw super expo factor", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 100.0, "group": "Multicopter Acro Mode", "increment": 5.0, "longDesc": "Full stick deflection leads to this rate.\n", "max": 1800.0, "min": 0.0, "name": "MC_ACRO_Y_MAX", "shortDesc": "Acro mode maximum yaw rate", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 220.0, "group": "Multicopter Attitude Control", "increment": 5.0, "longDesc": "Limit for pitch rate in manual and auto modes (except acro).\nHas effect for large rotations in autonomous mode, to avoid large control\noutput and mixer saturation.\n\nThis is not only limited by the vehicle's properties, but also by the maximum\nmeasurement rate of the gyro.\n", "max": 1800.0, "min": 0.0, "name": "MC_PITCHRATE_MAX", "shortDesc": "Max pitch rate", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 4.0, "group": "Multicopter Attitude Control", "increment": 0.1, "longDesc": "Pitch proportional gain, i.e. desired angular speed in rad/s for error 1 rad.\n", "max": 12.0, "min": 0.0, "name": "MC_PITCH_P", "shortDesc": "Pitch P gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Multicopter Attitude Control", "increment": 0.01, "longDesc": "Scale on the reference-model rate feed-forward. 0 disables it.\n", "max": 1.0, "min": 0.0, "name": "MC_REF_FF", "shortDesc": "Attitude reference-model feed-forward gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 0, "default": 100.0, "group": "Multicopter Attitude Control", "increment": 5.0, "longDesc": "Per-axis cap on the rate feed-forward.\n", "max": 1800.0, "min": 0.0, "name": "MC_REF_FF_MAX", "shortDesc": "Feed-forward angular-rate cap; 0 = disabled", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 0, "default": 50.0, "group": "Multicopter Attitude Control", "increment": 1.0, "longDesc": "Bandwidth of the reference model that smooths the attitude setpoint\nand generates the rate feed-forward. Higher = less lag, more peak\nrate demand.\n", "max": 200.0, "min": 1.0, "name": "MC_REF_W_N", "shortDesc": "Attitude reference-model natural frequency", "type": "Float", "units": "rad/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 220.0, "group": "Multicopter Attitude Control", "increment": 5.0, "longDesc": "Limit for roll rate in manual and auto modes (except acro).\nHas effect for large rotations in autonomous mode, to avoid large control\noutput and mixer saturation.\n\nThis is not only limited by the vehicle's properties, but also by the maximum\nmeasurement rate of the gyro.\n", "max": 1800.0, "min": 0.0, "name": "MC_ROLLRATE_MAX", "shortDesc": "Max roll rate", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 4.0, "group": "Multicopter Attitude Control", "increment": 0.1, "longDesc": "Roll proportional gain, i.e. desired angular speed in rad/s for error 1 rad.\n", "max": 12.0, "min": 0.0, "name": "MC_ROLL_P", "shortDesc": "Roll P gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 200.0, "group": "Multicopter Attitude Control", "increment": 5.0, "max": 1800.0, "min": 0.0, "name": "MC_YAWRATE_MAX", "shortDesc": "Max yaw rate", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 2.8, "group": "Multicopter Attitude Control", "increment": 0.1, "longDesc": "Yaw proportional gain, i.e. desired angular speed in rad/s for error 1 rad.\n", "max": 5.0, "min": 0.0, "name": "MC_YAW_P", "shortDesc": "Yaw P gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.4, "group": "Multicopter Attitude Control", "increment": 0.1, "longDesc": "A fraction [0,1] deprioritizing yaw compared to roll and pitch in non-linear attitude control.\nDeprioritizing yaw is necessary because multicopters have much less control authority\nin yaw compared to the other axes and it makes sense because yaw is not critical for\nstable hovering or 3D navigation.\n\nFor yaw control tuning use MC_YAW_P. This ratio has no impact on the yaw gain.\n", "max": 1.0, "min": 0.0, "name": "MC_YAW_WEIGHT", "shortDesc": "Yaw weight", "type": "Float"}, {"category": "Standard", "decimalPlaces": 0, "default": 20.0, "group": "Multicopter Attitude Control", "increment": 5.0, "longDesc": "Limits the acceleration of the yaw setpoint to avoid large\ncontrol output and mixer saturation.\n", "max": 360.0, "min": 5.0, "name": "MPC_YAWRAUTO_ACC", "shortDesc": "Maximum yaw acceleration in autonomous modes", "type": "Float", "units": "deg/s^2"}, {"category": "Standard", "decimalPlaces": 0, "default": 60.0, "group": "Multicopter Attitude Control", "increment": 5.0, "longDesc": "Limits the rate of change of the yaw setpoint to avoid large\ncontrol output and mixer saturation.\n", "max": 360.0, "min": 5.0, "name": "MPC_YAWRAUTO_MAX", "shortDesc": "Maximum yaw rate in autonomous modes", "type": "Float", "units": "deg/s"}, {"category": "Standard", "default": 0.4, "group": "Multicopter Position Control", "longDesc": "Average delay of the range sensor message plus the tracking delay of the position controller in seconds\n\nOnly used in Position mode.\n", "max": 1.0, "min": 0.0, "name": "CP_DELAY", "shortDesc": "Range sensor and position controller average delay", "type": "Float", "units": "s"}, {"category": "Standard", "default": -1.0, "group": "Multicopter Position Control", "longDesc": "Only used in Position mode. Collision avoidance is disabled by setting this parameter to a negative value\n", "max": 15.0, "min": -1.0, "name": "CP_DIST", "shortDesc": "Minimum distance the vehicle should keep to all obstacles", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Multicopter Position Control", "longDesc": "Boolean to allow moving into directions where there is no sensor data (outside FOV)\n\nOnly used in Position mode.\n", "name": "CP_GO_NO_DATA", "shortDesc": "Allow moving into directions without sensor data", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 30.0, "group": "Multicopter Position Control", "longDesc": "Angle left/right from the commanded setpoint by which the collision prevention algorithm can choose to change the setpoint direction\n\nOnly used in Position mode.\n", "max": 90.0, "min": 0.0, "name": "CP_GUIDE_ANG", "shortDesc": "Collision prevention guidance angle", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Multicopter Position Control", "longDesc": "Setting this parameter to 0 disables the filter\n", "max": 2.0, "min": 0.0, "name": "MC_MAN_TILT_TAU", "shortDesc": "Manual tilt input filter time constant", "type": "Float", "units": "s"}, {"category": "Standard", "default": 1, "group": "Multicopter Position Control", "longDesc": "Set to decouple tilt from vertical acceleration.\nThis provides smoother flight but slightly worse tracking in position and auto modes.\nUnset if accurate position tracking during dynamic maneuvers is more important than a smooth flight.\n", "name": "MPC_ACC_DECOUPLE", "shortDesc": "Acceleration to tilt coupling", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "Multicopter Position Control", "increment": 1.0, "max": 15.0, "min": 2.0, "name": "MPC_ACC_DOWN_MAX", "shortDesc": "Maximum downwards acceleration in climb rate controlled modes", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "Multicopter Position Control", "increment": 1.0, "longDesc": "When piloting manually, this parameter is only used in MPC_POS_MODE Acceleration based.\n", "max": 15.0, "min": 2.0, "name": "MPC_ACC_HOR", "shortDesc": "Acceleration for autonomous and for manual modes", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "decimalPlaces": 2, "default": 5.0, "group": "Multicopter Position Control", "increment": 1.0, "longDesc": "With MPC_POS_MODE=0 it limits deceleration.\nWith MPC_POS_MODE=4 it is unused (see MPC_ACC_HOR).\n", "max": 15.0, "min": 2.0, "name": "MPC_ACC_HOR_MAX", "shortDesc": "Maximum horizontal acceleration", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "decimalPlaces": 1, "default": 4.0, "group": "Multicopter Position Control", "increment": 1.0, "max": 15.0, "min": 2.0, "name": "MPC_ACC_UP_MAX", "shortDesc": "Maximum upwards acceleration in climb rate controlled modes", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "default": 2, "group": "Multicopter Position Control", "longDesc": "Control height\n0: relative earth frame origin which may drift due to sensors\n1: relative to ground (requires distance sensor) which changes with terrain variation.\nIt will revert to relative earth frame if the distance to ground estimate becomes invalid.\n2: relative to ground (requires distance sensor) when stationary\nand relative to earth frame when moving horizontally.\nThe speed threshold is MPC_HOLD_MAX_XY\n", "max": 2, "min": 0, "name": "MPC_ALT_MODE", "shortDesc": "Altitude reference mode", "type": "Int32", "values": [{"description": "Altitude following", "value": 0}, {"description": "Terrain following", "value": 1}, {"description": "Terrain hold", "value": 2}]}, {"bitmask": [{"description": "Yaw nudging", "index": 0}, {"description": "Landing nudging", "index": 1}], "category": "Standard", "default": 0, "group": "Multicopter Position Control", "longDesc": "Bitmask to enable pilot override of heading and position during auto modes.\n\nBit 0 - Yaw nudging: yaw stick rotates the heading in all auto types\n(takeoff, mission, Return, hold, landing). The new heading is held until a\nmode switch resets it.\n\nBit 1 - Land nudging: during autonomous landing the pitch/roll sticks move\nthe vehicle horizontally, the throttle stick amends the descent speed\n(stick full up: 0, centered: MPC_LAND_SPEED, full down: 2 * MPC_LAND_SPEED),\nand the yaw stick rotates the heading.\n\nStick override must be disabled (set MAN_OVERRIDE_SPD = -1).\n", "max": 3, "min": 0, "name": "MPC_AUTO_NUDGING", "shortDesc": "Enable stick nudging in autonomous modes", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.8, "group": "Multicopter Position Control", "longDesc": "Maximum horizontal velocity for which position hold is enabled (use 0 to disable check)\n\nOnly used with MPC_POS_MODE Direct velocity or MPC_ALT_MODE 2\n", "max": 3.0, "min": 0.0, "name": "MPC_HOLD_MAX_XY", "shortDesc": "Max horizontal velocity for position hold", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.6, "group": "Multicopter Position Control", "longDesc": "Maximum vertical velocity for which position hold is enabled (use 0 to disable check)\n\nOnly used with MPC_ALT_MODE 1\n", "max": 3.0, "min": 0.0, "name": "MPC_HOLD_MAX_Z", "shortDesc": "Max vertical velocity for position hold", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 4.0, "group": "Multicopter Position Control", "increment": 1.0, "longDesc": "Limit the maximum jerk of the vehicle (how fast the acceleration can change).\nA lower value leads to smoother vehicle motions but also limited agility.\n", "max": 80.0, "min": 1.0, "name": "MPC_JERK_AUTO", "shortDesc": "Jerk limit in autonomous modes", "type": "Float", "units": "m/s^3"}, {"category": "Standard", "decimalPlaces": 1, "default": 8.0, "group": "Multicopter Position Control", "increment": 1.0, "longDesc": "Limit the maximum jerk (acceleration change) of the vehicle.\nA lower value leads to smoother motions but limits agility.\n\nSetting this to the maximum value essentially disables the limit.\n\nOnly used with MPC_POS_MODE Acceleration based.\n", "max": 500.0, "min": 0.5, "name": "MPC_JERK_MAX", "shortDesc": "Maximum horizontal and vertical jerk in Position/Altitude mode", "type": "Float", "units": "m/s^3"}, {"category": "Standard", "decimalPlaces": 1, "default": 10.0, "group": "Multicopter Position Control", "longDesc": "Below this altitude descending velocity gets limited to a value\nbetween \"MPC_Z_VEL_MAX_DN\" (or \"MPC_Z_V_AUTO_DN\") and \"MPC_LAND_SPEED\"\nValue needs to be higher than \"MPC_LAND_ALT2\"\n", "max": 122.0, "min": 0.0, "name": "MPC_LAND_ALT1", "shortDesc": "Altitude for 1. step of slow landing (descend)", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "Multicopter Position Control", "longDesc": "Below this altitude descending velocity gets\nlimited to \"MPC_LAND_SPEED\"\nValue needs to be lower than \"MPC_LAND_ALT1\"\n", "max": 122.0, "min": 0.0, "name": "MPC_LAND_ALT2", "shortDesc": "Altitude for 2. step of slow landing (landing)", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.0, "group": "Multicopter Position Control", "longDesc": "If a valid distance sensor measurement to the ground is available,\nlimit descending velocity to \"MPC_LAND_CRWL\" below this altitude.\n", "max": 122.0, "min": 0.0, "name": "MPC_LAND_ALT3", "shortDesc": "Altitude for 3. step of slow landing", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.3, "group": "Multicopter Position Control", "longDesc": "Used below MPC_LAND_ALT3 if distance sensor data is availabe.\n", "min": 0.1, "name": "MPC_LAND_CRWL", "shortDesc": "Land crawl descend rate", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 0, "default": -1.0, "group": "Multicopter Position Control", "increment": 1.0, "longDesc": "When landing nudging is enabled (MPC_AUTO_NUDGING bit 1), this defines the maximum\nallowed horizontal displacement from the original landing point.\n- If inside of the radius, only allow nudging inputs that do not move the vehicle outside of it.\n- If outside of the radius, only allow nudging inputs that move the vehicle back towards it.\n\nSet it to -1 for infinite radius.\n", "min": -1.0, "name": "MPC_LAND_RADIUS", "shortDesc": "User assisted landing radius", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.7, "group": "Multicopter Position Control", "min": 0.6, "name": "MPC_LAND_SPEED", "shortDesc": "Landing descend rate", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.08, "group": "Multicopter Position Control", "increment": 0.01, "longDesc": "The value is mapped to the lowest throttle stick position in Stabilized mode.\n\nToo low collective thrust leads to loss of roll/pitch/yaw torque control authority.\nAirmode is used to keep torque authority with zero thrust (see MC_AIRMODE).\n", "max": 0.5, "min": 0.0, "name": "MPC_MANTHR_MIN", "shortDesc": "Minimum collective thrust in Stabilized mode", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 0, "default": 35.0, "group": "Multicopter Position Control", "increment": 1.0, "max": 70.0, "min": 1.0, "name": "MPC_MAN_TILT_MAX", "shortDesc": "Maximal tilt angle in Stabilized, Altitude and Altitude Cruise mode", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 0, "default": 150.0, "group": "Multicopter Position Control", "increment": 10.0, "max": 400.0, "min": 0.0, "name": "MPC_MAN_Y_MAX", "shortDesc": "Max manual yaw rate for Stabilized, Altitude, Position mode", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.08, "group": "Multicopter Position Control", "increment": 0.01, "longDesc": "Not used in Stabilized mode\nSetting this parameter to 0 disables the filter\n", "max": 5.0, "min": 0.0, "name": "MPC_MAN_Y_TAU", "shortDesc": "Manual yaw rate input filter time constant", "type": "Float", "units": "s"}, {"category": "Standard", "default": 4, "group": "Multicopter Position Control", "longDesc": "The supported sub-modes are:\nDirect velocity:\nSticks directly map to velocity setpoints without smoothing.\nAlso applies to vertical direction and Altitude mode.\nUseful for velocity control tuning.\nAcceleration based:\nSticks map to acceleration and there's a virtual brake drag\n", "name": "MPC_POS_MODE", "shortDesc": "Position/Altitude mode variant", "type": "Int32", "values": [{"description": "Direct velocity", "value": 0}, {"description": "Acceleration based", "value": 4}]}, {"category": "Standard", "default": 0, "group": "Multicopter Position Control", "longDesc": "Rescale to estimate: stick is rescaled linearly so center stick gives the hover thrust estimate.\nNo rescale: stick maps 1:1 to thrust; useful with very low hover thrust, where rescaling distorts the curve and makes the upper half sensitive.\nRescale to parameter: as Rescale to estimate, but uses MPC_THR_HOVER; with MPC_THR_HOVER 0.5 same as No rescale.\n", "name": "MPC_THR_CURVE", "shortDesc": "Thrust curve mapping in Stabilized Mode", "type": "Int32", "values": [{"description": "Rescale to estimate", "value": 0}, {"description": "No rescale", "value": 1}, {"description": "Rescale to parameter", "value": 2}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.5, "group": "Multicopter Position Control", "increment": 0.01, "longDesc": "Mapped to center throttle stick in Stabilized mode (see MPC_THR_CURVE).\nUsed for initialization of the hover thrust estimator.\nThe estimated hover thrust is used as base for zero vertical acceleration in altitude control.\nThe hover thrust is important for land detection to work correctly.\n", "max": 0.9, "min": 0.1, "name": "MPC_THR_HOVER", "shortDesc": "Vertical thrust required to hover", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Multicopter Position Control", "increment": 0.05, "longDesc": "Limit allowed thrust e.g. for indoor test of overpowered vehicle.\n", "max": 1.0, "min": 0.0, "name": "MPC_THR_MAX", "shortDesc": "Maximum collective thrust in climb rate controlled modes", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.12, "group": "Multicopter Position Control", "increment": 0.01, "longDesc": "Too low thrust leads to loss of roll/pitch/yaw torque control authority.\nWith airmode enabled this parameters can be set to 0\nwhile still keeping torque authority (see MC_AIRMODE).\n", "max": 0.5, "min": 0.05, "name": "MPC_THR_MIN", "shortDesc": "Minimum collective thrust in climb rate controlled modes", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "Multicopter Position Control", "increment": 0.01, "longDesc": "Margin that is kept for horizontal control when higher priority vertical thrust is saturated.\nTo avoid completely starving horizontal control with high vertical error.\n", "max": 0.5, "min": 0.0, "name": "MPC_THR_XY_MARG", "shortDesc": "Horizontal thrust margin", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 0, "default": 45.0, "group": "Multicopter Position Control", "increment": 1.0, "longDesc": "Absolute maximum for all velocity or acceleration controlled modes.\nAny higher value is truncated.\n", "max": 89.0, "min": 20.0, "name": "MPC_TILTMAX_AIR", "shortDesc": "Maximum tilt angle in air", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 0, "default": 12.0, "group": "Multicopter Position Control", "increment": 1.0, "longDesc": "Tighter tilt limit during takeoff to avoid tip over.\n", "max": 89.0, "min": 5.0, "name": "MPC_TILTMAX_LND", "shortDesc": "Maximum tilt during initial takeoff ramp", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 3.0, "group": "Multicopter Position Control", "longDesc": "Increasing this value will make climb rate controlled takeoff slower.\nIf it's too slow the drone might scratch the ground and tip over.\nA time constant of 0 disables the ramp\n", "max": 5.0, "min": 0.0, "name": "MPC_TKO_RAMP_T", "shortDesc": "Smooth takeoff ramp time constant", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.5, "group": "Multicopter Position Control", "max": 5.0, "min": 1.0, "name": "MPC_TKO_SPEED", "shortDesc": "Takeoff climb rate", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "Multicopter Position Control", "increment": 0.5, "longDesc": "A value of 0 disables the filter.\n", "max": 50.0, "min": 0.0, "name": "MPC_VELD_LP", "shortDesc": "Velocity derivative low pass cutoff frequency", "type": "Float", "units": "Hz"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "Multicopter Position Control", "increment": 0.5, "longDesc": "A value of 0 disables the filter.\n", "max": 50.0, "min": 0.0, "name": "MPC_VEL_LP", "shortDesc": "Velocity low pass cutoff frequency", "type": "Float", "units": "Hz"}, {"category": "Standard", "decimalPlaces": 1, "default": 10.0, "group": "Multicopter Position Control", "increment": 1.0, "longDesc": "Must be smaller than MPC_XY_VEL_MAX.\n\nThe maximum sideways and backward speed can be set differently\nusing MPC_VEL_MAN_SIDE and MPC_VEL_MAN_BACK, respectively.\n", "max": 20.0, "min": 3.0, "name": "MPC_VEL_MANUAL", "shortDesc": "Maximum horizontal velocity setpoint in Position mode", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": -1.0, "group": "Multicopter Position Control", "increment": 1.0, "longDesc": "If set to a negative value or larger than\nMPC_VEL_MANUAL then MPC_VEL_MANUAL is used.\n", "max": 20.0, "min": -1.0, "name": "MPC_VEL_MAN_BACK", "shortDesc": "Maximum backward velocity in Position mode", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": -1.0, "group": "Multicopter Position Control", "increment": 1.0, "longDesc": "If set to a negative value or larger than\nMPC_VEL_MANUAL then MPC_VEL_MANUAL is used.\n", "max": 20.0, "min": -1.0, "name": "MPC_VEL_MAN_SIDE", "shortDesc": "Maximum sideways velocity in Position mode", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "Multicopter Position Control", "increment": 0.5, "longDesc": "A value of 0 disables the filter.\n", "max": 50.0, "min": 0.0, "name": "MPC_VEL_NF_BW", "shortDesc": "Velocity notch filter bandwidth", "type": "Float", "units": "Hz"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "Multicopter Position Control", "increment": 0.5, "longDesc": "The center frequency for the 2nd order notch filter on the velocity.\nA value of 0 disables the filter.\n", "max": 50.0, "min": 0.0, "name": "MPC_VEL_NF_FRQ", "shortDesc": "Velocity notch filter frequency", "type": "Float", "units": "Hz"}, {"category": "Standard", "decimalPlaces": 0, "default": 5.0, "group": "Multicopter Position Control", "increment": 1.0, "longDesc": "e.g. in Missions, Return, Goto if the waypoint does not specify differently\n", "max": 20.0, "min": 3.0, "name": "MPC_XY_CRUISE", "shortDesc": "Default horizontal velocity in autonomous modes", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 2.0, "group": "Multicopter Position Control", "increment": 1.0, "longDesc": "The integration speed of the trajectory setpoint is linearly\nreduced with the horizontal position tracking error. When the\nerror is above this parameter, the integration of the\ntrajectory is stopped to wait for the drone.\n\nThis value can be adjusted depending on the tracking\ncapabilities of the vehicle. Set to 0 to disable the horizontal\ntime-stretch.\n", "max": 10.0, "min": 0.0, "name": "MPC_XY_ERR_MAX", "shortDesc": "Maximum horizontal error allowed by the trajectory generator", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.95, "group": "Multicopter Position Control", "increment": 0.1, "longDesc": "Defined as corrective velocity in m/s per m position error\n", "max": 2.0, "min": 0.0, "name": "MPC_XY_P", "shortDesc": "Proportional gain for horizontal position error", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.5, "group": "Multicopter Position Control", "increment": 0.1, "max": 1.0, "min": 0.1, "name": "MPC_XY_TRAJ_P", "shortDesc": "Proportional gain for horizontal trajectory position error", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": -10.0, "group": "Multicopter Position Control", "increment": 1.0, "longDesc": "If set to a value greater than zero, other parameters are automatically set (such as\nMPC_XY_VEL_MAX or MPC_VEL_MANUAL).\nIf set to a negative value, the existing individual parameters are used.\n", "max": 20.0, "min": -20.0, "name": "MPC_XY_VEL_ALL", "shortDesc": "Overall Horizontal Velocity Limit", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.2, "group": "Multicopter Position Control", "increment": 0.02, "longDesc": "Defined as corrective acceleration in m/s^2 per m/s^2 velocity derivative\n", "max": 2.0, "min": 0.1, "name": "MPC_XY_VEL_D_ACC", "shortDesc": "Differential gain for horizontal velocity error", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.4, "group": "Multicopter Position Control", "increment": 0.02, "longDesc": "Defined as correction acceleration in m/s^2 per m velocity integral\nAllows to eliminate steady state errors in disturbances like wind.\n", "max": 60.0, "min": 0.0, "name": "MPC_XY_VEL_I_ACC", "shortDesc": "Integral gain for horizontal velocity error", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 12.0, "group": "Multicopter Position Control", "increment": 1.0, "longDesc": "Absolute maximum for all velocity controlled modes.\nAny higher value is truncated.\n", "max": 20.0, "min": 0.0, "name": "MPC_XY_VEL_MAX", "shortDesc": "Maximum horizontal velocity", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.8, "group": "Multicopter Position Control", "increment": 0.1, "longDesc": "Defined as corrective acceleration in m/s^2 per m/s velocity error\n", "max": 5.0, "min": 1.2, "name": "MPC_XY_VEL_P_ACC", "shortDesc": "Proportional gain for horizontal velocity error", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.0, "group": "Multicopter Position Control", "increment": 0.1, "longDesc": "Vertical analog of MPC_XY_ERR_MAX. When the smoothed trajectory z\nleads the drone by more than this value, trajectory integration is\nslowed down so the virtual setpoint can't walk away from the drone.\nThis suppresses altitude overshoots caused by a noisy altitude\nreference (e.g. mission setpoint jittering as the home altitude\nestimate is refined in flight). Set to 0 to disable the vertical\ntime-stretch.\n", "max": 10.0, "min": 0.0, "name": "MPC_Z_ERR_MAX", "shortDesc": "Maximum vertical error allowed by the trajectory generator", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Multicopter Position Control", "increment": 0.1, "longDesc": "Defined as corrective velocity in m/s per m position error\n", "max": 1.5, "min": 0.1, "name": "MPC_Z_P", "shortDesc": "Proportional gain for vertical position error", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": -3.0, "group": "Multicopter Position Control", "increment": 0.5, "longDesc": "If set to a value greater than zero, other parameters are automatically set (such as\nMPC_Z_VEL_MAX_UP or MPC_LAND_SPEED).\nIf set to a negative value, the existing individual parameters are used.\n", "max": 8.0, "min": -3.0, "name": "MPC_Z_VEL_ALL", "shortDesc": "Overall Vertical Velocity Limit", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Multicopter Position Control", "increment": 0.02, "longDesc": "Defined as corrective acceleration in m/s^2 per m/s^2 velocity derivative\n", "max": 2.0, "min": 0.0, "name": "MPC_Z_VEL_D_ACC", "shortDesc": "Differential gain for vertical velocity error", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 2.0, "group": "Multicopter Position Control", "increment": 0.1, "longDesc": "Defined as corrective acceleration in m/s^2 per m velocity integral\n", "max": 3.0, "min": 0.2, "name": "MPC_Z_VEL_I_ACC", "shortDesc": "Integral gain for vertical velocity error", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.5, "group": "Multicopter Position Control", "increment": 0.1, "longDesc": "Absolute maximum for all climb rate controlled modes.\nIn manually piloted modes full stick deflection commands this velocity.\n\nFor default autonomous velocity see MPC_Z_V_AUTO_UP\n", "max": 4.0, "min": 0.5, "name": "MPC_Z_VEL_MAX_DN", "shortDesc": "Maximum descent velocity", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "Multicopter Position Control", "increment": 0.1, "longDesc": "Absolute maximum for all climb rate controlled modes.\nIn manually piloted modes full stick deflection commands this velocity.\n\nFor default autonomous velocity see MPC_Z_V_AUTO_UP\n", "max": 8.0, "min": 0.5, "name": "MPC_Z_VEL_MAX_UP", "shortDesc": "Maximum ascent velocity", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 4.0, "group": "Multicopter Position Control", "increment": 0.1, "longDesc": "Defined as corrective acceleration in m/s^2 per m/s velocity error\n", "max": 15.0, "min": 2.0, "name": "MPC_Z_VEL_P_ACC", "shortDesc": "Proportional gain for vertical velocity error", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.5, "group": "Multicopter Position Control", "increment": 0.5, "longDesc": "For manual modes and offboard, see MPC_Z_VEL_MAX_DN\n", "max": 4.0, "min": 0.5, "name": "MPC_Z_V_AUTO_DN", "shortDesc": "Descent velocity in autonomous modes", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "Multicopter Position Control", "increment": 0.5, "longDesc": "For manually controlled modes and offboard see MPC_Z_VEL_MAX_UP\n", "max": 8.0, "min": 0.5, "name": "MPC_Z_V_AUTO_UP", "shortDesc": "Ascent velocity in autonomous modes", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": -0.4, "group": "Multicopter Position Control", "increment": 0.05, "longDesc": "Changes the overall responsiveness of the vehicle.\nThe higher the value, the faster the vehicle will react.\n\nIf set to a value greater than zero, other parameters are automatically set (such as\nthe acceleration or jerk limits).\nIf set to a negative value, the existing individual parameters are used.\n", "max": 1.0, "min": -1.0, "name": "SYS_VEHICLE_RESP", "shortDesc": "Responsiveness", "type": "Float"}, {"category": "Standard", "default": 0, "group": "Multicopter Position Control", "name": "WV_EN", "shortDesc": "Enable weathervane", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 1.0, "group": "Multicopter Position Control", "longDesc": "Minimum roll angle setpoint for weathervane controller to demand a yaw-rate\n", "max": 5.0, "min": 0.0, "name": "WV_ROLL_MIN", "shortDesc": "Minimum roll angle for weathervane yaw-rate demand", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 90.0, "group": "Multicopter Position Control", "max": 120.0, "min": 0.0, "name": "WV_YRATE_MAX", "shortDesc": "Maximum yawrate the weathervane controller is allowed to demand", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 3.0, "group": "Multicopter Position Slow Mode", "increment": 0.1, "longDesc": "This value is used in slow mode if\nno aux channel is mapped and\nno limit is commanded through MAVLink.\n", "min": 0.1, "name": "MC_SLOW_DEF_HVEL", "shortDesc": "Default horizontal velocity limit", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Multicopter Position Slow Mode", "increment": 0.1, "longDesc": "This value is used in slow mode if\nno aux channel is mapped and\nno limit is commanded through MAVLink.\n", "min": 0.1, "name": "MC_SLOW_DEF_VVEL", "shortDesc": "Default vertical velocity limit", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 45.0, "group": "Multicopter Position Slow Mode", "increment": 0.1, "longDesc": "This value is used in slow mode if\nno aux channel is mapped and\nno limit is commanded through MAVLink.\n", "min": 1.0, "name": "MC_SLOW_DEF_YAWR", "shortDesc": "Default yaw rate limit", "type": "Float", "units": "deg/s"}, {"category": "Standard", "default": 0, "group": "Multicopter Position Slow Mode", "name": "MC_SLOW_MAP_HVEL", "shortDesc": "Manual input mapped to scale horizontal velocity in position slow mode", "type": "Int32", "values": [{"description": "No rescaling", "value": 0}, {"description": "AUX1", "value": 1}, {"description": "AUX2", "value": 2}, {"description": "AUX3", "value": 3}, {"description": "AUX4", "value": 4}, {"description": "AUX5", "value": 5}, {"description": "AUX6", "value": 6}]}, {"category": "Standard", "default": 0, "group": "Multicopter Position Slow Mode", "longDesc": "RC_MAP_AUX{N} to allow for gimbal pitch rate control in position slow mode\n", "name": "MC_SLOW_MAP_PTCH", "shortDesc": "Gimbal pitch rate control input in position slow mode", "type": "Int32", "values": [{"description": "No pitch rate input", "value": 0}, {"description": "AUX1", "value": 1}, {"description": "AUX2", "value": 2}, {"description": "AUX3", "value": 3}, {"description": "AUX4", "value": 4}, {"description": "AUX5", "value": 5}, {"description": "AUX6", "value": 6}]}, {"category": "Standard", "default": 0, "group": "Multicopter Position Slow Mode", "name": "MC_SLOW_MAP_VVEL", "shortDesc": "Manual input mapped to scale vertical velocity in position slow mode", "type": "Int32", "values": [{"description": "No rescaling", "value": 0}, {"description": "AUX1", "value": 1}, {"description": "AUX2", "value": 2}, {"description": "AUX3", "value": 3}, {"description": "AUX4", "value": 4}, {"description": "AUX5", "value": 5}, {"description": "AUX6", "value": 6}]}, {"category": "Standard", "default": 0, "group": "Multicopter Position Slow Mode", "name": "MC_SLOW_MAP_YAWR", "shortDesc": "Manual input mapped to scale yaw rate in position slow mode", "type": "Int32", "values": [{"description": "No rescaling", "value": 0}, {"description": "AUX1", "value": 1}, {"description": "AUX2", "value": 2}, {"description": "AUX3", "value": 3}, {"description": "AUX4", "value": 4}, {"description": "AUX5", "value": 5}, {"description": "AUX6", "value": 6}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "Multicopter Position Slow Mode", "increment": 0.1, "longDesc": "The lowest input maps and is clamped to this velocity.\n", "min": 0.1, "name": "MC_SLOW_MIN_HVEL", "shortDesc": "Horizontal velocity lower limit", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "Multicopter Position Slow Mode", "increment": 0.1, "longDesc": "The lowest input maps and is clamped to this velocity.\n", "min": 0.1, "name": "MC_SLOW_MIN_VVEL", "shortDesc": "Vertical velocity lower limit", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "Multicopter Position Slow Mode", "increment": 0.1, "longDesc": "The lowest input maps and is clamped to this rate.\n", "min": 1.0, "name": "MC_SLOW_MIN_YAWR", "shortDesc": "Yaw rate lower limit", "type": "Float", "units": "deg/s"}, {"category": "Standard", "default": 0, "group": "Multicopter Rate Control", "longDesc": "This compensates for voltage drop of the battery over time by attempting to\nnormalize performance across the operating range of the battery. The copter\nshould constantly behave as if it was fully charged with reduced max acceleration\nat lower battery percentages. i.e. if hover is at 0.5 throttle at 100% battery,\nit will still be 0.5 at 60% battery.\n", "name": "MC_BAT_SCALE_EN", "shortDesc": "Battery power level scaler", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Multicopter Rate Control", "longDesc": "Dynamically reduces the rate controller output gain when an oscillation\n(limit cycle) is detected on the torque setpoint, e.g. caused by too high gains.\nThe gain recovers to 1.0 once the oscillation stops.\n\n", "name": "MC_GC_EN", "shortDesc": "Enable rate gain compression", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "Multicopter Rate Control", "increment": 0.01, "longDesc": "The range of the compression gain is between this parameter and 1.0\n", "max": 1.0, "min": 0.0, "name": "MC_GC_GAIN_MIN", "shortDesc": "Compression gain lower limit", "type": "Float"}, {"category": "Standard", "decimalPlaces": 4, "default": 0.003, "group": "Multicopter Rate Control", "increment": 0.0005, "longDesc": "Pitch rate differential gain. Small values help reduce fast oscillations. If value is too big oscillations will appear again.\n", "min": 0.0, "name": "MC_PITCHRATE_D", "shortDesc": "Pitch rate D gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 4, "default": 0.0, "group": "Multicopter Rate Control", "longDesc": "Improves tracking performance.\n", "min": 0.0, "name": "MC_PITCHRATE_FF", "shortDesc": "Pitch rate feedforward", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.2, "group": "Multicopter Rate Control", "increment": 0.01, "longDesc": "Pitch rate integral gain. Can be set to compensate static thrust difference or gravity center offset.\n", "min": 0.0, "name": "MC_PITCHRATE_I", "shortDesc": "Pitch rate I gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 4, "default": 1.0, "group": "Multicopter Rate Control", "increment": 0.0005, "longDesc": "Global gain of the controller.\n\nThis gain scales the P, I and D terms of the controller:\n```\noutput = MC_PITCHRATE_K * (MC_PITCHRATE_P * error\n+ MC_PITCHRATE_I * error_integral\n+ MC_PITCHRATE_D * error_derivative)\n```\nSet MC_PITCHRATE_P=1 to implement a PID in the ideal form.\nSet MC_PITCHRATE_K=1 to implement a PID in the parallel form.\n", "max": 5.0, "min": 0.01, "name": "MC_PITCHRATE_K", "shortDesc": "Pitch rate controller gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.15, "group": "Multicopter Rate Control", "increment": 0.01, "longDesc": "Pitch rate proportional gain, i.e. control output for angular speed error 1 rad/s.\n", "max": 0.6, "min": 0.01, "name": "MC_PITCHRATE_P", "shortDesc": "Pitch rate P gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "Multicopter Rate Control", "increment": 0.01, "longDesc": "Pitch rate integrator limit. Can be set to increase the amount of integrator available to counteract disturbances or reduced to improve settling time after large pitch moment trim changes.\n", "min": 0.0, "name": "MC_PR_INT_LIM", "shortDesc": "Pitch rate integrator limit", "type": "Float"}, {"category": "Standard", "decimalPlaces": 4, "default": 0.003, "group": "Multicopter Rate Control", "increment": 0.0005, "longDesc": "Roll rate differential gain. Small values help reduce fast oscillations. If value is too big oscillations will appear again.\n", "max": 0.01, "min": 0.0, "name": "MC_ROLLRATE_D", "shortDesc": "Roll rate D gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 4, "default": 0.0, "group": "Multicopter Rate Control", "longDesc": "Improves tracking performance.\n", "min": 0.0, "name": "MC_ROLLRATE_FF", "shortDesc": "Roll rate feedforward", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.2, "group": "Multicopter Rate Control", "increment": 0.01, "longDesc": "Roll rate integral gain. Can be set to compensate static thrust difference or gravity center offset.\n", "min": 0.0, "name": "MC_ROLLRATE_I", "shortDesc": "Roll rate I gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 4, "default": 1.0, "group": "Multicopter Rate Control", "increment": 0.0005, "longDesc": "Global gain of the controller.\n\nThis gain scales the P, I and D terms of the controller:\n```\noutput = MC_ROLLRATE_K * (MC_ROLLRATE_P * error\n+ MC_ROLLRATE_I * error_integral\n+ MC_ROLLRATE_D * error_derivative)\n```\nSet MC_ROLLRATE_P=1 to implement a PID in the ideal form.\nSet MC_ROLLRATE_K=1 to implement a PID in the parallel form.\n", "max": 5.0, "min": 0.01, "name": "MC_ROLLRATE_K", "shortDesc": "Roll rate controller gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.15, "group": "Multicopter Rate Control", "increment": 0.01, "longDesc": "Roll rate proportional gain, i.e. control output for angular speed error 1 rad/s.\n", "max": 0.5, "min": 0.01, "name": "MC_ROLLRATE_P", "shortDesc": "Roll rate P gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "Multicopter Rate Control", "increment": 0.01, "longDesc": "Roll rate integrator limit. Can be set to increase the amount of integrator available to counteract disturbances or reduced to improve settling time after large roll moment trim changes.\n", "min": 0.0, "name": "MC_RR_INT_LIM", "shortDesc": "Roll rate integrator limit", "type": "Float"}, {"category": "Standard", "decimalPlaces": 4, "default": 0.0, "group": "Multicopter Rate Control", "increment": 0.0005, "longDesc": "Yaw rate differential gain. Small values help reduce fast oscillations. If value is too big oscillations will appear again.\n", "min": 0.0, "name": "MC_YAWRATE_D", "shortDesc": "Yaw rate D gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 4, "default": 0.0, "group": "Multicopter Rate Control", "longDesc": "Improves tracking performance.\n", "min": 0.0, "name": "MC_YAWRATE_FF", "shortDesc": "Yaw rate feedforward", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.1, "group": "Multicopter Rate Control", "increment": 0.01, "longDesc": "Yaw rate integral gain. Can be set to compensate static thrust difference or gravity center offset.\n", "min": 0.0, "name": "MC_YAWRATE_I", "shortDesc": "Yaw rate I gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 4, "default": 1.0, "group": "Multicopter Rate Control", "increment": 0.0005, "longDesc": "Global gain of the controller.\n\nThis gain scales the P, I and D terms of the controller:\n```\noutput = MC_YAWRATE_K * (MC_YAWRATE_P * error\n+ MC_YAWRATE_I * error_integral\n+ MC_YAWRATE_D * error_derivative)\n```\nSet MC_YAWRATE_P=1 to implement a PID in the ideal form.\nSet MC_YAWRATE_K=1 to implement a PID in the parallel form.\n", "max": 5.0, "min": 0.01, "name": "MC_YAWRATE_K", "shortDesc": "Yaw rate controller gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.2, "group": "Multicopter Rate Control", "increment": 0.01, "longDesc": "Yaw rate proportional gain, i.e. control output for angular speed error 1 rad/s.\n", "max": 0.6, "min": 0.0, "name": "MC_YAWRATE_P", "shortDesc": "Yaw rate P gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 2.0, "group": "Multicopter Rate Control", "longDesc": "Reduces vibrations by lowering high frequency torque caused by rotor acceleration.\n0 disables the filter\n", "max": 10.0, "min": 0.0, "name": "MC_YAW_TQ_CUTOFF", "shortDesc": "Low pass filter cutoff frequency for yaw torque setpoint", "type": "Float", "units": "Hz"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "Multicopter Rate Control", "increment": 0.01, "longDesc": "Yaw rate integrator limit. Can be set to increase the amount of integrator available to counteract disturbances or reduced to improve settling time after large yaw moment trim changes.\n", "min": 0.0, "name": "MC_YR_INT_LIM", "shortDesc": "Yaw rate integrator limit", "type": "Float"}, {"category": "Standard", "default": 0, "group": "OSD", "longDesc": "Controls the horizontal position of the crosshair display.\nResolution is limited by OSD to 15 discrete values. Negative\nvalues will display the crosshairs left of the center of the screen\n\n", "max": 8, "min": -8, "name": "OSD_CH_POS_HOR", "shortDesc": "OSD Crosshairs Horizontal Position", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "OSD", "longDesc": "Controls the vertical position of the crosshair display.\nResolution is limited by OSD to 15 discrete values. Negative\nvalues will display the crosshairs below the horizon\n\n", "max": 8, "min": -8, "name": "OSD_CH_POS_VER", "shortDesc": "OSD Crosshairs Vertical Position", "type": "Int32"}, {"category": "Standard", "default": 500, "group": "OSD", "longDesc": "Amount of time to dwell at the beginning of the display, when scrolling.\n\n", "max": 10000, "min": 100, "name": "OSD_DWELL_TIME", "shortDesc": "OSD Dwell Time", "type": "Int32", "units": "ms"}, {"category": "Standard", "default": 3, "group": "OSD", "longDesc": "Minimum security of log level to display on the OSD.\n\n", "name": "OSD_LOG_LEVEL", "shortDesc": "OSD Warning Level", "type": "Int32"}, {"category": "Standard", "default": 1, "group": "OSD", "longDesc": "Forward RC stick input to VTX when disarmed\n\n", "max": 1, "min": 0, "name": "OSD_RC_STICK", "shortDesc": "OSD RC Stick commands", "type": "Int32"}, {"category": "Standard", "default": 125, "group": "OSD", "longDesc": "Scroll rate for OSD messages longer than available character width.\nThis is lower-bounded by the nominal loop rate of this module.\n\n", "max": 1000, "min": 100, "name": "OSD_SCROLL_RATE", "shortDesc": "OSD Scroll Rate", "type": "Int32", "units": "ms"}, {"bitmask": [{"description": "CRAFT_NAME", "index": 0}, {"description": "DISARMED", "index": 1}, {"description": "GPS_LAT", "index": 2}, {"description": "GPS_LON", "index": 3}, {"description": "GPS_SATS", "index": 4}, {"description": "GPS_SPEED", "index": 5}, {"description": "HOME_DIST", "index": 6}, {"description": "(unused) HOME_DIR", "index": 7}, {"description": "(unused) MAIN_BATT_VOLTAGE", "index": 8}, {"description": "CURRENT_DRAW", "index": 9}, {"description": "MAH_DRAWN", "index": 10}, {"description": "RSSI_VALUE", "index": 11}, {"description": "ALTITUDE", "index": 12}, {"description": "(unused) NUMERICAL_VARIO", "index": 13}, {"description": "(unused) FLYMODE", "index": 14}, {"description": "(unused) ESC_TMP", "index": 15}, {"description": "PITCH_ANGLE", "index": 16}, {"description": "ROLL_ANGLE", "index": 17}, {"description": "CROSSHAIRS", "index": 18}, {"description": "AVG_CELL_VOLTAGE", "index": 19}, {"description": "(unused) HORIZON_SIDEBARS", "index": 20}, {"description": "(unused) POWER", "index": 21}], "category": "Standard", "default": 16383, "group": "OSD", "longDesc": "Configure / toggle support display options.\n\n", "max": 4194303, "min": 0, "name": "OSD_SYMBOLS", "shortDesc": "OSD Symbol Selection", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "PWM Outputs", "increment": 0.1, "longDesc": "Parameter used to model the nonlinear relationship between\nmotor control signal (e.g. PWM) and static thrust.\n\nThe model is:\n\n```\nrel_thrust = factor * rel_signal^2 + (1-factor) * rel_signal\n```\n, where rel_thrust is the normalized thrust between 0 and 1, and\nrel_signal is the relative motor control signal between 0 and 1.\n", "max": 1.0, "min": 0.0, "name": "THR_MDL_FAC", "shortDesc": "Thrust to motor control signal model parameter", "type": "Float"}, {"category": "Standard", "default": 1.0, "group": "Payload Deliverer", "longDesc": "Maximum time Gripper will wait while the successful griper actuation isn't recognised.\nIf the gripper has no feedback sensor, it will simply wait for\nthis time before considering gripper actuation successful and publish a\n'VehicleCommandAck' signaling successful gripper action\n\n", "min": 0.0, "name": "PD_GRIPPER_TO", "shortDesc": "Timeout for successful gripper actuation acknowledgement", "type": "Float", "units": "s"}, {"category": "Standard", "default": 0, "group": "Payload Deliverer", "longDesc": "Selects the types of control actions the gripper accepts.\n\n", "max": 0, "min": -1, "name": "PD_GRIPPER_TYPE", "shortDesc": "Gripper control type", "type": "Int32", "values": [{"description": "Undefined", "value": -1}, {"description": "Binary Grab/Release", "value": 0}]}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "Precision Land", "increment": 0.5, "longDesc": "Time after which the landing target is considered lost without any new measurements.\n", "max": 50.0, "min": 0.0, "name": "PLD_BTOUT", "shortDesc": "Landing Target Timeout", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "Precision Land", "increment": 0.1, "longDesc": "Allow final approach (without horizontal positioning) if losing landing target closer than this to the ground.\n", "max": 10.0, "min": 0.0, "name": "PLD_FAPPR_ALT", "shortDesc": "Final approach altitude", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.2, "group": "Precision Land", "increment": 0.1, "longDesc": "Start descending if closer above landing target than this.\n", "max": 10.0, "min": 0.0, "name": "PLD_HACC_RAD", "shortDesc": "Horizontal acceptance radius", "type": "Float", "units": "m"}, {"category": "Standard", "default": 3, "group": "Precision Land", "longDesc": "Maximum number of times to search for the landing target if it is lost during the precision landing.\n", "max": 100, "min": 0, "name": "PLD_MAX_SRCH", "shortDesc": "Maximum number of search attempts", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 2, "default": 3.0, "group": "Precision Land", "longDesc": "When the landing target is moving, precision land aims at the estimated future\ntarget position after a constrained prediction time. This sets the maximum time.\n", "max": 60.0, "min": 0.1, "name": "PLD_MOVING_T_MAX", "shortDesc": "Maximum moving-target prediction time", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 2.0, "group": "Precision Land", "longDesc": "When the landing target is moving, precision land aims at the estimated future\ntarget position after a constrained prediction time. This sets the minimum time.\n", "max": 30.0, "min": 0.1, "name": "PLD_MOVING_T_MIN", "shortDesc": "Minimum moving-target prediction time", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 10.0, "group": "Precision Land", "increment": 0.1, "longDesc": "Altitude above home to which to climb when searching for the landing target.\n", "max": 100.0, "min": 0.0, "name": "PLD_SRCH_ALT", "shortDesc": "Search altitude", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 10.0, "group": "Precision Land", "increment": 0.1, "longDesc": "Time allowed to search for the landing target before falling back to normal landing.\n", "max": 100.0, "min": 0.0, "name": "PLD_SRCH_TOUT", "shortDesc": "Search timeout", "type": "Float", "units": "s"}, {"category": "Standard", "default": 0, "group": "Precision Land", "longDesc": "Control the orientation when landing. The orientation comes from the topic vte_orientation.\n", "max": 1, "min": 0, "name": "PLD_YAW_EN", "shortDesc": "Set to true to control yaw while landing", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Pure Pursuit", "increment": 0.01, "longDesc": "Lower value -> More aggressive controller (beware overshoot/oscillations)\n", "max": 100.0, "min": 0.1, "name": "PP_LOOKAHD_GAIN", "shortDesc": "Tuning parameter for the pure pursuit controller", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 10.0, "group": "Pure Pursuit", "increment": 0.01, "max": 100.0, "min": 0.1, "name": "PP_LOOKAHD_MAX", "shortDesc": "Maximum lookahead distance for the pure pursuit controller", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Pure Pursuit", "increment": 0.01, "max": 100.0, "min": 0.1, "name": "PP_LOOKAHD_MIN", "shortDesc": "Minimum lookahead distance for the pure pursuit controller", "type": "Float", "units": "m"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC10_MAX", "shortDesc": "RC channel 10 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC10_MIN", "shortDesc": "RC channel 10 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC10_REV", "shortDesc": "RC channel 10 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC10_TRIM", "shortDesc": "RC channel 10 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC11_MAX", "shortDesc": "RC channel 11 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC11_MIN", "shortDesc": "RC channel 11 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC11_REV", "shortDesc": "RC channel 11 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC11_TRIM", "shortDesc": "RC channel 11 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC12_MAX", "shortDesc": "RC channel 12 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC12_MIN", "shortDesc": "RC channel 12 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC12_REV", "shortDesc": "RC channel 12 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC12_TRIM", "shortDesc": "RC channel 12 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC13_MAX", "shortDesc": "RC channel 13 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC13_MIN", "shortDesc": "RC channel 13 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC13_REV", "shortDesc": "RC channel 13 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC13_TRIM", "shortDesc": "RC channel 13 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC14_MAX", "shortDesc": "RC channel 14 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC14_MIN", "shortDesc": "RC channel 14 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC14_REV", "shortDesc": "RC channel 14 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC14_TRIM", "shortDesc": "RC channel 14 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC15_MAX", "shortDesc": "RC channel 15 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC15_MIN", "shortDesc": "RC channel 15 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC15_REV", "shortDesc": "RC channel 15 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC15_TRIM", "shortDesc": "RC channel 15 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC16_MAX", "shortDesc": "RC channel 16 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC16_MIN", "shortDesc": "RC channel 16 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC16_REV", "shortDesc": "RC channel 16 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC16_TRIM", "shortDesc": "RC channel 16 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC17_MAX", "shortDesc": "RC channel 17 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC17_MIN", "shortDesc": "RC channel 17 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC17_REV", "shortDesc": "RC channel 17 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC17_TRIM", "shortDesc": "RC channel 17 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC18_MAX", "shortDesc": "RC channel 18 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC18_MIN", "shortDesc": "RC channel 18 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC18_REV", "shortDesc": "RC channel 18 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC18_TRIM", "shortDesc": "RC channel 18 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for RC channel 1\n", "max": 2200.0, "min": 1500.0, "name": "RC1_MAX", "shortDesc": "RC channel 1 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for RC channel 1\n", "max": 1500.0, "min": 800.0, "name": "RC1_MIN", "shortDesc": "RC channel 1 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC1_REV", "shortDesc": "RC channel 1 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC1_TRIM", "shortDesc": "RC channel 1 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC2_MAX", "shortDesc": "RC channel 2 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC2_MIN", "shortDesc": "RC channel 2 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC2_REV", "shortDesc": "RC channel 2 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC2_TRIM", "shortDesc": "RC channel 2 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC3_MAX", "shortDesc": "RC channel 3 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC3_MIN", "shortDesc": "RC channel 3 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC3_REV", "shortDesc": "RC channel 3 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC3_TRIM", "shortDesc": "RC channel 3 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC4_MAX", "shortDesc": "RC channel 4 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC4_MIN", "shortDesc": "RC channel 4 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC4_REV", "shortDesc": "RC channel 4 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC4_TRIM", "shortDesc": "RC channel 4 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC5_MAX", "shortDesc": "RC channel 5 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC5_MIN", "shortDesc": "RC channel 5 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC5_REV", "shortDesc": "RC channel 5 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC5_TRIM", "shortDesc": "RC channel 5 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC6_MAX", "shortDesc": "RC channel 6 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC6_MIN", "shortDesc": "RC channel 6 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC6_REV", "shortDesc": "RC channel 6 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC6_TRIM", "shortDesc": "RC channel 6 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC7_MAX", "shortDesc": "RC channel 7 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC7_MIN", "shortDesc": "RC channel 7 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC7_REV", "shortDesc": "RC channel 7 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC7_TRIM", "shortDesc": "RC channel 7 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC8_MAX", "shortDesc": "RC channel 8 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC8_MIN", "shortDesc": "RC channel 8 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC8_REV", "shortDesc": "RC channel 8 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC8_TRIM", "shortDesc": "RC channel 8 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC9_MAX", "shortDesc": "RC channel 9 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC9_MIN", "shortDesc": "RC channel 9 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC9_REV", "shortDesc": "RC channel 9 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC9_TRIM", "shortDesc": "RC channel 9 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "longDesc": "Number of channels detected during RC calibration. Must be non-zero\nfor RC manual control input to be accepted.\n", "max": 18, "min": 0, "name": "RC_CHAN_CNT", "shortDesc": "Calibrated RC channel count", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "longDesc": "Use RC_MAP_FAILSAFE to specify which channel is used to indicate RC loss via this threshold.\nBy default this is the throttle channel.\n\nSet to a PWM value slightly above the PWM value for the channel (e.g. throttle) in a failsafe event,\nbut below the minimum PWM value for the channel during normal operation.\n\nNote: The default value of 0 disables the feature (it is below the expected range).\n", "max": 2200, "min": 0, "name": "RC_FAILS_THR", "shortDesc": "Failsafe channel PWM threshold", "type": "Int32", "units": "us"}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "max": 18, "min": 0, "name": "RC_MAP_AUX1", "shortDesc": "AUX1 Passthrough RC channel", "type": "Int32", "values": [{"description": "Unassigned", "value": 0}, {"description": "Channel 1", "value": 1}, {"description": "Channel 2", "value": 2}, {"description": "Channel 3", "value": 3}, {"description": "Channel 4", "value": 4}, {"description": "Channel 5", "value": 5}, {"description": "Channel 6", "value": 6}, {"description": "Channel 7", "value": 7}, {"description": "Channel 8", "value": 8}, {"description": "Channel 9", "value": 9}, {"description": "Channel 10", "value": 10}, {"description": "Channel 11", "value": 11}, {"description": "Channel 12", "value": 12}, {"description": "Channel 13", "value": 13}, {"description": "Channel 14", "value": 14}, {"description": "Channel 15", "value": 15}, {"description": "Channel 16", "value": 16}, {"description": "Channel 17", "value": 17}, {"description": "Channel 18", "value": 18}]}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "max": 18, "min": 0, "name": "RC_MAP_AUX2", "shortDesc": "AUX2 Passthrough RC channel", "type": "Int32", "values": [{"description": "Unassigned", "value": 0}, {"description": "Channel 1", "value": 1}, {"description": "Channel 2", "value": 2}, {"description": "Channel 3", "value": 3}, {"description": "Channel 4", "value": 4}, {"description": "Channel 5", "value": 5}, {"description": "Channel 6", "value": 6}, {"description": "Channel 7", "value": 7}, {"description": "Channel 8", "value": 8}, {"description": "Channel 9", "value": 9}, {"description": "Channel 10", "value": 10}, {"description": "Channel 11", "value": 11}, {"description": "Channel 12", "value": 12}, {"description": "Channel 13", "value": 13}, {"description": "Channel 14", "value": 14}, {"description": "Channel 15", "value": 15}, {"description": "Channel 16", "value": 16}, {"description": "Channel 17", "value": 17}, {"description": "Channel 18", "value": 18}]}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "max": 18, "min": 0, "name": "RC_MAP_AUX3", "shortDesc": "AUX3 Passthrough RC channel", "type": "Int32", "values": [{"description": "Unassigned", "value": 0}, {"description": "Channel 1", "value": 1}, {"description": "Channel 2", "value": 2}, {"description": "Channel 3", "value": 3}, {"description": "Channel 4", "value": 4}, {"description": "Channel 5", "value": 5}, {"description": "Channel 6", "value": 6}, {"description": "Channel 7", "value": 7}, {"description": "Channel 8", "value": 8}, {"description": "Channel 9", "value": 9}, {"description": "Channel 10", "value": 10}, {"description": "Channel 11", "value": 11}, {"description": "Channel 12", "value": 12}, {"description": "Channel 13", "value": 13}, {"description": "Channel 14", "value": 14}, {"description": "Channel 15", "value": 15}, {"description": "Channel 16", "value": 16}, {"description": "Channel 17", "value": 17}, {"description": "Channel 18", "value": 18}]}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "max": 18, "min": 0, "name": "RC_MAP_AUX4", "shortDesc": "AUX4 Passthrough RC channel", "type": "Int32", "values": [{"description": "Unassigned", "value": 0}, {"description": "Channel 1", "value": 1}, {"description": "Channel 2", "value": 2}, {"description": "Channel 3", "value": 3}, {"description": "Channel 4", "value": 4}, {"description": "Channel 5", "value": 5}, {"description": "Channel 6", "value": 6}, {"description": "Channel 7", "value": 7}, {"description": "Channel 8", "value": 8}, {"description": "Channel 9", "value": 9}, {"description": "Channel 10", "value": 10}, {"description": "Channel 11", "value": 11}, {"description": "Channel 12", "value": 12}, {"description": "Channel 13", "value": 13}, {"description": "Channel 14", "value": 14}, {"description": "Channel 15", "value": 15}, {"description": "Channel 16", "value": 16}, {"description": "Channel 17", "value": 17}, {"description": "Channel 18", "value": 18}]}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "max": 18, "min": 0, "name": "RC_MAP_AUX5", "shortDesc": "AUX5 Passthrough RC channel", "type": "Int32", "values": [{"description": "Unassigned", "value": 0}, {"description": "Channel 1", "value": 1}, {"description": "Channel 2", "value": 2}, {"description": "Channel 3", "value": 3}, {"description": "Channel 4", "value": 4}, {"description": "Channel 5", "value": 5}, {"description": "Channel 6", "value": 6}, {"description": "Channel 7", "value": 7}, {"description": "Channel 8", "value": 8}, {"description": "Channel 9", "value": 9}, {"description": "Channel 10", "value": 10}, {"description": "Channel 11", "value": 11}, {"description": "Channel 12", "value": 12}, {"description": "Channel 13", "value": 13}, {"description": "Channel 14", "value": 14}, {"description": "Channel 15", "value": 15}, {"description": "Channel 16", "value": 16}, {"description": "Channel 17", "value": 17}, {"description": "Channel 18", "value": 18}]}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "max": 18, "min": 0, "name": "RC_MAP_AUX6", "shortDesc": "AUX6 Passthrough RC channel", "type": "Int32", "values": [{"description": "Unassigned", "value": 0}, {"description": "Channel 1", "value": 1}, {"description": "Channel 2", "value": 2}, {"description": "Channel 3", "value": 3}, {"description": "Channel 4", "value": 4}, {"description": "Channel 5", "value": 5}, {"description": "Channel 6", "value": 6}, {"description": "Channel 7", "value": 7}, {"description": "Channel 8", "value": 8}, {"description": "Channel 9", "value": 9}, {"description": "Channel 10", "value": 10}, {"description": "Channel 11", "value": 11}, {"description": "Channel 12", "value": 12}, {"description": "Channel 13", "value": 13}, {"description": "Channel 14", "value": 14}, {"description": "Channel 15", "value": 15}, {"description": "Channel 16", "value": 16}, {"description": "Channel 17", "value": 17}, {"description": "Channel 18", "value": 18}]}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "max": 18, "min": 0, "name": "RC_MAP_ENG_MOT", "shortDesc": "RC channel to engage the main motor (for helicopters)", "type": "Int32", "values": [{"description": "Unassigned", "value": 0}, {"description": "Channel 1", "value": 1}, {"description": "Channel 2", "value": 2}, {"description": "Channel 3", "value": 3}, {"description": "Channel 4", "value": 4}, {"description": "Channel 5", "value": 5}, {"description": "Channel 6", "value": 6}, {"description": "Channel 7", "value": 7}, {"description": "Channel 8", "value": 8}, {"description": "Channel 9", "value": 9}, {"description": "Channel 10", "value": 10}, {"description": "Channel 11", "value": 11}, {"description": "Channel 12", "value": 12}, {"description": "Channel 13", "value": 13}, {"description": "Channel 14", "value": 14}, {"description": "Channel 15", "value": 15}, {"description": "Channel 16", "value": 16}, {"description": "Channel 17", "value": 17}, {"description": "Channel 18", "value": 18}]}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "longDesc": "Configures which RC channel is used by the receiver to indicate the signal was lost\n(on receivers that use output a fixed signal value to report lost signal).\nIf set to 0, the channel mapped to throttle is used.\n\nUse RC_FAILS_THR to set the threshold indicating lost signal. By default it's below\nthe expected range and hence disabled.\n", "max": 18, "min": 0, "name": "RC_MAP_FAILSAFE", "shortDesc": "Failsafe channel mapping", "type": "Int32", "values": [{"description": "Unassigned", "value": 0}, {"description": "Channel 1", "value": 1}, {"description": "Channel 2", "value": 2}, {"description": "Channel 3", "value": 3}, {"description": "Channel 4", "value": 4}, {"description": "Channel 5", "value": 5}, {"description": "Channel 6", "value": 6}, {"description": "Channel 7", "value": 7}, {"description": "Channel 8", "value": 8}, {"description": "Channel 9", "value": 9}, {"description": "Channel 10", "value": 10}, {"description": "Channel 11", "value": 11}, {"description": "Channel 12", "value": 12}, {"description": "Channel 13", "value": 13}, {"description": "Channel 14", "value": 14}, {"description": "Channel 15", "value": 15}, {"description": "Channel 16", "value": 16}, {"description": "Channel 17", "value": 17}, {"description": "Channel 18", "value": 18}]}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "longDesc": "Can be used for parameter tuning with the RC. This one is further referenced as the 1st parameter channel.\nSet to 0 to deactivate *\n", "max": 18, "min": 0, "name": "RC_MAP_PARAM1", "shortDesc": "PARAM1 tuning channel", "type": "Int32", "values": [{"description": "Unassigned", "value": 0}, {"description": "Channel 1", "value": 1}, {"description": "Channel 2", "value": 2}, {"description": "Channel 3", "value": 3}, {"description": "Channel 4", "value": 4}, {"description": "Channel 5", "value": 5}, {"description": "Channel 6", "value": 6}, {"description": "Channel 7", "value": 7}, {"description": "Channel 8", "value": 8}, {"description": "Channel 9", "value": 9}, {"description": "Channel 10", "value": 10}, {"description": "Channel 11", "value": 11}, {"description": "Channel 12", "value": 12}, {"description": "Channel 13", "value": 13}, {"description": "Channel 14", "value": 14}, {"description": "Channel 15", "value": 15}, {"description": "Channel 16", "value": 16}, {"description": "Channel 17", "value": 17}, {"description": "Channel 18", "value": 18}]}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "longDesc": "Can be used for parameter tuning with the RC. This one is further referenced as the 2nd parameter channel.\nSet to 0 to deactivate *\n", "max": 18, "min": 0, "name": "RC_MAP_PARAM2", "shortDesc": "PARAM2 tuning channel", "type": "Int32", "values": [{"description": "Unassigned", "value": 0}, {"description": "Channel 1", "value": 1}, {"description": "Channel 2", "value": 2}, {"description": "Channel 3", "value": 3}, {"description": "Channel 4", "value": 4}, {"description": "Channel 5", "value": 5}, {"description": "Channel 6", "value": 6}, {"description": "Channel 7", "value": 7}, {"description": "Channel 8", "value": 8}, {"description": "Channel 9", "value": 9}, {"description": "Channel 10", "value": 10}, {"description": "Channel 11", "value": 11}, {"description": "Channel 12", "value": 12}, {"description": "Channel 13", "value": 13}, {"description": "Channel 14", "value": 14}, {"description": "Channel 15", "value": 15}, {"description": "Channel 16", "value": 16}, {"description": "Channel 17", "value": 17}, {"description": "Channel 18", "value": 18}]}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "longDesc": "Can be used for parameter tuning with the RC. This one is further referenced as the 3th parameter channel.\nSet to 0 to deactivate *\n", "max": 18, "min": 0, "name": "RC_MAP_PARAM3", "shortDesc": "PARAM3 tuning channel", "type": "Int32", "values": [{"description": "Unassigned", "value": 0}, {"description": "Channel 1", "value": 1}, {"description": "Channel 2", "value": 2}, {"description": "Channel 3", "value": 3}, {"description": "Channel 4", "value": 4}, {"description": "Channel 5", "value": 5}, {"description": "Channel 6", "value": 6}, {"description": "Channel 7", "value": 7}, {"description": "Channel 8", "value": 8}, {"description": "Channel 9", "value": 9}, {"description": "Channel 10", "value": 10}, {"description": "Channel 11", "value": 11}, {"description": "Channel 12", "value": 12}, {"description": "Channel 13", "value": 13}, {"description": "Channel 14", "value": 14}, {"description": "Channel 15", "value": 15}, {"description": "Channel 16", "value": 16}, {"description": "Channel 17", "value": 17}, {"description": "Channel 18", "value": 18}]}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "longDesc": "The channel index (starting from 1 for channel 1) indicates\nwhich channel should be used for reading pitch inputs from.\nA value of zero indicates the switch is not assigned.\n", "max": 18, "min": 0, "name": "RC_MAP_PITCH", "shortDesc": "Pitch control channel mapping", "type": "Int32", "values": [{"description": "Unassigned", "value": 0}, {"description": "Channel 1", "value": 1}, {"description": "Channel 2", "value": 2}, {"description": "Channel 3", "value": 3}, {"description": "Channel 4", "value": 4}, {"description": "Channel 5", "value": 5}, {"description": "Channel 6", "value": 6}, {"description": "Channel 7", "value": 7}, {"description": "Channel 8", "value": 8}, {"description": "Channel 9", "value": 9}, {"description": "Channel 10", "value": 10}, {"description": "Channel 11", "value": 11}, {"description": "Channel 12", "value": 12}, {"description": "Channel 13", "value": 13}, {"description": "Channel 14", "value": 14}, {"description": "Channel 15", "value": 15}, {"description": "Channel 16", "value": 16}, {"description": "Channel 17", "value": 17}, {"description": "Channel 18", "value": 18}]}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "longDesc": "The channel index (starting from 1 for channel 1) indicates\nwhich channel should be used for reading roll inputs from.\nA value of zero indicates the switch is not assigned.\n", "max": 18, "min": 0, "name": "RC_MAP_ROLL", "shortDesc": "Roll control channel mapping", "type": "Int32", "values": [{"description": "Unassigned", "value": 0}, {"description": "Channel 1", "value": 1}, {"description": "Channel 2", "value": 2}, {"description": "Channel 3", "value": 3}, {"description": "Channel 4", "value": 4}, {"description": "Channel 5", "value": 5}, {"description": "Channel 6", "value": 6}, {"description": "Channel 7", "value": 7}, {"description": "Channel 8", "value": 8}, {"description": "Channel 9", "value": 9}, {"description": "Channel 10", "value": 10}, {"description": "Channel 11", "value": 11}, {"description": "Channel 12", "value": 12}, {"description": "Channel 13", "value": 13}, {"description": "Channel 14", "value": 14}, {"description": "Channel 15", "value": 15}, {"description": "Channel 16", "value": 16}, {"description": "Channel 17", "value": 17}, {"description": "Channel 18", "value": 18}]}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "longDesc": "The channel index (starting from 1 for channel 1) indicates\nwhich channel should be used for reading throttle inputs from.\nA value of zero indicates the switch is not assigned.\n", "max": 18, "min": 0, "name": "RC_MAP_THROTTLE", "shortDesc": "Throttle control channel mapping", "type": "Int32", "values": [{"description": "Unassigned", "value": 0}, {"description": "Channel 1", "value": 1}, {"description": "Channel 2", "value": 2}, {"description": "Channel 3", "value": 3}, {"description": "Channel 4", "value": 4}, {"description": "Channel 5", "value": 5}, {"description": "Channel 6", "value": 6}, {"description": "Channel 7", "value": 7}, {"description": "Channel 8", "value": 8}, {"description": "Channel 9", "value": 9}, {"description": "Channel 10", "value": 10}, {"description": "Channel 11", "value": 11}, {"description": "Channel 12", "value": 12}, {"description": "Channel 13", "value": 13}, {"description": "Channel 14", "value": 14}, {"description": "Channel 15", "value": 15}, {"description": "Channel 16", "value": 16}, {"description": "Channel 17", "value": 17}, {"description": "Channel 18", "value": 18}]}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "longDesc": "The channel index (starting from 1 for channel 1) indicates\nwhich channel should be used for reading yaw inputs from.\nA value of zero indicates the switch is not assigned.\n", "max": 18, "min": 0, "name": "RC_MAP_YAW", "shortDesc": "Yaw control channel mapping", "type": "Int32", "values": [{"description": "Unassigned", "value": 0}, {"description": "Channel 1", "value": 1}, {"description": "Channel 2", "value": 2}, {"description": "Channel 3", "value": 3}, {"description": "Channel 4", "value": 4}, {"description": "Channel 5", "value": 5}, {"description": "Channel 6", "value": 6}, {"description": "Channel 7", "value": 7}, {"description": "Channel 8", "value": 8}, {"description": "Channel 9", "value": 9}, {"description": "Channel 10", "value": 10}, {"description": "Channel 11", "value": 11}, {"description": "Channel 12", "value": 12}, {"description": "Channel 13", "value": 13}, {"description": "Channel 14", "value": 14}, {"description": "Channel 15", "value": 15}, {"description": "Channel 16", "value": 16}, {"description": "Channel 17", "value": 17}, {"description": "Channel 18", "value": 18}]}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "longDesc": "0: do not read RSSI from input channel\n1-18: read RSSI from specified input channel\n\nSpecify the range for RSSI input with RC_RSSI_PWM_MIN and RC_RSSI_PWM_MAX parameters.\n", "max": 18, "min": 0, "name": "RC_RSSI_PWM_CHAN", "shortDesc": "PWM input channel that provides RSSI", "type": "Int32", "values": [{"description": "Unassigned", "value": 0}, {"description": "Channel 1", "value": 1}, {"description": "Channel 2", "value": 2}, {"description": "Channel 3", "value": 3}, {"description": "Channel 4", "value": 4}, {"description": "Channel 5", "value": 5}, {"description": "Channel 6", "value": 6}, {"description": "Channel 7", "value": 7}, {"description": "Channel 8", "value": 8}, {"description": "Channel 9", "value": 9}, {"description": "Channel 10", "value": 10}, {"description": "Channel 11", "value": 11}, {"description": "Channel 12", "value": 12}, {"description": "Channel 13", "value": 13}, {"description": "Channel 14", "value": 14}, {"description": "Channel 15", "value": 15}, {"description": "Channel 16", "value": 16}, {"description": "Channel 17", "value": 17}, {"description": "Channel 18", "value": 18}]}, {"category": "Standard", "default": 2000, "group": "Radio Calibration", "longDesc": "Only used if RC_RSSI_PWM_CHAN > 0\n", "max": 2000, "min": 0, "name": "RC_RSSI_PWM_MAX", "shortDesc": "Max input value for RSSI reading", "type": "Int32"}, {"category": "Standard", "default": 1000, "group": "Radio Calibration", "longDesc": "Only used if RC_RSSI_PWM_CHAN > 0\n", "max": 2000, "min": 0, "name": "RC_RSSI_PWM_MIN", "shortDesc": "Min input value for RSSI reading", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Radio Calibration", "increment": 0.01, "longDesc": "The trim value is the actuator control value the system needs\nfor straight and level flight.\n", "max": 0.5, "min": -0.5, "name": "TRIM_PITCH", "shortDesc": "Pitch trim", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Radio Calibration", "increment": 0.01, "longDesc": "The trim value is the actuator control value the system needs\nfor straight and level flight.\n", "max": 0.5, "min": -0.5, "name": "TRIM_ROLL", "shortDesc": "Roll trim", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Radio Calibration", "increment": 0.01, "longDesc": "The trim value is the actuator control value the system needs\nfor straight and level flight.\n", "max": 0.5, "min": -0.5, "name": "TRIM_YAW", "shortDesc": "Yaw trim", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.75, "group": "Radio Switches", "longDesc": "0-1 indicate where in the full channel range the threshold sits\n0 : min\n1 : max\nsign indicates polarity of comparison\npositive : true when channel>th\nnegative : true when channelth\nnegative : true when channelth\nnegative : true when channelth\nnegative : true when channelth\nnegative : true when channelth\nnegative : true when channelth\nnegative : true when channelth\nnegative : true when channelth\nnegative : true when channelth\nnegative : true when channel The rover starts to cut the corner earlier.\n\n", "max": 100.0, "min": 1.0, "name": "RA_ACC_RAD_GAIN", "shortDesc": "Tuning parameter for corner cutting", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Rover Ackermann", "increment": 0.01, "longDesc": "The controller scales the acceptance radius based on the angle between\nthe previous, current and next waypoint.\nHigher value -> smoother trajectory at the cost of how close the rover gets\nto the waypoint (Set to -1 to disable corner cutting).\n\n", "max": 100.0, "min": -1.0, "name": "RA_ACC_RAD_MAX", "shortDesc": "Maximum acceptance radius for the waypoints", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Rover Ackermann", "increment": 0.01, "max": 1.5708, "min": 0.0, "name": "RA_MAX_STR_ANG", "shortDesc": "Maximum steering angle", "type": "Float", "units": "rad"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Rover Ackermann", "increment": 0.01, "longDesc": "Set to -1 to disable.\n", "max": 1000.0, "min": -1.0, "name": "RA_STR_RATE_LIM", "shortDesc": "Steering rate limit", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Rover Ackermann", "increment": 0.001, "longDesc": "Distance from the front to the rear axle.\n", "max": 100.0, "min": 0.0, "name": "RA_WHEEL_BASE", "shortDesc": "Wheel base", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Rover Attitude Control", "increment": 0.01, "max": 100.0, "min": 0.0, "name": "RO_YAW_P", "shortDesc": "Proportional gain for closed loop yaw controller", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.174533, "group": "Rover Differential", "increment": 0.01, "longDesc": "This threshold is used for the state machine to switch from driving to turning based on the\nerror between the desired and actual yaw. It is also used as the threshold whether the rover should come\nto a smooth stop at the next waypoint. This slow down effect is active if the angle between the\nline segments from prevWP-currWP and currWP-nextWP is smaller then 180 - RD_TRANS_DRV_TRN.\n\n", "max": 3.14159, "min": 0.001, "name": "RD_TRANS_DRV_TRN", "shortDesc": "Yaw error threshold to switch from driving to spot turning", "type": "Float", "units": "rad"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0872665, "group": "Rover Differential", "increment": 0.01, "longDesc": "This threshold is used for the state machine to switch from turning to driving based on the\nerror between the desired and actual yaw.\n\n", "max": 3.14159, "min": 0.001, "name": "RD_TRANS_TRN_DRV", "shortDesc": "Yaw error threshold to switch from spot turning to driving", "type": "Float", "units": "rad"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Rover Differential", "increment": 0.001, "longDesc": "Distance from the center of the right wheel to the center of the left wheel.\n", "max": 100.0, "min": 0.0, "name": "RD_WHEEL_TRACK", "shortDesc": "Wheel track", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "Rover Differential", "increment": 0.01, "longDesc": "Assign value <1.0 to decrease stick response for yaw control.\n", "max": 1.0, "min": 0.1, "name": "RD_YAW_STK_GAIN", "shortDesc": "Yaw stick gain for Manual mode", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "Rover Manual Control", "increment": 0.01, "longDesc": "Scales the stick inputs that are mapped to motor commands in Manual Parking mode, so that maneuvering in tight spaces stays slow. Applies symmetrically to forward and reverse throttle.\n\n", "max": 1.0, "min": 0.0, "name": "RO_PARK_THR_MAX", "shortDesc": "Maximum throttle in Manual Parking mode", "type": "Float", "units": "norm"}, {"category": "Standard", "default": 3, "group": "Rover Manual Control", "longDesc": "Follows the RC transmitter modes 1-4 with the pitch stick driving forwards/backwards, the roll stick sideways and the yaw stick turning, assuming the RC channels are mapped as for a mode 2 transmitter. Ackermann and differential rovers ignore the sideways assignment. In the tank-style Manual Parking mode of differential and mecanum rovers only the sideways assignment applies.\n", "name": "RO_STICK_MAP", "shortDesc": "Stick mapping for the manual modes", "type": "Int32", "values": [{"description": "Mode 1: forward and turn on left stick, sideways on right stick", "value": 1}, {"description": "Mode 2: turn on left stick, forward and sideways on right stick", "value": 2}, {"description": "Mode 3: forward and sideways on left stick, turn on right stick", "value": 3}, {"description": "Mode 4: sideways on left stick, forward and turn on right stick", "value": 4}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.17, "group": "Rover Mecanum", "increment": 0.01, "longDesc": "Threshold for the angle between the active cruise direction and the cruise direction given\nby the stick inputs.\nThis can be understood as a deadzone for the combined stick inputs for forward/backwards\nand lateral speed which defines a course direction.\n\n", "max": 3.14, "min": 0.0, "name": "RM_COURSE_CTL_TH", "shortDesc": "Threshold to update course control in manual position mode", "type": "Float", "units": "rad"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Rover Mecanum", "increment": 0.001, "longDesc": "Distance from the center of the right wheel to the center of the left wheel.\n", "max": 100.0, "min": 0.0, "name": "RM_WHEEL_TRACK", "shortDesc": "Wheel track", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "Rover Mecanum", "increment": 0.01, "longDesc": "Assign value <1.0 to decrease stick response for yaw control.\n", "max": 1.0, "min": 0.1, "name": "RM_YAW_STK_GAIN", "shortDesc": "Yaw stick gain for Manual mode", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Rover Rate Control", "increment": 0.01, "longDesc": "Used to cap how quickly the magnitude of yaw rate setpoints can increase.\nSet to -1 to disable.\n", "max": 10000.0, "min": -1.0, "name": "RO_YAW_ACCEL_LIM", "shortDesc": "Yaw acceleration limit", "type": "Float", "units": "deg/s^2"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Rover Rate Control", "increment": 0.01, "longDesc": "Used to cap how quickly the magnitude of yaw rate setpoints can decrease.\nSet to -1 to disable.\n", "max": 10000.0, "min": -1.0, "name": "RO_YAW_DECEL_LIM", "shortDesc": "Yaw deceleration limit", "type": "Float", "units": "deg/s^2"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Rover Rate Control", "longDesc": "Exponential factor for tuning the input curve shape.\n\n0 Purely linear input curve\n1 Purely cubic input curve\n", "max": 1.0, "min": 0.0, "name": "RO_YAW_EXPO", "shortDesc": "Yaw rate expo factor", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Rover Rate Control", "increment": 0.01, "longDesc": "Multiplicative correction factor for the feedforward mapping of the yaw rate controller.\nIncrease this value (x > 1) if the measured yaw rate is lower than the setpoint, decrease (0 < x < 1) otherwise.\nNote: Tuning this is particularly useful for skid-steered rovers, or rovers with misaligned wheels/steering axes\nthat cause a lot of friction when turning.\n", "max": 10000.0, "min": 0.01, "name": "RO_YAW_RATE_CORR", "shortDesc": "Yaw rate correction factor", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Rover Rate Control", "increment": 0.01, "max": 100.0, "min": 0.0, "name": "RO_YAW_RATE_I", "shortDesc": "Integral gain for closed loop yaw rate controller", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Rover Rate Control", "increment": 0.01, "longDesc": "Used to cap yaw rate setpoints and map controller inputs to yaw rate setpoints\nin Acro, Stabilized and Position mode.\n", "max": 10000.0, "min": 0.0, "name": "RO_YAW_RATE_LIM", "shortDesc": "Yaw rate limit", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Rover Rate Control", "increment": 0.01, "max": 100.0, "min": 0.0, "name": "RO_YAW_RATE_P", "shortDesc": "Proportional gain for closed loop yaw rate controller", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 3.0, "group": "Rover Rate Control", "increment": 0.01, "longDesc": "The minimum threshold for the yaw rate measurement not to be interpreted as zero.\n", "max": 100.0, "min": 0.0, "name": "RO_YAW_RATE_TH", "shortDesc": "Yaw rate measurement threshold", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "Rover Rate Control", "increment": 0.01, "longDesc": "Percentage of stick input range that will be interpreted as zero around the stick centered value.\n", "max": 1.0, "min": 0.0, "name": "RO_YAW_STICK_DZ", "shortDesc": "Yaw stick deadzone", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Rover Rate Control", "longDesc": "\"Superexponential\" factor for refining the input curve shape tuned using RO_YAW_EXPO.\n\n0 Pure Expo function\n0.7 reasonable shape enhancement for intuitive stick feel\n0.95 very strong bent input curve only near maxima have effect\n", "max": 0.95, "min": 0.0, "name": "RO_YAW_SUPEXPO", "shortDesc": "Yaw rate super expo factor", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Rover Velocity Control", "increment": 0.01, "longDesc": "Set to -1 to disable.\nFor mecanum rovers this limit is used for longitudinal and lateral acceleration.\n", "max": 100.0, "min": -1.0, "name": "RO_ACCEL_LIM", "shortDesc": "Acceleration limit", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Rover Velocity Control", "increment": 0.01, "longDesc": "Set to -1 to disable.\nNote that if it is disabled the rover will not slow down when approaching waypoints in auto modes.\nFor mecanum rovers this limit is used for longitudinal and lateral deceleration.\n", "max": 100.0, "min": -1.0, "name": "RO_DECEL_LIM", "shortDesc": "Deceleration limit", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Rover Velocity Control", "increment": 0.01, "longDesc": "Set to -1 to disable.\nNote that if it is disabled the rover will not slow down when approaching waypoints in auto modes.\nFor mecanum rovers this limit is used for longitudinal and lateral jerk.\n", "max": 100.0, "min": -1.0, "name": "RO_JERK_LIM", "shortDesc": "Jerk limit", "type": "Float", "units": "m/s^3"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Rover Velocity Control", "increment": 0.01, "longDesc": "Used to linearly map speeds [m/s] to throttle values [-1. 1].\n", "max": 100.0, "min": 0.0, "name": "RO_MAX_THR_SPEED", "shortDesc": "Speed the rover drives at maximum throttle", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Rover Velocity Control", "increment": 0.001, "max": 100.0, "min": 0.0, "name": "RO_SPEED_I", "shortDesc": "Integral gain for ground speed controller", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Rover Velocity Control", "increment": 0.01, "longDesc": "Used to cap speed setpoints and map controller inputs to speed setpoints in Position mode.\n", "max": 100.0, "min": -1.0, "name": "RO_SPEED_LIM", "shortDesc": "Speed limit", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Rover Velocity Control", "increment": 0.01, "max": 100.0, "min": 0.0, "name": "RO_SPEED_P", "shortDesc": "Proportional gain for ground speed controller", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Rover Velocity Control", "increment": 0.01, "longDesc": "```\nReduced_speed = RO_MAX_THR_SPEED * (1 - normalized_course_error * RO_SPEED_RED)\n```\nThe normalized course error is the angle between the current course and the bearing setpoint\ninterpolated from [0, 180] -> [0, 1].\nHigher value -> More speed reduction.\nNote: This is also used to calculate the speed at which the vehicle arrives at a waypoint in auto modes.\nSet to -1 to disable bearing error based speed reduction.\n", "max": 100.0, "min": -1.0, "name": "RO_SPEED_RED", "shortDesc": "Tuning parameter for the speed reduction based on the course error", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "Rover Velocity Control", "increment": 0.01, "longDesc": "Set to -1 to disable.\nThe minimum threshold for the speed measurement not to be interpreted as zero.\n", "max": 100.0, "min": 0.0, "name": "RO_SPEED_TH", "shortDesc": "Speed measurement threshold", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.1, "group": "Rover Velocity Control", "increment": 0.001, "longDesc": "Used to convert wheel encoder counts to the distance travelled by each wheel\nfor the MAVLink WHEEL_DISTANCE message:\ndistance = 2 * pi * RO_WHEEL_RAD * encoder_counts / counts_per_rev\n", "max": 10.0, "min": 0.01, "name": "RO_WHEEL_RAD", "shortDesc": "Wheel radius in meters", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Runway Takeoff", "increment": 0.01, "max": 1.0, "min": 0.0, "name": "RWTO_MAX_THR", "shortDesc": "Throttle during runway takeoff", "type": "Float", "units": "norm"}, {"category": "Standard", "default": 1, "group": "Runway Takeoff", "longDesc": "Enable use of yaw stick for nudging the wheel during runway ground roll\n\nThis is useful when map, GNSS, or yaw errors on ground are misaligned with what the operator intends for takeoff course.\nParticularly useful for skinny runways or if the wheel servo is a bit off trim.\n", "name": "RWTO_NUDGE", "shortDesc": "Enable yaw stick nudging during runway ground roll", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "Runway Takeoff", "increment": 0.5, "longDesc": "Pitch setpoint during taxi / before takeoff rotation airspeed is reached\n\nA taildragger with steerable wheel might need to pitch up\na little to keep its wheel on the ground before airspeed\nto takeoff is reached.\n", "max": 20.0, "min": -10.0, "name": "RWTO_PSP", "shortDesc": "Absolute pitch setpoint during taxi / before rotation", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 2, "default": 2.0, "group": "Runway Takeoff", "increment": 0.1, "max": 15.0, "min": 1.0, "name": "RWTO_RAMP_TIME", "shortDesc": "Throttle ramp up time for runway takeoff", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": -1.0, "group": "Runway Takeoff", "increment": 0.1, "longDesc": "The calibrated airspeed threshold during the takeoff ground roll when the plane should start rotating (pitching up).\nMust be less than the takeoff airspeed, will otherwise be capped at the takeoff airspeed (see FW_TKO_AIRSPD).\n\nIf set <= 0.0, defaults to 0.9 * takeoff airspeed (see FW_TKO_AIRSPD)\n", "min": -1.0, "name": "RWTO_ROT_AIRSPD", "shortDesc": "Takeoff rotation airspeed", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.0, "group": "Runway Takeoff", "increment": 0.1, "longDesc": "This is the time desired to linearly ramp in takeoff pitch constraints during the takeoff rotation\n", "min": 0.1, "name": "RWTO_ROT_TIME", "shortDesc": "Takeoff rotation time", "type": "Float", "units": "s"}, {"category": "Standard", "default": 0, "group": "Runway Takeoff", "name": "RWTO_TKOFF", "shortDesc": "Runway takeoff with landing gear", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"bitmask": [{"description": "SD card logging", "index": 0}, {"description": "Mavlink logging", "index": 1}], "category": "Standard", "default": 3, "group": "SD Logging", "longDesc": "If no logging is set the logger will not be started. Set bits true to enable: 0: SD card logging 1: Mavlink logging\n", "max": 3, "min": 0, "name": "SDLOG_BACKEND", "rebootRequired": true, "shortDesc": "Logging Backend (integer bitmask)", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "SD Logging", "longDesc": "When enabled, logging will not start from boot if battery power is not detected (e.g. powered via USB on a test bench). This prevents extraneous flight logs from being created during bench testing. Note that this only applies to log-from-boot modes. This has no effect on arm-based modes.\n", "name": "SDLOG_BOOT_BAT", "shortDesc": "Battery-only Logging", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "SD Logging", "longDesc": "At log start, oldest log directories are deleted to stay within this count. Independent of SDLOG_ROTATE and SDLOG_MAX_SIZE, e.g. to cap logs by count in SITL. Set to 0 to disable.\n", "max": 1000, "min": 0, "name": "SDLOG_DIRS_MAX", "shortDesc": "Maximum number of log directories to keep", "type": "Int32"}, {"category": "Standard", "default": 1024, "group": "SD Logging", "longDesc": "Maximum size of a single log file in mebibytes (1 MiB = 1024 * 1024 bytes). When reached, the log file is closed and a new one is started. This value is also added to the cleanup threshold (see SDLOG_ROTATE) to reserve headroom for the next log file. A value of 0 disables both file rotation and the cleanup reservation. Must stay below the FAT32 file size limit of 4 GiB.\n", "max": 4095, "min": 0, "name": "SDLOG_MAX_SIZE", "shortDesc": "Maximum log file size", "type": "Int32", "units": "MiB"}, {"category": "Standard", "default": 0, "group": "SD Logging", "longDesc": "Writes a small extra log with only the messages needed for flight statistics and geotagging. The full log is still written and contains all of this data.\n", "name": "SDLOG_MISSION", "rebootRequired": true, "shortDesc": "Mission Log", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "All mission messages", "value": 1}, {"description": "Geotagging messages", "value": 2}]}, {"category": "Standard", "default": 0, "group": "SD Logging", "longDesc": "Only applies to SD card logging; MAVLink logging starts and stops independently.\n", "name": "SDLOG_MODE", "rebootRequired": true, "shortDesc": "Logging Mode", "type": "Int32", "values": [{"description": "when armed until disarm (default)", "value": 0}, {"description": "from boot until disarm", "value": 1}, {"description": "from boot until shutdown", "value": 2}, {"description": "while manual input AUX1 >30%", "value": 3}, {"description": "from 1st armed until shutdown", "value": 4}]}, {"bitmask": [{"description": "Default set (general log analysis)", "index": 0}, {"description": "Estimator replay (EKF2, full rate)", "index": 1}, {"description": "Thermal calibration (high-rate raw IMU and baro)", "index": 2}, {"description": "System identification (high-rate actuator and IMU)", "index": 3}, {"description": "High rate (RC, attitude, rates and actuators)", "index": 4}, {"description": "Debug (debug_*.msg topics)", "index": 5}, {"description": "Sensor comparison (low-rate raw IMU, baro and mag)", "index": 6}, {"description": "Computer Vision and Avoidance", "index": 7}, {"description": "Raw FIFO high-rate IMU (Gyro)", "index": 8}, {"description": "Raw FIFO high-rate IMU (Accel)", "index": 9}, {"description": "Mavlink tunnel message logging (payload debugging)", "index": 10}, {"description": "High rate sensors", "index": 11}], "category": "Standard", "default": 1, "group": "SD Logging", "longDesc": "Each additional set increases bandwidth and log size.\n", "max": 4095, "min": 0, "name": "SDLOG_PROFILE", "rebootRequired": true, "shortDesc": "Logging topic profile", "type": "Int32"}, {"category": "Standard", "default": 90, "group": "SD Logging", "longDesc": "The limit includes the log being written. Oldest logs are deleted at log start (not boot), leaving room for a file of up to SDLOG_MAX_SIZE, so logs can be downloaded before deletion. 100 lets logs fill the disk. Set to 0 to disable.\n", "max": 100, "min": 0, "name": "SDLOG_ROTATE", "shortDesc": "Maximum disk usage percentage", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "SD Logging", "longDesc": "the difference in hours and minutes from Coordinated Universal Time (UTC) for a your place and date. for example, In case of South Korea(UTC+09:00), UTC offset is 540 min (9*60) refer to https://en.wikipedia.org/wiki/List_of_UTC_time_offsets\n", "max": 1000, "min": -1000, "name": "SDLOG_UTC_OFFSET", "shortDesc": "UTC offset (unit: min)", "type": "Int32", "units": "min"}, {"category": "Standard", "default": 1, "group": "SD Logging", "longDesc": "If set to 1, add an ID to the log, which uniquely identifies the vehicle\n", "name": "SDLOG_UUID", "shortDesc": "Log UUID", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": -1.0, "group": "SITL", "increment": 1.0, "longDesc": "Time in seconds for simulated battery 1 to drain from 100% to 0% while armed,\noverriding SIM_BAT_DRAIN for this battery only. A non-positive value uses SIM_BAT_DRAIN.\nOnly has an effect if battery 1 is enabled through BAT1_SOURCE.\n", "min": -1.0, "name": "SIM_BAT1_DRAIN", "shortDesc": "Simulated battery 1 full-discharge time", "type": "Float", "units": "s"}, {"category": "Standard", "default": -1.0, "group": "SITL", "increment": 0.1, "longDesc": "Lowest state of charge simulated battery 1 drains down to, overriding\nSIM_BAT_MIN_PCT for this battery only. Set to -1 to use SIM_BAT_MIN_PCT.\nOnly has an effect if battery 1 is enabled through BAT1_SOURCE.\n", "max": 100.0, "min": -1.0, "name": "SIM_BAT1_MIN_PCT", "shortDesc": "Simulated battery 1 minimal percentage", "type": "Float", "units": "%"}, {"category": "Standard", "default": -1.0, "group": "SITL", "increment": 1.0, "longDesc": "Time in seconds for simulated battery 2 to drain from 100% to 0% while armed,\noverriding SIM_BAT_DRAIN for this battery only. A non-positive value uses SIM_BAT_DRAIN.\nOnly has an effect if battery 2 is enabled through BAT2_SOURCE.\n", "min": -1.0, "name": "SIM_BAT2_DRAIN", "shortDesc": "Simulated battery 2 full-discharge time", "type": "Float", "units": "s"}, {"category": "Standard", "default": -1.0, "group": "SITL", "increment": 0.1, "longDesc": "Lowest state of charge simulated battery 2 drains down to, overriding\nSIM_BAT_MIN_PCT for this battery only. Set to -1 to use SIM_BAT_MIN_PCT.\nOnly has an effect if battery 2 is enabled through BAT2_SOURCE.\n", "max": 100.0, "min": -1.0, "name": "SIM_BAT2_MIN_PCT", "shortDesc": "Simulated battery 2 minimal percentage", "type": "Float", "units": "%"}, {"category": "Standard", "default": -1.0, "group": "SITL", "increment": 1.0, "longDesc": "Time in seconds for simulated battery 3 to drain from 100% to 0% while armed,\noverriding SIM_BAT_DRAIN for this battery only. A non-positive value uses SIM_BAT_DRAIN.\nOnly has an effect if battery 3 is enabled through BAT3_SOURCE.\n", "min": -1.0, "name": "SIM_BAT3_DRAIN", "shortDesc": "Simulated battery 3 full-discharge time", "type": "Float", "units": "s"}, {"category": "Standard", "default": -1.0, "group": "SITL", "increment": 0.1, "longDesc": "Lowest state of charge simulated battery 3 drains down to, overriding\nSIM_BAT_MIN_PCT for this battery only. Set to -1 to use SIM_BAT_MIN_PCT.\nOnly has an effect if battery 3 is enabled through BAT3_SOURCE.\n", "max": 100.0, "min": -1.0, "name": "SIM_BAT3_MIN_PCT", "shortDesc": "Simulated battery 3 minimal percentage", "type": "Float", "units": "%"}, {"category": "Standard", "default": 60.0, "group": "SITL", "increment": 1.0, "longDesc": "Time in seconds for the simulated battery to drain from 100% to 0% while armed. Set to 0 to disable the battery simulator entirely (useful when battery state is provided externally, e.g. via MAVLink).\n", "min": 0.0, "name": "SIM_BAT_DRAIN", "shortDesc": "Simulated battery full-discharge time", "type": "Float", "units": "s"}, {"category": "Standard", "default": 50.0, "group": "SITL", "increment": 0.1, "longDesc": "Can be used to alter the battery level during SITL- or HITL-simulation on the fly.\nParticularly useful for testing different low-battery behaviour.\n", "max": 100.0, "min": 0.0, "name": "SIM_BAT_MIN_PCT", "shortDesc": "Simulator Battery minimal percentage", "type": "Float", "units": "%"}, {"category": "System", "decimalPlaces": 3, "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the accelerometer this calibration applies to.\n", "name": "CAL_ACC0_ID", "shortDesc": "Accelerometer 0 calibration device ID", "type": "Int32"}, {"category": "System", "decimalPlaces": 3, "default": -1, "group": "Sensor Calibration", "longDesc": "Uninitialized sensors default to Medium when internal and Low when\nexternal, so an on-board IMU is preferred over one behind a bus.\n\n", "name": "CAL_ACC0_PRIO", "shortDesc": "Accelerometer 0 priority", "type": "Int32", "values": [{"description": "Uninitialized", "value": -1}, {"description": "Disabled", "value": 0}, {"description": "Min", "value": 1}, {"description": "Low", "value": 25}, {"description": "Medium (Default)", "value": 50}, {"description": "High", "value": 75}, {"description": "Max", "value": 100}]}, {"category": "System", "default": -1, "group": "Sensor Calibration", "longDesc": "An internal sensor will force a value of -1, so a GCS should only attempt to configure the rotation if the value is greater than or equal to zero.\n\n", "max": 40, "min": -1, "name": "CAL_ACC0_ROT", "shortDesc": "Accelerometer 0 rotation relative to airframe", "type": "Int32", "values": [{"description": "Internal", "value": -1}, {"description": "No rotation", "value": 0}, {"description": "Yaw 45\u00b0", "value": 1}, {"description": "Yaw 90\u00b0", "value": 2}, {"description": "Yaw 135\u00b0", "value": 3}, {"description": "Yaw 180\u00b0", "value": 4}, {"description": "Yaw 225\u00b0", "value": 5}, {"description": "Yaw 270\u00b0", "value": 6}, {"description": "Yaw 315\u00b0", "value": 7}, {"description": "Roll 180\u00b0", "value": 8}, {"description": "Roll 180\u00b0, Yaw 45\u00b0", "value": 9}, {"description": "Roll 180\u00b0, Yaw 90\u00b0", "value": 10}, {"description": "Roll 180\u00b0, Yaw 135\u00b0", "value": 11}, {"description": "Pitch 180\u00b0", "value": 12}, {"description": "Roll 180\u00b0, Yaw 225\u00b0", "value": 13}, {"description": "Roll 180\u00b0, Yaw 270\u00b0", "value": 14}, {"description": "Roll 180\u00b0, Yaw 315\u00b0", "value": 15}, {"description": "Roll 90\u00b0", "value": 16}, {"description": "Roll 90\u00b0, Yaw 45\u00b0", "value": 17}, {"description": "Roll 90\u00b0, Yaw 90\u00b0", "value": 18}, {"description": "Roll 90\u00b0, Yaw 135\u00b0", "value": 19}, {"description": "Roll 270\u00b0", "value": 20}, {"description": "Roll 270\u00b0, Yaw 45\u00b0", "value": 21}, {"description": "Roll 270\u00b0, Yaw 90\u00b0", "value": 22}, {"description": "Roll 270\u00b0, Yaw 135\u00b0", "value": 23}, {"description": "Pitch 90\u00b0", "value": 24}, {"description": "Pitch 270\u00b0", "value": 25}, {"description": "Pitch 180\u00b0, Yaw 90\u00b0", "value": 26}, {"description": "Pitch 180\u00b0, Yaw 270\u00b0", "value": 27}, {"description": "Roll 90\u00b0, Pitch 90\u00b0", "value": 28}, {"description": "Roll 180\u00b0, Pitch 90\u00b0", "value": 29}, {"description": "Roll 270\u00b0, Pitch 90\u00b0", "value": 30}, {"description": "Roll 90\u00b0, Pitch 180\u00b0", "value": 31}, {"description": "Roll 270\u00b0, Pitch 180\u00b0", "value": 32}, {"description": "Roll 90\u00b0, Pitch 270\u00b0", "value": 33}, {"description": "Roll 180\u00b0, Pitch 270\u00b0", "value": 34}, {"description": "Roll 270\u00b0, Pitch 270\u00b0", "value": 35}, {"description": "Roll 90\u00b0, Pitch 180\u00b0, Yaw 90\u00b0", "value": 36}, {"description": "Roll 90\u00b0, Yaw 270\u00b0", "value": 37}, {"description": "Roll 90\u00b0, Pitch 68\u00b0, Yaw 293\u00b0", "value": 38}, {"description": "Pitch 315\u00b0", "value": 39}, {"description": "Roll 90\u00b0, Pitch 315\u00b0", "value": 40}]}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_ACC0_XOFF", "shortDesc": "Accelerometer 0 X-axis offset", "type": "Float", "units": "m/s^2", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_ACC0_XSCALE", "shortDesc": "Accelerometer 0 X-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_ACC0_YOFF", "shortDesc": "Accelerometer 0 Y-axis offset", "type": "Float", "units": "m/s^2", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_ACC0_YSCALE", "shortDesc": "Accelerometer 0 Y-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_ACC0_ZOFF", "shortDesc": "Accelerometer 0 Z-axis offset", "type": "Float", "units": "m/s^2", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_ACC0_ZSCALE", "shortDesc": "Accelerometer 0 Z-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the accelerometer this calibration applies to.\n", "name": "CAL_ACC1_ID", "shortDesc": "Accelerometer 1 calibration device ID", "type": "Int32"}, {"category": "System", "decimalPlaces": 3, "default": -1, "group": "Sensor Calibration", "longDesc": "Uninitialized sensors default to Medium when internal and Low when\nexternal, so an on-board IMU is preferred over one behind a bus.\n\n", "name": "CAL_ACC1_PRIO", "shortDesc": "Accelerometer 1 priority", "type": "Int32", "values": [{"description": "Uninitialized", "value": -1}, {"description": "Disabled", "value": 0}, {"description": "Min", "value": 1}, {"description": "Low", "value": 25}, {"description": "Medium (Default)", "value": 50}, {"description": "High", "value": 75}, {"description": "Max", "value": 100}]}, {"category": "System", "default": -1, "group": "Sensor Calibration", "longDesc": "An internal sensor will force a value of -1, so a GCS should only attempt to configure the rotation if the value is greater than or equal to zero.\n\n", "max": 40, "min": -1, "name": "CAL_ACC1_ROT", "shortDesc": "Accelerometer 1 rotation relative to airframe", "type": "Int32", "values": [{"description": "Internal", "value": -1}, {"description": "No rotation", "value": 0}, {"description": "Yaw 45\u00b0", "value": 1}, {"description": "Yaw 90\u00b0", "value": 2}, {"description": "Yaw 135\u00b0", "value": 3}, {"description": "Yaw 180\u00b0", "value": 4}, {"description": "Yaw 225\u00b0", "value": 5}, {"description": "Yaw 270\u00b0", "value": 6}, {"description": "Yaw 315\u00b0", "value": 7}, {"description": "Roll 180\u00b0", "value": 8}, {"description": "Roll 180\u00b0, Yaw 45\u00b0", "value": 9}, {"description": "Roll 180\u00b0, Yaw 90\u00b0", "value": 10}, {"description": "Roll 180\u00b0, Yaw 135\u00b0", "value": 11}, {"description": "Pitch 180\u00b0", "value": 12}, {"description": "Roll 180\u00b0, Yaw 225\u00b0", "value": 13}, {"description": "Roll 180\u00b0, Yaw 270\u00b0", "value": 14}, {"description": "Roll 180\u00b0, Yaw 315\u00b0", "value": 15}, {"description": "Roll 90\u00b0", "value": 16}, {"description": "Roll 90\u00b0, Yaw 45\u00b0", "value": 17}, {"description": "Roll 90\u00b0, Yaw 90\u00b0", "value": 18}, {"description": "Roll 90\u00b0, Yaw 135\u00b0", "value": 19}, {"description": "Roll 270\u00b0", "value": 20}, {"description": "Roll 270\u00b0, Yaw 45\u00b0", "value": 21}, {"description": "Roll 270\u00b0, Yaw 90\u00b0", "value": 22}, {"description": "Roll 270\u00b0, Yaw 135\u00b0", "value": 23}, {"description": "Pitch 90\u00b0", "value": 24}, {"description": "Pitch 270\u00b0", "value": 25}, {"description": "Pitch 180\u00b0, Yaw 90\u00b0", "value": 26}, {"description": "Pitch 180\u00b0, Yaw 270\u00b0", "value": 27}, {"description": "Roll 90\u00b0, Pitch 90\u00b0", "value": 28}, {"description": "Roll 180\u00b0, Pitch 90\u00b0", "value": 29}, {"description": "Roll 270\u00b0, Pitch 90\u00b0", "value": 30}, {"description": "Roll 90\u00b0, Pitch 180\u00b0", "value": 31}, {"description": "Roll 270\u00b0, Pitch 180\u00b0", "value": 32}, {"description": "Roll 90\u00b0, Pitch 270\u00b0", "value": 33}, {"description": "Roll 180\u00b0, Pitch 270\u00b0", "value": 34}, {"description": "Roll 270\u00b0, Pitch 270\u00b0", "value": 35}, {"description": "Roll 90\u00b0, Pitch 180\u00b0, Yaw 90\u00b0", "value": 36}, {"description": "Roll 90\u00b0, Yaw 270\u00b0", "value": 37}, {"description": "Roll 90\u00b0, Pitch 68\u00b0, Yaw 293\u00b0", "value": 38}, {"description": "Pitch 315\u00b0", "value": 39}, {"description": "Roll 90\u00b0, Pitch 315\u00b0", "value": 40}]}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_ACC1_XOFF", "shortDesc": "Accelerometer 1 X-axis offset", "type": "Float", "units": "m/s^2", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_ACC1_XSCALE", "shortDesc": "Accelerometer 1 X-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_ACC1_YOFF", "shortDesc": "Accelerometer 1 Y-axis offset", "type": "Float", "units": "m/s^2", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_ACC1_YSCALE", "shortDesc": "Accelerometer 1 Y-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_ACC1_ZOFF", "shortDesc": "Accelerometer 1 Z-axis offset", "type": "Float", "units": "m/s^2", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_ACC1_ZSCALE", "shortDesc": "Accelerometer 1 Z-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the accelerometer this calibration applies to.\n", "name": "CAL_ACC2_ID", "shortDesc": "Accelerometer 2 calibration device ID", "type": "Int32"}, {"category": "System", "decimalPlaces": 3, "default": -1, "group": "Sensor Calibration", "longDesc": "Uninitialized sensors default to Medium when internal and Low when\nexternal, so an on-board IMU is preferred over one behind a bus.\n\n", "name": "CAL_ACC2_PRIO", "shortDesc": "Accelerometer 2 priority", "type": "Int32", "values": [{"description": "Uninitialized", "value": -1}, {"description": "Disabled", "value": 0}, {"description": "Min", "value": 1}, {"description": "Low", "value": 25}, {"description": "Medium (Default)", "value": 50}, {"description": "High", "value": 75}, {"description": "Max", "value": 100}]}, {"category": "System", "default": -1, "group": "Sensor Calibration", "longDesc": "An internal sensor will force a value of -1, so a GCS should only attempt to configure the rotation if the value is greater than or equal to zero.\n\n", "max": 40, "min": -1, "name": "CAL_ACC2_ROT", "shortDesc": "Accelerometer 2 rotation relative to airframe", "type": "Int32", "values": [{"description": "Internal", "value": -1}, {"description": "No rotation", "value": 0}, {"description": "Yaw 45\u00b0", "value": 1}, {"description": "Yaw 90\u00b0", "value": 2}, {"description": "Yaw 135\u00b0", "value": 3}, {"description": "Yaw 180\u00b0", "value": 4}, {"description": "Yaw 225\u00b0", "value": 5}, {"description": "Yaw 270\u00b0", "value": 6}, {"description": "Yaw 315\u00b0", "value": 7}, {"description": "Roll 180\u00b0", "value": 8}, {"description": "Roll 180\u00b0, Yaw 45\u00b0", "value": 9}, {"description": "Roll 180\u00b0, Yaw 90\u00b0", "value": 10}, {"description": "Roll 180\u00b0, Yaw 135\u00b0", "value": 11}, {"description": "Pitch 180\u00b0", "value": 12}, {"description": "Roll 180\u00b0, Yaw 225\u00b0", "value": 13}, {"description": "Roll 180\u00b0, Yaw 270\u00b0", "value": 14}, {"description": "Roll 180\u00b0, Yaw 315\u00b0", "value": 15}, {"description": "Roll 90\u00b0", "value": 16}, {"description": "Roll 90\u00b0, Yaw 45\u00b0", "value": 17}, {"description": "Roll 90\u00b0, Yaw 90\u00b0", "value": 18}, {"description": "Roll 90\u00b0, Yaw 135\u00b0", "value": 19}, {"description": "Roll 270\u00b0", "value": 20}, {"description": "Roll 270\u00b0, Yaw 45\u00b0", "value": 21}, {"description": "Roll 270\u00b0, Yaw 90\u00b0", "value": 22}, {"description": "Roll 270\u00b0, Yaw 135\u00b0", "value": 23}, {"description": "Pitch 90\u00b0", "value": 24}, {"description": "Pitch 270\u00b0", "value": 25}, {"description": "Pitch 180\u00b0, Yaw 90\u00b0", "value": 26}, {"description": "Pitch 180\u00b0, Yaw 270\u00b0", "value": 27}, {"description": "Roll 90\u00b0, Pitch 90\u00b0", "value": 28}, {"description": "Roll 180\u00b0, Pitch 90\u00b0", "value": 29}, {"description": "Roll 270\u00b0, Pitch 90\u00b0", "value": 30}, {"description": "Roll 90\u00b0, Pitch 180\u00b0", "value": 31}, {"description": "Roll 270\u00b0, Pitch 180\u00b0", "value": 32}, {"description": "Roll 90\u00b0, Pitch 270\u00b0", "value": 33}, {"description": "Roll 180\u00b0, Pitch 270\u00b0", "value": 34}, {"description": "Roll 270\u00b0, Pitch 270\u00b0", "value": 35}, {"description": "Roll 90\u00b0, Pitch 180\u00b0, Yaw 90\u00b0", "value": 36}, {"description": "Roll 90\u00b0, Yaw 270\u00b0", "value": 37}, {"description": "Roll 90\u00b0, Pitch 68\u00b0, Yaw 293\u00b0", "value": 38}, {"description": "Pitch 315\u00b0", "value": 39}, {"description": "Roll 90\u00b0, Pitch 315\u00b0", "value": 40}]}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_ACC2_XOFF", "shortDesc": "Accelerometer 2 X-axis offset", "type": "Float", "units": "m/s^2", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_ACC2_XSCALE", "shortDesc": "Accelerometer 2 X-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_ACC2_YOFF", "shortDesc": "Accelerometer 2 Y-axis offset", "type": "Float", "units": "m/s^2", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_ACC2_YSCALE", "shortDesc": "Accelerometer 2 Y-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_ACC2_ZOFF", "shortDesc": "Accelerometer 2 Z-axis offset", "type": "Float", "units": "m/s^2", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_ACC2_ZSCALE", "shortDesc": "Accelerometer 2 Z-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the accelerometer this calibration applies to.\n", "name": "CAL_ACC3_ID", "shortDesc": "Accelerometer 3 calibration device ID", "type": "Int32"}, {"category": "System", "decimalPlaces": 3, "default": -1, "group": "Sensor Calibration", "longDesc": "Uninitialized sensors default to Medium when internal and Low when\nexternal, so an on-board IMU is preferred over one behind a bus.\n\n", "name": "CAL_ACC3_PRIO", "shortDesc": "Accelerometer 3 priority", "type": "Int32", "values": [{"description": "Uninitialized", "value": -1}, {"description": "Disabled", "value": 0}, {"description": "Min", "value": 1}, {"description": "Low", "value": 25}, {"description": "Medium (Default)", "value": 50}, {"description": "High", "value": 75}, {"description": "Max", "value": 100}]}, {"category": "System", "default": -1, "group": "Sensor Calibration", "longDesc": "An internal sensor will force a value of -1, so a GCS should only attempt to configure the rotation if the value is greater than or equal to zero.\n\n", "max": 40, "min": -1, "name": "CAL_ACC3_ROT", "shortDesc": "Accelerometer 3 rotation relative to airframe", "type": "Int32", "values": [{"description": "Internal", "value": -1}, {"description": "No rotation", "value": 0}, {"description": "Yaw 45\u00b0", "value": 1}, {"description": "Yaw 90\u00b0", "value": 2}, {"description": "Yaw 135\u00b0", "value": 3}, {"description": "Yaw 180\u00b0", "value": 4}, {"description": "Yaw 225\u00b0", "value": 5}, {"description": "Yaw 270\u00b0", "value": 6}, {"description": "Yaw 315\u00b0", "value": 7}, {"description": "Roll 180\u00b0", "value": 8}, {"description": "Roll 180\u00b0, Yaw 45\u00b0", "value": 9}, {"description": "Roll 180\u00b0, Yaw 90\u00b0", "value": 10}, {"description": "Roll 180\u00b0, Yaw 135\u00b0", "value": 11}, {"description": "Pitch 180\u00b0", "value": 12}, {"description": "Roll 180\u00b0, Yaw 225\u00b0", "value": 13}, {"description": "Roll 180\u00b0, Yaw 270\u00b0", "value": 14}, {"description": "Roll 180\u00b0, Yaw 315\u00b0", "value": 15}, {"description": "Roll 90\u00b0", "value": 16}, {"description": "Roll 90\u00b0, Yaw 45\u00b0", "value": 17}, {"description": "Roll 90\u00b0, Yaw 90\u00b0", "value": 18}, {"description": "Roll 90\u00b0, Yaw 135\u00b0", "value": 19}, {"description": "Roll 270\u00b0", "value": 20}, {"description": "Roll 270\u00b0, Yaw 45\u00b0", "value": 21}, {"description": "Roll 270\u00b0, Yaw 90\u00b0", "value": 22}, {"description": "Roll 270\u00b0, Yaw 135\u00b0", "value": 23}, {"description": "Pitch 90\u00b0", "value": 24}, {"description": "Pitch 270\u00b0", "value": 25}, {"description": "Pitch 180\u00b0, Yaw 90\u00b0", "value": 26}, {"description": "Pitch 180\u00b0, Yaw 270\u00b0", "value": 27}, {"description": "Roll 90\u00b0, Pitch 90\u00b0", "value": 28}, {"description": "Roll 180\u00b0, Pitch 90\u00b0", "value": 29}, {"description": "Roll 270\u00b0, Pitch 90\u00b0", "value": 30}, {"description": "Roll 90\u00b0, Pitch 180\u00b0", "value": 31}, {"description": "Roll 270\u00b0, Pitch 180\u00b0", "value": 32}, {"description": "Roll 90\u00b0, Pitch 270\u00b0", "value": 33}, {"description": "Roll 180\u00b0, Pitch 270\u00b0", "value": 34}, {"description": "Roll 270\u00b0, Pitch 270\u00b0", "value": 35}, {"description": "Roll 90\u00b0, Pitch 180\u00b0, Yaw 90\u00b0", "value": 36}, {"description": "Roll 90\u00b0, Yaw 270\u00b0", "value": 37}, {"description": "Roll 90\u00b0, Pitch 68\u00b0, Yaw 293\u00b0", "value": 38}, {"description": "Pitch 315\u00b0", "value": 39}, {"description": "Roll 90\u00b0, Pitch 315\u00b0", "value": 40}]}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_ACC3_XOFF", "shortDesc": "Accelerometer 3 X-axis offset", "type": "Float", "units": "m/s^2", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_ACC3_XSCALE", "shortDesc": "Accelerometer 3 X-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_ACC3_YOFF", "shortDesc": "Accelerometer 3 Y-axis offset", "type": "Float", "units": "m/s^2", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_ACC3_YSCALE", "shortDesc": "Accelerometer 3 Y-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_ACC3_ZOFF", "shortDesc": "Accelerometer 3 Z-axis offset", "type": "Float", "units": "m/s^2", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_ACC3_ZSCALE", "shortDesc": "Accelerometer 3 Z-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the barometer this calibration applies to.\n", "name": "CAL_BARO0_ID", "shortDesc": "Barometer 0 calibration device ID", "type": "Int32"}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_BARO0_OFF", "shortDesc": "Barometer 0 offset", "type": "Float", "units": "Pa", "volatile": true}, {"category": "System", "default": -1, "group": "Sensor Calibration", "name": "CAL_BARO0_PRIO", "shortDesc": "Barometer 0 priority", "type": "Int32", "values": [{"description": "Uninitialized", "value": -1}, {"description": "Disabled", "value": 0}, {"description": "Min", "value": 1}, {"description": "Low", "value": 25}, {"description": "Medium (Default)", "value": 50}, {"description": "High", "value": 75}, {"description": "Max", "value": 100}]}, {"category": "System", "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the barometer this calibration applies to.\n", "name": "CAL_BARO1_ID", "shortDesc": "Barometer 1 calibration device ID", "type": "Int32"}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_BARO1_OFF", "shortDesc": "Barometer 1 offset", "type": "Float", "units": "Pa", "volatile": true}, {"category": "System", "default": -1, "group": "Sensor Calibration", "name": "CAL_BARO1_PRIO", "shortDesc": "Barometer 1 priority", "type": "Int32", "values": [{"description": "Uninitialized", "value": -1}, {"description": "Disabled", "value": 0}, {"description": "Min", "value": 1}, {"description": "Low", "value": 25}, {"description": "Medium (Default)", "value": 50}, {"description": "High", "value": 75}, {"description": "Max", "value": 100}]}, {"category": "System", "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the barometer this calibration applies to.\n", "name": "CAL_BARO2_ID", "shortDesc": "Barometer 2 calibration device ID", "type": "Int32"}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_BARO2_OFF", "shortDesc": "Barometer 2 offset", "type": "Float", "units": "Pa", "volatile": true}, {"category": "System", "default": -1, "group": "Sensor Calibration", "name": "CAL_BARO2_PRIO", "shortDesc": "Barometer 2 priority", "type": "Int32", "values": [{"description": "Uninitialized", "value": -1}, {"description": "Disabled", "value": 0}, {"description": "Min", "value": 1}, {"description": "Low", "value": 25}, {"description": "Medium (Default)", "value": 50}, {"description": "High", "value": 75}, {"description": "Max", "value": 100}]}, {"category": "System", "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the barometer this calibration applies to.\n", "name": "CAL_BARO3_ID", "shortDesc": "Barometer 3 calibration device ID", "type": "Int32"}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_BARO3_OFF", "shortDesc": "Barometer 3 offset", "type": "Float", "units": "Pa", "volatile": true}, {"category": "System", "default": -1, "group": "Sensor Calibration", "name": "CAL_BARO3_PRIO", "shortDesc": "Barometer 3 priority", "type": "Int32", "values": [{"description": "Uninitialized", "value": -1}, {"description": "Disabled", "value": 0}, {"description": "Min", "value": 1}, {"description": "Low", "value": 25}, {"description": "Medium (Default)", "value": 50}, {"description": "High", "value": 75}, {"description": "Max", "value": 100}]}, {"category": "System", "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the differential pressure sensor this calibration applies to.\n", "name": "CAL_DPRES0_ID", "shortDesc": "Differential pressure sensor 0 calibration device ID", "type": "Int32"}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "The zero-reading of this differential pressure sensor.\n", "name": "CAL_DPRES0_OFF", "shortDesc": "Differential pressure sensor 0 offset", "type": "Float", "units": "Pa", "volatile": true}, {"category": "System", "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the differential pressure sensor this calibration applies to.\n", "name": "CAL_DPRES1_ID", "shortDesc": "Differential pressure sensor 1 calibration device ID", "type": "Int32"}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "The zero-reading of this differential pressure sensor.\n", "name": "CAL_DPRES1_OFF", "shortDesc": "Differential pressure sensor 1 offset", "type": "Float", "units": "Pa", "volatile": true}, {"category": "System", "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the differential pressure sensor this calibration applies to.\n", "name": "CAL_DPRES2_ID", "shortDesc": "Differential pressure sensor 2 calibration device ID", "type": "Int32"}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "The zero-reading of this differential pressure sensor.\n", "name": "CAL_DPRES2_OFF", "shortDesc": "Differential pressure sensor 2 offset", "type": "Float", "units": "Pa", "volatile": true}, {"category": "System", "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the gyroscope this calibration applies to.\n", "name": "CAL_GYRO0_ID", "shortDesc": "Gyroscope 0 calibration device ID", "type": "Int32"}, {"category": "System", "default": -1, "group": "Sensor Calibration", "longDesc": "Uninitialized sensors default to Medium when internal and Low when\nexternal, so an on-board IMU is preferred over one behind a bus.\n\n", "name": "CAL_GYRO0_PRIO", "shortDesc": "Gyroscope 0 priority", "type": "Int32", "values": [{"description": "Uninitialized", "value": -1}, {"description": "Disabled", "value": 0}, {"description": "Min", "value": 1}, {"description": "Low", "value": 25}, {"description": "Medium (Default)", "value": 50}, {"description": "High", "value": 75}, {"description": "Max", "value": 100}]}, {"category": "System", "default": -1, "group": "Sensor Calibration", "longDesc": "An internal sensor will force a value of -1, so a GCS should only attempt to configure the rotation if the value is greater than or equal to zero.\n\n", "max": 40, "min": -1, "name": "CAL_GYRO0_ROT", "shortDesc": "Gyroscope 0 rotation relative to airframe", "type": "Int32", "values": [{"description": "Internal", "value": -1}, {"description": "No rotation", "value": 0}, {"description": "Yaw 45\u00b0", "value": 1}, {"description": "Yaw 90\u00b0", "value": 2}, {"description": "Yaw 135\u00b0", "value": 3}, {"description": "Yaw 180\u00b0", "value": 4}, {"description": "Yaw 225\u00b0", "value": 5}, {"description": "Yaw 270\u00b0", "value": 6}, {"description": "Yaw 315\u00b0", "value": 7}, {"description": "Roll 180\u00b0", "value": 8}, {"description": "Roll 180\u00b0, Yaw 45\u00b0", "value": 9}, {"description": "Roll 180\u00b0, Yaw 90\u00b0", "value": 10}, {"description": "Roll 180\u00b0, Yaw 135\u00b0", "value": 11}, {"description": "Pitch 180\u00b0", "value": 12}, {"description": "Roll 180\u00b0, Yaw 225\u00b0", "value": 13}, {"description": "Roll 180\u00b0, Yaw 270\u00b0", "value": 14}, {"description": "Roll 180\u00b0, Yaw 315\u00b0", "value": 15}, {"description": "Roll 90\u00b0", "value": 16}, {"description": "Roll 90\u00b0, Yaw 45\u00b0", "value": 17}, {"description": "Roll 90\u00b0, Yaw 90\u00b0", "value": 18}, {"description": "Roll 90\u00b0, Yaw 135\u00b0", "value": 19}, {"description": "Roll 270\u00b0", "value": 20}, {"description": "Roll 270\u00b0, Yaw 45\u00b0", "value": 21}, {"description": "Roll 270\u00b0, Yaw 90\u00b0", "value": 22}, {"description": "Roll 270\u00b0, Yaw 135\u00b0", "value": 23}, {"description": "Pitch 90\u00b0", "value": 24}, {"description": "Pitch 270\u00b0", "value": 25}, {"description": "Pitch 180\u00b0, Yaw 90\u00b0", "value": 26}, {"description": "Pitch 180\u00b0, Yaw 270\u00b0", "value": 27}, {"description": "Roll 90\u00b0, Pitch 90\u00b0", "value": 28}, {"description": "Roll 180\u00b0, Pitch 90\u00b0", "value": 29}, {"description": "Roll 270\u00b0, Pitch 90\u00b0", "value": 30}, {"description": "Roll 90\u00b0, Pitch 180\u00b0", "value": 31}, {"description": "Roll 270\u00b0, Pitch 180\u00b0", "value": 32}, {"description": "Roll 90\u00b0, Pitch 270\u00b0", "value": 33}, {"description": "Roll 180\u00b0, Pitch 270\u00b0", "value": 34}, {"description": "Roll 270\u00b0, Pitch 270\u00b0", "value": 35}, {"description": "Roll 90\u00b0, Pitch 180\u00b0, Yaw 90\u00b0", "value": 36}, {"description": "Roll 90\u00b0, Yaw 270\u00b0", "value": 37}, {"description": "Roll 90\u00b0, Pitch 68\u00b0, Yaw 293\u00b0", "value": 38}, {"description": "Pitch 315\u00b0", "value": 39}, {"description": "Roll 90\u00b0, Pitch 315\u00b0", "value": 40}]}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_GYRO0_XOFF", "shortDesc": "Gyroscope 0 X-axis offset", "type": "Float", "units": "rad/s", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_GYRO0_YOFF", "shortDesc": "Gyroscope 0 Y-axis offset", "type": "Float", "units": "rad/s", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_GYRO0_ZOFF", "shortDesc": "Gyroscope 0 Z-axis offset", "type": "Float", "units": "rad/s", "volatile": true}, {"category": "System", "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the gyroscope this calibration applies to.\n", "name": "CAL_GYRO1_ID", "shortDesc": "Gyroscope 1 calibration device ID", "type": "Int32"}, {"category": "System", "default": -1, "group": "Sensor Calibration", "longDesc": "Uninitialized sensors default to Medium when internal and Low when\nexternal, so an on-board IMU is preferred over one behind a bus.\n\n", "name": "CAL_GYRO1_PRIO", "shortDesc": "Gyroscope 1 priority", "type": "Int32", "values": [{"description": "Uninitialized", "value": -1}, {"description": "Disabled", "value": 0}, {"description": "Min", "value": 1}, {"description": "Low", "value": 25}, {"description": "Medium (Default)", "value": 50}, {"description": "High", "value": 75}, {"description": "Max", "value": 100}]}, {"category": "System", "default": -1, "group": "Sensor Calibration", "longDesc": "An internal sensor will force a value of -1, so a GCS should only attempt to configure the rotation if the value is greater than or equal to zero.\n\n", "max": 40, "min": -1, "name": "CAL_GYRO1_ROT", "shortDesc": "Gyroscope 1 rotation relative to airframe", "type": "Int32", "values": [{"description": "Internal", "value": -1}, {"description": "No rotation", "value": 0}, {"description": "Yaw 45\u00b0", "value": 1}, {"description": "Yaw 90\u00b0", "value": 2}, {"description": "Yaw 135\u00b0", "value": 3}, {"description": "Yaw 180\u00b0", "value": 4}, {"description": "Yaw 225\u00b0", "value": 5}, {"description": "Yaw 270\u00b0", "value": 6}, {"description": "Yaw 315\u00b0", "value": 7}, {"description": "Roll 180\u00b0", "value": 8}, {"description": "Roll 180\u00b0, Yaw 45\u00b0", "value": 9}, {"description": "Roll 180\u00b0, Yaw 90\u00b0", "value": 10}, {"description": "Roll 180\u00b0, Yaw 135\u00b0", "value": 11}, {"description": "Pitch 180\u00b0", "value": 12}, {"description": "Roll 180\u00b0, Yaw 225\u00b0", "value": 13}, {"description": "Roll 180\u00b0, Yaw 270\u00b0", "value": 14}, {"description": "Roll 180\u00b0, Yaw 315\u00b0", "value": 15}, {"description": "Roll 90\u00b0", "value": 16}, {"description": "Roll 90\u00b0, Yaw 45\u00b0", "value": 17}, {"description": "Roll 90\u00b0, Yaw 90\u00b0", "value": 18}, {"description": "Roll 90\u00b0, Yaw 135\u00b0", "value": 19}, {"description": "Roll 270\u00b0", "value": 20}, {"description": "Roll 270\u00b0, Yaw 45\u00b0", "value": 21}, {"description": "Roll 270\u00b0, Yaw 90\u00b0", "value": 22}, {"description": "Roll 270\u00b0, Yaw 135\u00b0", "value": 23}, {"description": "Pitch 90\u00b0", "value": 24}, {"description": "Pitch 270\u00b0", "value": 25}, {"description": "Pitch 180\u00b0, Yaw 90\u00b0", "value": 26}, {"description": "Pitch 180\u00b0, Yaw 270\u00b0", "value": 27}, {"description": "Roll 90\u00b0, Pitch 90\u00b0", "value": 28}, {"description": "Roll 180\u00b0, Pitch 90\u00b0", "value": 29}, {"description": "Roll 270\u00b0, Pitch 90\u00b0", "value": 30}, {"description": "Roll 90\u00b0, Pitch 180\u00b0", "value": 31}, {"description": "Roll 270\u00b0, Pitch 180\u00b0", "value": 32}, {"description": "Roll 90\u00b0, Pitch 270\u00b0", "value": 33}, {"description": "Roll 180\u00b0, Pitch 270\u00b0", "value": 34}, {"description": "Roll 270\u00b0, Pitch 270\u00b0", "value": 35}, {"description": "Roll 90\u00b0, Pitch 180\u00b0, Yaw 90\u00b0", "value": 36}, {"description": "Roll 90\u00b0, Yaw 270\u00b0", "value": 37}, {"description": "Roll 90\u00b0, Pitch 68\u00b0, Yaw 293\u00b0", "value": 38}, {"description": "Pitch 315\u00b0", "value": 39}, {"description": "Roll 90\u00b0, Pitch 315\u00b0", "value": 40}]}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_GYRO1_XOFF", "shortDesc": "Gyroscope 1 X-axis offset", "type": "Float", "units": "rad/s", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_GYRO1_YOFF", "shortDesc": "Gyroscope 1 Y-axis offset", "type": "Float", "units": "rad/s", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_GYRO1_ZOFF", "shortDesc": "Gyroscope 1 Z-axis offset", "type": "Float", "units": "rad/s", "volatile": true}, {"category": "System", "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the gyroscope this calibration applies to.\n", "name": "CAL_GYRO2_ID", "shortDesc": "Gyroscope 2 calibration device ID", "type": "Int32"}, {"category": "System", "default": -1, "group": "Sensor Calibration", "longDesc": "Uninitialized sensors default to Medium when internal and Low when\nexternal, so an on-board IMU is preferred over one behind a bus.\n\n", "name": "CAL_GYRO2_PRIO", "shortDesc": "Gyroscope 2 priority", "type": "Int32", "values": [{"description": "Uninitialized", "value": -1}, {"description": "Disabled", "value": 0}, {"description": "Min", "value": 1}, {"description": "Low", "value": 25}, {"description": "Medium (Default)", "value": 50}, {"description": "High", "value": 75}, {"description": "Max", "value": 100}]}, {"category": "System", "default": -1, "group": "Sensor Calibration", "longDesc": "An internal sensor will force a value of -1, so a GCS should only attempt to configure the rotation if the value is greater than or equal to zero.\n\n", "max": 40, "min": -1, "name": "CAL_GYRO2_ROT", "shortDesc": "Gyroscope 2 rotation relative to airframe", "type": "Int32", "values": [{"description": "Internal", "value": -1}, {"description": "No rotation", "value": 0}, {"description": "Yaw 45\u00b0", "value": 1}, {"description": "Yaw 90\u00b0", "value": 2}, {"description": "Yaw 135\u00b0", "value": 3}, {"description": "Yaw 180\u00b0", "value": 4}, {"description": "Yaw 225\u00b0", "value": 5}, {"description": "Yaw 270\u00b0", "value": 6}, {"description": "Yaw 315\u00b0", "value": 7}, {"description": "Roll 180\u00b0", "value": 8}, {"description": "Roll 180\u00b0, Yaw 45\u00b0", "value": 9}, {"description": "Roll 180\u00b0, Yaw 90\u00b0", "value": 10}, {"description": "Roll 180\u00b0, Yaw 135\u00b0", "value": 11}, {"description": "Pitch 180\u00b0", "value": 12}, {"description": "Roll 180\u00b0, Yaw 225\u00b0", "value": 13}, {"description": "Roll 180\u00b0, Yaw 270\u00b0", "value": 14}, {"description": "Roll 180\u00b0, Yaw 315\u00b0", "value": 15}, {"description": "Roll 90\u00b0", "value": 16}, {"description": "Roll 90\u00b0, Yaw 45\u00b0", "value": 17}, {"description": "Roll 90\u00b0, Yaw 90\u00b0", "value": 18}, {"description": "Roll 90\u00b0, Yaw 135\u00b0", "value": 19}, {"description": "Roll 270\u00b0", "value": 20}, {"description": "Roll 270\u00b0, Yaw 45\u00b0", "value": 21}, {"description": "Roll 270\u00b0, Yaw 90\u00b0", "value": 22}, {"description": "Roll 270\u00b0, Yaw 135\u00b0", "value": 23}, {"description": "Pitch 90\u00b0", "value": 24}, {"description": "Pitch 270\u00b0", "value": 25}, {"description": "Pitch 180\u00b0, Yaw 90\u00b0", "value": 26}, {"description": "Pitch 180\u00b0, Yaw 270\u00b0", "value": 27}, {"description": "Roll 90\u00b0, Pitch 90\u00b0", "value": 28}, {"description": "Roll 180\u00b0, Pitch 90\u00b0", "value": 29}, {"description": "Roll 270\u00b0, Pitch 90\u00b0", "value": 30}, {"description": "Roll 90\u00b0, Pitch 180\u00b0", "value": 31}, {"description": "Roll 270\u00b0, Pitch 180\u00b0", "value": 32}, {"description": "Roll 90\u00b0, Pitch 270\u00b0", "value": 33}, {"description": "Roll 180\u00b0, Pitch 270\u00b0", "value": 34}, {"description": "Roll 270\u00b0, Pitch 270\u00b0", "value": 35}, {"description": "Roll 90\u00b0, Pitch 180\u00b0, Yaw 90\u00b0", "value": 36}, {"description": "Roll 90\u00b0, Yaw 270\u00b0", "value": 37}, {"description": "Roll 90\u00b0, Pitch 68\u00b0, Yaw 293\u00b0", "value": 38}, {"description": "Pitch 315\u00b0", "value": 39}, {"description": "Roll 90\u00b0, Pitch 315\u00b0", "value": 40}]}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_GYRO2_XOFF", "shortDesc": "Gyroscope 2 X-axis offset", "type": "Float", "units": "rad/s", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_GYRO2_YOFF", "shortDesc": "Gyroscope 2 Y-axis offset", "type": "Float", "units": "rad/s", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_GYRO2_ZOFF", "shortDesc": "Gyroscope 2 Z-axis offset", "type": "Float", "units": "rad/s", "volatile": true}, {"category": "System", "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the gyroscope this calibration applies to.\n", "name": "CAL_GYRO3_ID", "shortDesc": "Gyroscope 3 calibration device ID", "type": "Int32"}, {"category": "System", "default": -1, "group": "Sensor Calibration", "longDesc": "Uninitialized sensors default to Medium when internal and Low when\nexternal, so an on-board IMU is preferred over one behind a bus.\n\n", "name": "CAL_GYRO3_PRIO", "shortDesc": "Gyroscope 3 priority", "type": "Int32", "values": [{"description": "Uninitialized", "value": -1}, {"description": "Disabled", "value": 0}, {"description": "Min", "value": 1}, {"description": "Low", "value": 25}, {"description": "Medium (Default)", "value": 50}, {"description": "High", "value": 75}, {"description": "Max", "value": 100}]}, {"category": "System", "default": -1, "group": "Sensor Calibration", "longDesc": "An internal sensor will force a value of -1, so a GCS should only attempt to configure the rotation if the value is greater than or equal to zero.\n\n", "max": 40, "min": -1, "name": "CAL_GYRO3_ROT", "shortDesc": "Gyroscope 3 rotation relative to airframe", "type": "Int32", "values": [{"description": "Internal", "value": -1}, {"description": "No rotation", "value": 0}, {"description": "Yaw 45\u00b0", "value": 1}, {"description": "Yaw 90\u00b0", "value": 2}, {"description": "Yaw 135\u00b0", "value": 3}, {"description": "Yaw 180\u00b0", "value": 4}, {"description": "Yaw 225\u00b0", "value": 5}, {"description": "Yaw 270\u00b0", "value": 6}, {"description": "Yaw 315\u00b0", "value": 7}, {"description": "Roll 180\u00b0", "value": 8}, {"description": "Roll 180\u00b0, Yaw 45\u00b0", "value": 9}, {"description": "Roll 180\u00b0, Yaw 90\u00b0", "value": 10}, {"description": "Roll 180\u00b0, Yaw 135\u00b0", "value": 11}, {"description": "Pitch 180\u00b0", "value": 12}, {"description": "Roll 180\u00b0, Yaw 225\u00b0", "value": 13}, {"description": "Roll 180\u00b0, Yaw 270\u00b0", "value": 14}, {"description": "Roll 180\u00b0, Yaw 315\u00b0", "value": 15}, {"description": "Roll 90\u00b0", "value": 16}, {"description": "Roll 90\u00b0, Yaw 45\u00b0", "value": 17}, {"description": "Roll 90\u00b0, Yaw 90\u00b0", "value": 18}, {"description": "Roll 90\u00b0, Yaw 135\u00b0", "value": 19}, {"description": "Roll 270\u00b0", "value": 20}, {"description": "Roll 270\u00b0, Yaw 45\u00b0", "value": 21}, {"description": "Roll 270\u00b0, Yaw 90\u00b0", "value": 22}, {"description": "Roll 270\u00b0, Yaw 135\u00b0", "value": 23}, {"description": "Pitch 90\u00b0", "value": 24}, {"description": "Pitch 270\u00b0", "value": 25}, {"description": "Pitch 180\u00b0, Yaw 90\u00b0", "value": 26}, {"description": "Pitch 180\u00b0, Yaw 270\u00b0", "value": 27}, {"description": "Roll 90\u00b0, Pitch 90\u00b0", "value": 28}, {"description": "Roll 180\u00b0, Pitch 90\u00b0", "value": 29}, {"description": "Roll 270\u00b0, Pitch 90\u00b0", "value": 30}, {"description": "Roll 90\u00b0, Pitch 180\u00b0", "value": 31}, {"description": "Roll 270\u00b0, Pitch 180\u00b0", "value": 32}, {"description": "Roll 90\u00b0, Pitch 270\u00b0", "value": 33}, {"description": "Roll 180\u00b0, Pitch 270\u00b0", "value": 34}, {"description": "Roll 270\u00b0, Pitch 270\u00b0", "value": 35}, {"description": "Roll 90\u00b0, Pitch 180\u00b0, Yaw 90\u00b0", "value": 36}, {"description": "Roll 90\u00b0, Yaw 270\u00b0", "value": 37}, {"description": "Roll 90\u00b0, Pitch 68\u00b0, Yaw 293\u00b0", "value": 38}, {"description": "Pitch 315\u00b0", "value": 39}, {"description": "Roll 90\u00b0, Pitch 315\u00b0", "value": 40}]}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_GYRO3_XOFF", "shortDesc": "Gyroscope 3 X-axis offset", "type": "Float", "units": "rad/s", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_GYRO3_YOFF", "shortDesc": "Gyroscope 3 Y-axis offset", "type": "Float", "units": "rad/s", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_GYRO3_ZOFF", "shortDesc": "Gyroscope 3 Z-axis offset", "type": "Float", "units": "rad/s", "volatile": true}, {"category": "System", "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the magnetometer this calibration applies to.\n", "name": "CAL_MAG0_ID", "shortDesc": "Magnetometer 0 calibration device ID", "type": "Int32"}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "longDesc": "Setting this parameter changes CAL_MAG0_ROT to \"Custom Euler Angle\"\n", "max": 180.0, "min": -180.0, "name": "CAL_MAG0_PITCH", "shortDesc": "Magnetometer 0 Custom Euler Pitch Angle", "type": "Float", "units": "deg"}, {"category": "System", "default": -1, "group": "Sensor Calibration", "name": "CAL_MAG0_PRIO", "shortDesc": "Magnetometer 0 priority", "type": "Int32", "values": [{"description": "Uninitialized", "value": -1}, {"description": "Disabled", "value": 0}, {"description": "Min", "value": 1}, {"description": "Low", "value": 25}, {"description": "Medium (Default)", "value": 50}, {"description": "High", "value": 75}, {"description": "Max", "value": 100}]}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "longDesc": "Setting this parameter changes CAL_MAG0_ROT to \"Custom Euler Angle\"\n", "max": 180.0, "min": -180.0, "name": "CAL_MAG0_ROLL", "shortDesc": "Magnetometer 0 Custom Euler Roll Angle", "type": "Float", "units": "deg"}, {"category": "System", "default": -1, "group": "Sensor Calibration", "longDesc": "An internal sensor will force a value of -1, so a GCS should only attempt to configure the rotation if the value is greater than or equal to zero.\nSet to \"Custom Euler Angle\" to define the rotation using CAL_MAG0_ROLL, CAL_MAG0_PITCH and CAL_MAG0_YAW.\n\n", "max": 100, "min": -1, "name": "CAL_MAG0_ROT", "shortDesc": "Magnetometer 0 rotation relative to airframe", "type": "Int32", "values": [{"description": "Internal", "value": -1}, {"description": "No rotation", "value": 0}, {"description": "Yaw 45\u00b0", "value": 1}, {"description": "Yaw 90\u00b0", "value": 2}, {"description": "Yaw 135\u00b0", "value": 3}, {"description": "Yaw 180\u00b0", "value": 4}, {"description": "Yaw 225\u00b0", "value": 5}, {"description": "Yaw 270\u00b0", "value": 6}, {"description": "Yaw 315\u00b0", "value": 7}, {"description": "Roll 180\u00b0", "value": 8}, {"description": "Roll 180\u00b0, Yaw 45\u00b0", "value": 9}, {"description": "Roll 180\u00b0, Yaw 90\u00b0", "value": 10}, {"description": "Roll 180\u00b0, Yaw 135\u00b0", "value": 11}, {"description": "Pitch 180\u00b0", "value": 12}, {"description": "Roll 180\u00b0, Yaw 225\u00b0", "value": 13}, {"description": "Roll 180\u00b0, Yaw 270\u00b0", "value": 14}, {"description": "Roll 180\u00b0, Yaw 315\u00b0", "value": 15}, {"description": "Roll 90\u00b0", "value": 16}, {"description": "Roll 90\u00b0, Yaw 45\u00b0", "value": 17}, {"description": "Roll 90\u00b0, Yaw 90\u00b0", "value": 18}, {"description": "Roll 90\u00b0, Yaw 135\u00b0", "value": 19}, {"description": "Roll 270\u00b0", "value": 20}, {"description": "Roll 270\u00b0, Yaw 45\u00b0", "value": 21}, {"description": "Roll 270\u00b0, Yaw 90\u00b0", "value": 22}, {"description": "Roll 270\u00b0, Yaw 135\u00b0", "value": 23}, {"description": "Pitch 90\u00b0", "value": 24}, {"description": "Pitch 270\u00b0", "value": 25}, {"description": "Pitch 180\u00b0, Yaw 90\u00b0", "value": 26}, {"description": "Pitch 180\u00b0, Yaw 270\u00b0", "value": 27}, {"description": "Roll 90\u00b0, Pitch 90\u00b0", "value": 28}, {"description": "Roll 180\u00b0, Pitch 90\u00b0", "value": 29}, {"description": "Roll 270\u00b0, Pitch 90\u00b0", "value": 30}, {"description": "Roll 90\u00b0, Pitch 180\u00b0", "value": 31}, {"description": "Roll 270\u00b0, Pitch 180\u00b0", "value": 32}, {"description": "Roll 90\u00b0, Pitch 270\u00b0", "value": 33}, {"description": "Roll 180\u00b0, Pitch 270\u00b0", "value": 34}, {"description": "Roll 270\u00b0, Pitch 270\u00b0", "value": 35}, {"description": "Roll 90\u00b0, Pitch 180\u00b0, Yaw 90\u00b0", "value": 36}, {"description": "Roll 90\u00b0, Yaw 270\u00b0", "value": 37}, {"description": "Roll 90\u00b0, Pitch 68\u00b0, Yaw 293\u00b0", "value": 38}, {"description": "Pitch 315\u00b0", "value": 39}, {"description": "Roll 90\u00b0, Pitch 315\u00b0", "value": 40}, {"description": "Custom Euler Angle", "value": 100}]}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "Coefficient describing linear relationship between\nX component of magnetometer in body frame axis\nand either current or throttle depending on value of CAL_MAG_COMP_TYP.\nUnit for throttle-based compensation is [G] and\nfor current-based compensation [G/kA]\n\n", "name": "CAL_MAG0_XCOMP", "shortDesc": "Magnetometer 0 X Axis throttle compensation", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG0_XODIAG", "shortDesc": "Magnetometer 0 X-axis off diagonal scale factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG0_XOFF", "shortDesc": "Magnetometer 0 X-axis offset", "type": "Float", "units": "gauss", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_MAG0_XSCALE", "shortDesc": "Magnetometer 0 X-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "longDesc": "Setting this parameter changes CAL_MAG0_ROT to \"Custom Euler Angle\"\n", "max": 180.0, "min": -180.0, "name": "CAL_MAG0_YAW", "shortDesc": "Magnetometer 0 Custom Euler Yaw Angle", "type": "Float", "units": "deg"}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "Coefficient describing linear relationship between\nY component of magnetometer in body frame axis\nand either current or throttle depending on value of CAL_MAG_COMP_TYP.\nUnit for throttle-based compensation is [G] and\nfor current-based compensation [G/kA]\n\n", "name": "CAL_MAG0_YCOMP", "shortDesc": "Magnetometer 0 Y Axis throttle compensation", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG0_YODIAG", "shortDesc": "Magnetometer 0 Y-axis off diagonal scale factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG0_YOFF", "shortDesc": "Magnetometer 0 Y-axis offset", "type": "Float", "units": "gauss", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_MAG0_YSCALE", "shortDesc": "Magnetometer 0 Y-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "Coefficient describing linear relationship between\nZ component of magnetometer in body frame axis\nand either current or throttle depending on value of CAL_MAG_COMP_TYP.\nUnit for throttle-based compensation is [G] and\nfor current-based compensation [G/kA]\n\n", "name": "CAL_MAG0_ZCOMP", "shortDesc": "Magnetometer 0 Z Axis throttle compensation", "type": "Float", "volatile": true}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG0_ZODIAG", "shortDesc": "Magnetometer 0 Z-axis off diagonal scale factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG0_ZOFF", "shortDesc": "Magnetometer 0 Z-axis offset", "type": "Float", "units": "gauss", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_MAG0_ZSCALE", "shortDesc": "Magnetometer 0 Z-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the magnetometer this calibration applies to.\n", "name": "CAL_MAG1_ID", "shortDesc": "Magnetometer 1 calibration device ID", "type": "Int32"}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "longDesc": "Setting this parameter changes CAL_MAG1_ROT to \"Custom Euler Angle\"\n", "max": 180.0, "min": -180.0, "name": "CAL_MAG1_PITCH", "shortDesc": "Magnetometer 1 Custom Euler Pitch Angle", "type": "Float", "units": "deg"}, {"category": "System", "default": -1, "group": "Sensor Calibration", "name": "CAL_MAG1_PRIO", "shortDesc": "Magnetometer 1 priority", "type": "Int32", "values": [{"description": "Uninitialized", "value": -1}, {"description": "Disabled", "value": 0}, {"description": "Min", "value": 1}, {"description": "Low", "value": 25}, {"description": "Medium (Default)", "value": 50}, {"description": "High", "value": 75}, {"description": "Max", "value": 100}]}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "longDesc": "Setting this parameter changes CAL_MAG1_ROT to \"Custom Euler Angle\"\n", "max": 180.0, "min": -180.0, "name": "CAL_MAG1_ROLL", "shortDesc": "Magnetometer 1 Custom Euler Roll Angle", "type": "Float", "units": "deg"}, {"category": "System", "default": -1, "group": "Sensor Calibration", "longDesc": "An internal sensor will force a value of -1, so a GCS should only attempt to configure the rotation if the value is greater than or equal to zero.\nSet to \"Custom Euler Angle\" to define the rotation using CAL_MAG1_ROLL, CAL_MAG1_PITCH and CAL_MAG1_YAW.\n\n", "max": 100, "min": -1, "name": "CAL_MAG1_ROT", "shortDesc": "Magnetometer 1 rotation relative to airframe", "type": "Int32", "values": [{"description": "Internal", "value": -1}, {"description": "No rotation", "value": 0}, {"description": "Yaw 45\u00b0", "value": 1}, {"description": "Yaw 90\u00b0", "value": 2}, {"description": "Yaw 135\u00b0", "value": 3}, {"description": "Yaw 180\u00b0", "value": 4}, {"description": "Yaw 225\u00b0", "value": 5}, {"description": "Yaw 270\u00b0", "value": 6}, {"description": "Yaw 315\u00b0", "value": 7}, {"description": "Roll 180\u00b0", "value": 8}, {"description": "Roll 180\u00b0, Yaw 45\u00b0", "value": 9}, {"description": "Roll 180\u00b0, Yaw 90\u00b0", "value": 10}, {"description": "Roll 180\u00b0, Yaw 135\u00b0", "value": 11}, {"description": "Pitch 180\u00b0", "value": 12}, {"description": "Roll 180\u00b0, Yaw 225\u00b0", "value": 13}, {"description": "Roll 180\u00b0, Yaw 270\u00b0", "value": 14}, {"description": "Roll 180\u00b0, Yaw 315\u00b0", "value": 15}, {"description": "Roll 90\u00b0", "value": 16}, {"description": "Roll 90\u00b0, Yaw 45\u00b0", "value": 17}, {"description": "Roll 90\u00b0, Yaw 90\u00b0", "value": 18}, {"description": "Roll 90\u00b0, Yaw 135\u00b0", "value": 19}, {"description": "Roll 270\u00b0", "value": 20}, {"description": "Roll 270\u00b0, Yaw 45\u00b0", "value": 21}, {"description": "Roll 270\u00b0, Yaw 90\u00b0", "value": 22}, {"description": "Roll 270\u00b0, Yaw 135\u00b0", "value": 23}, {"description": "Pitch 90\u00b0", "value": 24}, {"description": "Pitch 270\u00b0", "value": 25}, {"description": "Pitch 180\u00b0, Yaw 90\u00b0", "value": 26}, {"description": "Pitch 180\u00b0, Yaw 270\u00b0", "value": 27}, {"description": "Roll 90\u00b0, Pitch 90\u00b0", "value": 28}, {"description": "Roll 180\u00b0, Pitch 90\u00b0", "value": 29}, {"description": "Roll 270\u00b0, Pitch 90\u00b0", "value": 30}, {"description": "Roll 90\u00b0, Pitch 180\u00b0", "value": 31}, {"description": "Roll 270\u00b0, Pitch 180\u00b0", "value": 32}, {"description": "Roll 90\u00b0, Pitch 270\u00b0", "value": 33}, {"description": "Roll 180\u00b0, Pitch 270\u00b0", "value": 34}, {"description": "Roll 270\u00b0, Pitch 270\u00b0", "value": 35}, {"description": "Roll 90\u00b0, Pitch 180\u00b0, Yaw 90\u00b0", "value": 36}, {"description": "Roll 90\u00b0, Yaw 270\u00b0", "value": 37}, {"description": "Roll 90\u00b0, Pitch 68\u00b0, Yaw 293\u00b0", "value": 38}, {"description": "Pitch 315\u00b0", "value": 39}, {"description": "Roll 90\u00b0, Pitch 315\u00b0", "value": 40}, {"description": "Custom Euler Angle", "value": 100}]}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "Coefficient describing linear relationship between\nX component of magnetometer in body frame axis\nand either current or throttle depending on value of CAL_MAG_COMP_TYP.\nUnit for throttle-based compensation is [G] and\nfor current-based compensation [G/kA]\n\n", "name": "CAL_MAG1_XCOMP", "shortDesc": "Magnetometer 1 X Axis throttle compensation", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG1_XODIAG", "shortDesc": "Magnetometer 1 X-axis off diagonal scale factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG1_XOFF", "shortDesc": "Magnetometer 1 X-axis offset", "type": "Float", "units": "gauss", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_MAG1_XSCALE", "shortDesc": "Magnetometer 1 X-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "longDesc": "Setting this parameter changes CAL_MAG1_ROT to \"Custom Euler Angle\"\n", "max": 180.0, "min": -180.0, "name": "CAL_MAG1_YAW", "shortDesc": "Magnetometer 1 Custom Euler Yaw Angle", "type": "Float", "units": "deg"}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "Coefficient describing linear relationship between\nY component of magnetometer in body frame axis\nand either current or throttle depending on value of CAL_MAG_COMP_TYP.\nUnit for throttle-based compensation is [G] and\nfor current-based compensation [G/kA]\n\n", "name": "CAL_MAG1_YCOMP", "shortDesc": "Magnetometer 1 Y Axis throttle compensation", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG1_YODIAG", "shortDesc": "Magnetometer 1 Y-axis off diagonal scale factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG1_YOFF", "shortDesc": "Magnetometer 1 Y-axis offset", "type": "Float", "units": "gauss", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_MAG1_YSCALE", "shortDesc": "Magnetometer 1 Y-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "Coefficient describing linear relationship between\nZ component of magnetometer in body frame axis\nand either current or throttle depending on value of CAL_MAG_COMP_TYP.\nUnit for throttle-based compensation is [G] and\nfor current-based compensation [G/kA]\n\n", "name": "CAL_MAG1_ZCOMP", "shortDesc": "Magnetometer 1 Z Axis throttle compensation", "type": "Float", "volatile": true}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG1_ZODIAG", "shortDesc": "Magnetometer 1 Z-axis off diagonal scale factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG1_ZOFF", "shortDesc": "Magnetometer 1 Z-axis offset", "type": "Float", "units": "gauss", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_MAG1_ZSCALE", "shortDesc": "Magnetometer 1 Z-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the magnetometer this calibration applies to.\n", "name": "CAL_MAG2_ID", "shortDesc": "Magnetometer 2 calibration device ID", "type": "Int32"}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "longDesc": "Setting this parameter changes CAL_MAG2_ROT to \"Custom Euler Angle\"\n", "max": 180.0, "min": -180.0, "name": "CAL_MAG2_PITCH", "shortDesc": "Magnetometer 2 Custom Euler Pitch Angle", "type": "Float", "units": "deg"}, {"category": "System", "default": -1, "group": "Sensor Calibration", "name": "CAL_MAG2_PRIO", "shortDesc": "Magnetometer 2 priority", "type": "Int32", "values": [{"description": "Uninitialized", "value": -1}, {"description": "Disabled", "value": 0}, {"description": "Min", "value": 1}, {"description": "Low", "value": 25}, {"description": "Medium (Default)", "value": 50}, {"description": "High", "value": 75}, {"description": "Max", "value": 100}]}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "longDesc": "Setting this parameter changes CAL_MAG2_ROT to \"Custom Euler Angle\"\n", "max": 180.0, "min": -180.0, "name": "CAL_MAG2_ROLL", "shortDesc": "Magnetometer 2 Custom Euler Roll Angle", "type": "Float", "units": "deg"}, {"category": "System", "default": -1, "group": "Sensor Calibration", "longDesc": "An internal sensor will force a value of -1, so a GCS should only attempt to configure the rotation if the value is greater than or equal to zero.\nSet to \"Custom Euler Angle\" to define the rotation using CAL_MAG2_ROLL, CAL_MAG2_PITCH and CAL_MAG2_YAW.\n\n", "max": 100, "min": -1, "name": "CAL_MAG2_ROT", "shortDesc": "Magnetometer 2 rotation relative to airframe", "type": "Int32", "values": [{"description": "Internal", "value": -1}, {"description": "No rotation", "value": 0}, {"description": "Yaw 45\u00b0", "value": 1}, {"description": "Yaw 90\u00b0", "value": 2}, {"description": "Yaw 135\u00b0", "value": 3}, {"description": "Yaw 180\u00b0", "value": 4}, {"description": "Yaw 225\u00b0", "value": 5}, {"description": "Yaw 270\u00b0", "value": 6}, {"description": "Yaw 315\u00b0", "value": 7}, {"description": "Roll 180\u00b0", "value": 8}, {"description": "Roll 180\u00b0, Yaw 45\u00b0", "value": 9}, {"description": "Roll 180\u00b0, Yaw 90\u00b0", "value": 10}, {"description": "Roll 180\u00b0, Yaw 135\u00b0", "value": 11}, {"description": "Pitch 180\u00b0", "value": 12}, {"description": "Roll 180\u00b0, Yaw 225\u00b0", "value": 13}, {"description": "Roll 180\u00b0, Yaw 270\u00b0", "value": 14}, {"description": "Roll 180\u00b0, Yaw 315\u00b0", "value": 15}, {"description": "Roll 90\u00b0", "value": 16}, {"description": "Roll 90\u00b0, Yaw 45\u00b0", "value": 17}, {"description": "Roll 90\u00b0, Yaw 90\u00b0", "value": 18}, {"description": "Roll 90\u00b0, Yaw 135\u00b0", "value": 19}, {"description": "Roll 270\u00b0", "value": 20}, {"description": "Roll 270\u00b0, Yaw 45\u00b0", "value": 21}, {"description": "Roll 270\u00b0, Yaw 90\u00b0", "value": 22}, {"description": "Roll 270\u00b0, Yaw 135\u00b0", "value": 23}, {"description": "Pitch 90\u00b0", "value": 24}, {"description": "Pitch 270\u00b0", "value": 25}, {"description": "Pitch 180\u00b0, Yaw 90\u00b0", "value": 26}, {"description": "Pitch 180\u00b0, Yaw 270\u00b0", "value": 27}, {"description": "Roll 90\u00b0, Pitch 90\u00b0", "value": 28}, {"description": "Roll 180\u00b0, Pitch 90\u00b0", "value": 29}, {"description": "Roll 270\u00b0, Pitch 90\u00b0", "value": 30}, {"description": "Roll 90\u00b0, Pitch 180\u00b0", "value": 31}, {"description": "Roll 270\u00b0, Pitch 180\u00b0", "value": 32}, {"description": "Roll 90\u00b0, Pitch 270\u00b0", "value": 33}, {"description": "Roll 180\u00b0, Pitch 270\u00b0", "value": 34}, {"description": "Roll 270\u00b0, Pitch 270\u00b0", "value": 35}, {"description": "Roll 90\u00b0, Pitch 180\u00b0, Yaw 90\u00b0", "value": 36}, {"description": "Roll 90\u00b0, Yaw 270\u00b0", "value": 37}, {"description": "Roll 90\u00b0, Pitch 68\u00b0, Yaw 293\u00b0", "value": 38}, {"description": "Pitch 315\u00b0", "value": 39}, {"description": "Roll 90\u00b0, Pitch 315\u00b0", "value": 40}, {"description": "Custom Euler Angle", "value": 100}]}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "Coefficient describing linear relationship between\nX component of magnetometer in body frame axis\nand either current or throttle depending on value of CAL_MAG_COMP_TYP.\nUnit for throttle-based compensation is [G] and\nfor current-based compensation [G/kA]\n\n", "name": "CAL_MAG2_XCOMP", "shortDesc": "Magnetometer 2 X Axis throttle compensation", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG2_XODIAG", "shortDesc": "Magnetometer 2 X-axis off diagonal scale factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG2_XOFF", "shortDesc": "Magnetometer 2 X-axis offset", "type": "Float", "units": "gauss", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_MAG2_XSCALE", "shortDesc": "Magnetometer 2 X-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "longDesc": "Setting this parameter changes CAL_MAG2_ROT to \"Custom Euler Angle\"\n", "max": 180.0, "min": -180.0, "name": "CAL_MAG2_YAW", "shortDesc": "Magnetometer 2 Custom Euler Yaw Angle", "type": "Float", "units": "deg"}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "Coefficient describing linear relationship between\nY component of magnetometer in body frame axis\nand either current or throttle depending on value of CAL_MAG_COMP_TYP.\nUnit for throttle-based compensation is [G] and\nfor current-based compensation [G/kA]\n\n", "name": "CAL_MAG2_YCOMP", "shortDesc": "Magnetometer 2 Y Axis throttle compensation", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG2_YODIAG", "shortDesc": "Magnetometer 2 Y-axis off diagonal scale factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG2_YOFF", "shortDesc": "Magnetometer 2 Y-axis offset", "type": "Float", "units": "gauss", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_MAG2_YSCALE", "shortDesc": "Magnetometer 2 Y-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "Coefficient describing linear relationship between\nZ component of magnetometer in body frame axis\nand either current or throttle depending on value of CAL_MAG_COMP_TYP.\nUnit for throttle-based compensation is [G] and\nfor current-based compensation [G/kA]\n\n", "name": "CAL_MAG2_ZCOMP", "shortDesc": "Magnetometer 2 Z Axis throttle compensation", "type": "Float", "volatile": true}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG2_ZODIAG", "shortDesc": "Magnetometer 2 Z-axis off diagonal scale factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG2_ZOFF", "shortDesc": "Magnetometer 2 Z-axis offset", "type": "Float", "units": "gauss", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_MAG2_ZSCALE", "shortDesc": "Magnetometer 2 Z-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the magnetometer this calibration applies to.\n", "name": "CAL_MAG3_ID", "shortDesc": "Magnetometer 3 calibration device ID", "type": "Int32"}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "longDesc": "Setting this parameter changes CAL_MAG3_ROT to \"Custom Euler Angle\"\n", "max": 180.0, "min": -180.0, "name": "CAL_MAG3_PITCH", "shortDesc": "Magnetometer 3 Custom Euler Pitch Angle", "type": "Float", "units": "deg"}, {"category": "System", "default": -1, "group": "Sensor Calibration", "name": "CAL_MAG3_PRIO", "shortDesc": "Magnetometer 3 priority", "type": "Int32", "values": [{"description": "Uninitialized", "value": -1}, {"description": "Disabled", "value": 0}, {"description": "Min", "value": 1}, {"description": "Low", "value": 25}, {"description": "Medium (Default)", "value": 50}, {"description": "High", "value": 75}, {"description": "Max", "value": 100}]}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "longDesc": "Setting this parameter changes CAL_MAG3_ROT to \"Custom Euler Angle\"\n", "max": 180.0, "min": -180.0, "name": "CAL_MAG3_ROLL", "shortDesc": "Magnetometer 3 Custom Euler Roll Angle", "type": "Float", "units": "deg"}, {"category": "System", "default": -1, "group": "Sensor Calibration", "longDesc": "An internal sensor will force a value of -1, so a GCS should only attempt to configure the rotation if the value is greater than or equal to zero.\nSet to \"Custom Euler Angle\" to define the rotation using CAL_MAG3_ROLL, CAL_MAG3_PITCH and CAL_MAG3_YAW.\n\n", "max": 100, "min": -1, "name": "CAL_MAG3_ROT", "shortDesc": "Magnetometer 3 rotation relative to airframe", "type": "Int32", "values": [{"description": "Internal", "value": -1}, {"description": "No rotation", "value": 0}, {"description": "Yaw 45\u00b0", "value": 1}, {"description": "Yaw 90\u00b0", "value": 2}, {"description": "Yaw 135\u00b0", "value": 3}, {"description": "Yaw 180\u00b0", "value": 4}, {"description": "Yaw 225\u00b0", "value": 5}, {"description": "Yaw 270\u00b0", "value": 6}, {"description": "Yaw 315\u00b0", "value": 7}, {"description": "Roll 180\u00b0", "value": 8}, {"description": "Roll 180\u00b0, Yaw 45\u00b0", "value": 9}, {"description": "Roll 180\u00b0, Yaw 90\u00b0", "value": 10}, {"description": "Roll 180\u00b0, Yaw 135\u00b0", "value": 11}, {"description": "Pitch 180\u00b0", "value": 12}, {"description": "Roll 180\u00b0, Yaw 225\u00b0", "value": 13}, {"description": "Roll 180\u00b0, Yaw 270\u00b0", "value": 14}, {"description": "Roll 180\u00b0, Yaw 315\u00b0", "value": 15}, {"description": "Roll 90\u00b0", "value": 16}, {"description": "Roll 90\u00b0, Yaw 45\u00b0", "value": 17}, {"description": "Roll 90\u00b0, Yaw 90\u00b0", "value": 18}, {"description": "Roll 90\u00b0, Yaw 135\u00b0", "value": 19}, {"description": "Roll 270\u00b0", "value": 20}, {"description": "Roll 270\u00b0, Yaw 45\u00b0", "value": 21}, {"description": "Roll 270\u00b0, Yaw 90\u00b0", "value": 22}, {"description": "Roll 270\u00b0, Yaw 135\u00b0", "value": 23}, {"description": "Pitch 90\u00b0", "value": 24}, {"description": "Pitch 270\u00b0", "value": 25}, {"description": "Pitch 180\u00b0, Yaw 90\u00b0", "value": 26}, {"description": "Pitch 180\u00b0, Yaw 270\u00b0", "value": 27}, {"description": "Roll 90\u00b0, Pitch 90\u00b0", "value": 28}, {"description": "Roll 180\u00b0, Pitch 90\u00b0", "value": 29}, {"description": "Roll 270\u00b0, Pitch 90\u00b0", "value": 30}, {"description": "Roll 90\u00b0, Pitch 180\u00b0", "value": 31}, {"description": "Roll 270\u00b0, Pitch 180\u00b0", "value": 32}, {"description": "Roll 90\u00b0, Pitch 270\u00b0", "value": 33}, {"description": "Roll 180\u00b0, Pitch 270\u00b0", "value": 34}, {"description": "Roll 270\u00b0, Pitch 270\u00b0", "value": 35}, {"description": "Roll 90\u00b0, Pitch 180\u00b0, Yaw 90\u00b0", "value": 36}, {"description": "Roll 90\u00b0, Yaw 270\u00b0", "value": 37}, {"description": "Roll 90\u00b0, Pitch 68\u00b0, Yaw 293\u00b0", "value": 38}, {"description": "Pitch 315\u00b0", "value": 39}, {"description": "Roll 90\u00b0, Pitch 315\u00b0", "value": 40}, {"description": "Custom Euler Angle", "value": 100}]}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "Coefficient describing linear relationship between\nX component of magnetometer in body frame axis\nand either current or throttle depending on value of CAL_MAG_COMP_TYP.\nUnit for throttle-based compensation is [G] and\nfor current-based compensation [G/kA]\n\n", "name": "CAL_MAG3_XCOMP", "shortDesc": "Magnetometer 3 X Axis throttle compensation", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG3_XODIAG", "shortDesc": "Magnetometer 3 X-axis off diagonal scale factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG3_XOFF", "shortDesc": "Magnetometer 3 X-axis offset", "type": "Float", "units": "gauss", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_MAG3_XSCALE", "shortDesc": "Magnetometer 3 X-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "longDesc": "Setting this parameter changes CAL_MAG3_ROT to \"Custom Euler Angle\"\n", "max": 180.0, "min": -180.0, "name": "CAL_MAG3_YAW", "shortDesc": "Magnetometer 3 Custom Euler Yaw Angle", "type": "Float", "units": "deg"}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "Coefficient describing linear relationship between\nY component of magnetometer in body frame axis\nand either current or throttle depending on value of CAL_MAG_COMP_TYP.\nUnit for throttle-based compensation is [G] and\nfor current-based compensation [G/kA]\n\n", "name": "CAL_MAG3_YCOMP", "shortDesc": "Magnetometer 3 Y Axis throttle compensation", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG3_YODIAG", "shortDesc": "Magnetometer 3 Y-axis off diagonal scale factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG3_YOFF", "shortDesc": "Magnetometer 3 Y-axis offset", "type": "Float", "units": "gauss", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_MAG3_YSCALE", "shortDesc": "Magnetometer 3 Y-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "Coefficient describing linear relationship between\nZ component of magnetometer in body frame axis\nand either current or throttle depending on value of CAL_MAG_COMP_TYP.\nUnit for throttle-based compensation is [G] and\nfor current-based compensation [G/kA]\n\n", "name": "CAL_MAG3_ZCOMP", "shortDesc": "Magnetometer 3 Z Axis throttle compensation", "type": "Float", "volatile": true}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG3_ZODIAG", "shortDesc": "Magnetometer 3 Z-axis off diagonal scale factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG3_ZOFF", "shortDesc": "Magnetometer 3 Z-axis offset", "type": "Float", "units": "gauss", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_MAG3_ZSCALE", "shortDesc": "Magnetometer 3 Z-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "default": 0, "group": "Sensor Calibration", "name": "CAL_MAG_COMP_TYP", "shortDesc": "Type of magnetometer compensation", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Throttle-based compensation", "value": 1}, {"description": "Current-based compensation (battery_status instance 0)", "value": 2}, {"description": "Current-based compensation (battery_status instance 1)", "value": 3}]}, {"category": "Standard", "default": 0.0, "group": "Sensor Calibration", "longDesc": "Pick the appropriate scaling from the datasheet.\nthis number defines the (linear) conversion from voltage\nto pressure. For the MPXV7002DP this is 1000.\n\nNOTE: If the sensor always registers zero, try switching\nthe static and dynamic tubes.\n", "name": "SENS_DPRES_ANSC", "shortDesc": "Differential pressure sensor analog scaling", "type": "Float", "units": "Pa/V"}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "longDesc": "The offset (zero-reading) of the sensor holding calibration slot 0.\n\nKept as a mirror of CAL_DPRES0_OFF so that ground stations can still detect whether\nairspeed has been calibrated. The firmware applies CAL_DPRESx_OFF, not this value.\n", "name": "SENS_DPRES_OFF", "shortDesc": "Differential pressure sensor offset of the first airspeed sensor", "type": "Float", "units": "Pa", "volatile": true}, {"category": "System", "default": 0, "group": "Sensor Calibration", "longDesc": "Reverse the raw measurements of all differential pressure sensors.\nThis can be enabled if the sensors have static and dynamic ports swapped.\n", "name": "SENS_DPRES_REV", "shortDesc": "Reverse differential pressure sensor readings", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 100.0, "group": "Sensor Calibration", "increment": 0.1, "longDesc": "This parameter defines the maximum distance from ground at which the optical flow sensor operates reliably.\nThe height setpoint will be limited to be no greater than this value when the navigation system\nis completely reliant on optical flow data and the height above ground estimate is valid.\nThe sensor may be usable above this height, but accuracy will progressively degrade.\n", "max": 100.0, "min": 1.0, "name": "SENS_FLOW_MAXHGT", "shortDesc": "Maximum height above ground when reliant on optical flow", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 8.0, "group": "Sensor Calibration", "longDesc": "Magnitude of maximum angular flow rate reliably measurable by the optical flow sensor\n\nOptical flow data will not fused by the estimators if the magnitude of the flow rate exceeds this value and\ncontrol loops will be instructed to limit ground speed such that the flow rate produced by movement over ground\nis less than 50% of this value.\n", "min": 1.0, "name": "SENS_FLOW_MAXR", "shortDesc": "Max angular flow rate measurable by sensor", "type": "Float", "units": "rad/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.08, "group": "Sensor Calibration", "increment": 0.1, "longDesc": "This parameter defines the minimum distance from ground at which the optical flow sensor operates reliably.\nThe sensor may be usable below this height, but accuracy will progressively reduce to loss of focus.\n", "max": 1.0, "min": 0.0, "name": "SENS_FLOW_MINHGT", "shortDesc": "Minimum height above ground when reliant on optical flow", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Sensors", "longDesc": "Model with Pitot\nCAL_AIR_TUBED_MM: Not used, 1.5 mm tubes assumed.\nCAL_AIR_TUBELEN: Length of the tubes connecting the pitot to the sensor.\nModel without Pitot (1.5 mm tubes)\nCAL_AIR_TUBED_MM: Not used, 1.5 mm tubes assumed.\nCAL_AIR_TUBELEN: Length of the tubes connecting the pitot to the sensor.\nTube Pressure Drop\nCAL_AIR_TUBED_MM: Diameter in mm of the pitot and tubes, must have the same diameter.\nCAL_AIR_TUBELEN: Length of the tubes connecting the pitot to the sensor and the static + dynamic port length of the pitot.\n", "name": "CAL_AIR_CMODEL", "shortDesc": "Airspeed sensor compensation model for the SDP3x", "type": "Int32", "values": [{"description": "Model with Pitot", "value": 0}, {"description": "Model without Pitot (1.5 mm tubes)", "value": 1}, {"description": "Tube Pressure Drop", "value": 2}]}, {"category": "Standard", "default": 1.5, "group": "Sensors", "longDesc": "Airspeed sensor tube diameter. Only used for the Tube Pressure Drop Compensation\n", "max": 100.0, "min": 1.5, "name": "CAL_AIR_TUBED_MM", "shortDesc": "Airspeed sensor tube diameter", "type": "Float", "units": "mm"}, {"category": "Standard", "default": 0.2, "group": "Sensors", "longDesc": "See the CAL_AIR_CMODEL explanation on how this parameter should be set.\n", "max": 2.0, "min": 0.01, "name": "CAL_AIR_TUBELEN", "shortDesc": "Airspeed sensor tube length", "type": "Float", "units": "m"}, {"category": "Developer", "default": 63, "group": "Sensors", "longDesc": "Use SENS_MAG_SIDES instead\n", "name": "CAL_MAG_SIDES", "shortDesc": "For legacy QGC support only", "type": "Int32"}, {"bitmask": [{"description": "Sat count (GNSS_REQ_NSATS)", "index": 0}, {"description": "PDOP (GNSS_REQ_PDOP)", "index": 1}, {"description": "EPH (GNSS_REQ_EPH)", "index": 2}, {"description": "EPV (GNSS_REQ_EPV)", "index": 3}, {"description": "Speed accuracy (GNSS_REQ_SACC)", "index": 4}, {"description": "Horizontal position drift (GNSS_REQ_HDRIFT)", "index": 5}, {"description": "Vertical position drift (GNSS_REQ_VDRIFT)", "index": 6}, {"description": "Horizontal speed offset (GNSS_REQ_HDRIFT)", "index": 7}, {"description": "Vertical speed offset (GNSS_REQ_VDRIFT)", "index": 8}, {"description": "Spoofing", "index": 9}, {"description": "GNSS fix type (GNSS_REQ_FIX)", "index": 10}, {"description": "Jamming", "index": 11}, {"description": "Horizontal kinematic consistency (GNSS_REQ_HKIN)", "index": 12}], "category": "Standard", "default": 6143, "group": "Sensors", "longDesc": "Each threshold value is defined by the parameter indicated next to the check. Drift and offset checks only run when the vehicle is on ground and stationary. The spoofing and jamming checks also apply to the receiver providing the GNSS heading.\n", "max": 8191, "min": 0, "name": "GNSS_CHECK", "shortDesc": "Integer bitmask controlling GNSS checks", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "Sensors", "max": 100.0, "min": 0.1, "name": "GNSS_REQ_EPH", "shortDesc": "Required EPH to use GNSS", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "Sensors", "max": 100.0, "min": 0.1, "name": "GNSS_REQ_EPV", "shortDesc": "Required EPV to use GNSS", "type": "Float", "units": "m"}, {"category": "Standard", "default": 3, "group": "Sensors", "longDesc": "Minimum GNSS fix type required for GNSS usage.\n", "name": "GNSS_REQ_FIX", "shortDesc": "Required GNSS fix", "type": "Int32", "values": [{"description": "No fix required", "value": 0}, {"description": "2D fix", "value": 2}, {"description": "3D fix", "value": 3}, {"description": "RTCM code differential", "value": 4}, {"description": "RTK float", "value": 5}, {"description": "RTK fixed", "value": 6}, {"description": "Extrapolated", "value": 8}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "Sensors", "max": 1.0, "min": 0.1, "name": "GNSS_REQ_HDRIFT", "shortDesc": "Maximum horizontal drift speed to use GNSS", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 2.0, "group": "Sensors", "longDesc": "The rate of change of the reported horizontal position, minus the reported horizontal velocity, filtered over 1 s.\n", "max": 20.0, "min": 0.1, "name": "GNSS_REQ_HKIN", "shortDesc": "Maximum horizontal kinematic inconsistency to use GNSS", "type": "Float", "units": "m/s"}, {"category": "Standard", "default": 6, "group": "Sensors", "max": 12, "min": 4, "name": "GNSS_REQ_NSATS", "shortDesc": "Required satellite count to use GNSS", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 1, "default": 2.5, "group": "Sensors", "max": 5.0, "min": 1.5, "name": "GNSS_REQ_PDOP", "shortDesc": "Maximum PDOP to use GNSS", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.5, "group": "Sensors", "longDesc": "EKF2 also feeds GNSS velocity to the EKF-GSF yaw estimator, and trusts the GNSS vertical velocity while the accelerometer clips, only below this speed accuracy, in flight too. With the speed accuracy check disabled in GNSS_CHECK, it does both whatever the speed accuracy.\n", "max": 5.0, "min": 0.5, "name": "GNSS_REQ_SACC", "shortDesc": "Required speed accuracy to use GNSS", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 10.0, "group": "Sensors", "longDesc": "Minimum continuous period without GNSS failure required to mark a healthy GNSS status. It can be reduced to speed up initialization, but it's recommended to keep this unchanged for a vehicle.\n", "min": 0.1, "name": "GNSS_REQ_TIME", "shortDesc": "Required GNSS health time on startup", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.2, "group": "Sensors", "max": 1.5, "min": 0.1, "name": "GNSS_REQ_VDRIFT", "shortDesc": "Maximum vertical drift speed to use GNSS", "type": "Float", "units": "m/s"}, {"category": "Standard", "default": 30.0, "group": "Sensors", "longDesc": "The cutoff frequency for the 2nd order butterworth filter on the primary accelerometer.\nThis only affects the signal sent to the controllers, not the estimators. 0 disables the filter.\n", "max": 1000.0, "min": 0.0, "name": "IMU_ACCEL_CUTOFF", "rebootRequired": true, "shortDesc": "Low pass filter cutoff frequency for accel", "type": "Float", "units": "Hz"}, {"category": "Standard", "decimalPlaces": 1, "default": 20.0, "group": "Sensors", "increment": 0.1, "longDesc": "The cutoff frequency for the 2nd order butterworth filter used on\nthe time derivative of the measured angular velocity, also known as\nthe D-term filter in the rate controller. The D-term uses the derivative of\nthe rate and thus is the most susceptible to noise. Therefore, using\na D-term filter allows to increase IMU_GYRO_CUTOFF, which\nleads to reduced control latency and permits to increase the P gains.\n\nA value of 0 disables the filter.\n", "max": 1000.0, "min": 0.0, "name": "IMU_DGYRO_CUTOFF", "shortDesc": "Cutoff frequency for angular acceleration (D-Term filter)", "type": "Float", "units": "Hz"}, {"category": "Standard", "default": 1, "group": "Sensors", "name": "IMU_GYRO_CAL_EN", "rebootRequired": true, "shortDesc": "IMU gyro auto calibration enable", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 40.0, "group": "Sensors", "increment": 0.1, "longDesc": "The cutoff frequency for the 2nd order butterworth filter on the primary gyro.\nThis only affects the angular velocity sent to the controllers, not the estimators.\nIt applies also to the angular acceleration (D-Term filter), see IMU_DGYRO_CUTOFF.\n\nA value of 0 disables the filter.\n", "max": 1000.0, "min": 0.0, "name": "IMU_GYRO_CUTOFF", "shortDesc": "Low pass filter cutoff frequency for gyro", "type": "Float", "units": "Hz"}, {"category": "Standard", "decimalPlaces": 1, "default": 15.0, "group": "Sensors", "increment": 0.1, "longDesc": "Bandwidth per notch filter when using dynamic notch filtering with ESC RPM.\n", "max": 30.0, "min": 5.0, "name": "IMU_GYRO_DNF_BW", "shortDesc": "IMU gyro ESC notch filter bandwidth", "type": "Float", "units": "Hz"}, {"bitmask": [{"description": "ESC RPM", "index": 0}, {"description": "FFT", "index": 1}], "category": "Standard", "default": 0, "group": "Sensors", "longDesc": "Enable bank of dynamically updating notch filters.\nRequires ESC RPM feedback or onboard FFT (IMU_GYRO_FFT_EN).\n", "max": 3, "min": 0, "name": "IMU_GYRO_DNF_EN", "shortDesc": "IMU gyro dynamic notch filtering", "type": "Int32"}, {"category": "Standard", "default": 3, "group": "Sensors", "longDesc": "ESC RPM number of harmonics (multiples of RPM) for ESC RPM dynamic notch filtering.\n", "max": 7, "min": 1, "name": "IMU_GYRO_DNF_HMC", "shortDesc": "IMU gyro dynamic notch filter harmonics", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 1, "default": 25.0, "group": "Sensors", "increment": 0.1, "longDesc": "Minimum notch filter frequency in Hz.\n", "name": "IMU_GYRO_DNF_MIN", "shortDesc": "IMU gyro dynamic notch filter minimum frequency", "type": "Float", "units": "Hz"}, {"category": "Standard", "default": 0, "group": "Sensors", "name": "IMU_GYRO_FFT_EN", "rebootRequired": true, "shortDesc": "IMU gyro FFT enable", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 512, "group": "Sensors", "name": "IMU_GYRO_FFT_LEN", "rebootRequired": true, "shortDesc": "IMU gyro FFT length", "type": "Int32", "values": [{"description": "256", "value": 256}, {"description": "512", "value": 512}, {"description": "1024", "value": 1024}]}, {"category": "Standard", "default": 150.0, "group": "Sensors", "max": 1000.0, "min": 1.0, "name": "IMU_GYRO_FFT_MAX", "rebootRequired": true, "shortDesc": "IMU gyro FFT maximum frequency", "type": "Float", "units": "Hz"}, {"category": "Standard", "default": 30.0, "group": "Sensors", "max": 1000.0, "min": 1.0, "name": "IMU_GYRO_FFT_MIN", "rebootRequired": true, "shortDesc": "IMU gyro FFT minimum frequency", "type": "Float", "units": "Hz"}, {"category": "Standard", "default": 10.0, "group": "Sensors", "max": 30.0, "min": 1.0, "name": "IMU_GYRO_FFT_SNR", "shortDesc": "IMU gyro FFT SNR", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 20.0, "group": "Sensors", "increment": 0.1, "longDesc": "The frequency width of the stop band for the 2nd order notch filter on the primary gyro.\nSee \"IMU_GYRO_NF0_FRQ\" to activate the filter and to set the notch frequency.\nApplies to both angular velocity and angular acceleration sent to the controllers.\n", "max": 100.0, "min": 0.0, "name": "IMU_GYRO_NF0_BW", "shortDesc": "Notch filter 0 bandwidth for gyro", "type": "Float", "units": "Hz"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "Sensors", "increment": 0.1, "longDesc": "The center frequency for the 2nd order notch filter on the primary gyro.\nThis filter can be enabled to avoid feedback amplification of structural resonances at a specific frequency.\nThis only affects the signal sent to the controllers, not the estimators.\nApplies to both angular velocity and angular acceleration sent to the controllers.\nSee \"IMU_GYRO_NF0_BW\" to set the bandwidth of the filter.\n\nA value of 0 disables the filter.\n", "max": 1000.0, "min": 0.0, "name": "IMU_GYRO_NF0_FRQ", "shortDesc": "Notch filter 0 frequency for gyro", "type": "Float", "units": "Hz"}, {"category": "Standard", "decimalPlaces": 1, "default": 20.0, "group": "Sensors", "increment": 0.1, "longDesc": "The frequency width of the stop band for the 2nd order notch filter on the primary gyro.\nSee \"IMU_GYRO_NF1_FRQ\" to activate the filter and to set the notch frequency.\nApplies to both angular velocity and angular acceleration sent to the controllers.\n", "max": 100.0, "min": 0.0, "name": "IMU_GYRO_NF1_BW", "shortDesc": "Notch filter 1 bandwidth for gyro", "type": "Float", "units": "Hz"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "Sensors", "increment": 0.1, "longDesc": "The center frequency for the 2nd order notch filter on the primary gyro.\nThis filter can be enabled to avoid feedback amplification of structural resonances at a specific frequency.\nThis only affects the signal sent to the controllers, not the estimators.\nApplies to both angular velocity and angular acceleration sent to the controllers.\nSee \"IMU_GYRO_NF1_BW\" to set the bandwidth of the filter.\n\nA value of 0 disables the filter.\n", "max": 1000.0, "min": 0.0, "name": "IMU_GYRO_NF1_FRQ", "shortDesc": "Notch filter 1 frequency for gyro", "type": "Float", "units": "Hz"}, {"category": "Standard", "default": 400, "group": "Sensors", "longDesc": "The maximum rate the gyro control data (vehicle_angular_velocity) will be\nallowed to publish at. This is the loop rate for the rate controller and outputs.\n\nNote: sensor data is always read and filtered at the full raw rate (eg commonly 8 kHz) regardless of this setting.\n", "max": 2000, "min": 100, "name": "IMU_GYRO_RATEMAX", "rebootRequired": true, "shortDesc": "Gyro control data maximum publication rate (inner loop rate)", "type": "Int32", "units": "Hz", "values": [{"description": "100 Hz", "value": 100}, {"description": "250 Hz", "value": 250}, {"description": "400 Hz", "value": 400}, {"description": "800 Hz", "value": 800}, {"description": "1000 Hz", "value": 1000}, {"description": "2000 Hz", "value": 2000}]}, {"category": "Standard", "default": 200, "group": "Sensors", "longDesc": "The rate at which raw IMU data is integrated to produce delta angles and delta velocities.\nRecommended to set this to a multiple of the estimator update period (currently 10 ms for ekf2).\n", "max": 1000, "min": 100, "name": "IMU_INTEG_RATE", "rebootRequired": true, "shortDesc": "IMU integration rate", "type": "Int32", "units": "Hz", "values": [{"description": "100 Hz", "value": 100}, {"description": "200 Hz", "value": 200}, {"description": "250 Hz", "value": 250}, {"description": "400 Hz", "value": 400}]}, {"category": "Standard", "default": 1013.25, "group": "Sensors", "max": 1500.0, "min": 500.0, "name": "SENS_BARO_QNH", "shortDesc": "QNH for barometer", "type": "Float", "units": "hPa"}, {"category": "Standard", "default": 20.0, "group": "Sensors", "longDesc": "Barometric air data maximum publication rate. This is an upper bound,\nactual barometric data rate is still dependent on the sensor.\n", "max": 200.0, "min": 1.0, "name": "SENS_BARO_RATE", "shortDesc": "Baro max rate", "type": "Float", "units": "Hz"}, {"category": "System", "default": 1, "group": "Sensors", "longDesc": "Automatically calibrate barometer based on the GNSS height\n", "name": "SENS_BAR_AUTOCAL", "shortDesc": "Barometer auto calibration", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Sensors", "longDesc": "This parameter defines the rotation of the FMU board relative to the platform.\n", "max": 40, "min": -1, "name": "SENS_BOARD_ROT", "rebootRequired": true, "shortDesc": "Board rotation", "type": "Int32", "values": [{"description": "No rotation", "value": 0}, {"description": "Yaw 45\u00b0", "value": 1}, {"description": "Yaw 90\u00b0", "value": 2}, {"description": "Yaw 135\u00b0", "value": 3}, {"description": "Yaw 180\u00b0", "value": 4}, {"description": "Yaw 225\u00b0", "value": 5}, {"description": "Yaw 270\u00b0", "value": 6}, {"description": "Yaw 315\u00b0", "value": 7}, {"description": "Roll 180\u00b0", "value": 8}, {"description": "Roll 180\u00b0, Yaw 45\u00b0", "value": 9}, {"description": "Roll 180\u00b0, Yaw 90\u00b0", "value": 10}, {"description": "Roll 180\u00b0, Yaw 135\u00b0", "value": 11}, {"description": "Pitch 180\u00b0", "value": 12}, {"description": "Roll 180\u00b0, Yaw 225\u00b0", "value": 13}, {"description": "Roll 180\u00b0, Yaw 270\u00b0", "value": 14}, {"description": "Roll 180\u00b0, Yaw 315\u00b0", "value": 15}, {"description": "Roll 90\u00b0", "value": 16}, {"description": "Roll 90\u00b0, Yaw 45\u00b0", "value": 17}, {"description": "Roll 90\u00b0, Yaw 90\u00b0", "value": 18}, {"description": "Roll 90\u00b0, Yaw 135\u00b0", "value": 19}, {"description": "Roll 270\u00b0", "value": 20}, {"description": "Roll 270\u00b0, Yaw 45\u00b0", "value": 21}, {"description": "Roll 270\u00b0, Yaw 90\u00b0", "value": 22}, {"description": "Roll 270\u00b0, Yaw 135\u00b0", "value": 23}, {"description": "Pitch 90\u00b0", "value": 24}, {"description": "Pitch 270\u00b0", "value": 25}, {"description": "Pitch 180\u00b0, Yaw 90\u00b0", "value": 26}, {"description": "Pitch 180\u00b0, Yaw 270\u00b0", "value": 27}, {"description": "Roll 90\u00b0, Pitch 90\u00b0", "value": 28}, {"description": "Roll 180\u00b0, Pitch 90\u00b0", "value": 29}, {"description": "Roll 270\u00b0, Pitch 90\u00b0", "value": 30}, {"description": "Roll 90\u00b0, Pitch 180\u00b0", "value": 31}, {"description": "Roll 270\u00b0, Pitch 180\u00b0", "value": 32}, {"description": "Roll 90\u00b0, Pitch 270\u00b0", "value": 33}, {"description": "Roll 180\u00b0, Pitch 270\u00b0", "value": 34}, {"description": "Roll 270\u00b0, Pitch 270\u00b0", "value": 35}, {"description": "Roll 90\u00b0, Pitch 180\u00b0, Yaw 90\u00b0", "value": 36}, {"description": "Roll 90\u00b0, Yaw 270\u00b0", "value": 37}, {"description": "Roll 90\u00b0, Pitch 68\u00b0, Yaw 293\u00b0", "value": 38}, {"description": "Pitch 315\u00b0", "value": 39}, {"description": "Roll 90\u00b0, Pitch 315\u00b0", "value": 40}]}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "Sensors", "longDesc": "Rotation from flight controller board to vehicle body frame.\nThis parameter gets set during the \"level horizon\" calibration or can be\nset manually.\n", "max": 45.0, "min": -45.0, "name": "SENS_BOARD_X_OFF", "shortDesc": "Board rotation X (roll) offset", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "Sensors", "longDesc": "Rotation from flight controller board to vehicle body frame.\nThis parameter gets set during the \"level horizon\" calibration or can be\nset manually.\n", "max": 45.0, "min": -45.0, "name": "SENS_BOARD_Y_OFF", "shortDesc": "Board rotation Y (pitch) offset", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "Sensors", "longDesc": "Rotation from flight controller board to vehicle body frame.\nHas to be set manually (not set by any calibration).\n", "max": 45.0, "min": -45.0, "name": "SENS_BOARD_Z_OFF", "shortDesc": "Board rotation Z (yaw) offset", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 0, "group": "Sensors", "max": 1, "min": 0, "name": "SENS_EN_AGPSIM", "rebootRequired": true, "shortDesc": "Simulate Aux Global Position (AGP)", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Sensors", "max": 1, "min": 0, "name": "SENS_EN_ARSPDSIM", "rebootRequired": true, "shortDesc": "Enable simulated airspeed sensor instance", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Sensors", "max": 1, "min": 0, "name": "SENS_EN_BAROSIM", "rebootRequired": true, "shortDesc": "Enable simulated barometer sensor instance", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Sensors", "max": 1, "min": 0, "name": "SENS_EN_GPSSIM", "rebootRequired": true, "shortDesc": "Enable simulated GPS instance", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Sensors", "max": 1, "min": 0, "name": "SENS_EN_MAGSIM", "rebootRequired": true, "shortDesc": "Enable simulated magnetometer sensor instance", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "System", "default": -1, "group": "Sensors", "name": "SENS_EN_THERMAL", "shortDesc": "Thermal control of sensor temperature", "type": "Int32", "values": [{"description": "Thermal control unavailable", "value": -1}, {"description": "Thermal control off", "value": 0}, {"description": "Thermal control enabled", "value": 1}]}, {"category": "System", "default": 1, "group": "Sensors", "longDesc": "Probe for optional external I2C devices.\n", "name": "SENS_EXT_I2C_PRB", "shortDesc": "External I2C probe", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 70.0, "group": "Sensors", "longDesc": "Optical flow data maximum publication rate. This is an upper bound,\nactual optical flow data rate is still dependent on the sensor.\n", "max": 200.0, "min": 1.0, "name": "SENS_FLOW_RATE", "rebootRequired": true, "shortDesc": "Optical flow max rate", "type": "Float", "units": "Hz"}, {"category": "Standard", "default": 0, "group": "Sensors", "longDesc": "This parameter defines the yaw rotation of the optical flow relative to the vehicle body frame.\nZero rotation is defined as X on flow board pointing towards front of vehicle.\n", "name": "SENS_FLOW_ROT", "shortDesc": "Optical flow rotation", "type": "Int32", "values": [{"description": "No rotation", "value": 0}, {"description": "Yaw 45\u00b0", "value": 1}, {"description": "Yaw 90\u00b0", "value": 2}, {"description": "Yaw 135\u00b0", "value": 3}, {"description": "Yaw 180\u00b0", "value": 4}, {"description": "Yaw 225\u00b0", "value": 5}, {"description": "Yaw 270\u00b0", "value": 6}, {"description": "Yaw 315\u00b0", "value": 7}]}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Sensors", "max": 1.5, "min": 0.5, "name": "SENS_FLOW_SCALE", "shortDesc": "Optical flow scale factor", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Sensors", "longDesc": "Forward axis relative to vehicle centre of gravity, of the receiver's second antenna.\nUsed when SENS_GNSS0_HDG is Dual antenna.\n\n", "name": "SENS_GNSS0_AUXX", "shortDesc": "GNSS 0 auxiliary antenna X position", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Sensors", "longDesc": "Right axis relative to vehicle centre of gravity, of the receiver's second antenna.\nUsed when SENS_GNSS0_HDG is Dual antenna.\n\n", "name": "SENS_GNSS0_AUXY", "shortDesc": "GNSS 0 auxiliary antenna Y position", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Sensors", "longDesc": "Down axis relative to vehicle centre of gravity, of the receiver's second antenna.\nUsed when SENS_GNSS0_HDG is Dual antenna.\n\n", "name": "SENS_GNSS0_AUXZ", "shortDesc": "GNSS 0 auxiliary antenna Z position", "type": "Float", "units": "m"}, {"category": "Standard", "default": 110, "group": "Sensors", "longDesc": "GPS measurement delay relative to IMU measurements.\nMatched to physical GPS receiver via SENS_GNSS0_ID.\nOnly applied when the GPS driver does not provide its own\ntimestamp_sample correction.\n\n", "max": 300, "min": 0, "name": "SENS_GNSS0_DELAY", "shortDesc": "GPS 0 measurement delay", "type": "Int32", "units": "ms"}, {"category": "Standard", "default": 0, "group": "Sensors", "longDesc": "How the receiver in slot 0 (matched via SENS_GNSS0_ID) measures its dual antenna heading.\nThe heading is the bearing of the baseline between two antennas, and is only used when the\nbaseline length the receiver reports is within 20% of the configured one.\nMoving base rover: this receiver is the rover of a moving base pair, the moving base is the\nreceiver in the other slot. The baseline runs from the moving base's antenna to this\nreceiver's antenna (SENS_GNSSn_OFFX/Y/Z of both slots).\nDual antenna: this receiver has two antennas. The baseline runs from its main antenna\n(SENS_GNSS0_OFFX/Y/Z) to its auxiliary antenna (SENS_GNSS0_AUXX/Y/Z).\n\n", "name": "SENS_GNSS0_HDG", "shortDesc": "GNSS 0 heading setup", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Moving base rover", "value": 1}, {"description": "Dual antenna", "value": 2}]}, {"category": "System", "default": 0, "group": "Sensors", "longDesc": "Device ID of the GPS receiver for antenna offset slot 0.\nSet to 0 to disable this slot. When all slots are 0, offsets are\nmatched by uORB instance index (only reliable for serial GPS).\n\n", "name": "SENS_GNSS0_ID", "shortDesc": "GPS 0 device ID", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Sensors", "longDesc": "Forward axis relative to vehicle centre of gravity.\nMatched to physical GPS receiver via SENS_GNSS0_ID.\n\n", "name": "SENS_GNSS0_OFFX", "shortDesc": "GPS 0 antenna X position", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Sensors", "longDesc": "Right axis relative to vehicle centre of gravity.\nMatched to physical GPS receiver via SENS_GNSS0_ID.\n\n", "name": "SENS_GNSS0_OFFY", "shortDesc": "GPS 0 antenna Y position", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Sensors", "longDesc": "Down axis relative to vehicle centre of gravity.\nMatched to physical GPS receiver via SENS_GNSS0_ID.\n\n", "name": "SENS_GNSS0_OFFZ", "shortDesc": "GPS 0 antenna Z position", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Sensors", "longDesc": "Forward axis relative to vehicle centre of gravity, of the receiver's second antenna.\nUsed when SENS_GNSS1_HDG is Dual antenna.\n\n", "name": "SENS_GNSS1_AUXX", "shortDesc": "GNSS 1 auxiliary antenna X position", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Sensors", "longDesc": "Right axis relative to vehicle centre of gravity, of the receiver's second antenna.\nUsed when SENS_GNSS1_HDG is Dual antenna.\n\n", "name": "SENS_GNSS1_AUXY", "shortDesc": "GNSS 1 auxiliary antenna Y position", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Sensors", "longDesc": "Down axis relative to vehicle centre of gravity, of the receiver's second antenna.\nUsed when SENS_GNSS1_HDG is Dual antenna.\n\n", "name": "SENS_GNSS1_AUXZ", "shortDesc": "GNSS 1 auxiliary antenna Z position", "type": "Float", "units": "m"}, {"category": "Standard", "default": 110, "group": "Sensors", "longDesc": "GPS measurement delay relative to IMU measurements.\nMatched to physical GPS receiver via SENS_GNSS1_ID.\nOnly applied when the GPS driver does not provide its own\ntimestamp_sample correction.\n\n", "max": 300, "min": 0, "name": "SENS_GNSS1_DELAY", "shortDesc": "GPS 1 measurement delay", "type": "Int32", "units": "ms"}, {"category": "Standard", "default": 0, "group": "Sensors", "longDesc": "How the receiver in slot 1 (matched via SENS_GNSS1_ID) measures its dual antenna heading.\nThe heading is the bearing of the baseline between two antennas, and is only used when the\nbaseline length the receiver reports is within 20% of the configured one.\nMoving base rover: this receiver is the rover of a moving base pair, the moving base is the\nreceiver in the other slot. The baseline runs from the moving base's antenna to this\nreceiver's antenna (SENS_GNSSn_OFFX/Y/Z of both slots).\nDual antenna: this receiver has two antennas. The baseline runs from its main antenna\n(SENS_GNSS1_OFFX/Y/Z) to its auxiliary antenna (SENS_GNSS1_AUXX/Y/Z).\n\n", "name": "SENS_GNSS1_HDG", "shortDesc": "GNSS 1 heading setup", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Moving base rover", "value": 1}, {"description": "Dual antenna", "value": 2}]}, {"category": "System", "default": 0, "group": "Sensors", "longDesc": "Device ID of the GPS receiver for antenna offset slot 1.\nSet to 0 to disable this slot. When all slots are 0, offsets are\nmatched by uORB instance index (only reliable for serial GPS).\n\n", "name": "SENS_GNSS1_ID", "shortDesc": "GPS 1 device ID", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Sensors", "longDesc": "Forward axis relative to vehicle centre of gravity.\nMatched to physical GPS receiver via SENS_GNSS1_ID.\n\n", "name": "SENS_GNSS1_OFFX", "shortDesc": "GPS 1 antenna X position", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Sensors", "longDesc": "Right axis relative to vehicle centre of gravity.\nMatched to physical GPS receiver via SENS_GNSS1_ID.\n\n", "name": "SENS_GNSS1_OFFY", "shortDesc": "GPS 1 antenna Y position", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Sensors", "longDesc": "Down axis relative to vehicle centre of gravity.\nMatched to physical GPS receiver via SENS_GNSS1_ID.\n\n", "name": "SENS_GNSS1_OFFZ", "shortDesc": "GPS 1 antenna Z position", "type": "Float", "units": "m"}, {"category": "Standard", "default": -1, "group": "Sensors", "longDesc": "The primary receiver is used while it passes the strict checks (GNSS_REQ_*), and while disarmed whenever it publishes. In flight, the other receiver is used when the primary fails its checks (GNSS_CHECK) or stops publishing for 2 s, and then for the rest of the flight unless it fails too. The other receiver is also used once it has been better through a hold: when the primary failed the strict checks while the other passed them, or when the primary was usable for a clearly smaller share of the last 10 s or so (availability lower by 0.2). The primary is used again once it has been better through the hold. The hold is 10 s and doubles with every such switch in a flight, so the first return takes 20 s. With Auto, the moving base of a moving base pair (SENS_GNSSn_HDG) is the primary. Without a primary, a receiver that passes the strict checks is preferred, and among those one with an RTK fixed solution. To make a DroneCAN receiver the primary, set its node ID (2 to 127). GPS_RAW_INT reports the primary receiver, or the first receiver to publish if there is no primary.\n", "max": 127, "min": -1, "name": "SENS_GNSS_PRIME", "shortDesc": "Multi GPS primary instance", "type": "Int32"}, {"category": "System", "default": 1, "group": "Sensors", "longDesc": "Automatically initialize IMU (accel/gyro) calibration from bias estimates if available.\n", "name": "SENS_IMU_AUTOCAL", "shortDesc": "IMU auto calibration", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "System", "default": 1, "group": "Sensors", "longDesc": "Notify the user if the IMU is clipping\n", "name": "SENS_IMU_CLPNOTI", "shortDesc": "IMU notify clipping", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "System", "default": 1, "group": "Sensors", "name": "SENS_IMU_MODE", "rebootRequired": true, "shortDesc": "Sensors hub IMU mode", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Publish primary IMU selection", "value": 1}]}, {"category": "System", "default": 0, "group": "Sensors", "longDesc": "Automatically initialize magnetometer calibration from bias estimate if available. The estimate only captures hard-iron offsets, so a full calibration is still recommended. Mainly intended for remote nodes (e.g. CAN GPS units) that cannot be calibrated from a ground station.\n", "name": "SENS_MAG_AUTOCAL", "shortDesc": "Magnetometer auto calibration", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 1, "group": "Sensors", "longDesc": "During calibration attempt to automatically determine the rotation of external magnetometers.\n", "name": "SENS_MAG_AUTOROT", "shortDesc": "Automatically set external rotations", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "System", "default": 1, "group": "Sensors", "name": "SENS_MAG_MODE", "rebootRequired": true, "shortDesc": "Sensors hub mag mode", "type": "Int32", "values": [{"description": "Publish all magnetometers", "value": 0}, {"description": "Publish primary magnetometer", "value": 1}]}, {"category": "Standard", "default": 15.0, "group": "Sensors", "longDesc": "Magnetometer data maximum publication rate. This is an upper bound,\nactual magnetometer data rate is still dependent on the sensor.\n", "max": 200.0, "min": 1.0, "name": "SENS_MAG_RATE", "rebootRequired": true, "shortDesc": "Magnetometer max rate", "type": "Float", "units": "Hz"}, {"category": "Standard", "default": 63, "group": "Sensors", "longDesc": "If set to two side calibration, only the offsets are estimated, the scale\ncalibration is left unchanged. Thus an initial six side calibration is\nrecommended.\n\nBits:\nORIENTATION_TAIL_DOWN = 1\nORIENTATION_NOSE_DOWN = 2\nORIENTATION_LEFT = 4\nORIENTATION_RIGHT = 8\nORIENTATION_UPSIDE_DOWN = 16\nORIENTATION_RIGHTSIDE_UP = 32\n", "max": 63, "min": 34, "name": "SENS_MAG_SIDES", "shortDesc": "Bitfield selecting mag sides for calibration", "type": "Int32", "values": [{"description": "Two side calibration", "value": 34}, {"description": "Three side calibration", "value": 38}, {"description": "Six side calibration", "value": 63}]}, {"category": "Standard", "default": 1, "group": "Septentrio", "longDesc": "By default, the receiver is automatically configured. Sometimes it may be used for multiple purposes.\nIf the offered parameters aren't sufficient, this parameter can be disabled to have full control of the receiver configuration.\nA good way to use this is to enable automatic configuration, let the receiver be configured, and then disable it to make manual adjustments.\n\n", "name": "SEP_AUTO_CONFIG", "rebootRequired": true, "shortDesc": "Toggle automatic receiver configuration", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"bitmask": [{"description": "GPS", "index": 0}, {"description": "GLONASS", "index": 1}, {"description": "Galileo", "index": 2}, {"description": "SBAS", "index": 3}, {"description": "BeiDou", "index": 4}], "category": "Standard", "default": 0, "group": "Septentrio", "longDesc": "Choice of which constellations the receiver should use for PVT computation.\n\nWhen this is 0, the constellation usage isn't changed.\n\n", "max": 63, "min": 0, "name": "SEP_CONST_USAGE", "rebootRequired": true, "shortDesc": "Usage of different constellations", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "Septentrio", "longDesc": "Log raw communication between the driver and connected receivers.\nFor example, \"To receiver\" will log all commands and corrections sent by the driver to the receiver.\n\n", "max": 3, "min": 0, "name": "SEP_DUMP_COMM", "shortDesc": "Log GPS communication data", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "From receiver", "value": 1}, {"description": "To receiver", "value": 2}, {"description": "Both", "value": 3}]}, {"category": "Standard", "default": 0, "group": "Septentrio", "longDesc": "Setup and expected use of the hardware.\n\n- Default: Use two receivers as completely separate instances.\n- Moving base: Use two receivers in a rover & moving base setup for heading.\n\n", "max": 1, "min": 0, "name": "SEP_HARDW_SETUP", "rebootRequired": true, "shortDesc": "Setup and expected use of the hardware", "type": "Int32", "values": [{"description": "Default", "value": 0}, {"description": "Moving base", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Septentrio", "longDesc": "When the receiver is already set up to log data, this decides whether extra logged data should be added or overwrite existing data.\n\n", "name": "SEP_LOG_FORCE", "rebootRequired": true, "shortDesc": "Whether to overwrite or add to existing logging", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Septentrio", "longDesc": "Select the frequency at which the connected receiver should log data to its internal storage.\n\n", "max": 10, "min": 0, "name": "SEP_LOG_HZ", "rebootRequired": true, "shortDesc": "Logging frequency for the receiver", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "0.1 Hz", "value": 1}, {"description": "0.2 Hz", "value": 2}, {"description": "0.5 Hz", "value": 3}, {"description": "1 Hz", "value": 4}, {"description": "2 Hz", "value": 5}, {"description": "5 Hz", "value": 6}, {"description": "10 Hz", "value": 7}, {"description": "20 Hz", "value": 8}, {"description": "25 Hz", "value": 9}, {"description": "50 Hz", "value": 10}]}, {"category": "Standard", "default": 2, "group": "Septentrio", "longDesc": "Select the level of detail that needs to be logged by the receiver.\n\n", "max": 3, "min": 0, "name": "SEP_LOG_LEVEL", "rebootRequired": true, "shortDesc": "Logging level for the receiver", "type": "Int32", "values": [{"description": "Lite", "value": 0}, {"description": "Basic", "value": 1}, {"description": "Default", "value": 2}, {"description": "Full", "value": 3}]}, {"category": "Standard", "default": 1, "group": "Septentrio", "longDesc": "The output frequency of the main SBF blocks needed for PVT information.\n\n", "max": 3, "min": 0, "name": "SEP_OUTP_HZ", "rebootRequired": true, "shortDesc": "Output frequency of main SBF blocks", "type": "Int32", "values": [{"description": "5 Hz", "value": 0}, {"description": "10 Hz", "value": 1}, {"description": "20 Hz", "value": 2}, {"description": "25 Hz", "value": 3}]}, {"category": "Standard", "default": 0, "group": "Septentrio", "longDesc": "Enable publication of satellite info (ORB_ID(satellite_info)) if possible.\n\n", "name": "SEP_SAT_INFO", "rebootRequired": true, "shortDesc": "Enable sat info", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 2, "group": "Septentrio", "longDesc": "The stream the autopilot sets up on the receiver to output the logging data.\n\nSet this to another value if the default stream is already used for another purpose.\n\n", "max": 10, "min": 1, "name": "SEP_STREAM_LOG", "rebootRequired": true, "shortDesc": "Logging stream used during automatic configuration", "type": "Int32"}, {"category": "Standard", "default": 1, "group": "Septentrio", "longDesc": "The stream the autopilot sets up on the receiver to output the main data.\n\nSet this to another value if the default stream is already used for another purpose.\n\n", "max": 10, "min": 1, "name": "SEP_STREAM_MAIN", "rebootRequired": true, "shortDesc": "Main stream used during automatic configuration", "type": "Int32"}, {"category": "Standard", "default": 1, "group": "Simulation In Hardware", "name": "SIH_DISTSNSR_EN", "shortDesc": "Enable the simulated downward facing distance sensor", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 4, "default": 100.0, "group": "Simulation In Hardware", "increment": 0.01, "longDesc": "The signal quality degrades over the last 20% of the range. Beyond the maximum range\nthe sensor reports a saturated reading with a zero signal quality.\n", "max": 1000.0, "min": 0.0, "name": "SIH_DISTSNSR_MAX", "shortDesc": "distance sensor maximum range", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 4, "default": 0.0, "group": "Simulation In Hardware", "increment": 0.01, "longDesc": "Readings closer than this saturate at the minimum range\nand are reported with a zero signal quality.\n", "max": 10.0, "min": 0.0, "name": "SIH_DISTSNSR_MIN", "shortDesc": "distance sensor minimum range", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.01, "group": "Simulation In Hardware", "longDesc": "Gaussian noise added to the simulated distance sensor measurements.\nSet to 0 to disable noise.\n", "max": 10.0, "min": 0.0, "name": "SIH_DISTSNSR_NOI", "shortDesc": "Distance sensor measurement noise standard deviation", "type": "Float", "units": "m"}, {"category": "Standard", "default": -1.0, "group": "Simulation In Hardware", "longDesc": "Set SIH_DISTSNSR_EN to 0 to disable the distance sensor.\n", "name": "SIH_DISTSNSR_OVR", "shortDesc": "if >= 0 the distance sensor measures will be overridden by this value", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Simulation In Hardware", "min": 0.0, "name": "SIH_F_CP0", "shortDesc": "Forward thruster static power coefficient", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Simulation In Hardware", "longDesc": "CP(J) = CP0 + CP1*J + CP2*J^2\n", "name": "SIH_F_CP1", "shortDesc": "Forward thruster power coefficient 1", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Simulation In Hardware", "longDesc": "CP(J) = CP0 + CP1*J + CP2*J^2\n", "max": 0.0, "name": "SIH_F_CP2", "shortDesc": "Forward thruster power coefficient 2", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Simulation In Hardware", "min": 0.0, "name": "SIH_F_CT0", "shortDesc": "Forward thruster static thrust coefficient", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Simulation In Hardware", "longDesc": "CT(J) = CT0 + CT1*J + CT2*J^2\n", "name": "SIH_F_CT1", "shortDesc": "Forward thruster thrust coefficient 1", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Simulation In Hardware", "longDesc": "CT(J) = CT0 + CT1*J + CT2*J^2\n", "max": 0.0, "name": "SIH_F_CT2", "shortDesc": "Forward thruster thrust coefficient 2", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.1, "group": "Simulation In Hardware", "min": 0.1, "name": "SIH_F_DIA_INCH", "shortDesc": "Forward thruster propeller diameter in inches", "type": "Float"}, {"category": "Standard", "decimalPlaces": 4, "default": 0.0165, "group": "Simulation In Hardware", "longDesc": "This is used for the Fixed-Wing, Tailsitter, or pusher of the Standard VTOL\nif SIH_F_CP0 <= 0.\nIf SIH_F_CP0 > 0, propeller model with advance ratio J is used\nand this parameter value is overridden at simulation startup.\n", "min": 0.0, "name": "SIH_F_Q_MAX", "shortDesc": "Forward thruster max torque (Nm)", "type": "Float", "units": "Nm"}, {"category": "Standard", "decimalPlaces": 1, "default": 6000.0, "group": "Simulation In Hardware", "min": 0.1, "name": "SIH_F_RPM_MAX", "shortDesc": "Forward thruster max RPM", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 2.0, "group": "Simulation In Hardware", "longDesc": "This is used for the Fixed-Wing, Tailsitter, or pusher of the Standard VTOL\nif SIH_F_CT0 <= 0.\nIf SIH_F_CT0 > 0, propeller model with advance ratio J is used\nand this parameter value is overridden at simulation startup.\n", "min": 0.0, "name": "SIH_F_T_MAX", "shortDesc": "Forward thruster max thrust (N)", "type": "Float", "units": "N"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.025, "group": "Simulation In Hardware", "increment": 0.005, "longDesc": "The inertia is a 3 by 3 symmetric matrix.\nIt represents the difficulty of the vehicle to modify its angular rate.\n", "min": 0.0, "name": "SIH_IXX", "shortDesc": "Vehicle inertia about X axis", "type": "Float", "units": "kg m^2"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Simulation In Hardware", "increment": 0.005, "longDesc": "The inertia is a 3 by 3 symmetric matrix.\nThis value can be set to 0 for a quad symmetric about its center of mass.\n", "name": "SIH_IXY", "shortDesc": "Vehicle cross term inertia xy", "type": "Float", "units": "kg m^2"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Simulation In Hardware", "increment": 0.005, "longDesc": "The inertia is a 3 by 3 symmetric matrix.\nThis value can be set to 0 for a quad symmetric about its center of mass.\n", "name": "SIH_IXZ", "shortDesc": "Vehicle cross term inertia xz", "type": "Float", "units": "kg m^2"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.025, "group": "Simulation In Hardware", "increment": 0.005, "longDesc": "The inertia is a 3 by 3 symmetric matrix.\nIt represents the difficulty of the vehicle to modify its angular rate.\n", "min": 0.0, "name": "SIH_IYY", "shortDesc": "Vehicle inertia about Y axis", "type": "Float", "units": "kg m^2"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Simulation In Hardware", "increment": 0.005, "longDesc": "The inertia is a 3 by 3 symmetric matrix.\nThis value can be set to 0 for a quad symmetric about its center of mass.\n", "name": "SIH_IYZ", "shortDesc": "Vehicle cross term inertia yz", "type": "Float", "units": "kg m^2"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.03, "group": "Simulation In Hardware", "increment": 0.005, "longDesc": "The inertia is a 3 by 3 symmetric matrix.\nIt represents the difficulty of the vehicle to modify its angular rate.\n", "min": 0.0, "name": "SIH_IZZ", "shortDesc": "Vehicle inertia about Z axis", "type": "Float", "units": "kg m^2"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Simulation In Hardware", "increment": 0.05, "longDesc": "Physical coefficient representing the friction with air particles.\nThe greater this value, the slower the quad will move.\n\nDrag force function of velocity: D=-KDV*V.\nThe maximum freefall velocity can be computed as V=10*MASS/KDV [m/s]\n", "min": 0.0, "name": "SIH_KDV", "shortDesc": "First order drag coefficient", "type": "Float", "units": "N/(m/s)"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.025, "group": "Simulation In Hardware", "increment": 0.005, "longDesc": "Physical coefficient representing the friction with air particles during rotations.\nThe greater this value, the slower the quad will rotate.\n\nAerodynamic moment function of body rate: Ma=-KDW*W_B.\nThis value can be set to 0 if unknown.\n", "min": 0.0, "name": "SIH_KDW", "shortDesc": "First order angular damper coefficient", "type": "Float", "units": "Nm/(rad/s)"}, {"category": "Standard", "decimalPlaces": 2, "default": 489.4, "group": "Simulation In Hardware", "increment": 0.01, "longDesc": "This value represents the Above Mean Sea Level (AMSL) altitude where the simulation begins.\n\nIf using FlightGear as a visual animation,\nthis value can be tweaked such that the vehicle lies on the ground at takeoff.\n\nLAT0, LON0, H0, MU_X, MU_Y, and MU_Z should ideally be consistent among each others\nto represent a physical ground location on Earth.\n", "max": 8848.0, "min": -420.0, "name": "SIH_LOC_H0", "shortDesc": "Initial AMSL ground altitude", "type": "Float", "units": "m"}, {"category": "Standard", "default": 47.397742, "group": "Simulation In Hardware", "longDesc": "This value represents the North-South location on Earth where the simulation begins.\n\nLAT0, LON0, H0, MU_X, MU_Y, and MU_Z should ideally be consistent among each others\nto represent a physical ground location on Earth.\n", "max": 90.0, "min": -90.0, "name": "SIH_LOC_LAT0", "shortDesc": "Initial geodetic latitude", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 8.545594, "group": "Simulation In Hardware", "longDesc": "This value represents the East-West location on Earth where the simulation begins.\n\nLAT0, LON0, H0, MU_X, MU_Y, and MU_Z should ideally be consistent among each others\nto represent a physical ground location on Earth.\n", "max": 180.0, "min": -180.0, "name": "SIH_LOC_LON0", "shortDesc": "Initial geodetic longitude", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Simulation In Hardware", "increment": 0.01, "longDesc": "This value represents the initial heading (yaw) of the simulated vehicle at the start of the simulation.\n", "max": 3.14159, "min": -3.14159, "name": "SIH_LOC_YAW0", "shortDesc": "Initial heading (yaw) of the simulated vehicle", "type": "Float", "units": "rad"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.2, "group": "Simulation In Hardware", "increment": 0.05, "longDesc": "This is the arm length generating the pitching moment\n\nThis value can be measured with a ruler.\nThis corresponds to half the distance between the front and rear motors.\n", "min": 0.0, "name": "SIH_L_PITCH", "shortDesc": "Pitch arm length", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.2, "group": "Simulation In Hardware", "increment": 0.05, "longDesc": "This is the arm length generating the rolling moment\n\nThis value can be measured with a ruler.\nThis corresponds to half the distance between the left and right motors.\n", "min": 0.0, "name": "SIH_L_ROLL", "shortDesc": "Roll arm length", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Simulation In Hardware", "increment": 0.1, "longDesc": "This value can be measured by weighting the quad on a scale.\n", "min": 0.0, "name": "SIH_MASS", "shortDesc": "Vehicle mass", "type": "Float", "units": "kg"}, {"category": "Standard", "default": 0, "group": "Simulation In Hardware", "longDesc": "The simulated sensor reports the integrated flow only. The flow module completes the\nsample with the vehicle gyro and the downward facing distance sensor, which therefore\nhas to be enabled as well (SIH_DISTSNSR_EN) for the flow to be usable by the estimator.\n", "name": "SIH_OF_EN", "shortDesc": "Enable the simulated optical flow sensor", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 30.0, "group": "Simulation In Hardware", "longDesc": "Above this distance to the ground the simulated sensor cannot track the ground image\nanymore and reports a zero quality.\n", "min": 1.0, "name": "SIH_OF_H_MAX", "shortDesc": "Optical flow maximum ground distance", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "Simulation In Hardware", "longDesc": "Gaussian noise added to the simulated flow rate.\nSet to 0 to disable noise.\n", "max": 5.0, "min": 0.0, "name": "SIH_OF_NOISE", "shortDesc": "Optical flow measurement noise standard deviation", "type": "Float", "units": "rad/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 12.0, "group": "Simulation In Hardware", "longDesc": "The simulated sensor integrates the flow over one publication interval.\n", "max": 100.0, "min": 1.0, "name": "SIH_OF_RATE", "shortDesc": "Optical flow publication rate", "type": "Float", "units": "Hz"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.1, "group": "Simulation In Hardware", "increment": 0.05, "longDesc": "This is the maximum torque delivered by one propeller\nwhen the motor is running at full speed.\n\nThis value is usually about few percent of the maximum thrust force.\n\nRefer to SIH_F_Q_MAX for the propeller torque for FW, Tailsitter, and VTOL pusher.\n", "min": 0.0, "name": "SIH_Q_MAX", "shortDesc": "Max multicopter propeller torque", "type": "Float", "units": "Nm"}, {"category": "Standard", "decimalPlaces": 1, "default": 30.0, "group": "Simulation In Hardware", "longDesc": "Gaussian noise added to simulated ranging beacon measurements. Set to 0 to disable noise.\n", "max": 100.0, "min": 0.0, "name": "SIH_RNGBC_NOISE", "shortDesc": "Ranging beacon measurement noise standard deviation", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 5.0, "group": "Simulation In Hardware", "increment": 0.5, "longDesc": "This is the maximum force delivered by one propeller\nwhen the motor is running at full speed.\n\nThis value is usually about 5 times the mass of the quadrotor.\n\nRefer to SIH_F_T_MAX for the thrust for FW, Tailsitter, and VTOL pusher.\n", "min": 0.0, "name": "SIH_T_MAX", "shortDesc": "Max multicopter propeller thrust force", "type": "Float", "units": "N"}, {"category": "Standard", "default": 0.05, "group": "Simulation In Hardware", "longDesc": "the time taken for the thruster to step from 0 to 100% should be about 4 times tau\n", "name": "SIH_T_TAU", "shortDesc": "thruster time constant tau", "type": "Float", "units": "s"}, {"category": "Standard", "default": 0, "group": "Simulation In Hardware", "name": "SIH_VEHICLE_TYPE", "rebootRequired": true, "shortDesc": "Vehicle type", "type": "Int32", "values": [{"description": "Quadcopter", "value": 0}, {"description": "Fixed-Wing", "value": 1}, {"description": "Tailsitter", "value": 2}, {"description": "Standard VTOL", "value": 3}, {"description": "Hexacopter", "value": 4}, {"description": "Rover Ackermann", "value": 5}]}, {"category": "Standard", "default": 0.0, "group": "Simulation In Hardware", "name": "SIH_WIND_E", "shortDesc": "Wind velocity from east direction", "type": "Float", "units": "m/s"}, {"category": "Standard", "default": 0.0, "group": "Simulation In Hardware", "name": "SIH_WIND_N", "shortDesc": "Wind velocity from north direction", "type": "Float", "units": "m/s"}, {"bitmask": [{"description": "Stuck", "index": 0}, {"description": "Drift", "index": 1}], "category": "Standard", "default": 0, "group": "Simulator", "longDesc": "Stuck: freeze the measurement to the current location\nDrift: add a linearly growing bias to the sensor data\n", "max": 3, "min": 0, "name": "SIM_AGP_FAIL", "shortDesc": "AGP failure mode", "type": "Int32"}, {"category": "Standard", "default": 0.0, "group": "Simulator", "name": "SIM_BARO_OFF_P", "shortDesc": "simulated barometer pressure offset", "type": "Float", "units": "Pa"}, {"category": "Standard", "default": 0.0, "group": "Simulator", "name": "SIM_BARO_OFF_T", "shortDesc": "simulated barometer temperature offset", "type": "Float", "units": "celcius"}, {"category": "Standard", "default": 10, "group": "Simulator", "max": 50, "min": 0, "name": "SIM_GPS_USED", "shortDesc": "simulated GPS number of satellites used", "type": "Int32"}, {"category": "Standard", "default": 0.0, "group": "Simulator", "name": "SIM_MAG_OFFSET_X", "shortDesc": "simulated magnetometer X offset", "type": "Float", "units": "gauss"}, {"category": "Standard", "default": 0.0, "group": "Simulator", "name": "SIM_MAG_OFFSET_Y", "shortDesc": "simulated magnetometer Y offset", "type": "Float", "units": "gauss"}, {"category": "Standard", "default": 0.0, "group": "Simulator", "name": "SIM_MAG_OFFSET_Z", "shortDesc": "simulated magnetometer Z offset", "type": "Float", "units": "gauss"}, {"category": "Standard", "default": 0, "group": "System", "longDesc": "If enabled, a SYS_AUTOCONFIG reset overwrites stored sensor calibration with the airframe's built-in defaults.\nEnable when the airframe ships its own calibration.\n", "name": "SYS_AUTOCFG_CAL", "shortDesc": "Sensor calibration in SYS_AUTOCONFIG reset", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "System", "longDesc": "Set to 1 to reset parameters on next system startup (setting defaults).\nPlatform-specific values are used if available.\n", "name": "SYS_AUTOCONFIG", "shortDesc": "Automatically configure default values", "type": "Int32", "values": [{"description": "Keep parameters", "value": 0}, {"description": "Reset parameters to airframe defaults", "value": 1}]}, {"category": "Standard", "default": 0, "group": "System", "longDesc": "CHANGING THIS VALUE REQUIRES A RESTART. Defines the auto-start script used to bootstrap the system.\n", "max": 9999999, "min": 0, "name": "SYS_AUTOSTART", "rebootRequired": true, "shortDesc": "Auto-start script index", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "System", "longDesc": "If enabled, update the bootloader on the next boot. DroneCAN nodes\nupdate within about 2 seconds of it being set, without rebooting.\n\nWARNING: do not cut the power during an update process, otherwise you will\nhave to recover using some alternative method (e.g. JTAG).\n\nInstructions:\n- Insert an SD card\n- Enable this parameter\n- Reboot the board (plug the power or send a reboot command)\n- Wait until the board comes back up (or at least 2 minutes)\n- If it does not come back, check the file bootlog.txt on the SD card\n", "name": "SYS_BL_UPDATE", "rebootRequired": true, "shortDesc": "Bootloader update", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "System", "longDesc": "Enable auto start of accelerometer thermal calibration at the next power up\n\n0 : Set to 0 to do nothing\n1 : Set to 1 to start a calibration at next boot\nThis parameter is reset to zero when the temperature calibration starts.\n\ndefault (0, no calibration)\n", "max": 1, "min": 0, "name": "SYS_CAL_ACCEL", "shortDesc": "Auto start accel thermal calibration on next boot", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "System", "longDesc": "Enable auto start of barometer thermal calibration at the next power up\n\n0 : Set to 0 to do nothing\n1 : Set to 1 to start a calibration at next boot\nThis parameter is reset to zero when the temperature calibration starts.\n\ndefault (0, no calibration)\n", "max": 1, "min": 0, "name": "SYS_CAL_BARO", "shortDesc": "Auto start baro thermal calibration on next boot", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "System", "longDesc": "Enable auto start of rate gyro thermal calibration at the next power up\n\n0 : Set to 0 to do nothing\n1 : Set to 1 to start a calibration at next boot\nThis parameter is reset to zero when the temperature calibration starts.\n\ndefault (0, no calibration)\n", "max": 1, "min": 0, "name": "SYS_CAL_GYRO", "shortDesc": "Auto start gyro thermal calibration on next boot", "type": "Int32"}, {"category": "Standard", "default": 24, "group": "System", "longDesc": "A temperature increase greater than this value is required during calibration.\nCalibration will complete for each sensor when the temperature increase above the starting temperature exceeds the value set by SYS_CAL_TDEL.\nIf the temperature rise is insufficient, the calibration will continue indefinitely and the board will need to be repowered to exit.\n", "min": 10, "name": "SYS_CAL_TDEL", "shortDesc": "Required temperature rise during thermal calibration", "type": "Int32", "units": "celcius"}, {"category": "Standard", "default": 10, "group": "System", "longDesc": "Temperature calibration will not start if the temperature of any sensor is higher than the value set by SYS_CAL_TMAX.\n", "name": "SYS_CAL_TMAX", "shortDesc": "Maximum starting temperature for thermal calibration", "type": "Int32", "units": "celcius"}, {"category": "Standard", "default": 5, "group": "System", "longDesc": "Temperature calibration for each sensor will ignore data if the temperature is lower than the value set by SYS_CAL_TMIN.\n", "name": "SYS_CAL_TMIN", "shortDesc": "Minimum starting temperature for thermal calibration", "type": "Int32", "units": "celcius"}, {"category": "Standard", "default": 0, "group": "System", "longDesc": "If the board supports persistent storage (i.e., the KConfig variable DATAMAN_PERSISTENT_STORAGE is set),\nthe 'Default storage' backend uses a file on persistent storage. If not supported, this backend uses\nnon-persistent storage in RAM.\n", "name": "SYS_DM_BACKEND", "rebootRequired": true, "shortDesc": "Dataman storage backend", "type": "Int32", "values": [{"description": "Dataman disabled", "value": -1}, {"description": "Default storage", "value": 0}, {"description": "RAM storage", "value": 1}]}, {"category": "Standard", "default": 0, "group": "System", "longDesc": "If enabled, future sensor calibrations will be stored to /fs/mtd_caldata.\n\nNote: this is only supported on boards with a separate calibration storage\n/fs/mtd_caldata.\n", "name": "SYS_FAC_CAL_MODE", "shortDesc": "Enable factory calibration mode", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "All sensors", "value": 1}, {"description": "All sensors except mag", "value": 2}]}, {"category": "Standard", "default": 1, "group": "System", "longDesc": "Disable this if the board has no barometer, such as some of the Omnibus\nF4 SD variants.\nIf disabled, the preflight checks will not check for the presence of a\nbarometer.\n", "name": "SYS_HAS_BARO", "rebootRequired": true, "shortDesc": "Control if the vehicle has a barometer", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 1, "group": "System", "longDesc": "Disable this if the system has no GPS.\nIf disabled, the sensors hub will not process sensor_gnss,\nand GPS will not be available for the rest of the system.\n", "name": "SYS_HAS_GPS", "rebootRequired": true, "shortDesc": "Control if the vehicle has a GPS", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 1, "group": "System", "longDesc": "0: System has no magnetometer, preflight checks should pass without one.\n1-N: Require the presence of N magnetometer sensors for check to pass.\n", "name": "SYS_HAS_MAG", "rebootRequired": true, "shortDesc": "Control if and how many magnetometers are expected", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "System", "longDesc": "Set this to 0 if the board has no airspeed sensor.\nIf set to 0, the preflight checks will not check for the presence of an\nairspeed sensor.\n", "max": 1, "min": 0, "name": "SYS_HAS_NUM_ASPD", "shortDesc": "Control if the vehicle has an airspeed sensor", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "System", "longDesc": "The preflight check will fail if fewer than this number of distance sensors with valid data is present.\n\nDisable the check with 0.\n", "max": 4, "min": 0, "name": "SYS_HAS_NUM_DIST", "shortDesc": "Number of distance sensors to check being available", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "System", "longDesc": "0: No minimum receiver count required. Position divergence between two receivers\nand loss of a GNSS receiver still produce a warning but never trigger the\nCOM_GNSSLOSS_ACT failsafe action.\n1-N: Require the presence of N GNSS receivers for arming.\nIf the active count drops below this value in flight, COM_GNSSLOSS_ACT is triggered.\nWhen set to 2, position divergence between the two receivers also blocks arming when not armed and triggers COM_GNSSLOSS_ACT in flight.\n", "max": 2, "min": 0, "name": "SYS_HAS_NUM_GNSS", "shortDesc": "Control if and how many GNSS receivers are required", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "System", "longDesc": "The preflight check will fail if fewer than this number of optical flow sensors with valid data are present.\n", "max": 1, "min": 0, "name": "SYS_HAS_NUM_OF", "shortDesc": "Number of optical flow sensors required to be available", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "System", "longDesc": "While enabled the system will boot in Hardware-In-The-Loop (HITL)\nor Simulation-In-Hardware (SIH) mode and not enable all sensors and checks.\nWhen disabled the same vehicle can be flown normally.\n\nSet to 'external HITL', if the system should perform as if it were a real\nvehicle (the only difference to a real system is then only the parameter\nvalue, which can be used for log analysis).\n", "name": "SYS_HITL", "rebootRequired": true, "shortDesc": "Enable HITL/SIH mode on next boot", "type": "Int32", "values": [{"description": "external HITL", "value": -1}, {"description": "HITL and SIH disabled", "value": 0}, {"description": "HITL enabled", "value": 1}, {"description": "SIH enabled", "value": 2}]}, {"category": "Standard", "default": 1, "group": "System", "longDesc": "This is used internally only: an airframe configuration might set an expected\nparameter version value via PARAM_DEFAULTS_VER. This is checked on bootup\nagainst SYS_PARAM_VER, and if they do not match, parameters are reset and\nreloaded from the airframe configuration.\n", "min": 0, "name": "SYS_PARAM_VER", "shortDesc": "Parameter version", "type": "Int32"}, {"category": "Standard", "default": 1.0, "group": "System", "longDesc": "Set to 0 to disable, 1 for maximum brightness\n", "name": "SYS_RGB_MAXBRT", "shortDesc": "RGB Led brightness limit", "type": "Float", "units": "%"}, {"category": "Standard", "default": 1, "group": "System", "name": "SYS_STCK_EN", "shortDesc": "Enable stack checking", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"bitmask": [{"description": "GPS time", "index": 0}, {"description": "MAVLink time", "index": 1}, {"description": "Software RTC time", "index": 2}, {"description": "DDS time", "index": 3}, {"description": "Input simulation time", "index": 4}], "category": "Standard", "default": 31, "group": "System", "longDesc": "This parameter selects the source allowed to set the system time.\nThe default value enables all sources.\n", "max": 31, "min": 0, "name": "SYS_TIME_SRC", "rebootRequired": true, "shortDesc": "Select the source of the system time", "type": "Int32"}, {"category": "Standard", "default": 2, "group": "Testing", "name": "TEST_1", "shortDesc": "TEST_1", "type": "Int32"}, {"category": "Standard", "default": 4, "group": "Testing", "name": "TEST_2", "shortDesc": "TEST_2", "type": "Int32"}, {"category": "Standard", "default": 5.0, "group": "Testing", "name": "TEST_3", "shortDesc": "TEST_3", "type": "Float"}, {"category": "Standard", "default": 0.01, "group": "Testing", "name": "TEST_D", "shortDesc": "TEST_D", "type": "Float"}, {"category": "Standard", "default": 2.0, "group": "Testing", "name": "TEST_DEV", "shortDesc": "TEST_DEV", "type": "Float"}, {"category": "Standard", "default": 10.0, "group": "Testing", "name": "TEST_D_LP", "shortDesc": "TEST_D_LP", "type": "Float"}, {"category": "Standard", "default": 10.0, "group": "Testing", "name": "TEST_HP", "shortDesc": "TEST_HP", "type": "Float"}, {"category": "Standard", "default": 0.1, "group": "Testing", "name": "TEST_I", "shortDesc": "TEST_I", "type": "Float"}, {"category": "Standard", "default": 1.0, "group": "Testing", "name": "TEST_I_MAX", "shortDesc": "TEST_I_MAX", "type": "Float"}, {"category": "Standard", "default": 10.0, "group": "Testing", "name": "TEST_LP", "shortDesc": "TEST_LP", "type": "Float"}, {"category": "Standard", "default": 1.0, "group": "Testing", "name": "TEST_MAX", "shortDesc": "TEST_MAX", "type": "Float"}, {"category": "Standard", "default": 1.0, "group": "Testing", "name": "TEST_MEAN", "shortDesc": "TEST_MEAN", "type": "Float"}, {"category": "Standard", "default": -1.0, "group": "Testing", "name": "TEST_MIN", "shortDesc": "TEST_MIN", "type": "Float"}, {"category": "Standard", "default": 0.2, "group": "Testing", "name": "TEST_P", "shortDesc": "TEST_P", "type": "Float"}, {"category": "Standard", "default": 12345678, "group": "Testing", "name": "TEST_PARAMS", "shortDesc": "TEST_PARAMS", "type": "Int32"}, {"category": "Standard", "default": 16, "group": "Testing", "name": "TEST_RC2_X", "shortDesc": "TEST_RC2_X", "type": "Int32"}, {"category": "Standard", "default": 8, "group": "Testing", "name": "TEST_RC_X", "shortDesc": "TEST_RC_X", "type": "Int32"}, {"category": "Standard", "default": 0.5, "group": "Testing", "name": "TEST_TRIM", "shortDesc": "TEST_TRIM", "type": "Float"}, {"category": "System", "default": 0, "group": "Thermal Compensation", "name": "TC_A0_ID", "shortDesc": "ID of Accelerometer that the calibration is for", "type": "Int32"}, {"category": "System", "default": 100.0, "group": "Thermal Compensation", "name": "TC_A0_TMAX", "shortDesc": "Accelerometer calibration maximum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A0_TMIN", "shortDesc": "Accelerometer calibration minimum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 25.0, "group": "Thermal Compensation", "name": "TC_A0_TREF", "shortDesc": "Accelerometer calibration reference temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A0_X0_0", "shortDesc": "Accelerometer offset temperature ^0 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A0_X0_1", "shortDesc": "Accelerometer offset temperature ^0 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A0_X0_2", "shortDesc": "Accelerometer offset temperature ^0 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A0_X1_0", "shortDesc": "Accelerometer offset temperature ^1 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A0_X1_1", "shortDesc": "Accelerometer offset temperature ^1 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A0_X1_2", "shortDesc": "Accelerometer offset temperature ^1 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A0_X2_0", "shortDesc": "Accelerometer offset temperature ^2 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A0_X2_1", "shortDesc": "Accelerometer offset temperature ^2 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A0_X2_2", "shortDesc": "Accelerometer offset temperature ^2 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A0_X3_0", "shortDesc": "Accelerometer offset temperature ^3 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A0_X3_1", "shortDesc": "Accelerometer offset temperature ^3 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A0_X3_2", "shortDesc": "Accelerometer offset temperature ^3 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0, "group": "Thermal Compensation", "name": "TC_A1_ID", "shortDesc": "ID of Accelerometer that the calibration is for", "type": "Int32"}, {"category": "System", "default": 100.0, "group": "Thermal Compensation", "name": "TC_A1_TMAX", "shortDesc": "Accelerometer calibration maximum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A1_TMIN", "shortDesc": "Accelerometer calibration minimum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 25.0, "group": "Thermal Compensation", "name": "TC_A1_TREF", "shortDesc": "Accelerometer calibration reference temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A1_X0_0", "shortDesc": "Accelerometer offset temperature ^0 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A1_X0_1", "shortDesc": "Accelerometer offset temperature ^0 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A1_X0_2", "shortDesc": "Accelerometer offset temperature ^0 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A1_X1_0", "shortDesc": "Accelerometer offset temperature ^1 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A1_X1_1", "shortDesc": "Accelerometer offset temperature ^1 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A1_X1_2", "shortDesc": "Accelerometer offset temperature ^1 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A1_X2_0", "shortDesc": "Accelerometer offset temperature ^2 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A1_X2_1", "shortDesc": "Accelerometer offset temperature ^2 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A1_X2_2", "shortDesc": "Accelerometer offset temperature ^2 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A1_X3_0", "shortDesc": "Accelerometer offset temperature ^3 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A1_X3_1", "shortDesc": "Accelerometer offset temperature ^3 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A1_X3_2", "shortDesc": "Accelerometer offset temperature ^3 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0, "group": "Thermal Compensation", "name": "TC_A2_ID", "shortDesc": "ID of Accelerometer that the calibration is for", "type": "Int32"}, {"category": "System", "default": 100.0, "group": "Thermal Compensation", "name": "TC_A2_TMAX", "shortDesc": "Accelerometer calibration maximum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A2_TMIN", "shortDesc": "Accelerometer calibration minimum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 25.0, "group": "Thermal Compensation", "name": "TC_A2_TREF", "shortDesc": "Accelerometer calibration reference temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A2_X0_0", "shortDesc": "Accelerometer offset temperature ^0 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A2_X0_1", "shortDesc": "Accelerometer offset temperature ^0 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A2_X0_2", "shortDesc": "Accelerometer offset temperature ^0 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A2_X1_0", "shortDesc": "Accelerometer offset temperature ^1 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A2_X1_1", "shortDesc": "Accelerometer offset temperature ^1 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A2_X1_2", "shortDesc": "Accelerometer offset temperature ^1 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A2_X2_0", "shortDesc": "Accelerometer offset temperature ^2 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A2_X2_1", "shortDesc": "Accelerometer offset temperature ^2 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A2_X2_2", "shortDesc": "Accelerometer offset temperature ^2 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A2_X3_0", "shortDesc": "Accelerometer offset temperature ^3 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A2_X3_1", "shortDesc": "Accelerometer offset temperature ^3 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A2_X3_2", "shortDesc": "Accelerometer offset temperature ^3 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0, "group": "Thermal Compensation", "name": "TC_A3_ID", "shortDesc": "ID of Accelerometer that the calibration is for", "type": "Int32"}, {"category": "System", "default": 100.0, "group": "Thermal Compensation", "name": "TC_A3_TMAX", "shortDesc": "Accelerometer calibration maximum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A3_TMIN", "shortDesc": "Accelerometer calibration minimum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 25.0, "group": "Thermal Compensation", "name": "TC_A3_TREF", "shortDesc": "Accelerometer calibration reference temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A3_X0_0", "shortDesc": "Accelerometer offset temperature ^0 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A3_X0_1", "shortDesc": "Accelerometer offset temperature ^0 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A3_X0_2", "shortDesc": "Accelerometer offset temperature ^0 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A3_X1_0", "shortDesc": "Accelerometer offset temperature ^1 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A3_X1_1", "shortDesc": "Accelerometer offset temperature ^1 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A3_X1_2", "shortDesc": "Accelerometer offset temperature ^1 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A3_X2_0", "shortDesc": "Accelerometer offset temperature ^2 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A3_X2_1", "shortDesc": "Accelerometer offset temperature ^2 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A3_X2_2", "shortDesc": "Accelerometer offset temperature ^2 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A3_X3_0", "shortDesc": "Accelerometer offset temperature ^3 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A3_X3_1", "shortDesc": "Accelerometer offset temperature ^3 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A3_X3_2", "shortDesc": "Accelerometer offset temperature ^3 polynomial coefficient - Z axis", "type": "Float"}, {"category": "Standard", "default": 0, "group": "Thermal Compensation", "name": "TC_A_ENABLE", "rebootRequired": true, "shortDesc": "Thermal compensation for accelerometer sensors", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "System", "default": 0, "group": "Thermal Compensation", "name": "TC_B0_ID", "shortDesc": "ID of Barometer that the calibration is for", "type": "Int32"}, {"category": "System", "default": 75.0, "group": "Thermal Compensation", "name": "TC_B0_TMAX", "shortDesc": "Barometer calibration maximum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 5.0, "group": "Thermal Compensation", "name": "TC_B0_TMIN", "shortDesc": "Barometer calibration minimum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 40.0, "group": "Thermal Compensation", "name": "TC_B0_TREF", "shortDesc": "Barometer calibration reference temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B0_X0", "shortDesc": "Barometer offset temperature ^0 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B0_X1", "shortDesc": "Barometer offset temperature ^1 polynomial coefficients", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B0_X2", "shortDesc": "Barometer offset temperature ^2 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B0_X3", "shortDesc": "Barometer offset temperature ^3 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B0_X4", "shortDesc": "Barometer offset temperature ^4 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B0_X5", "shortDesc": "Barometer offset temperature ^5 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0, "group": "Thermal Compensation", "name": "TC_B1_ID", "shortDesc": "ID of Barometer that the calibration is for", "type": "Int32"}, {"category": "System", "default": 75.0, "group": "Thermal Compensation", "name": "TC_B1_TMAX", "shortDesc": "Barometer calibration maximum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 5.0, "group": "Thermal Compensation", "name": "TC_B1_TMIN", "shortDesc": "Barometer calibration minimum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 40.0, "group": "Thermal Compensation", "name": "TC_B1_TREF", "shortDesc": "Barometer calibration reference temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B1_X0", "shortDesc": "Barometer offset temperature ^0 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B1_X1", "shortDesc": "Barometer offset temperature ^1 polynomial coefficients", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B1_X2", "shortDesc": "Barometer offset temperature ^2 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B1_X3", "shortDesc": "Barometer offset temperature ^3 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B1_X4", "shortDesc": "Barometer offset temperature ^4 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B1_X5", "shortDesc": "Barometer offset temperature ^5 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0, "group": "Thermal Compensation", "name": "TC_B2_ID", "shortDesc": "ID of Barometer that the calibration is for", "type": "Int32"}, {"category": "System", "default": 75.0, "group": "Thermal Compensation", "name": "TC_B2_TMAX", "shortDesc": "Barometer calibration maximum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 5.0, "group": "Thermal Compensation", "name": "TC_B2_TMIN", "shortDesc": "Barometer calibration minimum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 40.0, "group": "Thermal Compensation", "name": "TC_B2_TREF", "shortDesc": "Barometer calibration reference temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B2_X0", "shortDesc": "Barometer offset temperature ^0 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B2_X1", "shortDesc": "Barometer offset temperature ^1 polynomial coefficients", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B2_X2", "shortDesc": "Barometer offset temperature ^2 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B2_X3", "shortDesc": "Barometer offset temperature ^3 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B2_X4", "shortDesc": "Barometer offset temperature ^4 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B2_X5", "shortDesc": "Barometer offset temperature ^5 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0, "group": "Thermal Compensation", "name": "TC_B3_ID", "shortDesc": "ID of Barometer that the calibration is for", "type": "Int32"}, {"category": "System", "default": 75.0, "group": "Thermal Compensation", "name": "TC_B3_TMAX", "shortDesc": "Barometer calibration maximum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 5.0, "group": "Thermal Compensation", "name": "TC_B3_TMIN", "shortDesc": "Barometer calibration minimum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 40.0, "group": "Thermal Compensation", "name": "TC_B3_TREF", "shortDesc": "Barometer calibration reference temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B3_X0", "shortDesc": "Barometer offset temperature ^0 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B3_X1", "shortDesc": "Barometer offset temperature ^1 polynomial coefficients", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B3_X2", "shortDesc": "Barometer offset temperature ^2 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B3_X3", "shortDesc": "Barometer offset temperature ^3 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B3_X4", "shortDesc": "Barometer offset temperature ^4 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B3_X5", "shortDesc": "Barometer offset temperature ^5 polynomial coefficient", "type": "Float"}, {"category": "Standard", "default": 0, "group": "Thermal Compensation", "name": "TC_B_ENABLE", "rebootRequired": true, "shortDesc": "Thermal compensation for barometric pressure sensors", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "System", "default": 0, "group": "Thermal Compensation", "name": "TC_G0_ID", "shortDesc": "ID of Gyro that the calibration is for", "type": "Int32"}, {"category": "System", "default": 100.0, "group": "Thermal Compensation", "name": "TC_G0_TMAX", "shortDesc": "Gyro calibration maximum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G0_TMIN", "shortDesc": "Gyro calibration minimum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 25.0, "group": "Thermal Compensation", "name": "TC_G0_TREF", "shortDesc": "Gyro calibration reference temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G0_X0_0", "shortDesc": "Gyro rate offset temperature ^0 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G0_X0_1", "shortDesc": "Gyro rate offset temperature ^0 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G0_X0_2", "shortDesc": "Gyro rate offset temperature ^0 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G0_X1_0", "shortDesc": "Gyro rate offset temperature ^1 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G0_X1_1", "shortDesc": "Gyro rate offset temperature ^1 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G0_X1_2", "shortDesc": "Gyro rate offset temperature ^1 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G0_X2_0", "shortDesc": "Gyro rate offset temperature ^2 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G0_X2_1", "shortDesc": "Gyro rate offset temperature ^2 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G0_X2_2", "shortDesc": "Gyro rate offset temperature ^2 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G0_X3_0", "shortDesc": "Gyro rate offset temperature ^3 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G0_X3_1", "shortDesc": "Gyro rate offset temperature ^3 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G0_X3_2", "shortDesc": "Gyro rate offset temperature ^3 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0, "group": "Thermal Compensation", "name": "TC_G1_ID", "shortDesc": "ID of Gyro that the calibration is for", "type": "Int32"}, {"category": "System", "default": 100.0, "group": "Thermal Compensation", "name": "TC_G1_TMAX", "shortDesc": "Gyro calibration maximum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G1_TMIN", "shortDesc": "Gyro calibration minimum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 25.0, "group": "Thermal Compensation", "name": "TC_G1_TREF", "shortDesc": "Gyro calibration reference temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G1_X0_0", "shortDesc": "Gyro rate offset temperature ^0 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G1_X0_1", "shortDesc": "Gyro rate offset temperature ^0 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G1_X0_2", "shortDesc": "Gyro rate offset temperature ^0 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G1_X1_0", "shortDesc": "Gyro rate offset temperature ^1 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G1_X1_1", "shortDesc": "Gyro rate offset temperature ^1 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G1_X1_2", "shortDesc": "Gyro rate offset temperature ^1 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G1_X2_0", "shortDesc": "Gyro rate offset temperature ^2 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G1_X2_1", "shortDesc": "Gyro rate offset temperature ^2 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G1_X2_2", "shortDesc": "Gyro rate offset temperature ^2 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G1_X3_0", "shortDesc": "Gyro rate offset temperature ^3 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G1_X3_1", "shortDesc": "Gyro rate offset temperature ^3 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G1_X3_2", "shortDesc": "Gyro rate offset temperature ^3 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0, "group": "Thermal Compensation", "name": "TC_G2_ID", "shortDesc": "ID of Gyro that the calibration is for", "type": "Int32"}, {"category": "System", "default": 100.0, "group": "Thermal Compensation", "name": "TC_G2_TMAX", "shortDesc": "Gyro calibration maximum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G2_TMIN", "shortDesc": "Gyro calibration minimum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 25.0, "group": "Thermal Compensation", "name": "TC_G2_TREF", "shortDesc": "Gyro calibration reference temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G2_X0_0", "shortDesc": "Gyro rate offset temperature ^0 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G2_X0_1", "shortDesc": "Gyro rate offset temperature ^0 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G2_X0_2", "shortDesc": "Gyro rate offset temperature ^0 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G2_X1_0", "shortDesc": "Gyro rate offset temperature ^1 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G2_X1_1", "shortDesc": "Gyro rate offset temperature ^1 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G2_X1_2", "shortDesc": "Gyro rate offset temperature ^1 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G2_X2_0", "shortDesc": "Gyro rate offset temperature ^2 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G2_X2_1", "shortDesc": "Gyro rate offset temperature ^2 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G2_X2_2", "shortDesc": "Gyro rate offset temperature ^2 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G2_X3_0", "shortDesc": "Gyro rate offset temperature ^3 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G2_X3_1", "shortDesc": "Gyro rate offset temperature ^3 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G2_X3_2", "shortDesc": "Gyro rate offset temperature ^3 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0, "group": "Thermal Compensation", "name": "TC_G3_ID", "shortDesc": "ID of Gyro that the calibration is for", "type": "Int32"}, {"category": "System", "default": 100.0, "group": "Thermal Compensation", "name": "TC_G3_TMAX", "shortDesc": "Gyro calibration maximum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G3_TMIN", "shortDesc": "Gyro calibration minimum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 25.0, "group": "Thermal Compensation", "name": "TC_G3_TREF", "shortDesc": "Gyro calibration reference temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G3_X0_0", "shortDesc": "Gyro rate offset temperature ^0 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G3_X0_1", "shortDesc": "Gyro rate offset temperature ^0 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G3_X0_2", "shortDesc": "Gyro rate offset temperature ^0 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G3_X1_0", "shortDesc": "Gyro rate offset temperature ^1 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G3_X1_1", "shortDesc": "Gyro rate offset temperature ^1 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G3_X1_2", "shortDesc": "Gyro rate offset temperature ^1 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G3_X2_0", "shortDesc": "Gyro rate offset temperature ^2 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G3_X2_1", "shortDesc": "Gyro rate offset temperature ^2 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G3_X2_2", "shortDesc": "Gyro rate offset temperature ^2 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G3_X3_0", "shortDesc": "Gyro rate offset temperature ^3 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G3_X3_1", "shortDesc": "Gyro rate offset temperature ^3 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G3_X3_2", "shortDesc": "Gyro rate offset temperature ^3 polynomial coefficient - Z axis", "type": "Float"}, {"category": "Standard", "default": 0, "group": "Thermal Compensation", "name": "TC_G_ENABLE", "rebootRequired": true, "shortDesc": "Thermal compensation for rate gyro sensors", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "System", "default": 0, "group": "Thermal Compensation", "name": "TC_M0_ID", "shortDesc": "ID of Magnetometer that the calibration is for", "type": "Int32"}, {"category": "System", "default": 100.0, "group": "Thermal Compensation", "name": "TC_M0_TMAX", "shortDesc": "Magnetometer calibration maximum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M0_TMIN", "shortDesc": "Magnetometer calibration minimum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 25.0, "group": "Thermal Compensation", "name": "TC_M0_TREF", "shortDesc": "Magnetometer calibration reference temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M0_X0_0", "shortDesc": "Magnetometer offset temperature ^0 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M0_X0_1", "shortDesc": "Magnetometer offset temperature ^0 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M0_X0_2", "shortDesc": "Magnetometer offset temperature ^0 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M0_X1_0", "shortDesc": "Magnetometer offset temperature ^1 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M0_X1_1", "shortDesc": "Magnetometer offset temperature ^1 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M0_X1_2", "shortDesc": "Magnetometer offset temperature ^1 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M0_X2_0", "shortDesc": "Magnetometer offset temperature ^2 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M0_X2_1", "shortDesc": "Magnetometer offset temperature ^2 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M0_X2_2", "shortDesc": "Magnetometer offset temperature ^2 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M0_X3_0", "shortDesc": "Magnetometer offset temperature ^3 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M0_X3_1", "shortDesc": "Magnetometer offset temperature ^3 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M0_X3_2", "shortDesc": "Magnetometer offset temperature ^3 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0, "group": "Thermal Compensation", "name": "TC_M1_ID", "shortDesc": "ID of Magnetometer that the calibration is for", "type": "Int32"}, {"category": "System", "default": 100.0, "group": "Thermal Compensation", "name": "TC_M1_TMAX", "shortDesc": "Magnetometer calibration maximum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M1_TMIN", "shortDesc": "Magnetometer calibration minimum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 25.0, "group": "Thermal Compensation", "name": "TC_M1_TREF", "shortDesc": "Magnetometer calibration reference temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M1_X0_0", "shortDesc": "Magnetometer offset temperature ^0 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M1_X0_1", "shortDesc": "Magnetometer offset temperature ^0 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M1_X0_2", "shortDesc": "Magnetometer offset temperature ^0 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M1_X1_0", "shortDesc": "Magnetometer offset temperature ^1 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M1_X1_1", "shortDesc": "Magnetometer offset temperature ^1 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M1_X1_2", "shortDesc": "Magnetometer offset temperature ^1 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M1_X2_0", "shortDesc": "Magnetometer offset temperature ^2 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M1_X2_1", "shortDesc": "Magnetometer offset temperature ^2 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M1_X2_2", "shortDesc": "Magnetometer offset temperature ^2 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M1_X3_0", "shortDesc": "Magnetometer offset temperature ^3 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M1_X3_1", "shortDesc": "Magnetometer offset temperature ^3 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M1_X3_2", "shortDesc": "Magnetometer offset temperature ^3 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0, "group": "Thermal Compensation", "name": "TC_M2_ID", "shortDesc": "ID of Magnetometer that the calibration is for", "type": "Int32"}, {"category": "System", "default": 100.0, "group": "Thermal Compensation", "name": "TC_M2_TMAX", "shortDesc": "Magnetometer calibration maximum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M2_TMIN", "shortDesc": "Magnetometer calibration minimum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 25.0, "group": "Thermal Compensation", "name": "TC_M2_TREF", "shortDesc": "Magnetometer calibration reference temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M2_X0_0", "shortDesc": "Magnetometer offset temperature ^0 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M2_X0_1", "shortDesc": "Magnetometer offset temperature ^0 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M2_X0_2", "shortDesc": "Magnetometer offset temperature ^0 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M2_X1_0", "shortDesc": "Magnetometer offset temperature ^1 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M2_X1_1", "shortDesc": "Magnetometer offset temperature ^1 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M2_X1_2", "shortDesc": "Magnetometer offset temperature ^1 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M2_X2_0", "shortDesc": "Magnetometer offset temperature ^2 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M2_X2_1", "shortDesc": "Magnetometer offset temperature ^2 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M2_X2_2", "shortDesc": "Magnetometer offset temperature ^2 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M2_X3_0", "shortDesc": "Magnetometer offset temperature ^3 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M2_X3_1", "shortDesc": "Magnetometer offset temperature ^3 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M2_X3_2", "shortDesc": "Magnetometer offset temperature ^3 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0, "group": "Thermal Compensation", "name": "TC_M3_ID", "shortDesc": "ID of Magnetometer that the calibration is for", "type": "Int32"}, {"category": "System", "default": 100.0, "group": "Thermal Compensation", "name": "TC_M3_TMAX", "shortDesc": "Magnetometer calibration maximum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M3_TMIN", "shortDesc": "Magnetometer calibration minimum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 25.0, "group": "Thermal Compensation", "name": "TC_M3_TREF", "shortDesc": "Magnetometer calibration reference temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M3_X0_0", "shortDesc": "Magnetometer offset temperature ^0 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M3_X0_1", "shortDesc": "Magnetometer offset temperature ^0 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M3_X0_2", "shortDesc": "Magnetometer offset temperature ^0 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M3_X1_0", "shortDesc": "Magnetometer offset temperature ^1 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M3_X1_1", "shortDesc": "Magnetometer offset temperature ^1 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M3_X1_2", "shortDesc": "Magnetometer offset temperature ^1 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M3_X2_0", "shortDesc": "Magnetometer offset temperature ^2 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M3_X2_1", "shortDesc": "Magnetometer offset temperature ^2 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M3_X2_2", "shortDesc": "Magnetometer offset temperature ^2 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M3_X3_0", "shortDesc": "Magnetometer offset temperature ^3 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M3_X3_1", "shortDesc": "Magnetometer offset temperature ^3 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M3_X3_2", "shortDesc": "Magnetometer offset temperature ^3 polynomial coefficient - Z axis", "type": "Float"}, {"category": "Standard", "default": 0, "group": "Thermal Compensation", "name": "TC_M_ENABLE", "rebootRequired": true, "shortDesc": "Thermal compensation for magnetometer sensors", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 12, "group": "UUV Attitude Control", "max": 16, "min": 0, "name": "UUV_HGT_B_DOWN", "shortDesc": "Height rc-button down", "type": "Int32"}, {"category": "Standard", "default": 11, "group": "UUV Attitude Control", "max": 16, "min": 0, "name": "UUV_HGT_B_UP", "shortDesc": "Height rc-button up", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "UUV Attitude Control", "name": "UUV_HGT_D", "shortDesc": "Height differential gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.2, "group": "UUV Attitude Control", "name": "UUV_HGT_I", "shortDesc": "Height integrational gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "UUV Attitude Control", "name": "UUV_HGT_I_SPD", "shortDesc": "sum speed of error for integrational gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "UUV Attitude Control", "longDesc": "maximum Height distance controlled by manual input. Diff between actual and desired Height cannot be higher than that\n", "name": "UUV_HGT_MAX_DIFF", "shortDesc": "Max height error from manual input", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "UUV Attitude Control", "name": "UUV_HGT_P", "shortDesc": "Height proportional gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "UUV Attitude Control", "name": "UUV_HGT_STR", "shortDesc": "Height change strength from manual input", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.05, "group": "UUV Attitude Control", "min": 0.0, "name": "UUV_MGM_PITCH", "shortDesc": "Pitch gain for manual inputs in manual control mode", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.05, "group": "UUV Attitude Control", "min": 0.0, "name": "UUV_MGM_ROLL", "shortDesc": "Roll gain for manual inputs in manual control mode", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "UUV Attitude Control", "min": 0.0, "name": "UUV_MGM_THRTL", "shortDesc": "Throttle gain for manual inputs in manual control mode", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.05, "group": "UUV Attitude Control", "min": 0.0, "name": "UUV_MGM_YAW", "shortDesc": "Yaw gain for manual inputs in manual control mode", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 2.0, "group": "UUV Attitude Control", "name": "UUV_PITCH_D", "shortDesc": "Pitch differential gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 4.0, "group": "UUV Attitude Control", "name": "UUV_PITCH_P", "shortDesc": "Pitch proportional gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 100.0, "group": "UUV Attitude Control", "min": 0.0, "name": "UUV_RGM_PITCH", "shortDesc": "Pitch gain for manual inputs in rate control mode", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 100.0, "group": "UUV Attitude Control", "min": 0.0, "name": "UUV_RGM_ROLL", "shortDesc": "Roll gain for manual inputs in rate control mode", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 10.0, "group": "UUV Attitude Control", "min": 0.0, "name": "UUV_RGM_THRTL", "shortDesc": "Throttle gain for manual inputs in rate control mode", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 100.0, "group": "UUV Attitude Control", "min": 0.0, "name": "UUV_RGM_YAW", "shortDesc": "Yaw gain for manual inputs in rate control mode", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.5, "group": "UUV Attitude Control", "name": "UUV_ROLL_D", "shortDesc": "Roll differential gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 4.0, "group": "UUV Attitude Control", "name": "UUV_ROLL_P", "shortDesc": "Roll proportional gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.5, "group": "UUV Attitude Control", "min": 0.0, "name": "UUV_SGM_PITCH", "shortDesc": "Pitch gain for manual inputs in attitude control mode", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.5, "group": "UUV Attitude Control", "min": 0.0, "name": "UUV_SGM_ROLL", "shortDesc": "Roll gain for manual inputs in attitude control mode", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "UUV Attitude Control", "min": 0.0, "name": "UUV_SGM_THRTL", "shortDesc": "Throttle gain for manual inputs in attitude control mode", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.5, "group": "UUV Attitude Control", "min": 0.0, "name": "UUV_SGM_YAW", "shortDesc": "Yaw gain for manual inputs in attitude control mode", "type": "Float"}, {"category": "Standard", "default": 2.0, "group": "UUV Attitude Control", "name": "UUV_SP_MAX_AGE", "shortDesc": "Maximum time before resetting setpoint", "type": "Float", "units": "s"}, {"category": "Standard", "default": 0, "group": "UUV Attitude Control", "longDesc": "Stick mode selector (0=Heave/sway control, roll/pitch leveled; 1=Pitch/roll control)\n", "max": 1, "min": 0, "name": "UUV_STICK_MODE", "shortDesc": "UUV stick input mode", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "UUV Attitude Control", "max": 1.0, "min": 0.0, "name": "UUV_THRUST_SAT", "shortDesc": "UUV Thrust setpoint Saturation", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "UUV Attitude Control", "max": 1.0, "min": 0.0, "name": "UUV_TORQUE_SAT", "shortDesc": "UUV Torque setpoint Saturation", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 2.0, "group": "UUV Attitude Control", "name": "UUV_YAW_D", "shortDesc": "Yaw differential gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 4.0, "group": "UUV Attitude Control", "name": "UUV_YAW_P", "shortDesc": "Yaw proportional gain", "type": "Float"}, {"category": "Standard", "default": 0.2, "group": "UUV Position Control", "name": "UUV_GAIN_X_D", "shortDesc": "Gain of D controller X", "type": "Float"}, {"category": "Standard", "default": 1.0, "group": "UUV Position Control", "name": "UUV_GAIN_X_P", "shortDesc": "Gain of P controller X", "type": "Float"}, {"category": "Standard", "default": 0.2, "group": "UUV Position Control", "name": "UUV_GAIN_Y_D", "shortDesc": "Gain of D controller Y", "type": "Float"}, {"category": "Standard", "default": 1.0, "group": "UUV Position Control", "name": "UUV_GAIN_Y_P", "shortDesc": "Gain of P controller Y", "type": "Float"}, {"category": "Standard", "default": 0.2, "group": "UUV Position Control", "name": "UUV_GAIN_Z_D", "shortDesc": "Gain of D controller Z", "type": "Float"}, {"category": "Standard", "default": 1.0, "group": "UUV Position Control", "name": "UUV_GAIN_Z_P", "shortDesc": "Gain of P controller Z", "type": "Float"}, {"category": "Standard", "default": 0.5, "group": "UUV Position Control", "name": "UUV_PGM_VEL", "shortDesc": "Gain for position control velocity setpoint update", "type": "Float"}, {"category": "Standard", "default": 1, "group": "UUV Position Control", "name": "UUV_POS_MODE", "shortDesc": "Stabilization mode(1) or Position Control(0)", "type": "Int32", "values": [{"description": "Moves position setpoint in world frame", "value": 0}, {"description": "Moves position setpoint in body frame", "value": 1}]}, {"category": "Standard", "default": 0.1, "group": "UUV Position Control", "name": "UUV_POS_STICK_DB", "shortDesc": "Deadband for changing position setpoint", "type": "Float"}, {"category": "Standard", "default": 1, "group": "UUV Position Control", "name": "UUV_STAB_MODE", "shortDesc": "Stabilization mode(1) or Position Control(0)", "type": "Int32", "values": [{"description": "Tracks previous attitude setpoint", "value": 0}, {"description": "Tracks horizontal attitude (allows yaw change)", "value": 1}]}, {"category": "Standard", "default": 2130706433, "group": "UXRCE-DDS Client", "longDesc": "If ethernet is enabled and is the selected configuration for uXRCE-DDS,\nthe selected Agent IP address will be set and used.\nDecimal dot notation is not supported. IP address must be provided\nin int32 format. For example, 192.168.1.2 is mapped to -1062731518;\n127.0.0.1 is mapped to 2130706433.\n\n", "name": "UXRCE_DDS_AG_IP", "rebootRequired": true, "shortDesc": "uXRCE-DDS Agent IP address", "type": "Int32"}, {"category": "System", "default": 0, "group": "UXRCE-DDS Client", "longDesc": "uXRCE-DDS domain ID\n", "name": "UXRCE_DDS_DOM_ID", "rebootRequired": true, "shortDesc": "uXRCE-DDS domain ID", "type": "Int32"}, {"category": "System", "default": 0, "group": "UXRCE-DDS Client", "longDesc": "This is used to enable flow control for the serial uXRCE instance.\nUsed for reliable high bandwidth communication.\n\n", "name": "UXRCE_DDS_FLCTRL", "rebootRequired": true, "shortDesc": "Enable serial flow control for UXRCE interface", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "System", "default": 1, "group": "UXRCE-DDS Client", "longDesc": "uXRCE-DDS key, must be different from zero.\nIn a single agent - multi client configuration, each client\nmust have a unique session key.\n\n", "name": "UXRCE_DDS_KEY", "rebootRequired": true, "shortDesc": "uXRCE-DDS session key", "type": "Int32"}, {"category": "System", "default": -1, "group": "UXRCE-DDS Client", "longDesc": "Defines an index-based namespace for DDS messages, e.g, uav_0, uav_1, up to uav_9999\nA value less than zero leaves the namespace empty\n\n", "max": 9999, "min": -1, "name": "UXRCE_DDS_NS_IDX", "rebootRequired": true, "shortDesc": "Define an index-based message namespace", "type": "Int32"}, {"category": "Standard", "default": 8888, "group": "UXRCE-DDS Client", "longDesc": "If ethernet is enabled and is the selected configuration for uXRCE-DDS,\nthe selected UDP port will be set and used.\n\n", "max": 65535, "min": 0, "name": "UXRCE_DDS_PRT", "rebootRequired": true, "shortDesc": "uXRCE-DDS UDP port", "type": "Int32"}, {"category": "System", "default": 0, "group": "UXRCE-DDS Client", "longDesc": "Set the participant configuration on the Agent's system.\n0: Use the default configuration.\n1: Restrict messages to localhost\n(use in combination with ROS_LOCALHOST_ONLY=1).\n2: Use a custom participant with the profile name \"px4_participant\".\n\n", "max": 2, "min": 0, "name": "UXRCE_DDS_PTCFG", "rebootRequired": true, "shortDesc": "uXRCE-DDS participant configuration", "type": "Int32", "values": [{"description": "Default", "value": 0}, {"description": "Localhost-only", "value": 1}, {"description": "Custom participant", "value": 2}]}, {"category": "System", "default": -1, "group": "UXRCE-DDS Client", "longDesc": "Specifies after how many seconds without receiving data the DDS connection is reestablished.\nA value less than one disables the RX rate timeout.\n\n", "name": "UXRCE_DDS_RX_TO", "rebootRequired": true, "shortDesc": "RX rate timeout configuration", "type": "Int32", "units": "s"}, {"category": "System", "default": 0, "group": "UXRCE-DDS Client", "longDesc": "When enabled along with UXRCE_DDS_SYNCT, uxrce_dds_client will set the system clock using the agents UTC timestamp.\n", "name": "UXRCE_DDS_SYNCC", "rebootRequired": true, "shortDesc": "Enable uXRCE-DDS system clock synchronization", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "System", "default": 1, "group": "UXRCE-DDS Client", "longDesc": "When enabled, uxrce_dds_client will synchronize the timestamps of the incoming and outgoing messages measuring the offset between the Agent OS time and the PX4 time.\n", "name": "UXRCE_DDS_SYNCT", "rebootRequired": true, "shortDesc": "Enable uXRCE-DDS timestamp synchronization", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "System", "default": 3, "group": "UXRCE-DDS Client", "longDesc": "Specifies after how many seconds without sending data the DDS connection is reestablished.\nA value less than one disables the TX rate timeout.\n\n", "name": "UXRCE_DDS_TX_TO", "rebootRequired": true, "shortDesc": "TX rate timeout configuration", "type": "Int32", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 8.0, "group": "VTOL Attitude Control", "increment": 1.0, "longDesc": "Airspeed at which we can start blending both fw and mc controls. Set to 0 to disable.\n", "max": 30.0, "min": 0.0, "name": "VT_ARSP_BLEND", "shortDesc": "Transition blending airspeed", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 10.0, "group": "VTOL Attitude Control", "increment": 1.0, "longDesc": "Airspeed at which we can switch to fw mode\n", "max": 30.0, "min": 0.0, "name": "VT_ARSP_TRANS", "shortDesc": "Transition airspeed", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.0, "group": "VTOL Attitude Control", "increment": 0.1, "longDesc": "Time in seconds it takes to tilt form VT_TILT_FW to VT_TILT_MC.\n", "max": 10.0, "min": 0.1, "name": "VT_BT_TILT_DUR", "shortDesc": "Duration motor tilt up in backtransition", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "VTOL Attitude Control", "increment": 0.05, "max": 0.3, "min": 0.0, "name": "VT_B_DEC_I", "shortDesc": "Backtransition deceleration setpoint to tilt I gain", "type": "Float", "units": "rad s/m"}, {"category": "Standard", "decimalPlaces": 2, "default": 2.0, "group": "VTOL Attitude Control", "increment": 0.1, "longDesc": "Used to calculate back transition distance in an auto mode.\nFor standard vtol and tiltrotors a controller is used to track this value during the transition.\n", "max": 10.0, "min": 0.5, "name": "VT_B_DEC_MSS", "shortDesc": "Approximate deceleration during back transition", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "decimalPlaces": 2, "default": 10.0, "group": "VTOL Attitude Control", "increment": 1.0, "longDesc": "Transition is also declared over if the groundspeed drops below MPC_XY_CRUISE.\n", "max": 20.0, "min": 0.1, "name": "VT_B_TRANS_DUR", "shortDesc": "Maximum duration of a back transition", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "VTOL Attitude Control", "increment": 0.1, "longDesc": "This sets the duration during which the MC motors ramp up to the commanded thrust during the back transition stage.\n", "max": 20.0, "min": 0.0, "name": "VT_B_TRANS_RAMP", "shortDesc": "Back transition MC motor ramp up time", "type": "Float", "units": "s"}, {"category": "Standard", "default": 1, "group": "VTOL Attitude Control", "longDesc": "If set to 1 the control surfaces are locked at the disarmed value in multicopter mode.\n", "name": "VT_ELEV_MC_LOCK", "shortDesc": "Lock control surfaces in hover", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "VTOL Attitude Control", "longDesc": "Prevents downforce from pitching the body down when facing wind.\nUses puller/pusher (standard VTOL), or forward-tilt (tiltrotor VTOL) to accelerate forward instead.\nOnly active if demanded pitch is below VT_PITCH_MIN.\nUse VT_FWD_THRUST_SC to tune it.\nDescend mode is treated as Landing too.\n\nOnly active (if enabled) in height-rate controlled modes.\n", "name": "VT_FWD_THRUST_EN", "shortDesc": "Use fixed-wing actuation in hover to accelerate forward", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled (except LANDING)", "value": 1}, {"description": "Enabled if above MPC_LAND_ALT1", "value": 2}, {"description": "Enabled if above MPC_LAND_ALT2", "value": 3}, {"description": "Enabled constantly", "value": 4}, {"description": "Enabled if above MPC_LAND_ALT1 (except LANDING)", "value": 5}, {"description": "Enabled if above MPC_LAND_ALT2 (except LANDING)", "value": 6}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.7, "group": "VTOL Attitude Control", "increment": 0.01, "longDesc": "Scale applied to the demanded pitch (below VT_PITCH_MIN) to get the fixed-wing forward actuation in hover mode.\nEnabled via VT_FWD_THRUST_EN.\n", "max": 5.0, "min": 0.0, "name": "VT_FWD_THRUST_SC", "shortDesc": "Fixed-wing actuation thrust scale in hover", "type": "Float"}, {"bitmask": [{"description": "Yaw", "index": 0}, {"description": "Roll", "index": 1}, {"description": "Pitch", "index": 2}], "category": "Standard", "default": 0, "group": "VTOL Attitude Control", "longDesc": "Enable differential thrust separately for roll, pitch, yaw in forward (fixed-wing) mode.\nThe effectiveness of differential thrust around the corresponding axis can be\ntuned by setting VT_FW_DIFTHR_S_R / VT_FW_DIFTHR_S_P / VT_FW_DIFTHR_S_Y.\n", "max": 7, "min": 0, "name": "VT_FW_DIFTHR_EN", "shortDesc": "Differential thrust in forwards flight", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "VTOL Attitude Control", "increment": 0.1, "longDesc": "Differential thrust in forward flight is enabled via VT_FW_DIFTHR_EN.\n", "max": 2.0, "min": 0.0, "name": "VT_FW_DIFTHR_S_P", "shortDesc": "Pitch differential thrust factor in forward flight", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "VTOL Attitude Control", "increment": 0.1, "longDesc": "Differential thrust in forward flight is enabled via VT_FW_DIFTHR_EN.\n", "max": 2.0, "min": 0.0, "name": "VT_FW_DIFTHR_S_R", "shortDesc": "Roll differential thrust factor in forward flight", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "VTOL Attitude Control", "increment": 0.1, "longDesc": "Differential thrust in forward flight is enabled via VT_FW_DIFTHR_EN.\n", "max": 2.0, "min": 0.0, "name": "VT_FW_DIFTHR_S_Y", "shortDesc": "Yaw differential thrust factor in forward flight", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "VTOL Attitude Control", "increment": 1.0, "longDesc": "Minimum altitude for fixed-wing flight. When the vehicle is in fixed-wing mode\nand the altitude drops below this altitude (relative altitude above local origin),\nit will instantly switch back to MC mode and execute behavior defined in COM_QC_ACT.\n", "max": 200.0, "min": 0.0, "name": "VT_FW_MIN_ALT", "shortDesc": "Quad-chute altitude", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "VTOL Attitude Control", "increment": 1, "longDesc": "Maximum height above the ground (if available, otherwise above\nHome if available, otherwise above the local origin) where triggering a quad-chute is possible.\nAt high altitudes there is a big risk to deplete the battery and therefore crash if quad-chuting there.\n", "min": 0, "name": "VT_FW_QC_HMAX", "shortDesc": "Quad-chute maximum height", "type": "Int32", "units": "m"}, {"category": "Standard", "default": 0, "group": "VTOL Attitude Control", "longDesc": "Absolute pitch threshold for quad-chute triggering in FW mode.\nAbove this the vehicle will transition back to MC mode and execute behavior defined in COM_QC_ACT.\nSet to 0 do disable this threshold.\n", "max": 180, "min": 0, "name": "VT_FW_QC_P", "shortDesc": "Quad-chute max pitch threshold", "type": "Int32", "units": "deg"}, {"category": "Standard", "default": 0, "group": "VTOL Attitude Control", "longDesc": "Absolute roll threshold for quad-chute triggering in FW mode.\nAbove this the vehicle will transition back to MC mode and execute behavior defined in COM_QC_ACT.\nSet to 0 do disable this threshold.\n", "max": 180, "min": 0, "name": "VT_FW_QC_R", "shortDesc": "Quad-chute max roll threshold", "type": "Int32", "units": "deg"}, {"category": "Standard", "decimalPlaces": 2, "default": 5.0, "group": "VTOL Attitude Control", "increment": 1.0, "longDesc": "Time in seconds used for a transition\n", "max": 20.0, "min": 0.1, "name": "VT_F_TRANS_DUR", "shortDesc": "Duration of a front transition", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "VTOL Attitude Control", "increment": 0.01, "longDesc": "Scaled by the square root of the weight ratio (WEIGHT_GROSS / WEIGHT_BASE).\n", "max": 1.0, "min": 0.0, "name": "VT_F_TRANS_THR", "shortDesc": "Target throttle value for the transition to fixed-wing flight", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 1, "default": 6.0, "group": "VTOL Attitude Control", "increment": 0.5, "longDesc": "The duration of the front transition when there is no airspeed feedback available.\nWhen airspeed is used, transition timeout is declared if airspeed does not\nreach VT_ARSP_BLEND after this time.\n", "max": 30.0, "min": 1.0, "name": "VT_F_TR_OL_TM", "shortDesc": "Airspeed-less front transition time (open loop)", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "VTOL Attitude Control", "increment": 0.1, "longDesc": "Overrides VT_PITCH_MIN when the vehicle is in LAND mode (hovering).\nDuring landing it can be beneficial to reduce the pitch angle to reduce the generated lift in head wind.\n", "max": 45.0, "min": -10.0, "name": "VT_LND_PITCH_MIN", "shortDesc": "Minimum pitch angle during hover landing", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "VTOL Attitude Control", "increment": 0.1, "longDesc": "Any pitch setpoint below this value is translated to a forward force by the fixed-wing forward actuation if\nVT_FWD_TRHUST_EN is set.\n", "max": 45.0, "min": -10.0, "name": "VT_PITCH_MIN", "shortDesc": "Minimum pitch angle during hover", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.33, "group": "VTOL Attitude Control", "increment": 0.01, "longDesc": "Defines the slew rate of the puller/pusher throttle during transitions.\nZero will deactivate the slew rate limiting and thus produce an instant throttle\nrise to the transition throttle VT_F_TRANS_THR.\n", "min": 0.0, "name": "VT_PSHER_SLEW", "shortDesc": "Pusher throttle ramp up slew rate", "type": "Float", "units": "1/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "VTOL Attitude Control", "increment": 1.0, "longDesc": "Altitude error threshold for quad-chute triggering during fixed-wing flight.\nThe check is only active if altitude is controlled and the vehicle is below the current altitude reference.\nThe altitude error is relative to the highest altitude the vehicle has achieved since it has flown below the current\naltitude reference.\n\nSet to 0 do disable.\n", "max": 200.0, "min": 0.0, "name": "VT_QC_ALT_LOSS", "shortDesc": "Quad-chute uncommanded descent threshold", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 20.0, "group": "VTOL Attitude Control", "increment": 1.0, "longDesc": "Altitude loss threshold for quad-chute triggering during VTOL transition to fixed-wing flight\nin altitude-controlled flight modes.\nActive until 5s after completing transition to fixed-wing.\nIf the current altitude is more than this value below the altitude at the beginning of the\ntransition, it will instantly switch back to MC mode and execute behavior defined in COM_QC_ACT.\n\nSet to 0 do disable this threshold.\n", "max": 50.0, "min": 0.0, "name": "VT_QC_T_ALT_LOSS", "shortDesc": "Quad-chute transition altitude loss threshold", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "VTOL Attitude Control", "increment": 0.1, "max": 1.0, "min": -1.0, "name": "VT_SPOILER_MC_LD", "shortDesc": "Spoiler setting while landing (hover)", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "VTOL Attitude Control", "increment": 0.01, "max": 1.0, "min": 0.0, "name": "VT_TILT_FW", "shortDesc": "Normalized tilt in FW", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "VTOL Attitude Control", "increment": 0.01, "max": 1.0, "min": 0.0, "name": "VT_TILT_MC", "shortDesc": "Normalized tilt in Hover", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.4, "group": "VTOL Attitude Control", "increment": 0.01, "max": 1.0, "min": 0.0, "name": "VT_TILT_TRANS", "shortDesc": "Normalized tilt in transition to FW", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 2.0, "group": "VTOL Attitude Control", "increment": 0.1, "longDesc": "Minimum time in seconds for front transition.\n", "max": 20.0, "min": 0.0, "name": "VT_TRANS_MIN_TM", "shortDesc": "Front transition minimum time", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.5, "group": "VTOL Attitude Control", "increment": 0.01, "longDesc": "Time in seconds it takes to tilt form VT_TILT_TRANS to VT_TILT_FW.\n", "max": 5.0, "min": 0.1, "name": "VT_TRANS_P2_DUR", "shortDesc": "Duration of front transition phase 2", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 15.0, "group": "VTOL Attitude Control", "increment": 1.0, "longDesc": "Time in seconds after which transition will be cancelled.\n", "max": 30.0, "min": 0.1, "name": "VT_TRANS_TIMEOUT", "shortDesc": "Front transition timeout", "type": "Float", "units": "s"}, {"category": "Standard", "default": 0, "group": "VTOL Attitude Control", "max": 2, "min": 0, "name": "VT_TYPE", "rebootRequired": true, "shortDesc": "VTOL Type (Tailsitter=0, Tiltrotor=1, Standard=2)", "type": "Int32", "values": [{"description": "Tailsitter", "value": 0}, {"description": "Tiltrotor", "value": 1}, {"description": "Standard", "value": 2}]}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "VTOL Attitude Control", "increment": 0.01, "longDesc": "The desired gain to convert roll sp into yaw rate sp.\n", "max": 3.0, "min": 0.0, "name": "WV_GAIN", "shortDesc": "Weather-vane roll angle to yawrate", "type": "Float", "units": "Hz"}, {"category": "Standard", "decimalPlaces": 1, "default": 80.0, "group": "VTOL Takeoff", "increment": 1.0, "longDesc": "Altitude relative to home at which vehicle will loiter after front transition.\n", "max": 300.0, "min": 20.0, "name": "VTO_LOITER_ALT", "shortDesc": "VTOL Takeoff relative loiter altitude", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 4, "default": 0.02, "group": "Vision Target Estimator", "longDesc": "UAV velocity variance growth rate from acceleration noise (m^2/s^3), independent of update rate.\nHigher values follow measurements faster and reject fewer outliers.\n", "min": 0.0001, "name": "VTE_ACC_D_UNC", "shortDesc": "UAV acceleration white-noise power spectral density", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "Vision Target Estimator", "longDesc": "Target acceleration variance growth rate (m^2/s^5), independent of update rate. Moving-target builds only.\nHigher values track manoeuvres faster and reject fewer outliers.\n", "min": 0.01, "name": "VTE_ACC_T_UNC", "shortDesc": "Target acceleration random-walk process noise", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.1, "group": "Vision Target Estimator", "longDesc": "Initial absolute target-acceleration variance per axis (moving-target builds only).\nChanges apply at initialization/reset. Use VTE_ACC_T_UNC for ongoing manoeuvre tracking.\n", "min": 0.001, "name": "VTE_ACC_UNC_IN", "shortDesc": "Initial target absolute acceleration uncertainty", "type": "Float", "units": "(m/s^2)^2"}, {"bitmask": [{"description": "Target GNSS position (receiver on the target)", "index": 0}, {"description": "UAV GNSS velocity", "index": 1}, {"description": "Vision relative position", "index": 2}, {"description": "Mission land position (precision landing)", "index": 3}, {"description": "Target GNSS velocity (moving-target builds only)", "index": 4}, {"description": "Home position (precision takeoff)", "index": 5}], "category": "Standard", "default": 14, "group": "Vision Target Estimator", "longDesc": "Absolute target references (bits 0, 3, 5) require vehicle GNSS; their offset from vision is estimated as a bias.\nBit 0 overrides bits 3 and 5, which are ignored in moving-target builds.\n", "max": 63, "min": 0, "name": "VTE_AID_MASK", "shortDesc": "Integer bitmask controlling data fusion and aiding methods", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 4, "default": 0.001, "group": "Vision Target Estimator", "longDesc": "GNSS/vision position-bias variance growth rate (m^2/s), independent of update rate.\nHigher values track reference drift faster; lower values keep the bias steadier.\n", "min": 0.0001, "name": "VTE_BIAS_UNC", "shortDesc": "Bias random-walk process noise", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "Vision Target Estimator", "longDesc": "Maximum 3D difference between raw and filtered bias to finish averaging after GNSS-first startup.\nLower values require steadier samples. Requires 5 consecutive matches and at least 0.6 s, or VTE_BIA_AVG_TOUT.\nSet to 0 to disable averaging.\n", "min": 0.0, "name": "VTE_BIA_AVG_THR", "shortDesc": "Initial GNSS/vision bias averaging threshold", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Vision Target Estimator", "longDesc": "Maximum time to average the GNSS/vision bias when starting from GNSS position. Vision fusion waits meanwhile.\nIf GNSS expires, switch to vision with the filtered bias. Set to 0 to disable averaging.\n", "min": 0.0, "name": "VTE_BIA_AVG_TOUT", "shortDesc": "Initial GNSS/vision bias averaging timeout", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "Vision Target Estimator", "longDesc": "Initial GNSS/vision position-bias variance per axis. Higher values allow larger initial bias corrections.\nApplied at initialization/reset and bias activation. Use VTE_BIAS_UNC for ongoing drift.\n", "min": 0.001, "name": "VTE_BIA_UNC_IN", "shortDesc": "Initial GPS bias uncertainty", "type": "Float", "units": "m^2"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "Vision Target Estimator", "increment": 0.5, "longDesc": "Reset after this long without accepted position or yaw updates, tracked separately.\nVelocity updates do not prevent position resets.\n", "max": 50.0, "min": 0.1, "name": "VTE_BTOUT", "shortDesc": "Vision target timeout", "type": "Float", "units": "s"}, {"category": "Standard", "default": 1, "group": "Vision Target Estimator", "name": "VTE_EN", "rebootRequired": true, "shortDesc": "Vision Target Estimator module enable", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.07, "group": "Vision Target Estimator", "longDesc": "Minimum vision yaw noise; used only when reported noise is lower. Default: about 4 deg.\nLower values increase trust in yaw measurements and can cause control oscillations.\n", "min": 0.05, "name": "VTE_EVA_NOISE", "shortDesc": "Minimum standard deviation for vision yaw observations", "type": "Float", "units": "rad"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "Vision Target Estimator", "longDesc": "Minimum vision position noise; used only when reported noise is lower.\nIncrease to reduce trust in position measurements.\n", "min": 0.01, "name": "VTE_EVP_NOISE", "shortDesc": "Minimum standard deviation for vision relative-position observations", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.5, "group": "Vision Target Estimator", "longDesc": "Minimum GNSS position noise for target, mission or home aiding; used only when reported noise is lower.\nIncrease to reduce trust in position measurements.\n", "max": 10.0, "min": 0.01, "name": "VTE_GPS_P_NOISE", "shortDesc": "Minimum standard deviation for GPS position observations", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "Vision Target Estimator", "longDesc": "Minimum GNSS velocity noise; used only when reported noise is lower.\nIncrease to reduce trust in velocity measurements.\n", "max": 5.0, "min": 0.01, "name": "VTE_GPS_V_NOISE", "shortDesc": "Minimum standard deviation for GPS velocity observations", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Vision Target Estimator", "increment": 0.05, "longDesc": "Maximum raw measurement age allowed for fusion.\n", "max": 10.0, "min": 0.1, "name": "VTE_M_REC_TOUT", "shortDesc": "Measurement recent timeout", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.1, "group": "Vision Target Estimator", "increment": 0.01, "longDesc": "Maximum age of local position, velocity and antenna-offset corrections. GNSS-to-vision alignment may span the measurement recent timeout.\n", "max": 5.0, "min": 0.01, "name": "VTE_M_UPD_TOUT", "shortDesc": "Measurement updated timeout", "type": "Float", "units": "s"}, {"category": "Standard", "default": 1, "group": "Vision Target Estimator", "name": "VTE_POS_EN", "rebootRequired": true, "shortDesc": "Vision Target Estimator module enable position estimation", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 3.84, "group": "Vision Target Estimator", "longDesc": "Per-axis outlier gate for position and velocity measurements. Lower values reject more samples.\nFor Gaussian innovations, 3.84 rejects about 5% of valid samples; 6.63 rejects 1%.\n", "max": 10.83, "min": 0.46, "name": "VTE_POS_NIS_THRE", "shortDesc": "Normalized innovation squared threshold for the position estimator", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.5, "group": "Vision Target Estimator", "longDesc": "Minimum initial variance of the relative target position in x, y, and z direction.\nThe variance reported by the initializing observation is used if it is larger.\nApplied at initialization/reset and GNSS/vision bias activation.\n", "min": 0.001, "name": "VTE_POS_UNC_IN", "shortDesc": "Initial target and drone relative position uncertainty", "type": "Float", "units": "m^2"}, {"bitmask": [{"description": "precision landing", "index": 0}, {"description": "DEBUG, always active", "index": 1}, {"description": "precision takeoff", "index": 2}], "category": "Standard", "default": 1, "group": "Vision Target Estimator", "max": 7, "min": 0, "name": "VTE_TASK_MASK", "shortDesc": "Integer bitmask controlling the tasks of the target estimator", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 2, "default": 2.0, "group": "Vision Target Estimator", "increment": 0.25, "longDesc": "Maximum time without accepted position or yaw updates before that estimate becomes invalid.\nKeep below VTE_BTOUT.\n", "max": 50.0, "min": 0.1, "name": "VTE_TGT_TOUT", "shortDesc": "Target validity timeout", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.5, "group": "Vision Target Estimator", "longDesc": "Initial velocity variance per axis, applied separately to the UAV and moving target.\nChanges apply at initialization/reset.\n", "min": 0.001, "name": "VTE_VEL_UNC_IN", "shortDesc": "Initial target and drone relative velocity uncertainty", "type": "Float", "units": "(m/s)^2"}, {"category": "Standard", "decimalPlaces": 4, "default": 0.004, "group": "Vision Target Estimator", "longDesc": "Yaw-rate variance growth rate from acceleration noise (rad^2/s^3), independent of update rate.\nHigher values track heading changes faster; lower values smooth yaw more.\n", "min": 0.0, "name": "VTE_YAW_ACC_UNC", "shortDesc": "Yaw acceleration white-noise power spectral density", "type": "Float"}, {"category": "Standard", "default": 0, "group": "Vision Target Estimator", "name": "VTE_YAW_EN", "rebootRequired": true, "shortDesc": "Vision Target Estimator module enable orientation estimation", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 3.84, "group": "Vision Target Estimator", "longDesc": "Yaw outlier gate. Lower values reject more samples.\nFor Gaussian innovations, 3.84 rejects about 5% of valid samples; 6.63 rejects 1%.\n", "max": 10.83, "min": 0.46, "name": "VTE_YAW_NIS_THRE", "shortDesc": "Normalized innovation squared threshold for the orientation estimator", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "Vision Target Estimator", "longDesc": "Initial yaw variance (rad^2); also used for yaw-rate variance ((rad/s)^2).\nChanges apply at initialization/reset.\n", "min": 0.001, "name": "VTE_YAW_UNC_IN", "shortDesc": "Initial orientation uncertainty", "type": "Float"}, {"category": "System", "default": 0, "group": "Zenoh", "longDesc": "Set true (1) to start the Zenoh driver module (a.k.a the \"Zenoh-Pico Node\").\nSee https://docs.px4.io/main/en/middleware/zenoh and\nhttps://docs.px4.io/main/en/modules/modules_driver.html#zenoh\n\n", "name": "ZENOH_ENABLE", "rebootRequired": true, "shortDesc": "Enable Zenoh", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Miscellaneous", "max": 232, "min": 0, "name": "ZENOH_DOMAIN_ID", "shortDesc": "ROS2 RMW_ZENOH_CPP Domain id", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "Miscellaneous", "max": 1, "min": 0, "name": "ZENOH_PUB_CC", "rebootRequired": true, "shortDesc": "Zenoh publisher congestion control (global default)", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "Miscellaneous", "max": 1, "min": 0, "name": "ZENOH_PUB_EXPR", "rebootRequired": true, "shortDesc": "Zenoh publisher express mode (global default)", "type": "Int32"}, {"category": "Standard", "default": 5, "group": "Miscellaneous", "max": 7, "min": 1, "name": "ZENOH_PUB_PRIO", "rebootRequired": true, "shortDesc": "Zenoh publisher priority (global default)", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "Miscellaneous", "max": 1, "min": 0, "name": "ZENOH_PUB_REL", "rebootRequired": true, "shortDesc": "Zenoh publisher reliability (global default)", "type": "Int32"}], "translation": {"items": {"parameters": {"list": {"items": {"bitmask": {"list": {"key": "index", "translate": ["description"]}}, "values": {"list": {"key": "value", "translate": ["description"]}}}, "key": "name", "translate": ["shortDesc", "longDesc"], "translate-global": ["category", "group"]}}}}, "version": 1} \ No newline at end of file +{"parameters": [{"category": "Standard", "default": 0, "group": "ADSB", "longDesc": "Sets first 4 characters of a total of 8. Valid characters are A-Z, 0-9, \" \". Example \"PX4 \" -> 1347957792\nFor CALLSIGN shorter than 8 characters use the null terminator at the end '\\0'.\n", "name": "ADSB_CALLSIGN_1", "rebootRequired": true, "shortDesc": "First 4 characters of CALLSIGN", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "ADSB", "longDesc": "Sets second 4 characters of a total of 8. Valid characters are A-Z, 0-9, \" \" only. Example \"TEST\" -> 1413829460\nFor CALLSIGN shorter than 8 characters use the null terminator at the end '\\0'.\n", "name": "ADSB_CALLSIGN_2", "rebootRequired": true, "shortDesc": "Second 4 characters of CALLSIGN", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "ADSB", "longDesc": "Sets the vehicle emergency state\n", "max": 6, "min": 0, "name": "ADSB_EMERGC", "shortDesc": "ADSB-Out Emergency State", "type": "Int32", "values": [{"description": "NoEmergency", "value": 0}, {"description": "General", "value": 1}, {"description": "Medical", "value": 2}, {"description": "LowFuel", "value": 3}, {"description": "NoCommunications", "value": 4}, {"description": "Interference", "value": 5}, {"description": "Downed", "value": 6}]}, {"category": "Standard", "default": 14, "group": "ADSB", "longDesc": "Configure the emitter type of the vehicle.\n", "max": 19, "min": 0, "name": "ADSB_EMIT_TYPE", "rebootRequired": true, "shortDesc": "ADSB-Out Vehicle Emitter Type", "type": "Int32", "values": [{"description": "Unknown", "value": 0}, {"description": "Light", "value": 1}, {"description": "Small", "value": 2}, {"description": "Large", "value": 3}, {"description": "HighVortex", "value": 4}, {"description": "Heavy", "value": 5}, {"description": "Performance", "value": 6}, {"description": "Rotorcraft", "value": 7}, {"description": "RESERVED", "value": 8}, {"description": "Glider", "value": 9}, {"description": "LightAir", "value": 10}, {"description": "Parachute", "value": 11}, {"description": "UltraLight", "value": 12}, {"description": "RESERVED", "value": 13}, {"description": "UAV", "value": 14}, {"description": "Space", "value": 15}, {"description": "RESERVED", "value": 16}, {"description": "EmergencySurf", "value": 17}, {"description": "ServiceSurf", "value": 18}, {"description": "PointObstacle", "value": 19}]}, {"category": "Standard", "default": 0, "group": "ADSB", "longDesc": "Sets GPS lataral offset encoding\n", "max": 7, "min": 0, "name": "ADSB_GPS_OFF_LAT", "shortDesc": "ADSB-Out GPS Offset lat", "type": "Int32", "values": [{"description": "NoData", "value": 0}, {"description": "LatLeft2M", "value": 1}, {"description": "LatLeft4M", "value": 2}, {"description": "LatLeft6M", "value": 3}, {"description": "LatRight0M", "value": 4}, {"description": "LatRight2M", "value": 5}, {"description": "LatRight4M", "value": 6}, {"description": "LatRight6M", "value": 7}]}, {"category": "Standard", "default": 0, "group": "ADSB", "longDesc": "Sets GPS longitudinal offset encoding\n", "max": 1, "min": 0, "name": "ADSB_GPS_OFF_LON", "shortDesc": "ADSB-Out GPS Offset lon", "type": "Int32", "values": [{"description": "NoData", "value": 0}, {"description": "AppliedBySensor", "value": 1}]}, {"category": "Standard", "default": -1, "group": "ADSB", "longDesc": "Vehicle ICAO ID. Use -1 to disable.\n", "max": 16777215, "min": -1, "name": "ADSB_ICAO_ID", "rebootRequired": true, "shortDesc": "ADSB-Out ICAO ID", "type": "Int32"}, {"category": "Standard", "default": -1, "group": "ADSB", "longDesc": "Optional second ownship ICAO ID used to filter self-detections. Use -1 to disable.\n", "max": 16777215, "min": -1, "name": "ADSB_ICAO_ID_2", "rebootRequired": true, "shortDesc": "Secondary ownship ICAO ID", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "ADSB", "longDesc": "This vehicle is always tracked. Use 0 to disable.\n", "max": 16777215, "min": 0, "name": "ADSB_ICAO_SPECL", "shortDesc": "ADSB-In Special ICAO configuration", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "ADSB", "longDesc": "Enable Identification of Position feature\n", "name": "ADSB_IDENT", "shortDesc": "ADSB-Out Ident Configuration", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 1, "group": "ADSB", "longDesc": "Report the length and width of the vehicle in meters. In most cases, use '1' for the smallest vehicle size.\n", "max": 15, "min": 0, "name": "ADSB_LEN_WIDTH", "rebootRequired": true, "shortDesc": "ADSB-Out Vehicle Size Configuration", "type": "Int32", "values": [{"description": "SizeUnknown", "value": 0}, {"description": "Len15_Wid23", "value": 1}, {"description": "Len25_Wid28", "value": 2}, {"description": "Len25_Wid34", "value": 3}, {"description": "Len35_Wid33", "value": 4}, {"description": "Len35_Wid38", "value": 5}, {"description": "Len45_Wid39", "value": 6}, {"description": "Len45_Wid45", "value": 7}, {"description": "Len55_Wid45", "value": 8}, {"description": "Len55_Wid52", "value": 9}, {"description": "Len65_Wid59", "value": 10}, {"description": "Len65_Wid67", "value": 11}, {"description": "Len75_Wid72", "value": 12}, {"description": "Len75_Wid80", "value": 13}, {"description": "Len85_Wid80", "value": 14}, {"description": "Len85_Wid90", "value": 15}]}, {"category": "Standard", "default": 25, "group": "ADSB", "longDesc": "Change number of targets to track\n", "max": 50, "min": 0, "name": "ADSB_LIST_MAX", "rebootRequired": true, "shortDesc": "ADSB-In Vehicle List Size", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "ADSB", "longDesc": "Informs ADSB vehicles of this vehicle's max speed capability\n", "max": 6, "min": 0, "name": "ADSB_MAX_SPEED", "rebootRequired": true, "shortDesc": "ADSB-Out Vehicle Max Speed", "type": "Int32", "values": [{"description": "UnknownMaxSpeed", "value": 0}, {"description": "75Kts", "value": 1}, {"description": "150Kts", "value": 2}, {"description": "300Kts", "value": 3}, {"description": "600Kts", "value": 4}, {"description": "1200Kts", "value": 5}, {"description": "Over1200Kts", "value": 6}]}, {"category": "Standard", "default": 1200, "group": "ADSB", "longDesc": "This parameter defines the squawk code. Value should be between 0000 and 7777.\n", "max": 7777, "min": 0, "name": "ADSB_SQUAWK", "shortDesc": "ADSB-Out squawk code configuration", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Select what should be output on SIM Channel 1.\n\nThe default failsafe value is set according to the selected function:\n- 'Min' for ConstantMin\n- 'Max' for ConstantMax\n- 'Max' for Parachute\n- ('Max'+'Min')/2 for Servos\n- 'Disarmed' for the rest\n\n", "name": "PWM_MAIN_FUNC1", "shortDesc": "SIM Channel 1 Output Function", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Constant Min", "value": 1}, {"description": "Constant Max", "value": 2}, {"description": "Motor 1", "value": 101}, {"description": "Motor 2", "value": 102}, {"description": "Motor 3", "value": 103}, {"description": "Motor 4", "value": 104}, {"description": "Motor 5", "value": 105}, {"description": "Motor 6", "value": 106}, {"description": "Motor 7", "value": 107}, {"description": "Motor 8", "value": 108}, {"description": "Motor 9", "value": 109}, {"description": "Motor 10", "value": 110}, {"description": "Motor 11", "value": 111}, {"description": "Motor 12", "value": 112}, {"description": "Servo 1", "value": 201}, {"description": "Servo 2", "value": 202}, {"description": "Servo 3", "value": 203}, {"description": "Servo 4", "value": 204}, {"description": "Servo 5", "value": 205}, {"description": "Servo 6", "value": 206}, {"description": "Servo 7", "value": 207}, {"description": "Servo 8", "value": 208}, {"description": "Servo 9", "value": 209}, {"description": "Servo 10", "value": 210}, {"description": "Servo 11", "value": 211}, {"description": "Servo 12", "value": 212}, {"description": "Servo 13", "value": 213}, {"description": "Servo 14", "value": 214}, {"description": "Servo 15", "value": 215}, {"description": "Peripheral via Actuator Set 1", "value": 301}, {"description": "Peripheral via Actuator Set 2", "value": 302}, {"description": "Peripheral via Actuator Set 3", "value": 303}, {"description": "Peripheral via Actuator Set 4", "value": 304}, {"description": "Peripheral via Actuator Set 5", "value": 305}, {"description": "Peripheral via Actuator Set 6", "value": 306}, {"description": "Landing Gear", "value": 400}, {"description": "Parachute", "value": 401}, {"description": "RC Roll", "value": 402}, {"description": "RC Pitch", "value": 403}, {"description": "RC Throttle", "value": 404}, {"description": "RC Yaw", "value": 405}, {"description": "RC Flaps", "value": 406}, {"description": "RC AUX 1", "value": 407}, {"description": "RC AUX 2", "value": 408}, {"description": "RC AUX 3", "value": 409}, {"description": "RC AUX 4", "value": 410}, {"description": "RC AUX 5", "value": 411}, {"description": "RC AUX 6", "value": 412}, {"description": "Gimbal Roll", "value": 420}, {"description": "Gimbal Pitch", "value": 421}, {"description": "Gimbal Yaw", "value": 422}, {"description": "Gripper", "value": 430}, {"description": "Landing Gear Wheel", "value": 440}, {"description": "IC Engine Ignition", "value": 450}, {"description": "IC Engine Throttle", "value": 451}, {"description": "IC Engine Choke", "value": 452}, {"description": "IC Engine Starter", "value": 453}]}, {"category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Select what should be output on SIM Channel 10.\n\nThe default failsafe value is set according to the selected function:\n- 'Min' for ConstantMin\n- 'Max' for ConstantMax\n- 'Max' for Parachute\n- ('Max'+'Min')/2 for Servos\n- 'Disarmed' for the rest\n\n", "name": "PWM_MAIN_FUNC10", "shortDesc": "SIM Channel 10 Output Function", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Constant Min", "value": 1}, {"description": "Constant Max", "value": 2}, {"description": "Motor 1", "value": 101}, {"description": "Motor 2", "value": 102}, {"description": "Motor 3", "value": 103}, {"description": "Motor 4", "value": 104}, {"description": "Motor 5", "value": 105}, {"description": "Motor 6", "value": 106}, {"description": "Motor 7", "value": 107}, {"description": "Motor 8", "value": 108}, {"description": "Motor 9", "value": 109}, {"description": "Motor 10", "value": 110}, {"description": "Motor 11", "value": 111}, {"description": "Motor 12", "value": 112}, {"description": "Servo 1", "value": 201}, {"description": "Servo 2", "value": 202}, {"description": "Servo 3", "value": 203}, {"description": "Servo 4", "value": 204}, {"description": "Servo 5", "value": 205}, {"description": "Servo 6", "value": 206}, {"description": "Servo 7", "value": 207}, {"description": "Servo 8", "value": 208}, {"description": "Servo 9", "value": 209}, {"description": "Servo 10", "value": 210}, {"description": "Servo 11", "value": 211}, {"description": "Servo 12", "value": 212}, {"description": "Servo 13", "value": 213}, {"description": "Servo 14", "value": 214}, {"description": "Servo 15", "value": 215}, {"description": "Peripheral via Actuator Set 1", "value": 301}, {"description": "Peripheral via Actuator Set 2", "value": 302}, {"description": "Peripheral via Actuator Set 3", "value": 303}, {"description": "Peripheral via Actuator Set 4", "value": 304}, {"description": "Peripheral via Actuator Set 5", "value": 305}, {"description": "Peripheral via Actuator Set 6", "value": 306}, {"description": "Landing Gear", "value": 400}, {"description": "Parachute", "value": 401}, {"description": "RC Roll", "value": 402}, {"description": "RC Pitch", "value": 403}, {"description": "RC Throttle", "value": 404}, {"description": "RC Yaw", "value": 405}, {"description": "RC Flaps", "value": 406}, {"description": "RC AUX 1", "value": 407}, {"description": "RC AUX 2", "value": 408}, {"description": "RC AUX 3", "value": 409}, {"description": "RC AUX 4", "value": 410}, {"description": "RC AUX 5", "value": 411}, {"description": "RC AUX 6", "value": 412}, {"description": "Gimbal Roll", "value": 420}, {"description": "Gimbal Pitch", "value": 421}, {"description": "Gimbal Yaw", "value": 422}, {"description": "Gripper", "value": 430}, {"description": "Landing Gear Wheel", "value": 440}, {"description": "IC Engine Ignition", "value": 450}, {"description": "IC Engine Throttle", "value": 451}, {"description": "IC Engine Choke", "value": 452}, {"description": "IC Engine Starter", "value": 453}]}, {"category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Select what should be output on SIM Channel 11.\n\nThe default failsafe value is set according to the selected function:\n- 'Min' for ConstantMin\n- 'Max' for ConstantMax\n- 'Max' for Parachute\n- ('Max'+'Min')/2 for Servos\n- 'Disarmed' for the rest\n\n", "name": "PWM_MAIN_FUNC11", "shortDesc": "SIM Channel 11 Output Function", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Constant Min", "value": 1}, {"description": "Constant Max", "value": 2}, {"description": "Motor 1", "value": 101}, {"description": "Motor 2", "value": 102}, {"description": "Motor 3", "value": 103}, {"description": "Motor 4", "value": 104}, {"description": "Motor 5", "value": 105}, {"description": "Motor 6", "value": 106}, {"description": "Motor 7", "value": 107}, {"description": "Motor 8", "value": 108}, {"description": "Motor 9", "value": 109}, {"description": "Motor 10", "value": 110}, {"description": "Motor 11", "value": 111}, {"description": "Motor 12", "value": 112}, {"description": "Servo 1", "value": 201}, {"description": "Servo 2", "value": 202}, {"description": "Servo 3", "value": 203}, {"description": "Servo 4", "value": 204}, {"description": "Servo 5", "value": 205}, {"description": "Servo 6", "value": 206}, {"description": "Servo 7", "value": 207}, {"description": "Servo 8", "value": 208}, {"description": "Servo 9", "value": 209}, {"description": "Servo 10", "value": 210}, {"description": "Servo 11", "value": 211}, {"description": "Servo 12", "value": 212}, {"description": "Servo 13", "value": 213}, {"description": "Servo 14", "value": 214}, {"description": "Servo 15", "value": 215}, {"description": "Peripheral via Actuator Set 1", "value": 301}, {"description": "Peripheral via Actuator Set 2", "value": 302}, {"description": "Peripheral via Actuator Set 3", "value": 303}, {"description": "Peripheral via Actuator Set 4", "value": 304}, {"description": "Peripheral via Actuator Set 5", "value": 305}, {"description": "Peripheral via Actuator Set 6", "value": 306}, {"description": "Landing Gear", "value": 400}, {"description": "Parachute", "value": 401}, {"description": "RC Roll", "value": 402}, {"description": "RC Pitch", "value": 403}, {"description": "RC Throttle", "value": 404}, {"description": "RC Yaw", "value": 405}, {"description": "RC Flaps", "value": 406}, {"description": "RC AUX 1", "value": 407}, {"description": "RC AUX 2", "value": 408}, {"description": "RC AUX 3", "value": 409}, {"description": "RC AUX 4", "value": 410}, {"description": "RC AUX 5", "value": 411}, {"description": "RC AUX 6", "value": 412}, {"description": "Gimbal Roll", "value": 420}, {"description": "Gimbal Pitch", "value": 421}, {"description": "Gimbal Yaw", "value": 422}, {"description": "Gripper", "value": 430}, {"description": "Landing Gear Wheel", "value": 440}, {"description": "IC Engine Ignition", "value": 450}, {"description": "IC Engine Throttle", "value": 451}, {"description": "IC Engine Choke", "value": 452}, {"description": "IC Engine Starter", "value": 453}]}, {"category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Select what should be output on SIM Channel 12.\n\nThe default failsafe value is set according to the selected function:\n- 'Min' for ConstantMin\n- 'Max' for ConstantMax\n- 'Max' for Parachute\n- ('Max'+'Min')/2 for Servos\n- 'Disarmed' for the rest\n\n", "name": "PWM_MAIN_FUNC12", "shortDesc": "SIM Channel 12 Output Function", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Constant Min", "value": 1}, {"description": "Constant Max", "value": 2}, {"description": "Motor 1", "value": 101}, {"description": "Motor 2", "value": 102}, {"description": "Motor 3", "value": 103}, {"description": "Motor 4", "value": 104}, {"description": "Motor 5", "value": 105}, {"description": "Motor 6", "value": 106}, {"description": "Motor 7", "value": 107}, {"description": "Motor 8", "value": 108}, {"description": "Motor 9", "value": 109}, {"description": "Motor 10", "value": 110}, {"description": "Motor 11", "value": 111}, {"description": "Motor 12", "value": 112}, {"description": "Servo 1", "value": 201}, {"description": "Servo 2", "value": 202}, {"description": "Servo 3", "value": 203}, {"description": "Servo 4", "value": 204}, {"description": "Servo 5", "value": 205}, {"description": "Servo 6", "value": 206}, {"description": "Servo 7", "value": 207}, {"description": "Servo 8", "value": 208}, {"description": "Servo 9", "value": 209}, {"description": "Servo 10", "value": 210}, {"description": "Servo 11", "value": 211}, {"description": "Servo 12", "value": 212}, {"description": "Servo 13", "value": 213}, {"description": "Servo 14", "value": 214}, {"description": "Servo 15", "value": 215}, {"description": "Peripheral via Actuator Set 1", "value": 301}, {"description": "Peripheral via Actuator Set 2", "value": 302}, {"description": "Peripheral via Actuator Set 3", "value": 303}, {"description": "Peripheral via Actuator Set 4", "value": 304}, {"description": "Peripheral via Actuator Set 5", "value": 305}, {"description": "Peripheral via Actuator Set 6", "value": 306}, {"description": "Landing Gear", "value": 400}, {"description": "Parachute", "value": 401}, {"description": "RC Roll", "value": 402}, {"description": "RC Pitch", "value": 403}, {"description": "RC Throttle", "value": 404}, {"description": "RC Yaw", "value": 405}, {"description": "RC Flaps", "value": 406}, {"description": "RC AUX 1", "value": 407}, {"description": "RC AUX 2", "value": 408}, {"description": "RC AUX 3", "value": 409}, {"description": "RC AUX 4", "value": 410}, {"description": "RC AUX 5", "value": 411}, {"description": "RC AUX 6", "value": 412}, {"description": "Gimbal Roll", "value": 420}, {"description": "Gimbal Pitch", "value": 421}, {"description": "Gimbal Yaw", "value": 422}, {"description": "Gripper", "value": 430}, {"description": "Landing Gear Wheel", "value": 440}, {"description": "IC Engine Ignition", "value": 450}, {"description": "IC Engine Throttle", "value": 451}, {"description": "IC Engine Choke", "value": 452}, {"description": "IC Engine Starter", "value": 453}]}, {"category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Select what should be output on SIM Channel 13.\n\nThe default failsafe value is set according to the selected function:\n- 'Min' for ConstantMin\n- 'Max' for ConstantMax\n- 'Max' for Parachute\n- ('Max'+'Min')/2 for Servos\n- 'Disarmed' for the rest\n\n", "name": "PWM_MAIN_FUNC13", "shortDesc": "SIM Channel 13 Output Function", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Constant Min", "value": 1}, {"description": "Constant Max", "value": 2}, {"description": "Motor 1", "value": 101}, {"description": "Motor 2", "value": 102}, {"description": "Motor 3", "value": 103}, {"description": "Motor 4", "value": 104}, {"description": "Motor 5", "value": 105}, {"description": "Motor 6", "value": 106}, {"description": "Motor 7", "value": 107}, {"description": "Motor 8", "value": 108}, {"description": "Motor 9", "value": 109}, {"description": "Motor 10", "value": 110}, {"description": "Motor 11", "value": 111}, {"description": "Motor 12", "value": 112}, {"description": "Servo 1", "value": 201}, {"description": "Servo 2", "value": 202}, {"description": "Servo 3", "value": 203}, {"description": "Servo 4", "value": 204}, {"description": "Servo 5", "value": 205}, {"description": "Servo 6", "value": 206}, {"description": "Servo 7", "value": 207}, {"description": "Servo 8", "value": 208}, {"description": "Servo 9", "value": 209}, {"description": "Servo 10", "value": 210}, {"description": "Servo 11", "value": 211}, {"description": "Servo 12", "value": 212}, {"description": "Servo 13", "value": 213}, {"description": "Servo 14", "value": 214}, {"description": "Servo 15", "value": 215}, {"description": "Peripheral via Actuator Set 1", "value": 301}, {"description": "Peripheral via Actuator Set 2", "value": 302}, {"description": "Peripheral via Actuator Set 3", "value": 303}, {"description": "Peripheral via Actuator Set 4", "value": 304}, {"description": "Peripheral via Actuator Set 5", "value": 305}, {"description": "Peripheral via Actuator Set 6", "value": 306}, {"description": "Landing Gear", "value": 400}, {"description": "Parachute", "value": 401}, {"description": "RC Roll", "value": 402}, {"description": "RC Pitch", "value": 403}, {"description": "RC Throttle", "value": 404}, {"description": "RC Yaw", "value": 405}, {"description": "RC Flaps", "value": 406}, {"description": "RC AUX 1", "value": 407}, {"description": "RC AUX 2", "value": 408}, {"description": "RC AUX 3", "value": 409}, {"description": "RC AUX 4", "value": 410}, {"description": "RC AUX 5", "value": 411}, {"description": "RC AUX 6", "value": 412}, {"description": "Gimbal Roll", "value": 420}, {"description": "Gimbal Pitch", "value": 421}, {"description": "Gimbal Yaw", "value": 422}, {"description": "Gripper", "value": 430}, {"description": "Landing Gear Wheel", "value": 440}, {"description": "IC Engine Ignition", "value": 450}, {"description": "IC Engine Throttle", "value": 451}, {"description": "IC Engine Choke", "value": 452}, {"description": "IC Engine Starter", "value": 453}]}, {"category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Select what should be output on SIM Channel 14.\n\nThe default failsafe value is set according to the selected function:\n- 'Min' for ConstantMin\n- 'Max' for ConstantMax\n- 'Max' for Parachute\n- ('Max'+'Min')/2 for Servos\n- 'Disarmed' for the rest\n\n", "name": "PWM_MAIN_FUNC14", "shortDesc": "SIM Channel 14 Output Function", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Constant Min", "value": 1}, {"description": "Constant Max", "value": 2}, {"description": "Motor 1", "value": 101}, {"description": "Motor 2", "value": 102}, {"description": "Motor 3", "value": 103}, {"description": "Motor 4", "value": 104}, {"description": "Motor 5", "value": 105}, {"description": "Motor 6", "value": 106}, {"description": "Motor 7", "value": 107}, {"description": "Motor 8", "value": 108}, {"description": "Motor 9", "value": 109}, {"description": "Motor 10", "value": 110}, {"description": "Motor 11", "value": 111}, {"description": "Motor 12", "value": 112}, {"description": "Servo 1", "value": 201}, {"description": "Servo 2", "value": 202}, {"description": "Servo 3", "value": 203}, {"description": "Servo 4", "value": 204}, {"description": "Servo 5", "value": 205}, {"description": "Servo 6", "value": 206}, {"description": "Servo 7", "value": 207}, {"description": "Servo 8", "value": 208}, {"description": "Servo 9", "value": 209}, {"description": "Servo 10", "value": 210}, {"description": "Servo 11", "value": 211}, {"description": "Servo 12", "value": 212}, {"description": "Servo 13", "value": 213}, {"description": "Servo 14", "value": 214}, {"description": "Servo 15", "value": 215}, {"description": "Peripheral via Actuator Set 1", "value": 301}, {"description": "Peripheral via Actuator Set 2", "value": 302}, {"description": "Peripheral via Actuator Set 3", "value": 303}, {"description": "Peripheral via Actuator Set 4", "value": 304}, {"description": "Peripheral via Actuator Set 5", "value": 305}, {"description": "Peripheral via Actuator Set 6", "value": 306}, {"description": "Landing Gear", "value": 400}, {"description": "Parachute", "value": 401}, {"description": "RC Roll", "value": 402}, {"description": "RC Pitch", "value": 403}, {"description": "RC Throttle", "value": 404}, {"description": "RC Yaw", "value": 405}, {"description": "RC Flaps", "value": 406}, {"description": "RC AUX 1", "value": 407}, {"description": "RC AUX 2", "value": 408}, {"description": "RC AUX 3", "value": 409}, {"description": "RC AUX 4", "value": 410}, {"description": "RC AUX 5", "value": 411}, {"description": "RC AUX 6", "value": 412}, {"description": "Gimbal Roll", "value": 420}, {"description": "Gimbal Pitch", "value": 421}, {"description": "Gimbal Yaw", "value": 422}, {"description": "Gripper", "value": 430}, {"description": "Landing Gear Wheel", "value": 440}, {"description": "IC Engine Ignition", "value": 450}, {"description": "IC Engine Throttle", "value": 451}, {"description": "IC Engine Choke", "value": 452}, {"description": "IC Engine Starter", "value": 453}]}, {"category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Select what should be output on SIM Channel 15.\n\nThe default failsafe value is set according to the selected function:\n- 'Min' for ConstantMin\n- 'Max' for ConstantMax\n- 'Max' for Parachute\n- ('Max'+'Min')/2 for Servos\n- 'Disarmed' for the rest\n\n", "name": "PWM_MAIN_FUNC15", "shortDesc": "SIM Channel 15 Output Function", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Constant Min", "value": 1}, {"description": "Constant Max", "value": 2}, {"description": "Motor 1", "value": 101}, {"description": "Motor 2", "value": 102}, {"description": "Motor 3", "value": 103}, {"description": "Motor 4", "value": 104}, {"description": "Motor 5", "value": 105}, {"description": "Motor 6", "value": 106}, {"description": "Motor 7", "value": 107}, {"description": "Motor 8", "value": 108}, {"description": "Motor 9", "value": 109}, {"description": "Motor 10", "value": 110}, {"description": "Motor 11", "value": 111}, {"description": "Motor 12", "value": 112}, {"description": "Servo 1", "value": 201}, {"description": "Servo 2", "value": 202}, {"description": "Servo 3", "value": 203}, {"description": "Servo 4", "value": 204}, {"description": "Servo 5", "value": 205}, {"description": "Servo 6", "value": 206}, {"description": "Servo 7", "value": 207}, {"description": "Servo 8", "value": 208}, {"description": "Servo 9", "value": 209}, {"description": "Servo 10", "value": 210}, {"description": "Servo 11", "value": 211}, {"description": "Servo 12", "value": 212}, {"description": "Servo 13", "value": 213}, {"description": "Servo 14", "value": 214}, {"description": "Servo 15", "value": 215}, {"description": "Peripheral via Actuator Set 1", "value": 301}, {"description": "Peripheral via Actuator Set 2", "value": 302}, {"description": "Peripheral via Actuator Set 3", "value": 303}, {"description": "Peripheral via Actuator Set 4", "value": 304}, {"description": "Peripheral via Actuator Set 5", "value": 305}, {"description": "Peripheral via Actuator Set 6", "value": 306}, {"description": "Landing Gear", "value": 400}, {"description": "Parachute", "value": 401}, {"description": "RC Roll", "value": 402}, {"description": "RC Pitch", "value": 403}, {"description": "RC Throttle", "value": 404}, {"description": "RC Yaw", "value": 405}, {"description": "RC Flaps", "value": 406}, {"description": "RC AUX 1", "value": 407}, {"description": "RC AUX 2", "value": 408}, {"description": "RC AUX 3", "value": 409}, {"description": "RC AUX 4", "value": 410}, {"description": "RC AUX 5", "value": 411}, {"description": "RC AUX 6", "value": 412}, {"description": "Gimbal Roll", "value": 420}, {"description": "Gimbal Pitch", "value": 421}, {"description": "Gimbal Yaw", "value": 422}, {"description": "Gripper", "value": 430}, {"description": "Landing Gear Wheel", "value": 440}, {"description": "IC Engine Ignition", "value": 450}, {"description": "IC Engine Throttle", "value": 451}, {"description": "IC Engine Choke", "value": 452}, {"description": "IC Engine Starter", "value": 453}]}, {"category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Select what should be output on SIM Channel 16.\n\nThe default failsafe value is set according to the selected function:\n- 'Min' for ConstantMin\n- 'Max' for ConstantMax\n- 'Max' for Parachute\n- ('Max'+'Min')/2 for Servos\n- 'Disarmed' for the rest\n\n", "name": "PWM_MAIN_FUNC16", "shortDesc": "SIM Channel 16 Output Function", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Constant Min", "value": 1}, {"description": "Constant Max", "value": 2}, {"description": "Motor 1", "value": 101}, {"description": "Motor 2", "value": 102}, {"description": "Motor 3", "value": 103}, {"description": "Motor 4", "value": 104}, {"description": "Motor 5", "value": 105}, {"description": "Motor 6", "value": 106}, {"description": "Motor 7", "value": 107}, {"description": "Motor 8", "value": 108}, {"description": "Motor 9", "value": 109}, {"description": "Motor 10", "value": 110}, {"description": "Motor 11", "value": 111}, {"description": "Motor 12", "value": 112}, {"description": "Servo 1", "value": 201}, {"description": "Servo 2", "value": 202}, {"description": "Servo 3", "value": 203}, {"description": "Servo 4", "value": 204}, {"description": "Servo 5", "value": 205}, {"description": "Servo 6", "value": 206}, {"description": "Servo 7", "value": 207}, {"description": "Servo 8", "value": 208}, {"description": "Servo 9", "value": 209}, {"description": "Servo 10", "value": 210}, {"description": "Servo 11", "value": 211}, {"description": "Servo 12", "value": 212}, {"description": "Servo 13", "value": 213}, {"description": "Servo 14", "value": 214}, {"description": "Servo 15", "value": 215}, {"description": "Peripheral via Actuator Set 1", "value": 301}, {"description": "Peripheral via Actuator Set 2", "value": 302}, {"description": "Peripheral via Actuator Set 3", "value": 303}, {"description": "Peripheral via Actuator Set 4", "value": 304}, {"description": "Peripheral via Actuator Set 5", "value": 305}, {"description": "Peripheral via Actuator Set 6", "value": 306}, {"description": "Landing Gear", "value": 400}, {"description": "Parachute", "value": 401}, {"description": "RC Roll", "value": 402}, {"description": "RC Pitch", "value": 403}, {"description": "RC Throttle", "value": 404}, {"description": "RC Yaw", "value": 405}, {"description": "RC Flaps", "value": 406}, {"description": "RC AUX 1", "value": 407}, {"description": "RC AUX 2", "value": 408}, {"description": "RC AUX 3", "value": 409}, {"description": "RC AUX 4", "value": 410}, {"description": "RC AUX 5", "value": 411}, {"description": "RC AUX 6", "value": 412}, {"description": "Gimbal Roll", "value": 420}, {"description": "Gimbal Pitch", "value": 421}, {"description": "Gimbal Yaw", "value": 422}, {"description": "Gripper", "value": 430}, {"description": "Landing Gear Wheel", "value": 440}, {"description": "IC Engine Ignition", "value": 450}, {"description": "IC Engine Throttle", "value": 451}, {"description": "IC Engine Choke", "value": 452}, {"description": "IC Engine Starter", "value": 453}]}, {"category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Select what should be output on SIM Channel 2.\n\nThe default failsafe value is set according to the selected function:\n- 'Min' for ConstantMin\n- 'Max' for ConstantMax\n- 'Max' for Parachute\n- ('Max'+'Min')/2 for Servos\n- 'Disarmed' for the rest\n\n", "name": "PWM_MAIN_FUNC2", "shortDesc": "SIM Channel 2 Output Function", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Constant Min", "value": 1}, {"description": "Constant Max", "value": 2}, {"description": "Motor 1", "value": 101}, {"description": "Motor 2", "value": 102}, {"description": "Motor 3", "value": 103}, {"description": "Motor 4", "value": 104}, {"description": "Motor 5", "value": 105}, {"description": "Motor 6", "value": 106}, {"description": "Motor 7", "value": 107}, {"description": "Motor 8", "value": 108}, {"description": "Motor 9", "value": 109}, {"description": "Motor 10", "value": 110}, {"description": "Motor 11", "value": 111}, {"description": "Motor 12", "value": 112}, {"description": "Servo 1", "value": 201}, {"description": "Servo 2", "value": 202}, {"description": "Servo 3", "value": 203}, {"description": "Servo 4", "value": 204}, {"description": "Servo 5", "value": 205}, {"description": "Servo 6", "value": 206}, {"description": "Servo 7", "value": 207}, {"description": "Servo 8", "value": 208}, {"description": "Servo 9", "value": 209}, {"description": "Servo 10", "value": 210}, {"description": "Servo 11", "value": 211}, {"description": "Servo 12", "value": 212}, {"description": "Servo 13", "value": 213}, {"description": "Servo 14", "value": 214}, {"description": "Servo 15", "value": 215}, {"description": "Peripheral via Actuator Set 1", "value": 301}, {"description": "Peripheral via Actuator Set 2", "value": 302}, {"description": "Peripheral via Actuator Set 3", "value": 303}, {"description": "Peripheral via Actuator Set 4", "value": 304}, {"description": "Peripheral via Actuator Set 5", "value": 305}, {"description": "Peripheral via Actuator Set 6", "value": 306}, {"description": "Landing Gear", "value": 400}, {"description": "Parachute", "value": 401}, {"description": "RC Roll", "value": 402}, {"description": "RC Pitch", "value": 403}, {"description": "RC Throttle", "value": 404}, {"description": "RC Yaw", "value": 405}, {"description": "RC Flaps", "value": 406}, {"description": "RC AUX 1", "value": 407}, {"description": "RC AUX 2", "value": 408}, {"description": "RC AUX 3", "value": 409}, {"description": "RC AUX 4", "value": 410}, {"description": "RC AUX 5", "value": 411}, {"description": "RC AUX 6", "value": 412}, {"description": "Gimbal Roll", "value": 420}, {"description": "Gimbal Pitch", "value": 421}, {"description": "Gimbal Yaw", "value": 422}, {"description": "Gripper", "value": 430}, {"description": "Landing Gear Wheel", "value": 440}, {"description": "IC Engine Ignition", "value": 450}, {"description": "IC Engine Throttle", "value": 451}, {"description": "IC Engine Choke", "value": 452}, {"description": "IC Engine Starter", "value": 453}]}, {"category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Select what should be output on SIM Channel 3.\n\nThe default failsafe value is set according to the selected function:\n- 'Min' for ConstantMin\n- 'Max' for ConstantMax\n- 'Max' for Parachute\n- ('Max'+'Min')/2 for Servos\n- 'Disarmed' for the rest\n\n", "name": "PWM_MAIN_FUNC3", "shortDesc": "SIM Channel 3 Output Function", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Constant Min", "value": 1}, {"description": "Constant Max", "value": 2}, {"description": "Motor 1", "value": 101}, {"description": "Motor 2", "value": 102}, {"description": "Motor 3", "value": 103}, {"description": "Motor 4", "value": 104}, {"description": "Motor 5", "value": 105}, {"description": "Motor 6", "value": 106}, {"description": "Motor 7", "value": 107}, {"description": "Motor 8", "value": 108}, {"description": "Motor 9", "value": 109}, {"description": "Motor 10", "value": 110}, {"description": "Motor 11", "value": 111}, {"description": "Motor 12", "value": 112}, {"description": "Servo 1", "value": 201}, {"description": "Servo 2", "value": 202}, {"description": "Servo 3", "value": 203}, {"description": "Servo 4", "value": 204}, {"description": "Servo 5", "value": 205}, {"description": "Servo 6", "value": 206}, {"description": "Servo 7", "value": 207}, {"description": "Servo 8", "value": 208}, {"description": "Servo 9", "value": 209}, {"description": "Servo 10", "value": 210}, {"description": "Servo 11", "value": 211}, {"description": "Servo 12", "value": 212}, {"description": "Servo 13", "value": 213}, {"description": "Servo 14", "value": 214}, {"description": "Servo 15", "value": 215}, {"description": "Peripheral via Actuator Set 1", "value": 301}, {"description": "Peripheral via Actuator Set 2", "value": 302}, {"description": "Peripheral via Actuator Set 3", "value": 303}, {"description": "Peripheral via Actuator Set 4", "value": 304}, {"description": "Peripheral via Actuator Set 5", "value": 305}, {"description": "Peripheral via Actuator Set 6", "value": 306}, {"description": "Landing Gear", "value": 400}, {"description": "Parachute", "value": 401}, {"description": "RC Roll", "value": 402}, {"description": "RC Pitch", "value": 403}, {"description": "RC Throttle", "value": 404}, {"description": "RC Yaw", "value": 405}, {"description": "RC Flaps", "value": 406}, {"description": "RC AUX 1", "value": 407}, {"description": "RC AUX 2", "value": 408}, {"description": "RC AUX 3", "value": 409}, {"description": "RC AUX 4", "value": 410}, {"description": "RC AUX 5", "value": 411}, {"description": "RC AUX 6", "value": 412}, {"description": "Gimbal Roll", "value": 420}, {"description": "Gimbal Pitch", "value": 421}, {"description": "Gimbal Yaw", "value": 422}, {"description": "Gripper", "value": 430}, {"description": "Landing Gear Wheel", "value": 440}, {"description": "IC Engine Ignition", "value": 450}, {"description": "IC Engine Throttle", "value": 451}, {"description": "IC Engine Choke", "value": 452}, {"description": "IC Engine Starter", "value": 453}]}, {"category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Select what should be output on SIM Channel 4.\n\nThe default failsafe value is set according to the selected function:\n- 'Min' for ConstantMin\n- 'Max' for ConstantMax\n- 'Max' for Parachute\n- ('Max'+'Min')/2 for Servos\n- 'Disarmed' for the rest\n\n", "name": "PWM_MAIN_FUNC4", "shortDesc": "SIM Channel 4 Output Function", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Constant Min", "value": 1}, {"description": "Constant Max", "value": 2}, {"description": "Motor 1", "value": 101}, {"description": "Motor 2", "value": 102}, {"description": "Motor 3", "value": 103}, {"description": "Motor 4", "value": 104}, {"description": "Motor 5", "value": 105}, {"description": "Motor 6", "value": 106}, {"description": "Motor 7", "value": 107}, {"description": "Motor 8", "value": 108}, {"description": "Motor 9", "value": 109}, {"description": "Motor 10", "value": 110}, {"description": "Motor 11", "value": 111}, {"description": "Motor 12", "value": 112}, {"description": "Servo 1", "value": 201}, {"description": "Servo 2", "value": 202}, {"description": "Servo 3", "value": 203}, {"description": "Servo 4", "value": 204}, {"description": "Servo 5", "value": 205}, {"description": "Servo 6", "value": 206}, {"description": "Servo 7", "value": 207}, {"description": "Servo 8", "value": 208}, {"description": "Servo 9", "value": 209}, {"description": "Servo 10", "value": 210}, {"description": "Servo 11", "value": 211}, {"description": "Servo 12", "value": 212}, {"description": "Servo 13", "value": 213}, {"description": "Servo 14", "value": 214}, {"description": "Servo 15", "value": 215}, {"description": "Peripheral via Actuator Set 1", "value": 301}, {"description": "Peripheral via Actuator Set 2", "value": 302}, {"description": "Peripheral via Actuator Set 3", "value": 303}, {"description": "Peripheral via Actuator Set 4", "value": 304}, {"description": "Peripheral via Actuator Set 5", "value": 305}, {"description": "Peripheral via Actuator Set 6", "value": 306}, {"description": "Landing Gear", "value": 400}, {"description": "Parachute", "value": 401}, {"description": "RC Roll", "value": 402}, {"description": "RC Pitch", "value": 403}, {"description": "RC Throttle", "value": 404}, {"description": "RC Yaw", "value": 405}, {"description": "RC Flaps", "value": 406}, {"description": "RC AUX 1", "value": 407}, {"description": "RC AUX 2", "value": 408}, {"description": "RC AUX 3", "value": 409}, {"description": "RC AUX 4", "value": 410}, {"description": "RC AUX 5", "value": 411}, {"description": "RC AUX 6", "value": 412}, {"description": "Gimbal Roll", "value": 420}, {"description": "Gimbal Pitch", "value": 421}, {"description": "Gimbal Yaw", "value": 422}, {"description": "Gripper", "value": 430}, {"description": "Landing Gear Wheel", "value": 440}, {"description": "IC Engine Ignition", "value": 450}, {"description": "IC Engine Throttle", "value": 451}, {"description": "IC Engine Choke", "value": 452}, {"description": "IC Engine Starter", "value": 453}]}, {"category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Select what should be output on SIM Channel 5.\n\nThe default failsafe value is set according to the selected function:\n- 'Min' for ConstantMin\n- 'Max' for ConstantMax\n- 'Max' for Parachute\n- ('Max'+'Min')/2 for Servos\n- 'Disarmed' for the rest\n\n", "name": "PWM_MAIN_FUNC5", "shortDesc": "SIM Channel 5 Output Function", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Constant Min", "value": 1}, {"description": "Constant Max", "value": 2}, {"description": "Motor 1", "value": 101}, {"description": "Motor 2", "value": 102}, {"description": "Motor 3", "value": 103}, {"description": "Motor 4", "value": 104}, {"description": "Motor 5", "value": 105}, {"description": "Motor 6", "value": 106}, {"description": "Motor 7", "value": 107}, {"description": "Motor 8", "value": 108}, {"description": "Motor 9", "value": 109}, {"description": "Motor 10", "value": 110}, {"description": "Motor 11", "value": 111}, {"description": "Motor 12", "value": 112}, {"description": "Servo 1", "value": 201}, {"description": "Servo 2", "value": 202}, {"description": "Servo 3", "value": 203}, {"description": "Servo 4", "value": 204}, {"description": "Servo 5", "value": 205}, {"description": "Servo 6", "value": 206}, {"description": "Servo 7", "value": 207}, {"description": "Servo 8", "value": 208}, {"description": "Servo 9", "value": 209}, {"description": "Servo 10", "value": 210}, {"description": "Servo 11", "value": 211}, {"description": "Servo 12", "value": 212}, {"description": "Servo 13", "value": 213}, {"description": "Servo 14", "value": 214}, {"description": "Servo 15", "value": 215}, {"description": "Peripheral via Actuator Set 1", "value": 301}, {"description": "Peripheral via Actuator Set 2", "value": 302}, {"description": "Peripheral via Actuator Set 3", "value": 303}, {"description": "Peripheral via Actuator Set 4", "value": 304}, {"description": "Peripheral via Actuator Set 5", "value": 305}, {"description": "Peripheral via Actuator Set 6", "value": 306}, {"description": "Landing Gear", "value": 400}, {"description": "Parachute", "value": 401}, {"description": "RC Roll", "value": 402}, {"description": "RC Pitch", "value": 403}, {"description": "RC Throttle", "value": 404}, {"description": "RC Yaw", "value": 405}, {"description": "RC Flaps", "value": 406}, {"description": "RC AUX 1", "value": 407}, {"description": "RC AUX 2", "value": 408}, {"description": "RC AUX 3", "value": 409}, {"description": "RC AUX 4", "value": 410}, {"description": "RC AUX 5", "value": 411}, {"description": "RC AUX 6", "value": 412}, {"description": "Gimbal Roll", "value": 420}, {"description": "Gimbal Pitch", "value": 421}, {"description": "Gimbal Yaw", "value": 422}, {"description": "Gripper", "value": 430}, {"description": "Landing Gear Wheel", "value": 440}, {"description": "IC Engine Ignition", "value": 450}, {"description": "IC Engine Throttle", "value": 451}, {"description": "IC Engine Choke", "value": 452}, {"description": "IC Engine Starter", "value": 453}]}, {"category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Select what should be output on SIM Channel 6.\n\nThe default failsafe value is set according to the selected function:\n- 'Min' for ConstantMin\n- 'Max' for ConstantMax\n- 'Max' for Parachute\n- ('Max'+'Min')/2 for Servos\n- 'Disarmed' for the rest\n\n", "name": "PWM_MAIN_FUNC6", "shortDesc": "SIM Channel 6 Output Function", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Constant Min", "value": 1}, {"description": "Constant Max", "value": 2}, {"description": "Motor 1", "value": 101}, {"description": "Motor 2", "value": 102}, {"description": "Motor 3", "value": 103}, {"description": "Motor 4", "value": 104}, {"description": "Motor 5", "value": 105}, {"description": "Motor 6", "value": 106}, {"description": "Motor 7", "value": 107}, {"description": "Motor 8", "value": 108}, {"description": "Motor 9", "value": 109}, {"description": "Motor 10", "value": 110}, {"description": "Motor 11", "value": 111}, {"description": "Motor 12", "value": 112}, {"description": "Servo 1", "value": 201}, {"description": "Servo 2", "value": 202}, {"description": "Servo 3", "value": 203}, {"description": "Servo 4", "value": 204}, {"description": "Servo 5", "value": 205}, {"description": "Servo 6", "value": 206}, {"description": "Servo 7", "value": 207}, {"description": "Servo 8", "value": 208}, {"description": "Servo 9", "value": 209}, {"description": "Servo 10", "value": 210}, {"description": "Servo 11", "value": 211}, {"description": "Servo 12", "value": 212}, {"description": "Servo 13", "value": 213}, {"description": "Servo 14", "value": 214}, {"description": "Servo 15", "value": 215}, {"description": "Peripheral via Actuator Set 1", "value": 301}, {"description": "Peripheral via Actuator Set 2", "value": 302}, {"description": "Peripheral via Actuator Set 3", "value": 303}, {"description": "Peripheral via Actuator Set 4", "value": 304}, {"description": "Peripheral via Actuator Set 5", "value": 305}, {"description": "Peripheral via Actuator Set 6", "value": 306}, {"description": "Landing Gear", "value": 400}, {"description": "Parachute", "value": 401}, {"description": "RC Roll", "value": 402}, {"description": "RC Pitch", "value": 403}, {"description": "RC Throttle", "value": 404}, {"description": "RC Yaw", "value": 405}, {"description": "RC Flaps", "value": 406}, {"description": "RC AUX 1", "value": 407}, {"description": "RC AUX 2", "value": 408}, {"description": "RC AUX 3", "value": 409}, {"description": "RC AUX 4", "value": 410}, {"description": "RC AUX 5", "value": 411}, {"description": "RC AUX 6", "value": 412}, {"description": "Gimbal Roll", "value": 420}, {"description": "Gimbal Pitch", "value": 421}, {"description": "Gimbal Yaw", "value": 422}, {"description": "Gripper", "value": 430}, {"description": "Landing Gear Wheel", "value": 440}, {"description": "IC Engine Ignition", "value": 450}, {"description": "IC Engine Throttle", "value": 451}, {"description": "IC Engine Choke", "value": 452}, {"description": "IC Engine Starter", "value": 453}]}, {"category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Select what should be output on SIM Channel 7.\n\nThe default failsafe value is set according to the selected function:\n- 'Min' for ConstantMin\n- 'Max' for ConstantMax\n- 'Max' for Parachute\n- ('Max'+'Min')/2 for Servos\n- 'Disarmed' for the rest\n\n", "name": "PWM_MAIN_FUNC7", "shortDesc": "SIM Channel 7 Output Function", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Constant Min", "value": 1}, {"description": "Constant Max", "value": 2}, {"description": "Motor 1", "value": 101}, {"description": "Motor 2", "value": 102}, {"description": "Motor 3", "value": 103}, {"description": "Motor 4", "value": 104}, {"description": "Motor 5", "value": 105}, {"description": "Motor 6", "value": 106}, {"description": "Motor 7", "value": 107}, {"description": "Motor 8", "value": 108}, {"description": "Motor 9", "value": 109}, {"description": "Motor 10", "value": 110}, {"description": "Motor 11", "value": 111}, {"description": "Motor 12", "value": 112}, {"description": "Servo 1", "value": 201}, {"description": "Servo 2", "value": 202}, {"description": "Servo 3", "value": 203}, {"description": "Servo 4", "value": 204}, {"description": "Servo 5", "value": 205}, {"description": "Servo 6", "value": 206}, {"description": "Servo 7", "value": 207}, {"description": "Servo 8", "value": 208}, {"description": "Servo 9", "value": 209}, {"description": "Servo 10", "value": 210}, {"description": "Servo 11", "value": 211}, {"description": "Servo 12", "value": 212}, {"description": "Servo 13", "value": 213}, {"description": "Servo 14", "value": 214}, {"description": "Servo 15", "value": 215}, {"description": "Peripheral via Actuator Set 1", "value": 301}, {"description": "Peripheral via Actuator Set 2", "value": 302}, {"description": "Peripheral via Actuator Set 3", "value": 303}, {"description": "Peripheral via Actuator Set 4", "value": 304}, {"description": "Peripheral via Actuator Set 5", "value": 305}, {"description": "Peripheral via Actuator Set 6", "value": 306}, {"description": "Landing Gear", "value": 400}, {"description": "Parachute", "value": 401}, {"description": "RC Roll", "value": 402}, {"description": "RC Pitch", "value": 403}, {"description": "RC Throttle", "value": 404}, {"description": "RC Yaw", "value": 405}, {"description": "RC Flaps", "value": 406}, {"description": "RC AUX 1", "value": 407}, {"description": "RC AUX 2", "value": 408}, {"description": "RC AUX 3", "value": 409}, {"description": "RC AUX 4", "value": 410}, {"description": "RC AUX 5", "value": 411}, {"description": "RC AUX 6", "value": 412}, {"description": "Gimbal Roll", "value": 420}, {"description": "Gimbal Pitch", "value": 421}, {"description": "Gimbal Yaw", "value": 422}, {"description": "Gripper", "value": 430}, {"description": "Landing Gear Wheel", "value": 440}, {"description": "IC Engine Ignition", "value": 450}, {"description": "IC Engine Throttle", "value": 451}, {"description": "IC Engine Choke", "value": 452}, {"description": "IC Engine Starter", "value": 453}]}, {"category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Select what should be output on SIM Channel 8.\n\nThe default failsafe value is set according to the selected function:\n- 'Min' for ConstantMin\n- 'Max' for ConstantMax\n- 'Max' for Parachute\n- ('Max'+'Min')/2 for Servos\n- 'Disarmed' for the rest\n\n", "name": "PWM_MAIN_FUNC8", "shortDesc": "SIM Channel 8 Output Function", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Constant Min", "value": 1}, {"description": "Constant Max", "value": 2}, {"description": "Motor 1", "value": 101}, {"description": "Motor 2", "value": 102}, {"description": "Motor 3", "value": 103}, {"description": "Motor 4", "value": 104}, {"description": "Motor 5", "value": 105}, {"description": "Motor 6", "value": 106}, {"description": "Motor 7", "value": 107}, {"description": "Motor 8", "value": 108}, {"description": "Motor 9", "value": 109}, {"description": "Motor 10", "value": 110}, {"description": "Motor 11", "value": 111}, {"description": "Motor 12", "value": 112}, {"description": "Servo 1", "value": 201}, {"description": "Servo 2", "value": 202}, {"description": "Servo 3", "value": 203}, {"description": "Servo 4", "value": 204}, {"description": "Servo 5", "value": 205}, {"description": "Servo 6", "value": 206}, {"description": "Servo 7", "value": 207}, {"description": "Servo 8", "value": 208}, {"description": "Servo 9", "value": 209}, {"description": "Servo 10", "value": 210}, {"description": "Servo 11", "value": 211}, {"description": "Servo 12", "value": 212}, {"description": "Servo 13", "value": 213}, {"description": "Servo 14", "value": 214}, {"description": "Servo 15", "value": 215}, {"description": "Peripheral via Actuator Set 1", "value": 301}, {"description": "Peripheral via Actuator Set 2", "value": 302}, {"description": "Peripheral via Actuator Set 3", "value": 303}, {"description": "Peripheral via Actuator Set 4", "value": 304}, {"description": "Peripheral via Actuator Set 5", "value": 305}, {"description": "Peripheral via Actuator Set 6", "value": 306}, {"description": "Landing Gear", "value": 400}, {"description": "Parachute", "value": 401}, {"description": "RC Roll", "value": 402}, {"description": "RC Pitch", "value": 403}, {"description": "RC Throttle", "value": 404}, {"description": "RC Yaw", "value": 405}, {"description": "RC Flaps", "value": 406}, {"description": "RC AUX 1", "value": 407}, {"description": "RC AUX 2", "value": 408}, {"description": "RC AUX 3", "value": 409}, {"description": "RC AUX 4", "value": 410}, {"description": "RC AUX 5", "value": 411}, {"description": "RC AUX 6", "value": 412}, {"description": "Gimbal Roll", "value": 420}, {"description": "Gimbal Pitch", "value": 421}, {"description": "Gimbal Yaw", "value": 422}, {"description": "Gripper", "value": 430}, {"description": "Landing Gear Wheel", "value": 440}, {"description": "IC Engine Ignition", "value": 450}, {"description": "IC Engine Throttle", "value": 451}, {"description": "IC Engine Choke", "value": 452}, {"description": "IC Engine Starter", "value": 453}]}, {"category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Select what should be output on SIM Channel 9.\n\nThe default failsafe value is set according to the selected function:\n- 'Min' for ConstantMin\n- 'Max' for ConstantMax\n- 'Max' for Parachute\n- ('Max'+'Min')/2 for Servos\n- 'Disarmed' for the rest\n\n", "name": "PWM_MAIN_FUNC9", "shortDesc": "SIM Channel 9 Output Function", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Constant Min", "value": 1}, {"description": "Constant Max", "value": 2}, {"description": "Motor 1", "value": 101}, {"description": "Motor 2", "value": 102}, {"description": "Motor 3", "value": 103}, {"description": "Motor 4", "value": 104}, {"description": "Motor 5", "value": 105}, {"description": "Motor 6", "value": 106}, {"description": "Motor 7", "value": 107}, {"description": "Motor 8", "value": 108}, {"description": "Motor 9", "value": 109}, {"description": "Motor 10", "value": 110}, {"description": "Motor 11", "value": 111}, {"description": "Motor 12", "value": 112}, {"description": "Servo 1", "value": 201}, {"description": "Servo 2", "value": 202}, {"description": "Servo 3", "value": 203}, {"description": "Servo 4", "value": 204}, {"description": "Servo 5", "value": 205}, {"description": "Servo 6", "value": 206}, {"description": "Servo 7", "value": 207}, {"description": "Servo 8", "value": 208}, {"description": "Servo 9", "value": 209}, {"description": "Servo 10", "value": 210}, {"description": "Servo 11", "value": 211}, {"description": "Servo 12", "value": 212}, {"description": "Servo 13", "value": 213}, {"description": "Servo 14", "value": 214}, {"description": "Servo 15", "value": 215}, {"description": "Peripheral via Actuator Set 1", "value": 301}, {"description": "Peripheral via Actuator Set 2", "value": 302}, {"description": "Peripheral via Actuator Set 3", "value": 303}, {"description": "Peripheral via Actuator Set 4", "value": 304}, {"description": "Peripheral via Actuator Set 5", "value": 305}, {"description": "Peripheral via Actuator Set 6", "value": 306}, {"description": "Landing Gear", "value": 400}, {"description": "Parachute", "value": 401}, {"description": "RC Roll", "value": 402}, {"description": "RC Pitch", "value": 403}, {"description": "RC Throttle", "value": 404}, {"description": "RC Yaw", "value": 405}, {"description": "RC Flaps", "value": 406}, {"description": "RC AUX 1", "value": 407}, {"description": "RC AUX 2", "value": 408}, {"description": "RC AUX 3", "value": 409}, {"description": "RC AUX 4", "value": 410}, {"description": "RC AUX 5", "value": 411}, {"description": "RC AUX 6", "value": 412}, {"description": "Gimbal Roll", "value": 420}, {"description": "Gimbal Pitch", "value": 421}, {"description": "Gimbal Yaw", "value": 422}, {"description": "Gripper", "value": 430}, {"description": "Landing Gear Wheel", "value": 440}, {"description": "IC Engine Ignition", "value": 450}, {"description": "IC Engine Throttle", "value": 451}, {"description": "IC Engine Choke", "value": 452}, {"description": "IC Engine Starter", "value": 453}]}, {"bitmask": [{"description": "SIM Channel 1", "index": 0}, {"description": "SIM Channel 2", "index": 1}, {"description": "SIM Channel 3", "index": 2}, {"description": "SIM Channel 4", "index": 3}, {"description": "SIM Channel 5", "index": 4}, {"description": "SIM Channel 6", "index": 5}, {"description": "SIM Channel 7", "index": 6}, {"description": "SIM Channel 8", "index": 7}, {"description": "SIM Channel 9", "index": 8}, {"description": "SIM Channel 10", "index": 9}, {"description": "SIM Channel 11", "index": 10}, {"description": "SIM Channel 12", "index": 11}, {"description": "SIM Channel 13", "index": 12}, {"description": "SIM Channel 14", "index": 13}, {"description": "SIM Channel 15", "index": 14}, {"description": "SIM Channel 16", "index": 15}], "category": "Standard", "default": 0, "group": "Actuator Outputs", "longDesc": "Allows to reverse the output range for each channel.\nNote: this is only useful for servos.\n\n", "max": 65535, "min": 0, "name": "PWM_MAIN_REV", "shortDesc": "Reverse Output Range for SIM", "type": "Int32"}, {"bitmask": [{"description": "Only data missing check (triggers if more than 1s no data)", "index": 0}, {"description": "Data stuck (triggers if data is exactly constant for 2s in FW mode)", "index": 1}, {"description": "Innovation check (see ASPD_FS_INNOV)", "index": 2}, {"description": "Load factor check (triggers if measurement is below stall speed)", "index": 3}, {"description": "First principle check (airspeed change vs. throttle and pitch)", "index": 4}], "category": "Standard", "default": 7, "group": "Airspeed Validator", "longDesc": "Controls which checks are run to check airspeed data for validity. Only applied if ASPD_PRIMARY > 0.\n\nNote: The missing data check (bit 0) is implicitly always enabled when ASPD_DO_CHECKS > 0, even if bit 0 is not explicitly set.\n", "max": 31, "min": 0, "name": "ASPD_DO_CHECKS", "shortDesc": "Enable checks on airspeed sensors", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "Airspeed Validator", "name": "ASPD_FALLBACK", "shortDesc": "Fallback options", "type": "Int32", "values": [{"description": "Fallback only to other airspeed sensors", "value": 0}, {"description": "Fallback to groundspeed-minus-windspeed airspeed estimation", "value": 1}, {"description": "Fallback to thrust based airspeed estimation", "value": 2}]}, {"category": "Standard", "decimalPlaces": 1, "default": 2.0, "group": "Airspeed Validator", "longDesc": "Window for comparing airspeed change to throttle and pitch change.\nTriggers when the airspeed change within this window is negative while throttle increases\nand the vehicle pitches down.\nIs meant to catch degrading airspeed blockages as can happen when flying through icing conditions.\nRelies on FW_THR_TRIM being set accurately.\n", "min": 0.0, "name": "ASPD_FP_T_WINDOW", "shortDesc": "First principle airspeed check time window", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "Airspeed Validator", "longDesc": "This specifies the minimum airspeed innovation required to trigger a failsafe. Larger values make the check less sensitive,\nsmaller values make it more sensitive. Large innovations indicate an inconsistency between predicted (groundspeed - windspeeed)\nand measured airspeed.\nThe time required to detect a fault when the threshold is exceeded depends on the size of the exceedance and is controlled by the ASPD_FS_INTEG parameter.\n", "max": 10.0, "min": 0.5, "name": "ASPD_FS_INNOV", "shortDesc": "Airspeed failure innovation threshold", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 10.0, "group": "Airspeed Validator", "longDesc": "This sets the time integral of airspeed innovation exceedance above ASPD_FS_INNOV required to trigger a failsafe.\nLarger values make the check less sensitive, smaller positive values make it more sensitive.\n", "max": 50.0, "min": 0.0, "name": "ASPD_FS_INTEG", "shortDesc": "Airspeed failure innovation integral threshold", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": -1.0, "group": "Airspeed Validator", "longDesc": "Delay before switching back to using airspeed sensor if checks indicate sensor is good.\nSet to a negative value to disable the re-enabling in flight.\n", "min": -1.0, "name": "ASPD_FS_T_START", "shortDesc": "Airspeed failsafe start delay", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.0, "group": "Airspeed Validator", "longDesc": "Delay before stopping use of airspeed sensor if checks indicate sensor is bad.\n", "min": 0.0, "name": "ASPD_FS_T_STOP", "shortDesc": "Airspeed failsafe stop delay", "type": "Float", "units": "s"}, {"category": "Standard", "default": 1, "group": "Airspeed Validator", "name": "ASPD_PRIMARY", "rebootRequired": true, "shortDesc": "Index or primary airspeed measurement source", "type": "Int32", "values": [{"description": "Groundspeed minus windspeed", "value": 0}, {"description": "First airspeed sensor", "value": 1}, {"description": "Second airspeed sensor", "value": 2}, {"description": "Third airspeed sensor", "value": 3}, {"description": "Thrust based airspeed", "value": 4}]}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Airspeed Validator", "longDesc": "This is the scale IAS --> CAS of the first airspeed sensor instance\n", "max": 2.0, "min": 0.5, "name": "ASPD_SCALE_1", "shortDesc": "Scale of airspeed sensor 1", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Airspeed Validator", "longDesc": "This is the scale IAS --> CAS of the second airspeed sensor instance\n", "max": 2.0, "min": 0.5, "name": "ASPD_SCALE_2", "shortDesc": "Scale of airspeed sensor 2", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Airspeed Validator", "longDesc": "This is the scale IAS --> CAS of the third airspeed sensor instance\n", "max": 2.0, "min": 0.5, "name": "ASPD_SCALE_3", "shortDesc": "Scale of airspeed sensor 3", "type": "Float"}, {"category": "Standard", "default": 2, "group": "Airspeed Validator", "name": "ASPD_SCALE_APPLY", "shortDesc": "Controls when to apply the new estimated airspeed scale(s)", "type": "Int32", "values": [{"description": "Do not automatically apply the estimated scale", "value": 0}, {"description": "Apply the estimated scale after disarm", "value": 1}, {"description": "Apply the estimated scale in air", "value": 2}]}, {"category": "Standard", "decimalPlaces": 1, "default": 1.4, "group": "Airspeed Validator", "longDesc": "True airspeed measurement noise of the internal wind estimator(s) of the airspeed selector.\n", "max": 4.0, "min": 0.0, "name": "ASPD_TAS_NOISE", "shortDesc": "Wind estimator true airspeed measurement noise", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 2.0, "group": "Airspeed Validator", "longDesc": "The airspeed alternative derived from groundspeed and heading will be declared valid\nas soon and as long the horizontal wind uncertainty is below this value.\n", "max": 5.0, "min": 0.01, "name": "ASPD_WERR_THR", "shortDesc": "Horizontal wind uncertainty threshold for valid ground-minus-wind", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "Airspeed Validator", "longDesc": "Wind process noise of the internal wind estimator(s) of the airspeed selector.\nWhen unaided, the wind estimate uncertainty (1-sigma, in m/s) increases by this amount every second.\n", "max": 1.0, "min": 0.0, "name": "ASPD_WIND_NSD", "shortDesc": "Wind estimator wind process noise spectral density", "type": "Float", "units": "m/s^2/sqrt(Hz)"}, {"category": "Standard", "default": 0, "group": "Attitude Q estimator", "name": "ATT_ACC_COMP", "shortDesc": "Acceleration compensation based on GPS velocity", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "Attitude Q estimator", "max": 2.0, "min": 0.0, "name": "ATT_BIAS_MAX", "shortDesc": "Gyro bias limit", "type": "Float", "units": "rad/s"}, {"category": "Standard", "default": 0, "group": "Attitude Q estimator", "longDesc": "Enable standalone quaternion based attitude estimator.\n", "name": "ATT_EN", "shortDesc": "standalone attitude estimator enable (unsupported)", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Attitude Q estimator", "longDesc": "Set to 1 to use heading estimate from vision.\nSet to 2 to use heading from motion capture.\n", "max": 2, "min": 0, "name": "ATT_EXT_HDG_M", "shortDesc": "External heading usage mode (from Motion capture/Vision)", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Vision", "value": 1}, {"description": "Motion Capture", "value": 2}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Attitude Q estimator", "longDesc": "This parameter is not used in normal operation,\nas the declination is looked up based on the\nGPS coordinates of the vehicle.\n", "name": "ATT_MAG_DECL", "shortDesc": "Magnetic declination, in degrees", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 1, "group": "Attitude Q estimator", "name": "ATT_MAG_DECL_A", "shortDesc": "Automatic GPS based declination compensation", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.2, "group": "Attitude Q estimator", "max": 1.0, "min": 0.0, "name": "ATT_W_ACC", "shortDesc": "Complementary filter accelerometer weight", "type": "Float"}, {"category": "Standard", "default": 0.1, "group": "Attitude Q estimator", "max": 1.0, "min": 0.0, "name": "ATT_W_EXT_HDG", "shortDesc": "Complementary filter external heading weight", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "Attitude Q estimator", "max": 1.0, "min": 0.0, "name": "ATT_W_GYRO_BIAS", "shortDesc": "Complementary filter gyroscope bias weight", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "Attitude Q estimator", "longDesc": "Set to 0 to avoid using the magnetometer.\n", "max": 1.0, "min": 0.0, "name": "ATT_W_MAG", "shortDesc": "Complementary filter magnetometer weight", "type": "Float"}, {"category": "Standard", "default": 2, "group": "Autotune", "longDesc": "After the auto-tuning sequence is completed,\na new set of gains is available and can be applied\nimmediately or after landing.\n", "name": "FW_AT_APPLY", "shortDesc": "Controls when to apply the new gains", "type": "Int32", "values": [{"description": "Do not apply the new gains (logging only)", "value": 0}, {"description": "Apply the new gains after disarm", "value": 1}, {"description": "Apply the new gains in air", "value": 2}]}, {"bitmask": [{"description": "roll", "index": 0}, {"description": "pitch", "index": 1}, {"description": "yaw", "index": 2}], "category": "Standard", "default": 3, "group": "Autotune", "longDesc": "Defines which axes will be tuned during the auto-tuning sequence\n\nSet bits in the following positions to enable:\n0 : Roll\n1 : Pitch\n2 : Yaw\n", "max": 7, "min": 1, "name": "FW_AT_AXES", "shortDesc": "Tuning axes selection", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "Autotune", "longDesc": "Defines which RC_MAP_AUXn parameter maps the manual control channel used to enable/disable auto tuning.\n", "max": 6, "min": 0, "name": "FW_AT_MAN_AUX", "shortDesc": "Enable/disable auto tuning using a manual control AUX input", "type": "Int32", "values": [{"description": "Disable", "value": 0}, {"description": "Aux1", "value": 1}, {"description": "Aux2", "value": 2}, {"description": "Aux3", "value": 3}, {"description": "Aux4", "value": 4}, {"description": "Aux5", "value": 5}, {"description": "Aux6", "value": 6}]}, {"category": "Standard", "decimalPlaces": 1, "default": 1.0, "group": "Autotune", "longDesc": "Can be set lower or higher than the end frequency\n", "max": 30.0, "min": 0.1, "name": "FW_AT_SYSID_F0", "shortDesc": "Start frequency of the injected signal", "type": "Float", "units": "Hz"}, {"category": "Standard", "decimalPlaces": 1, "default": 10.0, "group": "Autotune", "longDesc": "Can be set lower or higher than the start frequency\n", "max": 30.0, "min": 0.1, "name": "FW_AT_SYSID_F1", "shortDesc": "End frequency of the injected signal", "type": "Float", "units": "Hz"}, {"category": "Standard", "decimalPlaces": 0, "default": 10.0, "group": "Autotune", "longDesc": "Duration of the input signal sent on each axis during system identification\n", "max": 120.0, "min": 5.0, "name": "FW_AT_SYSID_TIME", "shortDesc": "Maneuver time for each axis", "type": "Float", "units": "s"}, {"category": "Standard", "default": 1, "group": "Autotune", "longDesc": "Type of signal used during system identification to excite the system.\n", "name": "FW_AT_SYSID_TYPE", "shortDesc": "Input signal type", "type": "Int32", "values": [{"description": "Step", "value": 0}, {"description": "Linear sine sweep", "value": 1}, {"description": "Logarithmic sine sweep", "value": 2}]}, {"category": "Standard", "default": 1, "group": "Autotune", "longDesc": "After the auto-tuning sequence is completed,\na new set of gains is available and can be applied\nimmediately or after landing.\n\nWARNING Applying the gains in air is dangerous as there is no\nguarantee that those new gains will be able to stabilize\nthe drone properly.\n", "name": "MC_AT_APPLY", "shortDesc": "Controls when to apply the new gains", "type": "Int32", "values": [{"description": "Do not apply the new gains (logging only)", "value": 0}, {"description": "Apply the new gains after disarm", "value": 1}, {"description": "WARNING Apply the new gains in air", "value": 2}]}, {"category": "Standard", "default": 0, "group": "Autotune", "name": "MC_AT_EN", "shortDesc": "Multicopter autotune module enable", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.14, "group": "Autotune", "max": 0.5, "min": 0.01, "name": "MC_AT_RISE_TIME", "shortDesc": "Desired angular rate closed-loop rise time", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.7, "group": "Autotune", "max": 6.0, "min": 0.1, "name": "MC_AT_SYSID_AMP", "shortDesc": "Amplitude of the injected signal", "type": "Float"}, {"category": "Standard", "decimalPlaces": 0, "default": -1.0, "group": "Battery Calibration", "increment": 50.0, "longDesc": "Defines the capacity of battery 1 in mAh.\n\n", "max": 100000.0, "min": -1.0, "name": "BAT1_CAPACITY", "rebootRequired": true, "shortDesc": "Battery 1 capacity", "type": "Float", "units": "mAh"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Battery Calibration", "longDesc": "While disarmed, replaces the measured current with this value, for ESCs that measure current inaccurately at no load. Set to 0 or less to disable.\n", "name": "BAT1_I_OVERWRITE", "shortDesc": "Battery 1 idle current overwrite", "type": "Float", "units": "A"}, {"category": "Standard", "default": 0, "group": "Battery Calibration", "longDesc": "Defines the number of cells the attached battery consists of.\n\n", "name": "BAT1_N_CELLS", "shortDesc": "Number of cells for battery 1", "type": "Int32", "values": [{"description": "Unknown", "value": 0}, {"description": "1S Battery", "value": 1}, {"description": "2S Battery", "value": 2}, {"description": "3S Battery", "value": 3}, {"description": "4S Battery", "value": 4}, {"description": "5S Battery", "value": 5}, {"description": "6S Battery", "value": 6}, {"description": "7S Battery", "value": 7}, {"description": "8S Battery", "value": 8}, {"description": "9S Battery", "value": 9}, {"description": "10S Battery", "value": 10}, {"description": "11S Battery", "value": 11}, {"description": "12S Battery", "value": 12}, {"description": "13S Battery", "value": 13}, {"description": "14S Battery", "value": 14}, {"description": "15S Battery", "value": 15}, {"description": "16S Battery", "value": 16}]}, {"category": "Standard", "decimalPlaces": 4, "default": -1.0, "group": "Battery Calibration", "increment": 0.0005, "longDesc": "If non-negative, then this will be used instead of the online estimated internal resistance.\n\n", "max": 0.2, "min": -1.0, "name": "BAT1_R_INTERNAL", "rebootRequired": true, "shortDesc": "Explicitly defines the per cell internal resistance for battery 1", "type": "Float", "units": "Ohm"}, {"category": "Standard", "default": 0, "group": "Battery Calibration", "longDesc": "Power Module / Analog: board ADC inputs (onboard or external analog power module) or an I2C power monitor (e.g. INA226).\nExternal: MAVLink or CAN battery status messages, or an external driver.\nESCs: esc_status from ESC telemetry; requires voltage and current.\n", "name": "BAT1_SOURCE", "rebootRequired": true, "shortDesc": "Battery 1 monitoring source", "type": "Int32", "values": [{"description": "Disabled", "value": -1}, {"description": "Power Module / Analog", "value": 0}, {"description": "External", "value": 1}, {"description": "ESCs", "value": 2}]}, {"category": "Standard", "decimalPlaces": 2, "default": 4.2, "group": "Battery Calibration", "increment": 0.01, "longDesc": "Defines the voltage where a single cell of the battery is considered full.\n\n", "name": "BAT1_V_CHARGED", "rebootRequired": true, "shortDesc": "Full cell voltage", "type": "Float", "units": "V"}, {"category": "Standard", "decimalPlaces": 2, "default": 3.6, "group": "Battery Calibration", "increment": 0.01, "longDesc": "Defines the voltage where a single cell of the battery is considered empty.\nThe voltage should be chosen above the steep dropoff at 3.5V. A typical\nlithium battery can only be discharged under high load down to 10% before\nit drops off to a voltage level damaging the cells.\n\n", "name": "BAT1_V_EMPTY", "rebootRequired": true, "shortDesc": "Empty cell voltage", "type": "Float", "units": "V"}, {"category": "Standard", "decimalPlaces": 0, "default": -1.0, "group": "Battery Calibration", "increment": 50.0, "longDesc": "Defines the capacity of battery 2 in mAh.\n\n", "max": 100000.0, "min": -1.0, "name": "BAT2_CAPACITY", "rebootRequired": true, "shortDesc": "Battery 2 capacity", "type": "Float", "units": "mAh"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Battery Calibration", "longDesc": "While disarmed, replaces the measured current with this value, for ESCs that measure current inaccurately at no load. Set to 0 or less to disable.\n", "name": "BAT2_I_OVERWRITE", "shortDesc": "Battery 2 idle current overwrite", "type": "Float", "units": "A"}, {"category": "Standard", "default": 0, "group": "Battery Calibration", "longDesc": "Defines the number of cells the attached battery consists of.\n\n", "name": "BAT2_N_CELLS", "shortDesc": "Number of cells for battery 2", "type": "Int32", "values": [{"description": "Unknown", "value": 0}, {"description": "1S Battery", "value": 1}, {"description": "2S Battery", "value": 2}, {"description": "3S Battery", "value": 3}, {"description": "4S Battery", "value": 4}, {"description": "5S Battery", "value": 5}, {"description": "6S Battery", "value": 6}, {"description": "7S Battery", "value": 7}, {"description": "8S Battery", "value": 8}, {"description": "9S Battery", "value": 9}, {"description": "10S Battery", "value": 10}, {"description": "11S Battery", "value": 11}, {"description": "12S Battery", "value": 12}, {"description": "13S Battery", "value": 13}, {"description": "14S Battery", "value": 14}, {"description": "15S Battery", "value": 15}, {"description": "16S Battery", "value": 16}]}, {"category": "Standard", "decimalPlaces": 4, "default": -1.0, "group": "Battery Calibration", "increment": 0.0005, "longDesc": "If non-negative, then this will be used instead of the online estimated internal resistance.\n\n", "max": 0.2, "min": -1.0, "name": "BAT2_R_INTERNAL", "rebootRequired": true, "shortDesc": "Explicitly defines the per cell internal resistance for battery 2", "type": "Float", "units": "Ohm"}, {"category": "Standard", "default": -1, "group": "Battery Calibration", "longDesc": "Power Module / Analog: board ADC inputs (onboard or external analog power module) or an I2C power monitor (e.g. INA226).\nExternal: MAVLink or CAN battery status messages, or an external driver.\nESCs: esc_status from ESC telemetry; requires voltage and current.\n", "name": "BAT2_SOURCE", "rebootRequired": true, "shortDesc": "Battery 2 monitoring source", "type": "Int32", "values": [{"description": "Disabled", "value": -1}, {"description": "Power Module / Analog", "value": 0}, {"description": "External", "value": 1}, {"description": "ESCs", "value": 2}]}, {"category": "Standard", "decimalPlaces": 2, "default": 4.2, "group": "Battery Calibration", "increment": 0.01, "longDesc": "Defines the voltage where a single cell of the battery is considered full.\n\n", "name": "BAT2_V_CHARGED", "rebootRequired": true, "shortDesc": "Full cell voltage", "type": "Float", "units": "V"}, {"category": "Standard", "decimalPlaces": 2, "default": 3.6, "group": "Battery Calibration", "increment": 0.01, "longDesc": "Defines the voltage where a single cell of the battery is considered empty.\nThe voltage should be chosen above the steep dropoff at 3.5V. A typical\nlithium battery can only be discharged under high load down to 10% before\nit drops off to a voltage level damaging the cells.\n\n", "name": "BAT2_V_EMPTY", "rebootRequired": true, "shortDesc": "Empty cell voltage", "type": "Float", "units": "V"}, {"category": "Standard", "decimalPlaces": 0, "default": -1.0, "group": "Battery Calibration", "increment": 50.0, "longDesc": "Defines the capacity of battery 3 in mAh.\n\n", "max": 100000.0, "min": -1.0, "name": "BAT3_CAPACITY", "rebootRequired": true, "shortDesc": "Battery 3 capacity", "type": "Float", "units": "mAh"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Battery Calibration", "longDesc": "While disarmed, replaces the measured current with this value, for ESCs that measure current inaccurately at no load. Set to 0 or less to disable.\n", "name": "BAT3_I_OVERWRITE", "shortDesc": "Battery 3 idle current overwrite", "type": "Float", "units": "A"}, {"category": "Standard", "default": 0, "group": "Battery Calibration", "longDesc": "Defines the number of cells the attached battery consists of.\n\n", "name": "BAT3_N_CELLS", "shortDesc": "Number of cells for battery 3", "type": "Int32", "values": [{"description": "Unknown", "value": 0}, {"description": "1S Battery", "value": 1}, {"description": "2S Battery", "value": 2}, {"description": "3S Battery", "value": 3}, {"description": "4S Battery", "value": 4}, {"description": "5S Battery", "value": 5}, {"description": "6S Battery", "value": 6}, {"description": "7S Battery", "value": 7}, {"description": "8S Battery", "value": 8}, {"description": "9S Battery", "value": 9}, {"description": "10S Battery", "value": 10}, {"description": "11S Battery", "value": 11}, {"description": "12S Battery", "value": 12}, {"description": "13S Battery", "value": 13}, {"description": "14S Battery", "value": 14}, {"description": "15S Battery", "value": 15}, {"description": "16S Battery", "value": 16}]}, {"category": "Standard", "decimalPlaces": 4, "default": -1.0, "group": "Battery Calibration", "increment": 0.0005, "longDesc": "If non-negative, then this will be used instead of the online estimated internal resistance.\n\n", "max": 0.2, "min": -1.0, "name": "BAT3_R_INTERNAL", "rebootRequired": true, "shortDesc": "Explicitly defines the per cell internal resistance for battery 3", "type": "Float", "units": "Ohm"}, {"category": "Standard", "default": -1, "group": "Battery Calibration", "longDesc": "Power Module / Analog: board ADC inputs (onboard or external analog power module) or an I2C power monitor (e.g. INA226).\nExternal: MAVLink or CAN battery status messages, or an external driver.\nESCs: esc_status from ESC telemetry; requires voltage and current.\n", "name": "BAT3_SOURCE", "rebootRequired": true, "shortDesc": "Battery 3 monitoring source", "type": "Int32", "values": [{"description": "Disabled", "value": -1}, {"description": "Power Module / Analog", "value": 0}, {"description": "External", "value": 1}, {"description": "ESCs", "value": 2}]}, {"category": "Standard", "decimalPlaces": 2, "default": 4.2, "group": "Battery Calibration", "increment": 0.01, "longDesc": "Defines the voltage where a single cell of the battery is considered full.\n\n", "name": "BAT3_V_CHARGED", "rebootRequired": true, "shortDesc": "Full cell voltage", "type": "Float", "units": "V"}, {"category": "Standard", "decimalPlaces": 2, "default": 3.6, "group": "Battery Calibration", "increment": 0.01, "longDesc": "Defines the voltage where a single cell of the battery is considered empty.\nThe voltage should be chosen above the steep dropoff at 3.5V. A typical\nlithium battery can only be discharged under high load down to 10% before\nit drops off to a voltage level damaging the cells.\n\n", "name": "BAT3_V_EMPTY", "rebootRequired": true, "shortDesc": "Empty cell voltage", "type": "Float", "units": "V"}, {"category": "Standard", "decimalPlaces": 2, "default": 15.0, "group": "Battery Calibration", "increment": 0.1, "longDesc": "This value is used to initialize the in-flight average current estimation,\nwhich in turn is used for estimating remaining flight time and Return triggering.\n\n", "max": 500.0, "min": 0.0, "name": "BAT_AVRG_CURRENT", "shortDesc": "Expected battery current in flight", "type": "Float", "units": "A"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.07, "group": "Battery Calibration", "increment": 0.01, "longDesc": "Sets the threshold when the battery will be reported as critically low.\nThis has to be lower than the low threshold. This threshold commonly\nwill trigger Return.\n\n", "max": 0.5, "min": 0.05, "name": "BAT_CRIT_THR", "shortDesc": "Critical threshold", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.05, "group": "Battery Calibration", "increment": 0.01, "longDesc": "Sets the threshold when the battery will be reported as dangerously low.\nThis has to be lower than the critical threshold. This threshold commonly\nwill trigger landing.\n\n", "max": 0.5, "min": 0.03, "name": "BAT_EMERGEN_THR", "shortDesc": "Emergency threshold", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.15, "group": "Battery Calibration", "increment": 0.01, "longDesc": "Sets the threshold when the battery will be reported as low.\nThis has to be higher than the critical threshold.\n\n", "max": 0.5, "min": 0.12, "name": "BAT_LOW_THR", "shortDesc": "Low threshold", "type": "Float", "units": "norm"}, {"category": "Standard", "default": 1, "group": "Camera Control", "longDesc": "Whether the autopilot reports captures to the ground station by emitting\nCAMERA_IMAGE_CAPTURED.\n\nDisable for cameras that report captures themselves (e.g. cameras\nimplementing the MAVLink Camera Protocol) to avoid duplicate\nCAMERA_IMAGE_CAPTURED messages. Capture events are still published on the\ncamera_capture topic and logged for geotagging regardless of this setting.\n\n", "name": "CAM_CAP_REPORT", "shortDesc": "Report captures to the ground station", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 40.0, "group": "Camera trigger", "longDesc": "This parameter sets the time the trigger needs to pulled high or low.\n", "max": 3000.0, "min": 0.1, "name": "TRIG_ACT_TIME", "rebootRequired": true, "shortDesc": "Camera trigger activation time", "type": "Float", "units": "ms"}, {"category": "Standard", "decimalPlaces": 1, "default": 25.0, "group": "Camera trigger", "increment": 1.0, "longDesc": "Sets the distance at which to trigger the camera.\n", "min": 0.0, "name": "TRIG_DISTANCE", "rebootRequired": true, "shortDesc": "Camera trigger distance", "type": "Float", "units": "m"}, {"category": "Standard", "default": 4, "group": "Camera trigger", "longDesc": "Selects the trigger interface\n", "name": "TRIG_INTERFACE", "rebootRequired": true, "shortDesc": "Camera trigger Interface", "type": "Int32", "values": [{"description": "GPIO", "value": 1}, {"description": "Seagull MAP2 (over PWM)", "value": 2}, {"description": "MAVLink (Camera Protocol v1)", "value": 3}, {"description": "Generic PWM (IR trigger, servo)", "value": 4}]}, {"category": "Standard", "decimalPlaces": 1, "default": 40.0, "group": "Camera trigger", "longDesc": "This parameter sets the time between two consecutive trigger events\n", "max": 10000.0, "min": 4.0, "name": "TRIG_INTERVAL", "rebootRequired": true, "shortDesc": "Camera trigger interval", "type": "Float", "units": "ms"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.0, "group": "Camera trigger", "longDesc": "This parameter sets the minimum time between two consecutive trigger events\nthe specific camera setup is supporting.\n", "max": 10000.0, "min": 1.0, "name": "TRIG_MIN_INTERVA", "rebootRequired": true, "shortDesc": "Minimum camera trigger interval", "type": "Float", "units": "ms"}, {"category": "Standard", "default": 0, "group": "Camera trigger", "max": 4, "min": 0, "name": "TRIG_MODE", "rebootRequired": true, "shortDesc": "Camera trigger mode", "type": "Int32", "values": [{"description": "Disable", "value": 0}, {"description": "Time based, on command", "value": 1}, {"description": "Time based, always on", "value": 2}, {"description": "Distance based, always on", "value": 3}, {"description": "Distance based, on command (Survey mode)", "value": 4}]}, {"category": "Standard", "default": 0, "group": "Camera trigger", "longDesc": "This parameter sets the polarity of the trigger (0 = active low, 1 = active high )\n", "max": 1, "min": 0, "name": "TRIG_POLARITY", "rebootRequired": true, "shortDesc": "Camera trigger polarity", "type": "Int32", "values": [{"description": "Active low", "value": 0}, {"description": "Active high", "value": 1}]}, {"category": "Standard", "default": 1500, "group": "Camera trigger", "max": 2000, "min": 1000, "name": "TRIG_PWM_NEUTRAL", "rebootRequired": true, "shortDesc": "PWM neutral output on trigger pin", "type": "Int32", "units": "us"}, {"category": "Standard", "default": 1900, "group": "Camera trigger", "max": 2000, "min": 1000, "name": "TRIG_PWM_SHOOT", "rebootRequired": true, "shortDesc": "PWM output to trigger shot", "type": "Int32", "units": "us"}, {"category": "Developer", "default": 0, "group": "Circuit Breaker", "longDesc": "Setting this parameter to 782097 will disable the buzzer audio notification.\n\nSetting this parameter to 782090 will disable the startup tune, while keeping\nall others enabled.\n", "max": 782097, "min": 0, "name": "CBRK_BUZZER", "rebootRequired": true, "shortDesc": "Circuit breaker for disabling buzzer", "type": "Int32"}, {"category": "Developer", "default": 121212, "group": "Circuit Breaker", "longDesc": "Setting this parameter to 121212 will disable the flight termination action if triggered\nby the FailureDetector logic or if FMU is lost.\nThis circuit breaker does not affect the RC loss, data link loss, geofence,\nand takeoff failure detection safety logic.\n", "max": 121212, "min": 0, "name": "CBRK_FLIGHTTERM", "rebootRequired": true, "shortDesc": "Circuit breaker for flight termination", "type": "Int32"}, {"category": "Developer", "default": 0, "group": "Circuit Breaker", "longDesc": "Setting this parameter to 894281 will disable the power valid\nchecks in the commander.\nWARNING: ENABLING THIS CIRCUIT BREAKER IS AT OWN RISK\n", "max": 894281, "min": 0, "name": "CBRK_SUPPLY_CHK", "shortDesc": "Circuit breaker for power supply check", "type": "Int32"}, {"category": "Developer", "default": 0, "group": "Circuit Breaker", "longDesc": "Setting this parameter to 5318008 will allow arming even when a UAVCAN\nnode firmware update is pending or a node went offline mid-update.\nWARNING: ENABLING THIS CIRCUIT BREAKER IS AT OWN RISK\n", "max": 5318008, "min": 0, "name": "CBRK_UAVCAN_FW", "shortDesc": "Circuit breaker for UAVCAN firmware update arming check", "type": "Int32"}, {"category": "Developer", "default": 197848, "group": "Circuit Breaker", "longDesc": "Setting this parameter to 197848 will disable the USB connected\nchecks in the commander, setting it to 0 keeps them enabled (recommended).\n\nWe are generally recommending to not fly with the USB link\nconnected and production vehicles should set this parameter to\nzero to prevent users from flying USB powered. However, for R&D purposes\nit has proven over the years to work just fine.\n", "max": 197848, "min": 0, "name": "CBRK_USB_CHK", "shortDesc": "Circuit breaker for USB link check", "type": "Int32"}, {"category": "Developer", "default": 0, "group": "Circuit Breaker", "longDesc": "Setting this parameter to 159753 will enable arming in fixed-wing\nmode for VTOLs.\nWARNING: ENABLING THIS CIRCUIT BREAKER IS AT OWN RISK\n", "max": 159753, "min": 0, "name": "CBRK_VTOLARMING", "shortDesc": "Circuit breaker for arming in fixed-wing mode check", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "Note: actuator failure needs to be enabled and configured via FD_ACT_*\nparameters.\n", "name": "COM_ACT_FAIL_ACT", "shortDesc": "Set the actuator failure failsafe mode", "type": "Int32", "values": [{"description": "Warning only", "value": 0}, {"description": "Hold mode", "value": 1}, {"description": "Land mode", "value": 2}, {"description": "Return mode", "value": 3}, {"description": "Terminate", "value": 4}]}, {"category": "Standard", "default": 1, "group": "Commander", "longDesc": "Set 0 to prevent accidental use of the vehicle e.g. for safety or maintenance reasons.\n", "name": "COM_ARMABLE", "shortDesc": "Flag to allow arming", "type": "Int32", "values": [{"description": "Disallow arming", "value": 0}, {"description": "Allow arming", "value": 1}]}, {"category": "Standard", "default": 10, "group": "Commander", "longDesc": "Used if arm authorization is requested by COM_ARM_AUTH_REQ.\n", "name": "COM_ARM_AUTH_ID", "shortDesc": "Arm authorizer system id", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "Methods:\n- one arm: request authorization and arm when authorization is received\n- two step arm: 1st arm command request an authorization and\n2nd arm command arm the drone if authorized\n\nUsed if arm authorization is requested by COM_ARM_AUTH_REQ.\n", "name": "COM_ARM_AUTH_MET", "shortDesc": "Arm authorization method", "type": "Int32", "values": [{"description": "one arm", "value": 0}, {"description": "two step arm", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "By default off. The default allows to arm the vehicle without a arm authorization.\n", "name": "COM_ARM_AUTH_REQ", "shortDesc": "Require arm authorization to arm", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 1.0, "group": "Commander", "increment": 0.1, "longDesc": "Timeout for authorizer answer.\nUsed if arm authorization is requested by COM_ARM_AUTH_REQ.\n", "name": "COM_ARM_AUTH_TO", "shortDesc": "Arm authorization timeout", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Commander", "increment": 0.01, "longDesc": "Threshold for battery percentage below arming is prohibited.\n\nA negative value means BAT_CRIT_THR is the threshold.\n", "max": 0.9, "min": -1.0, "name": "COM_ARM_BAT_MIN", "shortDesc": "Minimum battery level for arming", "type": "Float", "units": "norm"}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "If this parameter is set, the system will check ESC's online status and failures.\nThis param is specific for ESCs reporting status. It shall be used only if ESCs support telemetry.\n", "name": "COM_ARM_CHK_ESCS", "shortDesc": "Enable checks on ESCs that report telemetry", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 1, "group": "Commander", "longDesc": "This check detects if there are hardfault / watchdog files present on the\nSD card. If so, and the parameter is enabled, arming is prevented.\n", "name": "COM_ARM_HFLT_CHK", "shortDesc": "Enable FMU SD card hardfault / watchdog detection check", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.7, "group": "Commander", "increment": 0.05, "longDesc": "Maximum accelerometer inconsistency between IMU units that will allow arming\n", "max": 1.0, "min": 0.1, "name": "COM_ARM_IMU_ACC", "shortDesc": "Max accelerometer inconsistency for arming", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.25, "group": "Commander", "increment": 0.01, "longDesc": "Maximum rate gyro inconsistency between IMU units that will allow arming\n", "max": 0.3, "min": 0.02, "name": "COM_ARM_IMU_GYR", "shortDesc": "Max rate gyro inconsistency for arming", "type": "Float", "units": "rad/s"}, {"category": "Standard", "default": 60, "group": "Commander", "longDesc": "Maximum magnetic field inconsistency between units that will allow arming\n\nSet -1 to disable the check.\n", "max": 180, "min": 3, "name": "COM_ARM_MAG_ANG", "shortDesc": "Max magnetic field inconsistency for arming", "type": "Int32", "units": "deg"}, {"category": "Standard", "default": 2, "group": "Commander", "longDesc": "Check if the estimator detects a strong magnetic\ndisturbance (check enabled by EKF2_MAG_CHECK)\n", "name": "COM_ARM_MAG_STR", "shortDesc": "Enable mag strength preflight check", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Deny arming", "value": 1}, {"description": "Warning only", "value": 2}]}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "The default allows to arm the vehicle without a valid mission.\n", "name": "COM_ARM_MIS_REQ", "shortDesc": "Require valid mission to arm", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "Actions other than warning also prevent arming.\n", "name": "COM_ARM_ODID", "shortDesc": "Open Drone ID system check and in-flight failsafe", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Warning only", "value": 1}, {"description": "Error only", "value": 2}, {"description": "Return", "value": 3}, {"description": "Land", "value": 4}, {"description": "Terminate", "value": 5}]}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "When enabled, the vehicle arms automatically once all preflight checks pass after boot.\nThe vehicle will not re-arm after a manual disarm.\nHas no effect if COM_ARMABLE is 0.\n", "name": "COM_ARM_ON_BOOT", "rebootRequired": true, "shortDesc": "Arm automatically on boot", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "0: Arming/disarming triggers on switch transition.\n1: Arming/disarming triggers when holding the momentary button down like the stick gesture.\n", "name": "COM_ARM_SWISBTN", "shortDesc": "Arm switch is a momentary button", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 1, "group": "Commander", "longDesc": "Configures whether arming is allowed without GNSS, for modes that require a global position\n(specifically, in those modes when a check defined by GNSS_CHECK fails).\nThe settings deny arming and warn, allow arming and warn, or silently allow arming.\n", "name": "COM_ARM_WO_GPS", "shortDesc": "Arming without GNSS configuration", "type": "Int32", "values": [{"description": "Deny arming", "value": 0}, {"description": "Allow arming (with warning)", "value": 1}, {"description": "Allow arming (no warning)", "value": 2}]}, {"category": "Standard", "decimalPlaces": 0, "default": 80.0, "group": "Commander", "increment": 1.0, "longDesc": "Arming is not prevented as the temperature typically drops in flight.\n\nSet to -1 to disable.\n", "max": 127.0, "min": -1.0, "name": "COM_CC_TEMP_WARN", "shortDesc": "Companion computer high-temperature warning threshold", "type": "Float", "units": "celcius"}, {"category": "Standard", "default": 95.0, "group": "Commander", "increment": 1.0, "longDesc": "The check fails if the CPU load is above this threshold for 2s.\n\nA negative value disables the check.\n", "max": 100.0, "min": -1.0, "name": "COM_CPU_MAX", "shortDesc": "Maximum allowed CPU load to still arm", "type": "Float", "units": "%"}, {"category": "Standard", "decimalPlaces": 1, "default": 2.0, "group": "Commander", "increment": 0.1, "longDesc": "A non-zero, positive value specifies the time-out period in seconds after which the vehicle will be\nautomatically disarmed in case a landing situation has been detected during this period.\n\nA zero or negative value means that automatic disarming triggered by landing detection is disabled.\n", "name": "COM_DISARM_LAND", "shortDesc": "Time-out for auto disarm after landing", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 10.0, "group": "Commander", "increment": 0.1, "longDesc": "A non-zero, positive value specifies the time in seconds, within which the\nvehicle is expected to take off after arming. In case the vehicle didn't takeoff\nwithin the timeout it disarms again.\n\nA negative value disables autmoatic disarming triggered by a pre-takeoff timeout.\n", "name": "COM_DISARM_PRFLT", "shortDesc": "Time-out for auto disarm if not taking off", "type": "Float", "units": "s"}, {"bitmask": [{"description": "Mission", "index": 0}, {"description": "Auto modes", "index": 1}, {"description": "Offboard", "index": 2}, {"description": "External Mode", "index": 3}, {"description": "Altitude Cruise", "index": 4}], "category": "Standard", "default": 0, "group": "Commander", "longDesc": "Specify modes in which ground control station connection loss is ignored and no failsafe action is triggered.\nSee also COM_RCL_EXCEPT.\n", "max": 31, "min": 0, "name": "COM_DLL_EXCEPT", "shortDesc": "Datalink loss exceptions", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 1, "default": 10, "group": "Commander", "increment": 1, "longDesc": "After this amount of seconds without datalink, the GCS connection lost mode triggers\n", "max": 300, "min": 5, "name": "COM_DL_LOSS_T", "shortDesc": "GCS connection loss time threshold", "type": "Int32", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "Commander", "longDesc": "Before entering failsafe (Return, Land, Hold), wait COM_FAIL_ACT_T seconds in Hold mode\nfor the user to realize.\nDuring that time the user can switch modes, but cannot take over control via the manual control override feature (see MAN_OVERRIDE_SPD).\nAfterwards the configured failsafe action is triggered and the user may use manual control override.\n\nA zero value disables the delay.\n", "max": 25.0, "min": 0.0, "name": "COM_FAIL_ACT_T", "shortDesc": "Delay between failsafe condition triggered and failsafe reaction", "type": "Float", "units": "s"}, {"category": "System", "default": 0, "group": "Commander", "longDesc": "This number is incremented automatically after every flight on\ndisarming in order to remember the next flight UUID.\nThe first flight is 0.\n", "min": 0, "name": "COM_FLIGHT_UUID", "shortDesc": "Next flight UUID", "type": "Int32", "volatile": true}, {"category": "Standard", "default": -1, "group": "Commander", "longDesc": "If the main switch channel is in this range the\nselected flight mode will be applied.\n\n", "name": "COM_FLTMODE1", "shortDesc": "Mode slot 1", "type": "Int32", "values": [{"description": "Unassigned", "value": -1}, {"description": "Manual", "value": 0}, {"description": "Altitude", "value": 1}, {"description": "Position / Cruise", "value": 2}, {"description": "Mission", "value": 3}, {"description": "Hold", "value": 4}, {"description": "Return", "value": 5}, {"description": "Acro", "value": 6}, {"description": "Offboard", "value": 7}, {"description": "Stabilized", "value": 8}, {"description": "Position Slow", "value": 9}, {"description": "Takeoff", "value": 10}, {"description": "Land", "value": 11}, {"description": "Follow Me", "value": 12}, {"description": "Precision Land", "value": 13}, {"description": "Altitude Cruise", "value": 16}, {"description": "Manual Parking", "value": 17}, {"description": "External Mode 1", "value": 100}, {"description": "External Mode 2", "value": 101}, {"description": "External Mode 3", "value": 102}, {"description": "External Mode 4", "value": 103}, {"description": "External Mode 5", "value": 104}, {"description": "External Mode 6", "value": 105}, {"description": "External Mode 7", "value": 106}, {"description": "External Mode 8", "value": 107}]}, {"category": "Standard", "default": -1, "group": "Commander", "longDesc": "If the main switch channel is in this range the\nselected flight mode will be applied.\n\n", "name": "COM_FLTMODE2", "shortDesc": "Mode slot 2", "type": "Int32", "values": [{"description": "Unassigned", "value": -1}, {"description": "Manual", "value": 0}, {"description": "Altitude", "value": 1}, {"description": "Position / Cruise", "value": 2}, {"description": "Mission", "value": 3}, {"description": "Hold", "value": 4}, {"description": "Return", "value": 5}, {"description": "Acro", "value": 6}, {"description": "Offboard", "value": 7}, {"description": "Stabilized", "value": 8}, {"description": "Position Slow", "value": 9}, {"description": "Takeoff", "value": 10}, {"description": "Land", "value": 11}, {"description": "Follow Me", "value": 12}, {"description": "Precision Land", "value": 13}, {"description": "Altitude Cruise", "value": 16}, {"description": "Manual Parking", "value": 17}, {"description": "External Mode 1", "value": 100}, {"description": "External Mode 2", "value": 101}, {"description": "External Mode 3", "value": 102}, {"description": "External Mode 4", "value": 103}, {"description": "External Mode 5", "value": 104}, {"description": "External Mode 6", "value": 105}, {"description": "External Mode 7", "value": 106}, {"description": "External Mode 8", "value": 107}]}, {"category": "Standard", "default": -1, "group": "Commander", "longDesc": "If the main switch channel is in this range the\nselected flight mode will be applied.\n\n", "name": "COM_FLTMODE3", "shortDesc": "Mode slot 3", "type": "Int32", "values": [{"description": "Unassigned", "value": -1}, {"description": "Manual", "value": 0}, {"description": "Altitude", "value": 1}, {"description": "Position / Cruise", "value": 2}, {"description": "Mission", "value": 3}, {"description": "Hold", "value": 4}, {"description": "Return", "value": 5}, {"description": "Acro", "value": 6}, {"description": "Offboard", "value": 7}, {"description": "Stabilized", "value": 8}, {"description": "Position Slow", "value": 9}, {"description": "Takeoff", "value": 10}, {"description": "Land", "value": 11}, {"description": "Follow Me", "value": 12}, {"description": "Precision Land", "value": 13}, {"description": "Altitude Cruise", "value": 16}, {"description": "Manual Parking", "value": 17}, {"description": "External Mode 1", "value": 100}, {"description": "External Mode 2", "value": 101}, {"description": "External Mode 3", "value": 102}, {"description": "External Mode 4", "value": 103}, {"description": "External Mode 5", "value": 104}, {"description": "External Mode 6", "value": 105}, {"description": "External Mode 7", "value": 106}, {"description": "External Mode 8", "value": 107}]}, {"category": "Standard", "default": -1, "group": "Commander", "longDesc": "If the main switch channel is in this range the\nselected flight mode will be applied.\n\n", "name": "COM_FLTMODE4", "shortDesc": "Mode slot 4", "type": "Int32", "values": [{"description": "Unassigned", "value": -1}, {"description": "Manual", "value": 0}, {"description": "Altitude", "value": 1}, {"description": "Position / Cruise", "value": 2}, {"description": "Mission", "value": 3}, {"description": "Hold", "value": 4}, {"description": "Return", "value": 5}, {"description": "Acro", "value": 6}, {"description": "Offboard", "value": 7}, {"description": "Stabilized", "value": 8}, {"description": "Position Slow", "value": 9}, {"description": "Takeoff", "value": 10}, {"description": "Land", "value": 11}, {"description": "Follow Me", "value": 12}, {"description": "Precision Land", "value": 13}, {"description": "Altitude Cruise", "value": 16}, {"description": "Manual Parking", "value": 17}, {"description": "External Mode 1", "value": 100}, {"description": "External Mode 2", "value": 101}, {"description": "External Mode 3", "value": 102}, {"description": "External Mode 4", "value": 103}, {"description": "External Mode 5", "value": 104}, {"description": "External Mode 6", "value": 105}, {"description": "External Mode 7", "value": 106}, {"description": "External Mode 8", "value": 107}]}, {"category": "Standard", "default": -1, "group": "Commander", "longDesc": "If the main switch channel is in this range the\nselected flight mode will be applied.\n\n", "name": "COM_FLTMODE5", "shortDesc": "Mode slot 5", "type": "Int32", "values": [{"description": "Unassigned", "value": -1}, {"description": "Manual", "value": 0}, {"description": "Altitude", "value": 1}, {"description": "Position / Cruise", "value": 2}, {"description": "Mission", "value": 3}, {"description": "Hold", "value": 4}, {"description": "Return", "value": 5}, {"description": "Acro", "value": 6}, {"description": "Offboard", "value": 7}, {"description": "Stabilized", "value": 8}, {"description": "Position Slow", "value": 9}, {"description": "Takeoff", "value": 10}, {"description": "Land", "value": 11}, {"description": "Follow Me", "value": 12}, {"description": "Precision Land", "value": 13}, {"description": "Altitude Cruise", "value": 16}, {"description": "Manual Parking", "value": 17}, {"description": "External Mode 1", "value": 100}, {"description": "External Mode 2", "value": 101}, {"description": "External Mode 3", "value": 102}, {"description": "External Mode 4", "value": 103}, {"description": "External Mode 5", "value": 104}, {"description": "External Mode 6", "value": 105}, {"description": "External Mode 7", "value": 106}, {"description": "External Mode 8", "value": 107}]}, {"category": "Standard", "default": -1, "group": "Commander", "longDesc": "If the main switch channel is in this range the\nselected flight mode will be applied.\n\n", "name": "COM_FLTMODE6", "shortDesc": "Mode slot 6", "type": "Int32", "values": [{"description": "Unassigned", "value": -1}, {"description": "Manual", "value": 0}, {"description": "Altitude", "value": 1}, {"description": "Position / Cruise", "value": 2}, {"description": "Mission", "value": 3}, {"description": "Hold", "value": 4}, {"description": "Return", "value": 5}, {"description": "Acro", "value": 6}, {"description": "Offboard", "value": 7}, {"description": "Stabilized", "value": 8}, {"description": "Position Slow", "value": 9}, {"description": "Takeoff", "value": 10}, {"description": "Land", "value": 11}, {"description": "Follow Me", "value": 12}, {"description": "Precision Land", "value": 13}, {"description": "Altitude Cruise", "value": 16}, {"description": "Manual Parking", "value": 17}, {"description": "External Mode 1", "value": 100}, {"description": "External Mode 2", "value": 101}, {"description": "External Mode 3", "value": 102}, {"description": "External Mode 4", "value": 103}, {"description": "External Mode 5", "value": 104}, {"description": "External Mode 6", "value": 105}, {"description": "External Mode 7", "value": 106}, {"description": "External Mode 8", "value": 107}]}, {"category": "Standard", "default": 4, "group": "Commander", "longDesc": "Flight mode set on boot and after a power cycle, before any RC input or\nmode command is received.\n", "name": "COM_FLTMODE_BOOT", "shortDesc": "Flight mode on boot", "type": "Int32", "values": [{"description": "Manual", "value": 0}, {"description": "Altitude", "value": 1}, {"description": "Position / Cruise", "value": 2}, {"description": "Mission", "value": 3}, {"description": "Hold", "value": 4}, {"description": "Position Slow", "value": 6}, {"description": "Altitude Cruise", "value": 8}, {"description": "Acro", "value": 10}, {"description": "Offboard", "value": 14}, {"description": "Stabilized", "value": 15}, {"description": "Takeoff", "value": 17}, {"description": "External 1", "value": 23}, {"description": "External 2", "value": 24}, {"description": "External 3", "value": 25}, {"description": "External 4", "value": 26}, {"description": "External 5", "value": 27}, {"description": "External 6", "value": 28}, {"description": "External 7", "value": 29}, {"description": "External 8", "value": 30}]}, {"category": "Standard", "default": -1, "group": "Commander", "longDesc": "The vehicle aborts the current operation and switches to Return mode when\nthe time since takeoff is above this value. It is not possible to resume the\nmission or switch to any auto mode other than Return or Land. Taking over in any manual\nmode is still possible.\n\nStarting from 90% of the maximum flight time, a warning message will be sent\nevery 1 minute with the remaining time until automatic Return.\n\nSet to -1 to disable.\n", "min": -1, "name": "COM_FLT_TIME_MAX", "shortDesc": "Maximum allowed flight time", "type": "Int32", "units": "s"}, {"category": "Standard", "default": 0, "group": "Commander", "name": "COM_FORCE_SAFETY", "shortDesc": "Re-enable safety when the vehicle disarms", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "Action the system takes when a GNSS failure is detected during flight.\nTriggers when the active GNSS count drops below SYS_HAS_NUM_GNSS (disabled\nwhen SYS_HAS_NUM_GNSS=0), or when two receivers report positions inconsistent\nwith their reported accuracy and SYS_HAS_NUM_GNSS=2 (otherwise warning only).\nThe reported accuracy of each receiver is floored with EKF2_GPS_P_NOISE.\nReturn and Land are skipped if the failure clears during the COM_FAIL_ACT_T Hold.\nAny value above Warning also blocks arming.\n", "name": "COM_GNSSLOSS_ACT", "shortDesc": "GNSS loss failsafe mode", "type": "Int32", "values": [{"description": "Warning", "value": 0}, {"description": "Return", "value": 1}, {"description": "Land", "value": 2}, {"description": "Terminate", "value": 3}, {"description": "Warning, block arming", "value": 4}]}, {"category": "Standard", "default": 120, "group": "Commander", "longDesc": "After this amount of seconds without datalink the data link lost mode triggers\n", "max": 3600, "min": 60, "name": "COM_HLDL_LOSS_T", "shortDesc": "High Latency Datalink loss time threshold", "type": "Int32", "units": "s"}, {"category": "Standard", "default": 1, "group": "Commander", "longDesc": "Set home position automatically if possible.\n\nIf disabled, home is only set manually with MAV_CMD_DO_SET_HOME.\n\nDuring missions, the latitude/longitude of the home position is locked and will not reset during intermediate landings.\nIt will only update once the mission is complete or landed outside of a mission.\nHowever, the altitude is still being adjusted to correct for GNSS vertical drift in the first 2 minutes after takeoff.\n", "name": "COM_HOME_EN", "rebootRequired": true, "shortDesc": "Home position enabled", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "If set to true, the autopilot is allowed to set its home position after takeoff\nThe true home position is back-computed if a local position is estimate if available.\nIf no local position is available, home is set to the current position.\n", "name": "COM_HOME_IN_AIR", "shortDesc": "Allows setting the home position after takeoff", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "Action when the battery drops below the critical (BAT_CRIT_THR) or emergency (BAT_EMERGEN_THR) level.\n\nOptions 3 and 4 also engage Return mode when the remaining flight time is only just enough to return (distance-aware return, with the margin set by RTL_TIME_FACTOR and RTL_TIME_MARGIN).\nThis needs a remaining flight time estimate, such as from BATn_CAPACITY or a smart battery.\nThe other options only warn.\n", "name": "COM_LOW_BAT_ACT", "shortDesc": "Battery failsafe mode", "type": "Int32", "values": [{"description": "Warning", "value": 0}, {"description": "Land mode", "value": 2}, {"description": "Distance-aware return, Critical level return, Emergency level land", "value": 3}, {"description": "Distance-aware return, Critical level return, Emergency level terminate", "value": 4}, {"description": "Critical level return, Emergency level land", "value": 5}, {"description": "Critical level return, Emergency level terminate", "value": 6}]}, {"category": "System", "default": 0, "group": "Commander", "longDesc": "This parameter is automatically set to identify external modes. It ensures that modes\nget assigned to the same index independent from their startup order,\nwhich is required when mapping an external mode to an RC switch.\n\n", "name": "COM_MODE0_HASH", "shortDesc": "External mode identifier 0", "type": "Int32", "volatile": true}, {"category": "System", "default": 0, "group": "Commander", "longDesc": "This parameter is automatically set to identify external modes. It ensures that modes\nget assigned to the same index independent from their startup order,\nwhich is required when mapping an external mode to an RC switch.\n\n", "name": "COM_MODE1_HASH", "shortDesc": "External mode identifier 1", "type": "Int32", "volatile": true}, {"category": "System", "default": 0, "group": "Commander", "longDesc": "This parameter is automatically set to identify external modes. It ensures that modes\nget assigned to the same index independent from their startup order,\nwhich is required when mapping an external mode to an RC switch.\n\n", "name": "COM_MODE2_HASH", "shortDesc": "External mode identifier 2", "type": "Int32", "volatile": true}, {"category": "System", "default": 0, "group": "Commander", "longDesc": "This parameter is automatically set to identify external modes. It ensures that modes\nget assigned to the same index independent from their startup order,\nwhich is required when mapping an external mode to an RC switch.\n\n", "name": "COM_MODE3_HASH", "shortDesc": "External mode identifier 3", "type": "Int32", "volatile": true}, {"category": "System", "default": 0, "group": "Commander", "longDesc": "This parameter is automatically set to identify external modes. It ensures that modes\nget assigned to the same index independent from their startup order,\nwhich is required when mapping an external mode to an RC switch.\n\n", "name": "COM_MODE4_HASH", "shortDesc": "External mode identifier 4", "type": "Int32", "volatile": true}, {"category": "System", "default": 0, "group": "Commander", "longDesc": "This parameter is automatically set to identify external modes. It ensures that modes\nget assigned to the same index independent from their startup order,\nwhich is required when mapping an external mode to an RC switch.\n\n", "name": "COM_MODE5_HASH", "shortDesc": "External mode identifier 5", "type": "Int32", "volatile": true}, {"category": "System", "default": 0, "group": "Commander", "longDesc": "This parameter is automatically set to identify external modes. It ensures that modes\nget assigned to the same index independent from their startup order,\nwhich is required when mapping an external mode to an RC switch.\n\n", "name": "COM_MODE6_HASH", "shortDesc": "External mode identifier 6", "type": "Int32", "volatile": true}, {"category": "System", "default": 0, "group": "Commander", "longDesc": "This parameter is automatically set to identify external modes. It ensures that modes\nget assigned to the same index independent from their startup order,\nwhich is required when mapping an external mode to an RC switch.\n\n", "name": "COM_MODE7_HASH", "shortDesc": "External mode identifier 7", "type": "Int32", "volatile": true}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "By default disabled for safety reasons\n", "name": "COM_MODE_ARM_CHK", "shortDesc": "Allow external mode registration while armed", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "The offboard loss failsafe will only be entered after a timeout,\nset by COM_OF_LOSS_T in seconds.\n", "name": "COM_OBL_RC_ACT", "shortDesc": "Set offboard loss failsafe mode", "type": "Int32", "values": [{"description": "Position mode", "value": 0}, {"description": "Altitude mode", "value": 1}, {"description": "Stabilized", "value": 2}, {"description": "Return mode", "value": 3}, {"description": "Land mode", "value": 4}, {"description": "Hold mode", "value": 5}, {"description": "Terminate", "value": 6}, {"description": "Disarm", "value": 7}]}, {"category": "Standard", "default": 1.0, "group": "Commander", "increment": 0.01, "longDesc": "Time-out to wait when offboard connection is lost before triggering offboard lost action\n\nSee COM_OBL_RC_ACT to configure action.\n", "max": 60.0, "min": 0.0, "name": "COM_OF_LOSS_T", "shortDesc": "Offboard connection loss timeout", "type": "Float", "units": "s"}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "Require a MAVLink parachute system for arming and the failsafe action when missing or unhealthy.\n\nWarning only warns without preventing arming. Actions other than Warning also prevent arming.\n", "name": "COM_PARACHUTE", "shortDesc": "Parachute requirement and failsafe", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Warning", "value": 1}, {"description": "Error", "value": 2}, {"description": "Return", "value": 3}, {"description": "Land", "value": 4}]}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "Final fallback failsafe action for loss of horizontal position in autonomous modes:\n- Descend (potential for horizontal drift on landing)\n- Flight termination (allows parachute landing)\n", "name": "COM_POS_FS_ACT", "shortDesc": "Loss of position failsafe action", "type": "Int32", "values": [{"description": "Descend mode", "value": 0}, {"description": "Terminate", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "Commander", "longDesc": "This is the horizontal position error (EPH) threshold that will trigger a failsafe.\nIf the previous position error was below this threshold, there is an additional\nfactor of 2.5 applied (threshold for invalidation 2.5 times the one for validation).\nOnly used for multicopters and VTOLs in hover mode.\nIndependent from estimator positioning data timeout threshold (see EKF2_NOAID_TOUT).\n\nSet to -1 to disable.\n", "max": 400.0, "min": -1.0, "name": "COM_POS_FS_EPH", "shortDesc": "Horizontal position error threshold for hovering systems", "type": "Float", "units": "m"}, {"category": "Standard", "default": 3, "group": "Commander", "increment": 1, "longDesc": "Action the system takes when the estimated position has an accuracy below the specified threshold.\nSee COM_POS_LOW_EPH to set the failsafe threshold.\nThe failsafe action is only executed if the vehicle is in auto mission or auto loiter mode,\notherwise it is only a warning.\n", "name": "COM_POS_LOW_ACT", "shortDesc": "Low position accuracy action", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Warning", "value": 1}, {"description": "Hold", "value": 2}, {"description": "Return", "value": 3}, {"description": "Terminate", "value": 4}, {"description": "Land", "value": 5}]}, {"category": "Standard", "default": -1.0, "group": "Commander", "longDesc": "This triggers the action specified in COM_POS_LOW_ACT if the estimated position accuracy is below this threshold.\nLocal position has to be still declared valid, which requires some kind of velocity aiding or large dead-reckoning time (EKF2_NOAID_TOUT),\nand a high failsafe threshold (COM_POS_FS_EPH).\n\nSet to -1 to disable.\n", "max": 1000.0, "min": -1.0, "name": "COM_POS_LOW_EPH", "shortDesc": "Low position accuracy failsafe threshold", "type": "Float", "units": "m"}, {"category": "Standard", "default": 1, "group": "Commander", "longDesc": "This configures a check to verify the expected number of 5V rail power supplies are present. By default only one is expected.\nNote: CBRK_SUPPLY_CHK disables all power checks including this one.\n", "max": 4, "min": 0, "name": "COM_POWER_COUNT", "shortDesc": "Required number of redundant power modules", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "Condition to enter the prearmed state, an intermediate state between disarmed and armed\nin which non-throttling actuators are active.\n\n0: Never prearmed.\n1: Prearmed when safety is off (COM_SAFETY_MODE)\n2: Always prearmed.\n", "name": "COM_PREARM_MODE", "shortDesc": "Condition to enter prearmed mode", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "When safety off", "value": 1}, {"description": "Always", "value": 2}]}, {"category": "Standard", "default": 0, "group": "Commander", "name": "COM_QC_ACT", "shortDesc": "Set action after a quadchute", "type": "Int32", "values": [{"description": "Warning only", "value": -1}, {"description": "Return mode", "value": 0}, {"description": "Land mode", "value": 1}, {"description": "Hold mode", "value": 2}]}, {"category": "Standard", "default": 95.0, "group": "Commander", "increment": 1.0, "longDesc": "The check fails if the RAM usage is above this threshold.\n\nA negative value disables the check.\n", "max": 100.0, "min": -1.0, "name": "COM_RAM_MAX", "shortDesc": "Maximum allowed RAM usage to pass checks", "type": "Float", "units": "%"}, {"bitmask": [{"description": "Mission", "index": 0}, {"description": "Auto modes", "index": 1}, {"description": "Offboard", "index": 2}, {"description": "External Mode", "index": 3}, {"description": "Altitude Cruise", "index": 4}], "category": "Standard", "default": 0, "group": "Commander", "longDesc": "Specify modes in which stick input is ignored and no failsafe action is triggered.\nExternal modes requiring stick input will still failsafe.\nAuto modes are: Hold, Takeoff, Land, Return, Descend, Follow Target, Precland, Orbit.\n", "max": 31, "min": 0, "name": "COM_RCL_EXCEPT", "shortDesc": "Manual control loss exceptions", "type": "Int32"}, {"category": "Standard", "default": 3, "group": "Commander", "longDesc": "RC receiver or MAVLink joystick (MANUAL_CONTROL). Priority modes switch to a higher-priority source as soon as it becomes valid. MAVL 1 is the lower MAVLink instance.\n", "name": "COM_RC_IN_MODE", "shortDesc": "Manual control input source configuration", "type": "Int32", "values": [{"description": "RC only (requires RC calibration)", "value": 0}, {"description": "MAVLink only (disables RC checks)", "value": 1}, {"description": "RC or MAVLink with fallback", "value": 2}, {"description": "RC or MAVLink keep first until reboot", "value": 3}, {"description": "Disable manual control", "value": 4}, {"description": "Prio: RC > MAVL 1 > MAVL 2", "value": 5}, {"description": "Prio: MAVL 1 > MAVL 2 > RC", "value": 6}, {"description": "Prio: RC > MAVL 2 > MAVL 1", "value": 7}, {"description": "Prio: MAVL 2 > MAVL 1 > RC", "value": 8}]}, {"category": "Standard", "decimalPlaces": 1, "default": 0.5, "group": "Commander", "increment": 0.1, "longDesc": "The time in seconds without a new setpoint from RC or Joystick, after which the connection is considered lost.\nThis must be kept short as the vehicle will use the last supplied setpoint until the timeout triggers.\nEnsure the value is not set lower than the update interval of the RC or Joystick.\n", "max": 35.0, "min": 0.0, "name": "COM_RC_LOSS_T", "shortDesc": "Manual control loss timeout", "type": "Float", "units": "s"}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "Condition to turn safety off. Vehicle arming is prevented for as long as safety is on.\n\n0: Always off.\n1: Safety can be turned off either by pressing a physical safety switch, or by sending a MAV_CMD_DO_SET_SAFETY_SWITCH_STATE command.\n2: Safety can only be turned off by pressing a physical safety switch. MAV_CMD_DO_SET_SAFETY_SWITCH_STATE commands are rejected.\n3: Safety can only be turned off by sending a MAV_CMD_DO_SET_SAFETY_SWITCH_STATE command. Any physical switch is ignored.\n", "name": "COM_SAFETY_MODE", "rebootRequired": true, "shortDesc": "Condition to turn safety off", "type": "Int32", "values": [{"description": "Always off", "value": 0}, {"description": "Safety switch (physical or virtual via MAVLink)", "value": 1}, {"description": "Physical safety switch only", "value": 2}, {"description": "MAVLink only", "value": 3}]}, {"category": "Standard", "decimalPlaces": 1, "default": 1.0, "group": "Commander", "increment": 0.1, "longDesc": "The minimal time from arming the motors until moving the vehicle is possible is COM_SPOOLUP_TIME seconds.\nGoal:\n- Motors and propellers spool up to idle speed before getting commanded to spin faster\n- Timeout for ESCs and smart batteries to successfulyy do failure checks\ne.g. for stuck rotors before the vehicle is off the ground\n", "max": 30.0, "min": 0.0, "name": "COM_SPOOLUP_TIME", "shortDesc": "Enforced delay between arming and further navigation", "type": "Float", "units": "s"}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "Allows to start the vehicle by throwing it into the air.\n", "name": "COM_THROW_EN", "shortDesc": "Enable throw-start", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "Commander", "increment": 0.1, "longDesc": "When the throw launch is enabled, the drone will only allow motors to spin after this speed\nis exceeded before detecting the freefall. This is a safety feature to ensure the drone does\nnot turn on after accidental drop or a rapid movement before the throw.\n\nSet to 0 to disable.\n", "min": 0.0, "name": "COM_THROW_SPEED", "shortDesc": "Minimum speed for the throw start", "type": "Float", "units": "m/s"}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "Warn about, and optionally require, a traffic avoidance system (ADS-B/FLARM\ntransponder, detected via MAVLink heartbeats with a 3 second timeout), and\ntrigger a failsafe action when it is missing or lost in flight.\n", "name": "COM_TRAFF_AVOID", "shortDesc": "Traffic avoidance system requirement and failsafe", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Warning", "value": 1}, {"description": "Error", "value": 2}, {"description": "Return", "value": 3}, {"description": "Land", "value": 4}]}, {"category": "Standard", "decimalPlaces": 1, "default": 1.0, "group": "Commander", "longDesc": "This is the horizontal velocity error (EVH) threshold that will trigger a failsafe.\nThe default is appropriate for a multicopter. Can be increased for a fixed-wing.\nIf the previous velocity error was below this threshold, there is an additional\nfactor of 2.5 applied (threshold for invalidation 2.5 times the one for validation).\n", "min": 0.0, "name": "COM_VEL_FS_EVH", "shortDesc": "Horizontal velocity error threshold", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": -1.0, "group": "Commander", "increment": 0.1, "longDesc": "Wind speed threshold above which an automatic failsafe action is triggered.\nFailsafe action can be specified with COM_WIND_MAX_ACT.\n", "min": -1.0, "name": "COM_WIND_MAX", "shortDesc": "High wind speed failsafe threshold", "type": "Float", "units": "m/s"}, {"category": "Standard", "default": 0, "group": "Commander", "increment": 1, "longDesc": "Action the system takes when a wind speed above the specified threshold is detected.\nSee COM_WIND_MAX to set the failsafe threshold.\nIf enabled, it is not possible to resume the mission or switch to any auto mode other than\nReturn or Land if this threshold is exceeded. Taking over in any manual\nmode is still possible.\n", "name": "COM_WIND_MAX_ACT", "shortDesc": "High wind failsafe mode", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Warning", "value": 1}, {"description": "Hold", "value": 2}, {"description": "Return", "value": 3}, {"description": "Terminate", "value": 4}, {"description": "Land", "value": 5}]}, {"category": "Standard", "decimalPlaces": 1, "default": -1.0, "group": "Commander", "increment": 0.1, "longDesc": "A warning is triggered if the currently estimated wind speed is above this value.\nWarning is sent periodically (every 1 minute).\n\nSet to -1 to disable.\n", "min": -1.0, "name": "COM_WIND_WARN", "shortDesc": "Wind speed warning threshold", "type": "Float", "units": "m/s"}, {"category": "Standard", "default": 0, "group": "Commander", "longDesc": "The GCS connection loss failsafe will only be entered after a timeout,\nset by COM_DL_LOSS_T in seconds. Once the timeout occurs the selected\naction will be executed.\n", "name": "NAV_DLL_ACT", "shortDesc": "Set GCS connection loss failsafe mode", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Hold mode", "value": 1}, {"description": "Return mode", "value": 2}, {"description": "Land mode", "value": 3}, {"description": "Terminate", "value": 5}, {"description": "Disarm", "value": 6}]}, {"category": "Standard", "default": 2, "group": "Commander", "longDesc": "The manual control loss failsafe will only be entered after a timeout,\nset by COM_RC_LOSS_T in seconds.\n\n\"Hold mode (no failsafe)\" does not trigger the failsafe: instead, if manual control\nis lost while actively flying a manual mode, the vehicle switches to Hold as a regular\nmode change (no failsafe state, no alarming notification). If Hold cannot be entered\n(e.g. without a valid position estimate), the normal failsafe takes over and escalates\nfrom there (Return/Land/Descend/Terminate as applicable).\n", "name": "NAV_RCL_ACT", "shortDesc": "Set manual control loss failsafe mode", "type": "Int32", "values": [{"description": "Hold mode", "value": 1}, {"description": "Return mode", "value": 2}, {"description": "Land mode", "value": 3}, {"description": "Terminate", "value": 5}, {"description": "Disarm", "value": 6}, {"description": "Hold mode (no failsafe)", "value": 7}]}, {"category": "Standard", "default": 1, "group": "Detect and Avoid", "name": "DAA_EN", "shortDesc": "Enable DAA", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 20, "group": "Detect and Avoid", "longDesc": "Time between notifications for the most urgent conflict. Set to 0 to disable the periodic status notification.\n", "max": 600, "min": 0, "name": "DAA_NOTIF_STATE", "shortDesc": "DAA status notification period", "type": "Int32", "units": "s"}, {"category": "Standard", "default": 20, "group": "Detect and Avoid", "longDesc": "Conflict age before removal.\n", "max": 120, "min": 1, "name": "DAA_TRAFF_TOUT", "shortDesc": "DAA stale conflict timeout", "type": "Int32", "units": "s"}, {"category": "Standard", "default": 10.0, "group": "Detect and Avoid F3442 Standard", "longDesc": "Used when DAA_EN_DFLT_VEL is enabled. Specific to the F3442 DAA standard.\n", "min": 0.0, "name": "DAA_DFLT_VEL", "shortDesc": "Default vertical speed of other aircraft", "type": "Float", "units": "m/s"}, {"category": "Standard", "default": 1, "group": "Detect and Avoid F3442 Standard", "longDesc": "Use DAA_DFLT_VEL instead of reported traffic vertical speed. Specific to the F3442 DAA standard.\n", "name": "DAA_EN_DFLT_VEL", "shortDesc": "Ignore reported vertical speed of other aircraft", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 1, "group": "Detect and Avoid F3442 Standard", "longDesc": "Action requested when the critical conflict level is reached.\nRuntime changes apply on later conflict level transitions.\nSpecific to the F3442 DAA standard.\n", "max": 5, "min": 0, "name": "DAA_LVL_CRIT_ACT", "shortDesc": "Critical conflict action", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Warn only", "value": 1}, {"description": "Return mode", "value": 2}, {"description": "Land mode", "value": 3}, {"description": "Position Hold mode", "value": 4}, {"description": "Terminate", "value": 5}]}, {"category": "Standard", "default": 16.0, "group": "Detect and Avoid F3442 Standard", "longDesc": "Per-aircraft half-zone. Specific to the F3442 DAA standard.\n", "min": 10.0, "name": "DAA_LVL_CRIT_HGT", "shortDesc": "Critical conflict zone cylinder height (NMAC)", "type": "Float", "units": "m"}, {"category": "Standard", "default": 77.0, "group": "Detect and Avoid F3442 Standard", "longDesc": "Per-aircraft half-zone. Specific to the F3442 DAA standard.\n", "min": 10.0, "name": "DAA_LVL_CRIT_RAD", "shortDesc": "Critical conflict zone cylinder radius (NMAC)", "type": "Float", "units": "m"}, {"category": "Standard", "default": 1, "group": "Detect and Avoid F3442 Standard", "longDesc": "Action requested when the high conflict level is reached.\nRuntime changes apply on later conflict level transitions.\nSpecific to the F3442 DAA standard.\n", "max": 5, "min": 0, "name": "DAA_LVL_HIGH_ACT", "shortDesc": "High conflict action", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Warn only", "value": 1}, {"description": "Return mode", "value": 2}, {"description": "Land mode", "value": 3}, {"description": "Position Hold mode", "value": 4}, {"description": "Terminate", "value": 5}]}, {"category": "Standard", "default": 39.0, "group": "Detect and Avoid F3442 Standard", "longDesc": "Per-aircraft half-zone. Specific to the F3442 DAA standard.\n", "min": 10.0, "name": "DAA_LVL_HIGH_HGT", "shortDesc": "High conflict zone cylinder height (WC)", "type": "Float", "units": "m"}, {"category": "Standard", "default": 305.0, "group": "Detect and Avoid F3442 Standard", "longDesc": "Per-aircraft half-zone. Specific to the F3442 DAA standard.\n", "min": 10.0, "name": "DAA_LVL_HIGH_RAD", "shortDesc": "High conflict zone cylinder radius (WC)", "type": "Float", "units": "m"}, {"category": "Standard", "default": 1, "group": "Detect and Avoid F3442 Standard", "longDesc": "Action requested when the low conflict level is reached.\nRuntime changes apply on later conflict level transitions.\nSpecific to the F3442 DAA standard.\n", "max": 5, "min": 0, "name": "DAA_LVL_LOW_ACT", "shortDesc": "Low conflict action", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Warn only", "value": 1}, {"description": "Return mode", "value": 2}, {"description": "Land mode", "value": 3}, {"description": "Position Hold mode", "value": 4}, {"description": "Terminate", "value": 5}]}, {"category": "Standard", "default": 33, "group": "Detect and Avoid F3442 Standard", "longDesc": "Expands well-clear bounds by aircraft speed times this value. Specific to the F3442 DAA standard.\n", "min": 0, "name": "DAA_LVL_LOW_TIME", "shortDesc": "Low conflict latency time", "type": "Int32", "units": "s"}, {"category": "Standard", "default": 1, "group": "Detect and Avoid F3442 Standard", "longDesc": "Action requested when the medium conflict level is reached.\nRuntime changes apply on later conflict level transitions.\nSpecific to the F3442 DAA standard.\n", "max": 5, "min": 0, "name": "DAA_LVL_MED_ACT", "shortDesc": "Medium conflict action", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Warn only", "value": 1}, {"description": "Return mode", "value": 2}, {"description": "Land mode", "value": 3}, {"description": "Position Hold mode", "value": 4}, {"description": "Terminate", "value": 5}]}, {"category": "Standard", "default": 33, "group": "Detect and Avoid F3442 Standard", "longDesc": "Expands NMAC bounds by aircraft speed times this value. Specific to the F3442 DAA standard.\n", "min": 0, "name": "DAA_LVL_MED_TIME", "shortDesc": "Medium conflict latency time", "type": "Int32", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.2, "group": "EKF2", "max": 0.5, "min": 0.0, "name": "EKF2_ABIAS_INIT", "rebootRequired": true, "shortDesc": "1-sigma IMU accelerometer switch-on bias", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "decimalPlaces": 1, "default": 25.0, "group": "EKF2", "longDesc": "If the magnitude of the IMU accelerometer vector exceeds this value, the EKF accel bias state estimation will be inhibited. This reduces the adverse effect of high manoeuvre accelerations and IMU nonlinerity and scale factor errors on the accel bias estimates.\n", "max": 200.0, "min": 20.0, "name": "EKF2_ABL_ACCLIM", "shortDesc": "Maximum IMU accel magnitude that allows IMU bias learning", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "EKF2", "longDesc": "If the magnitude of the IMU angular rate vector exceeds this value, the EKF accel bias state estimation will be inhibited. This reduces the adverse effect of rapid rotation rates and associated errors on the accel bias estimates.\n", "max": 20.0, "min": 2.0, "name": "EKF2_ABL_GYRLIM", "shortDesc": "Maximum IMU gyro angular rate magnitude that allows IMU bias learning", "type": "Float", "units": "rad/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.4, "group": "EKF2", "longDesc": "The ekf accel bias states will be limited to within a range equivalent to +- of this value.\n", "max": 0.8, "min": 0.0, "name": "EKF2_ABL_LIM", "shortDesc": "Accelerometer bias learning limit", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.5, "group": "EKF2", "longDesc": "The vector magnitude of angular rate and acceleration used to check if learning should be inhibited has a peak hold filter applied to it with an exponential decay. This parameter controls the time constant of the decay.\n", "max": 1.0, "min": 0.1, "name": "EKF2_ABL_TAU", "shortDesc": "Accel bias learning inhibit time constant", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 6, "default": 0.003, "group": "EKF2", "max": 0.01, "min": 0.0, "name": "EKF2_ACC_B_NOISE", "shortDesc": "Process noise for IMU accelerometer bias prediction", "type": "Float", "units": "m/s^3"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.35, "group": "EKF2", "max": 1.0, "min": 0.01, "name": "EKF2_ACC_NOISE", "shortDesc": "Accelerometer noise for covariance prediction", "type": "Float", "units": "m/s^2"}, {"bitmask": [{"description": "Horizontal position", "index": 0}, {"description": "Vertical position (reserved, not implemented)", "index": 1}], "category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Set bit 0 to enable the horizontal position fusion. Bit 1 is reserved for vertical position fusion, which is not implemented: the altitude is not fused, it only takes part when the global origin is first set from this source.\n", "max": 3, "min": 0, "name": "EKF2_AGP0_CTRL", "shortDesc": "Auxiliary global position sensor 0 aiding", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "EKF2", "max": 1000.0, "min": 0.0, "name": "EKF2_AGP0_DELAY", "rebootRequired": true, "shortDesc": "Auxiliary global position sensor 0 delay (to IMU)", "type": "Float", "units": "ms"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "EKF2", "longDesc": "Sets the number of standard deviations used by the innovation consistency test.\n", "min": 1.0, "name": "EKF2_AGP0_GATE", "shortDesc": "Gate size for auxiliary global position sensor 0 fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Sensor ID for slot 0. Set to 0 to disable this slot.\n", "max": 255, "min": 0, "name": "EKF2_AGP0_ID", "rebootRequired": true, "shortDesc": "Auxiliary global position sensor 0 ID", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Automatic: reset on fusion timeout if no other source of position is available Dead-reckoning: reset on fusion timeout if no source of velocity is available\n", "name": "EKF2_AGP0_MODE", "shortDesc": "Fusion reset mode for sensor 0", "type": "Int32", "values": [{"description": "Automatic", "value": 0}, {"description": "Dead-reckoning", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "EKF2", "longDesc": "Used to lower bound or replace the uncertainty included in the message\n", "min": 0.01, "name": "EKF2_AGP0_NOISE", "shortDesc": "Measurement noise for auxiliary global position sensor 0", "type": "Float", "units": "m"}, {"bitmask": [{"description": "Horizontal position", "index": 0}, {"description": "Vertical position (reserved, not implemented)", "index": 1}], "category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Set bit 0 to enable the horizontal position fusion. Bit 1 is reserved for vertical position fusion, which is not implemented: the altitude is not fused, it only takes part when the global origin is first set from this source.\n", "max": 3, "min": 0, "name": "EKF2_AGP1_CTRL", "shortDesc": "Auxiliary global position sensor 1 aiding", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "EKF2", "max": 1000.0, "min": 0.0, "name": "EKF2_AGP1_DELAY", "rebootRequired": true, "shortDesc": "Auxiliary global position sensor 1 delay (to IMU)", "type": "Float", "units": "ms"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "EKF2", "longDesc": "Sets the number of standard deviations used by the innovation consistency test.\n", "min": 1.0, "name": "EKF2_AGP1_GATE", "shortDesc": "Gate size for auxiliary global position sensor 1 fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Sensor ID for slot 1. Set to 0 to disable this slot.\n", "max": 255, "min": 0, "name": "EKF2_AGP1_ID", "rebootRequired": true, "shortDesc": "Auxiliary global position sensor 1 ID", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Automatic: reset on fusion timeout if no other source of position is available Dead-reckoning: reset on fusion timeout if no source of velocity is available\n", "name": "EKF2_AGP1_MODE", "shortDesc": "Fusion reset mode for sensor 1", "type": "Int32", "values": [{"description": "Automatic", "value": 0}, {"description": "Dead-reckoning", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "EKF2", "longDesc": "Used to lower bound or replace the uncertainty included in the message\n", "min": 0.01, "name": "EKF2_AGP1_NOISE", "shortDesc": "Measurement noise for auxiliary global position sensor 1", "type": "Float", "units": "m"}, {"bitmask": [{"description": "Horizontal position", "index": 0}, {"description": "Vertical position (reserved, not implemented)", "index": 1}], "category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Set bit 0 to enable the horizontal position fusion. Bit 1 is reserved for vertical position fusion, which is not implemented: the altitude is not fused, it only takes part when the global origin is first set from this source.\n", "max": 3, "min": 0, "name": "EKF2_AGP2_CTRL", "shortDesc": "Auxiliary global position sensor 2 aiding", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "EKF2", "max": 1000.0, "min": 0.0, "name": "EKF2_AGP2_DELAY", "rebootRequired": true, "shortDesc": "Auxiliary global position sensor 2 delay (to IMU)", "type": "Float", "units": "ms"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "EKF2", "longDesc": "Sets the number of standard deviations used by the innovation consistency test.\n", "min": 1.0, "name": "EKF2_AGP2_GATE", "shortDesc": "Gate size for auxiliary global position sensor 2 fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Sensor ID for slot 2. Set to 0 to disable this slot.\n", "max": 255, "min": 0, "name": "EKF2_AGP2_ID", "rebootRequired": true, "shortDesc": "Auxiliary global position sensor 2 ID", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Automatic: reset on fusion timeout if no other source of position is available Dead-reckoning: reset on fusion timeout if no source of velocity is available\n", "name": "EKF2_AGP2_MODE", "shortDesc": "Fusion reset mode for sensor 2", "type": "Int32", "values": [{"description": "Automatic", "value": 0}, {"description": "Dead-reckoning", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "EKF2", "longDesc": "Used to lower bound or replace the uncertainty included in the message\n", "min": 0.01, "name": "EKF2_AGP2_NOISE", "shortDesc": "Measurement noise for auxiliary global position sensor 2", "type": "Float", "units": "m"}, {"bitmask": [{"description": "Horizontal position", "index": 0}, {"description": "Vertical position (reserved, not implemented)", "index": 1}], "category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Set bit 0 to enable the horizontal position fusion. Bit 1 is reserved for vertical position fusion, which is not implemented: the altitude is not fused, it only takes part when the global origin is first set from this source.\n", "max": 3, "min": 0, "name": "EKF2_AGP3_CTRL", "shortDesc": "Auxiliary global position sensor 3 aiding", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "EKF2", "max": 1000.0, "min": 0.0, "name": "EKF2_AGP3_DELAY", "rebootRequired": true, "shortDesc": "Auxiliary global position sensor 3 delay (to IMU)", "type": "Float", "units": "ms"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "EKF2", "longDesc": "Sets the number of standard deviations used by the innovation consistency test.\n", "min": 1.0, "name": "EKF2_AGP3_GATE", "shortDesc": "Gate size for auxiliary global position sensor 3 fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Sensor ID for slot 3. Set to 0 to disable this slot.\n", "max": 255, "min": 0, "name": "EKF2_AGP3_ID", "rebootRequired": true, "shortDesc": "Auxiliary global position sensor 3 ID", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Automatic: reset on fusion timeout if no other source of position is available Dead-reckoning: reset on fusion timeout if no source of velocity is available\n", "name": "EKF2_AGP3_MODE", "shortDesc": "Fusion reset mode for sensor 3", "type": "Int32", "values": [{"description": "Automatic", "value": 0}, {"description": "Dead-reckoning", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "EKF2", "longDesc": "Used to lower bound or replace the uncertainty included in the message\n", "min": 0.01, "name": "EKF2_AGP3_NOISE", "shortDesc": "Measurement noise for auxiliary global position sensor 3", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.1, "group": "EKF2", "max": 0.5, "min": 0.0, "name": "EKF2_ANGERR_INIT", "rebootRequired": true, "shortDesc": "1-sigma tilt angle uncertainty after gravity vector alignment", "type": "Float", "units": "rad"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "EKF2", "longDesc": "Airspeed data is fused for wind estimation if above this threshold. Set to 0 to disable airspeed fusion. For reliable wind estimation both sideslip (see EKF2_FUSE_BETA) and airspeed fusion should be enabled. Only applies to fixed-wing vehicles (or VTOLs in fixed-wing mode).\n", "min": 0.0, "name": "EKF2_ARSP_THR", "shortDesc": "Airspeed fusion threshold", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 20.0, "group": "EKF2", "max": 50.0, "min": 5.0, "name": "EKF2_ASPD_MAX", "shortDesc": "Maximum airspeed used for baro static pressure compensation", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 100.0, "group": "EKF2", "max": 300.0, "min": 0.0, "name": "EKF2_ASP_DELAY", "rebootRequired": true, "shortDesc": "Airspeed measurement delay relative to IMU measurements", "type": "Float", "units": "ms"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "EKF2", "max": 300.0, "min": 0.0, "name": "EKF2_AVEL_DELAY", "rebootRequired": true, "shortDesc": "Auxiliary Velocity Estimate delay relative to IMU measurements", "type": "Float", "units": "ms"}, {"category": "Standard", "default": 1, "group": "EKF2", "longDesc": "When enabled, EKF2 fuses the relative velocity published in landing_target_pose\n(vx_rel, vy_rel) as a horizontal auxiliary velocity measurement. The data is\nonly fused when landing_target_pose.rel_vel_ekf2_valid is true.\n", "name": "EKF2_AVEL_EN", "shortDesc": "Fuse the landing-target relative velocity as auxiliary velocity", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 1, "group": "EKF2", "longDesc": "If this parameter is enabled then the estimator will make use of the barometric height measurements to estimate its height in addition to other height sources (if activated).\n", "name": "EKF2_BARO_CTRL", "shortDesc": "Barometric sensor height aiding", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "EKF2", "max": 300.0, "min": 0.0, "name": "EKF2_BARO_DELAY", "rebootRequired": true, "shortDesc": "Barometer measurement delay relative to IMU measurements", "type": "Float", "units": "ms"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "EKF2", "longDesc": "Sets the number of standard deviations used by the innovation consistency test.\n", "min": 1.0, "name": "EKF2_BARO_GATE", "shortDesc": "Gate size for barometric and GPS height fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "decimalPlaces": 2, "default": 3.5, "group": "EKF2", "max": 15.0, "min": 0.01, "name": "EKF2_BARO_NOISE", "shortDesc": "Measurement noise for barometric altitude", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 100.0, "group": "EKF2", "longDesc": "Bluff body drag along the forward/reverse axis, which scales with speed squared. Rotor drag is set by EKF2_MCOEF. Only used when EKF2_DRAG_CTRL is enabled. Set to 0 to disable for this axis.\n", "max": 200.0, "min": 0.0, "name": "EKF2_BCOEF_X", "shortDesc": "X-axis ballistic coefficient used for multi-rotor wind estimation", "type": "Float", "units": "kg/m^2"}, {"category": "Standard", "decimalPlaces": 1, "default": 100.0, "group": "EKF2", "longDesc": "Bluff body drag along the right/left axis, which scales with speed squared. Rotor drag is set by EKF2_MCOEF. Only used when EKF2_DRAG_CTRL is enabled. Set to 0 to disable for this axis.\n", "max": 200.0, "min": 0.0, "name": "EKF2_BCOEF_Y", "shortDesc": "Y-axis ballistic coefficient used for multi-rotor wind estimation", "type": "Float", "units": "kg/m^2"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "EKF2", "longDesc": "Sets the number of standard deviations used by the innovation consistency test.\n", "min": 1.0, "name": "EKF2_BETA_GATE", "shortDesc": "Gate size for synthetic sideslip fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "EKF2", "max": 1.0, "min": 0.1, "name": "EKF2_BETA_NOISE", "shortDesc": "Noise for synthetic sideslip fusion", "type": "Float", "units": "m/s"}, {"bitmask": [{"description": "use geo_lookup declination", "index": 0}, {"description": "save EKF2_MAG_DECL on disarm", "index": 1}], "category": "Standard", "default": 3, "group": "EKF2", "longDesc": "Set bits in the following positions to enable functions. 0 : Set to true to use the declination from the geo_lookup library when the GPS position becomes available, set to false to always use the EKF2_MAG_DECL value. 1 : Set to true to save the EKF2_MAG_DECL parameter to the value returned by the EKF when the vehicle disarms.\n", "max": 3, "min": 0, "name": "EKF2_DECL_TYPE", "rebootRequired": true, "shortDesc": "Integer bitmask controlling handling of magnetic declination", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 1, "default": 200.0, "group": "EKF2", "longDesc": "Defines the delay between the current time and the delayed-time horizon. This value should be at least as large as the largest EKF2_XXX_DELAY parameter.\n", "max": 1000.0, "min": 0.0, "name": "EKF2_DELAY_MAX", "rebootRequired": true, "shortDesc": "Maximum delay of all the aiding sensors", "type": "Float", "units": "ms"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Activate wind speed estimation using specific-force measurements and a drag model defined by EKF2_BCOEF_[XY] and EKF2_MCOEF. Only use on vehicles that have their thrust aligned with the Z axis and no thrust in the XY plane.\n", "name": "EKF2_DRAG_CTRL", "shortDesc": "Multirotor wind estimation selection", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 2.5, "group": "EKF2", "longDesc": "Used by the multi-rotor specific drag force model. Increasing this makes the multi-rotor wind estimates adjust more slowly.\n", "max": 10.0, "min": 0.5, "name": "EKF2_DRAG_NOISE", "shortDesc": "Specific drag force observation noise variance", "type": "Float", "units": "(m/s^2)^2"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.4, "group": "EKF2", "max": 5.0, "min": 0.5, "name": "EKF2_EAS_NOISE", "shortDesc": "Measurement noise for airspeed fusion", "type": "Float", "units": "m/s"}, {"category": "Standard", "default": 1, "group": "EKF2", "name": "EKF2_EN", "shortDesc": "EKF2 enable", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "EKF2", "longDesc": "Used to lower bound or replace the uncertainty included in the message\n", "min": 0.05, "name": "EKF2_EVA_NOISE", "shortDesc": "Measurement noise for vision angle measurements", "type": "Float", "units": "rad"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "EKF2", "longDesc": "Sets the number of standard deviations used by the innovation consistency test.\n", "min": 1.0, "name": "EKF2_EVP_GATE", "shortDesc": "Gate size for vision position fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "EKF2", "longDesc": "Used to lower bound or replace the uncertainty included in the message\n", "min": 0.01, "name": "EKF2_EVP_NOISE", "shortDesc": "Measurement noise for vision position measurements", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "EKF2", "longDesc": "Sets the number of standard deviations used by the innovation consistency test.\n", "min": 1.0, "name": "EKF2_EVV_GATE", "shortDesc": "Gate size for vision velocity estimate fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "EKF2", "longDesc": "Used to lower bound or replace the uncertainty included in the message\n", "min": 0.01, "name": "EKF2_EVV_NOISE", "shortDesc": "Measurement noise for vision velocity measurements", "type": "Float", "units": "m/s"}, {"bitmask": [{"description": "Horizontal position", "index": 0}, {"description": "Vertical position", "index": 1}, {"description": "3D velocity", "index": 2}, {"description": "Yaw", "index": 3}], "category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Set bits in the following positions to enable: 0 : Horizontal position fusion 1 : Vertical position fusion 2 : 3D velocity fusion 3 : Yaw\n", "max": 15, "min": 0, "name": "EKF2_EV_CTRL", "shortDesc": "External vision (EV) sensor aiding", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "EKF2", "max": 300.0, "min": 0.0, "name": "EKF2_EV_DELAY", "rebootRequired": true, "shortDesc": "Vision Position Estimator delay relative to IMU measurements", "type": "Float", "units": "ms"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "If set to 0 (default) the measurement noise is taken from the vision message and the EV noise parameters are used as a lower bound. If set to 1 the observation noise is set from the parameters directly,\n", "name": "EKF2_EV_NOISE_MD", "shortDesc": "External vision (EV) noise mode", "type": "Int32", "values": [{"description": "EV reported variance (parameter lower bound)", "value": 0}, {"description": "EV noise parameters", "value": 1}]}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "EKF2", "longDesc": "Forward axis with origin relative to vehicle centre of gravity\n", "name": "EKF2_EV_POS_X", "shortDesc": "X position of VI sensor focal point in body frame", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "EKF2", "longDesc": "Forward axis with origin relative to vehicle centre of gravity\n", "name": "EKF2_EV_POS_Y", "shortDesc": "Y position of VI sensor focal point in body frame", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "EKF2", "longDesc": "Forward axis with origin relative to vehicle centre of gravity\n", "name": "EKF2_EV_POS_Z", "shortDesc": "Z position of VI sensor focal point in body frame", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 0, "group": "EKF2", "longDesc": "External vision will only be started and fused if the quality metric is above this threshold. The quality metric is a completely optional field provided by some VIO systems.\n", "max": 100, "min": 0, "name": "EKF2_EV_QMIN", "shortDesc": "External vision (EV) minimum quality (optional)", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "For reliable wind estimation both sideslip and airspeed fusion (see EKF2_ARSP_THR) should be enabled. Only applies to vehicles in fixed-wing mode or with airspeed fusion active. Note: side slip fusion is currently not supported for tailsitters.\n", "name": "EKF2_FUSE_BETA", "shortDesc": "Enable synthetic sideslip fusion", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "EKF2", "max": 0.2, "min": 0.0, "name": "EKF2_GBIAS_INIT", "rebootRequired": true, "shortDesc": "1-sigma IMU gyro switch-on bias", "type": "Float", "units": "rad/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 4.0, "group": "EKF2", "longDesc": "Sets the value of deadzone applied to negative baro innovations. Deadzone is enabled when EKF2_GND_EFF_DZ > 0.\n", "max": 10.0, "min": 0.0, "name": "EKF2_GND_EFF_DZ", "shortDesc": "Baro deadzone range for height fusion", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.5, "group": "EKF2", "longDesc": "Sets the maximum distance to the ground level where negative baro innovations are expected.\n", "max": 5.0, "min": 0.0, "name": "EKF2_GND_MAX_HGT", "shortDesc": "Height above ground level for ground effect zone", "type": "Float", "units": "m"}, {"bitmask": [{"description": "Lon/lat", "index": 0}, {"description": "Altitude", "index": 1}, {"description": "3D velocity", "index": 2}, {"description": "Dual antenna heading", "index": 3}], "category": "Standard", "default": 7, "group": "EKF2", "longDesc": "Set bits in the following positions to enable: 0 : Longitude and latitude fusion 1 : Altitude fusion 2 : 3D velocity fusion 3 : Dual antenna heading fusion\n", "max": 15, "min": 0, "name": "EKF2_GPS_CTRL", "shortDesc": "GNSS sensor aiding", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Automatic: reset on fusion timeout if no other source of position is available. Dead-reckoning: reset on fusion timeout if no source of velocity is available.\n", "name": "EKF2_GPS_MODE", "shortDesc": "Fusion reset mode", "type": "Int32", "values": [{"description": "Automatic", "value": 0}, {"description": "Dead-reckoning", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "EKF2", "longDesc": "Sets the number of standard deviations used by the innovation consistency test.\n", "min": 1.0, "name": "EKF2_GPS_P_GATE", "shortDesc": "Gate size for GNSS position fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.5, "group": "EKF2", "max": 10.0, "min": 0.01, "name": "EKF2_GPS_P_NOISE", "shortDesc": "Measurement noise for GNSS position", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "EKF2", "longDesc": "Sets the number of standard deviations used by the innovation consistency test.\n", "min": 1.0, "name": "EKF2_GPS_V_GATE", "shortDesc": "Gate size for GNSS velocity fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "EKF2", "max": 5.0, "min": 0.01, "name": "EKF2_GPS_V_NOISE", "shortDesc": "Measurement noise for GNSS velocity", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 10.0, "group": "EKF2", "longDesc": "After GNSS heading fusion fails, or the heading receiver reports spoofing or jamming, EKF2 waits this long before resetting yaw to the GNSS heading.\n", "min": 0.1, "name": "EKF2_GPS_YAW_RST", "shortDesc": "GNSS heading reset wait", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "EKF2", "max": 10.0, "min": 0.1, "name": "EKF2_GRAV_NOISE", "shortDesc": "Accelerometer measurement noise for gravity based observations", "type": "Float", "units": "g0"}, {"category": "Standard", "decimalPlaces": 1, "default": 15.0, "group": "EKF2", "longDesc": "If no airspeed measurements are available, the EKF-GSF AHRS calculation will assume this value of true airspeed when compensating for centripetal acceleration during turns. Set to zero to disable centripetal acceleration compensation during fixed wing flight modes.\n", "max": 100.0, "min": 0.0, "name": "EKF2_GSF_TAS", "shortDesc": "Default value of true airspeed used in EKF-GSF AHRS calculation", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.15, "group": "EKF2", "longDesc": "The ekf gyro bias states will be limited to within a range equivalent to +- of this value.\n", "max": 0.4, "min": 0.0, "name": "EKF2_GYR_B_LIM", "shortDesc": "Gyro bias learning limit", "type": "Float", "units": "rad/s"}, {"category": "Standard", "decimalPlaces": 6, "default": 0.001, "group": "EKF2", "max": 0.01, "min": 0.0, "name": "EKF2_GYR_B_NOISE", "shortDesc": "Process noise for IMU rate gyro bias prediction", "type": "Float", "units": "rad/s^2"}, {"category": "Standard", "decimalPlaces": 4, "default": 0.015, "group": "EKF2", "max": 0.1, "min": 0.0001, "name": "EKF2_GYR_NOISE", "shortDesc": "Rate gyro noise for covariance prediction", "type": "Float", "units": "rad/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 2.6, "group": "EKF2", "longDesc": "Sets the number of standard deviations used by the innovation consistency test.\n", "min": 1.0, "name": "EKF2_HDG_GATE", "shortDesc": "Gate size for heading fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "EKF2", "max": 1.0, "min": 0.01, "name": "EKF2_HEAD_NOISE", "shortDesc": "Measurement noise for magnetic heading fusion", "type": "Float", "units": "rad"}, {"category": "Standard", "default": 1, "group": "EKF2", "longDesc": "When multiple height sources are enabled at the same time, the height estimate will always converge towards the reference height source selected by this parameter. The range sensor and vision options should only be used when for operation over a flat surface as the local NED origin will move up and down with ground level.\nIf GPS is set as reference and EKF2_GPS_CTRL is not 0, the GPS altitude is still used to initiaize the bias of the other height sensors, regardless of the altitude fusion bit in EKF2_GPS_CTRL.\n", "name": "EKF2_HGT_REF", "rebootRequired": true, "shortDesc": "Determines the reference source of height data used by the EKF", "type": "Int32", "values": [{"description": "Barometric pressure", "value": 0}, {"description": "GPS", "value": 1}, {"description": "Range sensor", "value": 2}, {"description": "Vision", "value": 3}]}, {"bitmask": [{"description": "Gyro Bias", "index": 0}, {"description": "Accel Bias", "index": 1}, {"description": "Gravity vector fusion", "index": 2}], "category": "Standard", "default": 7, "group": "EKF2", "max": 7, "min": 0, "name": "EKF2_IMU_CTRL", "shortDesc": "IMU control", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "EKF2", "longDesc": "Forward axis with origin relative to vehicle centre of gravity\n", "name": "EKF2_IMU_POS_X", "shortDesc": "X position of IMU in body frame", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "EKF2", "longDesc": "Forward axis with origin relative to vehicle centre of gravity\n", "name": "EKF2_IMU_POS_Y", "shortDesc": "Y position of IMU in body frame", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "EKF2", "longDesc": "Forward axis with origin relative to vehicle centre of gravity\n", "name": "EKF2_IMU_POS_Z", "shortDesc": "Z position of IMU in body frame", "type": "Float", "units": "m"}, {"category": "Standard", "default": 1, "group": "EKF2", "name": "EKF2_LOG_VERBOSE", "shortDesc": "Verbose logging", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.5, "group": "EKF2", "longDesc": "The heading is assumed to be observable when the body acceleration is greater than this parameter when a global position/velocity aiding source is active.\n", "max": 5.0, "min": 0.0, "name": "EKF2_MAG_ACCLIM", "shortDesc": "Horizontal acceleration threshold used for heading observability check", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "decimalPlaces": 6, "default": 0.0001, "group": "EKF2", "max": 0.1, "min": 0.0, "name": "EKF2_MAG_B_NOISE", "shortDesc": "Process noise for body magnetic field prediction", "type": "Float", "units": "gauss/s"}, {"bitmask": [{"description": "Strength (EKF2_MAG_CHK_STR)", "index": 0}, {"description": "Inclination (EKF2_MAG_CHK_INC)", "index": 1}, {"description": "Wait for WMM", "index": 2}], "category": "Standard", "default": 1, "group": "EKF2", "longDesc": "Bitmask to set which check is used to decide whether the magnetometer data is valid. If GNSS data is received, the magnetic field is compared to a World Magnetic Model (WMM), otherwise an average value is used. This check is useful to reject occasional hard iron disturbance. Set bits to 1 to enable checks. Checks enabled by the following bit positions 0 : Magnetic field strength. Set tolerance using EKF2_MAG_CHK_STR 1 : Magnetic field inclination. Set tolerance using EKF2_MAG_CHK_INC 2 : Wait for GNSS to find the theoretical strength and inclination using the WMM\n", "max": 7, "min": 0, "name": "EKF2_MAG_CHECK", "shortDesc": "Magnetic field strength test selection", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 1, "default": 20.0, "group": "EKF2", "longDesc": "Maximum allowed deviation from the expected magnetic field inclination to pass the check.\n", "max": 90.0, "min": 0.0, "name": "EKF2_MAG_CHK_INC", "shortDesc": "Magnetic field inclination check tolerance", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.2, "group": "EKF2", "longDesc": "Maximum allowed deviation from the expected magnetic field strength to pass the check.\n", "max": 1.0, "min": 0.0, "name": "EKF2_MAG_CHK_STR", "shortDesc": "Magnetic field strength check tolerance", "type": "Float", "units": "gauss"}, {"category": "System", "decimalPlaces": 1, "default": 0.0, "group": "EKF2", "name": "EKF2_MAG_DECL", "shortDesc": "Magnetic declination", "type": "Float", "units": "deg", "volatile": true}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "EKF2", "max": 300.0, "min": 0.0, "name": "EKF2_MAG_DELAY", "rebootRequired": true, "shortDesc": "Magnetometer measurement delay relative to IMU measurements", "type": "Float", "units": "ms"}, {"category": "Standard", "decimalPlaces": 6, "default": 0.001, "group": "EKF2", "max": 0.1, "min": 0.0, "name": "EKF2_MAG_E_NOISE", "shortDesc": "Process noise for earth magnetic field prediction", "type": "Float", "units": "gauss/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "EKF2", "longDesc": "Sets the number of standard deviations used by the innovation consistency test.\n", "min": 1.0, "name": "EKF2_MAG_GATE", "shortDesc": "Gate size for magnetometer XYZ component fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "EKF2", "max": 1.0, "min": 0.001, "name": "EKF2_MAG_NOISE", "shortDesc": "Measurement noise for magnetometer 3-axis fusion", "type": "Float", "units": "gauss"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Integer controlling the type of magnetometer fusion used - magnetic heading or 3-component vector. The fusion of magnetometer data as a three component vector enables vehicle body fixed hard iron errors to be learned, but requires a stable earth field. If set to 'Automatic' magnetic heading fusion is used when on-ground and 3-axis magnetic field fusion in-flight. If set to 'Magnetic heading' magnetic heading fusion is used at all times. If set to 'None' the magnetometer will not be used under any circumstance. If no external source of yaw is available, it is possible to use post-takeoff horizontal movement combined with GNSS velocity measurements to align the yaw angle. If set to 'Init' the magnetometer is only used to initialize the heading.\n", "name": "EKF2_MAG_TYPE", "rebootRequired": true, "shortDesc": "Type of magnetometer fusion", "type": "Int32", "values": [{"description": "Automatic", "value": 0}, {"description": "Magnetic heading", "value": 1}, {"description": "None", "value": 5}, {"description": "Init", "value": 6}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.15, "group": "EKF2", "longDesc": "Propeller momentum drag, which scales with speed, not speed squared. For unducted propellers of equal diameter, roughly proportional to blade area seen side-on; much higher for ducted rotors. Body drag is set by EKF2_BCOEF_X and EKF2_BCOEF_Y. Only used when EKF2_DRAG_CTRL is enabled. Set to 0 to disable for both axes.\n", "max": 1.0, "min": 0.0, "name": "EKF2_MCOEF", "shortDesc": "Propeller momentum drag coefficient for multi-rotor wind estimation", "type": "Float", "units": "1/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.01, "group": "EKF2", "longDesc": "If the vehicle is on ground, is not moving as determined by the motion test and the range finder is returning invalid or no data, then an assumed range value of EKF2_MIN_RNG will be used by the terrain estimator so that a terrain height estimate is available at the start of flight in situations where the range finder may be inside its minimum measurements distance when on ground.\n", "min": 0.01, "name": "EKF2_MIN_RNG", "shortDesc": "Expected range finder reading when on ground", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Maximum number of IMUs to use for Multi-EKF. Set 0 to disable. Requires SENS_IMU_MODE 0.\n", "max": 4, "min": 0, "name": "EKF2_MULTI_IMU", "rebootRequired": true, "shortDesc": "Multi-EKF IMUs", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Maximum number of magnetometers to use for Multi-EKF. Set 0 to disable. Requires SENS_MAG_MODE 0.\n", "max": 4, "min": 0, "name": "EKF2_MULTI_MAG", "rebootRequired": true, "shortDesc": "Multi-EKF Magnetometers", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 1, "default": 10.0, "group": "EKF2", "max": 50.0, "min": 0.5, "name": "EKF2_NOAID_NOISE", "shortDesc": "Measurement noise for non-aiding position hold", "type": "Float", "units": "m"}, {"category": "Standard", "default": 5000000, "group": "EKF2", "longDesc": "Maximum lapsed time from last fusion of measurements that constrain velocity drift before the EKF will report the horizontal nav solution as invalid\n", "max": 10000000, "min": 500000, "name": "EKF2_NOAID_TOUT", "shortDesc": "Maximum inertial dead-reckoning time", "type": "Int32", "units": "us"}, {"category": "Standard", "default": 1, "group": "EKF2", "longDesc": "Enable optical flow fusion for sensor slot 0.\n", "name": "EKF2_OF0_CTRL", "shortDesc": "Optical flow sensor 0 aiding", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "EKF2", "longDesc": "Sets the number of standard deviations used by the innovation consistency test.\n", "min": 1.0, "name": "EKF2_OF0_GATE", "shortDesc": "Gate size for optical flow sensor 0 fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Auto: use gyro from optical flow message if available, internal gyro otherwise. Internal: always use internal gyro\n", "name": "EKF2_OF0_GYR_SRC", "shortDesc": "Optical flow sensor 0 angular rate compensation source", "type": "Int32", "values": [{"description": "Auto", "value": 0}, {"description": "Internal", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.5, "group": "EKF2", "longDesc": "Measurement noise for the optical flow sensor when it's reported quality metric is at the minimum\n", "min": 0.05, "name": "EKF2_OF0_N_MAX", "shortDesc": "Optical flow sensor 0 maximum noise", "type": "Float", "units": "rad/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.15, "group": "EKF2", "longDesc": "Measurement noise for the optical flow sensor when it's reported quality metric is at the maximum\n", "min": 0.05, "name": "EKF2_OF0_N_MIN", "shortDesc": "Optical flow sensor 0 minimum noise", "type": "Float", "units": "rad/s"}, {"category": "Standard", "default": 1, "group": "EKF2", "longDesc": "Optical Flow data will only be used in air if the sensor reports a quality metric >= EKF2_OF0_QMIN\n", "max": 255, "min": 0, "name": "EKF2_OF0_QMIN", "shortDesc": "In air optical flow sensor 0 minimum quality", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Optical Flow data will only be used on the ground if the sensor reports a quality metric >= EKF2_OF0_QMINGND\n", "max": 255, "min": 0, "name": "EKF2_OF0_QMINGND", "shortDesc": "On ground optical flow sensor 0 minimum quality", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Enable optical flow fusion for sensor slot 1.\n", "name": "EKF2_OF1_CTRL", "shortDesc": "Optical flow sensor 1 aiding", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "EKF2", "longDesc": "Sets the number of standard deviations used by the innovation consistency test.\n", "min": 1.0, "name": "EKF2_OF1_GATE", "shortDesc": "Gate size for optical flow sensor 1 fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Auto: use gyro from optical flow message if available, internal gyro otherwise. Internal: always use internal gyro\n", "name": "EKF2_OF1_GYR_SRC", "shortDesc": "Optical flow sensor 1 angular rate compensation source", "type": "Int32", "values": [{"description": "Auto", "value": 0}, {"description": "Internal", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.5, "group": "EKF2", "longDesc": "Measurement noise for the optical flow sensor when it's reported quality metric is at the minimum\n", "min": 0.05, "name": "EKF2_OF1_N_MAX", "shortDesc": "Optical flow sensor 1 maximum noise", "type": "Float", "units": "rad/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.15, "group": "EKF2", "longDesc": "Measurement noise for the optical flow sensor when it's reported quality metric is at the maximum\n", "min": 0.05, "name": "EKF2_OF1_N_MIN", "shortDesc": "Optical flow sensor 1 minimum noise", "type": "Float", "units": "rad/s"}, {"category": "Standard", "default": 1, "group": "EKF2", "longDesc": "Optical Flow data will only be used in air if the sensor reports a quality metric >= EKF2_OF1_QMIN\n", "max": 255, "min": 0, "name": "EKF2_OF1_QMIN", "shortDesc": "In air optical flow sensor 1 minimum quality", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Optical Flow data will only be used on the ground if the sensor reports a quality metric >= EKF2_OF1_QMINGND\n", "max": 255, "min": 0, "name": "EKF2_OF1_QMINGND", "shortDesc": "On ground optical flow sensor 1 minimum quality", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "EKF2", "longDesc": "This is the ratio of static pressure error to dynamic pressure generated by a negative wind relative velocity along the X body axis. If the baro height estimate rises during backwards flight, then this will be a negative number.\n", "max": 0.5, "min": -0.5, "name": "EKF2_PCOEF_XN", "shortDesc": "Static pressure position error coefficient for the negative X axis", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "EKF2", "longDesc": "This is the ratio of static pressure error to dynamic pressure generated by a positive wind relative velocity along the X body axis. If the baro height estimate rises during forward flight, then this will be a negative number.\n", "max": 0.5, "min": -0.5, "name": "EKF2_PCOEF_XP", "shortDesc": "Static pressure position error coefficient for the positive X axis", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "EKF2", "longDesc": "This is the ratio of static pressure error to dynamic pressure generated by a wind relative velocity along the negative Y (LH) body axis. If the baro height estimate rises during sideways flight to the left, then this will be a negative number.\n", "max": 0.5, "min": -0.5, "name": "EKF2_PCOEF_YN", "shortDesc": "Pressure position error coefficient for the negative Y axis", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "EKF2", "longDesc": "This is the ratio of static pressure error to dynamic pressure generated by a wind relative velocity along the positive Y (RH) body axis. If the baro height estimate rises during sideways flight to the right, then this will be a negative number.\n", "max": 0.5, "min": -0.5, "name": "EKF2_PCOEF_YP", "shortDesc": "Pressure position error coefficient for the positive Y axis", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "EKF2", "longDesc": "This is the ratio of static pressure error to dynamic pressure generated by a wind relative velocity along the Z body axis.\n", "max": 0.5, "min": -0.5, "name": "EKF2_PCOEF_Z", "shortDesc": "Static pressure position error coefficient for the Z axis", "type": "Float"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "When enabled, constant position fusion is enabled when the vehicle is landeded if position has been initialized but has currently no vel/pos aiding.\n", "name": "EKF2_POS_LOCK", "shortDesc": "Enable constant position fusion while on ground", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 10000, "group": "EKF2", "longDesc": "EKF prediction period in microseconds. This should ideally be an integer multiple of the IMU time delta. Actual filter update will be an integer multiple of IMU update.\n", "max": 20000, "min": 1000, "name": "EKF2_PREDICT_US", "shortDesc": "EKF prediction period", "type": "Int32", "units": "us"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Enable/disable ranging beacon fusion.\n", "name": "EKF2_RNGBC_CTRL", "shortDesc": "Ranging beacon fusion control", "type": "Int32", "values": [{"description": "Disable ranging beacon fusion", "value": 0}, {"description": "Enable ranging beacon fusion", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "EKF2", "max": 1000.0, "min": 0.0, "name": "EKF2_RNGBC_DELAY", "rebootRequired": true, "shortDesc": "Ranging beacon measurement delay relative to IMU measurements", "type": "Float", "units": "ms"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "EKF2", "longDesc": "Sets the number of standard deviations used by the innovation consistency test.\n", "min": 1.0, "name": "EKF2_RNGBC_GATE", "shortDesc": "Gate size for ranging beacon fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "decimalPlaces": 1, "default": 30.0, "group": "EKF2", "longDesc": "Used to lower bound or replace the uncertainty included in the message\n", "max": 500.0, "min": 0.1, "name": "EKF2_RNGBC_NOISE", "shortDesc": "Measurement noise for ranging beacon fusion", "type": "Float", "units": "m"}, {"category": "Standard", "default": 5.0, "group": "EKF2", "longDesc": "If the vehicle absolute altitude exceeds this value then the estimator will not fuse range measurements to estimate its height. This only applies when conditional range aid mode is activated (EKF2_RNG_CTRL = 1).\n", "max": 10.0, "min": 1.0, "name": "EKF2_RNG_A_HMAX", "shortDesc": "Maximum height above ground allowed for conditional range aid mode", "type": "Float", "units": "m"}, {"category": "Standard", "default": 1.0, "group": "EKF2", "longDesc": "If the vehicle horizontal speed exceeds this value then the estimator will not fuse range measurements to estimate its height. This only applies when conditional range aid mode is activated (EKF2_RNG_CTRL = 1).\n", "max": 2.0, "min": 0.1, "name": "EKF2_RNG_A_VMAX", "shortDesc": "Maximum horizontal velocity allowed for conditional range aid mode", "type": "Float", "units": "m/s"}, {"category": "Standard", "default": 1, "group": "EKF2", "longDesc": "WARNING: range finders are less reliable and can have unexpected errors. For accurate height above ground, use MPC_ALT_MODE instead, unless baro errors cause problems at takeoff and landing. Fuses range as an additional height source. Conditional mode only fuses it below EKF2_RNG_A_VMAX speed and EKF2_RNG_A_HMAX height, where rotor wash corrupts the baro; for vertical takeoff and landing with no horizontal flight below EKF2_RNG_A_HMAX.\n", "name": "EKF2_RNG_CTRL", "shortDesc": "Range sensor height aiding", "type": "Int32", "values": [{"description": "Disable range fusion", "value": 0}, {"description": "Enabled (conditional mode)", "value": 1}, {"description": "Enabled", "value": 2}]}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "EKF2", "max": 300.0, "min": 0.0, "name": "EKF2_RNG_DELAY", "rebootRequired": true, "shortDesc": "Range finder measurement delay relative to IMU measurements", "type": "Float", "units": "ms"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "EKF2", "longDesc": "Limit for fog detection. If the range finder measures a distance greater than this value, the measurement is considered to not be blocked by fog or rain. If there's a jump from larger than RNG_FOG to smaller than EKF2_RNG_FOG, the measurement may gets rejected. 0 - disabled\n", "max": 20.0, "min": 0.0, "name": "EKF2_RNG_FOG", "shortDesc": "Maximum distance at which the range finder could detect fog (m)", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "EKF2", "longDesc": "Sets the number of standard deviations used by the innovation consistency test.\n", "min": 1.0, "name": "EKF2_RNG_GATE", "shortDesc": "Gate size for range finder fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "default": 1.0, "group": "EKF2", "longDesc": "To be used, the time derivative of the distance sensor measurements projected on the vertical axis needs to be statistically consistent with the estimated vertical velocity of the drone. Decrease this value to make the filter more robust against range finder faulty data (stuck, reflections, ...). Note: tune the range finder noise parameters (EKF2_RNG_NOISE and EKF2_RNG_SFE) before tuning this gate.\n", "max": 5.0, "min": 0.1, "name": "EKF2_RNG_K_GATE", "shortDesc": "Gate size used for range finder kinematic consistency check", "type": "Float", "units": "SD"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "EKF2", "min": 0.01, "name": "EKF2_RNG_NOISE", "shortDesc": "Measurement noise for range finder fusion", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "EKF2", "max": 0.75, "min": -0.75, "name": "EKF2_RNG_PITCH", "shortDesc": "Range sensor pitch offset", "type": "Float", "units": "rad"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "EKF2", "longDesc": "Forward axis with origin relative to vehicle centre of gravity\n", "name": "EKF2_RNG_POS_X", "shortDesc": "X position of range finder origin in body frame", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "EKF2", "longDesc": "Forward axis with origin relative to vehicle centre of gravity\n", "name": "EKF2_RNG_POS_Y", "shortDesc": "Y position of range finder origin in body frame", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "EKF2", "longDesc": "Forward axis with origin relative to vehicle centre of gravity\n", "name": "EKF2_RNG_POS_Z", "shortDesc": "Z position of range finder origin in body frame", "type": "Float", "units": "m"}, {"category": "Standard", "default": 1.0, "group": "EKF2", "longDesc": "Minimum duration during which the reported range finder signal quality needs to be non-zero in order to be declared valid (s)\n", "max": 5.0, "min": 0.1, "name": "EKF2_RNG_QLTY_T", "shortDesc": "Minimum range validity period", "type": "Float", "units": "s"}, {"category": "Standard", "default": 0.05, "group": "EKF2", "longDesc": "Specifies the increase in range finder noise with range.\n", "max": 0.2, "min": 0.0, "name": "EKF2_RNG_SFE", "shortDesc": "Range finder range dependent noise scaler", "type": "Float", "units": "m/m"}, {"category": "Standard", "default": 0.2, "group": "EKF2", "longDesc": "EKF2 instances have to be better than the selected by at least this amount before their relative score can be reduced.\n", "name": "EKF2_SEL_ERR_RED", "shortDesc": "Selector error reduce threshold", "type": "Float"}, {"category": "Standard", "default": 1.0, "group": "EKF2", "longDesc": "EKF2 selector acceleration error threshold for comparing accelerometers. Acceleration vector differences larger than this will result in accumulated velocity error.\n", "name": "EKF2_SEL_IMU_ACC", "shortDesc": "Selector acceleration threshold", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "default": 15.0, "group": "EKF2", "longDesc": "EKF2 selector maximum accumulated angular error threshold for comparing gyros. Accumulated angular error larger than this will result in the sensor being declared faulty.\n", "name": "EKF2_SEL_IMU_ANG", "shortDesc": "Selector angular threshold", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 7.0, "group": "EKF2", "longDesc": "EKF2 selector angular rate error threshold for comparing gyros. Angular rate vector differences larger than this will result in accumulated angular error.\n", "name": "EKF2_SEL_IMU_RAT", "shortDesc": "Selector angular rate threshold", "type": "Float", "units": "deg/s"}, {"category": "Standard", "default": 2.0, "group": "EKF2", "longDesc": "EKF2 selector maximum accumulated velocity threshold for comparing accelerometers. Accumulated velocity error larger than this will result in the sensor being declared faulty.\n", "name": "EKF2_SEL_IMU_VEL", "shortDesc": "Selector angular threshold", "type": "Float", "units": "m/s"}, {"bitmask": [{"description": "GNSS 0", "index": 0}, {"description": "GNSS 1", "index": 1}, {"description": "Optical flow", "index": 2}, {"description": "External vision", "index": 3}, {"description": "Aux global position 0", "index": 4}, {"description": "Aux global position 1", "index": 5}, {"description": "Aux global position 2", "index": 6}, {"description": "Aux global position 3", "index": 7}, {"description": "Barometer", "index": 8}, {"description": "Range finder", "index": 9}, {"description": "Magnetometer", "index": 10}, {"description": "Airspeed", "index": 11}, {"description": "Ranging beacon", "index": 12}], "category": "Standard", "default": 8191, "group": "EKF2", "longDesc": "Bitmask to control which sensor fusion sources are enabled. Sources whose bit is cleared will be disabled. Only applied while disarmed. For in-flight changes use the MAVLink command VEHICLE_CMD_ESTIMATOR_SENSOR_ENABLE or the individual CTRL params (e.g. EKF2_GPS_CTRL, EKF2_BARO_CTRL).\n", "max": 8191, "min": 0, "name": "EKF2_SENS_EN", "shortDesc": "Sensor fusion enable bitmask", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "EKF2", "longDesc": "Use for vehicles where the measured body Z magnetic field is subject to strong magnetic interference. For magnetic heading fusion the magnetometer Z measurement will be replaced by a synthetic value calculated using the knowledge of the 3D magnetic field vector at the location of the drone. Therefore, this parameter will only have an effect if the global position of the drone is known. For 3D mag fusion the magnetometer Z measurement will simply be ignored instead of fusing the synthetic value.\n", "name": "EKF2_SYNT_MAG_Z", "shortDesc": "Enable synthetic magnetometer Z component measurement", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "EKF2", "longDesc": "Sets the number of standard deviations used by the innovation consistency test.\n", "min": 1.0, "name": "EKF2_TAS_GATE", "shortDesc": "Gate size for TAS fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.25, "group": "EKF2", "longDesc": "Controls how tightly the output track the EKF states\n", "max": 1.0, "min": 0.1, "name": "EKF2_TAU_POS", "shortDesc": "Output predictor position time constant", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.25, "group": "EKF2", "max": 1.0, "name": "EKF2_TAU_VEL", "shortDesc": "Time constant of the velocity output prediction and smoothing filter", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.5, "group": "EKF2", "min": 0.0, "name": "EKF2_TERR_GRAD", "shortDesc": "Magnitude of terrain gradient", "type": "Float", "units": "m/m"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "EKF2", "min": 0.5, "name": "EKF2_TERR_NOISE", "shortDesc": "Terrain altitude process noise", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 100.0, "group": "EKF2", "longDesc": "Each axis of the velocity state is constrained to this magnitude. GNSS and external vision velocity samples beyond it are not fused.\n", "max": 299792458.0, "name": "EKF2_VEL_LIM", "shortDesc": "Velocity limit", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "EKF2", "longDesc": "When unaided, the wind estimate uncertainty (1-sigma, in m/s) increases by this amount every second.\n", "max": 1.0, "min": 0.0, "name": "EKF2_WIND_NSD", "shortDesc": "Process noise spectral density for wind velocity prediction", "type": "Float", "units": "m/s^2/sqrt(Hz)"}, {"category": "Standard", "decimalPlaces": 1, "default": 90.0, "group": "ESC", "increment": 1.0, "longDesc": "Warning only, no failsafe or arming blocked.\n-1 disables the check.\n", "max": 150.0, "min": -1.0, "name": "ESC_TEMP_WARN_TH", "shortDesc": "ESC temperature warning threshold", "type": "Float", "units": "celcius"}, {"category": "Standard", "default": 0, "group": "Events", "longDesc": "Enable/disable event task for RC Loss. When enabled, an alarm tune will be\nplayed via buzzer or ESCs, if supported. The alarm will sound after a disarm,\nif the vehicle was previously armed and only if the vehicle had RC signal at\nsome point. Particularly useful for locating crashed drones without a GPS\nsensor.\n", "name": "EV_TSK_RC_LOSS", "rebootRequired": true, "shortDesc": "RC Loss Alarm", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Events", "longDesc": "Enable/disable event task for displaying the vehicle status using arm-mounted\nLEDs. When enabled and if the vehicle supports it, LEDs will flash\nindicating various vehicle status changes. Currently PX4 has not implemented\nany specific status events.\n", "name": "EV_TSK_STAT_DIS", "rebootRequired": true, "shortDesc": "Status Display", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 30.0, "group": "FW Attitude Control", "increment": 0.5, "longDesc": "Pitch angle commanded by full stick deflection, relative to FW_PSP_OFF (the centred-stick pitch).\nThe resulting pitch setpoint is additionally limited to this angle around level,\nso with a non-zero FW_PSP_OFF the range is not symmetric.\nApplies in all manual modes with attitude stabilization but without altitude control.\n", "max": 90.0, "min": 0.0, "name": "FW_MAN_P_MAX", "shortDesc": "Maximum manual pitch angle", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 1, "default": 45.0, "group": "FW Attitude Control", "increment": 0.5, "longDesc": "Applies to both directions in all manual modes with attitude stabilization\n", "max": 90.0, "min": 0.0, "name": "FW_MAN_R_MAX", "shortDesc": "Maximum manual roll angle", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 1, "default": 30.0, "group": "FW Attitude Control", "increment": 0.5, "longDesc": "This is the maximally added yaw rate setpoint from the yaw stick in any attitude controlled flight mode.\nIt is added to the yaw rate setpoint generated by the controller for turn coordination.\n", "min": 0.0, "name": "FW_MAN_YR_MAX", "shortDesc": "Maximum manually added yaw rate", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "FW Attitude Control", "increment": 0.5, "longDesc": "Pitch angle of the body x-axis above the horizon in level flight at trim airspeed (FW_AIRSPD_TRIM).\n\nThe altitude and airspeed controller (TECS) uses it as the pitch at zero climb angle,\nand in Stabilized mode the centred pitch stick commands it.\nPitch setpoints and pitch limits set elsewhere, for example FW_P_LIM_MIN and FW_P_LIM_MAX,\nare absolute and do not include it.\n", "max": 90.0, "min": -90.0, "name": "FW_PSP_OFF", "shortDesc": "Pitch setpoint offset (pitch at level flight)", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 1, "default": 60.0, "group": "FW Attitude Control", "increment": 0.5, "max": 180.0, "min": 0.0, "name": "FW_P_RMAX_NEG", "shortDesc": "Maximum negative / down pitch rate setpoint", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 60.0, "group": "FW Attitude Control", "increment": 0.5, "max": 180.0, "min": 0.0, "name": "FW_P_RMAX_POS", "shortDesc": "Maximum positive / up pitch rate setpoint", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.4, "group": "FW Attitude Control", "increment": 0.05, "longDesc": "This defines the latency between a pitch step input and the achieved setpoint\n(inverse to a P gain). Smaller systems may require smaller values.\n", "max": 1.0, "min": 0.2, "name": "FW_P_TC", "shortDesc": "Attitude pitch time constant", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 70.0, "group": "FW Attitude Control", "increment": 0.5, "max": 180.0, "min": 0.0, "name": "FW_R_RMAX", "shortDesc": "Maximum roll rate setpoint", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.4, "group": "FW Attitude Control", "increment": 0.05, "longDesc": "This defines the latency between a roll step input and the achieved setpoint\n(inverse to a P gain). Smaller systems may require smaller values.\n", "max": 1.0, "min": 0.2, "name": "FW_R_TC", "shortDesc": "Attitude Roll Time Constant", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.2, "group": "FW Attitude Control", "increment": 0.05, "max": 10.0, "min": 0.0, "name": "FW_WR_FF", "shortDesc": "Wheel steering rate feed forward", "type": "Float", "units": "%/rad/s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.1, "group": "FW Attitude Control", "increment": 0.005, "longDesc": "This gain defines how much control response will result out of a steady\nstate error. It trims any constant error.\n", "max": 10.0, "min": 0.0, "name": "FW_WR_I", "shortDesc": "Wheel steering rate integrator gain", "type": "Float", "units": "%/rad"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.4, "group": "FW Attitude Control", "increment": 0.05, "max": 1.0, "min": 0.0, "name": "FW_WR_IMAX", "shortDesc": "Wheel steering rate integrator limit", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.5, "group": "FW Attitude Control", "increment": 0.005, "longDesc": "This defines how much the wheel steering input will be commanded depending on the\ncurrent body angular rate error.\n", "max": 10.0, "min": 0.0, "name": "FW_WR_P", "shortDesc": "Wheel steering rate proportional gain", "type": "Float", "units": "%/rad/s"}, {"category": "Standard", "default": 0, "group": "FW Attitude Control", "longDesc": "Only enabled during automatic runway takeoff and landing.\nIn all manual modes the wheel is directly controlled with yaw stick.\n", "name": "FW_W_EN", "shortDesc": "Enable wheel steering controller", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 30.0, "group": "FW Attitude Control", "increment": 0.5, "longDesc": "This limits the maximum wheel steering rate the controller will output (in degrees per\nsecond).\n", "max": 90.0, "min": 0.0, "name": "FW_W_RMAX", "shortDesc": "Maximum wheel steering rate", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 50.0, "group": "FW Attitude Control", "increment": 0.5, "max": 180.0, "min": 0.0, "name": "FW_Y_RMAX", "shortDesc": "Maximum yaw rate setpoint", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "FW Auto Landing", "increment": 0.01, "longDesc": "Sets a fraction of full flaps during landing.\nAlso applies to flaperons if enabled in the mixer/allocation.\n", "max": 1.0, "min": 0.0, "name": "FW_FLAPS_LND_SCL", "shortDesc": "Flaps setting during landing", "type": "Float", "units": "norm"}, {"bitmask": [{"description": "Abort if terrain is not found (only applies to mission landings)", "index": 0}, {"description": "Abort if terrain times out (after a first successful measurement)", "index": 1}], "category": "Standard", "default": 3, "group": "FW Auto Landing", "longDesc": "Terrain estimation:\nbit 0: Abort if terrain is not found\nbit 1: Abort if terrain times out (after a first successful measurement)\n\nThe last estimate is always used as ground, whether the last valid measurement or the land waypoint, depending on the\nselected abort criteria, until an abort condition is entered. If FW_LND_USETER == 0, these bits are ignored.\n\nTODO: Extend automatic abort conditions\ne.g. glide slope tracking error (horizontal and vertical)\n", "max": 3, "min": 0, "name": "FW_LND_ABORT", "shortDesc": "Bit mask to set the automatic landing abort conditions", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 1, "default": -1.0, "group": "FW Auto Landing", "increment": 0.1, "longDesc": "The calibrated airspeed setpoint during landing.\n\nIf set <= 0, landing airspeed = FW_AIRSPD_MIN by default.\n", "min": -1.0, "name": "FW_LND_AIRSPD", "shortDesc": "Landing airspeed", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "FW Auto Landing", "increment": 0.5, "longDesc": "Typically the desired landing slope angle when landing configuration (flaps, airspeed) is enabled.\nSet this value within the vehicle's performance limits.\n", "max": 45.0, "min": 1.0, "name": "FW_LND_ANG", "shortDesc": "Maximum landing slope angle", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 0, "group": "FW Auto Landing", "longDesc": "Allows to deploy the landing configuration (flaps, landing airspeed, etc.) already in\nthe loiter-down waypoint before the final approach.\nOtherwise is enabled only in the final approach.\n", "name": "FW_LND_EARLYCFG", "shortDesc": "Early landing configuration deployment", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 0.5, "group": "FW Auto Landing", "increment": 0.5, "longDesc": "NOTE: max(FW_LND_FLALT, FW_LND_FL_TIME * |z-velocity|) is taken as the flare altitude\n\nSet FW_LND_FLALT or FW_LND_FL_TIME to -1 to disable the flare (land on the glide slope at landing airspeed).\n", "min": -1.0, "name": "FW_LND_FLALT", "shortDesc": "Landing flare altitude (relative to landing altitude)", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 15.0, "group": "FW Auto Landing", "increment": 0.5, "longDesc": "Maximum pitch during landing flare.\n", "max": 45.0, "min": 0.0, "name": "FW_LND_FL_PMAX", "shortDesc": "Flare, maximum absolute pitch", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 1, "default": 2.5, "group": "FW Auto Landing", "increment": 0.5, "longDesc": "Minimum pitch during landing flare.\n", "max": 15.0, "min": -5.0, "name": "FW_LND_FL_PMIN", "shortDesc": "Flare, minimum absolute pitch", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.25, "group": "FW Auto Landing", "increment": 0.1, "longDesc": "TECS will attempt to control the aircraft to this sink rate via pitch angle (throttle killed during flare)\n", "max": 2.0, "min": 0.0, "name": "FW_LND_FL_SINK", "shortDesc": "Landing flare sink rate", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.0, "group": "FW Auto Landing", "increment": 0.1, "longDesc": "Multiplied by the descent rate to calculate a dynamic altitude at which\nto trigger the flare.\n\nNOTE: max(FW_LND_FLALT, FW_LND_FL_TIME * descent rate) is taken as the flare altitude\n\nSet FW_LND_FLALT or FW_LND_FL_TIME to -1 to disable the flare (land on the glide slope at landing airspeed).\n", "max": 5.0, "min": -1.0, "name": "FW_LND_FL_TIME", "shortDesc": "Landing flare time", "type": "Float", "units": "s"}, {"category": "Standard", "default": 2, "group": "FW Auto Landing", "longDesc": "Approach angle nudging: shifts the touchdown point laterally while keeping the approach entrance point constant\nApproach path nudging: shifts the touchdown point laterally along with the entire approach path\n\nThis is useful for manually adjusting the landing point in real time when map or GNSS errors cause an offset from the\ndesired landing vector. Nudging is done with yaw stick, constrained to FW_LND_TD_OFF (in meters) and the direction is\nrelative to the vehicle heading (stick deflection to the right = land point moves to the right as seen by the vehicle).\n", "max": 2, "min": 0, "name": "FW_LND_NUDGE", "shortDesc": "Landing touchdown nudging option", "type": "Int32", "values": [{"description": "Disable nudging", "value": 0}, {"description": "Nudge approach angle", "value": 1}, {"description": "Nudge approach path", "value": 2}]}, {"category": "Standard", "decimalPlaces": 1, "default": 20.0, "group": "FW Auto Landing", "increment": 0.5, "longDesc": "Altitude the vehicle descends to and holds for the release. The release happens\nhigher if the predicted touchdown point reaches the landing point while still on\nthe approach slope, or lower for a vehicle that cannot hold the altitude, but\nnever below 3 seconds of descent at FW_LND_PARA_SINK, so that the canopy has\nroom to open.\n\nLower values reduce the wind drift of the touchdown point.\n", "min": 1.0, "name": "FW_LND_PARA_ALT", "shortDesc": "Parachute landing release altitude above ground", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "FW Auto Landing", "longDesc": "If enabled, the vehicle follows the mission landing approach down to the release\naltitude (FW_LND_PARA_ALT) and releases the parachute by triggering flight\ntermination, such that the predicted touchdown point under canopy lies on the\nlanding point, accounting for ground speed, estimated wind drift during the descent\n(FW_LND_PARA_SINK) and the forward carry while the parachute deploys.\n\nThe parachute is released through the flight termination failsafe outputs, or an\nexternal parachute system (COM_PARACHUTE). Not supported on VTOL.\n", "name": "FW_LND_PARA_EN", "shortDesc": "Enable parachute landing on mission landing approach", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "FW Auto Landing", "increment": 0.1, "longDesc": "Expected steady-state sink rate under canopy. Used to predict the descent duration and\ntherewith the wind drift of the touchdown point.\n", "min": 0.1, "name": "FW_LND_PARA_SINK", "shortDesc": "Sink rate under the deployed parachute", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "FW Auto Landing", "increment": 1.0, "max": 10.0, "min": 0.0, "name": "FW_LND_TD_OFF", "shortDesc": "Maximum lateral position offset for the touchdown point", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": -1.0, "group": "FW Auto Landing", "increment": 0.1, "longDesc": "This is the time after the start of flaring that we expect the vehicle to touch the runway.\nAt this time, a 0.5s clamp down ramp will engage, constraining the pitch setpoint to RWTO_PSP.\nIf enabled, ensure that RWTO_PSP is configured appropriately for full gear contact on ground roll.\n\nSet to -1.0 to disable touchdown clamping. E.g. it may not be desirable to clamp on belly landings.\n\nThe touchdown time will be constrained to be greater than or equal to the flare time (FW_LND_FL_TIME).\n", "max": 5.0, "min": -1.0, "name": "FW_LND_TD_TIME", "shortDesc": "Landing touchdown time (since flare start)", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.0, "group": "FW Auto Landing", "increment": 0.1, "longDesc": "The TECS altitude time constant (FW_T_ALT_TC) is multiplied by this value.\n", "max": 1.0, "min": 0.2, "name": "FW_LND_THRTC_SC", "shortDesc": "Altitude time constant factor for landing and low-height flight", "type": "Float"}, {"category": "Standard", "default": 1, "group": "FW Auto Landing", "longDesc": "This is critical for detecting when to flare, and should be enabled if possible.\n\nIf enabled and no measurement is found within a given timeout, the landing waypoint altitude will be used OR the landing\nwill be aborted, depending on the criteria set in FW_LND_ABORT.\n\nIf disabled, FW_LND_ABORT terrain based criteria are ignored.\n", "max": 2, "min": 0, "name": "FW_LND_USETER", "shortDesc": "Use terrain estimation during landing", "type": "Int32", "values": [{"description": "Disable the terrain estimate", "value": 0}, {"description": "Use the terrain estimate to trigger the flare (only)", "value": 1}, {"description": "Calculate landing glide slope relative to the terrain estimate", "value": 2}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "FW Auto Landing", "increment": 0.01, "max": 1.0, "min": 0.0, "name": "FW_SPOILERS_LND", "shortDesc": "Spoiler landing setting", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "FW Auto Takeoff", "increment": 0.01, "longDesc": "Sets a fraction of full flaps during take-off.\nAlso applies to flaperons if enabled in the mixer/allocation.\n", "max": 1.0, "min": 0.0, "name": "FW_FLAPS_TO_SCL", "shortDesc": "Flaps setting during take-off", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.05, "group": "FW Auto Takeoff", "increment": 0.05, "longDesc": "Launch is detected when the norm of body acceleration is above FW_LAUN_AC_THLD for FW_LAUN_AC_T seconds.\n", "max": 5.0, "min": 0.0, "name": "FW_LAUN_AC_T", "shortDesc": "Trigger time", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 30.0, "group": "FW Auto Takeoff", "increment": 0.5, "longDesc": "Launch is detected when the norm of body acceleration is above FW_LAUN_AC_THLD for FW_LAUN_AC_T seconds.\n", "min": 0.0, "name": "FW_LAUN_AC_THLD", "shortDesc": "Trigger acceleration threshold", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "FW Auto Takeoff", "increment": 1.0, "longDesc": "Height above the launch point below which the vehicle holds the wind-compensated launch bearing\ninstead of the normal line-following guidance, and the roll limit is ramped linearly from 0 at\nthe launch point up to FW_R_LIM at this altitude, so that a poor heading estimate or a bad launch\ncannot induce a large bank close to the ground. Only relevant for hand- or catapult-launched\nvehicles (FW_LAUN_DETCN_ON).\n", "min": 0.0, "name": "FW_LAUN_CLR_ALT", "shortDesc": "Launch climbout clearance altitude", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "FW Auto Takeoff", "increment": 0.1, "longDesc": "Locks control surfaces during pre-launch (armed) and until this time since launch has passed.\nOnly affects control surfaces that have corresponding flag set, and not active for runway takeoff.\nSet to 0 to disable any surface locking after arming.\n", "min": 0.0, "name": "FW_LAUN_CS_LK_DY", "shortDesc": "Control surface launch delay", "type": "Float", "units": "s"}, {"category": "Standard", "default": 0, "group": "FW Auto Takeoff", "longDesc": "Enables automatic launch detection based on measured acceleration. Use for hand- or catapult-launched vehicles.\nNot compatible with runway takeoff.\n", "name": "FW_LAUN_DETCN_ON", "shortDesc": "Fixed-wing launch detection", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "FW Auto Takeoff", "increment": 0.5, "longDesc": "Start the motor(s) this amount of seconds after launch is detected.\n", "max": 10.0, "min": 0.0, "name": "FW_LAUN_MOT_DEL", "shortDesc": "Motor delay", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": -1.0, "group": "FW Auto Takeoff", "increment": 0.1, "longDesc": "The calibrated airspeed setpoint during the takeoff climbout.\n\nIf set <= 0, FW_AIRSPD_MIN will be set by default.\n", "min": -1.0, "name": "FW_TKO_AIRSPD", "shortDesc": "Takeoff Airspeed", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "FW Auto Takeoff", "increment": 1.0, "longDesc": "Ends the takeoff climbout this many seconds after the vehicle started climbing, instead of\nwhen the takeoff altitude is reached.\n\nIf set to 0, the climbout ends at the takeoff altitude.\n", "min": 0.0, "name": "FW_TKO_CLMB_T", "shortDesc": "Takeoff climbout duration", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 10.0, "group": "FW Auto Takeoff", "increment": 0.5, "max": 80.0, "min": -5.0, "name": "FW_TKO_PITCH_MIN", "shortDesc": "Minimum absolute pitch during takeoff", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 30, "group": "FW General", "longDesc": "The time the system should do open loop loiter and wait for GPS recovery\nbefore it starts descending. Set to 0 to disable. Roll angle is set to FW_GPSF_R.\nDoes only apply for fixed-wing vehicles or VTOLs with NAV_FORCE_VT set to 0.\n", "min": 0, "name": "FW_GPSF_LT", "shortDesc": "GPS failure loiter time", "type": "Int32", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 15.0, "group": "FW General", "increment": 0.5, "longDesc": "Roll angle in GPS failure loiter mode.\n", "max": 60.0, "min": 0.0, "name": "FW_GPSF_R", "shortDesc": "GPS failure fixed roll angle", "type": "Float", "units": "deg"}, {"bitmask": [{"description": "Alternative stick configuration (height rate on throttle stick, airspeed on pitch stick)", "index": 0}, {"description": "Enable airspeed setpoint via sticks in altitude and position flight mode", "index": 1}], "category": "Standard", "default": 2, "group": "FW General", "longDesc": "Applies in manual Position and Altitude flight modes.\n", "max": 3, "min": 0, "name": "FW_POS_STK_CONF", "shortDesc": "Custom stick configuration", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 1, "default": 30.0, "group": "FW General", "increment": 0.5, "longDesc": "Applies in any altitude controlled flight mode.\n", "max": 80.0, "min": 0.0, "name": "FW_P_LIM_MAX", "shortDesc": "Maximum absolute pitch angle setpoint", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 1, "default": -30.0, "group": "FW General", "increment": 0.5, "longDesc": "Applies in any altitude controlled flight mode.\n", "max": 0.0, "min": -60.0, "name": "FW_P_LIM_MIN", "shortDesc": "Minimum absolute pitch angle setpoint", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 1, "default": 50.0, "group": "FW General", "increment": 0.5, "longDesc": "Applies in any altitude controlled flight mode.\n", "max": 75.0, "min": 35.0, "name": "FW_R_LIM", "shortDesc": "Maximum roll angle setpoint", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "FW General", "increment": 0.01, "longDesc": "This is the minimum throttle while on the ground (\"landed\") in auto modes.\n", "max": 1.0, "min": 0.0, "name": "FW_THR_IDLE", "shortDesc": "Idle throttle", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "FW General", "increment": 0.01, "longDesc": "Applies in any altitude controlled flight mode.\nShould be set accordingly to achieve FW_T_CLMB_MAX.\n", "max": 1.0, "min": 0.0, "name": "FW_THR_MAX", "shortDesc": "Throttle limit max", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "FW General", "increment": 0.01, "longDesc": "Applies in any altitude controlled flight mode.\nUsually set to 0 but can be increased to prevent the motor from stopping when\ndescending, which can increase achievable descent rates.\n", "max": 1.0, "min": 0.0, "name": "FW_THR_MIN", "shortDesc": "Throttle limit min", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 2, "default": 3.0, "group": "FW General", "increment": 0.01, "longDesc": "In auto modes: default climb rate output by controller to achieve altitude setpoints.\nIn manual modes: maximum climb rate setpoint.\n", "min": 0.1, "name": "FW_T_CLMB_R_SP", "shortDesc": "Default target climbrate", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 2.0, "group": "FW General", "increment": 0.01, "longDesc": "In auto modes: default sink rate output by controller to achieve altitude setpoints.\nIn manual modes: maximum sink rate setpoint.\n", "min": 0.1, "name": "FW_T_SINK_R_SP", "shortDesc": "Default target sinkrate", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.0, "group": "FW General", "increment": 1.0, "longDesc": "Adjusts the amount of weighting that the pitch control\napplies to speed vs height errors.\n0 -> control height only\n2 -> control speed only (gliders)\nUp to a weight of 1, pitch only trades height for speed up to trim airspeed;\naccelerating above trim is left to the throttle. Between 1 and 2, pitch\nincreasingly tracks airspeed setpoints above trim as well.\n", "max": 2.0, "min": 0.0, "name": "FW_T_SPDWEIGHT", "shortDesc": "Speed <--> Altitude weight", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.5, "group": "FW General", "increment": 1.0, "longDesc": "This is used to constrain a minimum altitude below which we keep wings level to avoid wing tip strike. It's safer\nto give a slight margin here (> 0m)\n", "min": 0.0, "name": "FW_WING_HEIGHT", "shortDesc": "Height (AGL) of the wings when the aircraft is on the ground", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "FW General", "increment": 0.1, "longDesc": "This is used for limiting the roll setpoint near the ground. (if multiple wings, take the longest span)\n", "min": 0.1, "name": "FW_WING_SPAN", "shortDesc": "The aircraft's wing span (length from tip to tip)", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 0, "default": 90.0, "group": "FW Lateral Control", "increment": 1.0, "longDesc": "Maximum change in roll angle setpoint per second.\nApplied in all Auto modes, plus manual Position & Altitude modes.\n", "min": 0.0, "name": "FW_PN_R_SLEW_MAX", "shortDesc": "Path navigation roll slew rate limit", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "FW Longitudinal Control", "increment": 0.5, "longDesc": "The controller will increase the commanded airspeed to maintain\nthis minimum groundspeed to the next waypoint.\n", "max": 40.0, "min": 0.0, "name": "FW_GND_SPD_MIN", "shortDesc": "Minimum groundspeed", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "FW Longitudinal Control", "increment": 0.01, "longDesc": "Maximum slew rate for the commanded throttle\n", "max": 1.0, "min": 0.0, "name": "FW_THR_SLEW_MAX", "shortDesc": "Throttle max slew rate", "type": "Float", "units": "1/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 5.0, "group": "FW Longitudinal Control", "increment": 0.5, "min": 2.0, "name": "FW_T_ALT_TC", "shortDesc": "Altitude error time constant", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 0, "default": -1.0, "group": "FW Longitudinal Control", "longDesc": "Minimum altitude error needed to descend with max airspeed and minimal throttle.\nA negative value disables fast descend.\n", "min": -1.0, "name": "FW_T_F_ALT_ERR", "shortDesc": "Fast descend: minimum altitude error", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.5, "group": "FW Longitudinal Control", "increment": 0.05, "max": 1.0, "min": 0.0, "name": "FW_T_HRATE_FF", "shortDesc": "Height rate feed forward", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "FW Longitudinal Control", "increment": 0.05, "longDesc": "Increase it to trim out speed and height offsets faster,\nwith the downside of possible overshoots and oscillations.\n", "max": 2.0, "min": 0.0, "name": "FW_T_I_GAIN_PIT", "shortDesc": "Integrator gain pitch", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "FW Longitudinal Control", "increment": 0.1, "max": 2.0, "min": 0.0, "name": "FW_T_PTCH_DAMP", "shortDesc": "Pitch damping gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 15.0, "group": "FW Longitudinal Control", "increment": 0.5, "longDesc": "Is used to compensate for the additional drag created by turning.\nIncrease this gain if the aircraft initially loses energy in turns\nand reduce if the aircraft initially gains energy in turns.\n", "max": 20.0, "min": 0.0, "name": "FW_T_RLL2THR", "shortDesc": "Roll -> Throttle feedforward", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "FW Longitudinal Control", "increment": 0.01, "max": 3.0, "min": 0.5, "name": "FW_T_SEB_R_FF", "shortDesc": "Specific total energy balance rate feedforward gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "FW Longitudinal Control", "increment": 0.5, "max": 15.0, "min": 1.0, "name": "FW_T_SINK_MAX", "shortDesc": "Maximum descent rate", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.4, "group": "FW Longitudinal Control", "increment": 0.01, "longDesc": "This filter is applied to the specific total energy rate used for throttle damping.\n", "max": 2.0, "min": 0.0, "name": "FW_T_STE_R_TC", "shortDesc": "Specific total energy rate first order filter time constant", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 5.0, "group": "FW Longitudinal Control", "increment": 0.5, "min": 2.0, "name": "FW_T_TAS_TC", "shortDesc": "True airspeed error time constant", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "FW Longitudinal Control", "increment": 0.01, "longDesc": "This is the damping gain for the throttle demand loop.\n", "max": 1.0, "min": 0.0, "name": "FW_T_THR_DAMPING", "shortDesc": "Throttle damping factor", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.02, "group": "FW Longitudinal Control", "increment": 0.005, "longDesc": "Increase it to trim out speed and height offsets faster,\nwith the downside of possible overshoots and oscillations.\n", "max": 1.0, "min": 0.0, "name": "FW_T_THR_INTEG", "shortDesc": "Integrator gain throttle", "type": "Float"}, {"category": "Standard", "decimalPlaces": 0, "default": -1.0, "group": "FW Longitudinal Control", "increment": 1.0, "longDesc": "Height above ground threshold below which tighter altitude\ntracking gets enabled (see FW_LND_THRTC_SC). Below this height, TECS smoothly\n(1 sec / sec) transitions the altitude tracking time constant from FW_T_ALT_TC\nto FW_LND_THRTC_SC*FW_T_ALT_TC.\n\n-1 to disable.\n", "min": -1.0, "name": "FW_T_THR_LOW_HGT", "shortDesc": "Low-height threshold for tighter altitude tracking", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 7.0, "group": "FW Longitudinal Control", "increment": 0.5, "longDesc": "This is the maximum vertical acceleration\neither up or down that the controller will use to correct speed\nor height errors.\n", "max": 10.0, "min": 1.0, "name": "FW_T_VERT_ACC", "shortDesc": "Maximum vertical acceleration", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "FW Longitudinal Control", "increment": 0.01, "longDesc": "Multiplying this factor with the current absolute wind estimate gives the airspeed offset\nadded to the minimum airspeed setpoint limit. This helps to make the\nsystem more robust against disturbances (turbulence) in high wind.\n", "min": 0.0, "name": "FW_WIND_ARSP_SC", "shortDesc": "Wind-based airspeed scaling factor", "type": "Float"}, {"category": "Standard", "decimalPlaces": 0, "default": -1.0, "group": "FW NPFG Control", "increment": 1.0, "longDesc": "If a horizontal position reset larger than this occurs while flying between two\nwaypoints, fly directly to the current waypoint instead of rejoining the line.\n-1 to disable.\n", "max": 10000.0, "min": -1.0, "name": "FW_WP_RST_DIST", "shortDesc": "Max position reset distance", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.7, "group": "FW NPFG Control", "increment": 0.01, "longDesc": "Damping ratio of NPFG control law.\n", "max": 1.0, "min": 0.1, "name": "NPFG_DAMPING", "shortDesc": "NPFG damping ratio", "type": "Float"}, {"category": "Standard", "default": 1, "group": "FW NPFG Control", "longDesc": "Avoids limit cycling from a too aggressively tuned period/damping combination.\nIf false, also disables upper bound NPFG_PERIOD_UB.\n", "name": "NPFG_LB_PERIOD", "shortDesc": "Enable automatic lower bound on the NPFG period", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 10.0, "group": "FW NPFG Control", "increment": 0.1, "longDesc": "Period of NPFG control law.\n", "max": 100.0, "min": 1.0, "name": "NPFG_PERIOD", "shortDesc": "NPFG period", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.5, "group": "FW NPFG Control", "increment": 0.1, "longDesc": "Multiplied by period for conservative minimum period bounding (when period lower\nbounding is enabled). 1.0 bounds at marginal stability.\n", "max": 10.0, "min": 1.0, "name": "NPFG_PERIOD_SF", "shortDesc": "Period safety factor", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.5, "group": "FW NPFG Control", "increment": 0.05, "longDesc": "Time constant of roll controller command / response, modeled as first order delay.\nUsed to determine lower period bound. Setting zero disables automatic period bounding.\n", "max": 2.0, "min": 0.0, "name": "NPFG_ROLL_TC", "shortDesc": "Roll time constant", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.32, "group": "FW NPFG Control", "increment": 0.01, "longDesc": "Multiplied by the track error boundary to determine when the aircraft switches\nto the next waypoint and/or path segment. Should be less than 1.\n", "max": 1.0, "min": 0.1, "name": "NPFG_SW_DST_MLT", "shortDesc": "NPFG switch distance multiplier", "type": "Float"}, {"category": "Standard", "default": 1, "group": "FW NPFG Control", "longDesc": "Adapts period to maintain track keeping in variable winds and path curvature.\n", "name": "NPFG_UB_PERIOD", "shortDesc": "Enable automatic upper bound on the NPFG period", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "FW Performance", "increment": 0.01, "longDesc": "Factor applied to the minimum and stall airspeed when flaps are fully deployed.\n", "max": 1.0, "min": 0.5, "name": "FW_AIRSPD_FLP_SC", "shortDesc": "Airspeed scale with full flaps", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 20.0, "group": "FW Performance", "increment": 0.5, "longDesc": "The maximal airspeed (calibrated airspeed) the user is able to command.\n", "min": 0.5, "name": "FW_AIRSPD_MAX", "shortDesc": "Maximum Airspeed (CAS)", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 10.0, "group": "FW Performance", "increment": 0.5, "longDesc": "The minimal airspeed (calibrated airspeed) the user is able to command.\nFurther, if the airspeed falls below this value, the TECS controller will try to\nincrease airspeed more aggressively.\nHas to be set according to the vehicle's stall speed (which should be set in FW_AIRSPD_STALL),\nwith some margin between the stall speed and minimum airspeed.\nThis value corresponds to the desired minimum speed with the default load factor (level flight, default weight),\nand is automatically adpated to the current load factor (calculated from roll setpoint and WEIGHT_GROSS/WEIGHT_BASE).\n", "min": 0.5, "name": "FW_AIRSPD_MIN", "shortDesc": "Minimum Airspeed (CAS)", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 7.0, "group": "FW Performance", "increment": 0.5, "longDesc": "The stall airspeed (calibrated airspeed) of the vehicle.\nIt is used for airspeed sensor failure detection and for the control\nsurface scaling airspeed limits.\n", "min": 0.5, "name": "FW_AIRSPD_STALL", "shortDesc": "Stall Airspeed (CAS)", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 15.0, "group": "FW Performance", "increment": 0.5, "longDesc": "The trim CAS (calibrated airspeed) of the vehicle. If an airspeed controller is active,\nthis is the default airspeed setpoint that the controller will try to achieve.\nThis value corresponds to the trim airspeed with the default load factor (level flight, default weight).\n", "min": 0.5, "name": "FW_AIRSPD_TRIM", "shortDesc": "Trim (Cruise) Airspeed", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 0, "default": -1.0, "group": "FW Performance", "increment": 1.0, "longDesc": "Altitude in standard atmosphere at which the vehicle in normal configuration (WEIGHT_BASE) is still able to achieve a maximum climb rate of\n0.5m/s at maximum throttle (FW_THR_MAX). Used to compensate for air density in FW_T_CLMB_MAX.\nSet negative to disable.\n", "min": -1.0, "name": "FW_SERVICE_CEIL", "shortDesc": "Service ceiling", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "FW Performance", "increment": 0.01, "longDesc": "Required throttle (at sea level, standard atmosphere) for level flight at maximum airspeed FW_AIRSPD_MAX\n\nSet to 0 to disable mapping of airspeed to trim throttle.\n", "max": 1.0, "min": 0.0, "name": "FW_THR_ASPD_MAX", "shortDesc": "Throttle at max airspeed", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "FW Performance", "increment": 0.01, "longDesc": "Required throttle (at sea level, standard atmosphere) for level flight at minimum airspeed FW_AIRSPD_MIN\n\nSet to 0 to disable mapping of airspeed to trim throttle below FW_AIRSPD_TRIM.\n", "max": 1.0, "min": 0.0, "name": "FW_THR_ASPD_MIN", "shortDesc": "Throttle at min airspeed", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.6, "group": "FW Performance", "increment": 0.01, "longDesc": "Required throttle (at sea level, standard atmosphere) for level flight at FW_AIRSPD_TRIM\n", "max": 1.0, "min": 0.0, "name": "FW_THR_TRIM", "shortDesc": "Trim throttle", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "FW Performance", "increment": 0.5, "longDesc": "This is the maximum calibrated climb rate that the aircraft can achieve with\nthe throttle set to FW_THR_MAX and the airspeed set to the\ntrim value. For electric aircraft make sure this number can be\nachieved towards the end of flight when the battery voltage has reduced.\n", "min": 1.0, "name": "FW_T_CLMB_MAX", "shortDesc": "Maximum climb rate", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 2.0, "group": "FW Performance", "increment": 0.5, "longDesc": "This is the minimum calibrated sink rate of the aircraft with the throttle\nset to THR_MIN and flown at the same airspeed as used\nto measure FW_T_CLMB_MAX.\n", "min": 1.0, "name": "FW_T_SINK_MIN", "shortDesc": "Minimum descent rate", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": -1.0, "group": "FW Performance", "increment": 0.5, "longDesc": "This is the weight of the vehicle at which it's performance limits were derived. A zero or negative value\ndisables trim throttle and minimum airspeed compensation based on weight.\n", "name": "WEIGHT_BASE", "shortDesc": "Vehicle base weight", "type": "Float", "units": "kg"}, {"category": "Standard", "decimalPlaces": 1, "default": -1.0, "group": "FW Performance", "increment": 0.1, "longDesc": "If set together with WEIGHT_BASE and WEIGHT_GROSS, the weight used for\nperformance scaling is reduced by the burned fuel reported in the fuel tank status.\nOnly a single fuel tank is supported. A zero or negative value disables fuel-based weight compensation.\n", "name": "WEIGHT_FUEL", "shortDesc": "Mass of a full fuel load", "type": "Float", "units": "kg"}, {"category": "Standard", "decimalPlaces": 1, "default": -1.0, "group": "FW Performance", "increment": 0.1, "longDesc": "This is the actual weight of the vehicle at any time. This value will differ from WEIGHT_BASE in case weight was added\nor removed from the base weight. Examples are the addition of payloads or larger batteries. A zero or negative value\ndisables trim throttle and minimum airspeed compensation based on weight.\nIf fuel-based weight compensation is enabled (WEIGHT_FUEL), set this to the takeoff weight with a full fuel load.\n", "name": "WEIGHT_GROSS", "shortDesc": "Vehicle gross weight", "type": "Float", "units": "kg"}, {"category": "Standard", "default": 90.0, "group": "FW Rate Control", "max": 720.0, "min": 10.0, "name": "FW_ACRO_X_MAX", "shortDesc": "Acro body roll max rate setpoint", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 0, "group": "FW Rate Control", "longDesc": "If this parameter is set to 1, the yaw rate controller is enabled in Fixed-wing Acro mode.\nOtherwise the pilot commands directly the yaw actuator.\nIt is disabled by default because an active yaw rate controller will fight against the\nnatural turn coordination of the plane.\n", "name": "FW_ACRO_YAW_EN", "shortDesc": "Enable yaw rate controller in Acro", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 90.0, "group": "FW Rate Control", "max": 720.0, "min": 10.0, "name": "FW_ACRO_Y_MAX", "shortDesc": "Acro body pitch max rate setpoint", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 45.0, "group": "FW Rate Control", "max": 720.0, "min": 10.0, "name": "FW_ACRO_Z_MAX", "shortDesc": "Acro body yaw max rate setpoint", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 1, "group": "FW Rate Control", "longDesc": "This enables a logic that automatically adjusts the output of the rate controller to take\ninto account the real torque produced by an aerodynamic control surface given\nthe current deviation from the trim airspeed (FW_AIRSPD_TRIM).\n\nEnable when using aerodynamic control surfaces (e.g.: plane)\nDisable when using rotor wings (e.g.: autogyro)\n", "name": "FW_ARSP_SCALE_EN", "shortDesc": "Enable airspeed scaling", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "FW Rate Control", "longDesc": "This compensates for voltage drop of the battery over time by attempting to\nnormalize performance across the operating range of the battery.\n", "name": "FW_BAT_SCALE_EN", "shortDesc": "Enable throttle scale by battery level", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "FW Rate Control", "increment": 0.01, "longDesc": "This increment is added to TRIM_PITCH when airspeed is FW_AIRSPD_MAX.\n", "max": 0.5, "min": -0.5, "name": "FW_DTRIM_P_VMAX", "shortDesc": "Pitch trim increment at maximum airspeed", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "FW Rate Control", "increment": 0.01, "longDesc": "This increment is added to TRIM_PITCH when airspeed is FW_AIRSPD_MIN.\n", "max": 0.5, "min": -0.5, "name": "FW_DTRIM_P_VMIN", "shortDesc": "Pitch trim increment at minimum airspeed", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "FW Rate Control", "increment": 0.01, "longDesc": "This increment is added to TRIM_ROLL when airspeed is FW_AIRSPD_MAX.\n", "max": 0.5, "min": -0.5, "name": "FW_DTRIM_R_VMAX", "shortDesc": "Roll trim increment at maximum airspeed", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "FW Rate Control", "increment": 0.01, "longDesc": "This increment is added to TRIM_ROLL when airspeed is FW_AIRSPD_MIN.\n", "max": 0.5, "min": -0.5, "name": "FW_DTRIM_R_VMIN", "shortDesc": "Roll trim increment at minimum airspeed", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "FW Rate Control", "increment": 0.01, "longDesc": "This increment is added to TRIM_YAW when airspeed is FW_AIRSPD_MAX.\n", "max": 0.5, "min": -0.5, "name": "FW_DTRIM_Y_VMAX", "shortDesc": "Yaw trim increment at maximum airspeed", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "FW Rate Control", "increment": 0.01, "longDesc": "This increment is added to TRIM_YAW when airspeed is FW_AIRSPD_MIN.\n", "max": 0.5, "min": -0.5, "name": "FW_DTRIM_Y_VMIN", "shortDesc": "Yaw trim increment at minimum airspeed", "type": "Float"}, {"category": "Standard", "default": 0, "group": "FW Rate Control", "longDesc": "Chose source for manual setting of flaps in manual flight modes.\n", "name": "FW_FLAPS_MAN", "shortDesc": "Flap input in manual flight", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Aux1", "value": 1}, {"description": "Aux2", "value": 2}, {"description": "Aux3", "value": 3}, {"description": "Aux4", "value": 4}, {"description": "Aux5", "value": 5}, {"description": "Flaps channel", "value": 6}, {"description": "Aux6", "value": 7}]}, {"category": "Standard", "default": 1, "group": "FW Rate Control", "name": "FW_GC_EN", "shortDesc": "Enable rate gain compression", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "FW Rate Control", "increment": 0.01, "longDesc": "The range of the compression gain is between this parameter and 1.0\n", "max": 1.0, "min": 0.0, "name": "FW_GC_GAIN_MIN", "shortDesc": "Compression gain lower limit", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "FW Rate Control", "increment": 0.01, "longDesc": "Scale factor applied to the desired pitch actuator command in full manual mode. This parameter allows\nto adjust the throws of the control surfaces.\n", "min": 0.0, "name": "FW_MAN_P_SC", "shortDesc": "Manual pitch scale", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "FW Rate Control", "increment": 0.01, "longDesc": "Scale factor applied to the desired roll actuator command in full manual mode. This parameter allows\nto adjust the throws of the control surfaces.\n", "max": 1.0, "min": 0.0, "name": "FW_MAN_R_SC", "shortDesc": "Manual roll scale", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "FW Rate Control", "increment": 0.01, "longDesc": "Scale factor applied to the desired yaw actuator command in full manual mode. This parameter allows\nto adjust the throws of the control surfaces.\n", "min": 0.0, "name": "FW_MAN_Y_SC", "shortDesc": "Manual yaw scale", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "FW Rate Control", "increment": 0.005, "longDesc": "Pitch rate differential gain.\n", "max": 10.0, "min": 0.0, "name": "FW_PR_D", "shortDesc": "Pitch rate derivative gain", "type": "Float", "units": "%/rad/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.5, "group": "FW Rate Control", "increment": 0.05, "longDesc": "Direct feed forward from rate setpoint to torque setpoint.\nPositive values compensate aerodynamic damping (scaled linearly with airspeed).\nNegative values reduce setpoint tracking aggressiveness while preserving disturbance rejection (2-DOF controller, scaled quadratically with airspeed)\n\n", "max": 10.0, "min": -10.0, "name": "FW_PR_FF", "shortDesc": "Pitch rate feed forward", "type": "Float", "units": "%/rad/s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.1, "group": "FW Rate Control", "increment": 0.005, "max": 10.0, "min": 0.0, "name": "FW_PR_I", "shortDesc": "Pitch rate integrator gain", "type": "Float", "units": "%/rad"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.4, "group": "FW Rate Control", "increment": 0.05, "max": 1.0, "min": 0.0, "name": "FW_PR_IMAX", "shortDesc": "Pitch rate integrator limit", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.08, "group": "FW Rate Control", "increment": 0.005, "max": 10.0, "min": 0.0, "name": "FW_PR_P", "shortDesc": "Pitch rate proportional gain", "type": "Float", "units": "%/rad/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "FW Rate Control", "increment": 0.01, "longDesc": "This gain can be used to counteract the \"adverse yaw\" effect for fixed wings.\nWhen the plane enters a roll it will tend to yaw the nose out of the turn.\nThis gain enables the use of a yaw actuator to counteract this effect.\n", "min": 0.0, "name": "FW_RLL_TO_YAW_FF", "shortDesc": "Roll control to yaw control feedforward gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "FW Rate Control", "increment": 0.005, "max": 10.0, "min": 0.0, "name": "FW_RR_D", "shortDesc": "Roll rate derivative gain", "type": "Float", "units": "%/rad/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.5, "group": "FW Rate Control", "increment": 0.05, "longDesc": "Direct feed forward from rate setpoint to torque setpoint.\nPositive values compensate aerodynamic damping (scaled linearly with airspeed).\nNegative values reduce setpoint tracking aggressiveness while preserving disturbance rejection (2-DOF controller, scaled quadratically with airspeed)\n\n", "max": 10.0, "min": -10.0, "name": "FW_RR_FF", "shortDesc": "Roll rate feed forward", "type": "Float", "units": "%/rad/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "FW Rate Control", "increment": 0.01, "max": 10.0, "min": 0.0, "name": "FW_RR_I", "shortDesc": "Roll rate integrator gain", "type": "Float", "units": "%/rad"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.2, "group": "FW Rate Control", "increment": 0.05, "max": 1.0, "min": 0.0, "name": "FW_RR_IMAX", "shortDesc": "Roll integrator limit", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "FW Rate Control", "increment": 0.005, "max": 10.0, "min": 0.0, "name": "FW_RR_P", "shortDesc": "Roll rate proportional gain", "type": "Float", "units": "%/rad/s"}, {"category": "Standard", "default": 0, "group": "FW Rate Control", "longDesc": "Chose source for manual setting of spoilers in manual flight modes.\n", "name": "FW_SPOILERS_MAN", "shortDesc": "Spoiler input in manual flight", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Flaps channel", "value": 1}, {"description": "Aux1", "value": 2}, {"description": "Aux2", "value": 3}, {"description": "Aux3", "value": 4}, {"description": "Aux4", "value": 5}, {"description": "Aux5", "value": 6}, {"description": "Aux6", "value": 7}]}, {"category": "Standard", "default": 1, "group": "FW Rate Control", "longDesc": "If set to 1, the airspeed measurement data, if valid, is used in the following controllers:\n- Rate controller: output scaling\n- Attitude controller: coordinated turn controller\n- Position controller: airspeed setpoint tracking, takeoff logic\n- VTOL: transition logic\n", "name": "FW_USE_AIRSPD", "shortDesc": "Use airspeed for control", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "FW Rate Control", "increment": 0.005, "max": 10.0, "min": 0.0, "name": "FW_YR_D", "shortDesc": "Yaw rate derivative gain", "type": "Float", "units": "%/rad/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "FW Rate Control", "increment": 0.05, "longDesc": "Direct feed forward from rate setpoint to torque setpoint.\nPositive values compensate aerodynamic damping (scaled linearly with airspeed).\nNegative values reduce setpoint tracking aggressiveness while preserving disturbance rejection (2-DOF controller, scaled quadratically with airspeed)\n\n", "max": 10.0, "min": -10.0, "name": "FW_YR_FF", "shortDesc": "Yaw rate feed forward", "type": "Float", "units": "%/rad/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.1, "group": "FW Rate Control", "increment": 0.5, "max": 10.0, "min": 0.0, "name": "FW_YR_I", "shortDesc": "Yaw rate integrator gain", "type": "Float", "units": "%/rad"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.2, "group": "FW Rate Control", "increment": 0.05, "max": 1.0, "min": 0.0, "name": "FW_YR_IMAX", "shortDesc": "Yaw rate integrator limit", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "FW Rate Control", "increment": 0.005, "max": 10.0, "min": 0.0, "name": "FW_YR_P", "shortDesc": "Yaw rate proportional gain", "type": "Float", "units": "%/rad/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "Failure Detector", "increment": 0.5, "longDesc": "Maximum altitude loss allowed before the vehicle terminates and deploys the parachute. Set to 0 to disable.\n", "max": 200.0, "min": 0.0, "name": "FD_ALT_LOSS", "shortDesc": "Altitude loss threshold for termination and parachute deployment", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Failure Detector", "longDesc": "Seconds that the altitude loss threshold must be exceeded before the failure is declared.\n", "max": 5.0, "min": 0.02, "name": "FD_ALT_LOSS_T", "shortDesc": "Altitude loss failure trigger time", "type": "Float", "units": "s"}, {"category": "Standard", "default": 0, "group": "Failure Detector", "longDesc": "Enable PWM input on for engaging failsafe from an external automatic trigger system (ATS)\n\nEnabled on either AUX5 or MAIN5 depending on board.\nExternal ATS is required by ASTM F3322-18.\n", "name": "FD_EXT_ATS_EN", "rebootRequired": true, "shortDesc": "Enable PWM input from external ATS for failsafe", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 1900, "group": "Failure Detector", "longDesc": "The PWM threshold from external automatic trigger system for engaging failsafe\n\nExternal ATS is required by ASTM F3322-18.\n", "name": "FD_EXT_ATS_TRIG", "shortDesc": "External ATS PWM threshold for failsafe", "type": "Int32", "units": "us"}, {"category": "Standard", "default": 30, "group": "Failure Detector", "increment": 1, "longDesc": "Value at which the imbalanced propeller metric (based on horizontal and\nvertical acceleration variance) triggers a failure\n\nSetting this value to 0 disables the feature.\n", "max": 1000, "min": 0, "name": "FD_IMB_PROP_THR", "shortDesc": "Imbalanced propeller check threshold", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 0, "default": 60.0, "group": "Failure Detector", "longDesc": "Maximum angle between the vehicle tilt and the attitude setpoint tilt before FailureDetector triggers the attitude_failure flag.\nWithout a recent attitude setpoint, e.g. on rovers, the tilt from level is checked instead.\nThe flag triggers flight termination (if @CBRK_FLIGHTTERM = 0),\nwhich sets outputs to their failsafe values.\nOn takeoff the flag triggers lockdown (irrespective of @CBRK_FLIGHTTERM),\nwhich disarms motors but does not set outputs to failsafe values.\nThe check is paused for the first 5 s after a VTOL quad-chute or aborted front transition.\n\nSet to -1 to disable.\n", "max": 180.0, "min": -1.0, "name": "FD_TILT_ERROR", "shortDesc": "FailureDetector Max Tilt Error", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Failure Detector", "longDesc": "Seconds (decimal) that the tilt error has to exceed FD_TILT_ERROR before being considered as a failure.\n", "max": 5.0, "min": 0.02, "name": "FD_TILT_ERROR_T", "shortDesc": "Tilt failure trigger time", "type": "Float", "units": "s"}, {"category": "Standard", "default": 0, "group": "Failure Injection", "longDesc": "If enabled allows Injection of Failures.\n\nWARNING: the failures can easily cause crashes and are to be used with caution!\n", "name": "SYS_FAILURE_EN", "rebootRequired": true, "shortDesc": "Enable failure injection", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.2, "group": "Failure Injection", "longDesc": "Constant offset added to every axis while an accel 'wrong' failure injection is active.\n", "name": "SYS_FAIL_A_BIAS", "shortDesc": "Accel bias failure injection offset", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.005, "group": "Failure Injection", "longDesc": "Rate at which the offset added to every axis grows while an accel 'drift' failure injection is active.\n", "name": "SYS_FAIL_A_DRIFT", "shortDesc": "Accel drift failure injection rate", "type": "Float", "units": "m/s^3"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Failure Injection", "longDesc": "Amplitude of the uniform noise added to every axis while an accel 'garbage' failure injection is active.\n", "min": 0.0, "name": "SYS_FAIL_A_NOISE", "shortDesc": "Accel noise failure injection magnitude", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "default": 3, "group": "Failure Injection", "longDesc": "Battery warning level reported while a battery 'wrong' failure\ninjection is active. The injected remaining charge is set just below\nthe matching threshold (BAT_LOW_THR, BAT_CRIT_THR or\nBAT_EMERGEN_THR).\n", "name": "SYS_FAIL_BAT_LVL", "shortDesc": "Battery failure injection severity", "type": "Int32", "values": [{"description": "Warn", "value": 1}, {"description": "Critical", "value": 2}, {"description": "Emergency", "value": 3}]}, {"category": "Standard", "default": 0, "group": "Failure Injection", "longDesc": "GNSS jamming state reported by the addressed receiver while a GPS 'wrong'\nfailure injection is active. The reported position is left untouched, so\n'Detected' simulates a receiver that still delivers a valid fix while\nreporting interference. Leave at 'Unchanged' to keep the simulated\nreceiver's own jamming state.\n", "name": "SYS_FAIL_GPS_JAM", "shortDesc": "GPS Wrong-failure jamming state", "type": "Int32", "values": [{"description": "Unchanged", "value": 0}, {"description": "OK", "value": 1}, {"description": "Mitigated", "value": 2}, {"description": "Detected", "value": 3}]}, {"category": "Standard", "default": 2, "group": "Failure Injection", "longDesc": "GNSS fix type reported by the addressed receiver while a GPS 'wrong'\nfailure injection is active. The reported position is left untouched.\nThe default 2D fix is rejected by the estimator, which requires a 3D\nfix, and makes the GNSS redundancy check report a lost fix. Values above\n3D fix report a better solution than the receiver really has.\n", "name": "SYS_FAIL_GPS_WRG", "shortDesc": "GPS Wrong-failure fix type", "type": "Int32", "values": [{"description": "Fix: None", "value": 1}, {"description": "Fix: 2D", "value": 2}, {"description": "Fix: 3D", "value": 3}, {"description": "Fix: RTK float", "value": 5}, {"description": "Fix: RTK fixed", "value": 6}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.01, "group": "Failure Injection", "longDesc": "Constant offset added to every axis while a gyro 'wrong' failure injection is active.\n", "name": "SYS_FAIL_G_BIAS", "shortDesc": "Gyro bias failure injection offset", "type": "Float", "units": "rad/s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.001, "group": "Failure Injection", "longDesc": "Rate at which the offset added to every axis grows while a gyro 'drift' failure injection is active.\n", "name": "SYS_FAIL_G_DRIFT", "shortDesc": "Gyro drift failure injection rate", "type": "Float", "units": "rad/s^2"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.05, "group": "Failure Injection", "longDesc": "Amplitude of the uniform noise added to every axis while a gyro 'garbage' failure injection is active.\n", "min": 0.0, "name": "SYS_FAIL_G_NOISE", "shortDesc": "Gyro noise failure injection magnitude", "type": "Float", "units": "rad/s"}, {"bitmask": [{"description": "Instance 1", "index": 0}, {"description": "Instance 2", "index": 1}, {"description": "Instance 3", "index": 2}, {"description": "Instance 4", "index": 3}, {"description": "Instance 5", "index": 4}, {"description": "Instance 6", "index": 5}, {"description": "Instance 7", "index": 6}, {"description": "Instance 8", "index": 7}, {"description": "Instance 9", "index": 8}, {"description": "Instance 10", "index": 9}, {"description": "Instance 11", "index": 10}, {"description": "Instance 12", "index": 11}, {"description": "Instance 13", "index": 12}, {"description": "Instance 14", "index": 13}, {"description": "Instance 15", "index": 14}, {"description": "Instance 16", "index": 15}], "category": "Standard", "default": 1, "group": "Failure Injection", "longDesc": "Bitmask of instances of SYS_FAIL_RC_UNIT that the SYS_FAIL_RC_SRC trigger\naffects (bit 0 = instance 1, motor number for motors). 0 = all instances.\n", "max": 65535, "min": 0, "name": "SYS_FAIL_RC_INST", "rebootRequired": true, "shortDesc": "Instances failed by the RC switch", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "Failure Injection", "longDesc": "How SYS_FAIL_RC_UNIT fails when the SYS_FAIL_RC_SRC trigger fires, on SYS_FAIL_RC_INST.\nunsupported (unit, type) pairs are ignored.\n", "name": "SYS_FAIL_RC_MODE", "rebootRequired": true, "shortDesc": "Failure type applied by the RC switch", "type": "Int32", "values": [{"description": "Ok (no failure)", "value": 0}, {"description": "Off", "value": 1}, {"description": "Stuck", "value": 2}, {"description": "Garbage", "value": 3}, {"description": "Wrong", "value": 4}, {"description": "Slow", "value": 5}, {"description": "Delayed", "value": 6}, {"description": "Intermittent", "value": 7}, {"description": "Drift", "value": 8}]}, {"category": "Standard", "default": 0, "group": "Failure Injection", "longDesc": "Defines the aux switch which injects the failure defined by SYS_FAIL_RC_UNIT,\nSYS_FAIL_RC_MODE and SYS_FAIL_RC_INST;\nMapped via RC_MAP_AUXn and gated by SYS_FAILURE_EN.\n", "max": 6, "min": 0, "name": "SYS_FAIL_RC_SRC", "rebootRequired": true, "shortDesc": "RC aux input that triggers failure injection", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "AUX1", "value": 1}, {"description": "AUX2", "value": 2}, {"description": "AUX3", "value": 3}, {"description": "AUX4", "value": 4}, {"description": "AUX5", "value": 5}, {"description": "AUX6", "value": 6}]}, {"category": "Standard", "default": 101, "group": "Failure Injection", "longDesc": "Which component the SYS_FAIL_RC_SRC trigger fails, with SYS_FAIL_RC_MODE on\nSYS_FAIL_RC_INST.\n", "name": "SYS_FAIL_RC_UNIT", "rebootRequired": true, "shortDesc": "Component failed by the RC switch", "type": "Int32", "values": [{"description": "Gyro", "value": 0}, {"description": "Accel", "value": 1}, {"description": "Mag", "value": 2}, {"description": "Baro", "value": 3}, {"description": "GPS", "value": 4}, {"description": "Distance sensor", "value": 7}, {"description": "Airspeed", "value": 8}, {"description": "Battery", "value": 100}, {"description": "Motor", "value": 101}, {"description": "Traffic avoidance", "value": 107}, {"description": "CAN bus", "value": 200}]}, {"category": "Standard", "decimalPlaces": 1, "default": 1000.0, "group": "Flight Task Orbit", "increment": 0.5, "max": 10000.0, "min": 1.0, "name": "MC_ORBIT_RAD_MAX", "shortDesc": "Maximum radius of orbit", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Flight Task Orbit", "name": "MC_ORBIT_YAW_MOD", "shortDesc": "Yaw behaviour during orbit flight", "type": "Int32", "values": [{"description": "Front to Circle Center", "value": 0}, {"description": "Hold Initial Heading", "value": 1}, {"description": "Uncontrolled", "value": 2}, {"description": "Hold Front Tangent to Circle", "value": 3}, {"description": "Manually (yaw stick) Controlled", "value": 4}]}, {"category": "Standard", "default": 0, "group": "Follow target", "longDesc": "Maintain altitude or track target's altitude. When maintaining the altitude,\nthe drone can crash into terrain when the target moves uphill. When tracking\nthe target's altitude, the follow altitude FLW_TGT_HT should be high enough\nto prevent terrain collisions due to GPS inaccuracies of the target.\n", "name": "FLW_TGT_ALT_M", "shortDesc": "Altitude control mode", "type": "Int32", "values": [{"description": "2D Tracking: Maintain constant altitude relative to home and track XY position only", "value": 0}, {"description": "2D + Terrain: Maintain constant altitude relative to terrain below and track XY position", "value": 1}, {"description": "3D Tracking: Track target's altitude (be aware that GPS altitude bias usually makes this useless)", "value": 2}]}, {"category": "Standard", "default": 8.0, "group": "Follow target", "longDesc": "The distance in meters to follow the target at\n", "min": 1.0, "name": "FLW_TGT_DST", "shortDesc": "Distance to follow target from", "type": "Float", "units": "m"}, {"category": "Standard", "default": 180.0, "group": "Follow target", "longDesc": "Angle to follow the target from. 0.0 Equals straight in front of the target's\ncourse (direction of motion) and the angle increases in clockwise direction,\nmeaning Right-side would be 90.0 degrees while Left-side is -90.0 degrees\n\nNote: When the user force sets the angle out of the min/max range, it will be\nwrapped (e.g. 480 -> 120) in the range to gracefully handle the out of range.\n", "max": 180.0, "min": -180.0, "name": "FLW_TGT_FA", "shortDesc": "Follow Angle setting", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 8.0, "group": "Follow target", "longDesc": "Following height above the target\n", "min": 8.0, "name": "FLW_TGT_HT", "shortDesc": "Follow target height", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "Follow target", "longDesc": "Maximum tangential velocity setting for generating the follow orbit trajectory\n\nThis is the maximum tangential velocity the drone will circle around the target whenever\nan orbit angle setpoint changes. Higher value means more aggressive follow behavior.\n", "max": 20.0, "min": 0.0, "name": "FLW_TGT_MAX_VEL", "shortDesc": "Max tangential velocity for follow orbit trajectory", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "Follow target", "longDesc": "lower values increase the responsiveness to changing position, but also ignore less noise\n", "max": 1.0, "min": 0.0, "name": "FLW_TGT_RS", "shortDesc": "Responsiveness to target movement in Target Estimator", "type": "Float"}, {"bitmask": [{"description": "GPS (with QZSS)", "index": 0}, {"description": "SBAS", "index": 1}, {"description": "Galileo", "index": 2}, {"description": "BeiDou", "index": 3}, {"description": "GLONASS", "index": 4}, {"description": "NAVIC", "index": 5}], "category": "Standard", "default": 0, "group": "GPS", "longDesc": "This integer bitmask controls the set of GNSS systems used by the receiver. Check your\nreceiver's documentation on how many systems are supported to be used in parallel.\n\nCurrently this functionality is just implemented for u-blox receivers.\n\nWhen no bits are set, the receiver's default configuration should be used.\n\nSet bits true to enable:\n0 : Use GPS (with QZSS)\n1 : Use SBAS (multiple GPS augmentation systems)\n2 : Use Galileo\n3 : Use BeiDou\n4 : Use GLONASS\n5 : Use NAVIC\n", "max": 63, "min": 0, "name": "GPS_1_GNSS", "rebootRequired": true, "shortDesc": "GNSS Systems for Primary GPS (integer bitmask)", "type": "Int32"}, {"category": "Standard", "default": 1, "group": "GPS", "longDesc": "Select the GPS protocol over serial.\n\nAuto-detection will probe all protocols, and thus is a bit slower.\n", "max": 7, "min": 0, "name": "GPS_1_PROTOCOL", "rebootRequired": true, "shortDesc": "Protocol for Main GPS", "type": "Int32", "values": [{"description": "Auto detect", "value": 0}, {"description": "u-blox", "value": 1}, {"description": "MTK", "value": 2}, {"description": "Ashtech / Trimble", "value": 3}, {"description": "Emlid Reach", "value": 4}, {"description": "Femtomes", "value": 5}, {"description": "NMEA (generic)", "value": 6}]}, {"bitmask": [{"description": "GPS (with QZSS)", "index": 0}, {"description": "SBAS", "index": 1}, {"description": "Galileo", "index": 2}, {"description": "BeiDou", "index": 3}, {"description": "GLONASS", "index": 4}, {"description": "NAVIC", "index": 5}], "category": "Standard", "default": 0, "group": "GPS", "longDesc": "This integer bitmask controls the set of GNSS systems used by the receiver. Check your\nreceiver's documentation on how many systems are supported to be used in parallel.\n\nCurrently this functionality is just implemented for u-blox receivers.\n\nWhen no bits are set, the receiver's default configuration should be used.\n\nSet bits true to enable:\n0 : Use GPS (with QZSS)\n1 : Use SBAS (multiple GPS augmentation systems)\n2 : Use Galileo\n3 : Use BeiDou\n4 : Use GLONASS\n5 : Use NAVIC\n", "max": 63, "min": 0, "name": "GPS_2_GNSS", "rebootRequired": true, "shortDesc": "GNSS Systems for Secondary GPS (integer bitmask)", "type": "Int32"}, {"category": "Standard", "default": 1, "group": "GPS", "longDesc": "Select the GPS protocol over serial.\n\nAuto-detection will probe all protocols, and thus is a bit slower.\n", "max": 6, "min": 0, "name": "GPS_2_PROTOCOL", "rebootRequired": true, "shortDesc": "Protocol for Secondary GPS", "type": "Int32", "values": [{"description": "Auto detect", "value": 0}, {"description": "u-blox", "value": 1}, {"description": "MTK", "value": 2}, {"description": "Ashtech / Trimble", "value": 3}, {"description": "Emlid Reach", "value": 4}, {"description": "Femtomes", "value": 5}, {"description": "NMEA (generic)", "value": 6}]}, {"category": "Standard", "default": 0, "group": "GPS", "longDesc": "Some UBX modules have a FLASH that allows to store persistent configuration that will be loaded on start.\nPX4 does override all configuration parameters it needs in RAM, which takes precedence over the values in FLASH.\nHowever, configuration parameters that are not overridden by PX4 can still cause unexpected problems during flight.\nTo avoid these kind of problems a clean config can be reached by wiping the FLASH on boot.\n\nNote: Currently only supported on UBX.\n", "name": "GPS_CFG_WIPE", "rebootRequired": true, "shortDesc": "Wipes the flash config of UBX modules", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "GPS", "longDesc": "If this is set to 1, all GPS communication data will be published via uORB,\nand written to the log file as gps_dump message.\n\nIf this is set to 2, the main GPS is configured to output RTCM data,\nwhich is then logged as gps_dump and can be used for PPK.\n", "max": 2, "min": 0, "name": "GPS_DUMP_COMM", "shortDesc": "Log GPS communication data", "type": "Int32", "values": [{"description": "Disable", "value": 0}, {"description": "Full communication", "value": 1}, {"description": "RTCM output (PPK)", "value": 2}]}, {"category": "Standard", "default": 0, "group": "GPS", "name": "GPS_SAT_INFO", "rebootRequired": true, "shortDesc": "Enable sat info (if available)", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "GPS", "longDesc": "Baudrate applied to the receiver UART1 after the link is auto-detected.\n0 keeps the driver default (115200). Modes that share UART1 with RTCM\n(GPS_UBX_MODE 3/4) may need a higher rate on short/reliable links.\n", "max": 3000000, "min": 0, "name": "GPS_UBX_BAUD1", "rebootRequired": true, "shortDesc": "u-blox UART1 target baudrate", "type": "Int32", "units": "B/s"}, {"category": "Standard", "default": 230400, "group": "GPS", "longDesc": "Baudrate for the receiver UART2 port. Only applied by GPS_UBX_MODE 1, 2, 5, 6 and 7;\nthe other modes leave UART2 untouched.\n", "min": 0, "name": "GPS_UBX_BAUD2", "rebootRequired": true, "shortDesc": "u-blox UART2 baudrate", "type": "Int32", "units": "B/s"}, {"bitmask": [{"description": "Enable I2C input protocol UBX", "index": 0}, {"description": "Enable I2C input protocol NMEA", "index": 1}, {"description": "Enable I2C input protocol RTCM3X", "index": 2}, {"description": "Enable I2C output protocol UBX", "index": 3}, {"description": "Enable I2C output protocol NMEA", "index": 4}, {"description": "Enable I2C output protocol RTCM3X", "index": 5}], "category": "Standard", "default": 0, "group": "GPS", "max": 63, "min": 0, "name": "GPS_UBX_CFG_INTF", "rebootRequired": true, "shortDesc": "u-blox protocol configuration for interfaces", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "GPS", "longDesc": "When set to 0 (default), default DGNSS timeout set by u-blox will be used.\n", "max": 255, "min": 0, "name": "GPS_UBX_DGNSS_TO", "rebootRequired": true, "shortDesc": "u-blox GPS DGNSS timeout", "type": "Int32", "units": "s"}, {"category": "Standard", "default": 7, "group": "GPS", "longDesc": "u-blox receivers support different dynamic platform models to adjust the navigation engine to\nthe expected application environment.\n", "max": 8, "min": 0, "name": "GPS_UBX_DYNMODEL", "rebootRequired": true, "shortDesc": "u-blox GPS dynamic platform model", "type": "Int32", "values": [{"description": "portable", "value": 0}, {"description": "stationary", "value": 2}, {"description": "pedestrian", "value": 3}, {"description": "automotive", "value": 4}, {"description": "sea", "value": 5}, {"description": "airborne with <1g acceleration", "value": 6}, {"description": "airborne with <2g acceleration", "value": 7}, {"description": "airborne with <4g acceleration", "value": 8}]}, {"category": "Standard", "default": 1, "group": "GPS", "longDesc": "Enables or disables the high sensitivity mode for the u-blox jamming detection\n(CFG-SEC-JAMDET_SENSITIVITY_HI). When enabled, the receiver uses a\nmore sensitive algorithm to detect jamming. Disabling this may reduce false\npositives in electrically noisy environments.\n", "name": "GPS_UBX_JAM_DET", "rebootRequired": true, "shortDesc": "u-blox GPS jamming detection high sensitivity mode", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "GPS", "longDesc": "When set to 0 (default), default minimum satellite signal level set by u-blox wll be used.\n", "max": 255, "min": 0, "name": "GPS_UBX_MIN_CNO", "rebootRequired": true, "shortDesc": "u-blox GPS minimum satellite signal level for navigation", "type": "Int32", "units": "dBHz"}, {"category": "Standard", "default": 0, "group": "GPS", "longDesc": "u-blox GPS minimum elevation for a GNSS satellite to be used in navigation\n\nWhen set to 0 (default), default minimum elevation set by u-blox will be used.\n", "max": 127, "min": 0, "name": "GPS_UBX_MIN_ELEV", "rebootRequired": true, "shortDesc": "u-blox GPS minimum satellite elevation angle", "type": "Int32", "units": "deg"}, {"category": "Standard", "default": 0, "group": "GPS", "longDesc": "Select the u-blox configuration setup. Most setups will use the default, including RTK and\ndual GPS without heading.\n\nIf rover has RTCM corrections from a static base (or other static correction source) coming in on UART2, then select Mode 5.\nThe Heading mode requires 2 F9P devices to be attached. The main GPS will act as rover and output\nheading information, whereas the secondary will act as moving base.\nModes 1 and 2 require each F9P UART1 to be connected to the Autopilot. In addition, UART2 on the\nF9P units are connected to each other.\nModes 3 and 4 only require UART1 on each F9P connected to the Autopilot or Can Node. UART RX DMA is required.\nRTK is still possible with this setup.\nMode 6 is intended for use with a ground control station (not necessarily an RTK correction base).\nMode 7 turns UART2 into a diagnostic port: the receiver keeps serving the autopilot on UART1\nwhile UART2 outputs UBX at GPS_UBX_BAUD2 for u-center. Keep GPS_UBX_BAUD2 at 115200 or above,\nthe diagnostic message set saturates a slower link. UBX input is left enabled on UART2, so\nanything attached there can also reconfigure the receiver.\nMode 8 uses the free Galileo HAS corrections broadcast on E6 (ZED-X20P with HPG 2.10 or\nlater) for a PPP solution of roughly 20 cm after a few minutes of convergence. The\nreceiver only processes HAS while host corrections are off, so RTCM and SPARTN from the\nautopilot are ignored in this mode; use mode 0 whenever a correction link is available.\n", "max": 8, "min": 0, "name": "GPS_UBX_MODE", "rebootRequired": true, "shortDesc": "u-blox GPS Mode", "type": "Int32", "values": [{"description": "Default", "value": 0}, {"description": "Heading (Rover With Moving Base UART1 Connected To Autopilot, UART2 Connected To Moving Base)", "value": 1}, {"description": "Moving Base (UART1 Connected To Autopilot, UART2 Connected To Rover)", "value": 2}, {"description": "Heading (Rover With Moving Base UART1 Connected to Autopilot Or Can Node)", "value": 3}, {"description": "Moving Base (Moving Base UART1 Connected to Autopilot Or Can Node)", "value": 4}, {"description": "Rover with Static Base on UART2 (similar to Default, except coming in on UART2)", "value": 5}, {"description": "Ground Control Station (UART2 outputs NMEA)", "value": 6}, {"description": "u-center on UART2 (UART2 outputs UBX diagnostics)", "value": 7}, {"description": "Galileo HAS (X20P, PPP from E6, RTCM/SPARTN input disabled)", "value": 8}]}, {"category": "Standard", "default": 0, "group": "GPS", "name": "GPS_UBX_PPK", "rebootRequired": true, "shortDesc": "Enable MSM7 message output for PPK workflow", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "GPS", "longDesc": "Configure the output rate of u-blox GPS receivers (protocol v27+).\nWhen set to 0, automatic rate selection is used based on the receiver model.\nDefault rates: M9N=8Hz, F9P L1L2=5Hz, F9P L1L5=5Hz, Others=10Hz.\n\nNote: Higher rates reduce satellite count (e.g., >8Hz limits to 16 SVs on M9N).\nMax rates vary by model and RTK mode: F9P L1L2=5-7Hz, F9P L1L5=7-8Hz, X20=25Hz.\nHigh rates at 115200 baud may cause dropouts.\n", "max": 25, "min": 0, "name": "GPS_UBX_RATE", "rebootRequired": true, "shortDesc": "u-blox GPS output rate", "type": "Int32", "units": "Hz"}, {"category": "Standard", "default": 0, "group": "GPS", "name": "GPS_UBX_SPECTRUM", "rebootRequired": true, "shortDesc": "Enable spectrum analyzer (if available)", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 2, "group": "Geofence", "longDesc": "Note: Setting this value to 4 enables flight termination,\nwhich will kill the vehicle on violation of the fence.\n", "max": 5, "min": 0, "name": "GF_ACTION", "shortDesc": "Geofence violation action", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Warning", "value": 1}, {"description": "Hold mode", "value": 2}, {"description": "Return mode", "value": 3}, {"description": "Terminate", "value": 4}, {"description": "Land mode", "value": 5}]}, {"category": "Standard", "default": 100, "group": "Geofence", "longDesc": "Maximum number of geofence vertices the Return geofence avoidance planner can use.\nCircles use 8 vertices each, polygons their vertex count plus extra vertices for sharp corners.\nIf the fence needs more vertices, Return flies directly and ignores the geofence.\nReplanning time (on geofence / safety margin change) is cubic, RAM usage quadratic in this number\n(about 2 * N^2 bytes, e.g. 20 kB for 100 nodes).\nThe maximum of 200 is sufficient for any fence that can be stored.\nSet to 0 to disable geofence avoidance in Return.\n", "max": 200, "min": 0, "name": "GF_AVOID_NODES", "rebootRequired": true, "shortDesc": "Max graph nodes for geofence avoidance in Return", "type": "Int32"}, {"category": "Standard", "default": 0.0, "group": "Geofence", "increment": 1.0, "longDesc": "Maximum horizontal distance in meters the vehicle can be from Home before triggering a geofence action.\nDisabled if 0.\n", "max": 10000.0, "min": 0.0, "name": "GF_MAX_HOR_DIST", "shortDesc": "Max horizontal distance from Home", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0.0, "group": "Geofence", "increment": 1.0, "longDesc": "Maximum vertical distance in meters the vehicle can be from Home before triggering a geofence action.\nDisabled if 0.\n", "max": 10000.0, "min": 0.0, "name": "GF_MAX_VER_DIST", "shortDesc": "Max vertical distance from Home", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Geofence", "longDesc": "Select which position source should be used. Selecting GPS instead of global position makes sure that there is\nno dependence on the position estimator\n0 = global position, 1 = GPS\n", "max": 1, "min": 0, "name": "GF_SOURCE", "shortDesc": "Geofence source", "type": "Int32", "values": [{"description": "GPOS", "value": 0}, {"description": "GPS", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "Defines which mixer implementation to use.\nSome are generic, while others are specifically fit to a certain vehicle with a fixed set of actuators.\n\n'Custom' should only be used if noting else can be used.\n\n", "name": "CA_AIRFRAME", "shortDesc": "Airframe selection", "type": "Int32", "values": [{"description": "Multirotor", "value": 0}, {"description": "Fixed-wing", "value": 1}, {"description": "Standard VTOL", "value": 2}, {"description": "Tiltrotor VTOL", "value": 3}, {"description": "Tailsitter VTOL", "value": 4}, {"description": "Rover (Ackermann)", "value": 5}, {"description": "Rover (Differential)", "value": 6}, {"description": "Motors (6DOF)", "value": 7}, {"description": "Multirotor with Tilt", "value": 8}, {"description": "Custom", "value": 9}, {"description": "Helicopter (tail ESC)", "value": 10}, {"description": "Helicopter (tail Servo)", "value": 11}, {"description": "Helicopter (Coaxial)", "value": 12}, {"description": "Rover (Mecanum)", "value": 13}, {"description": "Spacecraft 2D", "value": 14}, {"description": "Spacecraft 3D", "value": 15}]}, {"bitmask": [{"description": "Control Surface 1", "index": 0}, {"description": "Control Surface 2", "index": 1}, {"description": "Control Surface 3", "index": 2}, {"description": "Control Surface 4", "index": 3}, {"description": "Control Surface 5", "index": 4}, {"description": "Control Surface 6", "index": 5}, {"description": "Control Surface 7", "index": 6}, {"description": "Control Surface 8", "index": 7}], "category": "Standard", "default": 0, "group": "Geometry", "longDesc": "If actuator launch lock is enabled, this surface is kept at the disarmed value.\n", "max": 255, "min": 0, "name": "CA_CS_LAUN_LK", "shortDesc": "Control surface launch lock enabled", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "What to do on a single motor failure. Ignore disables this feature entirely. Otherwise\nthe failed motor is removed from the allocation, and on a hexarotor its geometric-opposite\nmotor is additionally stopped (mode 1) or reversed (mode 2) to recover the lost\nyaw/roll/pitch authority; on other airframes only the failed motor is removed. Mode 2\nneeds a reverse-capable ESC on the opposite motor.\n\n", "name": "CA_FAILURE_MODE", "shortDesc": "Motor failure handling mode", "type": "Int32", "values": [{"description": "Ignore", "value": 0}, {"description": "Remove failed motor and stop its opposite", "value": 1}, {"description": "Remove failed motor and reverse its opposite", "value": 2}]}, {"category": "Standard", "decimalPlaces": 3, "default": -0.05, "group": "Geometry", "increment": 0.1, "longDesc": "Defines the collective pitch at the interval position 0 for a given thrust setpoint.\n\nUse negative values if the swash plate needs to move down to provide upwards thrust.\n\n", "max": 1.0, "min": -1.0, "name": "CA_HELI_PITCH_C0", "shortDesc": "Collective pitch curve at position 0", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0725, "group": "Geometry", "increment": 0.1, "longDesc": "Defines the collective pitch at the interval position 1 for a given thrust setpoint.\n\nUse negative values if the swash plate needs to move down to provide upwards thrust.\n\n", "max": 1.0, "min": -1.0, "name": "CA_HELI_PITCH_C1", "shortDesc": "Collective pitch curve at position 1", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.2, "group": "Geometry", "increment": 0.1, "longDesc": "Defines the collective pitch at the interval position 2 for a given thrust setpoint.\n\nUse negative values if the swash plate needs to move down to provide upwards thrust.\n\n", "max": 1.0, "min": -1.0, "name": "CA_HELI_PITCH_C2", "shortDesc": "Collective pitch curve at position 2", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.325, "group": "Geometry", "increment": 0.1, "longDesc": "Defines the collective pitch at the interval position 3 for a given thrust setpoint.\n\nUse negative values if the swash plate needs to move down to provide upwards thrust.\n\n", "max": 1.0, "min": -1.0, "name": "CA_HELI_PITCH_C3", "shortDesc": "Collective pitch curve at position 3", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.45, "group": "Geometry", "increment": 0.1, "longDesc": "Defines the collective pitch at the interval position 4 for a given thrust setpoint.\n\nUse negative values if the swash plate needs to move down to provide upwards thrust.\n\n", "max": 1.0, "min": -1.0, "name": "CA_HELI_PITCH_C4", "shortDesc": "Collective pitch curve at position 4", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Same definition as the proportional gain but for integral.\n\n", "max": 10.0, "min": 0.0, "name": "CA_HELI_RPM_I", "shortDesc": "Integral gain for rpm control", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Ratio between rpm error devided by 1000 to how much normalized output gets added to correct for it.\n\nmotor_command = throttle_curve + CA_HELI_RPM_P * (rpm_setpoint - rpm_measurement) / 1000\n\n", "max": 10.0, "min": 0.0, "name": "CA_HELI_RPM_P", "shortDesc": "Proportional gain for rpm control", "type": "Float"}, {"category": "Standard", "decimalPlaces": 0, "default": 1500.0, "group": "Geometry", "increment": 1.0, "longDesc": "Requires rpm feedback for the controller.\n\n", "max": 10000.0, "min": 100.0, "name": "CA_HELI_RPM_SP", "shortDesc": "Setpoint for main rotor rpm", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Defines the output throttle at the interval position 0.\n\n", "max": 1.0, "min": 0.0, "name": "CA_HELI_THR_C0", "shortDesc": "Throttle curve at position 0", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Defines the output throttle at the interval position 1.\n\n", "max": 1.0, "min": 0.0, "name": "CA_HELI_THR_C1", "shortDesc": "Throttle curve at position 1", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Defines the output throttle at the interval position 2.\n\n", "max": 1.0, "min": 0.0, "name": "CA_HELI_THR_C2", "shortDesc": "Throttle curve at position 2", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Defines the output throttle at the interval position 3.\n\n", "max": 1.0, "min": 0.0, "name": "CA_HELI_THR_C3", "shortDesc": "Throttle curve at position 3", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Defines the output throttle at the interval position 4.\n\n", "max": 1.0, "min": 0.0, "name": "CA_HELI_THR_C4", "shortDesc": "Throttle curve at position 4", "type": "Float"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "Default configuration is for a clockwise turning main rotor and\npositive thrust of the tail rotor is expected to rotate the vehicle clockwise.\nSet this parameter to true if the tail rotor provides thrust in counter-clockwise direction\nwhich is mostly the case when the main rotor turns counter-clockwise.\n\n", "name": "CA_HELI_YAW_CCW", "shortDesc": "Main rotor turns counter-clockwise", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "This allows to specify which collective pitch command results in the least amount of rotor drag.\nThis is used to increase the accuracy of the yaw drag torque compensation based on collective pitch\nby aligning the lowest rotor drag with zero compensation.\nFor symmetric profile blades this is the command that results in exactly 0\u00b0 collective blade angle.\nFor lift profile blades this is typically a command resulting in slightly negative collective blade angle.\n\ntail_output += CA_HELI_YAW_CP_S * abs(collective_pitch - CA_HELI_YAW_CP_O)\n\n", "max": 2.0, "min": -2.0, "name": "CA_HELI_YAW_CP_O", "shortDesc": "Offset for yaw compensation based on collective pitch", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "This allows to add a proportional factor of the collective pitch command to the yaw command.\nA negative value is needed when positive thrust of the tail rotor rotates the vehicle opposite to the main rotor turn direction.\n\ntail_output += CA_HELI_YAW_CP_S * abs(collective_pitch - CA_HELI_YAW_CP_O)\n\n", "max": 2.0, "min": -2.0, "name": "CA_HELI_YAW_CP_S", "shortDesc": "Scale for yaw compensation based on collective pitch", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "This allows to add a proportional factor of the throttle command to the yaw command.\nA negative value is needed when positive thrust of the tail rotor rotates the vehicle opposite to the main rotor turn direction.\n\ntail_output += CA_HELI_YAW_TH_S * throttle\n\n", "max": 2.0, "min": -2.0, "name": "CA_HELI_YAW_TH_S", "shortDesc": "Scale for yaw compensation based on throttle", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Ice shedding prevents ice buildup in VTOL aircraft motors by periodically spinning inactive rotors.\nWhen enabled (period > 0), every cycle lasts for the defined period and includes a 2-second spin at 0.01 motor output.\nIf period <= 0, the feature is disabled.\n\n", "min": 0.0, "name": "CA_ICE_PERIOD", "shortDesc": "Ice shedding cycle period", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Used to linearize mechanical output of swashplate servos to avoid axis coupling and binding with 4 servo redundancy.\nThis requires a symmetric setup where the servo horn is exactly centered with a 0 command.\nSetting to zero disables feature.\n\n", "max": 75.0, "min": 0.0, "name": "CA_MAX_SVO_THROW", "shortDesc": "Throw angle of swashplate servo at maximum commands for linearization", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 2, "group": "Geometry", "longDesc": "Selects the algorithm and desaturation method.\nIf set to Automatic, the selection is based on the airframe (CA_AIRFRAME).\n\n", "name": "CA_METHOD", "shortDesc": "Control allocation method", "type": "Int32", "values": [{"description": "Pseudo-inverse with output clipping", "value": 0}, {"description": "Pseudo-inverse with sequential desaturation technique", "value": 1}, {"description": "Automatic", "value": 2}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.01, "longDesc": "Forces the motor output signal to take at least the configured time (in seconds)\nto traverse its full range (normally [0, 1], or if reversible [-1, 1]).\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_R0_SLEW", "shortDesc": "Motor 0 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.01, "longDesc": "Forces the motor output signal to take at least the configured time (in seconds)\nto traverse its full range (normally [0, 1], or if reversible [-1, 1]).\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_R10_SLEW", "shortDesc": "Motor 10 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.01, "longDesc": "Forces the motor output signal to take at least the configured time (in seconds)\nto traverse its full range (normally [0, 1], or if reversible [-1, 1]).\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_R11_SLEW", "shortDesc": "Motor 11 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.01, "longDesc": "Forces the motor output signal to take at least the configured time (in seconds)\nto traverse its full range (normally [0, 1], or if reversible [-1, 1]).\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_R1_SLEW", "shortDesc": "Motor 1 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.01, "longDesc": "Forces the motor output signal to take at least the configured time (in seconds)\nto traverse its full range (normally [0, 1], or if reversible [-1, 1]).\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_R2_SLEW", "shortDesc": "Motor 2 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.01, "longDesc": "Forces the motor output signal to take at least the configured time (in seconds)\nto traverse its full range (normally [0, 1], or if reversible [-1, 1]).\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_R3_SLEW", "shortDesc": "Motor 3 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.01, "longDesc": "Forces the motor output signal to take at least the configured time (in seconds)\nto traverse its full range (normally [0, 1], or if reversible [-1, 1]).\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_R4_SLEW", "shortDesc": "Motor 4 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.01, "longDesc": "Forces the motor output signal to take at least the configured time (in seconds)\nto traverse its full range (normally [0, 1], or if reversible [-1, 1]).\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_R5_SLEW", "shortDesc": "Motor 5 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.01, "longDesc": "Forces the motor output signal to take at least the configured time (in seconds)\nto traverse its full range (normally [0, 1], or if reversible [-1, 1]).\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_R6_SLEW", "shortDesc": "Motor 6 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.01, "longDesc": "Forces the motor output signal to take at least the configured time (in seconds)\nto traverse its full range (normally [0, 1], or if reversible [-1, 1]).\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_R7_SLEW", "shortDesc": "Motor 7 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.01, "longDesc": "Forces the motor output signal to take at least the configured time (in seconds)\nto traverse its full range (normally [0, 1], or if reversible [-1, 1]).\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_R8_SLEW", "shortDesc": "Motor 8 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.01, "longDesc": "Forces the motor output signal to take at least the configured time (in seconds)\nto traverse its full range (normally [0, 1], or if reversible [-1, 1]).\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_R9_SLEW", "shortDesc": "Motor 9 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "default": 0.4, "group": "Geometry", "longDesc": "Fraction of forward thrust a reversible motor produces in reverse (e.g. 0.4 = 40%).\nThis is mostly a property of the propeller.\n\n", "max": 1.0, "min": 0.1, "name": "CA_REV_THR_FRAC", "shortDesc": "Reverse thrust fraction for reversible motors", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR0_AX", "shortDesc": "Axis of rotor 0 thrust vector, X body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR0_AY", "shortDesc": "Axis of rotor 0 thrust vector, Y body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR0_AZ", "shortDesc": "Axis of rotor 0 thrust vector, Z body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 6.5, "group": "Geometry", "increment": 1.0, "longDesc": "The thrust coefficient if defined as Thrust = CT * u^2,\nwhere u (with value between actuator minimum and maximum)\nis the output signal sent to the motor controller.\n\n", "max": 100.0, "min": 0.0, "name": "CA_ROTOR0_CT", "shortDesc": "Thrust coefficient of rotor 0", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "Geometry", "increment": 0.01, "longDesc": "The moment coefficient if defined as Torque = KM * Thrust.\n\nUse a positive value for a rotor with CCW rotation.\nUse a negative value for a rotor with CW rotation.\n\n", "max": 1.0, "min": -1.0, "name": "CA_ROTOR0_KM", "shortDesc": "Moment coefficient of rotor 0", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR0_PX", "shortDesc": "Position of rotor 0 along X body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR0_PY", "shortDesc": "Position of rotor 0 along Y body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR0_PZ", "shortDesc": "Position of rotor 0 along Z body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "If not set to None, this motor is tilted by the configured tilt servo.\n", "name": "CA_ROTOR0_TILT", "shortDesc": "Rotor 0 tilt assignment", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Tilt 1", "value": 1}, {"description": "Tilt 2", "value": 2}, {"description": "Tilt 3", "value": 3}, {"description": "Tilt 4", "value": 4}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR10_AX", "shortDesc": "Axis of rotor 10 thrust vector, X body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR10_AY", "shortDesc": "Axis of rotor 10 thrust vector, Y body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR10_AZ", "shortDesc": "Axis of rotor 10 thrust vector, Z body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 6.5, "group": "Geometry", "increment": 1.0, "longDesc": "The thrust coefficient if defined as Thrust = CT * u^2,\nwhere u (with value between actuator minimum and maximum)\nis the output signal sent to the motor controller.\n\n", "max": 100.0, "min": 0.0, "name": "CA_ROTOR10_CT", "shortDesc": "Thrust coefficient of rotor 10", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "Geometry", "increment": 0.01, "longDesc": "The moment coefficient if defined as Torque = KM * Thrust.\n\nUse a positive value for a rotor with CCW rotation.\nUse a negative value for a rotor with CW rotation.\n\n", "max": 1.0, "min": -1.0, "name": "CA_ROTOR10_KM", "shortDesc": "Moment coefficient of rotor 10", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR10_PX", "shortDesc": "Position of rotor 10 along X body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR10_PY", "shortDesc": "Position of rotor 10 along Y body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR10_PZ", "shortDesc": "Position of rotor 10 along Z body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "If not set to None, this motor is tilted by the configured tilt servo.\n", "name": "CA_ROTOR10_TILT", "shortDesc": "Rotor 10 tilt assignment", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Tilt 1", "value": 1}, {"description": "Tilt 2", "value": 2}, {"description": "Tilt 3", "value": 3}, {"description": "Tilt 4", "value": 4}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR11_AX", "shortDesc": "Axis of rotor 11 thrust vector, X body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR11_AY", "shortDesc": "Axis of rotor 11 thrust vector, Y body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR11_AZ", "shortDesc": "Axis of rotor 11 thrust vector, Z body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 6.5, "group": "Geometry", "increment": 1.0, "longDesc": "The thrust coefficient if defined as Thrust = CT * u^2,\nwhere u (with value between actuator minimum and maximum)\nis the output signal sent to the motor controller.\n\n", "max": 100.0, "min": 0.0, "name": "CA_ROTOR11_CT", "shortDesc": "Thrust coefficient of rotor 11", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "Geometry", "increment": 0.01, "longDesc": "The moment coefficient if defined as Torque = KM * Thrust.\n\nUse a positive value for a rotor with CCW rotation.\nUse a negative value for a rotor with CW rotation.\n\n", "max": 1.0, "min": -1.0, "name": "CA_ROTOR11_KM", "shortDesc": "Moment coefficient of rotor 11", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR11_PX", "shortDesc": "Position of rotor 11 along X body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR11_PY", "shortDesc": "Position of rotor 11 along Y body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR11_PZ", "shortDesc": "Position of rotor 11 along Z body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "If not set to None, this motor is tilted by the configured tilt servo.\n", "name": "CA_ROTOR11_TILT", "shortDesc": "Rotor 11 tilt assignment", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Tilt 1", "value": 1}, {"description": "Tilt 2", "value": 2}, {"description": "Tilt 3", "value": 3}, {"description": "Tilt 4", "value": 4}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR1_AX", "shortDesc": "Axis of rotor 1 thrust vector, X body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR1_AY", "shortDesc": "Axis of rotor 1 thrust vector, Y body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR1_AZ", "shortDesc": "Axis of rotor 1 thrust vector, Z body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 6.5, "group": "Geometry", "increment": 1.0, "longDesc": "The thrust coefficient if defined as Thrust = CT * u^2,\nwhere u (with value between actuator minimum and maximum)\nis the output signal sent to the motor controller.\n\n", "max": 100.0, "min": 0.0, "name": "CA_ROTOR1_CT", "shortDesc": "Thrust coefficient of rotor 1", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "Geometry", "increment": 0.01, "longDesc": "The moment coefficient if defined as Torque = KM * Thrust.\n\nUse a positive value for a rotor with CCW rotation.\nUse a negative value for a rotor with CW rotation.\n\n", "max": 1.0, "min": -1.0, "name": "CA_ROTOR1_KM", "shortDesc": "Moment coefficient of rotor 1", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR1_PX", "shortDesc": "Position of rotor 1 along X body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR1_PY", "shortDesc": "Position of rotor 1 along Y body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR1_PZ", "shortDesc": "Position of rotor 1 along Z body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "If not set to None, this motor is tilted by the configured tilt servo.\n", "name": "CA_ROTOR1_TILT", "shortDesc": "Rotor 1 tilt assignment", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Tilt 1", "value": 1}, {"description": "Tilt 2", "value": 2}, {"description": "Tilt 3", "value": 3}, {"description": "Tilt 4", "value": 4}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR2_AX", "shortDesc": "Axis of rotor 2 thrust vector, X body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR2_AY", "shortDesc": "Axis of rotor 2 thrust vector, Y body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR2_AZ", "shortDesc": "Axis of rotor 2 thrust vector, Z body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 6.5, "group": "Geometry", "increment": 1.0, "longDesc": "The thrust coefficient if defined as Thrust = CT * u^2,\nwhere u (with value between actuator minimum and maximum)\nis the output signal sent to the motor controller.\n\n", "max": 100.0, "min": 0.0, "name": "CA_ROTOR2_CT", "shortDesc": "Thrust coefficient of rotor 2", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "Geometry", "increment": 0.01, "longDesc": "The moment coefficient if defined as Torque = KM * Thrust.\n\nUse a positive value for a rotor with CCW rotation.\nUse a negative value for a rotor with CW rotation.\n\n", "max": 1.0, "min": -1.0, "name": "CA_ROTOR2_KM", "shortDesc": "Moment coefficient of rotor 2", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR2_PX", "shortDesc": "Position of rotor 2 along X body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR2_PY", "shortDesc": "Position of rotor 2 along Y body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR2_PZ", "shortDesc": "Position of rotor 2 along Z body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "If not set to None, this motor is tilted by the configured tilt servo.\n", "name": "CA_ROTOR2_TILT", "shortDesc": "Rotor 2 tilt assignment", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Tilt 1", "value": 1}, {"description": "Tilt 2", "value": 2}, {"description": "Tilt 3", "value": 3}, {"description": "Tilt 4", "value": 4}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR3_AX", "shortDesc": "Axis of rotor 3 thrust vector, X body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR3_AY", "shortDesc": "Axis of rotor 3 thrust vector, Y body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR3_AZ", "shortDesc": "Axis of rotor 3 thrust vector, Z body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 6.5, "group": "Geometry", "increment": 1.0, "longDesc": "The thrust coefficient if defined as Thrust = CT * u^2,\nwhere u (with value between actuator minimum and maximum)\nis the output signal sent to the motor controller.\n\n", "max": 100.0, "min": 0.0, "name": "CA_ROTOR3_CT", "shortDesc": "Thrust coefficient of rotor 3", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "Geometry", "increment": 0.01, "longDesc": "The moment coefficient if defined as Torque = KM * Thrust.\n\nUse a positive value for a rotor with CCW rotation.\nUse a negative value for a rotor with CW rotation.\n\n", "max": 1.0, "min": -1.0, "name": "CA_ROTOR3_KM", "shortDesc": "Moment coefficient of rotor 3", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR3_PX", "shortDesc": "Position of rotor 3 along X body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR3_PY", "shortDesc": "Position of rotor 3 along Y body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR3_PZ", "shortDesc": "Position of rotor 3 along Z body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "If not set to None, this motor is tilted by the configured tilt servo.\n", "name": "CA_ROTOR3_TILT", "shortDesc": "Rotor 3 tilt assignment", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Tilt 1", "value": 1}, {"description": "Tilt 2", "value": 2}, {"description": "Tilt 3", "value": 3}, {"description": "Tilt 4", "value": 4}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR4_AX", "shortDesc": "Axis of rotor 4 thrust vector, X body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR4_AY", "shortDesc": "Axis of rotor 4 thrust vector, Y body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR4_AZ", "shortDesc": "Axis of rotor 4 thrust vector, Z body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 6.5, "group": "Geometry", "increment": 1.0, "longDesc": "The thrust coefficient if defined as Thrust = CT * u^2,\nwhere u (with value between actuator minimum and maximum)\nis the output signal sent to the motor controller.\n\n", "max": 100.0, "min": 0.0, "name": "CA_ROTOR4_CT", "shortDesc": "Thrust coefficient of rotor 4", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "Geometry", "increment": 0.01, "longDesc": "The moment coefficient if defined as Torque = KM * Thrust.\n\nUse a positive value for a rotor with CCW rotation.\nUse a negative value for a rotor with CW rotation.\n\n", "max": 1.0, "min": -1.0, "name": "CA_ROTOR4_KM", "shortDesc": "Moment coefficient of rotor 4", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR4_PX", "shortDesc": "Position of rotor 4 along X body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR4_PY", "shortDesc": "Position of rotor 4 along Y body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR4_PZ", "shortDesc": "Position of rotor 4 along Z body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "If not set to None, this motor is tilted by the configured tilt servo.\n", "name": "CA_ROTOR4_TILT", "shortDesc": "Rotor 4 tilt assignment", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Tilt 1", "value": 1}, {"description": "Tilt 2", "value": 2}, {"description": "Tilt 3", "value": 3}, {"description": "Tilt 4", "value": 4}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR5_AX", "shortDesc": "Axis of rotor 5 thrust vector, X body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR5_AY", "shortDesc": "Axis of rotor 5 thrust vector, Y body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR5_AZ", "shortDesc": "Axis of rotor 5 thrust vector, Z body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 6.5, "group": "Geometry", "increment": 1.0, "longDesc": "The thrust coefficient if defined as Thrust = CT * u^2,\nwhere u (with value between actuator minimum and maximum)\nis the output signal sent to the motor controller.\n\n", "max": 100.0, "min": 0.0, "name": "CA_ROTOR5_CT", "shortDesc": "Thrust coefficient of rotor 5", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "Geometry", "increment": 0.01, "longDesc": "The moment coefficient if defined as Torque = KM * Thrust.\n\nUse a positive value for a rotor with CCW rotation.\nUse a negative value for a rotor with CW rotation.\n\n", "max": 1.0, "min": -1.0, "name": "CA_ROTOR5_KM", "shortDesc": "Moment coefficient of rotor 5", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR5_PX", "shortDesc": "Position of rotor 5 along X body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR5_PY", "shortDesc": "Position of rotor 5 along Y body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR5_PZ", "shortDesc": "Position of rotor 5 along Z body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "If not set to None, this motor is tilted by the configured tilt servo.\n", "name": "CA_ROTOR5_TILT", "shortDesc": "Rotor 5 tilt assignment", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Tilt 1", "value": 1}, {"description": "Tilt 2", "value": 2}, {"description": "Tilt 3", "value": 3}, {"description": "Tilt 4", "value": 4}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR6_AX", "shortDesc": "Axis of rotor 6 thrust vector, X body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR6_AY", "shortDesc": "Axis of rotor 6 thrust vector, Y body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR6_AZ", "shortDesc": "Axis of rotor 6 thrust vector, Z body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 6.5, "group": "Geometry", "increment": 1.0, "longDesc": "The thrust coefficient if defined as Thrust = CT * u^2,\nwhere u (with value between actuator minimum and maximum)\nis the output signal sent to the motor controller.\n\n", "max": 100.0, "min": 0.0, "name": "CA_ROTOR6_CT", "shortDesc": "Thrust coefficient of rotor 6", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "Geometry", "increment": 0.01, "longDesc": "The moment coefficient if defined as Torque = KM * Thrust.\n\nUse a positive value for a rotor with CCW rotation.\nUse a negative value for a rotor with CW rotation.\n\n", "max": 1.0, "min": -1.0, "name": "CA_ROTOR6_KM", "shortDesc": "Moment coefficient of rotor 6", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR6_PX", "shortDesc": "Position of rotor 6 along X body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR6_PY", "shortDesc": "Position of rotor 6 along Y body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR6_PZ", "shortDesc": "Position of rotor 6 along Z body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "If not set to None, this motor is tilted by the configured tilt servo.\n", "name": "CA_ROTOR6_TILT", "shortDesc": "Rotor 6 tilt assignment", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Tilt 1", "value": 1}, {"description": "Tilt 2", "value": 2}, {"description": "Tilt 3", "value": 3}, {"description": "Tilt 4", "value": 4}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR7_AX", "shortDesc": "Axis of rotor 7 thrust vector, X body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR7_AY", "shortDesc": "Axis of rotor 7 thrust vector, Y body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR7_AZ", "shortDesc": "Axis of rotor 7 thrust vector, Z body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 6.5, "group": "Geometry", "increment": 1.0, "longDesc": "The thrust coefficient if defined as Thrust = CT * u^2,\nwhere u (with value between actuator minimum and maximum)\nis the output signal sent to the motor controller.\n\n", "max": 100.0, "min": 0.0, "name": "CA_ROTOR7_CT", "shortDesc": "Thrust coefficient of rotor 7", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "Geometry", "increment": 0.01, "longDesc": "The moment coefficient if defined as Torque = KM * Thrust.\n\nUse a positive value for a rotor with CCW rotation.\nUse a negative value for a rotor with CW rotation.\n\n", "max": 1.0, "min": -1.0, "name": "CA_ROTOR7_KM", "shortDesc": "Moment coefficient of rotor 7", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR7_PX", "shortDesc": "Position of rotor 7 along X body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR7_PY", "shortDesc": "Position of rotor 7 along Y body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR7_PZ", "shortDesc": "Position of rotor 7 along Z body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "If not set to None, this motor is tilted by the configured tilt servo.\n", "name": "CA_ROTOR7_TILT", "shortDesc": "Rotor 7 tilt assignment", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Tilt 1", "value": 1}, {"description": "Tilt 2", "value": 2}, {"description": "Tilt 3", "value": 3}, {"description": "Tilt 4", "value": 4}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR8_AX", "shortDesc": "Axis of rotor 8 thrust vector, X body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR8_AY", "shortDesc": "Axis of rotor 8 thrust vector, Y body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR8_AZ", "shortDesc": "Axis of rotor 8 thrust vector, Z body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 6.5, "group": "Geometry", "increment": 1.0, "longDesc": "The thrust coefficient if defined as Thrust = CT * u^2,\nwhere u (with value between actuator minimum and maximum)\nis the output signal sent to the motor controller.\n\n", "max": 100.0, "min": 0.0, "name": "CA_ROTOR8_CT", "shortDesc": "Thrust coefficient of rotor 8", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "Geometry", "increment": 0.01, "longDesc": "The moment coefficient if defined as Torque = KM * Thrust.\n\nUse a positive value for a rotor with CCW rotation.\nUse a negative value for a rotor with CW rotation.\n\n", "max": 1.0, "min": -1.0, "name": "CA_ROTOR8_KM", "shortDesc": "Moment coefficient of rotor 8", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR8_PX", "shortDesc": "Position of rotor 8 along X body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR8_PY", "shortDesc": "Position of rotor 8 along Y body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR8_PZ", "shortDesc": "Position of rotor 8 along Z body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "If not set to None, this motor is tilted by the configured tilt servo.\n", "name": "CA_ROTOR8_TILT", "shortDesc": "Rotor 8 tilt assignment", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Tilt 1", "value": 1}, {"description": "Tilt 2", "value": 2}, {"description": "Tilt 3", "value": 3}, {"description": "Tilt 4", "value": 4}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR9_AX", "shortDesc": "Axis of rotor 9 thrust vector, X body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR9_AY", "shortDesc": "Axis of rotor 9 thrust vector, Y body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Geometry", "increment": 0.1, "longDesc": "Only the direction is considered (the vector is normalized).\n", "max": 100.0, "min": -100.0, "name": "CA_ROTOR9_AZ", "shortDesc": "Axis of rotor 9 thrust vector, Z body axis component", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 6.5, "group": "Geometry", "increment": 1.0, "longDesc": "The thrust coefficient if defined as Thrust = CT * u^2,\nwhere u (with value between actuator minimum and maximum)\nis the output signal sent to the motor controller.\n\n", "max": 100.0, "min": 0.0, "name": "CA_ROTOR9_CT", "shortDesc": "Thrust coefficient of rotor 9", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "Geometry", "increment": 0.01, "longDesc": "The moment coefficient if defined as Torque = KM * Thrust.\n\nUse a positive value for a rotor with CCW rotation.\nUse a negative value for a rotor with CW rotation.\n\n", "max": 1.0, "min": -1.0, "name": "CA_ROTOR9_KM", "shortDesc": "Moment coefficient of rotor 9", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR9_PX", "shortDesc": "Position of rotor 9 along X body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR9_PY", "shortDesc": "Position of rotor 9 along Y body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.1, "max": 100.0, "min": -100.0, "name": "CA_ROTOR9_PZ", "shortDesc": "Position of rotor 9 along Z body axis relative to center of gravity", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "If not set to None, this motor is tilted by the configured tilt servo.\n", "name": "CA_ROTOR9_TILT", "shortDesc": "Rotor 9 tilt assignment", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Tilt 1", "value": 1}, {"description": "Tilt 2", "value": 2}, {"description": "Tilt 3", "value": 3}, {"description": "Tilt 4", "value": 4}]}, {"category": "Standard", "default": 0, "group": "Geometry", "name": "CA_ROTOR_COUNT", "shortDesc": "Total number of rotors", "type": "Int32", "values": [{"description": "0", "value": 0}, {"description": "1", "value": 1}, {"description": "2", "value": 2}, {"description": "3", "value": 3}, {"description": "4", "value": 4}, {"description": "5", "value": 5}, {"description": "6", "value": 6}, {"description": "7", "value": 7}, {"description": "8", "value": 8}, {"description": "9", "value": 9}, {"description": "10", "value": 10}, {"description": "11", "value": 11}, {"description": "12", "value": 12}]}, {"bitmask": [{"description": "Motor 1", "index": 0}, {"description": "Motor 2", "index": 1}, {"description": "Motor 3", "index": 2}, {"description": "Motor 4", "index": 3}, {"description": "Motor 5", "index": 4}, {"description": "Motor 6", "index": 5}, {"description": "Motor 7", "index": 6}, {"description": "Motor 8", "index": 7}, {"description": "Motor 9", "index": 8}, {"description": "Motor 10", "index": 9}, {"description": "Motor 11", "index": 10}, {"description": "Motor 12", "index": 11}], "category": "Standard", "default": 0, "group": "Geometry", "longDesc": "Configure motors to be bidirectional/reversible. Note that the output driver needs to support this as well.\n\n", "max": 4095, "min": 0, "name": "CA_R_REV", "shortDesc": "Bidirectional/Reversible motors", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 0, "default": 0.0, "group": "Geometry", "increment": 10.0, "longDesc": "The angle is measured clockwise (as seen from top), with 0 pointing forwards (X axis).\n\n", "max": 360.0, "min": 0.0, "name": "CA_SP0_ANG0", "shortDesc": "Angle for swash plate servo 0", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 0, "default": 140.0, "group": "Geometry", "increment": 10.0, "longDesc": "The angle is measured clockwise (as seen from top), with 0 pointing forwards (X axis).\n\n", "max": 360.0, "min": 0.0, "name": "CA_SP0_ANG1", "shortDesc": "Angle for swash plate servo 1", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 0, "default": 220.0, "group": "Geometry", "increment": 10.0, "longDesc": "The angle is measured clockwise (as seen from top), with 0 pointing forwards (X axis).\n\n", "max": 360.0, "min": 0.0, "name": "CA_SP0_ANG2", "shortDesc": "Angle for swash plate servo 2", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 0, "default": 0.0, "group": "Geometry", "increment": 10.0, "longDesc": "The angle is measured clockwise (as seen from top), with 0 pointing forwards (X axis).\n\n", "max": 360.0, "min": 0.0, "name": "CA_SP0_ANG3", "shortDesc": "Angle for swash plate servo 3", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "Geometry", "increment": 0.1, "longDesc": "This is relative to the other arm lengths.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SP0_ARM_L0", "shortDesc": "Arm length for swash plate servo 0", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "Geometry", "increment": 0.1, "longDesc": "This is relative to the other arm lengths.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SP0_ARM_L1", "shortDesc": "Arm length for swash plate servo 1", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "Geometry", "increment": 0.1, "longDesc": "This is relative to the other arm lengths.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SP0_ARM_L2", "shortDesc": "Arm length for swash plate servo 2", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "Geometry", "increment": 0.1, "longDesc": "This is relative to the other arm lengths.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SP0_ARM_L3", "shortDesc": "Arm length for swash plate servo 3", "type": "Float"}, {"category": "Standard", "default": 3, "group": "Geometry", "name": "CA_SP0_COUNT", "shortDesc": "Number of swash plates servos", "type": "Int32", "values": [{"description": "2", "value": 2}, {"description": "3", "value": 3}, {"description": "4", "value": 4}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.05, "longDesc": "Forces the servo output signal to take at least the configured time (in seconds)\nto traverse its full range [-100%, 100%].\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SV0_SLEW", "shortDesc": "Servo 0 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.05, "longDesc": "Forces the servo output signal to take at least the configured time (in seconds)\nto traverse its full range [-100%, 100%].\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SV10_SLEW", "shortDesc": "Servo 10 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.05, "longDesc": "Forces the servo output signal to take at least the configured time (in seconds)\nto traverse its full range [-100%, 100%].\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SV11_SLEW", "shortDesc": "Servo 11 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.05, "longDesc": "Forces the servo output signal to take at least the configured time (in seconds)\nto traverse its full range [-100%, 100%].\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SV12_SLEW", "shortDesc": "Servo 12 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.05, "longDesc": "Forces the servo output signal to take at least the configured time (in seconds)\nto traverse its full range [-100%, 100%].\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SV13_SLEW", "shortDesc": "Servo 13 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.05, "longDesc": "Forces the servo output signal to take at least the configured time (in seconds)\nto traverse its full range [-100%, 100%].\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SV14_SLEW", "shortDesc": "Servo 14 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.05, "longDesc": "Forces the servo output signal to take at least the configured time (in seconds)\nto traverse its full range [-100%, 100%].\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SV1_SLEW", "shortDesc": "Servo 1 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.05, "longDesc": "Forces the servo output signal to take at least the configured time (in seconds)\nto traverse its full range [-100%, 100%].\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SV2_SLEW", "shortDesc": "Servo 2 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.05, "longDesc": "Forces the servo output signal to take at least the configured time (in seconds)\nto traverse its full range [-100%, 100%].\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SV3_SLEW", "shortDesc": "Servo 3 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.05, "longDesc": "Forces the servo output signal to take at least the configured time (in seconds)\nto traverse its full range [-100%, 100%].\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SV4_SLEW", "shortDesc": "Servo 4 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.05, "longDesc": "Forces the servo output signal to take at least the configured time (in seconds)\nto traverse its full range [-100%, 100%].\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SV5_SLEW", "shortDesc": "Servo 5 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.05, "longDesc": "Forces the servo output signal to take at least the configured time (in seconds)\nto traverse its full range [-100%, 100%].\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SV6_SLEW", "shortDesc": "Servo 6 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.05, "longDesc": "Forces the servo output signal to take at least the configured time (in seconds)\nto traverse its full range [-100%, 100%].\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SV7_SLEW", "shortDesc": "Servo 7 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.05, "longDesc": "Forces the servo output signal to take at least the configured time (in seconds)\nto traverse its full range [-100%, 100%].\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SV8_SLEW", "shortDesc": "Servo 8 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "increment": 0.05, "longDesc": "Forces the servo output signal to take at least the configured time (in seconds)\nto traverse its full range [-100%, 100%].\n\nZero means that slew rate limiting is disabled.\n\n", "max": 10.0, "min": 0.0, "name": "CA_SV9_SLEW", "shortDesc": "Servo 9 slew rate limit", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "max": 1.0, "min": -1.0, "name": "CA_SV_CS0_FLAP", "shortDesc": "Control Surface 0 configuration as flap", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "max": 1.0, "min": -1.0, "name": "CA_SV_CS0_SPOIL", "shortDesc": "Control Surface 0 configuration as spoiler", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "longDesc": "Can be used to add an offset to the servo control.\n\nNOTE: Do not use for PWM servos. Use the PWM CENTER parameters instead (e.g., PWM_MAIN_CENT, PWM_AUX_CENT) instead.\nThis parameter can only be set if all PWM Center parameters are set to default.\n\n", "max": 1.0, "min": -1.0, "name": "CA_SV_CS0_TRIM", "shortDesc": "Control Surface 0 trim", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS0_TRQ_P", "shortDesc": "Control Surface 0 pitch torque scaling", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS0_TRQ_R", "shortDesc": "Control Surface 0 roll torque scaling", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS0_TRQ_Y", "shortDesc": "Control Surface 0 yaw torque scaling", "type": "Float"}, {"category": "Standard", "default": 0, "group": "Geometry", "name": "CA_SV_CS0_TYPE", "shortDesc": "Control Surface 0 type", "type": "Int32", "values": [{"description": "(Not set)", "value": 0}, {"description": "Left Aileron", "value": 1}, {"description": "Right Aileron", "value": 2}, {"description": "Elevator", "value": 3}, {"description": "Rudder", "value": 4}, {"description": "Left Elevon", "value": 5}, {"description": "Right Elevon", "value": 6}, {"description": "Left V-Tail", "value": 7}, {"description": "Right V-Tail", "value": 8}, {"description": "Left Flap", "value": 9}, {"description": "Right Flap", "value": 10}, {"description": "Airbrake", "value": 11}, {"description": "Custom", "value": 12}, {"description": "Left A-tail", "value": 13}, {"description": "Right A-tail", "value": 14}, {"description": "Single Channel Aileron", "value": 15}, {"description": "Steering Wheel", "value": 16}, {"description": "Left Spoiler", "value": 17}, {"description": "Right Spoiler", "value": 18}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "max": 1.0, "min": -1.0, "name": "CA_SV_CS1_FLAP", "shortDesc": "Control Surface 1 configuration as flap", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "max": 1.0, "min": -1.0, "name": "CA_SV_CS1_SPOIL", "shortDesc": "Control Surface 1 configuration as spoiler", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "longDesc": "Can be used to add an offset to the servo control.\n\nNOTE: Do not use for PWM servos. Use the PWM CENTER parameters instead (e.g., PWM_MAIN_CENT, PWM_AUX_CENT) instead.\nThis parameter can only be set if all PWM Center parameters are set to default.\n\n", "max": 1.0, "min": -1.0, "name": "CA_SV_CS1_TRIM", "shortDesc": "Control Surface 1 trim", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS1_TRQ_P", "shortDesc": "Control Surface 1 pitch torque scaling", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS1_TRQ_R", "shortDesc": "Control Surface 1 roll torque scaling", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS1_TRQ_Y", "shortDesc": "Control Surface 1 yaw torque scaling", "type": "Float"}, {"category": "Standard", "default": 0, "group": "Geometry", "name": "CA_SV_CS1_TYPE", "shortDesc": "Control Surface 1 type", "type": "Int32", "values": [{"description": "(Not set)", "value": 0}, {"description": "Left Aileron", "value": 1}, {"description": "Right Aileron", "value": 2}, {"description": "Elevator", "value": 3}, {"description": "Rudder", "value": 4}, {"description": "Left Elevon", "value": 5}, {"description": "Right Elevon", "value": 6}, {"description": "Left V-Tail", "value": 7}, {"description": "Right V-Tail", "value": 8}, {"description": "Left Flap", "value": 9}, {"description": "Right Flap", "value": 10}, {"description": "Airbrake", "value": 11}, {"description": "Custom", "value": 12}, {"description": "Left A-tail", "value": 13}, {"description": "Right A-tail", "value": 14}, {"description": "Single Channel Aileron", "value": 15}, {"description": "Steering Wheel", "value": 16}, {"description": "Left Spoiler", "value": 17}, {"description": "Right Spoiler", "value": 18}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "max": 1.0, "min": -1.0, "name": "CA_SV_CS2_FLAP", "shortDesc": "Control Surface 2 configuration as flap", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "max": 1.0, "min": -1.0, "name": "CA_SV_CS2_SPOIL", "shortDesc": "Control Surface 2 configuration as spoiler", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "longDesc": "Can be used to add an offset to the servo control.\n\nNOTE: Do not use for PWM servos. Use the PWM CENTER parameters instead (e.g., PWM_MAIN_CENT, PWM_AUX_CENT) instead.\nThis parameter can only be set if all PWM Center parameters are set to default.\n\n", "max": 1.0, "min": -1.0, "name": "CA_SV_CS2_TRIM", "shortDesc": "Control Surface 2 trim", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS2_TRQ_P", "shortDesc": "Control Surface 2 pitch torque scaling", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS2_TRQ_R", "shortDesc": "Control Surface 2 roll torque scaling", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS2_TRQ_Y", "shortDesc": "Control Surface 2 yaw torque scaling", "type": "Float"}, {"category": "Standard", "default": 0, "group": "Geometry", "name": "CA_SV_CS2_TYPE", "shortDesc": "Control Surface 2 type", "type": "Int32", "values": [{"description": "(Not set)", "value": 0}, {"description": "Left Aileron", "value": 1}, {"description": "Right Aileron", "value": 2}, {"description": "Elevator", "value": 3}, {"description": "Rudder", "value": 4}, {"description": "Left Elevon", "value": 5}, {"description": "Right Elevon", "value": 6}, {"description": "Left V-Tail", "value": 7}, {"description": "Right V-Tail", "value": 8}, {"description": "Left Flap", "value": 9}, {"description": "Right Flap", "value": 10}, {"description": "Airbrake", "value": 11}, {"description": "Custom", "value": 12}, {"description": "Left A-tail", "value": 13}, {"description": "Right A-tail", "value": 14}, {"description": "Single Channel Aileron", "value": 15}, {"description": "Steering Wheel", "value": 16}, {"description": "Left Spoiler", "value": 17}, {"description": "Right Spoiler", "value": 18}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "max": 1.0, "min": -1.0, "name": "CA_SV_CS3_FLAP", "shortDesc": "Control Surface 3 configuration as flap", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "max": 1.0, "min": -1.0, "name": "CA_SV_CS3_SPOIL", "shortDesc": "Control Surface 3 configuration as spoiler", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "longDesc": "Can be used to add an offset to the servo control.\n\nNOTE: Do not use for PWM servos. Use the PWM CENTER parameters instead (e.g., PWM_MAIN_CENT, PWM_AUX_CENT) instead.\nThis parameter can only be set if all PWM Center parameters are set to default.\n\n", "max": 1.0, "min": -1.0, "name": "CA_SV_CS3_TRIM", "shortDesc": "Control Surface 3 trim", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS3_TRQ_P", "shortDesc": "Control Surface 3 pitch torque scaling", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS3_TRQ_R", "shortDesc": "Control Surface 3 roll torque scaling", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS3_TRQ_Y", "shortDesc": "Control Surface 3 yaw torque scaling", "type": "Float"}, {"category": "Standard", "default": 0, "group": "Geometry", "name": "CA_SV_CS3_TYPE", "shortDesc": "Control Surface 3 type", "type": "Int32", "values": [{"description": "(Not set)", "value": 0}, {"description": "Left Aileron", "value": 1}, {"description": "Right Aileron", "value": 2}, {"description": "Elevator", "value": 3}, {"description": "Rudder", "value": 4}, {"description": "Left Elevon", "value": 5}, {"description": "Right Elevon", "value": 6}, {"description": "Left V-Tail", "value": 7}, {"description": "Right V-Tail", "value": 8}, {"description": "Left Flap", "value": 9}, {"description": "Right Flap", "value": 10}, {"description": "Airbrake", "value": 11}, {"description": "Custom", "value": 12}, {"description": "Left A-tail", "value": 13}, {"description": "Right A-tail", "value": 14}, {"description": "Single Channel Aileron", "value": 15}, {"description": "Steering Wheel", "value": 16}, {"description": "Left Spoiler", "value": 17}, {"description": "Right Spoiler", "value": 18}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "max": 1.0, "min": -1.0, "name": "CA_SV_CS4_FLAP", "shortDesc": "Control Surface 4 configuration as flap", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "max": 1.0, "min": -1.0, "name": "CA_SV_CS4_SPOIL", "shortDesc": "Control Surface 4 configuration as spoiler", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "longDesc": "Can be used to add an offset to the servo control.\n\nNOTE: Do not use for PWM servos. Use the PWM CENTER parameters instead (e.g., PWM_MAIN_CENT, PWM_AUX_CENT) instead.\nThis parameter can only be set if all PWM Center parameters are set to default.\n\n", "max": 1.0, "min": -1.0, "name": "CA_SV_CS4_TRIM", "shortDesc": "Control Surface 4 trim", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS4_TRQ_P", "shortDesc": "Control Surface 4 pitch torque scaling", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS4_TRQ_R", "shortDesc": "Control Surface 4 roll torque scaling", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS4_TRQ_Y", "shortDesc": "Control Surface 4 yaw torque scaling", "type": "Float"}, {"category": "Standard", "default": 0, "group": "Geometry", "name": "CA_SV_CS4_TYPE", "shortDesc": "Control Surface 4 type", "type": "Int32", "values": [{"description": "(Not set)", "value": 0}, {"description": "Left Aileron", "value": 1}, {"description": "Right Aileron", "value": 2}, {"description": "Elevator", "value": 3}, {"description": "Rudder", "value": 4}, {"description": "Left Elevon", "value": 5}, {"description": "Right Elevon", "value": 6}, {"description": "Left V-Tail", "value": 7}, {"description": "Right V-Tail", "value": 8}, {"description": "Left Flap", "value": 9}, {"description": "Right Flap", "value": 10}, {"description": "Airbrake", "value": 11}, {"description": "Custom", "value": 12}, {"description": "Left A-tail", "value": 13}, {"description": "Right A-tail", "value": 14}, {"description": "Single Channel Aileron", "value": 15}, {"description": "Steering Wheel", "value": 16}, {"description": "Left Spoiler", "value": 17}, {"description": "Right Spoiler", "value": 18}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "max": 1.0, "min": -1.0, "name": "CA_SV_CS5_FLAP", "shortDesc": "Control Surface 5 configuration as flap", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "max": 1.0, "min": -1.0, "name": "CA_SV_CS5_SPOIL", "shortDesc": "Control Surface 5 configuration as spoiler", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "longDesc": "Can be used to add an offset to the servo control.\n\nNOTE: Do not use for PWM servos. Use the PWM CENTER parameters instead (e.g., PWM_MAIN_CENT, PWM_AUX_CENT) instead.\nThis parameter can only be set if all PWM Center parameters are set to default.\n\n", "max": 1.0, "min": -1.0, "name": "CA_SV_CS5_TRIM", "shortDesc": "Control Surface 5 trim", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS5_TRQ_P", "shortDesc": "Control Surface 5 pitch torque scaling", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS5_TRQ_R", "shortDesc": "Control Surface 5 roll torque scaling", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS5_TRQ_Y", "shortDesc": "Control Surface 5 yaw torque scaling", "type": "Float"}, {"category": "Standard", "default": 0, "group": "Geometry", "name": "CA_SV_CS5_TYPE", "shortDesc": "Control Surface 5 type", "type": "Int32", "values": [{"description": "(Not set)", "value": 0}, {"description": "Left Aileron", "value": 1}, {"description": "Right Aileron", "value": 2}, {"description": "Elevator", "value": 3}, {"description": "Rudder", "value": 4}, {"description": "Left Elevon", "value": 5}, {"description": "Right Elevon", "value": 6}, {"description": "Left V-Tail", "value": 7}, {"description": "Right V-Tail", "value": 8}, {"description": "Left Flap", "value": 9}, {"description": "Right Flap", "value": 10}, {"description": "Airbrake", "value": 11}, {"description": "Custom", "value": 12}, {"description": "Left A-tail", "value": 13}, {"description": "Right A-tail", "value": 14}, {"description": "Single Channel Aileron", "value": 15}, {"description": "Steering Wheel", "value": 16}, {"description": "Left Spoiler", "value": 17}, {"description": "Right Spoiler", "value": 18}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "max": 1.0, "min": -1.0, "name": "CA_SV_CS6_FLAP", "shortDesc": "Control Surface 6 configuration as flap", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "max": 1.0, "min": -1.0, "name": "CA_SV_CS6_SPOIL", "shortDesc": "Control Surface 6 configuration as spoiler", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "longDesc": "Can be used to add an offset to the servo control.\n\nNOTE: Do not use for PWM servos. Use the PWM CENTER parameters instead (e.g., PWM_MAIN_CENT, PWM_AUX_CENT) instead.\nThis parameter can only be set if all PWM Center parameters are set to default.\n\n", "max": 1.0, "min": -1.0, "name": "CA_SV_CS6_TRIM", "shortDesc": "Control Surface 6 trim", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS6_TRQ_P", "shortDesc": "Control Surface 6 pitch torque scaling", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS6_TRQ_R", "shortDesc": "Control Surface 6 roll torque scaling", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS6_TRQ_Y", "shortDesc": "Control Surface 6 yaw torque scaling", "type": "Float"}, {"category": "Standard", "default": 0, "group": "Geometry", "name": "CA_SV_CS6_TYPE", "shortDesc": "Control Surface 6 type", "type": "Int32", "values": [{"description": "(Not set)", "value": 0}, {"description": "Left Aileron", "value": 1}, {"description": "Right Aileron", "value": 2}, {"description": "Elevator", "value": 3}, {"description": "Rudder", "value": 4}, {"description": "Left Elevon", "value": 5}, {"description": "Right Elevon", "value": 6}, {"description": "Left V-Tail", "value": 7}, {"description": "Right V-Tail", "value": 8}, {"description": "Left Flap", "value": 9}, {"description": "Right Flap", "value": 10}, {"description": "Airbrake", "value": 11}, {"description": "Custom", "value": 12}, {"description": "Left A-tail", "value": 13}, {"description": "Right A-tail", "value": 14}, {"description": "Single Channel Aileron", "value": 15}, {"description": "Steering Wheel", "value": 16}, {"description": "Left Spoiler", "value": 17}, {"description": "Right Spoiler", "value": 18}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "max": 1.0, "min": -1.0, "name": "CA_SV_CS7_FLAP", "shortDesc": "Control Surface 7 configuration as flap", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "max": 1.0, "min": -1.0, "name": "CA_SV_CS7_SPOIL", "shortDesc": "Control Surface 7 configuration as spoiler", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "longDesc": "Can be used to add an offset to the servo control.\n\nNOTE: Do not use for PWM servos. Use the PWM CENTER parameters instead (e.g., PWM_MAIN_CENT, PWM_AUX_CENT) instead.\nThis parameter can only be set if all PWM Center parameters are set to default.\n\n", "max": 1.0, "min": -1.0, "name": "CA_SV_CS7_TRIM", "shortDesc": "Control Surface 7 trim", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS7_TRQ_P", "shortDesc": "Control Surface 7 pitch torque scaling", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS7_TRQ_R", "shortDesc": "Control Surface 7 roll torque scaling", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Geometry", "name": "CA_SV_CS7_TRQ_Y", "shortDesc": "Control Surface 7 yaw torque scaling", "type": "Float"}, {"category": "Standard", "default": 0, "group": "Geometry", "name": "CA_SV_CS7_TYPE", "shortDesc": "Control Surface 7 type", "type": "Int32", "values": [{"description": "(Not set)", "value": 0}, {"description": "Left Aileron", "value": 1}, {"description": "Right Aileron", "value": 2}, {"description": "Elevator", "value": 3}, {"description": "Rudder", "value": 4}, {"description": "Left Elevon", "value": 5}, {"description": "Right Elevon", "value": 6}, {"description": "Left V-Tail", "value": 7}, {"description": "Right V-Tail", "value": 8}, {"description": "Left Flap", "value": 9}, {"description": "Right Flap", "value": 10}, {"description": "Airbrake", "value": 11}, {"description": "Custom", "value": 12}, {"description": "Left A-tail", "value": 13}, {"description": "Right A-tail", "value": 14}, {"description": "Single Channel Aileron", "value": 15}, {"description": "Steering Wheel", "value": 16}, {"description": "Left Spoiler", "value": 17}, {"description": "Right Spoiler", "value": 18}]}, {"category": "Standard", "default": 0, "group": "Geometry", "name": "CA_SV_CS_COUNT", "shortDesc": "Total number of Control Surfaces", "type": "Int32", "values": [{"description": "0", "value": 0}, {"description": "1", "value": 1}, {"description": "2", "value": 2}, {"description": "3", "value": 3}, {"description": "4", "value": 4}, {"description": "5", "value": 5}, {"description": "6", "value": 6}, {"description": "7", "value": 7}, {"description": "8", "value": 8}]}, {"category": "Standard", "decimalPlaces": 1, "default": 0.5, "group": "Geometry", "max": 5.0, "min": 0.0, "name": "CA_SV_FLAP_SLEW", "shortDesc": "Control Surface slew rate for normalized flaps setpoint", "type": "Float"}, {"category": "Standard", "default": 1, "group": "Geometry", "longDesc": "Define if this servo is used for additional control.\n", "name": "CA_SV_TL0_CT", "shortDesc": "Tilt 0 is used for control", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Yaw", "value": 1}, {"description": "Pitch", "value": 2}, {"description": "Yaw and Pitch", "value": 3}]}, {"category": "Standard", "decimalPlaces": 0, "default": 90.0, "group": "Geometry", "longDesc": "Defines the tilt angle when the servo is at the maximum.\nAn angle of zero means upwards.\n\n", "max": 90.0, "min": -90.0, "name": "CA_SV_TL0_MAXA", "shortDesc": "Tilt Servo 0 Tilt Angle at Maximum", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 0, "default": 0.0, "group": "Geometry", "longDesc": "Defines the tilt angle when the servo is at the minimum.\nAn angle of zero means upwards.\n\n", "max": 90.0, "min": -90.0, "name": "CA_SV_TL0_MINA", "shortDesc": "Tilt Servo 0 Tilt Angle at Minimum", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "Defines the direction the servo tilts towards when moving towards the maximum tilt angle.\nFor example if the minimum tilt angle is -90, the maximum 90, and the direction 'Towards Front',\nthe motor axis aligns with the XZ-plane, points towards -X at the minimum and +X at the maximum tilt.\n\n", "max": 359, "min": 0, "name": "CA_SV_TL0_TD", "shortDesc": "Tilt Servo 0 Tilt Direction", "type": "Int32", "values": [{"description": "Towards Front", "value": 0}, {"description": "Towards Right", "value": 90}]}, {"category": "Standard", "default": 1, "group": "Geometry", "longDesc": "Define if this servo is used for additional control.\n", "name": "CA_SV_TL1_CT", "shortDesc": "Tilt 1 is used for control", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Yaw", "value": 1}, {"description": "Pitch", "value": 2}, {"description": "Yaw and Pitch", "value": 3}]}, {"category": "Standard", "decimalPlaces": 0, "default": 90.0, "group": "Geometry", "longDesc": "Defines the tilt angle when the servo is at the maximum.\nAn angle of zero means upwards.\n\n", "max": 90.0, "min": -90.0, "name": "CA_SV_TL1_MAXA", "shortDesc": "Tilt Servo 1 Tilt Angle at Maximum", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 0, "default": 0.0, "group": "Geometry", "longDesc": "Defines the tilt angle when the servo is at the minimum.\nAn angle of zero means upwards.\n\n", "max": 90.0, "min": -90.0, "name": "CA_SV_TL1_MINA", "shortDesc": "Tilt Servo 1 Tilt Angle at Minimum", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "Defines the direction the servo tilts towards when moving towards the maximum tilt angle.\nFor example if the minimum tilt angle is -90, the maximum 90, and the direction 'Towards Front',\nthe motor axis aligns with the XZ-plane, points towards -X at the minimum and +X at the maximum tilt.\n\n", "max": 359, "min": 0, "name": "CA_SV_TL1_TD", "shortDesc": "Tilt Servo 1 Tilt Direction", "type": "Int32", "values": [{"description": "Towards Front", "value": 0}, {"description": "Towards Right", "value": 90}]}, {"category": "Standard", "default": 1, "group": "Geometry", "longDesc": "Define if this servo is used for additional control.\n", "name": "CA_SV_TL2_CT", "shortDesc": "Tilt 2 is used for control", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Yaw", "value": 1}, {"description": "Pitch", "value": 2}, {"description": "Yaw and Pitch", "value": 3}]}, {"category": "Standard", "decimalPlaces": 0, "default": 90.0, "group": "Geometry", "longDesc": "Defines the tilt angle when the servo is at the maximum.\nAn angle of zero means upwards.\n\n", "max": 90.0, "min": -90.0, "name": "CA_SV_TL2_MAXA", "shortDesc": "Tilt Servo 2 Tilt Angle at Maximum", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 0, "default": 0.0, "group": "Geometry", "longDesc": "Defines the tilt angle when the servo is at the minimum.\nAn angle of zero means upwards.\n\n", "max": 90.0, "min": -90.0, "name": "CA_SV_TL2_MINA", "shortDesc": "Tilt Servo 2 Tilt Angle at Minimum", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "Defines the direction the servo tilts towards when moving towards the maximum tilt angle.\nFor example if the minimum tilt angle is -90, the maximum 90, and the direction 'Towards Front',\nthe motor axis aligns with the XZ-plane, points towards -X at the minimum and +X at the maximum tilt.\n\n", "max": 359, "min": 0, "name": "CA_SV_TL2_TD", "shortDesc": "Tilt Servo 2 Tilt Direction", "type": "Int32", "values": [{"description": "Towards Front", "value": 0}, {"description": "Towards Right", "value": 90}]}, {"category": "Standard", "default": 1, "group": "Geometry", "longDesc": "Define if this servo is used for additional control.\n", "name": "CA_SV_TL3_CT", "shortDesc": "Tilt 3 is used for control", "type": "Int32", "values": [{"description": "None", "value": 0}, {"description": "Yaw", "value": 1}, {"description": "Pitch", "value": 2}, {"description": "Yaw and Pitch", "value": 3}]}, {"category": "Standard", "decimalPlaces": 0, "default": 90.0, "group": "Geometry", "longDesc": "Defines the tilt angle when the servo is at the maximum.\nAn angle of zero means upwards.\n\n", "max": 90.0, "min": -90.0, "name": "CA_SV_TL3_MAXA", "shortDesc": "Tilt Servo 3 Tilt Angle at Maximum", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 0, "default": 0.0, "group": "Geometry", "longDesc": "Defines the tilt angle when the servo is at the minimum.\nAn angle of zero means upwards.\n\n", "max": 90.0, "min": -90.0, "name": "CA_SV_TL3_MINA", "shortDesc": "Tilt Servo 3 Tilt Angle at Minimum", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 0, "group": "Geometry", "longDesc": "Defines the direction the servo tilts towards when moving towards the maximum tilt angle.\nFor example if the minimum tilt angle is -90, the maximum 90, and the direction 'Towards Front',\nthe motor axis aligns with the XZ-plane, points towards -X at the minimum and +X at the maximum tilt.\n\n", "max": 359, "min": 0, "name": "CA_SV_TL3_TD", "shortDesc": "Tilt Servo 3 Tilt Direction", "type": "Int32", "values": [{"description": "Towards Front", "value": 0}, {"description": "Towards Right", "value": 90}]}, {"category": "Standard", "default": 0, "group": "Geometry", "name": "CA_SV_TL_COUNT", "shortDesc": "Total number of Tilt Servos", "type": "Int32", "values": [{"description": "0", "value": 0}, {"description": "1", "value": 1}, {"description": "2", "value": 2}, {"description": "3", "value": 3}, {"description": "4", "value": 4}]}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "Hover Thrust Estimator", "longDesc": "Sets the number of standard deviations used\nby the innovation consistency test.\n", "max": 10.0, "min": 1.0, "name": "HTE_ACC_GATE", "shortDesc": "Gate size for acceleration fusion", "type": "Float", "units": "SD"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.1, "group": "Hover Thrust Estimator", "longDesc": "Initial standard deviation of the hover thrust state estimate.\nLarger values allow the estimate to move farther from the initial\nhover thrust before process noise takes over.\n", "max": 1.0, "min": 0.0, "name": "HTE_HT_ERR_INIT", "shortDesc": "1-sigma initial hover thrust uncertainty", "type": "Float", "units": "normalized_thrust"}, {"category": "Standard", "decimalPlaces": 4, "default": 0.0036, "group": "Hover Thrust Estimator", "longDesc": "Reduce to make the hover thrust estimate\nmore stable, increase if the real hover thrust\nis expected to change quickly over time.\n", "max": 1.0, "min": 0.0001, "name": "HTE_HT_NOISE", "shortDesc": "Hover thrust process noise", "type": "Float", "units": "normalized_thrust/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.2, "group": "Hover Thrust Estimator", "longDesc": "Defines the range of the hover thrust estimate around MPC_THR_HOVER.\nA value of 0.2 with MPC_THR_HOVER at 0.5 results in a range of [0.3, 0.7].\n\nSet to a large value if the vehicle operates in varying physical conditions that\naffect the required hover thrust strongly (e.g. differently sized payloads).\n", "max": 0.4, "min": 0.01, "name": "HTE_THR_RANGE", "shortDesc": "Max deviation from MPC_THR_HOVER", "type": "Float", "units": "normalized_thrust"}, {"category": "Standard", "decimalPlaces": 1, "default": 10.0, "group": "Hover Thrust Estimator", "longDesc": "Above this speed, the measurement noise is linearly increased\nto reduce the sensitivity of the estimator from biased measurement.\n\nSet to a low value on vehicles with large lifting surfaces.\n", "max": 20.0, "min": 1.0, "name": "HTE_VXY_THR", "shortDesc": "Horizontal velocity threshold for sensitivity reduction", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 2.0, "group": "Hover Thrust Estimator", "longDesc": "Above this speed, the measurement noise is linearly increased\nto reduce the sensitivity of the estimator from biased measurement.\n\nSet to a low value on vehicles affected by air drag when climbing or descending.\n", "max": 10.0, "min": 1.0, "name": "HTE_VZ_THR", "shortDesc": "Vertical velocity threshold for sensitivity reduction", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 6.0, "group": "Land Detector", "longDesc": "Maximum airspeed allowed in the landed state\n", "max": 30.0, "min": 2.0, "name": "LNDFW_AIRSPD_MAX", "shortDesc": "Fixed-wing land detector: Max airspeed", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.5, "group": "Land Detector", "longDesc": "Maximum allowed norm of the angular velocity in the landed state.\nOnly used if neither airspeed nor groundspeed can be used for landing detection.\n", "name": "LNDFW_ROT_MAX", "shortDesc": "Fixed-wing land detector: max rotational speed", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 2.0, "group": "Land Detector", "longDesc": "Time the land conditions (speeds and acceleration) have to be satisfied to detect a landing.\n", "min": 0.1, "name": "LNDFW_TRIG_TIME", "rebootRequired": true, "shortDesc": "Fixed-wing land detection trigger time", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "Land Detector", "longDesc": "Maximum horizontal velocity allowed in the landed state.\nA factor of 0.7 is applied in case of airspeed-less flying\n(either because no sensor is present or sensor data got invalid in flight).\n", "max": 20.0, "min": 0.5, "name": "LNDFW_VEL_XY_MAX", "shortDesc": "Fixed-wing land detector: Max horizontal velocity threshold", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.0, "group": "Land Detector", "longDesc": "Maximum vertical velocity allowed in the landed state.\n", "max": 20.0, "min": 0.1, "name": "LNDFW_VEL_Z_MAX", "shortDesc": "Fixed-wing land detector: Max vertiacal velocity threshold", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 8.0, "group": "Land Detector", "longDesc": "Maximum gravity-compensated horizontal (earth frame) acceleration allowed in the landed state.\n", "max": 30.0, "min": 2.0, "name": "LNDFW_XYACC_MAX", "shortDesc": "Fixed-wing land detector: Max horizontal acceleration", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "decimalPlaces": 2, "default": 2.0, "group": "Land Detector", "longDesc": "The height above ground below which ground effect creates barometric altitude errors.\nA negative value indicates no ground effect.\n", "min": -1.0, "name": "LNDMC_ALT_GND", "shortDesc": "Ground effect altitude for multicopters", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 20.0, "group": "Land Detector", "longDesc": "Maximum allowed norm of the angular velocity (roll, pitch) in the landed state.\n", "name": "LNDMC_ROT_MAX", "shortDesc": "Multicopter max rotational speed", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.5, "group": "Land Detector", "longDesc": "Maximum horizontal velocity allowed in the landed state\n", "name": "LNDMC_XY_VEL_MAX", "shortDesc": "Multicopter max horizontal velocity", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.25, "group": "Land Detector", "longDesc": "Vertical velocity threshold to detect landing.\nHas to be set lower than the expected minimal speed for landing,\nwhich is either MPC_LAND_SPEED or MPC_LAND_CRWL.\nThis is enforced by an automatic check.\n", "min": 0.0, "name": "LNDMC_Z_VEL_MAX", "shortDesc": "Multicopter vertical velocity threshold", "type": "Float", "units": "m/s"}, {"category": "System", "default": 0, "group": "Land Detector", "longDesc": "Total flight time of this autopilot. Higher 32 bits of the value.\nFlight time in microseconds = (LND_FLIGHT_T_HI << 32) | LND_FLIGHT_T_LO.\n", "min": 0, "name": "LND_FLIGHT_T_HI", "shortDesc": "Total flight time in microseconds", "type": "Int32", "volatile": true}, {"category": "System", "default": 0, "group": "Land Detector", "longDesc": "Total flight time of this autopilot. Lower 32 bits of the value.\nFlight time in microseconds = (LND_FLIGHT_T_HI << 32) | LND_FLIGHT_T_LO.\n", "min": 0, "name": "LND_FLIGHT_T_LO", "shortDesc": "Total flight time in microseconds", "type": "Int32", "volatile": true}, {"category": "Standard", "decimalPlaces": 5, "default": 0.012, "group": "Local Position Estimator", "longDesc": "Data sheet noise density = 150ug/sqrt(Hz) = 0.0015 m/s^2/sqrt(Hz)\n\nLarger than data sheet to account for tilt error.\n", "max": 2.0, "min": 1e-05, "name": "LPE_ACC_XY", "shortDesc": "Accelerometer xy noise density", "type": "Float", "units": "m/s^2/sqrt(Hz)"}, {"category": "Standard", "decimalPlaces": 5, "default": 0.02, "group": "Local Position Estimator", "longDesc": "Data sheet noise density = 150ug/sqrt(Hz) = 0.0015 m/s^2/sqrt(Hz)\n", "max": 2.0, "min": 1e-05, "name": "LPE_ACC_Z", "shortDesc": "Accelerometer z noise density", "type": "Float", "units": "m/s^2/sqrt(Hz)"}, {"category": "Standard", "decimalPlaces": 2, "default": 3.0, "group": "Local Position Estimator", "max": 100.0, "min": 0.01, "name": "LPE_BAR_Z", "shortDesc": "Barometric pressure altitude z standard deviation", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Local Position Estimator", "name": "LPE_EN", "shortDesc": "Local position estimator enable (unsupported)", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 3, "default": 3.0, "group": "Local Position Estimator", "max": 5.0, "min": 1.0, "name": "LPE_EPH_MAX", "shortDesc": "Max EPH allowed for GPS initialization", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 5.0, "group": "Local Position Estimator", "max": 5.0, "min": 1.0, "name": "LPE_EPV_MAX", "shortDesc": "Max EPV allowed for GPS initialization", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Local Position Estimator", "longDesc": "Enable publishing of a fake global position (e.g for AUTO missions using Optical Flow)\n\nBy initializing the estimator to the LPE_LAT/LON parameters when global information is unavailable\n", "max": 1, "min": 0, "name": "LPE_FAKE_ORIGIN", "shortDesc": "Enable fake global position for optical flow", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.001, "group": "Local Position Estimator", "max": 2.0, "min": 0.0, "name": "LPE_FGYRO_HP", "shortDesc": "Flow gyro high pass filter cut off frequency", "type": "Float", "units": "Hz"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Local Position Estimator", "max": 1.0, "min": -1.0, "name": "LPE_FLW_OFF_Z", "shortDesc": "Optical flow z offset from center", "type": "Float", "units": "m"}, {"category": "Standard", "default": 150, "group": "Local Position Estimator", "max": 255, "min": 0, "name": "LPE_FLW_QMIN", "shortDesc": "Optical flow minimum quality threshold", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 3, "default": 7.0, "group": "Local Position Estimator", "max": 10.0, "min": 0.1, "name": "LPE_FLW_R", "shortDesc": "Optical flow rotation (roll/pitch) noise gain", "type": "Float", "units": "m/s/rad"}, {"category": "Standard", "decimalPlaces": 3, "default": 7.0, "group": "Local Position Estimator", "max": 10.0, "min": 0.0, "name": "LPE_FLW_RR", "shortDesc": "Optical flow angular velocity noise gain", "type": "Float", "units": "m/rad"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.3, "group": "Local Position Estimator", "max": 10.0, "min": 0.1, "name": "LPE_FLW_SCALE", "shortDesc": "Optical flow scale", "type": "Float", "units": "m"}, {"bitmask": [{"description": "fuse GPS, requires GPS for alt. init", "index": 0}, {"description": "fuse optical flow", "index": 1}, {"description": "fuse vision position", "index": 2}, {"description": "fuse landing target", "index": 3}, {"description": "fuse land detector", "index": 4}, {"description": "pub agl as lpos down", "index": 5}, {"description": "flow gyro compensation", "index": 6}, {"description": "fuse baro", "index": 7}], "category": "Standard", "default": 145, "group": "Local Position Estimator", "longDesc": "Set bits in the following positions to enable:\n0 : Set to true to fuse GPS data if available, also requires GPS for altitude init\n1 : Set to true to fuse optical flow data if available\n2 : Set to true to fuse vision position\n3 : Set to true to enable landing target\n4 : Set to true to fuse land detector\n5 : Set to true to publish AGL as local position down component\n6 : Set to true to enable flow gyro compensation\n7 : Set to true to enable baro fusion\n\ndefault (145 - GPS, baro, land detector)\n", "max": 255, "min": 0, "name": "LPE_FUSION", "shortDesc": "Integer bitmask controlling data fusion", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.29, "group": "Local Position Estimator", "max": 0.4, "min": 0.0, "name": "LPE_GPS_DELAY", "shortDesc": "GPS delay compensation", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.25, "group": "Local Position Estimator", "longDesc": "EPV used if greater than this value.\n", "max": 2.0, "min": 0.01, "name": "LPE_GPS_VXY", "shortDesc": "GPS xy velocity standard deviation", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.25, "group": "Local Position Estimator", "max": 2.0, "min": 0.01, "name": "LPE_GPS_VZ", "shortDesc": "GPS z velocity standard deviation", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Local Position Estimator", "max": 5.0, "min": 0.01, "name": "LPE_GPS_XY", "shortDesc": "Minimum GPS xy standard deviation, uses reported EPH if greater", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 3.0, "group": "Local Position Estimator", "max": 200.0, "min": 0.01, "name": "LPE_GPS_Z", "shortDesc": "Minimum GPS z standard deviation, uses reported EPV if greater", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "Local Position Estimator", "max": 10.0, "min": 0.01, "name": "LPE_LAND_VXY", "shortDesc": "Land detector xy velocity standard deviation", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.03, "group": "Local Position Estimator", "max": 10.0, "min": 0.001, "name": "LPE_LAND_Z", "shortDesc": "Land detector z standard deviation", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 8, "default": 47.397742, "group": "Local Position Estimator", "max": 90.0, "min": -90.0, "name": "LPE_LAT", "shortDesc": "Local origin latitude for nav w/o GPS", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Local Position Estimator", "max": 1.0, "min": -1.0, "name": "LPE_LDR_OFF_Z", "shortDesc": "Lidar z offset from center of vehicle +down", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.03, "group": "Local Position Estimator", "max": 1.0, "min": 0.01, "name": "LPE_LDR_Z", "shortDesc": "Lidar z standard deviation", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 8, "default": 8.545594, "group": "Local Position Estimator", "max": 180.0, "min": -180.0, "name": "LPE_LON", "shortDesc": "Local origin longitude for nav w/o GPS", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 4, "default": 0.0001, "group": "Local Position Estimator", "longDesc": "Minimum landing target standard covariance, uses reported covariance if greater\n", "max": 10.0, "min": 0.0, "name": "LPE_LT_COV", "shortDesc": "Minimum landing target standard covariance", "type": "Float", "units": "m^2"}, {"category": "Standard", "decimalPlaces": 8, "default": 0.001, "group": "Local Position Estimator", "max": 1.0, "min": 0.0, "name": "LPE_PN_B", "shortDesc": "Accel bias propagation noise density", "type": "Float", "units": "m/s^3/sqrt(Hz)"}, {"category": "Standard", "decimalPlaces": 8, "default": 0.1, "group": "Local Position Estimator", "longDesc": "Increase to trust measurements more.\nDecrease to trust model more.\n", "max": 1.0, "min": 0.0, "name": "LPE_PN_P", "shortDesc": "Position propagation noise density", "type": "Float", "units": "m/s/sqrt(Hz)"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.001, "group": "Local Position Estimator", "longDesc": "Terrain random walk noise density, hilly/outdoor (0.1), flat/Indoor (0.001)\n", "max": 1.0, "min": 0.0, "name": "LPE_PN_T", "shortDesc": "Terrain random walk noise density", "type": "Float", "units": "m/s/sqrt(Hz)"}, {"category": "Standard", "decimalPlaces": 8, "default": 0.1, "group": "Local Position Estimator", "longDesc": "Increase to trust measurements more.\nDecrease to trust model more.\n", "max": 1.0, "min": 0.0, "name": "LPE_PN_V", "shortDesc": "Velocity propagation noise density", "type": "Float", "units": "m/s^2/sqrt(Hz)"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Local Position Estimator", "max": 1.0, "min": -1.0, "name": "LPE_SNR_OFF_Z", "shortDesc": "Sonar z offset from center of vehicle +down", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "Local Position Estimator", "max": 1.0, "min": 0.01, "name": "LPE_SNR_Z", "shortDesc": "Sonar z standard deviation", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "Local Position Estimator", "longDesc": "Terrain maximum percent grade, hilly/outdoor (100 = 45 deg), flat/Indoor (0 = 0 deg)\n\nUsed to calculate increased terrain random walk noise due to movement.\n", "max": 100.0, "min": 0.0, "name": "LPE_T_MAX_GRADE", "shortDesc": "Terrain maximum percent grade", "type": "Float", "units": "%"}, {"category": "Standard", "decimalPlaces": 4, "default": 0.001, "group": "Local Position Estimator", "max": 1.0, "min": 0.0001, "name": "LPE_VIC_P", "shortDesc": "Vicon position standard deviation", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "Local Position Estimator", "longDesc": "Set to zero to enable automatic compensation from measurement timestamps\n", "max": 0.1, "min": 0.0, "name": "LPE_VIS_DELAY", "shortDesc": "Vision delay compensation", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.1, "group": "Local Position Estimator", "max": 1.0, "min": 0.01, "name": "LPE_VIS_XY", "shortDesc": "Vision xy standard deviation", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.5, "group": "Local Position Estimator", "max": 100.0, "min": 0.01, "name": "LPE_VIS_Z", "shortDesc": "Vision z standard deviation", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.3, "group": "Local Position Estimator", "max": 1.0, "min": 0.01, "name": "LPE_VXY_PUB", "shortDesc": "Required velocity xy standard deviation to publish position", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 0, "default": 5.0, "group": "Local Position Estimator", "max": 1000.0, "min": 5.0, "name": "LPE_X_LP", "shortDesc": "Cut frequency for state publication", "type": "Float", "units": "Hz"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.0, "group": "Local Position Estimator", "max": 5.0, "min": 0.3, "name": "LPE_Z_PUB", "shortDesc": "Required z standard deviation to publish altitude/ terrain", "type": "Float", "units": "m"}, {"category": "Standard", "default": 1, "group": "MAVLink", "longDesc": "This allows a ground control station to automatically find the drone\non the local network.\n\n", "name": "MAV_0_BROADCAST", "shortDesc": "Broadcast heartbeats on local network for MAVLink instance 0", "type": "Int32", "values": [{"description": "Never broadcast", "value": 0}, {"description": "Always broadcast", "value": 1}, {"description": "Only multicast", "value": 2}]}, {"category": "Standard", "default": 2, "group": "MAVLink", "longDesc": "This is used to force flow control on or off for the the mavlink\ninstance. By default it is auto detected. Use when auto detection fails.\n\n", "name": "MAV_0_FLOW_CTRL", "rebootRequired": true, "shortDesc": "Enable serial flow control for instance 0", "type": "Int32", "values": [{"description": "Force off", "value": 0}, {"description": "Force on", "value": 1}, {"description": "Auto-detected", "value": 2}]}, {"category": "Standard", "default": 1, "group": "MAVLink", "longDesc": "If enabled, forward incoming MAVLink messages to other MAVLink ports if the\nmessage is either broadcast or the target is not the autopilot.\n\nThis allows for example a GCS to talk to a camera that is connected to the\nautopilot via MAVLink (on a different link than the GCS).\n\n", "name": "MAV_0_FORWARD", "rebootRequired": true, "shortDesc": "Enable MAVLink Message forwarding for instance 0", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 3, "default": 0.015, "group": "MAVLink", "increment": 0.001, "longDesc": "Positive real value that configures the transmission frequency of the\nHIGH_LATENCY2 stream for instance 0, configured in iridium mode.\nThis parameter has no effect if the instance mode is different from iridium.\n\n", "max": 50.0, "min": 0.0, "name": "MAV_0_HL_FREQ", "rebootRequired": true, "shortDesc": "Configures the frequency of HIGH_LATENCY2 stream for instance 0", "type": "Float", "units": "Hz"}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "The MAVLink Mode defines the set of streamed messages (for example the\nvehicle's attitude) and their sending rates.\n\nUse ADS-B/Traffic for a traffic receiver such as an ADS-B or FLARM\ndevice. With message signing active, unsigned ADSB_VEHICLE and\nCOLLISION messages are only accepted on links in this mode.\n\n", "name": "MAV_0_MODE", "rebootRequired": true, "shortDesc": "MAVLink Mode for instance 0", "type": "Int32", "values": [{"description": "Normal", "value": 0}, {"description": "Custom", "value": 1}, {"description": "Onboard", "value": 2}, {"description": "OSD", "value": 3}, {"description": "Magic", "value": 4}, {"description": "Config", "value": 5}, {"description": "Minimal", "value": 7}, {"description": "External Vision", "value": 8}, {"description": "Gimbal", "value": 10}, {"description": "Onboard Low Bandwidth", "value": 11}, {"description": "ADS-B/Traffic (uAvionix)", "value": 12}, {"description": "Low Bandwidth", "value": 13}]}, {"category": "Standard", "default": 1, "group": "MAVLink", "longDesc": "If enabled, MAVLink messages will be throttled according to\n`txbuf` field reported by radio_status.\n\nRequires a radio to send the mavlink message RADIO_STATUS.\n\n", "name": "MAV_0_RADIO_CTL", "rebootRequired": true, "shortDesc": "Enable software throttling of mavlink on instance 0", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 2000, "group": "MAVLink", "longDesc": "Configure the maximum sending rate for the MAVLink streams in Bytes/sec.\nIf the configured streams exceed the maximum rate, the sending rate of\neach stream is automatically decreased.\n\nIf this is set to 0 a value of half of the theoretical maximum bandwidth is used.\nThis corresponds to baudrate/20 Bytes/s (baudrate/10 = maximum data rate on\n8N1-configured links). USB and UDP links have no baudrate, so for those 0\nmeans 100000 Bytes/s.\n\nNote that for a telemetry radio the serial baudrate says little about what\nthe link can actually carry over the air. A SiK radio at the common 57600\nbaud, 64 kbps air rate carries roughly 2000 B/s with error correction\nenabled and about twice that without, where baudrate/20 would suggest 2880.\nInstance 0 therefore defaults to a fixed value that is safe either way\nrather than to 0. Raise it if you know your link is better.\n\n", "min": 0, "name": "MAV_0_RATE", "rebootRequired": true, "shortDesc": "Maximum MAVLink sending rate for instance 0", "type": "Int32", "units": "B/s"}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "Messages go to this address at port MAV_0_REMOTE_PRT. Encoded as int32\nwith the first octet in the most significant byte, e.g. 192.168.1.2 is -1062731518.\nSet to 0 to discover the partner from received packets.\n\n", "name": "MAV_0_REMOTE_IP", "rebootRequired": true, "shortDesc": "MAVLink Partner IP for instance 0", "type": "Int32"}, {"category": "Standard", "default": 14550, "group": "MAVLink", "longDesc": "If ethernet enabled and selected as configuration for MAVLink instance 0,\nselected remote port will be set and used in MAVLink instance 0.\n\n", "name": "MAV_0_REMOTE_PRT", "rebootRequired": true, "shortDesc": "MAVLink Remote Port for instance 0", "type": "Int32"}, {"category": "Standard", "default": 14556, "group": "MAVLink", "longDesc": "If ethernet enabled and selected as configuration for MAVLink instance 0,\nselected udp port will be set and used in MAVLink instance 0.\n\n", "name": "MAV_0_UDP_PRT", "rebootRequired": true, "shortDesc": "MAVLink Network Port for instance 0", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "This allows a ground control station to automatically find the drone\non the local network.\n\n", "name": "MAV_1_BROADCAST", "shortDesc": "Broadcast heartbeats on local network for MAVLink instance 1", "type": "Int32", "values": [{"description": "Never broadcast", "value": 0}, {"description": "Always broadcast", "value": 1}, {"description": "Only multicast", "value": 2}]}, {"category": "Standard", "default": 2, "group": "MAVLink", "longDesc": "This is used to force flow control on or off for the the mavlink\ninstance. By default it is auto detected. Use when auto detection fails.\n\n", "name": "MAV_1_FLOW_CTRL", "rebootRequired": true, "shortDesc": "Enable serial flow control for instance 1", "type": "Int32", "values": [{"description": "Force off", "value": 0}, {"description": "Force on", "value": 1}, {"description": "Auto-detected", "value": 2}]}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "If enabled, forward incoming MAVLink messages to other MAVLink ports if the\nmessage is either broadcast or the target is not the autopilot.\n\nThis allows for example a GCS to talk to a camera that is connected to the\nautopilot via MAVLink (on a different link than the GCS).\n\n", "name": "MAV_1_FORWARD", "rebootRequired": true, "shortDesc": "Enable MAVLink Message forwarding for instance 1", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 3, "default": 0.015, "group": "MAVLink", "increment": 0.001, "longDesc": "Positive real value that configures the transmission frequency of the\nHIGH_LATENCY2 stream for instance 1, configured in iridium mode.\nThis parameter has no effect if the instance mode is different from iridium.\n\n", "max": 50.0, "min": 0.0, "name": "MAV_1_HL_FREQ", "rebootRequired": true, "shortDesc": "Configures the frequency of HIGH_LATENCY2 stream for instance 1", "type": "Float", "units": "Hz"}, {"category": "Standard", "default": 2, "group": "MAVLink", "longDesc": "The MAVLink Mode defines the set of streamed messages (for example the\nvehicle's attitude) and their sending rates.\n\nUse ADS-B/Traffic for a traffic receiver such as an ADS-B or FLARM\ndevice. With message signing active, unsigned ADSB_VEHICLE and\nCOLLISION messages are only accepted on links in this mode.\n\n", "name": "MAV_1_MODE", "rebootRequired": true, "shortDesc": "MAVLink Mode for instance 1", "type": "Int32", "values": [{"description": "Normal", "value": 0}, {"description": "Custom", "value": 1}, {"description": "Onboard", "value": 2}, {"description": "OSD", "value": 3}, {"description": "Magic", "value": 4}, {"description": "Config", "value": 5}, {"description": "Minimal", "value": 7}, {"description": "External Vision", "value": 8}, {"description": "Gimbal", "value": 10}, {"description": "Onboard Low Bandwidth", "value": 11}, {"description": "ADS-B/Traffic (uAvionix)", "value": 12}, {"description": "Low Bandwidth", "value": 13}]}, {"category": "Standard", "default": 1, "group": "MAVLink", "longDesc": "If enabled, MAVLink messages will be throttled according to\n`txbuf` field reported by radio_status.\n\nRequires a radio to send the mavlink message RADIO_STATUS.\n\n", "name": "MAV_1_RADIO_CTL", "rebootRequired": true, "shortDesc": "Enable software throttling of mavlink on instance 1", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "Configure the maximum sending rate for the MAVLink streams in Bytes/sec.\nIf the configured streams exceed the maximum rate, the sending rate of\neach stream is automatically decreased.\n\nIf this is set to 0 a value of half of the theoretical maximum bandwidth is used.\nThis corresponds to baudrate/20 Bytes/s (baudrate/10 = maximum data rate on\n8N1-configured links). USB and UDP links have no baudrate, so for those 0\nmeans 100000 Bytes/s.\n\nNote that for a telemetry radio the serial baudrate says little about what\nthe link can actually carry over the air. A SiK radio at the common 57600\nbaud, 64 kbps air rate carries roughly 2000 B/s with error correction\nenabled and about twice that without, where baudrate/20 would suggest 2880.\nInstance 0 therefore defaults to a fixed value that is safe either way\nrather than to 0. Raise it if you know your link is better.\n\n", "min": 0, "name": "MAV_1_RATE", "rebootRequired": true, "shortDesc": "Maximum MAVLink sending rate for instance 1", "type": "Int32", "units": "B/s"}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "Messages go to this address at port MAV_1_REMOTE_PRT. Encoded as int32\nwith the first octet in the most significant byte, e.g. 192.168.1.2 is -1062731518.\nSet to 0 to discover the partner from received packets.\n\n", "name": "MAV_1_REMOTE_IP", "rebootRequired": true, "shortDesc": "MAVLink Partner IP for instance 1", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "If ethernet enabled and selected as configuration for MAVLink instance 1,\nselected remote port will be set and used in MAVLink instance 1.\n\n", "name": "MAV_1_REMOTE_PRT", "rebootRequired": true, "shortDesc": "MAVLink Remote Port for instance 1", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "If ethernet enabled and selected as configuration for MAVLink instance 1,\nselected udp port will be set and used in MAVLink instance 1.\n\n", "name": "MAV_1_UDP_PRT", "rebootRequired": true, "shortDesc": "MAVLink Network Port for instance 1", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "This allows a ground control station to automatically find the drone\non the local network.\n\n", "name": "MAV_2_BROADCAST", "shortDesc": "Broadcast heartbeats on local network for MAVLink instance 2", "type": "Int32", "values": [{"description": "Never broadcast", "value": 0}, {"description": "Always broadcast", "value": 1}, {"description": "Only multicast", "value": 2}]}, {"category": "Standard", "default": 2, "group": "MAVLink", "longDesc": "This is used to force flow control on or off for the the mavlink\ninstance. By default it is auto detected. Use when auto detection fails.\n\n", "name": "MAV_2_FLOW_CTRL", "rebootRequired": true, "shortDesc": "Enable serial flow control for instance 2", "type": "Int32", "values": [{"description": "Force off", "value": 0}, {"description": "Force on", "value": 1}, {"description": "Auto-detected", "value": 2}]}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "If enabled, forward incoming MAVLink messages to other MAVLink ports if the\nmessage is either broadcast or the target is not the autopilot.\n\nThis allows for example a GCS to talk to a camera that is connected to the\nautopilot via MAVLink (on a different link than the GCS).\n\n", "name": "MAV_2_FORWARD", "rebootRequired": true, "shortDesc": "Enable MAVLink Message forwarding for instance 2", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 3, "default": 0.015, "group": "MAVLink", "increment": 0.001, "longDesc": "Positive real value that configures the transmission frequency of the\nHIGH_LATENCY2 stream for instance 2, configured in iridium mode.\nThis parameter has no effect if the instance mode is different from iridium.\n\n", "max": 50.0, "min": 0.0, "name": "MAV_2_HL_FREQ", "rebootRequired": true, "shortDesc": "Configures the frequency of HIGH_LATENCY2 stream for instance 2", "type": "Float", "units": "Hz"}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "The MAVLink Mode defines the set of streamed messages (for example the\nvehicle's attitude) and their sending rates.\n\nUse ADS-B/Traffic for a traffic receiver such as an ADS-B or FLARM\ndevice. With message signing active, unsigned ADSB_VEHICLE and\nCOLLISION messages are only accepted on links in this mode.\n\n", "name": "MAV_2_MODE", "rebootRequired": true, "shortDesc": "MAVLink Mode for instance 2", "type": "Int32", "values": [{"description": "Normal", "value": 0}, {"description": "Custom", "value": 1}, {"description": "Onboard", "value": 2}, {"description": "OSD", "value": 3}, {"description": "Magic", "value": 4}, {"description": "Config", "value": 5}, {"description": "Minimal", "value": 7}, {"description": "External Vision", "value": 8}, {"description": "Gimbal", "value": 10}, {"description": "Onboard Low Bandwidth", "value": 11}, {"description": "ADS-B/Traffic (uAvionix)", "value": 12}, {"description": "Low Bandwidth", "value": 13}]}, {"category": "Standard", "default": 1, "group": "MAVLink", "longDesc": "If enabled, MAVLink messages will be throttled according to\n`txbuf` field reported by radio_status.\n\nRequires a radio to send the mavlink message RADIO_STATUS.\n\n", "name": "MAV_2_RADIO_CTL", "rebootRequired": true, "shortDesc": "Enable software throttling of mavlink on instance 2", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "Configure the maximum sending rate for the MAVLink streams in Bytes/sec.\nIf the configured streams exceed the maximum rate, the sending rate of\neach stream is automatically decreased.\n\nIf this is set to 0 a value of half of the theoretical maximum bandwidth is used.\nThis corresponds to baudrate/20 Bytes/s (baudrate/10 = maximum data rate on\n8N1-configured links). USB and UDP links have no baudrate, so for those 0\nmeans 100000 Bytes/s.\n\nNote that for a telemetry radio the serial baudrate says little about what\nthe link can actually carry over the air. A SiK radio at the common 57600\nbaud, 64 kbps air rate carries roughly 2000 B/s with error correction\nenabled and about twice that without, where baudrate/20 would suggest 2880.\nInstance 0 therefore defaults to a fixed value that is safe either way\nrather than to 0. Raise it if you know your link is better.\n\n", "min": 0, "name": "MAV_2_RATE", "rebootRequired": true, "shortDesc": "Maximum MAVLink sending rate for instance 2", "type": "Int32", "units": "B/s"}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "Messages go to this address at port MAV_2_REMOTE_PRT. Encoded as int32\nwith the first octet in the most significant byte, e.g. 192.168.1.2 is -1062731518.\nSet to 0 to discover the partner from received packets.\n\n", "name": "MAV_2_REMOTE_IP", "rebootRequired": true, "shortDesc": "MAVLink Partner IP for instance 2", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "If ethernet enabled and selected as configuration for MAVLink instance 2,\nselected remote port will be set and used in MAVLink instance 2.\n\n", "name": "MAV_2_REMOTE_PRT", "rebootRequired": true, "shortDesc": "MAVLink Remote Port for instance 2", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "If ethernet enabled and selected as configuration for MAVLink instance 2,\nselected udp port will be set and used in MAVLink instance 2.\n\n", "name": "MAV_2_UDP_PRT", "rebootRequired": true, "shortDesc": "MAVLink Network Port for instance 2", "type": "Int32"}, {"category": "Standard", "default": 1, "group": "MAVLink", "max": 250, "min": 1, "name": "MAV_COMP_ID", "rebootRequired": true, "shortDesc": "MAVLink component ID", "type": "Int32"}, {"category": "Standard", "default": 1, "group": "MAVLink", "longDesc": "If set to 1 incoming external setpoint messages will be directly forwarded\nto the controllers if in offboard control mode\n", "name": "MAV_FWDEXTSP", "shortDesc": "Forward external setpoint messages", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 1, "group": "MAVLink", "longDesc": "Disabling the parameter hash check functionality will make the mavlink instance\nstream parameters continuously.\n", "name": "MAV_HASH_CHK_EN", "shortDesc": "Parameter hash check", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 1, "group": "MAVLink", "longDesc": "The mavlink heartbeat message will not be forwarded if this parameter is set to 'disabled'.\nThe main reason for disabling heartbeats to be forwarded is because they confuse dronekit.\n", "name": "MAV_HB_FORW_EN", "shortDesc": "Heartbeat message forwarding", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 2, "group": "MAVLink", "name": "MAV_PROTO_VER", "shortDesc": "MAVLink protocol version", "type": "Int32", "values": [{"description": "Version 1 with auto-upgrade to v2 if detected", "value": 1}, {"description": "Version 2", "value": 2}]}, {"category": "Standard", "default": 5, "group": "MAVLink", "longDesc": "If the connected radio stops reporting RADIO_STATUS for a certain time,\na warning is triggered and, if MAV_X_RADIO_CTL is enabled, the software-flow\ncontrol is reset.\n", "max": 250, "min": 1, "name": "MAV_RADIO_TOUT", "shortDesc": "Timeout in seconds for the RADIO_STATUS reports coming in", "type": "Int32", "units": "s"}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "When non-zero the MAVLink app will attempt to configure the\nSiK radio to this ID and re-set the parameter to 0. If the value\nis negative it will reset the complete radio config to\nfactory defaults. Only applies if this mavlink instance is going through a SiK radio\n", "max": 240, "min": -1, "name": "MAV_SIK_RADIO_ID", "shortDesc": "MAVLink SiK Radio ID", "type": "Int32"}, {"category": "Standard", "default": 1, "group": "MAVLink", "longDesc": "IDs above 255 use the 32-bit system ID extension of MAVLink 2,\nwhich forces MAV_PROTO_VER to 2. Every system on the network needs\nto support the extension to talk to such a system.\n\nOnly use IDs above 255 for vehicles, and keep ground stations and\nother controlling systems at 255 or below. The gimbal protocol and\nother messages that carry a system ID inside the payload, such as\nthe ID of the system in control, still only support IDs up to 255.\n", "max": 2147483647, "min": 1, "name": "MAV_SYS_ID", "rebootRequired": true, "shortDesc": "MAVLink system ID", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "TELEM2 on Skynode only.\n\n", "name": "MAV_S_FORWARD", "rebootRequired": true, "shortDesc": "Enable MAVLink forwarding on TELEM2", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 11, "group": "MAVLink", "longDesc": "The MAVLink Mode defines the set of streamed messages (for example the\nvehicle's attitude) and their sending rates.\n\n", "name": "MAV_S_MODE", "rebootRequired": true, "shortDesc": "MAVLink Mode for SOM to FMU communication channel", "type": "Int32", "values": [{"description": "Normal", "value": 0}, {"description": "Onboard", "value": 2}, {"description": "Config", "value": 5}, {"description": "Minimal", "value": 7}, {"description": "Onboard Low Bandwidth", "value": 11}, {"description": "Low Bandwidth", "value": 13}]}, {"category": "Standard", "default": 0, "group": "MAVLink", "max": 23, "min": 0, "name": "MAV_TYPE", "shortDesc": "MAVLink airframe type", "type": "Int32", "values": [{"description": "Generic micro air vehicle", "value": 0}, {"description": "Fixed wing aircraft", "value": 1}, {"description": "Quadrotor", "value": 2}, {"description": "Coaxial helicopter", "value": 3}, {"description": "Normal helicopter with tail rotor", "value": 4}, {"description": "Airship, controlled", "value": 7}, {"description": "Free balloon, uncontrolled", "value": 8}, {"description": "Ground rover", "value": 10}, {"description": "Surface vessel, boat, ship", "value": 11}, {"description": "Submarine", "value": 12}, {"description": "Hexarotor", "value": 13}, {"description": "Octorotor", "value": 14}, {"description": "Tricopter", "value": 15}, {"description": "VTOL Two-rotor Tailsitter", "value": 19}, {"description": "VTOL Quad-rotor Tailsitter", "value": 20}, {"description": "VTOL Tiltrotor", "value": 21}, {"description": "VTOL Standard (separate fixed rotors for hover and cruise flight)", "value": 22}, {"description": "VTOL Tailsitter", "value": 23}]}, {"category": "Standard", "default": 0, "group": "MAVLink", "longDesc": "If set to 1 incoming HIL GPS messages are parsed.\n", "name": "MAV_USEHILGPS", "shortDesc": "Use/Accept HIL GPS message even if not in HIL mode", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Magnetometer Bias Estimator", "longDesc": "This enables continuous calibration of the magnetometers\nbefore takeoff using gyro data.\n", "name": "MBE_ENABLE", "rebootRequired": true, "shortDesc": "Enable online mag bias calibration", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 18.0, "group": "Magnetometer Bias Estimator", "increment": 0.1, "longDesc": "Increase to make the estimator more responsive\nDecrease to make the estimator more robust to noise\n", "max": 100.0, "min": 0.1, "name": "MBE_LEARN_GAIN", "shortDesc": "Mag bias estimator learning gain", "type": "Float"}, {"category": "Standard", "default": 1, "group": "Manual Control", "longDesc": "This determines if moving the left stick to the lower right\narms and to the lower left disarms the vehicle.\n", "name": "MAN_ARM_GESTURE", "shortDesc": "Enable arm/disarm stick gesture", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "Manual Control", "increment": 0.01, "longDesc": "Range around stick center ignored to prevent\nvehicle drift from stick hardware inaccuracy.\n\nDoes not apply to any precise constant input like\nthrottle and attitude or rate piloting.\n", "max": 1.0, "min": 0.0, "name": "MAN_DEADZONE", "shortDesc": "Deadzone for sticks (only specific use cases)", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Manual Control", "longDesc": "The timeout for holding the left stick to the lower left\nand the right stick to the lower right at the same time until the gesture\nkills the actuators one-way.\n\nA negative value disables the feature.\n", "max": 15.0, "min": -1.0, "name": "MAN_KILL_GEST_T", "shortDesc": "Trigger time for kill stick gesture", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.0, "group": "Manual Control", "increment": 0.5, "longDesc": "Stick velocity above which the pilot regains control by switching to Position mode (or Altitude if position is unavailable). Unit: normalized stick travel per second \u2014 at 1.0, moving a stick half its range in ~0.5s triggers it. A negative value disables the feature. Only applies to multicopters and VTOLs in MC mode.\n", "max": 10.0, "min": -1.0, "name": "MAN_OVERRIDE_SPD", "shortDesc": "Manual control override speed threshold", "type": "Float", "units": "1/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "Mission", "longDesc": "Ensure:\ngripper: NAV_CMD_DO_GRIPPER\nhas released before continuing mission.\nwinch: CMD_DO_WINCH\nhas delivered before continuing mission.\ngimbal: CMD_DO_GIMBAL_MANAGER_PITCHYAW\nhas reached the commanded orientation before beginning to take pictures.\n", "min": 0.0, "name": "MIS_COMMAND_TOUT", "shortDesc": "Timeout to allow the payload to execute the mission command", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 10000.0, "group": "Mission", "increment": 100.0, "longDesc": "There will be a warning message if the current waypoint is more distant than MIS_DIST_1WP from Home.\nHas no effect on mission validity.\nSet a value of zero or less to disable.\n", "max": 100000.0, "min": -1.0, "name": "MIS_DIST_1WP", "shortDesc": "Maximal horizontal distance from Home to first waypoint", "type": "Float", "units": "m"}, {"category": "Standard", "default": 30, "group": "Mission", "longDesc": "Minimum altitude above landing point that the vehicle will climb to after an aborted landing.\nThen vehicle will loiter in this altitude until further command is received.\nUsed as the default when the landing mission item does not specify its own abort altitude\n(MAV_CMD_NAV_LAND param1).\nOnly applies to fixed-wing vehicles.\n", "min": 0, "name": "MIS_LND_ABRT_ALT", "shortDesc": "Landing abort min altitude", "type": "Int32", "units": "m"}, {"category": "Standard", "default": 0, "group": "Mission", "longDesc": "Enable yaw control of the mount. (Only affects multicopters with an active ROI)\n\nIf enabled, yaw commands will be sent to the mount and the vehicle will follow its heading towards the flight direction.\nIf disabled, the vehicle will yaw towards the ROI in Mission and Hold mode.\n", "max": 1, "min": 0, "name": "MIS_MNT_YAW_CTL", "shortDesc": "Enable gimbal yaw control in missions and Hold", "type": "Int32", "values": [{"description": "Disable", "value": 0}, {"description": "Enable", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 2.5, "group": "Mission", "increment": 0.5, "longDesc": "This is the relative altitude the system will take off to\nif not otherwise specified.\n", "min": 0.0, "name": "MIS_TAKEOFF_ALT", "shortDesc": "Default take-off altitude", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Mission", "longDesc": "Specifies if a mission has to contain a takeoff and/or mission landing.\nValidity of configured takeoffs/landings is checked independently of the setting here.\n", "name": "MIS_TKO_LAND_REQ", "shortDesc": "Mission takeoff/landing required", "type": "Int32", "values": [{"description": "No requirements", "value": 0}, {"description": "Require a takeoff", "value": 1}, {"description": "Require a landing", "value": 2}, {"description": "Require a takeoff and a landing", "value": 3}, {"description": "Require both a takeoff and a landing, or neither", "value": 4}, {"description": "Same as previous when landed, in-air require landing only if no valid VTOL approach is present", "value": 5}]}, {"category": "Standard", "default": 0, "group": "Mission", "longDesc": "Keep the vehicle over the landing target during vertical takeoffs (multicopter and VTOL in hover),\nusing the landing target estimate. Requires the vision target estimator with bit 2 of\nVTE_TASK_MASK set. Without a valid target estimate the takeoff is unchanged.\n", "name": "MIS_TKO_PREC", "shortDesc": "Precision takeoff", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 2.0, "group": "Mission", "increment": 0.1, "longDesc": "Time after the takeoff ramp is complete before a vertical takeoff setpoint may move\nsideways onto the landing target. Gives the vehicle time to clear the pad. Only used with MIS_TKO_PREC.\n", "max": 10.0, "min": 0.0, "name": "MIS_TKO_PREC_DLY", "shortDesc": "Precision takeoff correction delay", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 12.0, "group": "Mission", "increment": 1.0, "max": 90.0, "min": 0.0, "name": "MIS_YAW_ERR", "shortDesc": "Max yaw error in degrees needed for waypoint heading acceptance", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 1, "default": 10.0, "group": "Mission", "increment": 1.0, "longDesc": "Time from commanding a waypoint heading until a multicopter continues without reaching it,\nto not get stuck with low yaw authority.\n\nA forced heading (e.g. before a VTOL transition) is never skipped: a mission fails instead,\nother modes keep waiting.\nVTOLs only wait for forced headings.\n0: don't wait, -1: wait indefinitely\n", "max": 60.0, "min": -1.0, "name": "MIS_YAW_TMT", "shortDesc": "Waypoint heading timeout", "type": "Float", "units": "s"}, {"category": "Standard", "default": 0, "group": "Mission", "max": 5, "min": 0, "name": "MPC_YAW_MODE", "shortDesc": "Heading behavior in autonomous modes", "type": "Int32", "values": [{"description": "towards waypoint", "value": 0}, {"description": "towards home", "value": 1}, {"description": "away from home", "value": 2}, {"description": "along trajectory", "value": 3}, {"description": "towards waypoint (yaw first)", "value": 4}, {"description": "yaw fixed", "value": 5}]}, {"category": "Standard", "decimalPlaces": 2, "default": 10.0, "group": "Mission", "increment": 0.5, "longDesc": "Overridden by a waypoint's own acceptance radius, if set. For fixed-wing and rovers, the controller's acceptance radius is used instead when it is larger.\n", "max": 200.0, "min": 0.05, "name": "NAV_ACC_RAD", "shortDesc": "Acceptance radius", "type": "Float", "units": "m"}, {"category": "Standard", "default": 1, "group": "Mission", "name": "NAV_FORCE_VT", "shortDesc": "Force VTOL mode takeoff and land", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 5.0, "group": "Mission", "longDesc": "FW acceptance alt for last waypoint before landing. Usually smaller than NAV_FW_ALT_RAD; accuracy matters more near the ground.\n", "max": 200.0, "min": 0.05, "name": "NAV_FW_ALTL_RAD", "shortDesc": "FW Altitude acceptance radius before landing", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 10.0, "group": "Mission", "increment": 0.5, "max": 200.0, "min": 0.05, "name": "NAV_FW_ALT_RAD", "shortDesc": "FW Altitude acceptance radius", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 80.0, "group": "Mission", "increment": 0.5, "longDesc": "Default for fixed-wing loiters, e.g. in Hold mode. Positive values loiter clockwise, negative values counter-clockwise.\n", "max": 10000.0, "min": -10000.0, "name": "NAV_LOITER_RAD", "shortDesc": "FW Loiter radius", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Mission", "longDesc": "If disabled, the vehicle loiters at its current position. Only applies to Hold mode during failsafe actions.\n", "name": "NAV_LTR_LAST_DL", "shortDesc": "Loiter at last GCS heartbeat position on data link loss", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.8, "group": "Mission", "increment": 0.5, "max": 200.0, "min": 0.05, "name": "NAV_MC_ALT_RAD", "shortDesc": "MC Altitude acceptance radius", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": -1.0, "group": "Mission", "increment": 1.0, "longDesc": "Minimum height AGL in Return and Mission (excluding landing commands). Requires a distance sensor. Stops further descent but doesn't force a climb. Set to -1 to disable.\n", "min": -1.0, "name": "NAV_MIN_GND_DIST", "shortDesc": "Minimum height above ground during Mission and Return", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": -1.0, "group": "Mission", "increment": 0.5, "longDesc": "Altitude above Home used when Hold mode is entered without an altitude, e.g. from an RC switch. Doesn't apply to mission loiters or reposition (\"Go to\") setpoints. Set to -1 to disable.\n", "min": -1.0, "name": "NAV_MIN_LTR_ALT", "shortDesc": "Minimum loiter altitude", "type": "Float", "units": "m"}, {"category": "Standard", "default": 1, "group": "Mission", "longDesc": "Changes take effect at the next cross-track conflict level transition.\n", "max": 5, "min": 0, "name": "NAV_TRAFF_AVOID", "shortDesc": "Traffic avoidance action (Xtrack only)", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Warn only", "value": 1}, {"description": "Return mode", "value": 2}, {"description": "Land mode", "value": 3}, {"description": "Position Hold mode", "value": 4}, {"description": "Terminate", "value": 5}]}, {"category": "Standard", "default": 500.0, "group": "Mission", "longDesc": "Maximum absolute distance from the projected traffic track.\n", "min": 500.0, "name": "NAV_TRAFF_A_HOR", "shortDesc": "Crosstrack conflict distance threshold", "type": "Float", "units": "m"}, {"category": "Standard", "default": 500.0, "group": "Mission", "max": 500.0, "min": 10.0, "name": "NAV_TRAFF_A_VER", "shortDesc": "Crosstrack vertical separation threshold", "type": "Float", "units": "m"}, {"category": "Standard", "default": 60, "group": "Mission", "longDesc": "A conflict is raised when the time estimate is below this threshold.\nThe estimate is the current 3D separation divided by the sum of the ownship and traffic speed magnitudes.\n", "max": 900000000, "min": 1, "name": "NAV_TRAFF_COLL_T", "shortDesc": "Crosstrack collision time threshold", "type": "Int32", "units": "s"}, {"category": "Standard", "default": 0, "group": "Mixer Output", "longDesc": "The air-mode enables the mixer to increase the total thrust of the multirotor\nin order to keep attitude and rate control even at low and high throttle.\n\nThis function should be disabled during tuning as it will help the controller\nto diverge if the closed-loop is unstable (i.e. the vehicle is not tuned yet).\n\nEnabling air-mode for yaw requires the use of an arming switch.\n", "name": "MC_AIRMODE", "shortDesc": "Multicopter air-mode", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Roll/Pitch", "value": 1}, {"description": "Roll/Pitch/Yaw", "value": 2}]}, {"category": "Standard", "default": 0, "group": "Motor Failure", "longDesc": "If enabled, the HealthAndArmingChecks compare each motor's ESC current against the expected\ncurrent for the commanded throttle, and flag a motor whose current stays too far from that\nexpectation (too low or too high) for a set time.\nThis check only works for ESCs that report current consumption.\n", "name": "FD_ACT_EN", "shortDesc": "Enable Actuator Failure check", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 35.0, "group": "Motor Failure", "increment": 1.0, "max": 50.0, "min": 0.0, "name": "MOTFAIL_C2T", "shortDesc": "Motor failure model current-vs-command slope", "type": "Float", "units": "A/%"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Motor Failure", "increment": 1.0, "max": 20.0, "min": 0.0, "name": "MOTFAIL_IDLE", "shortDesc": "Motor failure model idle current", "type": "Float", "units": "A"}, {"category": "Standard", "decimalPlaces": 2, "default": 10.0, "group": "Motor Failure", "increment": 1.0, "longDesc": "Set 0 to disable overcurrent detection.\n", "max": 30.0, "min": 0.0, "name": "MOTFAIL_OVER", "shortDesc": "Motor failure overcurrent trip band", "type": "Float", "units": "A"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Motor Failure", "increment": 1.0, "longDesc": "Motor failure only triggers after MOTFAIL_OVER is exceeded for this time.\n", "max": 10.0, "min": 0.01, "name": "MOTFAIL_OVR_TIME", "shortDesc": "Motor failure overcurrent trigger time", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 10.0, "group": "Motor Failure", "increment": 1.0, "longDesc": "Set 0 to disable undercurrent detection.\n", "max": 30.0, "min": 0.0, "name": "MOTFAIL_UNDER", "shortDesc": "Motor failure undercurrent trip band", "type": "Float", "units": "A"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Motor Failure", "increment": 1.0, "longDesc": "Motor failure only triggers after MOTFAIL_UNDER is exceeded for this time.\n", "max": 10.0, "min": 0.0, "name": "MOTFAIL_UND_TIME", "shortDesc": "Motor failure undercurrent trigger time", "type": "Float", "units": "s"}, {"category": "Standard", "default": 0, "group": "Mount", "longDesc": "Set to true for servo gimbal, false for passthrough.\nThis is required for a gimbal which is not capable of stabilizing itself\nand relies on the IMU's attitude estimation.\n", "name": "MNT_DO_STAB", "shortDesc": "Stabilize the mount", "type": "Int32", "values": [{"description": "Disable", "value": 0}, {"description": "Stabilize all axis", "value": 1}, {"description": "Stabilize yaw for absolute/lock mode.", "value": 2}, {"description": "Stabilize pitch for absolute/lock mode.", "value": 3}]}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "Mount", "max": 90.0, "min": -90.0, "name": "MNT_FIXED_PITCH", "shortDesc": "Tracked pitch angle when in fixed mode (MNT_MODE_IN=5)", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 1, "default": 90.0, "group": "Mount", "max": 90.0, "min": -90.0, "name": "MNT_LND_P_MAX", "shortDesc": "Pitch maximum when landed", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 1, "default": -90.0, "group": "Mount", "max": 90.0, "min": -90.0, "name": "MNT_LND_P_MIN", "shortDesc": "Pitch minimum when landed", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 0, "group": "Mount", "max": 6, "min": 0, "name": "MNT_MAN_PITCH", "shortDesc": "Auxiliary channel to control pitch (in AUX input or manual mode)", "type": "Int32", "values": [{"description": "Disable", "value": 0}, {"description": "AUX1", "value": 1}, {"description": "AUX2", "value": 2}, {"description": "AUX3", "value": 3}, {"description": "AUX4", "value": 4}, {"description": "AUX5", "value": 5}, {"description": "AUX6", "value": 6}]}, {"category": "Standard", "default": 0, "group": "Mount", "max": 6, "min": 0, "name": "MNT_MAN_ROLL", "shortDesc": "Auxiliary channel to control roll (in AUX input or manual mode)", "type": "Int32", "values": [{"description": "Disable", "value": 0}, {"description": "AUX1", "value": 1}, {"description": "AUX2", "value": 2}, {"description": "AUX3", "value": 3}, {"description": "AUX4", "value": 4}, {"description": "AUX5", "value": 5}, {"description": "AUX6", "value": 6}]}, {"category": "Standard", "default": 0, "group": "Mount", "max": 6, "min": 0, "name": "MNT_MAN_YAW", "shortDesc": "Auxiliary channel to control yaw (in AUX input or manual mode)", "type": "Int32", "values": [{"description": "Disable", "value": 0}, {"description": "AUX1", "value": 1}, {"description": "AUX2", "value": 2}, {"description": "AUX3", "value": 3}, {"description": "AUX4", "value": 4}, {"description": "AUX5", "value": 5}, {"description": "AUX6", "value": 6}]}, {"category": "Standard", "default": 154, "group": "Mount", "longDesc": "If MNT_MODE_OUT is MAVLink protocol v2, mount configure/control commands will be sent with this component ID.\n", "name": "MNT_MAV_COMPID", "shortDesc": "Mavlink Component ID of the mount", "type": "Int32"}, {"category": "Standard", "default": 1, "group": "Mount", "longDesc": "If MNT_MODE_OUT is MAVLink gimbal protocol v1, mount configure/control commands will be sent with this target ID.\n", "name": "MNT_MAV_SYSID", "shortDesc": "Mavlink System ID of the mount", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 1, "default": 45.0, "group": "Mount", "longDesc": "Use output driver settings to calibrate (e.g. PWM_CENT/_MIN/_MAX).\n", "name": "MNT_MAX_PITCH", "shortDesc": "Max positive angle of pitch setpoint (only in MNT_MODE_OUT=AUX)", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 1, "default": -45.0, "group": "Mount", "longDesc": "Use output driver settings to calibrate (e.g. PWM_CENT/_MIN/_MAX).\n", "name": "MNT_MIN_PITCH", "shortDesc": "Min negative angle of pitch setpoint (only in MNT_MODE_OUT=AUX)", "type": "Float", "units": "deg"}, {"category": "Standard", "default": -1, "group": "Mount", "longDesc": "This is the protocol used between the ground station and the autopilot.\n\nRecommended is Auto, RC only or MAVLink gimbal protocol v2.\nThe rest will be deprecated.\n", "max": 5, "min": -1, "name": "MNT_MODE_IN", "rebootRequired": true, "shortDesc": "Mount input mode", "type": "Int32", "values": [{"description": "DISABLED", "value": -1}, {"description": "Auto (RC and MAVLink gimbal protocol v2)", "value": 0}, {"description": "RC", "value": 1}, {"description": "MAVLINK_ROI (protocol v1, to be deprecated)", "value": 2}, {"description": "MAVLINK_DO_MOUNT (protocol v1, to be deprecated)", "value": 3}, {"description": "MAVlink gimbal protocol v2", "value": 4}, {"description": "Fixed world-frame attitude, not user controllable", "value": 5}]}, {"category": "Standard", "default": 0, "group": "Mount", "longDesc": "This is the protocol used between the autopilot and a connected gimbal.\n\nRecommended is the MAVLink gimbal protocol v2 if the gimbal supports it.\n\nIn AUX mode, the gimbal (and hence the gimbal manager) is only made\navailable if at least one output channel is assigned a gimbal\nroll/pitch/yaw output function (checked once at startup, so newly\nassigned output functions require a reboot).\n", "max": 3, "min": 0, "name": "MNT_MODE_OUT", "rebootRequired": true, "shortDesc": "Mount output mode", "type": "Int32", "values": [{"description": "AUX", "value": 0}, {"description": "MAVLink gimbal protocol v1", "value": 1}, {"description": "MAVLink gimbal protocol v2", "value": 2}, {"description": "Forward to external gimbal manager", "value": 3}]}, {"category": "Standard", "default": -1, "group": "Mount", "longDesc": "Optional second output, driven in parallel to MNT_MODE_OUT with the\nsame setpoints. This allows the gimbal driver to talk to a second\ngimbal in addition to the primary one.\n\nSet to Disabled if not used. The two outputs must use different modes.\n", "max": 3, "min": -1, "name": "MNT_MODE_OUT2", "rebootRequired": true, "shortDesc": "Second mount output mode", "type": "Int32", "values": [{"description": "Disabled", "value": -1}, {"description": "AUX", "value": 0}, {"description": "MAVLink gimbal protocol v1", "value": 1}, {"description": "MAVLink gimbal protocol v2", "value": 2}, {"description": "Forward to external gimbal manager", "value": 3}]}, {"category": "Standard", "decimalPlaces": 1, "default": 90.0, "group": "Mount", "longDesc": "Use output driver settings to calibrate (e.g. PWM_CENT/_MIN/_MAX). Note that only symmetric angular ranges are supported.\n", "max": 720.0, "min": 1.0, "name": "MNT_RANGE_ROLL", "shortDesc": "Range of roll channel output (only in MNT_MODE_OUT=AUX)", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 1, "default": 360.0, "group": "Mount", "longDesc": "Use output driver settings to calibrate (e.g. PWM_CENT/_MIN/_MAX). Note that only symmetric angular ranges are supported.\n", "max": 720.0, "min": 1.0, "name": "MNT_RANGE_YAW", "shortDesc": "Range of yaw channel output (only in MNT_MODE_OUT=AUX)", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 30.0, "group": "Mount", "longDesc": "Full stick input [-1..1] translats to [-pitch rate..pitch rate].\n", "max": 90.0, "min": 1.0, "name": "MNT_RATE_PITCH", "shortDesc": "Angular pitch rate for manual input in degrees/second", "type": "Float", "units": "deg/s"}, {"category": "Standard", "default": 30.0, "group": "Mount", "longDesc": "Full stick input [-1..1] translats to [-yaw rate..yaw rate].\n", "max": 90.0, "min": 1.0, "name": "MNT_RATE_YAW", "shortDesc": "Angular yaw rate for manual input in degrees/second", "type": "Float", "units": "deg/s"}, {"category": "Standard", "default": 1, "group": "Mount", "max": 1, "min": 0, "name": "MNT_RC_IN_MODE", "shortDesc": "Input mode for RC gimbal input", "type": "Int32", "values": [{"description": "Angle", "value": 0}, {"description": "Angular rate", "value": 1}]}, {"category": "Standard", "default": 0.3, "group": "Mount", "longDesc": "Alpha filter time constant defining the convergence rate for open-loop AUX mount control\n\nUse when no angular position feedback is available.\nWith MNT_MODE_OUT set to AUX, the mount operates in open-loop and directly commands the servo output.\nParameters must be tuned for the specific servo to approximate its speed and response.\n", "min": 0.0, "name": "MNT_TAU", "shortDesc": "Time constant for open-loop AUX gimbal control", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Multicopter Acro Mode", "longDesc": "Exponential factor for tuning the input curve shape.\n\n0 Purely linear input curve\n1 Purely cubic input curve\n", "max": 1.0, "min": 0.0, "name": "MC_ACRO_EXPO", "shortDesc": "Acro mode roll, pitch expo factor", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Multicopter Acro Mode", "longDesc": "Exponential factor for tuning the input curve shape.\n\n0 Purely linear input curve\n1 Purely cubic input curve\n", "max": 1.0, "min": 0.0, "name": "MC_ACRO_EXPO_Y", "shortDesc": "Acro mode yaw expo factor", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 100.0, "group": "Multicopter Acro Mode", "increment": 5.0, "longDesc": "Full stick deflection leads to this rate.\n", "max": 1800.0, "min": 0.0, "name": "MC_ACRO_P_MAX", "shortDesc": "Acro mode maximum pitch rate", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 100.0, "group": "Multicopter Acro Mode", "increment": 5.0, "longDesc": "Full stick deflection leads to this rate.\n", "max": 1800.0, "min": 0.0, "name": "MC_ACRO_R_MAX", "shortDesc": "Acro mode maximum roll rate", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Multicopter Acro Mode", "longDesc": "\"Superexponential\" factor for refining the input curve shape tuned using MC_ACRO_EXPO.\n\n0 Pure Expo function\n0.7 reasonable shape enhancement for intuitive stick feel\n0.95 very strong bent input curve only near maxima have effect\n", "max": 0.95, "min": 0.0, "name": "MC_ACRO_SUPEXPO", "shortDesc": "Acro mode roll, pitch super expo factor", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Multicopter Acro Mode", "longDesc": "\"Superexponential\" factor for refining the input curve shape tuned using MC_ACRO_EXPO_Y.\n\n0 Pure Expo function\n0.7 reasonable shape enhancement for intuitive stick feel\n0.95 very strong bent input curve only near maxima have effect\n", "max": 0.95, "min": 0.0, "name": "MC_ACRO_SUPEXPOY", "shortDesc": "Acro mode yaw super expo factor", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 100.0, "group": "Multicopter Acro Mode", "increment": 5.0, "longDesc": "Full stick deflection leads to this rate.\n", "max": 1800.0, "min": 0.0, "name": "MC_ACRO_Y_MAX", "shortDesc": "Acro mode maximum yaw rate", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 220.0, "group": "Multicopter Attitude Control", "increment": 5.0, "longDesc": "Limit for pitch rate in manual and auto modes (except acro).\nHas effect for large rotations in autonomous mode, to avoid large control\noutput and mixer saturation.\n\nThis is not only limited by the vehicle's properties, but also by the maximum\nmeasurement rate of the gyro.\n", "max": 1800.0, "min": 0.0, "name": "MC_PITCHRATE_MAX", "shortDesc": "Max pitch rate", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 4.0, "group": "Multicopter Attitude Control", "increment": 0.1, "longDesc": "Pitch proportional gain, i.e. desired angular speed in rad/s for error 1 rad.\n", "max": 12.0, "min": 0.0, "name": "MC_PITCH_P", "shortDesc": "Pitch P gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Multicopter Attitude Control", "increment": 0.01, "longDesc": "Scale on the reference-model rate feed-forward. 0 disables it.\n", "max": 1.0, "min": 0.0, "name": "MC_REF_FF", "shortDesc": "Attitude reference-model feed-forward gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 0, "default": 100.0, "group": "Multicopter Attitude Control", "increment": 5.0, "longDesc": "Per-axis cap on the rate feed-forward.\n", "max": 1800.0, "min": 0.0, "name": "MC_REF_FF_MAX", "shortDesc": "Feed-forward angular-rate cap; 0 = disabled", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 0, "default": 50.0, "group": "Multicopter Attitude Control", "increment": 1.0, "longDesc": "Bandwidth of the reference model that smooths the attitude setpoint\nand generates the rate feed-forward. Higher = less lag, more peak\nrate demand.\n", "max": 200.0, "min": 1.0, "name": "MC_REF_W_N", "shortDesc": "Attitude reference-model natural frequency", "type": "Float", "units": "rad/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 220.0, "group": "Multicopter Attitude Control", "increment": 5.0, "longDesc": "Limit for roll rate in manual and auto modes (except acro).\nHas effect for large rotations in autonomous mode, to avoid large control\noutput and mixer saturation.\n\nThis is not only limited by the vehicle's properties, but also by the maximum\nmeasurement rate of the gyro.\n", "max": 1800.0, "min": 0.0, "name": "MC_ROLLRATE_MAX", "shortDesc": "Max roll rate", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 4.0, "group": "Multicopter Attitude Control", "increment": 0.1, "longDesc": "Roll proportional gain, i.e. desired angular speed in rad/s for error 1 rad.\n", "max": 12.0, "min": 0.0, "name": "MC_ROLL_P", "shortDesc": "Roll P gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 200.0, "group": "Multicopter Attitude Control", "increment": 5.0, "max": 1800.0, "min": 0.0, "name": "MC_YAWRATE_MAX", "shortDesc": "Max yaw rate", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 2.8, "group": "Multicopter Attitude Control", "increment": 0.1, "longDesc": "Yaw proportional gain, i.e. desired angular speed in rad/s for error 1 rad.\n", "max": 5.0, "min": 0.0, "name": "MC_YAW_P", "shortDesc": "Yaw P gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.4, "group": "Multicopter Attitude Control", "increment": 0.1, "longDesc": "A fraction [0,1] deprioritizing yaw compared to roll and pitch in non-linear attitude control.\nDeprioritizing yaw is necessary because multicopters have much less control authority\nin yaw compared to the other axes and it makes sense because yaw is not critical for\nstable hovering or 3D navigation.\n\nFor yaw control tuning use MC_YAW_P. This ratio has no impact on the yaw gain.\n", "max": 1.0, "min": 0.0, "name": "MC_YAW_WEIGHT", "shortDesc": "Yaw weight", "type": "Float"}, {"category": "Standard", "decimalPlaces": 0, "default": 20.0, "group": "Multicopter Attitude Control", "increment": 5.0, "longDesc": "Limits the acceleration of the yaw setpoint to avoid large\ncontrol output and mixer saturation.\n", "max": 360.0, "min": 5.0, "name": "MPC_YAWRAUTO_ACC", "shortDesc": "Maximum yaw acceleration in autonomous modes", "type": "Float", "units": "deg/s^2"}, {"category": "Standard", "decimalPlaces": 0, "default": 60.0, "group": "Multicopter Attitude Control", "increment": 5.0, "longDesc": "Limits the rate of change of the yaw setpoint to avoid large\ncontrol output and mixer saturation.\n", "max": 360.0, "min": 5.0, "name": "MPC_YAWRAUTO_MAX", "shortDesc": "Maximum yaw rate in autonomous modes", "type": "Float", "units": "deg/s"}, {"category": "Standard", "default": 0.4, "group": "Multicopter Position Control", "longDesc": "Average delay of the range sensor message plus the tracking delay of the position controller in seconds\n\nOnly used in Position mode.\n", "max": 1.0, "min": 0.0, "name": "CP_DELAY", "shortDesc": "Range sensor and position controller average delay", "type": "Float", "units": "s"}, {"category": "Standard", "default": -1.0, "group": "Multicopter Position Control", "longDesc": "Only used in Position mode. Collision avoidance is disabled by setting this parameter to a negative value\n", "max": 15.0, "min": -1.0, "name": "CP_DIST", "shortDesc": "Minimum distance the vehicle should keep to all obstacles", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Multicopter Position Control", "longDesc": "Boolean to allow moving into directions where there is no sensor data (outside FOV)\n\nOnly used in Position mode.\n", "name": "CP_GO_NO_DATA", "shortDesc": "Allow moving into directions without sensor data", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 30.0, "group": "Multicopter Position Control", "longDesc": "Angle left/right from the commanded setpoint by which the collision prevention algorithm can choose to change the setpoint direction\n\nOnly used in Position mode.\n", "max": 90.0, "min": 0.0, "name": "CP_GUIDE_ANG", "shortDesc": "Collision prevention guidance angle", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Multicopter Position Control", "longDesc": "Setting this parameter to 0 disables the filter\n", "max": 2.0, "min": 0.0, "name": "MC_MAN_TILT_TAU", "shortDesc": "Manual tilt input filter time constant", "type": "Float", "units": "s"}, {"category": "Standard", "default": 1, "group": "Multicopter Position Control", "longDesc": "Set to decouple tilt from vertical acceleration.\nThis provides smoother flight but slightly worse tracking in position and auto modes.\nUnset if accurate position tracking during dynamic maneuvers is more important than a smooth flight.\n", "name": "MPC_ACC_DECOUPLE", "shortDesc": "Acceleration to tilt coupling", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "Multicopter Position Control", "increment": 1.0, "max": 15.0, "min": 2.0, "name": "MPC_ACC_DOWN_MAX", "shortDesc": "Maximum downwards acceleration in climb rate controlled modes", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "Multicopter Position Control", "increment": 1.0, "longDesc": "When piloting manually, this parameter is only used in MPC_POS_MODE Acceleration based.\n", "max": 15.0, "min": 2.0, "name": "MPC_ACC_HOR", "shortDesc": "Acceleration for autonomous and for manual modes", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "decimalPlaces": 2, "default": 5.0, "group": "Multicopter Position Control", "increment": 1.0, "longDesc": "With MPC_POS_MODE=0 it limits deceleration.\nWith MPC_POS_MODE=4 it is unused (see MPC_ACC_HOR).\n", "max": 15.0, "min": 2.0, "name": "MPC_ACC_HOR_MAX", "shortDesc": "Maximum horizontal acceleration", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "decimalPlaces": 1, "default": 4.0, "group": "Multicopter Position Control", "increment": 1.0, "max": 15.0, "min": 2.0, "name": "MPC_ACC_UP_MAX", "shortDesc": "Maximum upwards acceleration in climb rate controlled modes", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "default": 2, "group": "Multicopter Position Control", "longDesc": "Control height\n0: relative earth frame origin which may drift due to sensors\n1: relative to ground (requires distance sensor) which changes with terrain variation.\nIt will revert to relative earth frame if the distance to ground estimate becomes invalid.\n2: relative to ground (requires distance sensor) when stationary\nand relative to earth frame when moving horizontally.\nThe speed threshold is MPC_HOLD_MAX_XY\n", "max": 2, "min": 0, "name": "MPC_ALT_MODE", "shortDesc": "Altitude reference mode", "type": "Int32", "values": [{"description": "Altitude following", "value": 0}, {"description": "Terrain following", "value": 1}, {"description": "Terrain hold", "value": 2}]}, {"bitmask": [{"description": "Yaw nudging", "index": 0}, {"description": "Landing nudging", "index": 1}], "category": "Standard", "default": 0, "group": "Multicopter Position Control", "longDesc": "Bitmask to enable pilot override of heading and position during auto modes.\n\nBit 0 - Yaw nudging: yaw stick rotates the heading in all auto types\n(takeoff, mission, Return, hold, landing). The new heading is held until a\nmode switch resets it.\n\nBit 1 - Land nudging: during autonomous landing the pitch/roll sticks move\nthe vehicle horizontally, the throttle stick amends the descent speed\n(stick full up: 0, centered: MPC_LAND_SPEED, full down: 2 * MPC_LAND_SPEED),\nand the yaw stick rotates the heading.\n\nStick override must be disabled (set MAN_OVERRIDE_SPD = -1).\n", "max": 3, "min": 0, "name": "MPC_AUTO_NUDGING", "shortDesc": "Enable stick nudging in autonomous modes", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.8, "group": "Multicopter Position Control", "longDesc": "Maximum horizontal velocity for which position hold is enabled (use 0 to disable check)\n\nOnly used with MPC_POS_MODE Direct velocity or MPC_ALT_MODE 2\n", "max": 3.0, "min": 0.0, "name": "MPC_HOLD_MAX_XY", "shortDesc": "Max horizontal velocity for position hold", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.6, "group": "Multicopter Position Control", "longDesc": "Maximum vertical velocity for which position hold is enabled (use 0 to disable check)\n\nOnly used with MPC_ALT_MODE 1\n", "max": 3.0, "min": 0.0, "name": "MPC_HOLD_MAX_Z", "shortDesc": "Max vertical velocity for position hold", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 4.0, "group": "Multicopter Position Control", "increment": 1.0, "longDesc": "Limit the maximum jerk of the vehicle (how fast the acceleration can change).\nA lower value leads to smoother vehicle motions but also limited agility.\n", "max": 80.0, "min": 1.0, "name": "MPC_JERK_AUTO", "shortDesc": "Jerk limit in autonomous modes", "type": "Float", "units": "m/s^3"}, {"category": "Standard", "decimalPlaces": 1, "default": 8.0, "group": "Multicopter Position Control", "increment": 1.0, "longDesc": "Limit the maximum jerk (acceleration change) of the vehicle.\nA lower value leads to smoother motions but limits agility.\n\nSetting this to the maximum value essentially disables the limit.\n\nOnly used with MPC_POS_MODE Acceleration based.\n", "max": 500.0, "min": 0.5, "name": "MPC_JERK_MAX", "shortDesc": "Maximum horizontal and vertical jerk in Position/Altitude mode", "type": "Float", "units": "m/s^3"}, {"category": "Standard", "decimalPlaces": 1, "default": 10.0, "group": "Multicopter Position Control", "longDesc": "Below this altitude descending velocity gets limited to a value\nbetween \"MPC_Z_VEL_MAX_DN\" (or \"MPC_Z_V_AUTO_DN\") and \"MPC_LAND_SPEED\"\nValue needs to be higher than \"MPC_LAND_ALT2\"\n", "max": 122.0, "min": 0.0, "name": "MPC_LAND_ALT1", "shortDesc": "Altitude for 1. step of slow landing (descend)", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "Multicopter Position Control", "longDesc": "Below this altitude descending velocity gets\nlimited to \"MPC_LAND_SPEED\"\nValue needs to be lower than \"MPC_LAND_ALT1\"\n", "max": 122.0, "min": 0.0, "name": "MPC_LAND_ALT2", "shortDesc": "Altitude for 2. step of slow landing (landing)", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.0, "group": "Multicopter Position Control", "longDesc": "If a valid distance sensor measurement to the ground is available,\nlimit descending velocity to \"MPC_LAND_CRWL\" below this altitude.\n", "max": 122.0, "min": 0.0, "name": "MPC_LAND_ALT3", "shortDesc": "Altitude for 3. step of slow landing", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.3, "group": "Multicopter Position Control", "longDesc": "Used below MPC_LAND_ALT3 if distance sensor data is availabe.\n", "min": 0.1, "name": "MPC_LAND_CRWL", "shortDesc": "Land crawl descend rate", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 0, "default": -1.0, "group": "Multicopter Position Control", "increment": 1.0, "longDesc": "When landing nudging is enabled (MPC_AUTO_NUDGING bit 1), this defines the maximum\nallowed horizontal displacement from the original landing point.\n- If inside of the radius, only allow nudging inputs that do not move the vehicle outside of it.\n- If outside of the radius, only allow nudging inputs that move the vehicle back towards it.\n\nSet it to -1 for infinite radius.\n", "min": -1.0, "name": "MPC_LAND_RADIUS", "shortDesc": "User assisted landing radius", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.7, "group": "Multicopter Position Control", "min": 0.6, "name": "MPC_LAND_SPEED", "shortDesc": "Landing descend rate", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.08, "group": "Multicopter Position Control", "increment": 0.01, "longDesc": "The value is mapped to the lowest throttle stick position in Stabilized mode.\n\nToo low collective thrust leads to loss of roll/pitch/yaw torque control authority.\nAirmode is used to keep torque authority with zero thrust (see MC_AIRMODE).\n", "max": 0.5, "min": 0.0, "name": "MPC_MANTHR_MIN", "shortDesc": "Minimum collective thrust in Stabilized mode", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 0, "default": 35.0, "group": "Multicopter Position Control", "increment": 1.0, "max": 70.0, "min": 1.0, "name": "MPC_MAN_TILT_MAX", "shortDesc": "Maximal tilt angle in Stabilized, Altitude and Altitude Cruise mode", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 0, "default": 150.0, "group": "Multicopter Position Control", "increment": 10.0, "max": 400.0, "min": 0.0, "name": "MPC_MAN_Y_MAX", "shortDesc": "Max manual yaw rate for Stabilized, Altitude, Position mode", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.08, "group": "Multicopter Position Control", "increment": 0.01, "longDesc": "Not used in Stabilized mode\nSetting this parameter to 0 disables the filter\n", "max": 5.0, "min": 0.0, "name": "MPC_MAN_Y_TAU", "shortDesc": "Manual yaw rate input filter time constant", "type": "Float", "units": "s"}, {"category": "Standard", "default": 4, "group": "Multicopter Position Control", "longDesc": "The supported sub-modes are:\nDirect velocity:\nSticks directly map to velocity setpoints without smoothing.\nAlso applies to vertical direction and Altitude mode.\nUseful for velocity control tuning.\nAcceleration based:\nSticks map to acceleration and there's a virtual brake drag\n", "name": "MPC_POS_MODE", "shortDesc": "Position/Altitude mode variant", "type": "Int32", "values": [{"description": "Direct velocity", "value": 0}, {"description": "Acceleration based", "value": 4}]}, {"category": "Standard", "default": 0, "group": "Multicopter Position Control", "longDesc": "Rescale to estimate: stick is rescaled linearly so center stick gives the hover thrust estimate.\nNo rescale: stick maps 1:1 to thrust; useful with very low hover thrust, where rescaling distorts the curve and makes the upper half sensitive.\nRescale to parameter: as Rescale to estimate, but uses MPC_THR_HOVER; with MPC_THR_HOVER 0.5 same as No rescale.\n", "name": "MPC_THR_CURVE", "shortDesc": "Thrust curve mapping in Stabilized Mode", "type": "Int32", "values": [{"description": "Rescale to estimate", "value": 0}, {"description": "No rescale", "value": 1}, {"description": "Rescale to parameter", "value": 2}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.5, "group": "Multicopter Position Control", "increment": 0.01, "longDesc": "Mapped to center throttle stick in Stabilized mode (see MPC_THR_CURVE).\nUsed for initialization of the hover thrust estimator.\nThe estimated hover thrust is used as base for zero vertical acceleration in altitude control.\nThe hover thrust is important for land detection to work correctly.\n", "max": 0.9, "min": 0.1, "name": "MPC_THR_HOVER", "shortDesc": "Vertical thrust required to hover", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Multicopter Position Control", "increment": 0.05, "longDesc": "Limit allowed thrust e.g. for indoor test of overpowered vehicle.\n", "max": 1.0, "min": 0.0, "name": "MPC_THR_MAX", "shortDesc": "Maximum collective thrust in climb rate controlled modes", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.12, "group": "Multicopter Position Control", "increment": 0.01, "longDesc": "Too low thrust leads to loss of roll/pitch/yaw torque control authority.\nWith airmode enabled this parameters can be set to 0\nwhile still keeping torque authority (see MC_AIRMODE).\n", "max": 0.5, "min": 0.05, "name": "MPC_THR_MIN", "shortDesc": "Minimum collective thrust in climb rate controlled modes", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "Multicopter Position Control", "increment": 0.01, "longDesc": "Margin that is kept for horizontal control when higher priority vertical thrust is saturated.\nTo avoid completely starving horizontal control with high vertical error.\n", "max": 0.5, "min": 0.0, "name": "MPC_THR_XY_MARG", "shortDesc": "Horizontal thrust margin", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 0, "default": 45.0, "group": "Multicopter Position Control", "increment": 1.0, "longDesc": "Absolute maximum for all velocity or acceleration controlled modes.\nAny higher value is truncated.\n", "max": 89.0, "min": 20.0, "name": "MPC_TILTMAX_AIR", "shortDesc": "Maximum tilt angle in air", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 0, "default": 12.0, "group": "Multicopter Position Control", "increment": 1.0, "longDesc": "Tighter tilt limit during takeoff to avoid tip over.\n", "max": 89.0, "min": 5.0, "name": "MPC_TILTMAX_LND", "shortDesc": "Maximum tilt during initial takeoff ramp", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 3.0, "group": "Multicopter Position Control", "longDesc": "Increasing this value will make climb rate controlled takeoff slower.\nIf it's too slow the drone might scratch the ground and tip over.\nA time constant of 0 disables the ramp\n", "max": 5.0, "min": 0.0, "name": "MPC_TKO_RAMP_T", "shortDesc": "Smooth takeoff ramp time constant", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.5, "group": "Multicopter Position Control", "max": 5.0, "min": 1.0, "name": "MPC_TKO_SPEED", "shortDesc": "Takeoff climb rate", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "Multicopter Position Control", "increment": 0.5, "longDesc": "A value of 0 disables the filter.\n", "max": 50.0, "min": 0.0, "name": "MPC_VELD_LP", "shortDesc": "Velocity derivative low pass cutoff frequency", "type": "Float", "units": "Hz"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "Multicopter Position Control", "increment": 0.5, "longDesc": "A value of 0 disables the filter.\n", "max": 50.0, "min": 0.0, "name": "MPC_VEL_LP", "shortDesc": "Velocity low pass cutoff frequency", "type": "Float", "units": "Hz"}, {"category": "Standard", "decimalPlaces": 1, "default": 10.0, "group": "Multicopter Position Control", "increment": 1.0, "longDesc": "Must be smaller than MPC_XY_VEL_MAX.\n\nThe maximum sideways and backward speed can be set differently\nusing MPC_VEL_MAN_SIDE and MPC_VEL_MAN_BACK, respectively.\n", "max": 20.0, "min": 3.0, "name": "MPC_VEL_MANUAL", "shortDesc": "Maximum horizontal velocity setpoint in Position mode", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": -1.0, "group": "Multicopter Position Control", "increment": 1.0, "longDesc": "If set to a negative value or larger than\nMPC_VEL_MANUAL then MPC_VEL_MANUAL is used.\n", "max": 20.0, "min": -1.0, "name": "MPC_VEL_MAN_BACK", "shortDesc": "Maximum backward velocity in Position mode", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": -1.0, "group": "Multicopter Position Control", "increment": 1.0, "longDesc": "If set to a negative value or larger than\nMPC_VEL_MANUAL then MPC_VEL_MANUAL is used.\n", "max": 20.0, "min": -1.0, "name": "MPC_VEL_MAN_SIDE", "shortDesc": "Maximum sideways velocity in Position mode", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "Multicopter Position Control", "increment": 0.5, "longDesc": "A value of 0 disables the filter.\n", "max": 50.0, "min": 0.0, "name": "MPC_VEL_NF_BW", "shortDesc": "Velocity notch filter bandwidth", "type": "Float", "units": "Hz"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "Multicopter Position Control", "increment": 0.5, "longDesc": "The center frequency for the 2nd order notch filter on the velocity.\nA value of 0 disables the filter.\n", "max": 50.0, "min": 0.0, "name": "MPC_VEL_NF_FRQ", "shortDesc": "Velocity notch filter frequency", "type": "Float", "units": "Hz"}, {"category": "Standard", "decimalPlaces": 0, "default": 5.0, "group": "Multicopter Position Control", "increment": 1.0, "longDesc": "e.g. in Missions, Return, Goto if the waypoint does not specify differently\n", "max": 20.0, "min": 3.0, "name": "MPC_XY_CRUISE", "shortDesc": "Default horizontal velocity in autonomous modes", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 2.0, "group": "Multicopter Position Control", "increment": 1.0, "longDesc": "The integration speed of the trajectory setpoint is linearly\nreduced with the horizontal position tracking error. When the\nerror is above this parameter, the integration of the\ntrajectory is stopped to wait for the drone.\n\nThis value can be adjusted depending on the tracking\ncapabilities of the vehicle. Set to 0 to disable the horizontal\ntime-stretch.\n", "max": 10.0, "min": 0.0, "name": "MPC_XY_ERR_MAX", "shortDesc": "Maximum horizontal error allowed by the trajectory generator", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.95, "group": "Multicopter Position Control", "increment": 0.1, "longDesc": "Defined as corrective velocity in m/s per m position error\n", "max": 2.0, "min": 0.0, "name": "MPC_XY_P", "shortDesc": "Proportional gain for horizontal position error", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.5, "group": "Multicopter Position Control", "increment": 0.1, "max": 1.0, "min": 0.1, "name": "MPC_XY_TRAJ_P", "shortDesc": "Proportional gain for horizontal trajectory position error", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": -10.0, "group": "Multicopter Position Control", "increment": 1.0, "longDesc": "If set to a value greater than zero, other parameters are automatically set (such as\nMPC_XY_VEL_MAX or MPC_VEL_MANUAL).\nIf set to a negative value, the existing individual parameters are used.\n", "max": 20.0, "min": -20.0, "name": "MPC_XY_VEL_ALL", "shortDesc": "Overall Horizontal Velocity Limit", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.2, "group": "Multicopter Position Control", "increment": 0.02, "longDesc": "Defined as corrective acceleration in m/s^2 per m/s^2 velocity derivative\n", "max": 2.0, "min": 0.1, "name": "MPC_XY_VEL_D_ACC", "shortDesc": "Differential gain for horizontal velocity error", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.4, "group": "Multicopter Position Control", "increment": 0.02, "longDesc": "Defined as correction acceleration in m/s^2 per m velocity integral\nAllows to eliminate steady state errors in disturbances like wind.\n", "max": 60.0, "min": 0.0, "name": "MPC_XY_VEL_I_ACC", "shortDesc": "Integral gain for horizontal velocity error", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 12.0, "group": "Multicopter Position Control", "increment": 1.0, "longDesc": "Absolute maximum for all velocity controlled modes.\nAny higher value is truncated.\n", "max": 20.0, "min": 0.0, "name": "MPC_XY_VEL_MAX", "shortDesc": "Maximum horizontal velocity", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.8, "group": "Multicopter Position Control", "increment": 0.1, "longDesc": "Defined as corrective acceleration in m/s^2 per m/s velocity error\n", "max": 5.0, "min": 1.2, "name": "MPC_XY_VEL_P_ACC", "shortDesc": "Proportional gain for horizontal velocity error", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.0, "group": "Multicopter Position Control", "increment": 0.1, "longDesc": "Vertical analog of MPC_XY_ERR_MAX. When the smoothed trajectory z\nleads the drone by more than this value, trajectory integration is\nslowed down so the virtual setpoint can't walk away from the drone.\nThis suppresses altitude overshoots caused by a noisy altitude\nreference (e.g. mission setpoint jittering as the home altitude\nestimate is refined in flight). Set to 0 to disable the vertical\ntime-stretch.\n", "max": 10.0, "min": 0.0, "name": "MPC_Z_ERR_MAX", "shortDesc": "Maximum vertical error allowed by the trajectory generator", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Multicopter Position Control", "increment": 0.1, "longDesc": "Defined as corrective velocity in m/s per m position error\n", "max": 1.5, "min": 0.1, "name": "MPC_Z_P", "shortDesc": "Proportional gain for vertical position error", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": -3.0, "group": "Multicopter Position Control", "increment": 0.5, "longDesc": "If set to a value greater than zero, other parameters are automatically set (such as\nMPC_Z_VEL_MAX_UP or MPC_LAND_SPEED).\nIf set to a negative value, the existing individual parameters are used.\n", "max": 8.0, "min": -3.0, "name": "MPC_Z_VEL_ALL", "shortDesc": "Overall Vertical Velocity Limit", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Multicopter Position Control", "increment": 0.02, "longDesc": "Defined as corrective acceleration in m/s^2 per m/s^2 velocity derivative\n", "max": 2.0, "min": 0.0, "name": "MPC_Z_VEL_D_ACC", "shortDesc": "Differential gain for vertical velocity error", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 2.0, "group": "Multicopter Position Control", "increment": 0.1, "longDesc": "Defined as corrective acceleration in m/s^2 per m velocity integral\n", "max": 3.0, "min": 0.2, "name": "MPC_Z_VEL_I_ACC", "shortDesc": "Integral gain for vertical velocity error", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.5, "group": "Multicopter Position Control", "increment": 0.1, "longDesc": "Absolute maximum for all climb rate controlled modes.\nIn manually piloted modes full stick deflection commands this velocity.\n\nFor default autonomous velocity see MPC_Z_V_AUTO_UP\n", "max": 4.0, "min": 0.5, "name": "MPC_Z_VEL_MAX_DN", "shortDesc": "Maximum descent velocity", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "Multicopter Position Control", "increment": 0.1, "longDesc": "Absolute maximum for all climb rate controlled modes.\nIn manually piloted modes full stick deflection commands this velocity.\n\nFor default autonomous velocity see MPC_Z_V_AUTO_UP\n", "max": 8.0, "min": 0.5, "name": "MPC_Z_VEL_MAX_UP", "shortDesc": "Maximum ascent velocity", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 4.0, "group": "Multicopter Position Control", "increment": 0.1, "longDesc": "Defined as corrective acceleration in m/s^2 per m/s velocity error\n", "max": 15.0, "min": 2.0, "name": "MPC_Z_VEL_P_ACC", "shortDesc": "Proportional gain for vertical velocity error", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.5, "group": "Multicopter Position Control", "increment": 0.5, "longDesc": "For manual modes and offboard, see MPC_Z_VEL_MAX_DN\n", "max": 4.0, "min": 0.5, "name": "MPC_Z_V_AUTO_DN", "shortDesc": "Descent velocity in autonomous modes", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "Multicopter Position Control", "increment": 0.5, "longDesc": "For manually controlled modes and offboard see MPC_Z_VEL_MAX_UP\n", "max": 8.0, "min": 0.5, "name": "MPC_Z_V_AUTO_UP", "shortDesc": "Ascent velocity in autonomous modes", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": -0.4, "group": "Multicopter Position Control", "increment": 0.05, "longDesc": "Changes the overall responsiveness of the vehicle.\nThe higher the value, the faster the vehicle will react.\n\nIf set to a value greater than zero, other parameters are automatically set (such as\nthe acceleration or jerk limits).\nIf set to a negative value, the existing individual parameters are used.\n", "max": 1.0, "min": -1.0, "name": "SYS_VEHICLE_RESP", "shortDesc": "Responsiveness", "type": "Float"}, {"category": "Standard", "default": 0, "group": "Multicopter Position Control", "name": "WV_EN", "shortDesc": "Enable weathervane", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 1.0, "group": "Multicopter Position Control", "longDesc": "Minimum roll angle setpoint for weathervane controller to demand a yaw-rate\n", "max": 5.0, "min": 0.0, "name": "WV_ROLL_MIN", "shortDesc": "Minimum roll angle for weathervane yaw-rate demand", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 90.0, "group": "Multicopter Position Control", "max": 120.0, "min": 0.0, "name": "WV_YRATE_MAX", "shortDesc": "Maximum yawrate the weathervane controller is allowed to demand", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 3.0, "group": "Multicopter Position Slow Mode", "increment": 0.1, "longDesc": "This value is used in slow mode if\nno aux channel is mapped and\nno limit is commanded through MAVLink.\n", "min": 0.1, "name": "MC_SLOW_DEF_HVEL", "shortDesc": "Default horizontal velocity limit", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Multicopter Position Slow Mode", "increment": 0.1, "longDesc": "This value is used in slow mode if\nno aux channel is mapped and\nno limit is commanded through MAVLink.\n", "min": 0.1, "name": "MC_SLOW_DEF_VVEL", "shortDesc": "Default vertical velocity limit", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 45.0, "group": "Multicopter Position Slow Mode", "increment": 0.1, "longDesc": "This value is used in slow mode if\nno aux channel is mapped and\nno limit is commanded through MAVLink.\n", "min": 1.0, "name": "MC_SLOW_DEF_YAWR", "shortDesc": "Default yaw rate limit", "type": "Float", "units": "deg/s"}, {"category": "Standard", "default": 0, "group": "Multicopter Position Slow Mode", "name": "MC_SLOW_MAP_HVEL", "shortDesc": "Manual input mapped to scale horizontal velocity in position slow mode", "type": "Int32", "values": [{"description": "No rescaling", "value": 0}, {"description": "AUX1", "value": 1}, {"description": "AUX2", "value": 2}, {"description": "AUX3", "value": 3}, {"description": "AUX4", "value": 4}, {"description": "AUX5", "value": 5}, {"description": "AUX6", "value": 6}]}, {"category": "Standard", "default": 0, "group": "Multicopter Position Slow Mode", "longDesc": "RC_MAP_AUX{N} to allow for gimbal pitch rate control in position slow mode\n", "name": "MC_SLOW_MAP_PTCH", "shortDesc": "Gimbal pitch rate control input in position slow mode", "type": "Int32", "values": [{"description": "No pitch rate input", "value": 0}, {"description": "AUX1", "value": 1}, {"description": "AUX2", "value": 2}, {"description": "AUX3", "value": 3}, {"description": "AUX4", "value": 4}, {"description": "AUX5", "value": 5}, {"description": "AUX6", "value": 6}]}, {"category": "Standard", "default": 0, "group": "Multicopter Position Slow Mode", "name": "MC_SLOW_MAP_VVEL", "shortDesc": "Manual input mapped to scale vertical velocity in position slow mode", "type": "Int32", "values": [{"description": "No rescaling", "value": 0}, {"description": "AUX1", "value": 1}, {"description": "AUX2", "value": 2}, {"description": "AUX3", "value": 3}, {"description": "AUX4", "value": 4}, {"description": "AUX5", "value": 5}, {"description": "AUX6", "value": 6}]}, {"category": "Standard", "default": 0, "group": "Multicopter Position Slow Mode", "name": "MC_SLOW_MAP_YAWR", "shortDesc": "Manual input mapped to scale yaw rate in position slow mode", "type": "Int32", "values": [{"description": "No rescaling", "value": 0}, {"description": "AUX1", "value": 1}, {"description": "AUX2", "value": 2}, {"description": "AUX3", "value": 3}, {"description": "AUX4", "value": 4}, {"description": "AUX5", "value": 5}, {"description": "AUX6", "value": 6}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "Multicopter Position Slow Mode", "increment": 0.1, "longDesc": "The lowest input maps and is clamped to this velocity.\n", "min": 0.1, "name": "MC_SLOW_MIN_HVEL", "shortDesc": "Horizontal velocity lower limit", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "Multicopter Position Slow Mode", "increment": 0.1, "longDesc": "The lowest input maps and is clamped to this velocity.\n", "min": 0.1, "name": "MC_SLOW_MIN_VVEL", "shortDesc": "Vertical velocity lower limit", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "Multicopter Position Slow Mode", "increment": 0.1, "longDesc": "The lowest input maps and is clamped to this rate.\n", "min": 1.0, "name": "MC_SLOW_MIN_YAWR", "shortDesc": "Yaw rate lower limit", "type": "Float", "units": "deg/s"}, {"category": "Standard", "default": 0, "group": "Multicopter Rate Control", "longDesc": "This compensates for voltage drop of the battery over time by attempting to\nnormalize performance across the operating range of the battery. The copter\nshould constantly behave as if it was fully charged with reduced max acceleration\nat lower battery percentages. i.e. if hover is at 0.5 throttle at 100% battery,\nit will still be 0.5 at 60% battery.\n", "name": "MC_BAT_SCALE_EN", "shortDesc": "Battery power level scaler", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Multicopter Rate Control", "longDesc": "Dynamically reduces the rate controller output gain when an oscillation\n(limit cycle) is detected on the torque setpoint, e.g. caused by too high gains.\nThe gain recovers to 1.0 once the oscillation stops.\n\n", "name": "MC_GC_EN", "shortDesc": "Enable rate gain compression", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "Multicopter Rate Control", "increment": 0.01, "longDesc": "The range of the compression gain is between this parameter and 1.0\n", "max": 1.0, "min": 0.0, "name": "MC_GC_GAIN_MIN", "shortDesc": "Compression gain lower limit", "type": "Float"}, {"category": "Standard", "decimalPlaces": 4, "default": 0.003, "group": "Multicopter Rate Control", "increment": 0.0005, "longDesc": "Pitch rate differential gain. Small values help reduce fast oscillations. If value is too big oscillations will appear again.\n", "min": 0.0, "name": "MC_PITCHRATE_D", "shortDesc": "Pitch rate D gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 4, "default": 0.0, "group": "Multicopter Rate Control", "longDesc": "Improves tracking performance.\n", "min": 0.0, "name": "MC_PITCHRATE_FF", "shortDesc": "Pitch rate feedforward", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.2, "group": "Multicopter Rate Control", "increment": 0.01, "longDesc": "Pitch rate integral gain. Can be set to compensate static thrust difference or gravity center offset.\n", "min": 0.0, "name": "MC_PITCHRATE_I", "shortDesc": "Pitch rate I gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 4, "default": 1.0, "group": "Multicopter Rate Control", "increment": 0.0005, "longDesc": "Global gain of the controller.\n\nThis gain scales the P, I and D terms of the controller:\n```\noutput = MC_PITCHRATE_K * (MC_PITCHRATE_P * error\n+ MC_PITCHRATE_I * error_integral\n+ MC_PITCHRATE_D * error_derivative)\n```\nSet MC_PITCHRATE_P=1 to implement a PID in the ideal form.\nSet MC_PITCHRATE_K=1 to implement a PID in the parallel form.\n", "max": 5.0, "min": 0.01, "name": "MC_PITCHRATE_K", "shortDesc": "Pitch rate controller gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.15, "group": "Multicopter Rate Control", "increment": 0.01, "longDesc": "Pitch rate proportional gain, i.e. control output for angular speed error 1 rad/s.\n", "max": 0.6, "min": 0.01, "name": "MC_PITCHRATE_P", "shortDesc": "Pitch rate P gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "Multicopter Rate Control", "increment": 0.01, "longDesc": "Pitch rate integrator limit. Can be set to increase the amount of integrator available to counteract disturbances or reduced to improve settling time after large pitch moment trim changes.\n", "min": 0.0, "name": "MC_PR_INT_LIM", "shortDesc": "Pitch rate integrator limit", "type": "Float"}, {"category": "Standard", "decimalPlaces": 4, "default": 0.003, "group": "Multicopter Rate Control", "increment": 0.0005, "longDesc": "Roll rate differential gain. Small values help reduce fast oscillations. If value is too big oscillations will appear again.\n", "max": 0.01, "min": 0.0, "name": "MC_ROLLRATE_D", "shortDesc": "Roll rate D gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 4, "default": 0.0, "group": "Multicopter Rate Control", "longDesc": "Improves tracking performance.\n", "min": 0.0, "name": "MC_ROLLRATE_FF", "shortDesc": "Roll rate feedforward", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.2, "group": "Multicopter Rate Control", "increment": 0.01, "longDesc": "Roll rate integral gain. Can be set to compensate static thrust difference or gravity center offset.\n", "min": 0.0, "name": "MC_ROLLRATE_I", "shortDesc": "Roll rate I gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 4, "default": 1.0, "group": "Multicopter Rate Control", "increment": 0.0005, "longDesc": "Global gain of the controller.\n\nThis gain scales the P, I and D terms of the controller:\n```\noutput = MC_ROLLRATE_K * (MC_ROLLRATE_P * error\n+ MC_ROLLRATE_I * error_integral\n+ MC_ROLLRATE_D * error_derivative)\n```\nSet MC_ROLLRATE_P=1 to implement a PID in the ideal form.\nSet MC_ROLLRATE_K=1 to implement a PID in the parallel form.\n", "max": 5.0, "min": 0.01, "name": "MC_ROLLRATE_K", "shortDesc": "Roll rate controller gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.15, "group": "Multicopter Rate Control", "increment": 0.01, "longDesc": "Roll rate proportional gain, i.e. control output for angular speed error 1 rad/s.\n", "max": 0.5, "min": 0.01, "name": "MC_ROLLRATE_P", "shortDesc": "Roll rate P gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "Multicopter Rate Control", "increment": 0.01, "longDesc": "Roll rate integrator limit. Can be set to increase the amount of integrator available to counteract disturbances or reduced to improve settling time after large roll moment trim changes.\n", "min": 0.0, "name": "MC_RR_INT_LIM", "shortDesc": "Roll rate integrator limit", "type": "Float"}, {"category": "Standard", "decimalPlaces": 4, "default": 0.0, "group": "Multicopter Rate Control", "increment": 0.0005, "longDesc": "Yaw rate differential gain. Small values help reduce fast oscillations. If value is too big oscillations will appear again.\n", "min": 0.0, "name": "MC_YAWRATE_D", "shortDesc": "Yaw rate D gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 4, "default": 0.0, "group": "Multicopter Rate Control", "longDesc": "Improves tracking performance.\n", "min": 0.0, "name": "MC_YAWRATE_FF", "shortDesc": "Yaw rate feedforward", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.1, "group": "Multicopter Rate Control", "increment": 0.01, "longDesc": "Yaw rate integral gain. Can be set to compensate static thrust difference or gravity center offset.\n", "min": 0.0, "name": "MC_YAWRATE_I", "shortDesc": "Yaw rate I gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 4, "default": 1.0, "group": "Multicopter Rate Control", "increment": 0.0005, "longDesc": "Global gain of the controller.\n\nThis gain scales the P, I and D terms of the controller:\n```\noutput = MC_YAWRATE_K * (MC_YAWRATE_P * error\n+ MC_YAWRATE_I * error_integral\n+ MC_YAWRATE_D * error_derivative)\n```\nSet MC_YAWRATE_P=1 to implement a PID in the ideal form.\nSet MC_YAWRATE_K=1 to implement a PID in the parallel form.\n", "max": 5.0, "min": 0.01, "name": "MC_YAWRATE_K", "shortDesc": "Yaw rate controller gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.2, "group": "Multicopter Rate Control", "increment": 0.01, "longDesc": "Yaw rate proportional gain, i.e. control output for angular speed error 1 rad/s.\n", "max": 0.6, "min": 0.0, "name": "MC_YAWRATE_P", "shortDesc": "Yaw rate P gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 2.0, "group": "Multicopter Rate Control", "longDesc": "Reduces vibrations by lowering high frequency torque caused by rotor acceleration.\n0 disables the filter\n", "max": 10.0, "min": 0.0, "name": "MC_YAW_TQ_CUTOFF", "shortDesc": "Low pass filter cutoff frequency for yaw torque setpoint", "type": "Float", "units": "Hz"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "Multicopter Rate Control", "increment": 0.01, "longDesc": "Yaw rate integrator limit. Can be set to increase the amount of integrator available to counteract disturbances or reduced to improve settling time after large yaw moment trim changes.\n", "min": 0.0, "name": "MC_YR_INT_LIM", "shortDesc": "Yaw rate integrator limit", "type": "Float"}, {"category": "Standard", "default": 0, "group": "OSD", "longDesc": "Controls the horizontal position of the crosshair display.\nResolution is limited by OSD to 15 discrete values. Negative\nvalues will display the crosshairs left of the center of the screen\n\n", "max": 8, "min": -8, "name": "OSD_CH_POS_HOR", "shortDesc": "OSD Crosshairs Horizontal Position", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "OSD", "longDesc": "Controls the vertical position of the crosshair display.\nResolution is limited by OSD to 15 discrete values. Negative\nvalues will display the crosshairs below the horizon\n\n", "max": 8, "min": -8, "name": "OSD_CH_POS_VER", "shortDesc": "OSD Crosshairs Vertical Position", "type": "Int32"}, {"category": "Standard", "default": 500, "group": "OSD", "longDesc": "Amount of time to dwell at the beginning of the display, when scrolling.\n\n", "max": 10000, "min": 100, "name": "OSD_DWELL_TIME", "shortDesc": "OSD Dwell Time", "type": "Int32", "units": "ms"}, {"category": "Standard", "default": 3, "group": "OSD", "longDesc": "Minimum security of log level to display on the OSD.\n\n", "name": "OSD_LOG_LEVEL", "shortDesc": "OSD Warning Level", "type": "Int32"}, {"category": "Standard", "default": 1, "group": "OSD", "longDesc": "Forward RC stick input to VTX when disarmed\n\n", "max": 1, "min": 0, "name": "OSD_RC_STICK", "shortDesc": "OSD RC Stick commands", "type": "Int32"}, {"category": "Standard", "default": 125, "group": "OSD", "longDesc": "Scroll rate for OSD messages longer than available character width.\nThis is lower-bounded by the nominal loop rate of this module.\n\n", "max": 1000, "min": 100, "name": "OSD_SCROLL_RATE", "shortDesc": "OSD Scroll Rate", "type": "Int32", "units": "ms"}, {"bitmask": [{"description": "CRAFT_NAME", "index": 0}, {"description": "DISARMED", "index": 1}, {"description": "GPS_LAT", "index": 2}, {"description": "GPS_LON", "index": 3}, {"description": "GPS_SATS", "index": 4}, {"description": "GPS_SPEED", "index": 5}, {"description": "HOME_DIST", "index": 6}, {"description": "(unused) HOME_DIR", "index": 7}, {"description": "(unused) MAIN_BATT_VOLTAGE", "index": 8}, {"description": "CURRENT_DRAW", "index": 9}, {"description": "MAH_DRAWN", "index": 10}, {"description": "RSSI_VALUE", "index": 11}, {"description": "ALTITUDE", "index": 12}, {"description": "(unused) NUMERICAL_VARIO", "index": 13}, {"description": "(unused) FLYMODE", "index": 14}, {"description": "(unused) ESC_TMP", "index": 15}, {"description": "PITCH_ANGLE", "index": 16}, {"description": "ROLL_ANGLE", "index": 17}, {"description": "CROSSHAIRS", "index": 18}, {"description": "AVG_CELL_VOLTAGE", "index": 19}, {"description": "(unused) HORIZON_SIDEBARS", "index": 20}, {"description": "(unused) POWER", "index": 21}], "category": "Standard", "default": 16383, "group": "OSD", "longDesc": "Configure / toggle support display options.\n\n", "max": 4194303, "min": 0, "name": "OSD_SYMBOLS", "shortDesc": "OSD Symbol Selection", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "PWM Outputs", "increment": 0.1, "longDesc": "Parameter used to model the nonlinear relationship between\nmotor control signal (e.g. PWM) and static thrust.\n\nThe model is:\n\n```\nrel_thrust = factor * rel_signal^2 + (1-factor) * rel_signal\n```\n, where rel_thrust is the normalized thrust between 0 and 1, and\nrel_signal is the relative motor control signal between 0 and 1.\n", "max": 1.0, "min": 0.0, "name": "THR_MDL_FAC", "shortDesc": "Thrust to motor control signal model parameter", "type": "Float"}, {"category": "Standard", "default": 1.0, "group": "Payload Deliverer", "longDesc": "Maximum time Gripper will wait while the successful griper actuation isn't recognised.\nIf the gripper has no feedback sensor, it will simply wait for\nthis time before considering gripper actuation successful and publish a\n'VehicleCommandAck' signaling successful gripper action\n\n", "min": 0.0, "name": "PD_GRIPPER_TO", "shortDesc": "Timeout for successful gripper actuation acknowledgement", "type": "Float", "units": "s"}, {"category": "Standard", "default": 0, "group": "Payload Deliverer", "longDesc": "Selects the types of control actions the gripper accepts.\n\n", "max": 0, "min": -1, "name": "PD_GRIPPER_TYPE", "shortDesc": "Gripper control type", "type": "Int32", "values": [{"description": "Undefined", "value": -1}, {"description": "Binary Grab/Release", "value": 0}]}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "Precision Land", "increment": 0.5, "longDesc": "Time after which the landing target is considered lost without any new measurements.\n", "max": 50.0, "min": 0.0, "name": "PLD_BTOUT", "shortDesc": "Landing Target Timeout", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "Precision Land", "increment": 0.1, "longDesc": "Allow final approach (without horizontal positioning) if losing landing target closer than this to the ground.\n", "max": 10.0, "min": 0.0, "name": "PLD_FAPPR_ALT", "shortDesc": "Final approach altitude", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.2, "group": "Precision Land", "increment": 0.1, "longDesc": "Start descending if closer above landing target than this.\n", "max": 10.0, "min": 0.0, "name": "PLD_HACC_RAD", "shortDesc": "Horizontal acceptance radius", "type": "Float", "units": "m"}, {"category": "Standard", "default": 3, "group": "Precision Land", "longDesc": "Maximum number of times to search for the landing target if it is lost during the precision landing.\n", "max": 100, "min": 0, "name": "PLD_MAX_SRCH", "shortDesc": "Maximum number of search attempts", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 2, "default": 3.0, "group": "Precision Land", "longDesc": "When the landing target is moving, precision land aims at the estimated future\ntarget position after a constrained prediction time. This sets the maximum time.\n", "max": 60.0, "min": 0.1, "name": "PLD_MOVING_T_MAX", "shortDesc": "Maximum moving-target prediction time", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 2.0, "group": "Precision Land", "longDesc": "When the landing target is moving, precision land aims at the estimated future\ntarget position after a constrained prediction time. This sets the minimum time.\n", "max": 30.0, "min": 0.1, "name": "PLD_MOVING_T_MIN", "shortDesc": "Minimum moving-target prediction time", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 10.0, "group": "Precision Land", "increment": 0.1, "longDesc": "Altitude above home to which to climb when searching for the landing target.\n", "max": 100.0, "min": 0.0, "name": "PLD_SRCH_ALT", "shortDesc": "Search altitude", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 10.0, "group": "Precision Land", "increment": 0.1, "longDesc": "Time allowed to search for the landing target before falling back to normal landing.\n", "max": 100.0, "min": 0.0, "name": "PLD_SRCH_TOUT", "shortDesc": "Search timeout", "type": "Float", "units": "s"}, {"category": "Standard", "default": 0, "group": "Precision Land", "longDesc": "Control the orientation when landing. The orientation comes from the topic vte_orientation.\n", "max": 1, "min": 0, "name": "PLD_YAW_EN", "shortDesc": "Set to true to control yaw while landing", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Pure Pursuit", "increment": 0.01, "longDesc": "Lower value -> More aggressive controller (beware overshoot/oscillations)\n", "max": 100.0, "min": 0.1, "name": "PP_LOOKAHD_GAIN", "shortDesc": "Tuning parameter for the pure pursuit controller", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 10.0, "group": "Pure Pursuit", "increment": 0.01, "max": 100.0, "min": 0.1, "name": "PP_LOOKAHD_MAX", "shortDesc": "Maximum lookahead distance for the pure pursuit controller", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Pure Pursuit", "increment": 0.01, "max": 100.0, "min": 0.1, "name": "PP_LOOKAHD_MIN", "shortDesc": "Minimum lookahead distance for the pure pursuit controller", "type": "Float", "units": "m"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC10_MAX", "shortDesc": "RC channel 10 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC10_MIN", "shortDesc": "RC channel 10 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC10_REV", "shortDesc": "RC channel 10 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC10_TRIM", "shortDesc": "RC channel 10 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC11_MAX", "shortDesc": "RC channel 11 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC11_MIN", "shortDesc": "RC channel 11 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC11_REV", "shortDesc": "RC channel 11 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC11_TRIM", "shortDesc": "RC channel 11 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC12_MAX", "shortDesc": "RC channel 12 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC12_MIN", "shortDesc": "RC channel 12 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC12_REV", "shortDesc": "RC channel 12 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC12_TRIM", "shortDesc": "RC channel 12 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC13_MAX", "shortDesc": "RC channel 13 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC13_MIN", "shortDesc": "RC channel 13 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC13_REV", "shortDesc": "RC channel 13 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC13_TRIM", "shortDesc": "RC channel 13 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC14_MAX", "shortDesc": "RC channel 14 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC14_MIN", "shortDesc": "RC channel 14 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC14_REV", "shortDesc": "RC channel 14 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC14_TRIM", "shortDesc": "RC channel 14 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC15_MAX", "shortDesc": "RC channel 15 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC15_MIN", "shortDesc": "RC channel 15 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC15_REV", "shortDesc": "RC channel 15 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC15_TRIM", "shortDesc": "RC channel 15 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC16_MAX", "shortDesc": "RC channel 16 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC16_MIN", "shortDesc": "RC channel 16 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC16_REV", "shortDesc": "RC channel 16 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC16_TRIM", "shortDesc": "RC channel 16 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC17_MAX", "shortDesc": "RC channel 17 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC17_MIN", "shortDesc": "RC channel 17 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC17_REV", "shortDesc": "RC channel 17 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC17_TRIM", "shortDesc": "RC channel 17 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC18_MAX", "shortDesc": "RC channel 18 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC18_MIN", "shortDesc": "RC channel 18 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC18_REV", "shortDesc": "RC channel 18 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC18_TRIM", "shortDesc": "RC channel 18 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for RC channel 1\n", "max": 2200.0, "min": 1500.0, "name": "RC1_MAX", "shortDesc": "RC channel 1 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for RC channel 1\n", "max": 1500.0, "min": 800.0, "name": "RC1_MIN", "shortDesc": "RC channel 1 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC1_REV", "shortDesc": "RC channel 1 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC1_TRIM", "shortDesc": "RC channel 1 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC2_MAX", "shortDesc": "RC channel 2 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC2_MIN", "shortDesc": "RC channel 2 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC2_REV", "shortDesc": "RC channel 2 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC2_TRIM", "shortDesc": "RC channel 2 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC3_MAX", "shortDesc": "RC channel 3 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC3_MIN", "shortDesc": "RC channel 3 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC3_REV", "shortDesc": "RC channel 3 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC3_TRIM", "shortDesc": "RC channel 3 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC4_MAX", "shortDesc": "RC channel 4 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC4_MIN", "shortDesc": "RC channel 4 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC4_REV", "shortDesc": "RC channel 4 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC4_TRIM", "shortDesc": "RC channel 4 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC5_MAX", "shortDesc": "RC channel 5 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC5_MIN", "shortDesc": "RC channel 5 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC5_REV", "shortDesc": "RC channel 5 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC5_TRIM", "shortDesc": "RC channel 5 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC6_MAX", "shortDesc": "RC channel 6 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC6_MIN", "shortDesc": "RC channel 6 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC6_REV", "shortDesc": "RC channel 6 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC6_TRIM", "shortDesc": "RC channel 6 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC7_MAX", "shortDesc": "RC channel 7 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC7_MIN", "shortDesc": "RC channel 7 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC7_REV", "shortDesc": "RC channel 7 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC7_TRIM", "shortDesc": "RC channel 7 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC8_MAX", "shortDesc": "RC channel 8 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC8_MIN", "shortDesc": "RC channel 8 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC8_REV", "shortDesc": "RC channel 8 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC8_TRIM", "shortDesc": "RC channel 8 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 2000.0, "group": "Radio Calibration", "longDesc": "Maximum value for this channel.\n", "max": 2200.0, "min": 1500.0, "name": "RC9_MAX", "shortDesc": "RC channel 9 maximum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1000.0, "group": "Radio Calibration", "longDesc": "Minimum value for this channel.\n", "max": 1500.0, "min": 800.0, "name": "RC9_MIN", "shortDesc": "RC channel 9 minimum", "type": "Float", "units": "us"}, {"category": "Standard", "default": 1, "group": "Radio Calibration", "longDesc": "Set to -1 to reverse channel.\n", "max": 1, "min": -1, "name": "RC9_REV", "shortDesc": "RC channel 9 reverse", "type": "Int32"}, {"category": "Standard", "default": 1500.0, "group": "Radio Calibration", "longDesc": "Mid point value\n", "max": 2200.0, "min": 800.0, "name": "RC9_TRIM", "shortDesc": "RC channel 9 trim", "type": "Float", "units": "us"}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "longDesc": "Number of channels detected during RC calibration. Must be non-zero\nfor RC manual control input to be accepted.\n", "max": 18, "min": 0, "name": "RC_CHAN_CNT", "shortDesc": "Calibrated RC channel count", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "longDesc": "Use RC_MAP_FAILSAFE to specify which channel is used to indicate RC loss via this threshold.\nBy default this is the throttle channel.\n\nSet to a PWM value slightly above the PWM value for the channel (e.g. throttle) in a failsafe event,\nbut below the minimum PWM value for the channel during normal operation.\n\nNote: The default value of 0 disables the feature (it is below the expected range).\n", "max": 2200, "min": 0, "name": "RC_FAILS_THR", "shortDesc": "Failsafe channel PWM threshold", "type": "Int32", "units": "us"}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "max": 18, "min": 0, "name": "RC_MAP_AUX1", "shortDesc": "AUX1 Passthrough RC channel", "type": "Int32", "values": [{"description": "Unassigned", "value": 0}, {"description": "Channel 1", "value": 1}, {"description": "Channel 2", "value": 2}, {"description": "Channel 3", "value": 3}, {"description": "Channel 4", "value": 4}, {"description": "Channel 5", "value": 5}, {"description": "Channel 6", "value": 6}, {"description": "Channel 7", "value": 7}, {"description": "Channel 8", "value": 8}, {"description": "Channel 9", "value": 9}, {"description": "Channel 10", "value": 10}, {"description": "Channel 11", "value": 11}, {"description": "Channel 12", "value": 12}, {"description": "Channel 13", "value": 13}, {"description": "Channel 14", "value": 14}, {"description": "Channel 15", "value": 15}, {"description": "Channel 16", "value": 16}, {"description": "Channel 17", "value": 17}, {"description": "Channel 18", "value": 18}]}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "max": 18, "min": 0, "name": "RC_MAP_AUX2", "shortDesc": "AUX2 Passthrough RC channel", "type": "Int32", "values": [{"description": "Unassigned", "value": 0}, {"description": "Channel 1", "value": 1}, {"description": "Channel 2", "value": 2}, {"description": "Channel 3", "value": 3}, {"description": "Channel 4", "value": 4}, {"description": "Channel 5", "value": 5}, {"description": "Channel 6", "value": 6}, {"description": "Channel 7", "value": 7}, {"description": "Channel 8", "value": 8}, {"description": "Channel 9", "value": 9}, {"description": "Channel 10", "value": 10}, {"description": "Channel 11", "value": 11}, {"description": "Channel 12", "value": 12}, {"description": "Channel 13", "value": 13}, {"description": "Channel 14", "value": 14}, {"description": "Channel 15", "value": 15}, {"description": "Channel 16", "value": 16}, {"description": "Channel 17", "value": 17}, {"description": "Channel 18", "value": 18}]}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "max": 18, "min": 0, "name": "RC_MAP_AUX3", "shortDesc": "AUX3 Passthrough RC channel", "type": "Int32", "values": [{"description": "Unassigned", "value": 0}, {"description": "Channel 1", "value": 1}, {"description": "Channel 2", "value": 2}, {"description": "Channel 3", "value": 3}, {"description": "Channel 4", "value": 4}, {"description": "Channel 5", "value": 5}, {"description": "Channel 6", "value": 6}, {"description": "Channel 7", "value": 7}, {"description": "Channel 8", "value": 8}, {"description": "Channel 9", "value": 9}, {"description": "Channel 10", "value": 10}, {"description": "Channel 11", "value": 11}, {"description": "Channel 12", "value": 12}, {"description": "Channel 13", "value": 13}, {"description": "Channel 14", "value": 14}, {"description": "Channel 15", "value": 15}, {"description": "Channel 16", "value": 16}, {"description": "Channel 17", "value": 17}, {"description": "Channel 18", "value": 18}]}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "max": 18, "min": 0, "name": "RC_MAP_AUX4", "shortDesc": "AUX4 Passthrough RC channel", "type": "Int32", "values": [{"description": "Unassigned", "value": 0}, {"description": "Channel 1", "value": 1}, {"description": "Channel 2", "value": 2}, {"description": "Channel 3", "value": 3}, {"description": "Channel 4", "value": 4}, {"description": "Channel 5", "value": 5}, {"description": "Channel 6", "value": 6}, {"description": "Channel 7", "value": 7}, {"description": "Channel 8", "value": 8}, {"description": "Channel 9", "value": 9}, {"description": "Channel 10", "value": 10}, {"description": "Channel 11", "value": 11}, {"description": "Channel 12", "value": 12}, {"description": "Channel 13", "value": 13}, {"description": "Channel 14", "value": 14}, {"description": "Channel 15", "value": 15}, {"description": "Channel 16", "value": 16}, {"description": "Channel 17", "value": 17}, {"description": "Channel 18", "value": 18}]}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "max": 18, "min": 0, "name": "RC_MAP_AUX5", "shortDesc": "AUX5 Passthrough RC channel", "type": "Int32", "values": [{"description": "Unassigned", "value": 0}, {"description": "Channel 1", "value": 1}, {"description": "Channel 2", "value": 2}, {"description": "Channel 3", "value": 3}, {"description": "Channel 4", "value": 4}, {"description": "Channel 5", "value": 5}, {"description": "Channel 6", "value": 6}, {"description": "Channel 7", "value": 7}, {"description": "Channel 8", "value": 8}, {"description": "Channel 9", "value": 9}, {"description": "Channel 10", "value": 10}, {"description": "Channel 11", "value": 11}, {"description": "Channel 12", "value": 12}, {"description": "Channel 13", "value": 13}, {"description": "Channel 14", "value": 14}, {"description": "Channel 15", "value": 15}, {"description": "Channel 16", "value": 16}, {"description": "Channel 17", "value": 17}, {"description": "Channel 18", "value": 18}]}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "max": 18, "min": 0, "name": "RC_MAP_AUX6", "shortDesc": "AUX6 Passthrough RC channel", "type": "Int32", "values": [{"description": "Unassigned", "value": 0}, {"description": "Channel 1", "value": 1}, {"description": "Channel 2", "value": 2}, {"description": "Channel 3", "value": 3}, {"description": "Channel 4", "value": 4}, {"description": "Channel 5", "value": 5}, {"description": "Channel 6", "value": 6}, {"description": "Channel 7", "value": 7}, {"description": "Channel 8", "value": 8}, {"description": "Channel 9", "value": 9}, {"description": "Channel 10", "value": 10}, {"description": "Channel 11", "value": 11}, {"description": "Channel 12", "value": 12}, {"description": "Channel 13", "value": 13}, {"description": "Channel 14", "value": 14}, {"description": "Channel 15", "value": 15}, {"description": "Channel 16", "value": 16}, {"description": "Channel 17", "value": 17}, {"description": "Channel 18", "value": 18}]}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "max": 18, "min": 0, "name": "RC_MAP_ENG_MOT", "shortDesc": "RC channel to engage the main motor (for helicopters)", "type": "Int32", "values": [{"description": "Unassigned", "value": 0}, {"description": "Channel 1", "value": 1}, {"description": "Channel 2", "value": 2}, {"description": "Channel 3", "value": 3}, {"description": "Channel 4", "value": 4}, {"description": "Channel 5", "value": 5}, {"description": "Channel 6", "value": 6}, {"description": "Channel 7", "value": 7}, {"description": "Channel 8", "value": 8}, {"description": "Channel 9", "value": 9}, {"description": "Channel 10", "value": 10}, {"description": "Channel 11", "value": 11}, {"description": "Channel 12", "value": 12}, {"description": "Channel 13", "value": 13}, {"description": "Channel 14", "value": 14}, {"description": "Channel 15", "value": 15}, {"description": "Channel 16", "value": 16}, {"description": "Channel 17", "value": 17}, {"description": "Channel 18", "value": 18}]}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "longDesc": "Configures which RC channel is used by the receiver to indicate the signal was lost\n(on receivers that use output a fixed signal value to report lost signal).\nIf set to 0, the channel mapped to throttle is used.\n\nUse RC_FAILS_THR to set the threshold indicating lost signal. By default it's below\nthe expected range and hence disabled.\n", "max": 18, "min": 0, "name": "RC_MAP_FAILSAFE", "shortDesc": "Failsafe channel mapping", "type": "Int32", "values": [{"description": "Unassigned", "value": 0}, {"description": "Channel 1", "value": 1}, {"description": "Channel 2", "value": 2}, {"description": "Channel 3", "value": 3}, {"description": "Channel 4", "value": 4}, {"description": "Channel 5", "value": 5}, {"description": "Channel 6", "value": 6}, {"description": "Channel 7", "value": 7}, {"description": "Channel 8", "value": 8}, {"description": "Channel 9", "value": 9}, {"description": "Channel 10", "value": 10}, {"description": "Channel 11", "value": 11}, {"description": "Channel 12", "value": 12}, {"description": "Channel 13", "value": 13}, {"description": "Channel 14", "value": 14}, {"description": "Channel 15", "value": 15}, {"description": "Channel 16", "value": 16}, {"description": "Channel 17", "value": 17}, {"description": "Channel 18", "value": 18}]}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "longDesc": "Can be used for parameter tuning with the RC. This one is further referenced as the 1st parameter channel.\nSet to 0 to deactivate *\n", "max": 18, "min": 0, "name": "RC_MAP_PARAM1", "shortDesc": "PARAM1 tuning channel", "type": "Int32", "values": [{"description": "Unassigned", "value": 0}, {"description": "Channel 1", "value": 1}, {"description": "Channel 2", "value": 2}, {"description": "Channel 3", "value": 3}, {"description": "Channel 4", "value": 4}, {"description": "Channel 5", "value": 5}, {"description": "Channel 6", "value": 6}, {"description": "Channel 7", "value": 7}, {"description": "Channel 8", "value": 8}, {"description": "Channel 9", "value": 9}, {"description": "Channel 10", "value": 10}, {"description": "Channel 11", "value": 11}, {"description": "Channel 12", "value": 12}, {"description": "Channel 13", "value": 13}, {"description": "Channel 14", "value": 14}, {"description": "Channel 15", "value": 15}, {"description": "Channel 16", "value": 16}, {"description": "Channel 17", "value": 17}, {"description": "Channel 18", "value": 18}]}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "longDesc": "Can be used for parameter tuning with the RC. This one is further referenced as the 2nd parameter channel.\nSet to 0 to deactivate *\n", "max": 18, "min": 0, "name": "RC_MAP_PARAM2", "shortDesc": "PARAM2 tuning channel", "type": "Int32", "values": [{"description": "Unassigned", "value": 0}, {"description": "Channel 1", "value": 1}, {"description": "Channel 2", "value": 2}, {"description": "Channel 3", "value": 3}, {"description": "Channel 4", "value": 4}, {"description": "Channel 5", "value": 5}, {"description": "Channel 6", "value": 6}, {"description": "Channel 7", "value": 7}, {"description": "Channel 8", "value": 8}, {"description": "Channel 9", "value": 9}, {"description": "Channel 10", "value": 10}, {"description": "Channel 11", "value": 11}, {"description": "Channel 12", "value": 12}, {"description": "Channel 13", "value": 13}, {"description": "Channel 14", "value": 14}, {"description": "Channel 15", "value": 15}, {"description": "Channel 16", "value": 16}, {"description": "Channel 17", "value": 17}, {"description": "Channel 18", "value": 18}]}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "longDesc": "Can be used for parameter tuning with the RC. This one is further referenced as the 3th parameter channel.\nSet to 0 to deactivate *\n", "max": 18, "min": 0, "name": "RC_MAP_PARAM3", "shortDesc": "PARAM3 tuning channel", "type": "Int32", "values": [{"description": "Unassigned", "value": 0}, {"description": "Channel 1", "value": 1}, {"description": "Channel 2", "value": 2}, {"description": "Channel 3", "value": 3}, {"description": "Channel 4", "value": 4}, {"description": "Channel 5", "value": 5}, {"description": "Channel 6", "value": 6}, {"description": "Channel 7", "value": 7}, {"description": "Channel 8", "value": 8}, {"description": "Channel 9", "value": 9}, {"description": "Channel 10", "value": 10}, {"description": "Channel 11", "value": 11}, {"description": "Channel 12", "value": 12}, {"description": "Channel 13", "value": 13}, {"description": "Channel 14", "value": 14}, {"description": "Channel 15", "value": 15}, {"description": "Channel 16", "value": 16}, {"description": "Channel 17", "value": 17}, {"description": "Channel 18", "value": 18}]}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "longDesc": "The channel index (starting from 1 for channel 1) indicates\nwhich channel should be used for reading pitch inputs from.\nA value of zero indicates the switch is not assigned.\n", "max": 18, "min": 0, "name": "RC_MAP_PITCH", "shortDesc": "Pitch control channel mapping", "type": "Int32", "values": [{"description": "Unassigned", "value": 0}, {"description": "Channel 1", "value": 1}, {"description": "Channel 2", "value": 2}, {"description": "Channel 3", "value": 3}, {"description": "Channel 4", "value": 4}, {"description": "Channel 5", "value": 5}, {"description": "Channel 6", "value": 6}, {"description": "Channel 7", "value": 7}, {"description": "Channel 8", "value": 8}, {"description": "Channel 9", "value": 9}, {"description": "Channel 10", "value": 10}, {"description": "Channel 11", "value": 11}, {"description": "Channel 12", "value": 12}, {"description": "Channel 13", "value": 13}, {"description": "Channel 14", "value": 14}, {"description": "Channel 15", "value": 15}, {"description": "Channel 16", "value": 16}, {"description": "Channel 17", "value": 17}, {"description": "Channel 18", "value": 18}]}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "longDesc": "The channel index (starting from 1 for channel 1) indicates\nwhich channel should be used for reading roll inputs from.\nA value of zero indicates the switch is not assigned.\n", "max": 18, "min": 0, "name": "RC_MAP_ROLL", "shortDesc": "Roll control channel mapping", "type": "Int32", "values": [{"description": "Unassigned", "value": 0}, {"description": "Channel 1", "value": 1}, {"description": "Channel 2", "value": 2}, {"description": "Channel 3", "value": 3}, {"description": "Channel 4", "value": 4}, {"description": "Channel 5", "value": 5}, {"description": "Channel 6", "value": 6}, {"description": "Channel 7", "value": 7}, {"description": "Channel 8", "value": 8}, {"description": "Channel 9", "value": 9}, {"description": "Channel 10", "value": 10}, {"description": "Channel 11", "value": 11}, {"description": "Channel 12", "value": 12}, {"description": "Channel 13", "value": 13}, {"description": "Channel 14", "value": 14}, {"description": "Channel 15", "value": 15}, {"description": "Channel 16", "value": 16}, {"description": "Channel 17", "value": 17}, {"description": "Channel 18", "value": 18}]}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "longDesc": "The channel index (starting from 1 for channel 1) indicates\nwhich channel should be used for reading throttle inputs from.\nA value of zero indicates the switch is not assigned.\n", "max": 18, "min": 0, "name": "RC_MAP_THROTTLE", "shortDesc": "Throttle control channel mapping", "type": "Int32", "values": [{"description": "Unassigned", "value": 0}, {"description": "Channel 1", "value": 1}, {"description": "Channel 2", "value": 2}, {"description": "Channel 3", "value": 3}, {"description": "Channel 4", "value": 4}, {"description": "Channel 5", "value": 5}, {"description": "Channel 6", "value": 6}, {"description": "Channel 7", "value": 7}, {"description": "Channel 8", "value": 8}, {"description": "Channel 9", "value": 9}, {"description": "Channel 10", "value": 10}, {"description": "Channel 11", "value": 11}, {"description": "Channel 12", "value": 12}, {"description": "Channel 13", "value": 13}, {"description": "Channel 14", "value": 14}, {"description": "Channel 15", "value": 15}, {"description": "Channel 16", "value": 16}, {"description": "Channel 17", "value": 17}, {"description": "Channel 18", "value": 18}]}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "longDesc": "The channel index (starting from 1 for channel 1) indicates\nwhich channel should be used for reading yaw inputs from.\nA value of zero indicates the switch is not assigned.\n", "max": 18, "min": 0, "name": "RC_MAP_YAW", "shortDesc": "Yaw control channel mapping", "type": "Int32", "values": [{"description": "Unassigned", "value": 0}, {"description": "Channel 1", "value": 1}, {"description": "Channel 2", "value": 2}, {"description": "Channel 3", "value": 3}, {"description": "Channel 4", "value": 4}, {"description": "Channel 5", "value": 5}, {"description": "Channel 6", "value": 6}, {"description": "Channel 7", "value": 7}, {"description": "Channel 8", "value": 8}, {"description": "Channel 9", "value": 9}, {"description": "Channel 10", "value": 10}, {"description": "Channel 11", "value": 11}, {"description": "Channel 12", "value": 12}, {"description": "Channel 13", "value": 13}, {"description": "Channel 14", "value": 14}, {"description": "Channel 15", "value": 15}, {"description": "Channel 16", "value": 16}, {"description": "Channel 17", "value": 17}, {"description": "Channel 18", "value": 18}]}, {"category": "Standard", "default": 0, "group": "Radio Calibration", "longDesc": "0: do not read RSSI from input channel\n1-18: read RSSI from specified input channel\n\nSpecify the range for RSSI input with RC_RSSI_PWM_MIN and RC_RSSI_PWM_MAX parameters.\n", "max": 18, "min": 0, "name": "RC_RSSI_PWM_CHAN", "shortDesc": "PWM input channel that provides RSSI", "type": "Int32", "values": [{"description": "Unassigned", "value": 0}, {"description": "Channel 1", "value": 1}, {"description": "Channel 2", "value": 2}, {"description": "Channel 3", "value": 3}, {"description": "Channel 4", "value": 4}, {"description": "Channel 5", "value": 5}, {"description": "Channel 6", "value": 6}, {"description": "Channel 7", "value": 7}, {"description": "Channel 8", "value": 8}, {"description": "Channel 9", "value": 9}, {"description": "Channel 10", "value": 10}, {"description": "Channel 11", "value": 11}, {"description": "Channel 12", "value": 12}, {"description": "Channel 13", "value": 13}, {"description": "Channel 14", "value": 14}, {"description": "Channel 15", "value": 15}, {"description": "Channel 16", "value": 16}, {"description": "Channel 17", "value": 17}, {"description": "Channel 18", "value": 18}]}, {"category": "Standard", "default": 2000, "group": "Radio Calibration", "longDesc": "Only used if RC_RSSI_PWM_CHAN > 0\n", "max": 2000, "min": 0, "name": "RC_RSSI_PWM_MAX", "shortDesc": "Max input value for RSSI reading", "type": "Int32"}, {"category": "Standard", "default": 1000, "group": "Radio Calibration", "longDesc": "Only used if RC_RSSI_PWM_CHAN > 0\n", "max": 2000, "min": 0, "name": "RC_RSSI_PWM_MIN", "shortDesc": "Min input value for RSSI reading", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Radio Calibration", "increment": 0.01, "longDesc": "The trim value is the actuator control value the system needs\nfor straight and level flight.\n", "max": 0.5, "min": -0.5, "name": "TRIM_PITCH", "shortDesc": "Pitch trim", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Radio Calibration", "increment": 0.01, "longDesc": "The trim value is the actuator control value the system needs\nfor straight and level flight.\n", "max": 0.5, "min": -0.5, "name": "TRIM_ROLL", "shortDesc": "Roll trim", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Radio Calibration", "increment": 0.01, "longDesc": "The trim value is the actuator control value the system needs\nfor straight and level flight.\n", "max": 0.5, "min": -0.5, "name": "TRIM_YAW", "shortDesc": "Yaw trim", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.75, "group": "Radio Switches", "longDesc": "0-1 indicate where in the full channel range the threshold sits\n0 : min\n1 : max\nsign indicates polarity of comparison\npositive : true when channel>th\nnegative : true when channelth\nnegative : true when channelth\nnegative : true when channelth\nnegative : true when channelth\nnegative : true when channelth\nnegative : true when channelth\nnegative : true when channelth\nnegative : true when channelth\nnegative : true when channelth\nnegative : true when channel The rover starts to cut the corner earlier.\n\n", "max": 100.0, "min": 1.0, "name": "RA_ACC_RAD_GAIN", "shortDesc": "Tuning parameter for corner cutting", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Rover Ackermann", "increment": 0.01, "longDesc": "The controller scales the acceptance radius based on the angle between\nthe previous, current and next waypoint.\nHigher value -> smoother trajectory at the cost of how close the rover gets\nto the waypoint (Set to -1 to disable corner cutting).\n\n", "max": 100.0, "min": -1.0, "name": "RA_ACC_RAD_MAX", "shortDesc": "Maximum acceptance radius for the waypoints", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Rover Ackermann", "increment": 0.01, "max": 1.5708, "min": 0.0, "name": "RA_MAX_STR_ANG", "shortDesc": "Maximum steering angle", "type": "Float", "units": "rad"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Rover Ackermann", "increment": 0.01, "longDesc": "Set to -1 to disable.\n", "max": 1000.0, "min": -1.0, "name": "RA_STR_RATE_LIM", "shortDesc": "Steering rate limit", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Rover Ackermann", "increment": 0.001, "longDesc": "Distance from the front to the rear axle.\n", "max": 100.0, "min": 0.0, "name": "RA_WHEEL_BASE", "shortDesc": "Wheel base", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Rover Attitude Control", "increment": 0.01, "max": 100.0, "min": 0.0, "name": "RO_YAW_P", "shortDesc": "Proportional gain for closed loop yaw controller", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.174533, "group": "Rover Differential", "increment": 0.01, "longDesc": "This threshold is used for the state machine to switch from driving to turning based on the\nerror between the desired and actual yaw. It is also used as the threshold whether the rover should come\nto a smooth stop at the next waypoint. This slow down effect is active if the angle between the\nline segments from prevWP-currWP and currWP-nextWP is smaller then 180 - RD_TRANS_DRV_TRN.\n\n", "max": 3.14159, "min": 0.001, "name": "RD_TRANS_DRV_TRN", "shortDesc": "Yaw error threshold to switch from driving to spot turning", "type": "Float", "units": "rad"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0872665, "group": "Rover Differential", "increment": 0.01, "longDesc": "This threshold is used for the state machine to switch from turning to driving based on the\nerror between the desired and actual yaw.\n\n", "max": 3.14159, "min": 0.001, "name": "RD_TRANS_TRN_DRV", "shortDesc": "Yaw error threshold to switch from spot turning to driving", "type": "Float", "units": "rad"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Rover Differential", "increment": 0.001, "longDesc": "Distance from the center of the right wheel to the center of the left wheel.\n", "max": 100.0, "min": 0.0, "name": "RD_WHEEL_TRACK", "shortDesc": "Wheel track", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "Rover Differential", "increment": 0.01, "longDesc": "Assign value <1.0 to decrease stick response for yaw control.\n", "max": 1.0, "min": 0.1, "name": "RD_YAW_STK_GAIN", "shortDesc": "Yaw stick gain for Manual mode", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "Rover Manual Control", "increment": 0.01, "longDesc": "Scales the stick inputs that are mapped to motor commands in Manual Parking mode, so that maneuvering in tight spaces stays slow. Applies symmetrically to forward and reverse throttle.\n\n", "max": 1.0, "min": 0.0, "name": "RO_PARK_THR_MAX", "shortDesc": "Maximum throttle in Manual Parking mode", "type": "Float", "units": "norm"}, {"category": "Standard", "default": 3, "group": "Rover Manual Control", "longDesc": "Follows the RC transmitter modes 1-4 with the pitch stick driving forwards/backwards, the roll stick sideways and the yaw stick turning, assuming the RC channels are mapped as for a mode 2 transmitter. Ackermann and differential rovers ignore the sideways assignment. In the tank-style Manual Parking mode of differential and mecanum rovers only the sideways assignment applies.\n", "name": "RO_STICK_MAP", "shortDesc": "Stick mapping for the manual modes", "type": "Int32", "values": [{"description": "Mode 1: forward and turn on left stick, sideways on right stick", "value": 1}, {"description": "Mode 2: turn on left stick, forward and sideways on right stick", "value": 2}, {"description": "Mode 3: forward and sideways on left stick, turn on right stick", "value": 3}, {"description": "Mode 4: sideways on left stick, forward and turn on right stick", "value": 4}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.17, "group": "Rover Mecanum", "increment": 0.01, "longDesc": "Threshold for the angle between the active cruise direction and the cruise direction given\nby the stick inputs.\nThis can be understood as a deadzone for the combined stick inputs for forward/backwards\nand lateral speed which defines a course direction.\n\n", "max": 3.14, "min": 0.0, "name": "RM_COURSE_CTL_TH", "shortDesc": "Threshold to update course control in manual position mode", "type": "Float", "units": "rad"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Rover Mecanum", "increment": 0.001, "longDesc": "Distance from the center of the right wheel to the center of the left wheel.\n", "max": 100.0, "min": 0.0, "name": "RM_WHEEL_TRACK", "shortDesc": "Wheel track", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "Rover Mecanum", "increment": 0.01, "longDesc": "Assign value <1.0 to decrease stick response for yaw control.\n", "max": 1.0, "min": 0.1, "name": "RM_YAW_STK_GAIN", "shortDesc": "Yaw stick gain for Manual mode", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Rover Rate Control", "increment": 0.01, "longDesc": "Used to cap how quickly the magnitude of yaw rate setpoints can increase.\nSet to -1 to disable.\n", "max": 10000.0, "min": -1.0, "name": "RO_YAW_ACCEL_LIM", "shortDesc": "Yaw acceleration limit", "type": "Float", "units": "deg/s^2"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Rover Rate Control", "increment": 0.01, "longDesc": "Used to cap how quickly the magnitude of yaw rate setpoints can decrease.\nSet to -1 to disable.\n", "max": 10000.0, "min": -1.0, "name": "RO_YAW_DECEL_LIM", "shortDesc": "Yaw deceleration limit", "type": "Float", "units": "deg/s^2"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Rover Rate Control", "longDesc": "Exponential factor for tuning the input curve shape.\n\n0 Purely linear input curve\n1 Purely cubic input curve\n", "max": 1.0, "min": 0.0, "name": "RO_YAW_EXPO", "shortDesc": "Yaw rate expo factor", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Rover Rate Control", "increment": 0.01, "longDesc": "Multiplicative correction factor for the feedforward mapping of the yaw rate controller.\nIncrease this value (x > 1) if the measured yaw rate is lower than the setpoint, decrease (0 < x < 1) otherwise.\nNote: Tuning this is particularly useful for skid-steered rovers, or rovers with misaligned wheels/steering axes\nthat cause a lot of friction when turning.\n", "max": 10000.0, "min": 0.01, "name": "RO_YAW_RATE_CORR", "shortDesc": "Yaw rate correction factor", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Rover Rate Control", "increment": 0.01, "max": 100.0, "min": 0.0, "name": "RO_YAW_RATE_I", "shortDesc": "Integral gain for closed loop yaw rate controller", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Rover Rate Control", "increment": 0.01, "longDesc": "Used to cap yaw rate setpoints and map controller inputs to yaw rate setpoints\nin Acro, Stabilized and Position mode.\n", "max": 10000.0, "min": 0.0, "name": "RO_YAW_RATE_LIM", "shortDesc": "Yaw rate limit", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Rover Rate Control", "increment": 0.01, "max": 100.0, "min": 0.0, "name": "RO_YAW_RATE_P", "shortDesc": "Proportional gain for closed loop yaw rate controller", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 3.0, "group": "Rover Rate Control", "increment": 0.01, "longDesc": "The minimum threshold for the yaw rate measurement not to be interpreted as zero.\n", "max": 100.0, "min": 0.0, "name": "RO_YAW_RATE_TH", "shortDesc": "Yaw rate measurement threshold", "type": "Float", "units": "deg/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "Rover Rate Control", "increment": 0.01, "longDesc": "Percentage of stick input range that will be interpreted as zero around the stick centered value.\n", "max": 1.0, "min": 0.0, "name": "RO_YAW_STICK_DZ", "shortDesc": "Yaw stick deadzone", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Rover Rate Control", "longDesc": "\"Superexponential\" factor for refining the input curve shape tuned using RO_YAW_EXPO.\n\n0 Pure Expo function\n0.7 reasonable shape enhancement for intuitive stick feel\n0.95 very strong bent input curve only near maxima have effect\n", "max": 0.95, "min": 0.0, "name": "RO_YAW_SUPEXPO", "shortDesc": "Yaw rate super expo factor", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Rover Velocity Control", "increment": 0.01, "longDesc": "Set to -1 to disable.\nFor mecanum rovers this limit is used for longitudinal and lateral acceleration.\n", "max": 100.0, "min": -1.0, "name": "RO_ACCEL_LIM", "shortDesc": "Acceleration limit", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Rover Velocity Control", "increment": 0.01, "longDesc": "Set to -1 to disable.\nNote that if it is disabled the rover will not slow down when approaching waypoints in auto modes.\nFor mecanum rovers this limit is used for longitudinal and lateral deceleration.\n", "max": 100.0, "min": -1.0, "name": "RO_DECEL_LIM", "shortDesc": "Deceleration limit", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Rover Velocity Control", "increment": 0.01, "longDesc": "Set to -1 to disable.\nNote that if it is disabled the rover will not slow down when approaching waypoints in auto modes.\nFor mecanum rovers this limit is used for longitudinal and lateral jerk.\n", "max": 100.0, "min": -1.0, "name": "RO_JERK_LIM", "shortDesc": "Jerk limit", "type": "Float", "units": "m/s^3"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Rover Velocity Control", "increment": 0.01, "longDesc": "Used to linearly map speeds [m/s] to throttle values [-1. 1].\n", "max": 100.0, "min": 0.0, "name": "RO_MAX_THR_SPEED", "shortDesc": "Speed the rover drives at maximum throttle", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Rover Velocity Control", "increment": 0.001, "max": 100.0, "min": 0.0, "name": "RO_SPEED_I", "shortDesc": "Integral gain for ground speed controller", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Rover Velocity Control", "increment": 0.01, "longDesc": "Used to cap speed setpoints and map controller inputs to speed setpoints in Position mode.\n", "max": 100.0, "min": -1.0, "name": "RO_SPEED_LIM", "shortDesc": "Speed limit", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.0, "group": "Rover Velocity Control", "increment": 0.01, "max": 100.0, "min": 0.0, "name": "RO_SPEED_P", "shortDesc": "Proportional gain for ground speed controller", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": -1.0, "group": "Rover Velocity Control", "increment": 0.01, "longDesc": "```\nReduced_speed = RO_MAX_THR_SPEED * (1 - normalized_course_error * RO_SPEED_RED)\n```\nThe normalized course error is the angle between the current course and the bearing setpoint\ninterpolated from [0, 180] -> [0, 1].\nHigher value -> More speed reduction.\nNote: This is also used to calculate the speed at which the vehicle arrives at a waypoint in auto modes.\nSet to -1 to disable bearing error based speed reduction.\n", "max": 100.0, "min": -1.0, "name": "RO_SPEED_RED", "shortDesc": "Tuning parameter for the speed reduction based on the course error", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "Rover Velocity Control", "increment": 0.01, "longDesc": "Set to -1 to disable.\nThe minimum threshold for the speed measurement not to be interpreted as zero.\n", "max": 100.0, "min": 0.0, "name": "RO_SPEED_TH", "shortDesc": "Speed measurement threshold", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.1, "group": "Rover Velocity Control", "increment": 0.001, "longDesc": "Used to convert wheel encoder counts to the distance travelled by each wheel\nfor the MAVLink WHEEL_DISTANCE message:\ndistance = 2 * pi * RO_WHEEL_RAD * encoder_counts / counts_per_rev\n", "max": 10.0, "min": 0.01, "name": "RO_WHEEL_RAD", "shortDesc": "Wheel radius in meters", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Runway Takeoff", "increment": 0.01, "max": 1.0, "min": 0.0, "name": "RWTO_MAX_THR", "shortDesc": "Throttle during runway takeoff", "type": "Float", "units": "norm"}, {"category": "Standard", "default": 1, "group": "Runway Takeoff", "longDesc": "Enable use of yaw stick for nudging the wheel during runway ground roll\n\nThis is useful when map, GNSS, or yaw errors on ground are misaligned with what the operator intends for takeoff course.\nParticularly useful for skinny runways or if the wheel servo is a bit off trim.\n", "name": "RWTO_NUDGE", "shortDesc": "Enable yaw stick nudging during runway ground roll", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "Runway Takeoff", "increment": 0.5, "longDesc": "Pitch setpoint during taxi / before takeoff rotation airspeed is reached\n\nA taildragger with steerable wheel might need to pitch up\na little to keep its wheel on the ground before airspeed\nto takeoff is reached.\n", "max": 20.0, "min": -10.0, "name": "RWTO_PSP", "shortDesc": "Absolute pitch setpoint during taxi / before rotation", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 2, "default": 2.0, "group": "Runway Takeoff", "increment": 0.1, "max": 15.0, "min": 1.0, "name": "RWTO_RAMP_TIME", "shortDesc": "Throttle ramp up time for runway takeoff", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": -1.0, "group": "Runway Takeoff", "increment": 0.1, "longDesc": "The calibrated airspeed threshold during the takeoff ground roll when the plane should start rotating (pitching up).\nMust be less than the takeoff airspeed, will otherwise be capped at the takeoff airspeed (see FW_TKO_AIRSPD).\n\nIf set <= 0.0, defaults to 0.9 * takeoff airspeed (see FW_TKO_AIRSPD)\n", "min": -1.0, "name": "RWTO_ROT_AIRSPD", "shortDesc": "Takeoff rotation airspeed", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.0, "group": "Runway Takeoff", "increment": 0.1, "longDesc": "This is the time desired to linearly ramp in takeoff pitch constraints during the takeoff rotation\n", "min": 0.1, "name": "RWTO_ROT_TIME", "shortDesc": "Takeoff rotation time", "type": "Float", "units": "s"}, {"category": "Standard", "default": 0, "group": "Runway Takeoff", "name": "RWTO_TKOFF", "shortDesc": "Runway takeoff with landing gear", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"bitmask": [{"description": "SD card logging", "index": 0}, {"description": "Mavlink logging", "index": 1}], "category": "Standard", "default": 3, "group": "SD Logging", "longDesc": "If no logging is set the logger will not be started. Set bits true to enable: 0: SD card logging 1: Mavlink logging\n", "max": 3, "min": 0, "name": "SDLOG_BACKEND", "rebootRequired": true, "shortDesc": "Logging Backend (integer bitmask)", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "SD Logging", "longDesc": "When enabled, logging will not start from boot if battery power is not detected (e.g. powered via USB on a test bench). This prevents extraneous flight logs from being created during bench testing. Note that this only applies to log-from-boot modes. This has no effect on arm-based modes.\n", "name": "SDLOG_BOOT_BAT", "shortDesc": "Battery-only Logging", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "SD Logging", "longDesc": "At log start, oldest log directories are deleted to stay within this count. Independent of SDLOG_ROTATE and SDLOG_MAX_SIZE, e.g. to cap logs by count in SITL. Set to 0 to disable.\n", "max": 1000, "min": 0, "name": "SDLOG_DIRS_MAX", "shortDesc": "Maximum number of log directories to keep", "type": "Int32"}, {"category": "Standard", "default": 1024, "group": "SD Logging", "longDesc": "Maximum size of a single log file in mebibytes (1 MiB = 1024 * 1024 bytes). When reached, the log file is closed and a new one is started. This value is also added to the cleanup threshold (see SDLOG_ROTATE) to reserve headroom for the next log file. A value of 0 disables both file rotation and the cleanup reservation. Must stay below the FAT32 file size limit of 4 GiB.\n", "max": 4095, "min": 0, "name": "SDLOG_MAX_SIZE", "shortDesc": "Maximum log file size", "type": "Int32", "units": "MiB"}, {"category": "Standard", "default": 0, "group": "SD Logging", "longDesc": "Writes a small extra log with only the messages needed for flight statistics and geotagging. The full log is still written and contains all of this data.\n", "name": "SDLOG_MISSION", "rebootRequired": true, "shortDesc": "Mission Log", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "All mission messages", "value": 1}, {"description": "Geotagging messages", "value": 2}]}, {"category": "Standard", "default": 0, "group": "SD Logging", "longDesc": "Only applies to SD card logging; MAVLink logging starts and stops independently.\n", "name": "SDLOG_MODE", "rebootRequired": true, "shortDesc": "Logging Mode", "type": "Int32", "values": [{"description": "when armed until disarm (default)", "value": 0}, {"description": "from boot until disarm", "value": 1}, {"description": "from boot until shutdown", "value": 2}, {"description": "while manual input AUX1 >30%", "value": 3}, {"description": "from 1st armed until shutdown", "value": 4}]}, {"bitmask": [{"description": "Default set (general log analysis)", "index": 0}, {"description": "Estimator replay (EKF2, full rate)", "index": 1}, {"description": "Thermal calibration (high-rate raw IMU and baro)", "index": 2}, {"description": "System identification (high-rate actuator and IMU)", "index": 3}, {"description": "High rate (RC, attitude, rates and actuators)", "index": 4}, {"description": "Debug (debug_*.msg topics)", "index": 5}, {"description": "Sensor comparison (low-rate raw IMU, baro and mag)", "index": 6}, {"description": "Computer Vision and Avoidance", "index": 7}, {"description": "Raw FIFO high-rate IMU (Gyro)", "index": 8}, {"description": "Raw FIFO high-rate IMU (Accel)", "index": 9}, {"description": "Mavlink tunnel message logging (payload debugging)", "index": 10}, {"description": "High rate sensors", "index": 11}], "category": "Standard", "default": 1, "group": "SD Logging", "longDesc": "Each additional set increases bandwidth and log size.\n", "max": 4095, "min": 0, "name": "SDLOG_PROFILE", "rebootRequired": true, "shortDesc": "Logging topic profile", "type": "Int32"}, {"category": "Standard", "default": 90, "group": "SD Logging", "longDesc": "The limit includes the log being written. Oldest logs are deleted at log start (not boot), leaving room for a file of up to SDLOG_MAX_SIZE, so logs can be downloaded before deletion. 100 lets logs fill the disk. Set to 0 to disable.\n", "max": 100, "min": 0, "name": "SDLOG_ROTATE", "shortDesc": "Maximum disk usage percentage", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "SD Logging", "longDesc": "the difference in hours and minutes from Coordinated Universal Time (UTC) for a your place and date. for example, In case of South Korea(UTC+09:00), UTC offset is 540 min (9*60) refer to https://en.wikipedia.org/wiki/List_of_UTC_time_offsets\n", "max": 1000, "min": -1000, "name": "SDLOG_UTC_OFFSET", "shortDesc": "UTC offset (unit: min)", "type": "Int32", "units": "min"}, {"category": "Standard", "default": 1, "group": "SD Logging", "longDesc": "If set to 1, add an ID to the log, which uniquely identifies the vehicle\n", "name": "SDLOG_UUID", "shortDesc": "Log UUID", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": -1.0, "group": "SITL", "increment": 1.0, "longDesc": "Time in seconds for simulated battery 1 to drain from 100% to 0% while armed,\noverriding SIM_BAT_DRAIN for this battery only. A non-positive value uses SIM_BAT_DRAIN.\nOnly has an effect if battery 1 is enabled through BAT1_SOURCE.\n", "min": -1.0, "name": "SIM_BAT1_DRAIN", "shortDesc": "Simulated battery 1 full-discharge time", "type": "Float", "units": "s"}, {"category": "Standard", "default": -1.0, "group": "SITL", "increment": 0.1, "longDesc": "Lowest state of charge simulated battery 1 drains down to, overriding\nSIM_BAT_MIN_PCT for this battery only. Set to -1 to use SIM_BAT_MIN_PCT.\nOnly has an effect if battery 1 is enabled through BAT1_SOURCE.\n", "max": 100.0, "min": -1.0, "name": "SIM_BAT1_MIN_PCT", "shortDesc": "Simulated battery 1 minimal percentage", "type": "Float", "units": "%"}, {"category": "Standard", "default": -1.0, "group": "SITL", "increment": 1.0, "longDesc": "Time in seconds for simulated battery 2 to drain from 100% to 0% while armed,\noverriding SIM_BAT_DRAIN for this battery only. A non-positive value uses SIM_BAT_DRAIN.\nOnly has an effect if battery 2 is enabled through BAT2_SOURCE.\n", "min": -1.0, "name": "SIM_BAT2_DRAIN", "shortDesc": "Simulated battery 2 full-discharge time", "type": "Float", "units": "s"}, {"category": "Standard", "default": -1.0, "group": "SITL", "increment": 0.1, "longDesc": "Lowest state of charge simulated battery 2 drains down to, overriding\nSIM_BAT_MIN_PCT for this battery only. Set to -1 to use SIM_BAT_MIN_PCT.\nOnly has an effect if battery 2 is enabled through BAT2_SOURCE.\n", "max": 100.0, "min": -1.0, "name": "SIM_BAT2_MIN_PCT", "shortDesc": "Simulated battery 2 minimal percentage", "type": "Float", "units": "%"}, {"category": "Standard", "default": -1.0, "group": "SITL", "increment": 1.0, "longDesc": "Time in seconds for simulated battery 3 to drain from 100% to 0% while armed,\noverriding SIM_BAT_DRAIN for this battery only. A non-positive value uses SIM_BAT_DRAIN.\nOnly has an effect if battery 3 is enabled through BAT3_SOURCE.\n", "min": -1.0, "name": "SIM_BAT3_DRAIN", "shortDesc": "Simulated battery 3 full-discharge time", "type": "Float", "units": "s"}, {"category": "Standard", "default": -1.0, "group": "SITL", "increment": 0.1, "longDesc": "Lowest state of charge simulated battery 3 drains down to, overriding\nSIM_BAT_MIN_PCT for this battery only. Set to -1 to use SIM_BAT_MIN_PCT.\nOnly has an effect if battery 3 is enabled through BAT3_SOURCE.\n", "max": 100.0, "min": -1.0, "name": "SIM_BAT3_MIN_PCT", "shortDesc": "Simulated battery 3 minimal percentage", "type": "Float", "units": "%"}, {"category": "Standard", "default": 60.0, "group": "SITL", "increment": 1.0, "longDesc": "Time in seconds for the simulated battery to drain from 100% to 0% while armed. Set to 0 to disable the battery simulator entirely (useful when battery state is provided externally, e.g. via MAVLink).\n", "min": 0.0, "name": "SIM_BAT_DRAIN", "shortDesc": "Simulated battery full-discharge time", "type": "Float", "units": "s"}, {"category": "Standard", "default": 50.0, "group": "SITL", "increment": 0.1, "longDesc": "Can be used to alter the battery level during SITL- or HITL-simulation on the fly.\nParticularly useful for testing different low-battery behaviour.\n", "max": 100.0, "min": 0.0, "name": "SIM_BAT_MIN_PCT", "shortDesc": "Simulator Battery minimal percentage", "type": "Float", "units": "%"}, {"category": "System", "decimalPlaces": 3, "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the accelerometer this calibration applies to.\n", "name": "CAL_ACC0_ID", "shortDesc": "Accelerometer 0 calibration device ID", "type": "Int32"}, {"category": "System", "decimalPlaces": 3, "default": -1, "group": "Sensor Calibration", "longDesc": "Uninitialized sensors default to Medium when internal and Low when\nexternal, so an on-board IMU is preferred over one behind a bus.\n\n", "name": "CAL_ACC0_PRIO", "shortDesc": "Accelerometer 0 priority", "type": "Int32", "values": [{"description": "Uninitialized", "value": -1}, {"description": "Disabled", "value": 0}, {"description": "Min", "value": 1}, {"description": "Low", "value": 25}, {"description": "Medium (Default)", "value": 50}, {"description": "High", "value": 75}, {"description": "Max", "value": 100}]}, {"category": "System", "default": -1, "group": "Sensor Calibration", "longDesc": "An internal sensor will force a value of -1, so a GCS should only attempt to configure the rotation if the value is greater than or equal to zero.\n\n", "max": 40, "min": -1, "name": "CAL_ACC0_ROT", "shortDesc": "Accelerometer 0 rotation relative to airframe", "type": "Int32", "values": [{"description": "Internal", "value": -1}, {"description": "No rotation", "value": 0}, {"description": "Yaw 45\u00b0", "value": 1}, {"description": "Yaw 90\u00b0", "value": 2}, {"description": "Yaw 135\u00b0", "value": 3}, {"description": "Yaw 180\u00b0", "value": 4}, {"description": "Yaw 225\u00b0", "value": 5}, {"description": "Yaw 270\u00b0", "value": 6}, {"description": "Yaw 315\u00b0", "value": 7}, {"description": "Roll 180\u00b0", "value": 8}, {"description": "Roll 180\u00b0, Yaw 45\u00b0", "value": 9}, {"description": "Roll 180\u00b0, Yaw 90\u00b0", "value": 10}, {"description": "Roll 180\u00b0, Yaw 135\u00b0", "value": 11}, {"description": "Pitch 180\u00b0", "value": 12}, {"description": "Roll 180\u00b0, Yaw 225\u00b0", "value": 13}, {"description": "Roll 180\u00b0, Yaw 270\u00b0", "value": 14}, {"description": "Roll 180\u00b0, Yaw 315\u00b0", "value": 15}, {"description": "Roll 90\u00b0", "value": 16}, {"description": "Roll 90\u00b0, Yaw 45\u00b0", "value": 17}, {"description": "Roll 90\u00b0, Yaw 90\u00b0", "value": 18}, {"description": "Roll 90\u00b0, Yaw 135\u00b0", "value": 19}, {"description": "Roll 270\u00b0", "value": 20}, {"description": "Roll 270\u00b0, Yaw 45\u00b0", "value": 21}, {"description": "Roll 270\u00b0, Yaw 90\u00b0", "value": 22}, {"description": "Roll 270\u00b0, Yaw 135\u00b0", "value": 23}, {"description": "Pitch 90\u00b0", "value": 24}, {"description": "Pitch 270\u00b0", "value": 25}, {"description": "Pitch 180\u00b0, Yaw 90\u00b0", "value": 26}, {"description": "Pitch 180\u00b0, Yaw 270\u00b0", "value": 27}, {"description": "Roll 90\u00b0, Pitch 90\u00b0", "value": 28}, {"description": "Roll 180\u00b0, Pitch 90\u00b0", "value": 29}, {"description": "Roll 270\u00b0, Pitch 90\u00b0", "value": 30}, {"description": "Roll 90\u00b0, Pitch 180\u00b0", "value": 31}, {"description": "Roll 270\u00b0, Pitch 180\u00b0", "value": 32}, {"description": "Roll 90\u00b0, Pitch 270\u00b0", "value": 33}, {"description": "Roll 180\u00b0, Pitch 270\u00b0", "value": 34}, {"description": "Roll 270\u00b0, Pitch 270\u00b0", "value": 35}, {"description": "Roll 90\u00b0, Pitch 180\u00b0, Yaw 90\u00b0", "value": 36}, {"description": "Roll 90\u00b0, Yaw 270\u00b0", "value": 37}, {"description": "Roll 90\u00b0, Pitch 68\u00b0, Yaw 293\u00b0", "value": 38}, {"description": "Pitch 315\u00b0", "value": 39}, {"description": "Roll 90\u00b0, Pitch 315\u00b0", "value": 40}]}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_ACC0_XOFF", "shortDesc": "Accelerometer 0 X-axis offset", "type": "Float", "units": "m/s^2", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_ACC0_XSCALE", "shortDesc": "Accelerometer 0 X-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_ACC0_YOFF", "shortDesc": "Accelerometer 0 Y-axis offset", "type": "Float", "units": "m/s^2", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_ACC0_YSCALE", "shortDesc": "Accelerometer 0 Y-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_ACC0_ZOFF", "shortDesc": "Accelerometer 0 Z-axis offset", "type": "Float", "units": "m/s^2", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_ACC0_ZSCALE", "shortDesc": "Accelerometer 0 Z-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the accelerometer this calibration applies to.\n", "name": "CAL_ACC1_ID", "shortDesc": "Accelerometer 1 calibration device ID", "type": "Int32"}, {"category": "System", "decimalPlaces": 3, "default": -1, "group": "Sensor Calibration", "longDesc": "Uninitialized sensors default to Medium when internal and Low when\nexternal, so an on-board IMU is preferred over one behind a bus.\n\n", "name": "CAL_ACC1_PRIO", "shortDesc": "Accelerometer 1 priority", "type": "Int32", "values": [{"description": "Uninitialized", "value": -1}, {"description": "Disabled", "value": 0}, {"description": "Min", "value": 1}, {"description": "Low", "value": 25}, {"description": "Medium (Default)", "value": 50}, {"description": "High", "value": 75}, {"description": "Max", "value": 100}]}, {"category": "System", "default": -1, "group": "Sensor Calibration", "longDesc": "An internal sensor will force a value of -1, so a GCS should only attempt to configure the rotation if the value is greater than or equal to zero.\n\n", "max": 40, "min": -1, "name": "CAL_ACC1_ROT", "shortDesc": "Accelerometer 1 rotation relative to airframe", "type": "Int32", "values": [{"description": "Internal", "value": -1}, {"description": "No rotation", "value": 0}, {"description": "Yaw 45\u00b0", "value": 1}, {"description": "Yaw 90\u00b0", "value": 2}, {"description": "Yaw 135\u00b0", "value": 3}, {"description": "Yaw 180\u00b0", "value": 4}, {"description": "Yaw 225\u00b0", "value": 5}, {"description": "Yaw 270\u00b0", "value": 6}, {"description": "Yaw 315\u00b0", "value": 7}, {"description": "Roll 180\u00b0", "value": 8}, {"description": "Roll 180\u00b0, Yaw 45\u00b0", "value": 9}, {"description": "Roll 180\u00b0, Yaw 90\u00b0", "value": 10}, {"description": "Roll 180\u00b0, Yaw 135\u00b0", "value": 11}, {"description": "Pitch 180\u00b0", "value": 12}, {"description": "Roll 180\u00b0, Yaw 225\u00b0", "value": 13}, {"description": "Roll 180\u00b0, Yaw 270\u00b0", "value": 14}, {"description": "Roll 180\u00b0, Yaw 315\u00b0", "value": 15}, {"description": "Roll 90\u00b0", "value": 16}, {"description": "Roll 90\u00b0, Yaw 45\u00b0", "value": 17}, {"description": "Roll 90\u00b0, Yaw 90\u00b0", "value": 18}, {"description": "Roll 90\u00b0, Yaw 135\u00b0", "value": 19}, {"description": "Roll 270\u00b0", "value": 20}, {"description": "Roll 270\u00b0, Yaw 45\u00b0", "value": 21}, {"description": "Roll 270\u00b0, Yaw 90\u00b0", "value": 22}, {"description": "Roll 270\u00b0, Yaw 135\u00b0", "value": 23}, {"description": "Pitch 90\u00b0", "value": 24}, {"description": "Pitch 270\u00b0", "value": 25}, {"description": "Pitch 180\u00b0, Yaw 90\u00b0", "value": 26}, {"description": "Pitch 180\u00b0, Yaw 270\u00b0", "value": 27}, {"description": "Roll 90\u00b0, Pitch 90\u00b0", "value": 28}, {"description": "Roll 180\u00b0, Pitch 90\u00b0", "value": 29}, {"description": "Roll 270\u00b0, Pitch 90\u00b0", "value": 30}, {"description": "Roll 90\u00b0, Pitch 180\u00b0", "value": 31}, {"description": "Roll 270\u00b0, Pitch 180\u00b0", "value": 32}, {"description": "Roll 90\u00b0, Pitch 270\u00b0", "value": 33}, {"description": "Roll 180\u00b0, Pitch 270\u00b0", "value": 34}, {"description": "Roll 270\u00b0, Pitch 270\u00b0", "value": 35}, {"description": "Roll 90\u00b0, Pitch 180\u00b0, Yaw 90\u00b0", "value": 36}, {"description": "Roll 90\u00b0, Yaw 270\u00b0", "value": 37}, {"description": "Roll 90\u00b0, Pitch 68\u00b0, Yaw 293\u00b0", "value": 38}, {"description": "Pitch 315\u00b0", "value": 39}, {"description": "Roll 90\u00b0, Pitch 315\u00b0", "value": 40}]}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_ACC1_XOFF", "shortDesc": "Accelerometer 1 X-axis offset", "type": "Float", "units": "m/s^2", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_ACC1_XSCALE", "shortDesc": "Accelerometer 1 X-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_ACC1_YOFF", "shortDesc": "Accelerometer 1 Y-axis offset", "type": "Float", "units": "m/s^2", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_ACC1_YSCALE", "shortDesc": "Accelerometer 1 Y-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_ACC1_ZOFF", "shortDesc": "Accelerometer 1 Z-axis offset", "type": "Float", "units": "m/s^2", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_ACC1_ZSCALE", "shortDesc": "Accelerometer 1 Z-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the accelerometer this calibration applies to.\n", "name": "CAL_ACC2_ID", "shortDesc": "Accelerometer 2 calibration device ID", "type": "Int32"}, {"category": "System", "decimalPlaces": 3, "default": -1, "group": "Sensor Calibration", "longDesc": "Uninitialized sensors default to Medium when internal and Low when\nexternal, so an on-board IMU is preferred over one behind a bus.\n\n", "name": "CAL_ACC2_PRIO", "shortDesc": "Accelerometer 2 priority", "type": "Int32", "values": [{"description": "Uninitialized", "value": -1}, {"description": "Disabled", "value": 0}, {"description": "Min", "value": 1}, {"description": "Low", "value": 25}, {"description": "Medium (Default)", "value": 50}, {"description": "High", "value": 75}, {"description": "Max", "value": 100}]}, {"category": "System", "default": -1, "group": "Sensor Calibration", "longDesc": "An internal sensor will force a value of -1, so a GCS should only attempt to configure the rotation if the value is greater than or equal to zero.\n\n", "max": 40, "min": -1, "name": "CAL_ACC2_ROT", "shortDesc": "Accelerometer 2 rotation relative to airframe", "type": "Int32", "values": [{"description": "Internal", "value": -1}, {"description": "No rotation", "value": 0}, {"description": "Yaw 45\u00b0", "value": 1}, {"description": "Yaw 90\u00b0", "value": 2}, {"description": "Yaw 135\u00b0", "value": 3}, {"description": "Yaw 180\u00b0", "value": 4}, {"description": "Yaw 225\u00b0", "value": 5}, {"description": "Yaw 270\u00b0", "value": 6}, {"description": "Yaw 315\u00b0", "value": 7}, {"description": "Roll 180\u00b0", "value": 8}, {"description": "Roll 180\u00b0, Yaw 45\u00b0", "value": 9}, {"description": "Roll 180\u00b0, Yaw 90\u00b0", "value": 10}, {"description": "Roll 180\u00b0, Yaw 135\u00b0", "value": 11}, {"description": "Pitch 180\u00b0", "value": 12}, {"description": "Roll 180\u00b0, Yaw 225\u00b0", "value": 13}, {"description": "Roll 180\u00b0, Yaw 270\u00b0", "value": 14}, {"description": "Roll 180\u00b0, Yaw 315\u00b0", "value": 15}, {"description": "Roll 90\u00b0", "value": 16}, {"description": "Roll 90\u00b0, Yaw 45\u00b0", "value": 17}, {"description": "Roll 90\u00b0, Yaw 90\u00b0", "value": 18}, {"description": "Roll 90\u00b0, Yaw 135\u00b0", "value": 19}, {"description": "Roll 270\u00b0", "value": 20}, {"description": "Roll 270\u00b0, Yaw 45\u00b0", "value": 21}, {"description": "Roll 270\u00b0, Yaw 90\u00b0", "value": 22}, {"description": "Roll 270\u00b0, Yaw 135\u00b0", "value": 23}, {"description": "Pitch 90\u00b0", "value": 24}, {"description": "Pitch 270\u00b0", "value": 25}, {"description": "Pitch 180\u00b0, Yaw 90\u00b0", "value": 26}, {"description": "Pitch 180\u00b0, Yaw 270\u00b0", "value": 27}, {"description": "Roll 90\u00b0, Pitch 90\u00b0", "value": 28}, {"description": "Roll 180\u00b0, Pitch 90\u00b0", "value": 29}, {"description": "Roll 270\u00b0, Pitch 90\u00b0", "value": 30}, {"description": "Roll 90\u00b0, Pitch 180\u00b0", "value": 31}, {"description": "Roll 270\u00b0, Pitch 180\u00b0", "value": 32}, {"description": "Roll 90\u00b0, Pitch 270\u00b0", "value": 33}, {"description": "Roll 180\u00b0, Pitch 270\u00b0", "value": 34}, {"description": "Roll 270\u00b0, Pitch 270\u00b0", "value": 35}, {"description": "Roll 90\u00b0, Pitch 180\u00b0, Yaw 90\u00b0", "value": 36}, {"description": "Roll 90\u00b0, Yaw 270\u00b0", "value": 37}, {"description": "Roll 90\u00b0, Pitch 68\u00b0, Yaw 293\u00b0", "value": 38}, {"description": "Pitch 315\u00b0", "value": 39}, {"description": "Roll 90\u00b0, Pitch 315\u00b0", "value": 40}]}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_ACC2_XOFF", "shortDesc": "Accelerometer 2 X-axis offset", "type": "Float", "units": "m/s^2", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_ACC2_XSCALE", "shortDesc": "Accelerometer 2 X-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_ACC2_YOFF", "shortDesc": "Accelerometer 2 Y-axis offset", "type": "Float", "units": "m/s^2", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_ACC2_YSCALE", "shortDesc": "Accelerometer 2 Y-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_ACC2_ZOFF", "shortDesc": "Accelerometer 2 Z-axis offset", "type": "Float", "units": "m/s^2", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_ACC2_ZSCALE", "shortDesc": "Accelerometer 2 Z-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the accelerometer this calibration applies to.\n", "name": "CAL_ACC3_ID", "shortDesc": "Accelerometer 3 calibration device ID", "type": "Int32"}, {"category": "System", "decimalPlaces": 3, "default": -1, "group": "Sensor Calibration", "longDesc": "Uninitialized sensors default to Medium when internal and Low when\nexternal, so an on-board IMU is preferred over one behind a bus.\n\n", "name": "CAL_ACC3_PRIO", "shortDesc": "Accelerometer 3 priority", "type": "Int32", "values": [{"description": "Uninitialized", "value": -1}, {"description": "Disabled", "value": 0}, {"description": "Min", "value": 1}, {"description": "Low", "value": 25}, {"description": "Medium (Default)", "value": 50}, {"description": "High", "value": 75}, {"description": "Max", "value": 100}]}, {"category": "System", "default": -1, "group": "Sensor Calibration", "longDesc": "An internal sensor will force a value of -1, so a GCS should only attempt to configure the rotation if the value is greater than or equal to zero.\n\n", "max": 40, "min": -1, "name": "CAL_ACC3_ROT", "shortDesc": "Accelerometer 3 rotation relative to airframe", "type": "Int32", "values": [{"description": "Internal", "value": -1}, {"description": "No rotation", "value": 0}, {"description": "Yaw 45\u00b0", "value": 1}, {"description": "Yaw 90\u00b0", "value": 2}, {"description": "Yaw 135\u00b0", "value": 3}, {"description": "Yaw 180\u00b0", "value": 4}, {"description": "Yaw 225\u00b0", "value": 5}, {"description": "Yaw 270\u00b0", "value": 6}, {"description": "Yaw 315\u00b0", "value": 7}, {"description": "Roll 180\u00b0", "value": 8}, {"description": "Roll 180\u00b0, Yaw 45\u00b0", "value": 9}, {"description": "Roll 180\u00b0, Yaw 90\u00b0", "value": 10}, {"description": "Roll 180\u00b0, Yaw 135\u00b0", "value": 11}, {"description": "Pitch 180\u00b0", "value": 12}, {"description": "Roll 180\u00b0, Yaw 225\u00b0", "value": 13}, {"description": "Roll 180\u00b0, Yaw 270\u00b0", "value": 14}, {"description": "Roll 180\u00b0, Yaw 315\u00b0", "value": 15}, {"description": "Roll 90\u00b0", "value": 16}, {"description": "Roll 90\u00b0, Yaw 45\u00b0", "value": 17}, {"description": "Roll 90\u00b0, Yaw 90\u00b0", "value": 18}, {"description": "Roll 90\u00b0, Yaw 135\u00b0", "value": 19}, {"description": "Roll 270\u00b0", "value": 20}, {"description": "Roll 270\u00b0, Yaw 45\u00b0", "value": 21}, {"description": "Roll 270\u00b0, Yaw 90\u00b0", "value": 22}, {"description": "Roll 270\u00b0, Yaw 135\u00b0", "value": 23}, {"description": "Pitch 90\u00b0", "value": 24}, {"description": "Pitch 270\u00b0", "value": 25}, {"description": "Pitch 180\u00b0, Yaw 90\u00b0", "value": 26}, {"description": "Pitch 180\u00b0, Yaw 270\u00b0", "value": 27}, {"description": "Roll 90\u00b0, Pitch 90\u00b0", "value": 28}, {"description": "Roll 180\u00b0, Pitch 90\u00b0", "value": 29}, {"description": "Roll 270\u00b0, Pitch 90\u00b0", "value": 30}, {"description": "Roll 90\u00b0, Pitch 180\u00b0", "value": 31}, {"description": "Roll 270\u00b0, Pitch 180\u00b0", "value": 32}, {"description": "Roll 90\u00b0, Pitch 270\u00b0", "value": 33}, {"description": "Roll 180\u00b0, Pitch 270\u00b0", "value": 34}, {"description": "Roll 270\u00b0, Pitch 270\u00b0", "value": 35}, {"description": "Roll 90\u00b0, Pitch 180\u00b0, Yaw 90\u00b0", "value": 36}, {"description": "Roll 90\u00b0, Yaw 270\u00b0", "value": 37}, {"description": "Roll 90\u00b0, Pitch 68\u00b0, Yaw 293\u00b0", "value": 38}, {"description": "Pitch 315\u00b0", "value": 39}, {"description": "Roll 90\u00b0, Pitch 315\u00b0", "value": 40}]}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_ACC3_XOFF", "shortDesc": "Accelerometer 3 X-axis offset", "type": "Float", "units": "m/s^2", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_ACC3_XSCALE", "shortDesc": "Accelerometer 3 X-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_ACC3_YOFF", "shortDesc": "Accelerometer 3 Y-axis offset", "type": "Float", "units": "m/s^2", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_ACC3_YSCALE", "shortDesc": "Accelerometer 3 Y-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_ACC3_ZOFF", "shortDesc": "Accelerometer 3 Z-axis offset", "type": "Float", "units": "m/s^2", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_ACC3_ZSCALE", "shortDesc": "Accelerometer 3 Z-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the barometer this calibration applies to.\n", "name": "CAL_BARO0_ID", "shortDesc": "Barometer 0 calibration device ID", "type": "Int32"}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_BARO0_OFF", "shortDesc": "Barometer 0 offset", "type": "Float", "units": "Pa", "volatile": true}, {"category": "System", "default": -1, "group": "Sensor Calibration", "name": "CAL_BARO0_PRIO", "shortDesc": "Barometer 0 priority", "type": "Int32", "values": [{"description": "Uninitialized", "value": -1}, {"description": "Disabled", "value": 0}, {"description": "Min", "value": 1}, {"description": "Low", "value": 25}, {"description": "Medium (Default)", "value": 50}, {"description": "High", "value": 75}, {"description": "Max", "value": 100}]}, {"category": "System", "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the barometer this calibration applies to.\n", "name": "CAL_BARO1_ID", "shortDesc": "Barometer 1 calibration device ID", "type": "Int32"}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_BARO1_OFF", "shortDesc": "Barometer 1 offset", "type": "Float", "units": "Pa", "volatile": true}, {"category": "System", "default": -1, "group": "Sensor Calibration", "name": "CAL_BARO1_PRIO", "shortDesc": "Barometer 1 priority", "type": "Int32", "values": [{"description": "Uninitialized", "value": -1}, {"description": "Disabled", "value": 0}, {"description": "Min", "value": 1}, {"description": "Low", "value": 25}, {"description": "Medium (Default)", "value": 50}, {"description": "High", "value": 75}, {"description": "Max", "value": 100}]}, {"category": "System", "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the barometer this calibration applies to.\n", "name": "CAL_BARO2_ID", "shortDesc": "Barometer 2 calibration device ID", "type": "Int32"}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_BARO2_OFF", "shortDesc": "Barometer 2 offset", "type": "Float", "units": "Pa", "volatile": true}, {"category": "System", "default": -1, "group": "Sensor Calibration", "name": "CAL_BARO2_PRIO", "shortDesc": "Barometer 2 priority", "type": "Int32", "values": [{"description": "Uninitialized", "value": -1}, {"description": "Disabled", "value": 0}, {"description": "Min", "value": 1}, {"description": "Low", "value": 25}, {"description": "Medium (Default)", "value": 50}, {"description": "High", "value": 75}, {"description": "Max", "value": 100}]}, {"category": "System", "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the barometer this calibration applies to.\n", "name": "CAL_BARO3_ID", "shortDesc": "Barometer 3 calibration device ID", "type": "Int32"}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_BARO3_OFF", "shortDesc": "Barometer 3 offset", "type": "Float", "units": "Pa", "volatile": true}, {"category": "System", "default": -1, "group": "Sensor Calibration", "name": "CAL_BARO3_PRIO", "shortDesc": "Barometer 3 priority", "type": "Int32", "values": [{"description": "Uninitialized", "value": -1}, {"description": "Disabled", "value": 0}, {"description": "Min", "value": 1}, {"description": "Low", "value": 25}, {"description": "Medium (Default)", "value": 50}, {"description": "High", "value": 75}, {"description": "Max", "value": 100}]}, {"category": "System", "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the differential pressure sensor this calibration applies to.\n", "name": "CAL_DPRES0_ID", "shortDesc": "Differential pressure sensor 0 calibration device ID", "type": "Int32"}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "The zero-reading of this differential pressure sensor.\n", "name": "CAL_DPRES0_OFF", "shortDesc": "Differential pressure sensor 0 offset", "type": "Float", "units": "Pa", "volatile": true}, {"category": "System", "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the differential pressure sensor this calibration applies to.\n", "name": "CAL_DPRES1_ID", "shortDesc": "Differential pressure sensor 1 calibration device ID", "type": "Int32"}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "The zero-reading of this differential pressure sensor.\n", "name": "CAL_DPRES1_OFF", "shortDesc": "Differential pressure sensor 1 offset", "type": "Float", "units": "Pa", "volatile": true}, {"category": "System", "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the differential pressure sensor this calibration applies to.\n", "name": "CAL_DPRES2_ID", "shortDesc": "Differential pressure sensor 2 calibration device ID", "type": "Int32"}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "The zero-reading of this differential pressure sensor.\n", "name": "CAL_DPRES2_OFF", "shortDesc": "Differential pressure sensor 2 offset", "type": "Float", "units": "Pa", "volatile": true}, {"category": "System", "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the gyroscope this calibration applies to.\n", "name": "CAL_GYRO0_ID", "shortDesc": "Gyroscope 0 calibration device ID", "type": "Int32"}, {"category": "System", "default": -1, "group": "Sensor Calibration", "longDesc": "Uninitialized sensors default to Medium when internal and Low when\nexternal, so an on-board IMU is preferred over one behind a bus.\n\n", "name": "CAL_GYRO0_PRIO", "shortDesc": "Gyroscope 0 priority", "type": "Int32", "values": [{"description": "Uninitialized", "value": -1}, {"description": "Disabled", "value": 0}, {"description": "Min", "value": 1}, {"description": "Low", "value": 25}, {"description": "Medium (Default)", "value": 50}, {"description": "High", "value": 75}, {"description": "Max", "value": 100}]}, {"category": "System", "default": -1, "group": "Sensor Calibration", "longDesc": "An internal sensor will force a value of -1, so a GCS should only attempt to configure the rotation if the value is greater than or equal to zero.\n\n", "max": 40, "min": -1, "name": "CAL_GYRO0_ROT", "shortDesc": "Gyroscope 0 rotation relative to airframe", "type": "Int32", "values": [{"description": "Internal", "value": -1}, {"description": "No rotation", "value": 0}, {"description": "Yaw 45\u00b0", "value": 1}, {"description": "Yaw 90\u00b0", "value": 2}, {"description": "Yaw 135\u00b0", "value": 3}, {"description": "Yaw 180\u00b0", "value": 4}, {"description": "Yaw 225\u00b0", "value": 5}, {"description": "Yaw 270\u00b0", "value": 6}, {"description": "Yaw 315\u00b0", "value": 7}, {"description": "Roll 180\u00b0", "value": 8}, {"description": "Roll 180\u00b0, Yaw 45\u00b0", "value": 9}, {"description": "Roll 180\u00b0, Yaw 90\u00b0", "value": 10}, {"description": "Roll 180\u00b0, Yaw 135\u00b0", "value": 11}, {"description": "Pitch 180\u00b0", "value": 12}, {"description": "Roll 180\u00b0, Yaw 225\u00b0", "value": 13}, {"description": "Roll 180\u00b0, Yaw 270\u00b0", "value": 14}, {"description": "Roll 180\u00b0, Yaw 315\u00b0", "value": 15}, {"description": "Roll 90\u00b0", "value": 16}, {"description": "Roll 90\u00b0, Yaw 45\u00b0", "value": 17}, {"description": "Roll 90\u00b0, Yaw 90\u00b0", "value": 18}, {"description": "Roll 90\u00b0, Yaw 135\u00b0", "value": 19}, {"description": "Roll 270\u00b0", "value": 20}, {"description": "Roll 270\u00b0, Yaw 45\u00b0", "value": 21}, {"description": "Roll 270\u00b0, Yaw 90\u00b0", "value": 22}, {"description": "Roll 270\u00b0, Yaw 135\u00b0", "value": 23}, {"description": "Pitch 90\u00b0", "value": 24}, {"description": "Pitch 270\u00b0", "value": 25}, {"description": "Pitch 180\u00b0, Yaw 90\u00b0", "value": 26}, {"description": "Pitch 180\u00b0, Yaw 270\u00b0", "value": 27}, {"description": "Roll 90\u00b0, Pitch 90\u00b0", "value": 28}, {"description": "Roll 180\u00b0, Pitch 90\u00b0", "value": 29}, {"description": "Roll 270\u00b0, Pitch 90\u00b0", "value": 30}, {"description": "Roll 90\u00b0, Pitch 180\u00b0", "value": 31}, {"description": "Roll 270\u00b0, Pitch 180\u00b0", "value": 32}, {"description": "Roll 90\u00b0, Pitch 270\u00b0", "value": 33}, {"description": "Roll 180\u00b0, Pitch 270\u00b0", "value": 34}, {"description": "Roll 270\u00b0, Pitch 270\u00b0", "value": 35}, {"description": "Roll 90\u00b0, Pitch 180\u00b0, Yaw 90\u00b0", "value": 36}, {"description": "Roll 90\u00b0, Yaw 270\u00b0", "value": 37}, {"description": "Roll 90\u00b0, Pitch 68\u00b0, Yaw 293\u00b0", "value": 38}, {"description": "Pitch 315\u00b0", "value": 39}, {"description": "Roll 90\u00b0, Pitch 315\u00b0", "value": 40}]}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_GYRO0_XOFF", "shortDesc": "Gyroscope 0 X-axis offset", "type": "Float", "units": "rad/s", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_GYRO0_YOFF", "shortDesc": "Gyroscope 0 Y-axis offset", "type": "Float", "units": "rad/s", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_GYRO0_ZOFF", "shortDesc": "Gyroscope 0 Z-axis offset", "type": "Float", "units": "rad/s", "volatile": true}, {"category": "System", "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the gyroscope this calibration applies to.\n", "name": "CAL_GYRO1_ID", "shortDesc": "Gyroscope 1 calibration device ID", "type": "Int32"}, {"category": "System", "default": -1, "group": "Sensor Calibration", "longDesc": "Uninitialized sensors default to Medium when internal and Low when\nexternal, so an on-board IMU is preferred over one behind a bus.\n\n", "name": "CAL_GYRO1_PRIO", "shortDesc": "Gyroscope 1 priority", "type": "Int32", "values": [{"description": "Uninitialized", "value": -1}, {"description": "Disabled", "value": 0}, {"description": "Min", "value": 1}, {"description": "Low", "value": 25}, {"description": "Medium (Default)", "value": 50}, {"description": "High", "value": 75}, {"description": "Max", "value": 100}]}, {"category": "System", "default": -1, "group": "Sensor Calibration", "longDesc": "An internal sensor will force a value of -1, so a GCS should only attempt to configure the rotation if the value is greater than or equal to zero.\n\n", "max": 40, "min": -1, "name": "CAL_GYRO1_ROT", "shortDesc": "Gyroscope 1 rotation relative to airframe", "type": "Int32", "values": [{"description": "Internal", "value": -1}, {"description": "No rotation", "value": 0}, {"description": "Yaw 45\u00b0", "value": 1}, {"description": "Yaw 90\u00b0", "value": 2}, {"description": "Yaw 135\u00b0", "value": 3}, {"description": "Yaw 180\u00b0", "value": 4}, {"description": "Yaw 225\u00b0", "value": 5}, {"description": "Yaw 270\u00b0", "value": 6}, {"description": "Yaw 315\u00b0", "value": 7}, {"description": "Roll 180\u00b0", "value": 8}, {"description": "Roll 180\u00b0, Yaw 45\u00b0", "value": 9}, {"description": "Roll 180\u00b0, Yaw 90\u00b0", "value": 10}, {"description": "Roll 180\u00b0, Yaw 135\u00b0", "value": 11}, {"description": "Pitch 180\u00b0", "value": 12}, {"description": "Roll 180\u00b0, Yaw 225\u00b0", "value": 13}, {"description": "Roll 180\u00b0, Yaw 270\u00b0", "value": 14}, {"description": "Roll 180\u00b0, Yaw 315\u00b0", "value": 15}, {"description": "Roll 90\u00b0", "value": 16}, {"description": "Roll 90\u00b0, Yaw 45\u00b0", "value": 17}, {"description": "Roll 90\u00b0, Yaw 90\u00b0", "value": 18}, {"description": "Roll 90\u00b0, Yaw 135\u00b0", "value": 19}, {"description": "Roll 270\u00b0", "value": 20}, {"description": "Roll 270\u00b0, Yaw 45\u00b0", "value": 21}, {"description": "Roll 270\u00b0, Yaw 90\u00b0", "value": 22}, {"description": "Roll 270\u00b0, Yaw 135\u00b0", "value": 23}, {"description": "Pitch 90\u00b0", "value": 24}, {"description": "Pitch 270\u00b0", "value": 25}, {"description": "Pitch 180\u00b0, Yaw 90\u00b0", "value": 26}, {"description": "Pitch 180\u00b0, Yaw 270\u00b0", "value": 27}, {"description": "Roll 90\u00b0, Pitch 90\u00b0", "value": 28}, {"description": "Roll 180\u00b0, Pitch 90\u00b0", "value": 29}, {"description": "Roll 270\u00b0, Pitch 90\u00b0", "value": 30}, {"description": "Roll 90\u00b0, Pitch 180\u00b0", "value": 31}, {"description": "Roll 270\u00b0, Pitch 180\u00b0", "value": 32}, {"description": "Roll 90\u00b0, Pitch 270\u00b0", "value": 33}, {"description": "Roll 180\u00b0, Pitch 270\u00b0", "value": 34}, {"description": "Roll 270\u00b0, Pitch 270\u00b0", "value": 35}, {"description": "Roll 90\u00b0, Pitch 180\u00b0, Yaw 90\u00b0", "value": 36}, {"description": "Roll 90\u00b0, Yaw 270\u00b0", "value": 37}, {"description": "Roll 90\u00b0, Pitch 68\u00b0, Yaw 293\u00b0", "value": 38}, {"description": "Pitch 315\u00b0", "value": 39}, {"description": "Roll 90\u00b0, Pitch 315\u00b0", "value": 40}]}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_GYRO1_XOFF", "shortDesc": "Gyroscope 1 X-axis offset", "type": "Float", "units": "rad/s", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_GYRO1_YOFF", "shortDesc": "Gyroscope 1 Y-axis offset", "type": "Float", "units": "rad/s", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_GYRO1_ZOFF", "shortDesc": "Gyroscope 1 Z-axis offset", "type": "Float", "units": "rad/s", "volatile": true}, {"category": "System", "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the gyroscope this calibration applies to.\n", "name": "CAL_GYRO2_ID", "shortDesc": "Gyroscope 2 calibration device ID", "type": "Int32"}, {"category": "System", "default": -1, "group": "Sensor Calibration", "longDesc": "Uninitialized sensors default to Medium when internal and Low when\nexternal, so an on-board IMU is preferred over one behind a bus.\n\n", "name": "CAL_GYRO2_PRIO", "shortDesc": "Gyroscope 2 priority", "type": "Int32", "values": [{"description": "Uninitialized", "value": -1}, {"description": "Disabled", "value": 0}, {"description": "Min", "value": 1}, {"description": "Low", "value": 25}, {"description": "Medium (Default)", "value": 50}, {"description": "High", "value": 75}, {"description": "Max", "value": 100}]}, {"category": "System", "default": -1, "group": "Sensor Calibration", "longDesc": "An internal sensor will force a value of -1, so a GCS should only attempt to configure the rotation if the value is greater than or equal to zero.\n\n", "max": 40, "min": -1, "name": "CAL_GYRO2_ROT", "shortDesc": "Gyroscope 2 rotation relative to airframe", "type": "Int32", "values": [{"description": "Internal", "value": -1}, {"description": "No rotation", "value": 0}, {"description": "Yaw 45\u00b0", "value": 1}, {"description": "Yaw 90\u00b0", "value": 2}, {"description": "Yaw 135\u00b0", "value": 3}, {"description": "Yaw 180\u00b0", "value": 4}, {"description": "Yaw 225\u00b0", "value": 5}, {"description": "Yaw 270\u00b0", "value": 6}, {"description": "Yaw 315\u00b0", "value": 7}, {"description": "Roll 180\u00b0", "value": 8}, {"description": "Roll 180\u00b0, Yaw 45\u00b0", "value": 9}, {"description": "Roll 180\u00b0, Yaw 90\u00b0", "value": 10}, {"description": "Roll 180\u00b0, Yaw 135\u00b0", "value": 11}, {"description": "Pitch 180\u00b0", "value": 12}, {"description": "Roll 180\u00b0, Yaw 225\u00b0", "value": 13}, {"description": "Roll 180\u00b0, Yaw 270\u00b0", "value": 14}, {"description": "Roll 180\u00b0, Yaw 315\u00b0", "value": 15}, {"description": "Roll 90\u00b0", "value": 16}, {"description": "Roll 90\u00b0, Yaw 45\u00b0", "value": 17}, {"description": "Roll 90\u00b0, Yaw 90\u00b0", "value": 18}, {"description": "Roll 90\u00b0, Yaw 135\u00b0", "value": 19}, {"description": "Roll 270\u00b0", "value": 20}, {"description": "Roll 270\u00b0, Yaw 45\u00b0", "value": 21}, {"description": "Roll 270\u00b0, Yaw 90\u00b0", "value": 22}, {"description": "Roll 270\u00b0, Yaw 135\u00b0", "value": 23}, {"description": "Pitch 90\u00b0", "value": 24}, {"description": "Pitch 270\u00b0", "value": 25}, {"description": "Pitch 180\u00b0, Yaw 90\u00b0", "value": 26}, {"description": "Pitch 180\u00b0, Yaw 270\u00b0", "value": 27}, {"description": "Roll 90\u00b0, Pitch 90\u00b0", "value": 28}, {"description": "Roll 180\u00b0, Pitch 90\u00b0", "value": 29}, {"description": "Roll 270\u00b0, Pitch 90\u00b0", "value": 30}, {"description": "Roll 90\u00b0, Pitch 180\u00b0", "value": 31}, {"description": "Roll 270\u00b0, Pitch 180\u00b0", "value": 32}, {"description": "Roll 90\u00b0, Pitch 270\u00b0", "value": 33}, {"description": "Roll 180\u00b0, Pitch 270\u00b0", "value": 34}, {"description": "Roll 270\u00b0, Pitch 270\u00b0", "value": 35}, {"description": "Roll 90\u00b0, Pitch 180\u00b0, Yaw 90\u00b0", "value": 36}, {"description": "Roll 90\u00b0, Yaw 270\u00b0", "value": 37}, {"description": "Roll 90\u00b0, Pitch 68\u00b0, Yaw 293\u00b0", "value": 38}, {"description": "Pitch 315\u00b0", "value": 39}, {"description": "Roll 90\u00b0, Pitch 315\u00b0", "value": 40}]}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_GYRO2_XOFF", "shortDesc": "Gyroscope 2 X-axis offset", "type": "Float", "units": "rad/s", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_GYRO2_YOFF", "shortDesc": "Gyroscope 2 Y-axis offset", "type": "Float", "units": "rad/s", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_GYRO2_ZOFF", "shortDesc": "Gyroscope 2 Z-axis offset", "type": "Float", "units": "rad/s", "volatile": true}, {"category": "System", "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the gyroscope this calibration applies to.\n", "name": "CAL_GYRO3_ID", "shortDesc": "Gyroscope 3 calibration device ID", "type": "Int32"}, {"category": "System", "default": -1, "group": "Sensor Calibration", "longDesc": "Uninitialized sensors default to Medium when internal and Low when\nexternal, so an on-board IMU is preferred over one behind a bus.\n\n", "name": "CAL_GYRO3_PRIO", "shortDesc": "Gyroscope 3 priority", "type": "Int32", "values": [{"description": "Uninitialized", "value": -1}, {"description": "Disabled", "value": 0}, {"description": "Min", "value": 1}, {"description": "Low", "value": 25}, {"description": "Medium (Default)", "value": 50}, {"description": "High", "value": 75}, {"description": "Max", "value": 100}]}, {"category": "System", "default": -1, "group": "Sensor Calibration", "longDesc": "An internal sensor will force a value of -1, so a GCS should only attempt to configure the rotation if the value is greater than or equal to zero.\n\n", "max": 40, "min": -1, "name": "CAL_GYRO3_ROT", "shortDesc": "Gyroscope 3 rotation relative to airframe", "type": "Int32", "values": [{"description": "Internal", "value": -1}, {"description": "No rotation", "value": 0}, {"description": "Yaw 45\u00b0", "value": 1}, {"description": "Yaw 90\u00b0", "value": 2}, {"description": "Yaw 135\u00b0", "value": 3}, {"description": "Yaw 180\u00b0", "value": 4}, {"description": "Yaw 225\u00b0", "value": 5}, {"description": "Yaw 270\u00b0", "value": 6}, {"description": "Yaw 315\u00b0", "value": 7}, {"description": "Roll 180\u00b0", "value": 8}, {"description": "Roll 180\u00b0, Yaw 45\u00b0", "value": 9}, {"description": "Roll 180\u00b0, Yaw 90\u00b0", "value": 10}, {"description": "Roll 180\u00b0, Yaw 135\u00b0", "value": 11}, {"description": "Pitch 180\u00b0", "value": 12}, {"description": "Roll 180\u00b0, Yaw 225\u00b0", "value": 13}, {"description": "Roll 180\u00b0, Yaw 270\u00b0", "value": 14}, {"description": "Roll 180\u00b0, Yaw 315\u00b0", "value": 15}, {"description": "Roll 90\u00b0", "value": 16}, {"description": "Roll 90\u00b0, Yaw 45\u00b0", "value": 17}, {"description": "Roll 90\u00b0, Yaw 90\u00b0", "value": 18}, {"description": "Roll 90\u00b0, Yaw 135\u00b0", "value": 19}, {"description": "Roll 270\u00b0", "value": 20}, {"description": "Roll 270\u00b0, Yaw 45\u00b0", "value": 21}, {"description": "Roll 270\u00b0, Yaw 90\u00b0", "value": 22}, {"description": "Roll 270\u00b0, Yaw 135\u00b0", "value": 23}, {"description": "Pitch 90\u00b0", "value": 24}, {"description": "Pitch 270\u00b0", "value": 25}, {"description": "Pitch 180\u00b0, Yaw 90\u00b0", "value": 26}, {"description": "Pitch 180\u00b0, Yaw 270\u00b0", "value": 27}, {"description": "Roll 90\u00b0, Pitch 90\u00b0", "value": 28}, {"description": "Roll 180\u00b0, Pitch 90\u00b0", "value": 29}, {"description": "Roll 270\u00b0, Pitch 90\u00b0", "value": 30}, {"description": "Roll 90\u00b0, Pitch 180\u00b0", "value": 31}, {"description": "Roll 270\u00b0, Pitch 180\u00b0", "value": 32}, {"description": "Roll 90\u00b0, Pitch 270\u00b0", "value": 33}, {"description": "Roll 180\u00b0, Pitch 270\u00b0", "value": 34}, {"description": "Roll 270\u00b0, Pitch 270\u00b0", "value": 35}, {"description": "Roll 90\u00b0, Pitch 180\u00b0, Yaw 90\u00b0", "value": 36}, {"description": "Roll 90\u00b0, Yaw 270\u00b0", "value": 37}, {"description": "Roll 90\u00b0, Pitch 68\u00b0, Yaw 293\u00b0", "value": 38}, {"description": "Pitch 315\u00b0", "value": 39}, {"description": "Roll 90\u00b0, Pitch 315\u00b0", "value": 40}]}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_GYRO3_XOFF", "shortDesc": "Gyroscope 3 X-axis offset", "type": "Float", "units": "rad/s", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_GYRO3_YOFF", "shortDesc": "Gyroscope 3 Y-axis offset", "type": "Float", "units": "rad/s", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_GYRO3_ZOFF", "shortDesc": "Gyroscope 3 Z-axis offset", "type": "Float", "units": "rad/s", "volatile": true}, {"category": "System", "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the magnetometer this calibration applies to.\n", "name": "CAL_MAG0_ID", "shortDesc": "Magnetometer 0 calibration device ID", "type": "Int32"}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "longDesc": "Setting this parameter changes CAL_MAG0_ROT to \"Custom Euler Angle\"\n", "max": 180.0, "min": -180.0, "name": "CAL_MAG0_PITCH", "shortDesc": "Magnetometer 0 Custom Euler Pitch Angle", "type": "Float", "units": "deg"}, {"category": "System", "default": -1, "group": "Sensor Calibration", "name": "CAL_MAG0_PRIO", "shortDesc": "Magnetometer 0 priority", "type": "Int32", "values": [{"description": "Uninitialized", "value": -1}, {"description": "Disabled", "value": 0}, {"description": "Min", "value": 1}, {"description": "Low", "value": 25}, {"description": "Medium (Default)", "value": 50}, {"description": "High", "value": 75}, {"description": "Max", "value": 100}]}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "longDesc": "Setting this parameter changes CAL_MAG0_ROT to \"Custom Euler Angle\"\n", "max": 180.0, "min": -180.0, "name": "CAL_MAG0_ROLL", "shortDesc": "Magnetometer 0 Custom Euler Roll Angle", "type": "Float", "units": "deg"}, {"category": "System", "default": -1, "group": "Sensor Calibration", "longDesc": "An internal sensor will force a value of -1, so a GCS should only attempt to configure the rotation if the value is greater than or equal to zero.\nSet to \"Custom Euler Angle\" to define the rotation using CAL_MAG0_ROLL, CAL_MAG0_PITCH and CAL_MAG0_YAW.\n\n", "max": 100, "min": -1, "name": "CAL_MAG0_ROT", "shortDesc": "Magnetometer 0 rotation relative to airframe", "type": "Int32", "values": [{"description": "Internal", "value": -1}, {"description": "No rotation", "value": 0}, {"description": "Yaw 45\u00b0", "value": 1}, {"description": "Yaw 90\u00b0", "value": 2}, {"description": "Yaw 135\u00b0", "value": 3}, {"description": "Yaw 180\u00b0", "value": 4}, {"description": "Yaw 225\u00b0", "value": 5}, {"description": "Yaw 270\u00b0", "value": 6}, {"description": "Yaw 315\u00b0", "value": 7}, {"description": "Roll 180\u00b0", "value": 8}, {"description": "Roll 180\u00b0, Yaw 45\u00b0", "value": 9}, {"description": "Roll 180\u00b0, Yaw 90\u00b0", "value": 10}, {"description": "Roll 180\u00b0, Yaw 135\u00b0", "value": 11}, {"description": "Pitch 180\u00b0", "value": 12}, {"description": "Roll 180\u00b0, Yaw 225\u00b0", "value": 13}, {"description": "Roll 180\u00b0, Yaw 270\u00b0", "value": 14}, {"description": "Roll 180\u00b0, Yaw 315\u00b0", "value": 15}, {"description": "Roll 90\u00b0", "value": 16}, {"description": "Roll 90\u00b0, Yaw 45\u00b0", "value": 17}, {"description": "Roll 90\u00b0, Yaw 90\u00b0", "value": 18}, {"description": "Roll 90\u00b0, Yaw 135\u00b0", "value": 19}, {"description": "Roll 270\u00b0", "value": 20}, {"description": "Roll 270\u00b0, Yaw 45\u00b0", "value": 21}, {"description": "Roll 270\u00b0, Yaw 90\u00b0", "value": 22}, {"description": "Roll 270\u00b0, Yaw 135\u00b0", "value": 23}, {"description": "Pitch 90\u00b0", "value": 24}, {"description": "Pitch 270\u00b0", "value": 25}, {"description": "Pitch 180\u00b0, Yaw 90\u00b0", "value": 26}, {"description": "Pitch 180\u00b0, Yaw 270\u00b0", "value": 27}, {"description": "Roll 90\u00b0, Pitch 90\u00b0", "value": 28}, {"description": "Roll 180\u00b0, Pitch 90\u00b0", "value": 29}, {"description": "Roll 270\u00b0, Pitch 90\u00b0", "value": 30}, {"description": "Roll 90\u00b0, Pitch 180\u00b0", "value": 31}, {"description": "Roll 270\u00b0, Pitch 180\u00b0", "value": 32}, {"description": "Roll 90\u00b0, Pitch 270\u00b0", "value": 33}, {"description": "Roll 180\u00b0, Pitch 270\u00b0", "value": 34}, {"description": "Roll 270\u00b0, Pitch 270\u00b0", "value": 35}, {"description": "Roll 90\u00b0, Pitch 180\u00b0, Yaw 90\u00b0", "value": 36}, {"description": "Roll 90\u00b0, Yaw 270\u00b0", "value": 37}, {"description": "Roll 90\u00b0, Pitch 68\u00b0, Yaw 293\u00b0", "value": 38}, {"description": "Pitch 315\u00b0", "value": 39}, {"description": "Roll 90\u00b0, Pitch 315\u00b0", "value": 40}, {"description": "Custom Euler Angle", "value": 100}]}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "Coefficient describing linear relationship between\nX component of magnetometer in body frame axis\nand either current or throttle depending on value of CAL_MAG_COMP_TYP.\nUnit for throttle-based compensation is [G] and\nfor current-based compensation [G/kA]\n\n", "name": "CAL_MAG0_XCOMP", "shortDesc": "Magnetometer 0 X Axis throttle compensation", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG0_XODIAG", "shortDesc": "Magnetometer 0 X-axis off diagonal scale factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG0_XOFF", "shortDesc": "Magnetometer 0 X-axis offset", "type": "Float", "units": "gauss", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_MAG0_XSCALE", "shortDesc": "Magnetometer 0 X-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "longDesc": "Setting this parameter changes CAL_MAG0_ROT to \"Custom Euler Angle\"\n", "max": 180.0, "min": -180.0, "name": "CAL_MAG0_YAW", "shortDesc": "Magnetometer 0 Custom Euler Yaw Angle", "type": "Float", "units": "deg"}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "Coefficient describing linear relationship between\nY component of magnetometer in body frame axis\nand either current or throttle depending on value of CAL_MAG_COMP_TYP.\nUnit for throttle-based compensation is [G] and\nfor current-based compensation [G/kA]\n\n", "name": "CAL_MAG0_YCOMP", "shortDesc": "Magnetometer 0 Y Axis throttle compensation", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG0_YODIAG", "shortDesc": "Magnetometer 0 Y-axis off diagonal scale factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG0_YOFF", "shortDesc": "Magnetometer 0 Y-axis offset", "type": "Float", "units": "gauss", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_MAG0_YSCALE", "shortDesc": "Magnetometer 0 Y-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "Coefficient describing linear relationship between\nZ component of magnetometer in body frame axis\nand either current or throttle depending on value of CAL_MAG_COMP_TYP.\nUnit for throttle-based compensation is [G] and\nfor current-based compensation [G/kA]\n\n", "name": "CAL_MAG0_ZCOMP", "shortDesc": "Magnetometer 0 Z Axis throttle compensation", "type": "Float", "volatile": true}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG0_ZODIAG", "shortDesc": "Magnetometer 0 Z-axis off diagonal scale factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG0_ZOFF", "shortDesc": "Magnetometer 0 Z-axis offset", "type": "Float", "units": "gauss", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_MAG0_ZSCALE", "shortDesc": "Magnetometer 0 Z-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the magnetometer this calibration applies to.\n", "name": "CAL_MAG1_ID", "shortDesc": "Magnetometer 1 calibration device ID", "type": "Int32"}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "longDesc": "Setting this parameter changes CAL_MAG1_ROT to \"Custom Euler Angle\"\n", "max": 180.0, "min": -180.0, "name": "CAL_MAG1_PITCH", "shortDesc": "Magnetometer 1 Custom Euler Pitch Angle", "type": "Float", "units": "deg"}, {"category": "System", "default": -1, "group": "Sensor Calibration", "name": "CAL_MAG1_PRIO", "shortDesc": "Magnetometer 1 priority", "type": "Int32", "values": [{"description": "Uninitialized", "value": -1}, {"description": "Disabled", "value": 0}, {"description": "Min", "value": 1}, {"description": "Low", "value": 25}, {"description": "Medium (Default)", "value": 50}, {"description": "High", "value": 75}, {"description": "Max", "value": 100}]}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "longDesc": "Setting this parameter changes CAL_MAG1_ROT to \"Custom Euler Angle\"\n", "max": 180.0, "min": -180.0, "name": "CAL_MAG1_ROLL", "shortDesc": "Magnetometer 1 Custom Euler Roll Angle", "type": "Float", "units": "deg"}, {"category": "System", "default": -1, "group": "Sensor Calibration", "longDesc": "An internal sensor will force a value of -1, so a GCS should only attempt to configure the rotation if the value is greater than or equal to zero.\nSet to \"Custom Euler Angle\" to define the rotation using CAL_MAG1_ROLL, CAL_MAG1_PITCH and CAL_MAG1_YAW.\n\n", "max": 100, "min": -1, "name": "CAL_MAG1_ROT", "shortDesc": "Magnetometer 1 rotation relative to airframe", "type": "Int32", "values": [{"description": "Internal", "value": -1}, {"description": "No rotation", "value": 0}, {"description": "Yaw 45\u00b0", "value": 1}, {"description": "Yaw 90\u00b0", "value": 2}, {"description": "Yaw 135\u00b0", "value": 3}, {"description": "Yaw 180\u00b0", "value": 4}, {"description": "Yaw 225\u00b0", "value": 5}, {"description": "Yaw 270\u00b0", "value": 6}, {"description": "Yaw 315\u00b0", "value": 7}, {"description": "Roll 180\u00b0", "value": 8}, {"description": "Roll 180\u00b0, Yaw 45\u00b0", "value": 9}, {"description": "Roll 180\u00b0, Yaw 90\u00b0", "value": 10}, {"description": "Roll 180\u00b0, Yaw 135\u00b0", "value": 11}, {"description": "Pitch 180\u00b0", "value": 12}, {"description": "Roll 180\u00b0, Yaw 225\u00b0", "value": 13}, {"description": "Roll 180\u00b0, Yaw 270\u00b0", "value": 14}, {"description": "Roll 180\u00b0, Yaw 315\u00b0", "value": 15}, {"description": "Roll 90\u00b0", "value": 16}, {"description": "Roll 90\u00b0, Yaw 45\u00b0", "value": 17}, {"description": "Roll 90\u00b0, Yaw 90\u00b0", "value": 18}, {"description": "Roll 90\u00b0, Yaw 135\u00b0", "value": 19}, {"description": "Roll 270\u00b0", "value": 20}, {"description": "Roll 270\u00b0, Yaw 45\u00b0", "value": 21}, {"description": "Roll 270\u00b0, Yaw 90\u00b0", "value": 22}, {"description": "Roll 270\u00b0, Yaw 135\u00b0", "value": 23}, {"description": "Pitch 90\u00b0", "value": 24}, {"description": "Pitch 270\u00b0", "value": 25}, {"description": "Pitch 180\u00b0, Yaw 90\u00b0", "value": 26}, {"description": "Pitch 180\u00b0, Yaw 270\u00b0", "value": 27}, {"description": "Roll 90\u00b0, Pitch 90\u00b0", "value": 28}, {"description": "Roll 180\u00b0, Pitch 90\u00b0", "value": 29}, {"description": "Roll 270\u00b0, Pitch 90\u00b0", "value": 30}, {"description": "Roll 90\u00b0, Pitch 180\u00b0", "value": 31}, {"description": "Roll 270\u00b0, Pitch 180\u00b0", "value": 32}, {"description": "Roll 90\u00b0, Pitch 270\u00b0", "value": 33}, {"description": "Roll 180\u00b0, Pitch 270\u00b0", "value": 34}, {"description": "Roll 270\u00b0, Pitch 270\u00b0", "value": 35}, {"description": "Roll 90\u00b0, Pitch 180\u00b0, Yaw 90\u00b0", "value": 36}, {"description": "Roll 90\u00b0, Yaw 270\u00b0", "value": 37}, {"description": "Roll 90\u00b0, Pitch 68\u00b0, Yaw 293\u00b0", "value": 38}, {"description": "Pitch 315\u00b0", "value": 39}, {"description": "Roll 90\u00b0, Pitch 315\u00b0", "value": 40}, {"description": "Custom Euler Angle", "value": 100}]}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "Coefficient describing linear relationship between\nX component of magnetometer in body frame axis\nand either current or throttle depending on value of CAL_MAG_COMP_TYP.\nUnit for throttle-based compensation is [G] and\nfor current-based compensation [G/kA]\n\n", "name": "CAL_MAG1_XCOMP", "shortDesc": "Magnetometer 1 X Axis throttle compensation", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG1_XODIAG", "shortDesc": "Magnetometer 1 X-axis off diagonal scale factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG1_XOFF", "shortDesc": "Magnetometer 1 X-axis offset", "type": "Float", "units": "gauss", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_MAG1_XSCALE", "shortDesc": "Magnetometer 1 X-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "longDesc": "Setting this parameter changes CAL_MAG1_ROT to \"Custom Euler Angle\"\n", "max": 180.0, "min": -180.0, "name": "CAL_MAG1_YAW", "shortDesc": "Magnetometer 1 Custom Euler Yaw Angle", "type": "Float", "units": "deg"}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "Coefficient describing linear relationship between\nY component of magnetometer in body frame axis\nand either current or throttle depending on value of CAL_MAG_COMP_TYP.\nUnit for throttle-based compensation is [G] and\nfor current-based compensation [G/kA]\n\n", "name": "CAL_MAG1_YCOMP", "shortDesc": "Magnetometer 1 Y Axis throttle compensation", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG1_YODIAG", "shortDesc": "Magnetometer 1 Y-axis off diagonal scale factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG1_YOFF", "shortDesc": "Magnetometer 1 Y-axis offset", "type": "Float", "units": "gauss", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_MAG1_YSCALE", "shortDesc": "Magnetometer 1 Y-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "Coefficient describing linear relationship between\nZ component of magnetometer in body frame axis\nand either current or throttle depending on value of CAL_MAG_COMP_TYP.\nUnit for throttle-based compensation is [G] and\nfor current-based compensation [G/kA]\n\n", "name": "CAL_MAG1_ZCOMP", "shortDesc": "Magnetometer 1 Z Axis throttle compensation", "type": "Float", "volatile": true}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG1_ZODIAG", "shortDesc": "Magnetometer 1 Z-axis off diagonal scale factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG1_ZOFF", "shortDesc": "Magnetometer 1 Z-axis offset", "type": "Float", "units": "gauss", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_MAG1_ZSCALE", "shortDesc": "Magnetometer 1 Z-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the magnetometer this calibration applies to.\n", "name": "CAL_MAG2_ID", "shortDesc": "Magnetometer 2 calibration device ID", "type": "Int32"}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "longDesc": "Setting this parameter changes CAL_MAG2_ROT to \"Custom Euler Angle\"\n", "max": 180.0, "min": -180.0, "name": "CAL_MAG2_PITCH", "shortDesc": "Magnetometer 2 Custom Euler Pitch Angle", "type": "Float", "units": "deg"}, {"category": "System", "default": -1, "group": "Sensor Calibration", "name": "CAL_MAG2_PRIO", "shortDesc": "Magnetometer 2 priority", "type": "Int32", "values": [{"description": "Uninitialized", "value": -1}, {"description": "Disabled", "value": 0}, {"description": "Min", "value": 1}, {"description": "Low", "value": 25}, {"description": "Medium (Default)", "value": 50}, {"description": "High", "value": 75}, {"description": "Max", "value": 100}]}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "longDesc": "Setting this parameter changes CAL_MAG2_ROT to \"Custom Euler Angle\"\n", "max": 180.0, "min": -180.0, "name": "CAL_MAG2_ROLL", "shortDesc": "Magnetometer 2 Custom Euler Roll Angle", "type": "Float", "units": "deg"}, {"category": "System", "default": -1, "group": "Sensor Calibration", "longDesc": "An internal sensor will force a value of -1, so a GCS should only attempt to configure the rotation if the value is greater than or equal to zero.\nSet to \"Custom Euler Angle\" to define the rotation using CAL_MAG2_ROLL, CAL_MAG2_PITCH and CAL_MAG2_YAW.\n\n", "max": 100, "min": -1, "name": "CAL_MAG2_ROT", "shortDesc": "Magnetometer 2 rotation relative to airframe", "type": "Int32", "values": [{"description": "Internal", "value": -1}, {"description": "No rotation", "value": 0}, {"description": "Yaw 45\u00b0", "value": 1}, {"description": "Yaw 90\u00b0", "value": 2}, {"description": "Yaw 135\u00b0", "value": 3}, {"description": "Yaw 180\u00b0", "value": 4}, {"description": "Yaw 225\u00b0", "value": 5}, {"description": "Yaw 270\u00b0", "value": 6}, {"description": "Yaw 315\u00b0", "value": 7}, {"description": "Roll 180\u00b0", "value": 8}, {"description": "Roll 180\u00b0, Yaw 45\u00b0", "value": 9}, {"description": "Roll 180\u00b0, Yaw 90\u00b0", "value": 10}, {"description": "Roll 180\u00b0, Yaw 135\u00b0", "value": 11}, {"description": "Pitch 180\u00b0", "value": 12}, {"description": "Roll 180\u00b0, Yaw 225\u00b0", "value": 13}, {"description": "Roll 180\u00b0, Yaw 270\u00b0", "value": 14}, {"description": "Roll 180\u00b0, Yaw 315\u00b0", "value": 15}, {"description": "Roll 90\u00b0", "value": 16}, {"description": "Roll 90\u00b0, Yaw 45\u00b0", "value": 17}, {"description": "Roll 90\u00b0, Yaw 90\u00b0", "value": 18}, {"description": "Roll 90\u00b0, Yaw 135\u00b0", "value": 19}, {"description": "Roll 270\u00b0", "value": 20}, {"description": "Roll 270\u00b0, Yaw 45\u00b0", "value": 21}, {"description": "Roll 270\u00b0, Yaw 90\u00b0", "value": 22}, {"description": "Roll 270\u00b0, Yaw 135\u00b0", "value": 23}, {"description": "Pitch 90\u00b0", "value": 24}, {"description": "Pitch 270\u00b0", "value": 25}, {"description": "Pitch 180\u00b0, Yaw 90\u00b0", "value": 26}, {"description": "Pitch 180\u00b0, Yaw 270\u00b0", "value": 27}, {"description": "Roll 90\u00b0, Pitch 90\u00b0", "value": 28}, {"description": "Roll 180\u00b0, Pitch 90\u00b0", "value": 29}, {"description": "Roll 270\u00b0, Pitch 90\u00b0", "value": 30}, {"description": "Roll 90\u00b0, Pitch 180\u00b0", "value": 31}, {"description": "Roll 270\u00b0, Pitch 180\u00b0", "value": 32}, {"description": "Roll 90\u00b0, Pitch 270\u00b0", "value": 33}, {"description": "Roll 180\u00b0, Pitch 270\u00b0", "value": 34}, {"description": "Roll 270\u00b0, Pitch 270\u00b0", "value": 35}, {"description": "Roll 90\u00b0, Pitch 180\u00b0, Yaw 90\u00b0", "value": 36}, {"description": "Roll 90\u00b0, Yaw 270\u00b0", "value": 37}, {"description": "Roll 90\u00b0, Pitch 68\u00b0, Yaw 293\u00b0", "value": 38}, {"description": "Pitch 315\u00b0", "value": 39}, {"description": "Roll 90\u00b0, Pitch 315\u00b0", "value": 40}, {"description": "Custom Euler Angle", "value": 100}]}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "Coefficient describing linear relationship between\nX component of magnetometer in body frame axis\nand either current or throttle depending on value of CAL_MAG_COMP_TYP.\nUnit for throttle-based compensation is [G] and\nfor current-based compensation [G/kA]\n\n", "name": "CAL_MAG2_XCOMP", "shortDesc": "Magnetometer 2 X Axis throttle compensation", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG2_XODIAG", "shortDesc": "Magnetometer 2 X-axis off diagonal scale factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG2_XOFF", "shortDesc": "Magnetometer 2 X-axis offset", "type": "Float", "units": "gauss", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_MAG2_XSCALE", "shortDesc": "Magnetometer 2 X-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "longDesc": "Setting this parameter changes CAL_MAG2_ROT to \"Custom Euler Angle\"\n", "max": 180.0, "min": -180.0, "name": "CAL_MAG2_YAW", "shortDesc": "Magnetometer 2 Custom Euler Yaw Angle", "type": "Float", "units": "deg"}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "Coefficient describing linear relationship between\nY component of magnetometer in body frame axis\nand either current or throttle depending on value of CAL_MAG_COMP_TYP.\nUnit for throttle-based compensation is [G] and\nfor current-based compensation [G/kA]\n\n", "name": "CAL_MAG2_YCOMP", "shortDesc": "Magnetometer 2 Y Axis throttle compensation", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG2_YODIAG", "shortDesc": "Magnetometer 2 Y-axis off diagonal scale factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG2_YOFF", "shortDesc": "Magnetometer 2 Y-axis offset", "type": "Float", "units": "gauss", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_MAG2_YSCALE", "shortDesc": "Magnetometer 2 Y-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "Coefficient describing linear relationship between\nZ component of magnetometer in body frame axis\nand either current or throttle depending on value of CAL_MAG_COMP_TYP.\nUnit for throttle-based compensation is [G] and\nfor current-based compensation [G/kA]\n\n", "name": "CAL_MAG2_ZCOMP", "shortDesc": "Magnetometer 2 Z Axis throttle compensation", "type": "Float", "volatile": true}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG2_ZODIAG", "shortDesc": "Magnetometer 2 Z-axis off diagonal scale factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG2_ZOFF", "shortDesc": "Magnetometer 2 Z-axis offset", "type": "Float", "units": "gauss", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_MAG2_ZSCALE", "shortDesc": "Magnetometer 2 Z-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the magnetometer this calibration applies to.\n", "name": "CAL_MAG3_ID", "shortDesc": "Magnetometer 3 calibration device ID", "type": "Int32"}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "longDesc": "Setting this parameter changes CAL_MAG3_ROT to \"Custom Euler Angle\"\n", "max": 180.0, "min": -180.0, "name": "CAL_MAG3_PITCH", "shortDesc": "Magnetometer 3 Custom Euler Pitch Angle", "type": "Float", "units": "deg"}, {"category": "System", "default": -1, "group": "Sensor Calibration", "name": "CAL_MAG3_PRIO", "shortDesc": "Magnetometer 3 priority", "type": "Int32", "values": [{"description": "Uninitialized", "value": -1}, {"description": "Disabled", "value": 0}, {"description": "Min", "value": 1}, {"description": "Low", "value": 25}, {"description": "Medium (Default)", "value": 50}, {"description": "High", "value": 75}, {"description": "Max", "value": 100}]}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "longDesc": "Setting this parameter changes CAL_MAG3_ROT to \"Custom Euler Angle\"\n", "max": 180.0, "min": -180.0, "name": "CAL_MAG3_ROLL", "shortDesc": "Magnetometer 3 Custom Euler Roll Angle", "type": "Float", "units": "deg"}, {"category": "System", "default": -1, "group": "Sensor Calibration", "longDesc": "An internal sensor will force a value of -1, so a GCS should only attempt to configure the rotation if the value is greater than or equal to zero.\nSet to \"Custom Euler Angle\" to define the rotation using CAL_MAG3_ROLL, CAL_MAG3_PITCH and CAL_MAG3_YAW.\n\n", "max": 100, "min": -1, "name": "CAL_MAG3_ROT", "shortDesc": "Magnetometer 3 rotation relative to airframe", "type": "Int32", "values": [{"description": "Internal", "value": -1}, {"description": "No rotation", "value": 0}, {"description": "Yaw 45\u00b0", "value": 1}, {"description": "Yaw 90\u00b0", "value": 2}, {"description": "Yaw 135\u00b0", "value": 3}, {"description": "Yaw 180\u00b0", "value": 4}, {"description": "Yaw 225\u00b0", "value": 5}, {"description": "Yaw 270\u00b0", "value": 6}, {"description": "Yaw 315\u00b0", "value": 7}, {"description": "Roll 180\u00b0", "value": 8}, {"description": "Roll 180\u00b0, Yaw 45\u00b0", "value": 9}, {"description": "Roll 180\u00b0, Yaw 90\u00b0", "value": 10}, {"description": "Roll 180\u00b0, Yaw 135\u00b0", "value": 11}, {"description": "Pitch 180\u00b0", "value": 12}, {"description": "Roll 180\u00b0, Yaw 225\u00b0", "value": 13}, {"description": "Roll 180\u00b0, Yaw 270\u00b0", "value": 14}, {"description": "Roll 180\u00b0, Yaw 315\u00b0", "value": 15}, {"description": "Roll 90\u00b0", "value": 16}, {"description": "Roll 90\u00b0, Yaw 45\u00b0", "value": 17}, {"description": "Roll 90\u00b0, Yaw 90\u00b0", "value": 18}, {"description": "Roll 90\u00b0, Yaw 135\u00b0", "value": 19}, {"description": "Roll 270\u00b0", "value": 20}, {"description": "Roll 270\u00b0, Yaw 45\u00b0", "value": 21}, {"description": "Roll 270\u00b0, Yaw 90\u00b0", "value": 22}, {"description": "Roll 270\u00b0, Yaw 135\u00b0", "value": 23}, {"description": "Pitch 90\u00b0", "value": 24}, {"description": "Pitch 270\u00b0", "value": 25}, {"description": "Pitch 180\u00b0, Yaw 90\u00b0", "value": 26}, {"description": "Pitch 180\u00b0, Yaw 270\u00b0", "value": 27}, {"description": "Roll 90\u00b0, Pitch 90\u00b0", "value": 28}, {"description": "Roll 180\u00b0, Pitch 90\u00b0", "value": 29}, {"description": "Roll 270\u00b0, Pitch 90\u00b0", "value": 30}, {"description": "Roll 90\u00b0, Pitch 180\u00b0", "value": 31}, {"description": "Roll 270\u00b0, Pitch 180\u00b0", "value": 32}, {"description": "Roll 90\u00b0, Pitch 270\u00b0", "value": 33}, {"description": "Roll 180\u00b0, Pitch 270\u00b0", "value": 34}, {"description": "Roll 270\u00b0, Pitch 270\u00b0", "value": 35}, {"description": "Roll 90\u00b0, Pitch 180\u00b0, Yaw 90\u00b0", "value": 36}, {"description": "Roll 90\u00b0, Yaw 270\u00b0", "value": 37}, {"description": "Roll 90\u00b0, Pitch 68\u00b0, Yaw 293\u00b0", "value": 38}, {"description": "Pitch 315\u00b0", "value": 39}, {"description": "Roll 90\u00b0, Pitch 315\u00b0", "value": 40}, {"description": "Custom Euler Angle", "value": 100}]}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "Coefficient describing linear relationship between\nX component of magnetometer in body frame axis\nand either current or throttle depending on value of CAL_MAG_COMP_TYP.\nUnit for throttle-based compensation is [G] and\nfor current-based compensation [G/kA]\n\n", "name": "CAL_MAG3_XCOMP", "shortDesc": "Magnetometer 3 X Axis throttle compensation", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG3_XODIAG", "shortDesc": "Magnetometer 3 X-axis off diagonal scale factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG3_XOFF", "shortDesc": "Magnetometer 3 X-axis offset", "type": "Float", "units": "gauss", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_MAG3_XSCALE", "shortDesc": "Magnetometer 3 X-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "longDesc": "Setting this parameter changes CAL_MAG3_ROT to \"Custom Euler Angle\"\n", "max": 180.0, "min": -180.0, "name": "CAL_MAG3_YAW", "shortDesc": "Magnetometer 3 Custom Euler Yaw Angle", "type": "Float", "units": "deg"}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "Coefficient describing linear relationship between\nY component of magnetometer in body frame axis\nand either current or throttle depending on value of CAL_MAG_COMP_TYP.\nUnit for throttle-based compensation is [G] and\nfor current-based compensation [G/kA]\n\n", "name": "CAL_MAG3_YCOMP", "shortDesc": "Magnetometer 3 Y Axis throttle compensation", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG3_YODIAG", "shortDesc": "Magnetometer 3 Y-axis off diagonal scale factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG3_YOFF", "shortDesc": "Magnetometer 3 Y-axis offset", "type": "Float", "units": "gauss", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_MAG3_YSCALE", "shortDesc": "Magnetometer 3 Y-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "Coefficient describing linear relationship between\nZ component of magnetometer in body frame axis\nand either current or throttle depending on value of CAL_MAG_COMP_TYP.\nUnit for throttle-based compensation is [G] and\nfor current-based compensation [G/kA]\n\n", "name": "CAL_MAG3_ZCOMP", "shortDesc": "Magnetometer 3 Z Axis throttle compensation", "type": "Float", "volatile": true}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG3_ZODIAG", "shortDesc": "Magnetometer 3 Z-axis off diagonal scale factor", "type": "Float", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "name": "CAL_MAG3_ZOFF", "shortDesc": "Magnetometer 3 Z-axis offset", "type": "Float", "units": "gauss", "volatile": true}, {"category": "System", "decimalPlaces": 3, "default": 1.0, "group": "Sensor Calibration", "max": 3.0, "min": 0.1, "name": "CAL_MAG3_ZSCALE", "shortDesc": "Magnetometer 3 Z-axis scaling factor", "type": "Float", "volatile": true}, {"category": "System", "default": 0, "group": "Sensor Calibration", "name": "CAL_MAG_COMP_TYP", "shortDesc": "Type of magnetometer compensation", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Throttle-based compensation", "value": 1}, {"description": "Current-based compensation (battery_status instance 0)", "value": 2}, {"description": "Current-based compensation (battery_status instance 1)", "value": 3}]}, {"category": "Standard", "default": 0.0, "group": "Sensor Calibration", "longDesc": "Pick the appropriate scaling from the datasheet.\nthis number defines the (linear) conversion from voltage\nto pressure. For the MPXV7002DP this is 1000.\n\nNOTE: If the sensor always registers zero, try switching\nthe static and dynamic tubes.\n", "name": "SENS_DPRES_ANSC", "shortDesc": "Differential pressure sensor analog scaling", "type": "Float", "units": "Pa/V"}, {"category": "System", "default": 0.0, "group": "Sensor Calibration", "longDesc": "The offset (zero-reading) of the sensor holding calibration slot 0.\n\nKept as a mirror of CAL_DPRES0_OFF so that ground stations can still detect whether\nairspeed has been calibrated. The firmware applies CAL_DPRESx_OFF, not this value.\n", "name": "SENS_DPRES_OFF", "shortDesc": "Differential pressure sensor offset of the first airspeed sensor", "type": "Float", "units": "Pa", "volatile": true}, {"category": "System", "default": 0, "group": "Sensor Calibration", "longDesc": "Reverse the raw measurements of all differential pressure sensors.\nThis can be enabled if the sensors have static and dynamic ports swapped.\n", "name": "SENS_DPRES_REV", "shortDesc": "Reverse differential pressure sensor readings", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 7.0, "group": "Sensor Calibration", "longDesc": "Assumes measurement is timestamped at trailing edge of integration\nperiod. Applied to timestamp_sample of the published data. The default\nmatches a DroneCAN flow node, whose frame reaches the flight controller\nabout 7 ms after its integration window closes.\n", "max": 300.0, "min": 0.0, "name": "SENS_FLOW0_DELAY", "rebootRequired": true, "shortDesc": "Optical flow sensor 0 measurement delay relative to IMU", "type": "Float", "units": "ms"}, {"category": "Standard", "decimalPlaces": 2, "default": 100.0, "group": "Sensor Calibration", "increment": 0.1, "longDesc": "This parameter defines the maximum distance from ground at which the optical flow sensor operates reliably.\nThe height setpoint will be limited to be no greater than this value when the navigation system\nis completely reliant on optical flow data and the height above ground estimate is valid.\nThe sensor may be usable above this height, but accuracy will progressively degrade.\n", "max": 100.0, "min": 1.0, "name": "SENS_FLOW0_HMAX", "shortDesc": "Maximum height above ground when reliant on optical flow 0", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.08, "group": "Sensor Calibration", "increment": 0.1, "longDesc": "This parameter defines the minimum distance from ground at which the optical flow sensor operates reliably.\nThe sensor may be usable below this height, but accuracy will progressively reduce to loss of focus.\n", "max": 1.0, "min": 0.0, "name": "SENS_FLOW0_HMIN", "shortDesc": "Minimum height above ground when reliant on optical flow 0", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the flow sensor configured by the SENS_FLOW0_* parameters. Set to 0 to automatically bind the first unbound sensor reporting data.\n", "name": "SENS_FLOW0_ID", "rebootRequired": true, "shortDesc": "Optical flow sensor 0 ID", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 2, "default": 8.0, "group": "Sensor Calibration", "longDesc": "Magnitude of maximum angular flow rate reliably measurable by the optical flow sensor\n\nOptical flow data will not fused by the estimators if the magnitude of the flow rate exceeds this value and\ncontrol loops will be instructed to limit ground speed such that the flow rate produced by movement over ground\nis less than 50% of this value.\n", "min": 1.0, "name": "SENS_FLOW0_MAXR", "shortDesc": "Max angular flow rate measurable by sensor 0", "type": "Float", "units": "rad/s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "Forward axis with origin relative to vehicle centre of gravity\n", "name": "SENS_FLOW0_POS_X", "shortDesc": "X position of optical flow sensor 0 focal point in body frame", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "Right axis with origin relative to vehicle centre of gravity\n", "name": "SENS_FLOW0_POS_Y", "shortDesc": "Y position of optical flow sensor 0 focal point in body frame", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "Down axis with origin relative to vehicle centre of gravity\n", "name": "SENS_FLOW0_POS_Z", "shortDesc": "Z position of optical flow sensor 0 focal point in body frame", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 7.0, "group": "Sensor Calibration", "longDesc": "Assumes measurement is timestamped at trailing edge of integration\nperiod. Applied to timestamp_sample of the published data. The default\nmatches a DroneCAN flow node, whose frame reaches the flight controller\nabout 7 ms after its integration window closes.\n", "max": 300.0, "min": 0.0, "name": "SENS_FLOW1_DELAY", "rebootRequired": true, "shortDesc": "Optical flow sensor 1 measurement delay relative to IMU", "type": "Float", "units": "ms"}, {"category": "Standard", "decimalPlaces": 2, "default": 100.0, "group": "Sensor Calibration", "increment": 0.1, "longDesc": "This parameter defines the maximum distance from ground at which the optical flow sensor operates reliably.\nThe height setpoint will be limited to be no greater than this value when the navigation system\nis completely reliant on optical flow data and the height above ground estimate is valid.\nThe sensor may be usable above this height, but accuracy will progressively degrade.\n", "max": 100.0, "min": 1.0, "name": "SENS_FLOW1_HMAX", "shortDesc": "Maximum height above ground when reliant on optical flow 1", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.08, "group": "Sensor Calibration", "increment": 0.1, "longDesc": "This parameter defines the minimum distance from ground at which the optical flow sensor operates reliably.\nThe sensor may be usable below this height, but accuracy will progressively reduce to loss of focus.\n", "max": 1.0, "min": 0.0, "name": "SENS_FLOW1_HMIN", "shortDesc": "Minimum height above ground when reliant on optical flow 1", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Sensor Calibration", "longDesc": "Device ID of the flow sensor configured by the SENS_FLOW1_* parameters. Set to 0 to automatically bind the first unbound sensor reporting data.\n", "name": "SENS_FLOW1_ID", "rebootRequired": true, "shortDesc": "Optical flow sensor 1 ID", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 2, "default": 8.0, "group": "Sensor Calibration", "longDesc": "Magnitude of maximum angular flow rate reliably measurable by the optical flow sensor\n\nOptical flow data will not fused by the estimators if the magnitude of the flow rate exceeds this value and\ncontrol loops will be instructed to limit ground speed such that the flow rate produced by movement over ground\nis less than 50% of this value.\n", "min": 1.0, "name": "SENS_FLOW1_MAXR", "shortDesc": "Max angular flow rate measurable by sensor 1", "type": "Float", "units": "rad/s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "Forward axis with origin relative to vehicle centre of gravity\n", "name": "SENS_FLOW1_POS_X", "shortDesc": "X position of optical flow sensor 1 focal point in body frame", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "Right axis with origin relative to vehicle centre of gravity\n", "name": "SENS_FLOW1_POS_Y", "shortDesc": "Y position of optical flow sensor 1 focal point in body frame", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Sensor Calibration", "longDesc": "Down axis with origin relative to vehicle centre of gravity\n", "name": "SENS_FLOW1_POS_Z", "shortDesc": "Z position of optical flow sensor 1 focal point in body frame", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "Sensors", "longDesc": "Model with Pitot\nCAL_AIR_TUBED_MM: Not used, 1.5 mm tubes assumed.\nCAL_AIR_TUBELEN: Length of the tubes connecting the pitot to the sensor.\nModel without Pitot (1.5 mm tubes)\nCAL_AIR_TUBED_MM: Not used, 1.5 mm tubes assumed.\nCAL_AIR_TUBELEN: Length of the tubes connecting the pitot to the sensor.\nTube Pressure Drop\nCAL_AIR_TUBED_MM: Diameter in mm of the pitot and tubes, must have the same diameter.\nCAL_AIR_TUBELEN: Length of the tubes connecting the pitot to the sensor and the static + dynamic port length of the pitot.\n", "name": "CAL_AIR_CMODEL", "shortDesc": "Airspeed sensor compensation model for the SDP3x", "type": "Int32", "values": [{"description": "Model with Pitot", "value": 0}, {"description": "Model without Pitot (1.5 mm tubes)", "value": 1}, {"description": "Tube Pressure Drop", "value": 2}]}, {"category": "Standard", "default": 1.5, "group": "Sensors", "longDesc": "Airspeed sensor tube diameter. Only used for the Tube Pressure Drop Compensation\n", "max": 100.0, "min": 1.5, "name": "CAL_AIR_TUBED_MM", "shortDesc": "Airspeed sensor tube diameter", "type": "Float", "units": "mm"}, {"category": "Standard", "default": 0.2, "group": "Sensors", "longDesc": "See the CAL_AIR_CMODEL explanation on how this parameter should be set.\n", "max": 2.0, "min": 0.01, "name": "CAL_AIR_TUBELEN", "shortDesc": "Airspeed sensor tube length", "type": "Float", "units": "m"}, {"category": "Developer", "default": 63, "group": "Sensors", "longDesc": "Use SENS_MAG_SIDES instead\n", "name": "CAL_MAG_SIDES", "shortDesc": "For legacy QGC support only", "type": "Int32"}, {"bitmask": [{"description": "Sat count (GNSS_REQ_NSATS)", "index": 0}, {"description": "PDOP (GNSS_REQ_PDOP)", "index": 1}, {"description": "EPH (GNSS_REQ_EPH)", "index": 2}, {"description": "EPV (GNSS_REQ_EPV)", "index": 3}, {"description": "Speed accuracy (GNSS_REQ_SACC)", "index": 4}, {"description": "Horizontal position drift (GNSS_REQ_HDRIFT)", "index": 5}, {"description": "Vertical position drift (GNSS_REQ_VDRIFT)", "index": 6}, {"description": "Horizontal speed offset (GNSS_REQ_HDRIFT)", "index": 7}, {"description": "Vertical speed offset (GNSS_REQ_VDRIFT)", "index": 8}, {"description": "Spoofing", "index": 9}, {"description": "GNSS fix type (GNSS_REQ_FIX)", "index": 10}, {"description": "Jamming", "index": 11}, {"description": "Horizontal kinematic consistency (GNSS_REQ_HKIN)", "index": 12}], "category": "Standard", "default": 6143, "group": "Sensors", "longDesc": "Each threshold value is defined by the parameter indicated next to the check. Drift and offset checks only run when the vehicle is on ground and stationary. The spoofing and jamming checks also apply to the receiver providing the GNSS heading.\n", "max": 8191, "min": 0, "name": "GNSS_CHECK", "shortDesc": "Integer bitmask controlling GNSS checks", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "Sensors", "max": 100.0, "min": 0.1, "name": "GNSS_REQ_EPH", "shortDesc": "Required EPH to use GNSS", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "Sensors", "max": 100.0, "min": 0.1, "name": "GNSS_REQ_EPV", "shortDesc": "Required EPV to use GNSS", "type": "Float", "units": "m"}, {"category": "Standard", "default": 3, "group": "Sensors", "longDesc": "Minimum GNSS fix type required for GNSS usage.\n", "name": "GNSS_REQ_FIX", "shortDesc": "Required GNSS fix", "type": "Int32", "values": [{"description": "No fix required", "value": 0}, {"description": "2D fix", "value": 2}, {"description": "3D fix", "value": 3}, {"description": "RTCM code differential", "value": 4}, {"description": "RTK float", "value": 5}, {"description": "RTK fixed", "value": 6}, {"description": "Extrapolated", "value": 8}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "Sensors", "max": 1.0, "min": 0.1, "name": "GNSS_REQ_HDRIFT", "shortDesc": "Maximum horizontal drift speed to use GNSS", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 2.0, "group": "Sensors", "longDesc": "The rate of change of the reported horizontal position, minus the reported horizontal velocity, filtered over 1 s.\n", "max": 20.0, "min": 0.1, "name": "GNSS_REQ_HKIN", "shortDesc": "Maximum horizontal kinematic inconsistency to use GNSS", "type": "Float", "units": "m/s"}, {"category": "Standard", "default": 6, "group": "Sensors", "max": 12, "min": 4, "name": "GNSS_REQ_NSATS", "shortDesc": "Required satellite count to use GNSS", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 1, "default": 2.5, "group": "Sensors", "max": 5.0, "min": 1.5, "name": "GNSS_REQ_PDOP", "shortDesc": "Maximum PDOP to use GNSS", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.5, "group": "Sensors", "longDesc": "EKF2 also feeds GNSS velocity to the EKF-GSF yaw estimator, and trusts the GNSS vertical velocity while the accelerometer clips, only below this speed accuracy, in flight too. With the speed accuracy check disabled in GNSS_CHECK, it does both whatever the speed accuracy.\n", "max": 5.0, "min": 0.5, "name": "GNSS_REQ_SACC", "shortDesc": "Required speed accuracy to use GNSS", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 10.0, "group": "Sensors", "longDesc": "Minimum continuous period without GNSS failure required to mark a healthy GNSS status. It can be reduced to speed up initialization, but it's recommended to keep this unchanged for a vehicle.\n", "min": 0.1, "name": "GNSS_REQ_TIME", "shortDesc": "Required GNSS health time on startup", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.2, "group": "Sensors", "max": 1.5, "min": 0.1, "name": "GNSS_REQ_VDRIFT", "shortDesc": "Maximum vertical drift speed to use GNSS", "type": "Float", "units": "m/s"}, {"category": "Standard", "default": 30.0, "group": "Sensors", "longDesc": "The cutoff frequency for the 2nd order butterworth filter on the primary accelerometer.\nThis only affects the signal sent to the controllers, not the estimators. 0 disables the filter.\n", "max": 1000.0, "min": 0.0, "name": "IMU_ACCEL_CUTOFF", "rebootRequired": true, "shortDesc": "Low pass filter cutoff frequency for accel", "type": "Float", "units": "Hz"}, {"category": "Standard", "decimalPlaces": 1, "default": 20.0, "group": "Sensors", "increment": 0.1, "longDesc": "The cutoff frequency for the 2nd order butterworth filter used on\nthe time derivative of the measured angular velocity, also known as\nthe D-term filter in the rate controller. The D-term uses the derivative of\nthe rate and thus is the most susceptible to noise. Therefore, using\na D-term filter allows to increase IMU_GYRO_CUTOFF, which\nleads to reduced control latency and permits to increase the P gains.\n\nA value of 0 disables the filter.\n", "max": 1000.0, "min": 0.0, "name": "IMU_DGYRO_CUTOFF", "shortDesc": "Cutoff frequency for angular acceleration (D-Term filter)", "type": "Float", "units": "Hz"}, {"category": "Standard", "default": 1, "group": "Sensors", "name": "IMU_GYRO_CAL_EN", "rebootRequired": true, "shortDesc": "IMU gyro auto calibration enable", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 40.0, "group": "Sensors", "increment": 0.1, "longDesc": "The cutoff frequency for the 2nd order butterworth filter on the primary gyro.\nThis only affects the angular velocity sent to the controllers, not the estimators.\nIt applies also to the angular acceleration (D-Term filter), see IMU_DGYRO_CUTOFF.\n\nA value of 0 disables the filter.\n", "max": 1000.0, "min": 0.0, "name": "IMU_GYRO_CUTOFF", "shortDesc": "Low pass filter cutoff frequency for gyro", "type": "Float", "units": "Hz"}, {"category": "Standard", "decimalPlaces": 1, "default": 15.0, "group": "Sensors", "increment": 0.1, "longDesc": "Bandwidth per notch filter when using dynamic notch filtering with ESC RPM.\n", "max": 30.0, "min": 5.0, "name": "IMU_GYRO_DNF_BW", "shortDesc": "IMU gyro ESC notch filter bandwidth", "type": "Float", "units": "Hz"}, {"bitmask": [{"description": "ESC RPM", "index": 0}, {"description": "FFT", "index": 1}], "category": "Standard", "default": 0, "group": "Sensors", "longDesc": "Enable bank of dynamically updating notch filters.\nRequires ESC RPM feedback or onboard FFT (IMU_GYRO_FFT_EN).\n", "max": 3, "min": 0, "name": "IMU_GYRO_DNF_EN", "shortDesc": "IMU gyro dynamic notch filtering", "type": "Int32"}, {"category": "Standard", "default": 3, "group": "Sensors", "longDesc": "ESC RPM number of harmonics (multiples of RPM) for ESC RPM dynamic notch filtering.\n", "max": 7, "min": 1, "name": "IMU_GYRO_DNF_HMC", "shortDesc": "IMU gyro dynamic notch filter harmonics", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 1, "default": 25.0, "group": "Sensors", "increment": 0.1, "longDesc": "Minimum notch filter frequency in Hz.\n", "name": "IMU_GYRO_DNF_MIN", "shortDesc": "IMU gyro dynamic notch filter minimum frequency", "type": "Float", "units": "Hz"}, {"category": "Standard", "default": 0, "group": "Sensors", "name": "IMU_GYRO_FFT_EN", "rebootRequired": true, "shortDesc": "IMU gyro FFT enable", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 512, "group": "Sensors", "name": "IMU_GYRO_FFT_LEN", "rebootRequired": true, "shortDesc": "IMU gyro FFT length", "type": "Int32", "values": [{"description": "256", "value": 256}, {"description": "512", "value": 512}, {"description": "1024", "value": 1024}]}, {"category": "Standard", "default": 150.0, "group": "Sensors", "max": 1000.0, "min": 1.0, "name": "IMU_GYRO_FFT_MAX", "rebootRequired": true, "shortDesc": "IMU gyro FFT maximum frequency", "type": "Float", "units": "Hz"}, {"category": "Standard", "default": 30.0, "group": "Sensors", "max": 1000.0, "min": 1.0, "name": "IMU_GYRO_FFT_MIN", "rebootRequired": true, "shortDesc": "IMU gyro FFT minimum frequency", "type": "Float", "units": "Hz"}, {"category": "Standard", "default": 10.0, "group": "Sensors", "max": 30.0, "min": 1.0, "name": "IMU_GYRO_FFT_SNR", "shortDesc": "IMU gyro FFT SNR", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 20.0, "group": "Sensors", "increment": 0.1, "longDesc": "The frequency width of the stop band for the 2nd order notch filter on the primary gyro.\nSee \"IMU_GYRO_NF0_FRQ\" to activate the filter and to set the notch frequency.\nApplies to both angular velocity and angular acceleration sent to the controllers.\n", "max": 100.0, "min": 0.0, "name": "IMU_GYRO_NF0_BW", "shortDesc": "Notch filter 0 bandwidth for gyro", "type": "Float", "units": "Hz"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "Sensors", "increment": 0.1, "longDesc": "The center frequency for the 2nd order notch filter on the primary gyro.\nThis filter can be enabled to avoid feedback amplification of structural resonances at a specific frequency.\nThis only affects the signal sent to the controllers, not the estimators.\nApplies to both angular velocity and angular acceleration sent to the controllers.\nSee \"IMU_GYRO_NF0_BW\" to set the bandwidth of the filter.\n\nA value of 0 disables the filter.\n", "max": 1000.0, "min": 0.0, "name": "IMU_GYRO_NF0_FRQ", "shortDesc": "Notch filter 0 frequency for gyro", "type": "Float", "units": "Hz"}, {"category": "Standard", "decimalPlaces": 1, "default": 20.0, "group": "Sensors", "increment": 0.1, "longDesc": "The frequency width of the stop band for the 2nd order notch filter on the primary gyro.\nSee \"IMU_GYRO_NF1_FRQ\" to activate the filter and to set the notch frequency.\nApplies to both angular velocity and angular acceleration sent to the controllers.\n", "max": 100.0, "min": 0.0, "name": "IMU_GYRO_NF1_BW", "shortDesc": "Notch filter 1 bandwidth for gyro", "type": "Float", "units": "Hz"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "Sensors", "increment": 0.1, "longDesc": "The center frequency for the 2nd order notch filter on the primary gyro.\nThis filter can be enabled to avoid feedback amplification of structural resonances at a specific frequency.\nThis only affects the signal sent to the controllers, not the estimators.\nApplies to both angular velocity and angular acceleration sent to the controllers.\nSee \"IMU_GYRO_NF1_BW\" to set the bandwidth of the filter.\n\nA value of 0 disables the filter.\n", "max": 1000.0, "min": 0.0, "name": "IMU_GYRO_NF1_FRQ", "shortDesc": "Notch filter 1 frequency for gyro", "type": "Float", "units": "Hz"}, {"category": "Standard", "default": 400, "group": "Sensors", "longDesc": "The maximum rate the gyro control data (vehicle_angular_velocity) will be\nallowed to publish at. This is the loop rate for the rate controller and outputs.\n\nNote: sensor data is always read and filtered at the full raw rate (eg commonly 8 kHz) regardless of this setting.\n", "max": 2000, "min": 100, "name": "IMU_GYRO_RATEMAX", "rebootRequired": true, "shortDesc": "Gyro control data maximum publication rate (inner loop rate)", "type": "Int32", "units": "Hz", "values": [{"description": "100 Hz", "value": 100}, {"description": "250 Hz", "value": 250}, {"description": "400 Hz", "value": 400}, {"description": "800 Hz", "value": 800}, {"description": "1000 Hz", "value": 1000}, {"description": "2000 Hz", "value": 2000}]}, {"category": "Standard", "default": 200, "group": "Sensors", "longDesc": "The rate at which raw IMU data is integrated to produce delta angles and delta velocities.\nRecommended to set this to a multiple of the estimator update period (currently 10 ms for ekf2).\n", "max": 1000, "min": 100, "name": "IMU_INTEG_RATE", "rebootRequired": true, "shortDesc": "IMU integration rate", "type": "Int32", "units": "Hz", "values": [{"description": "100 Hz", "value": 100}, {"description": "200 Hz", "value": 200}, {"description": "250 Hz", "value": 250}, {"description": "400 Hz", "value": 400}]}, {"category": "Standard", "default": 1013.25, "group": "Sensors", "max": 1500.0, "min": 500.0, "name": "SENS_BARO_QNH", "shortDesc": "QNH for barometer", "type": "Float", "units": "hPa"}, {"category": "Standard", "default": 20.0, "group": "Sensors", "longDesc": "Barometric air data maximum publication rate. This is an upper bound,\nactual barometric data rate is still dependent on the sensor.\n", "max": 200.0, "min": 1.0, "name": "SENS_BARO_RATE", "shortDesc": "Baro max rate", "type": "Float", "units": "Hz"}, {"category": "System", "default": 1, "group": "Sensors", "longDesc": "Automatically calibrate barometer based on the GNSS height.\nKeeps recalibrating while landed and disarmed when the baro drifts away from the GNSS height.\n", "name": "SENS_BAR_AUTOCAL", "shortDesc": "Barometer auto calibration", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Sensors", "longDesc": "This parameter defines the rotation of the FMU board relative to the platform.\n", "max": 40, "min": -1, "name": "SENS_BOARD_ROT", "rebootRequired": true, "shortDesc": "Board rotation", "type": "Int32", "values": [{"description": "No rotation", "value": 0}, {"description": "Yaw 45\u00b0", "value": 1}, {"description": "Yaw 90\u00b0", "value": 2}, {"description": "Yaw 135\u00b0", "value": 3}, {"description": "Yaw 180\u00b0", "value": 4}, {"description": "Yaw 225\u00b0", "value": 5}, {"description": "Yaw 270\u00b0", "value": 6}, {"description": "Yaw 315\u00b0", "value": 7}, {"description": "Roll 180\u00b0", "value": 8}, {"description": "Roll 180\u00b0, Yaw 45\u00b0", "value": 9}, {"description": "Roll 180\u00b0, Yaw 90\u00b0", "value": 10}, {"description": "Roll 180\u00b0, Yaw 135\u00b0", "value": 11}, {"description": "Pitch 180\u00b0", "value": 12}, {"description": "Roll 180\u00b0, Yaw 225\u00b0", "value": 13}, {"description": "Roll 180\u00b0, Yaw 270\u00b0", "value": 14}, {"description": "Roll 180\u00b0, Yaw 315\u00b0", "value": 15}, {"description": "Roll 90\u00b0", "value": 16}, {"description": "Roll 90\u00b0, Yaw 45\u00b0", "value": 17}, {"description": "Roll 90\u00b0, Yaw 90\u00b0", "value": 18}, {"description": "Roll 90\u00b0, Yaw 135\u00b0", "value": 19}, {"description": "Roll 270\u00b0", "value": 20}, {"description": "Roll 270\u00b0, Yaw 45\u00b0", "value": 21}, {"description": "Roll 270\u00b0, Yaw 90\u00b0", "value": 22}, {"description": "Roll 270\u00b0, Yaw 135\u00b0", "value": 23}, {"description": "Pitch 90\u00b0", "value": 24}, {"description": "Pitch 270\u00b0", "value": 25}, {"description": "Pitch 180\u00b0, Yaw 90\u00b0", "value": 26}, {"description": "Pitch 180\u00b0, Yaw 270\u00b0", "value": 27}, {"description": "Roll 90\u00b0, Pitch 90\u00b0", "value": 28}, {"description": "Roll 180\u00b0, Pitch 90\u00b0", "value": 29}, {"description": "Roll 270\u00b0, Pitch 90\u00b0", "value": 30}, {"description": "Roll 90\u00b0, Pitch 180\u00b0", "value": 31}, {"description": "Roll 270\u00b0, Pitch 180\u00b0", "value": 32}, {"description": "Roll 90\u00b0, Pitch 270\u00b0", "value": 33}, {"description": "Roll 180\u00b0, Pitch 270\u00b0", "value": 34}, {"description": "Roll 270\u00b0, Pitch 270\u00b0", "value": 35}, {"description": "Roll 90\u00b0, Pitch 180\u00b0, Yaw 90\u00b0", "value": 36}, {"description": "Roll 90\u00b0, Yaw 270\u00b0", "value": 37}, {"description": "Roll 90\u00b0, Pitch 68\u00b0, Yaw 293\u00b0", "value": 38}, {"description": "Pitch 315\u00b0", "value": 39}, {"description": "Roll 90\u00b0, Pitch 315\u00b0", "value": 40}]}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "Sensors", "longDesc": "Rotation from flight controller board to vehicle body frame.\nThis parameter gets set during the \"level horizon\" calibration or can be\nset manually.\n", "max": 45.0, "min": -45.0, "name": "SENS_BOARD_X_OFF", "shortDesc": "Board rotation X (roll) offset", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "Sensors", "longDesc": "Rotation from flight controller board to vehicle body frame.\nThis parameter gets set during the \"level horizon\" calibration or can be\nset manually.\n", "max": 45.0, "min": -45.0, "name": "SENS_BOARD_Y_OFF", "shortDesc": "Board rotation Y (pitch) offset", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "Sensors", "longDesc": "Rotation from flight controller board to vehicle body frame.\nHas to be set manually (not set by any calibration).\n", "max": 45.0, "min": -45.0, "name": "SENS_BOARD_Z_OFF", "shortDesc": "Board rotation Z (yaw) offset", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 0, "group": "Sensors", "max": 1, "min": 0, "name": "SENS_EN_AGPSIM", "rebootRequired": true, "shortDesc": "Simulate Aux Global Position (AGP)", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Sensors", "max": 1, "min": 0, "name": "SENS_EN_ARSPDSIM", "rebootRequired": true, "shortDesc": "Enable simulated airspeed sensor instance", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Sensors", "max": 1, "min": 0, "name": "SENS_EN_BAROSIM", "rebootRequired": true, "shortDesc": "Enable simulated barometer sensor instance", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Sensors", "max": 1, "min": 0, "name": "SENS_EN_GPSSIM", "rebootRequired": true, "shortDesc": "Enable simulated GPS instance", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Sensors", "max": 1, "min": 0, "name": "SENS_EN_MAGSIM", "rebootRequired": true, "shortDesc": "Enable simulated magnetometer sensor instance", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "System", "default": -1, "group": "Sensors", "name": "SENS_EN_THERMAL", "shortDesc": "Thermal control of sensor temperature", "type": "Int32", "values": [{"description": "Thermal control unavailable", "value": -1}, {"description": "Thermal control off", "value": 0}, {"description": "Thermal control enabled", "value": 1}]}, {"category": "System", "default": 1, "group": "Sensors", "longDesc": "Probe for optional external I2C devices.\n", "name": "SENS_EXT_I2C_PRB", "shortDesc": "External I2C probe", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 70.0, "group": "Sensors", "longDesc": "Optical flow data maximum publication rate. This is an upper bound,\nactual optical flow data rate is still dependent on the sensor.\n", "max": 200.0, "min": 1.0, "name": "SENS_FLOW0_RATE", "rebootRequired": true, "shortDesc": "Optical flow 0 max rate", "type": "Float", "units": "Hz"}, {"category": "Standard", "default": 0, "group": "Sensors", "longDesc": "This parameter defines the yaw rotation of the optical flow relative to the vehicle body frame.\nZero rotation is defined as X on flow board pointing towards front of vehicle.\n", "name": "SENS_FLOW0_ROT", "shortDesc": "Optical flow 0 rotation", "type": "Int32", "values": [{"description": "No rotation", "value": 0}, {"description": "Yaw 45\u00b0", "value": 1}, {"description": "Yaw 90\u00b0", "value": 2}, {"description": "Yaw 135\u00b0", "value": 3}, {"description": "Yaw 180\u00b0", "value": 4}, {"description": "Yaw 225\u00b0", "value": 5}, {"description": "Yaw 270\u00b0", "value": 6}, {"description": "Yaw 315\u00b0", "value": 7}]}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Sensors", "max": 1.5, "min": 0.5, "name": "SENS_FLOW0_SCALE", "shortDesc": "Optical flow 0 scale factor", "type": "Float"}, {"category": "Standard", "default": 70.0, "group": "Sensors", "longDesc": "Optical flow data maximum publication rate. This is an upper bound,\nactual optical flow data rate is still dependent on the sensor.\n", "max": 200.0, "min": 1.0, "name": "SENS_FLOW1_RATE", "rebootRequired": true, "shortDesc": "Optical flow 1 max rate", "type": "Float", "units": "Hz"}, {"category": "Standard", "default": 0, "group": "Sensors", "longDesc": "This parameter defines the yaw rotation of the optical flow relative to the vehicle body frame.\nZero rotation is defined as X on flow board pointing towards front of vehicle.\n", "name": "SENS_FLOW1_ROT", "shortDesc": "Optical flow 1 rotation", "type": "Int32", "values": [{"description": "No rotation", "value": 0}, {"description": "Yaw 45\u00b0", "value": 1}, {"description": "Yaw 90\u00b0", "value": 2}, {"description": "Yaw 135\u00b0", "value": 3}, {"description": "Yaw 180\u00b0", "value": 4}, {"description": "Yaw 225\u00b0", "value": 5}, {"description": "Yaw 270\u00b0", "value": 6}, {"description": "Yaw 315\u00b0", "value": 7}]}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Sensors", "max": 1.5, "min": 0.5, "name": "SENS_FLOW1_SCALE", "shortDesc": "Optical flow 1 scale factor", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Sensors", "longDesc": "Forward axis relative to vehicle centre of gravity, of the receiver's second antenna.\nUsed when SENS_GNSS0_HDG is Dual antenna.\n\n", "name": "SENS_GNSS0_AUXX", "shortDesc": "GNSS 0 auxiliary antenna X position", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Sensors", "longDesc": "Right axis relative to vehicle centre of gravity, of the receiver's second antenna.\nUsed when SENS_GNSS0_HDG is Dual antenna.\n\n", "name": "SENS_GNSS0_AUXY", "shortDesc": "GNSS 0 auxiliary antenna Y position", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Sensors", "longDesc": "Down axis relative to vehicle centre of gravity, of the receiver's second antenna.\nUsed when SENS_GNSS0_HDG is Dual antenna.\n\n", "name": "SENS_GNSS0_AUXZ", "shortDesc": "GNSS 0 auxiliary antenna Z position", "type": "Float", "units": "m"}, {"category": "Standard", "default": 110, "group": "Sensors", "longDesc": "GPS measurement delay relative to IMU measurements.\nMatched to physical GPS receiver via SENS_GNSS0_ID.\nOnly applied when the GPS driver does not provide its own\ntimestamp_sample correction.\n\n", "max": 300, "min": 0, "name": "SENS_GNSS0_DELAY", "shortDesc": "GPS 0 measurement delay", "type": "Int32", "units": "ms"}, {"category": "Standard", "default": 0, "group": "Sensors", "longDesc": "How the receiver in slot 0 (matched via SENS_GNSS0_ID) measures its dual antenna heading.\nThe heading is the bearing of the baseline between two antennas, and is only used when the\nbaseline length the receiver reports is within 20% of the configured one.\nMoving base rover: this receiver is the rover of a moving base pair, the moving base is the\nreceiver in the other slot. The baseline runs from the moving base's antenna to this\nreceiver's antenna (SENS_GNSSn_OFFX/Y/Z of both slots).\nDual antenna: this receiver has two antennas. The baseline runs from its main antenna\n(SENS_GNSS0_OFFX/Y/Z) to its auxiliary antenna (SENS_GNSS0_AUXX/Y/Z).\n\n", "name": "SENS_GNSS0_HDG", "shortDesc": "GNSS 0 heading setup", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Moving base rover", "value": 1}, {"description": "Dual antenna", "value": 2}]}, {"category": "System", "default": 0, "group": "Sensors", "longDesc": "Device ID of the GPS receiver for antenna offset slot 0.\nSet to 0 to disable this slot. When all slots are 0, offsets are\nmatched by uORB instance index (only reliable for serial GPS).\n\n", "name": "SENS_GNSS0_ID", "shortDesc": "GPS 0 device ID", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Sensors", "longDesc": "Forward axis relative to vehicle centre of gravity.\nMatched to physical GPS receiver via SENS_GNSS0_ID.\n\n", "name": "SENS_GNSS0_OFFX", "shortDesc": "GPS 0 antenna X position", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Sensors", "longDesc": "Right axis relative to vehicle centre of gravity.\nMatched to physical GPS receiver via SENS_GNSS0_ID.\n\n", "name": "SENS_GNSS0_OFFY", "shortDesc": "GPS 0 antenna Y position", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Sensors", "longDesc": "Down axis relative to vehicle centre of gravity.\nMatched to physical GPS receiver via SENS_GNSS0_ID.\n\n", "name": "SENS_GNSS0_OFFZ", "shortDesc": "GPS 0 antenna Z position", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Sensors", "longDesc": "Forward axis relative to vehicle centre of gravity, of the receiver's second antenna.\nUsed when SENS_GNSS1_HDG is Dual antenna.\n\n", "name": "SENS_GNSS1_AUXX", "shortDesc": "GNSS 1 auxiliary antenna X position", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Sensors", "longDesc": "Right axis relative to vehicle centre of gravity, of the receiver's second antenna.\nUsed when SENS_GNSS1_HDG is Dual antenna.\n\n", "name": "SENS_GNSS1_AUXY", "shortDesc": "GNSS 1 auxiliary antenna Y position", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Sensors", "longDesc": "Down axis relative to vehicle centre of gravity, of the receiver's second antenna.\nUsed when SENS_GNSS1_HDG is Dual antenna.\n\n", "name": "SENS_GNSS1_AUXZ", "shortDesc": "GNSS 1 auxiliary antenna Z position", "type": "Float", "units": "m"}, {"category": "Standard", "default": 110, "group": "Sensors", "longDesc": "GPS measurement delay relative to IMU measurements.\nMatched to physical GPS receiver via SENS_GNSS1_ID.\nOnly applied when the GPS driver does not provide its own\ntimestamp_sample correction.\n\n", "max": 300, "min": 0, "name": "SENS_GNSS1_DELAY", "shortDesc": "GPS 1 measurement delay", "type": "Int32", "units": "ms"}, {"category": "Standard", "default": 0, "group": "Sensors", "longDesc": "How the receiver in slot 1 (matched via SENS_GNSS1_ID) measures its dual antenna heading.\nThe heading is the bearing of the baseline between two antennas, and is only used when the\nbaseline length the receiver reports is within 20% of the configured one.\nMoving base rover: this receiver is the rover of a moving base pair, the moving base is the\nreceiver in the other slot. The baseline runs from the moving base's antenna to this\nreceiver's antenna (SENS_GNSSn_OFFX/Y/Z of both slots).\nDual antenna: this receiver has two antennas. The baseline runs from its main antenna\n(SENS_GNSS1_OFFX/Y/Z) to its auxiliary antenna (SENS_GNSS1_AUXX/Y/Z).\n\n", "name": "SENS_GNSS1_HDG", "shortDesc": "GNSS 1 heading setup", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Moving base rover", "value": 1}, {"description": "Dual antenna", "value": 2}]}, {"category": "System", "default": 0, "group": "Sensors", "longDesc": "Device ID of the GPS receiver for antenna offset slot 1.\nSet to 0 to disable this slot. When all slots are 0, offsets are\nmatched by uORB instance index (only reliable for serial GPS).\n\n", "name": "SENS_GNSS1_ID", "shortDesc": "GPS 1 device ID", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Sensors", "longDesc": "Forward axis relative to vehicle centre of gravity.\nMatched to physical GPS receiver via SENS_GNSS1_ID.\n\n", "name": "SENS_GNSS1_OFFX", "shortDesc": "GPS 1 antenna X position", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Sensors", "longDesc": "Right axis relative to vehicle centre of gravity.\nMatched to physical GPS receiver via SENS_GNSS1_ID.\n\n", "name": "SENS_GNSS1_OFFY", "shortDesc": "GPS 1 antenna Y position", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Sensors", "longDesc": "Down axis relative to vehicle centre of gravity.\nMatched to physical GPS receiver via SENS_GNSS1_ID.\n\n", "name": "SENS_GNSS1_OFFZ", "shortDesc": "GPS 1 antenna Z position", "type": "Float", "units": "m"}, {"category": "Standard", "default": -1, "group": "Sensors", "longDesc": "The primary receiver is used while it passes the strict checks (GNSS_REQ_*), and while disarmed whenever it publishes. In flight, the other receiver is used when the primary fails its checks (GNSS_CHECK) or stops publishing for 2 s, and then for the rest of the flight unless it fails too. The other receiver is also used once it has been better through a hold: when the primary failed the strict checks while the other passed them, or when the primary was usable for a clearly smaller share of the last 10 s or so (availability lower by 0.2). The primary is used again once it has been better through the hold. The hold is 10 s and doubles with every such switch in a flight, so the first return takes 20 s. With Auto, the moving base of a moving base pair (SENS_GNSSn_HDG) is the primary. Without a primary, a receiver that passes the strict checks is preferred, and among those one with an RTK fixed solution. To make a DroneCAN receiver the primary, set its node ID (2 to 127). GPS_RAW_INT reports the primary receiver, or the first receiver to publish if there is no primary.\n", "max": 127, "min": -1, "name": "SENS_GNSS_PRIME", "shortDesc": "Multi GPS primary instance", "type": "Int32"}, {"category": "System", "default": 1, "group": "Sensors", "longDesc": "Automatically initialize IMU (accel/gyro) calibration from bias estimates if available.\n", "name": "SENS_IMU_AUTOCAL", "shortDesc": "IMU auto calibration", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "System", "default": 1, "group": "Sensors", "longDesc": "Notify the user if the IMU is clipping\n", "name": "SENS_IMU_CLPNOTI", "shortDesc": "IMU notify clipping", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "System", "default": 1, "group": "Sensors", "name": "SENS_IMU_MODE", "rebootRequired": true, "shortDesc": "Sensors hub IMU mode", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Publish primary IMU selection", "value": 1}]}, {"category": "System", "default": 0, "group": "Sensors", "longDesc": "Automatically initialize magnetometer calibration from bias estimate if available. The estimate only captures hard-iron offsets, so a full calibration is still recommended.\n", "name": "SENS_MAG_AUTOCAL", "shortDesc": "Magnetometer auto calibration", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 1, "group": "Sensors", "longDesc": "During calibration attempt to automatically determine the rotation of external magnetometers.\n", "name": "SENS_MAG_AUTOROT", "shortDesc": "Automatically set external rotations", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "System", "default": 1, "group": "Sensors", "name": "SENS_MAG_MODE", "rebootRequired": true, "shortDesc": "Sensors hub mag mode", "type": "Int32", "values": [{"description": "Publish all magnetometers", "value": 0}, {"description": "Publish primary magnetometer", "value": 1}]}, {"category": "Standard", "default": 15.0, "group": "Sensors", "longDesc": "Magnetometer data maximum publication rate. This is an upper bound,\nactual magnetometer data rate is still dependent on the sensor.\n", "max": 200.0, "min": 1.0, "name": "SENS_MAG_RATE", "rebootRequired": true, "shortDesc": "Magnetometer max rate", "type": "Float", "units": "Hz"}, {"category": "Standard", "default": 63, "group": "Sensors", "longDesc": "If set to two side calibration, only the offsets are estimated, the scale\ncalibration is left unchanged. Thus an initial six side calibration is\nrecommended.\n\nBits:\nORIENTATION_TAIL_DOWN = 1\nORIENTATION_NOSE_DOWN = 2\nORIENTATION_LEFT = 4\nORIENTATION_RIGHT = 8\nORIENTATION_UPSIDE_DOWN = 16\nORIENTATION_RIGHTSIDE_UP = 32\n", "max": 63, "min": 34, "name": "SENS_MAG_SIDES", "shortDesc": "Bitfield selecting mag sides for calibration", "type": "Int32", "values": [{"description": "Two side calibration", "value": 34}, {"description": "Three side calibration", "value": 38}, {"description": "Six side calibration", "value": 63}]}, {"category": "Standard", "default": 1, "group": "Septentrio", "longDesc": "By default, the receiver is automatically configured. Sometimes it may be used for multiple purposes.\nIf the offered parameters aren't sufficient, this parameter can be disabled to have full control of the receiver configuration.\nA good way to use this is to enable automatic configuration, let the receiver be configured, and then disable it to make manual adjustments.\n\n", "name": "SEP_AUTO_CONFIG", "rebootRequired": true, "shortDesc": "Toggle automatic receiver configuration", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"bitmask": [{"description": "GPS", "index": 0}, {"description": "GLONASS", "index": 1}, {"description": "Galileo", "index": 2}, {"description": "SBAS", "index": 3}, {"description": "BeiDou", "index": 4}], "category": "Standard", "default": 0, "group": "Septentrio", "longDesc": "Choice of which constellations the receiver should use for PVT computation.\n\nWhen this is 0, the constellation usage isn't changed.\n\n", "max": 63, "min": 0, "name": "SEP_CONST_USAGE", "rebootRequired": true, "shortDesc": "Usage of different constellations", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "Septentrio", "longDesc": "Log raw communication between the driver and connected receivers.\nFor example, \"To receiver\" will log all commands and corrections sent by the driver to the receiver.\n\n", "max": 3, "min": 0, "name": "SEP_DUMP_COMM", "shortDesc": "Log GPS communication data", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "From receiver", "value": 1}, {"description": "To receiver", "value": 2}, {"description": "Both", "value": 3}]}, {"category": "Standard", "default": 0, "group": "Septentrio", "longDesc": "Setup and expected use of the hardware.\n\n- Default: Use two receivers as completely separate instances.\n- Moving base: Use two receivers in a rover & moving base setup for heading.\n\n", "max": 1, "min": 0, "name": "SEP_HARDW_SETUP", "rebootRequired": true, "shortDesc": "Setup and expected use of the hardware", "type": "Int32", "values": [{"description": "Default", "value": 0}, {"description": "Moving base", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Septentrio", "longDesc": "When the receiver is already set up to log data, this decides whether extra logged data should be added or overwrite existing data.\n\n", "name": "SEP_LOG_FORCE", "rebootRequired": true, "shortDesc": "Whether to overwrite or add to existing logging", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Septentrio", "longDesc": "Select the frequency at which the connected receiver should log data to its internal storage.\n\n", "max": 10, "min": 0, "name": "SEP_LOG_HZ", "rebootRequired": true, "shortDesc": "Logging frequency for the receiver", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "0.1 Hz", "value": 1}, {"description": "0.2 Hz", "value": 2}, {"description": "0.5 Hz", "value": 3}, {"description": "1 Hz", "value": 4}, {"description": "2 Hz", "value": 5}, {"description": "5 Hz", "value": 6}, {"description": "10 Hz", "value": 7}, {"description": "20 Hz", "value": 8}, {"description": "25 Hz", "value": 9}, {"description": "50 Hz", "value": 10}]}, {"category": "Standard", "default": 2, "group": "Septentrio", "longDesc": "Select the level of detail that needs to be logged by the receiver.\n\n", "max": 3, "min": 0, "name": "SEP_LOG_LEVEL", "rebootRequired": true, "shortDesc": "Logging level for the receiver", "type": "Int32", "values": [{"description": "Lite", "value": 0}, {"description": "Basic", "value": 1}, {"description": "Default", "value": 2}, {"description": "Full", "value": 3}]}, {"category": "Standard", "default": 1, "group": "Septentrio", "longDesc": "The output frequency of the main SBF blocks needed for PVT information.\n\n", "max": 3, "min": 0, "name": "SEP_OUTP_HZ", "rebootRequired": true, "shortDesc": "Output frequency of main SBF blocks", "type": "Int32", "values": [{"description": "5 Hz", "value": 0}, {"description": "10 Hz", "value": 1}, {"description": "20 Hz", "value": 2}, {"description": "25 Hz", "value": 3}]}, {"category": "Standard", "default": 0, "group": "Septentrio", "longDesc": "Enable publication of satellite info (ORB_ID(satellite_info)) if possible.\n\n", "name": "SEP_SAT_INFO", "rebootRequired": true, "shortDesc": "Enable sat info", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 2, "group": "Septentrio", "longDesc": "The stream the autopilot sets up on the receiver to output the logging data.\n\nSet this to another value if the default stream is already used for another purpose.\n\n", "max": 10, "min": 1, "name": "SEP_STREAM_LOG", "rebootRequired": true, "shortDesc": "Logging stream used during automatic configuration", "type": "Int32"}, {"category": "Standard", "default": 1, "group": "Septentrio", "longDesc": "The stream the autopilot sets up on the receiver to output the main data.\n\nSet this to another value if the default stream is already used for another purpose.\n\n", "max": 10, "min": 1, "name": "SEP_STREAM_MAIN", "rebootRequired": true, "shortDesc": "Main stream used during automatic configuration", "type": "Int32"}, {"category": "Standard", "default": 1, "group": "Simulation In Hardware", "name": "SIH_DISTSNSR_EN", "shortDesc": "Enable the simulated downward facing distance sensor", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 4, "default": 100.0, "group": "Simulation In Hardware", "increment": 0.01, "longDesc": "The signal quality degrades over the last 20% of the range. Beyond the maximum range\nthe sensor reports a saturated reading with a zero signal quality.\n", "max": 1000.0, "min": 0.0, "name": "SIH_DISTSNSR_MAX", "shortDesc": "distance sensor maximum range", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 4, "default": 0.0, "group": "Simulation In Hardware", "increment": 0.01, "longDesc": "Readings closer than this saturate at the minimum range\nand are reported with a zero signal quality.\n", "max": 10.0, "min": 0.0, "name": "SIH_DISTSNSR_MIN", "shortDesc": "distance sensor minimum range", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.01, "group": "Simulation In Hardware", "longDesc": "Gaussian noise added to the simulated distance sensor measurements.\nSet to 0 to disable noise.\n", "max": 10.0, "min": 0.0, "name": "SIH_DISTSNSR_NOI", "shortDesc": "Distance sensor measurement noise standard deviation", "type": "Float", "units": "m"}, {"category": "Standard", "default": -1.0, "group": "Simulation In Hardware", "longDesc": "Set SIH_DISTSNSR_EN to 0 to disable the distance sensor.\n", "name": "SIH_DISTSNSR_OVR", "shortDesc": "if >= 0 the distance sensor measures will be overridden by this value", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Simulation In Hardware", "min": 0.0, "name": "SIH_F_CP0", "shortDesc": "Forward thruster static power coefficient", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Simulation In Hardware", "longDesc": "CP(J) = CP0 + CP1*J + CP2*J^2\n", "name": "SIH_F_CP1", "shortDesc": "Forward thruster power coefficient 1", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Simulation In Hardware", "longDesc": "CP(J) = CP0 + CP1*J + CP2*J^2\n", "max": 0.0, "name": "SIH_F_CP2", "shortDesc": "Forward thruster power coefficient 2", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Simulation In Hardware", "min": 0.0, "name": "SIH_F_CT0", "shortDesc": "Forward thruster static thrust coefficient", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Simulation In Hardware", "longDesc": "CT(J) = CT0 + CT1*J + CT2*J^2\n", "name": "SIH_F_CT1", "shortDesc": "Forward thruster thrust coefficient 1", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Simulation In Hardware", "longDesc": "CT(J) = CT0 + CT1*J + CT2*J^2\n", "max": 0.0, "name": "SIH_F_CT2", "shortDesc": "Forward thruster thrust coefficient 2", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.1, "group": "Simulation In Hardware", "min": 0.1, "name": "SIH_F_DIA_INCH", "shortDesc": "Forward thruster propeller diameter in inches", "type": "Float"}, {"category": "Standard", "decimalPlaces": 4, "default": 0.0165, "group": "Simulation In Hardware", "longDesc": "This is used for the Fixed-Wing, Tailsitter, or pusher of the Standard VTOL\nif SIH_F_CP0 <= 0.\nIf SIH_F_CP0 > 0, propeller model with advance ratio J is used\nand this parameter value is overridden at simulation startup.\n", "min": 0.0, "name": "SIH_F_Q_MAX", "shortDesc": "Forward thruster max torque (Nm)", "type": "Float", "units": "Nm"}, {"category": "Standard", "decimalPlaces": 1, "default": 6000.0, "group": "Simulation In Hardware", "min": 0.1, "name": "SIH_F_RPM_MAX", "shortDesc": "Forward thruster max RPM", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 2.0, "group": "Simulation In Hardware", "longDesc": "This is used for the Fixed-Wing, Tailsitter, or pusher of the Standard VTOL\nif SIH_F_CT0 <= 0.\nIf SIH_F_CT0 > 0, propeller model with advance ratio J is used\nand this parameter value is overridden at simulation startup.\n", "min": 0.0, "name": "SIH_F_T_MAX", "shortDesc": "Forward thruster max thrust (N)", "type": "Float", "units": "N"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.025, "group": "Simulation In Hardware", "increment": 0.005, "longDesc": "The inertia is a 3 by 3 symmetric matrix.\nIt represents the difficulty of the vehicle to modify its angular rate.\n", "min": 0.0, "name": "SIH_IXX", "shortDesc": "Vehicle inertia about X axis", "type": "Float", "units": "kg m^2"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Simulation In Hardware", "increment": 0.005, "longDesc": "The inertia is a 3 by 3 symmetric matrix.\nThis value can be set to 0 for a quad symmetric about its center of mass.\n", "name": "SIH_IXY", "shortDesc": "Vehicle cross term inertia xy", "type": "Float", "units": "kg m^2"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Simulation In Hardware", "increment": 0.005, "longDesc": "The inertia is a 3 by 3 symmetric matrix.\nThis value can be set to 0 for a quad symmetric about its center of mass.\n", "name": "SIH_IXZ", "shortDesc": "Vehicle cross term inertia xz", "type": "Float", "units": "kg m^2"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.025, "group": "Simulation In Hardware", "increment": 0.005, "longDesc": "The inertia is a 3 by 3 symmetric matrix.\nIt represents the difficulty of the vehicle to modify its angular rate.\n", "min": 0.0, "name": "SIH_IYY", "shortDesc": "Vehicle inertia about Y axis", "type": "Float", "units": "kg m^2"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Simulation In Hardware", "increment": 0.005, "longDesc": "The inertia is a 3 by 3 symmetric matrix.\nThis value can be set to 0 for a quad symmetric about its center of mass.\n", "name": "SIH_IYZ", "shortDesc": "Vehicle cross term inertia yz", "type": "Float", "units": "kg m^2"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.03, "group": "Simulation In Hardware", "increment": 0.005, "longDesc": "The inertia is a 3 by 3 symmetric matrix.\nIt represents the difficulty of the vehicle to modify its angular rate.\n", "min": 0.0, "name": "SIH_IZZ", "shortDesc": "Vehicle inertia about Z axis", "type": "Float", "units": "kg m^2"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Simulation In Hardware", "increment": 0.05, "longDesc": "Physical coefficient representing the friction with air particles.\nThe greater this value, the slower the quad will move.\n\nDrag force function of velocity: D=-KDV*V.\nThe maximum freefall velocity can be computed as V=10*MASS/KDV [m/s]\n", "min": 0.0, "name": "SIH_KDV", "shortDesc": "First order drag coefficient", "type": "Float", "units": "N/(m/s)"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.025, "group": "Simulation In Hardware", "increment": 0.005, "longDesc": "Physical coefficient representing the friction with air particles during rotations.\nThe greater this value, the slower the quad will rotate.\n\nAerodynamic moment function of body rate: Ma=-KDW*W_B.\nThis value can be set to 0 if unknown.\n", "min": 0.0, "name": "SIH_KDW", "shortDesc": "First order angular damper coefficient", "type": "Float", "units": "Nm/(rad/s)"}, {"category": "Standard", "decimalPlaces": 2, "default": 489.4, "group": "Simulation In Hardware", "increment": 0.01, "longDesc": "This value represents the Above Mean Sea Level (AMSL) altitude where the simulation begins.\n\nIf using FlightGear as a visual animation,\nthis value can be tweaked such that the vehicle lies on the ground at takeoff.\n\nLAT0, LON0, H0, MU_X, MU_Y, and MU_Z should ideally be consistent among each others\nto represent a physical ground location on Earth.\n", "max": 8848.0, "min": -420.0, "name": "SIH_LOC_H0", "shortDesc": "Initial AMSL ground altitude", "type": "Float", "units": "m"}, {"category": "Standard", "default": 47.397742, "group": "Simulation In Hardware", "longDesc": "This value represents the North-South location on Earth where the simulation begins.\n\nLAT0, LON0, H0, MU_X, MU_Y, and MU_Z should ideally be consistent among each others\nto represent a physical ground location on Earth.\n", "max": 90.0, "min": -90.0, "name": "SIH_LOC_LAT0", "shortDesc": "Initial geodetic latitude", "type": "Float", "units": "deg"}, {"category": "Standard", "default": 8.545594, "group": "Simulation In Hardware", "longDesc": "This value represents the East-West location on Earth where the simulation begins.\n\nLAT0, LON0, H0, MU_X, MU_Y, and MU_Z should ideally be consistent among each others\nto represent a physical ground location on Earth.\n", "max": 180.0, "min": -180.0, "name": "SIH_LOC_LON0", "shortDesc": "Initial geodetic longitude", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "Simulation In Hardware", "increment": 0.01, "longDesc": "This value represents the initial heading (yaw) of the simulated vehicle at the start of the simulation.\n", "max": 3.14159, "min": -3.14159, "name": "SIH_LOC_YAW0", "shortDesc": "Initial heading (yaw) of the simulated vehicle", "type": "Float", "units": "rad"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.2, "group": "Simulation In Hardware", "increment": 0.05, "longDesc": "This is the arm length generating the pitching moment\n\nThis value can be measured with a ruler.\nThis corresponds to half the distance between the front and rear motors.\n", "min": 0.0, "name": "SIH_L_PITCH", "shortDesc": "Pitch arm length", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.2, "group": "Simulation In Hardware", "increment": 0.05, "longDesc": "This is the arm length generating the rolling moment\n\nThis value can be measured with a ruler.\nThis corresponds to half the distance between the left and right motors.\n", "min": 0.0, "name": "SIH_L_ROLL", "shortDesc": "Roll arm length", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Simulation In Hardware", "increment": 0.1, "longDesc": "This value can be measured by weighting the quad on a scale.\n", "min": 0.0, "name": "SIH_MASS", "shortDesc": "Vehicle mass", "type": "Float", "units": "kg"}, {"category": "Standard", "default": 0, "group": "Simulation In Hardware", "longDesc": "The simulated sensor reports the integrated flow only. The flow module completes the\nsample with the vehicle gyro and the downward facing distance sensor, which therefore\nhas to be enabled as well (SIH_DISTSNSR_EN) for the flow to be usable by the estimator.\n", "name": "SIH_OF_EN", "shortDesc": "Enable the simulated optical flow sensor", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 1, "default": 30.0, "group": "Simulation In Hardware", "longDesc": "Above this distance to the ground the simulated sensor cannot track the ground image\nanymore and reports a zero quality.\n", "min": 1.0, "name": "SIH_OF_H_MAX", "shortDesc": "Optical flow maximum ground distance", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.05, "group": "Simulation In Hardware", "longDesc": "Gaussian noise added to the simulated flow rate.\nSet to 0 to disable noise.\n", "max": 5.0, "min": 0.0, "name": "SIH_OF_NOISE", "shortDesc": "Optical flow measurement noise standard deviation", "type": "Float", "units": "rad/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 12.0, "group": "Simulation In Hardware", "longDesc": "The simulated sensor integrates the flow over one publication interval.\n", "max": 100.0, "min": 1.0, "name": "SIH_OF_RATE", "shortDesc": "Optical flow publication rate", "type": "Float", "units": "Hz"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.1, "group": "Simulation In Hardware", "increment": 0.05, "longDesc": "This is the maximum torque delivered by one propeller\nwhen the motor is running at full speed.\n\nThis value is usually about few percent of the maximum thrust force.\n\nRefer to SIH_F_Q_MAX for the propeller torque for FW, Tailsitter, and VTOL pusher.\n", "min": 0.0, "name": "SIH_Q_MAX", "shortDesc": "Max multicopter propeller torque", "type": "Float", "units": "Nm"}, {"category": "Standard", "decimalPlaces": 1, "default": 30.0, "group": "Simulation In Hardware", "longDesc": "Gaussian noise added to simulated ranging beacon measurements. Set to 0 to disable noise.\n", "max": 100.0, "min": 0.0, "name": "SIH_RNGBC_NOISE", "shortDesc": "Ranging beacon measurement noise standard deviation", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 5.0, "group": "Simulation In Hardware", "increment": 0.5, "longDesc": "This is the maximum force delivered by one propeller\nwhen the motor is running at full speed.\n\nThis value is usually about 5 times the mass of the quadrotor.\n\nRefer to SIH_F_T_MAX for the thrust for FW, Tailsitter, and VTOL pusher.\n", "min": 0.0, "name": "SIH_T_MAX", "shortDesc": "Max multicopter propeller thrust force", "type": "Float", "units": "N"}, {"category": "Standard", "default": 0.05, "group": "Simulation In Hardware", "longDesc": "the time taken for the thruster to step from 0 to 100% should be about 4 times tau\n", "name": "SIH_T_TAU", "shortDesc": "thruster time constant tau", "type": "Float", "units": "s"}, {"category": "Standard", "default": 0, "group": "Simulation In Hardware", "name": "SIH_VEHICLE_TYPE", "rebootRequired": true, "shortDesc": "Vehicle type", "type": "Int32", "values": [{"description": "Quadcopter", "value": 0}, {"description": "Fixed-Wing", "value": 1}, {"description": "Tailsitter", "value": 2}, {"description": "Standard VTOL", "value": 3}, {"description": "Hexacopter", "value": 4}, {"description": "Rover Ackermann", "value": 5}, {"description": "Rover Differential", "value": 6}]}, {"category": "Standard", "default": 0.0, "group": "Simulation In Hardware", "name": "SIH_WIND_E", "shortDesc": "Wind velocity from east direction", "type": "Float", "units": "m/s"}, {"category": "Standard", "default": 0.0, "group": "Simulation In Hardware", "name": "SIH_WIND_N", "shortDesc": "Wind velocity from north direction", "type": "Float", "units": "m/s"}, {"bitmask": [{"description": "Stuck", "index": 0}, {"description": "Drift", "index": 1}], "category": "Standard", "default": 0, "group": "Simulator", "longDesc": "Stuck: freeze the measurement to the current location\nDrift: add a linearly growing bias to the sensor data\n", "max": 3, "min": 0, "name": "SIM_AGP_FAIL", "shortDesc": "AGP failure mode", "type": "Int32"}, {"category": "Standard", "default": 0.0, "group": "Simulator", "name": "SIM_BARO_OFF_P", "shortDesc": "simulated barometer pressure offset", "type": "Float", "units": "Pa"}, {"category": "Standard", "default": 0.0, "group": "Simulator", "name": "SIM_BARO_OFF_T", "shortDesc": "simulated barometer temperature offset", "type": "Float", "units": "celcius"}, {"category": "Standard", "default": 10, "group": "Simulator", "max": 50, "min": 0, "name": "SIM_GPS_USED", "shortDesc": "simulated GPS number of satellites used", "type": "Int32"}, {"category": "Standard", "default": 0.0, "group": "Simulator", "name": "SIM_MAG_OFFSET_X", "shortDesc": "simulated magnetometer X offset", "type": "Float", "units": "gauss"}, {"category": "Standard", "default": 0.0, "group": "Simulator", "name": "SIM_MAG_OFFSET_Y", "shortDesc": "simulated magnetometer Y offset", "type": "Float", "units": "gauss"}, {"category": "Standard", "default": 0.0, "group": "Simulator", "name": "SIM_MAG_OFFSET_Z", "shortDesc": "simulated magnetometer Z offset", "type": "Float", "units": "gauss"}, {"category": "Standard", "default": 0, "group": "System", "longDesc": "If enabled, a SYS_AUTOCONFIG reset overwrites stored sensor calibration with the airframe's built-in defaults.\nEnable when the airframe ships its own calibration.\n", "name": "SYS_AUTOCFG_CAL", "shortDesc": "Sensor calibration in SYS_AUTOCONFIG reset", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "System", "longDesc": "Set to 1 to reset parameters on next system startup (setting defaults).\nPlatform-specific values are used if available.\n", "name": "SYS_AUTOCONFIG", "shortDesc": "Automatically configure default values", "type": "Int32", "values": [{"description": "Keep parameters", "value": 0}, {"description": "Reset parameters to airframe defaults", "value": 1}]}, {"category": "Standard", "default": 0, "group": "System", "longDesc": "CHANGING THIS VALUE REQUIRES A RESTART. Defines the auto-start script used to bootstrap the system.\n", "max": 9999999, "min": 0, "name": "SYS_AUTOSTART", "rebootRequired": true, "shortDesc": "Auto-start script index", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "System", "longDesc": "If enabled, update the bootloader on the next boot. DroneCAN nodes\nupdate within about 2 seconds of it being set, without rebooting.\n\nWARNING: do not cut the power during an update process, otherwise you will\nhave to recover using some alternative method (e.g. JTAG).\n\nInstructions:\n- Insert an SD card\n- Enable this parameter\n- Reboot the board (plug the power or send a reboot command)\n- Wait until the board comes back up (or at least 2 minutes)\n- If it does not come back, check the file bootlog.txt on the SD card\n", "name": "SYS_BL_UPDATE", "rebootRequired": true, "shortDesc": "Bootloader update", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "System", "longDesc": "Enable auto start of accelerometer thermal calibration at the next power up\n\n0 : Set to 0 to do nothing\n1 : Set to 1 to start a calibration at next boot\nThis parameter is reset to zero when the temperature calibration starts.\n\ndefault (0, no calibration)\n", "max": 1, "min": 0, "name": "SYS_CAL_ACCEL", "shortDesc": "Auto start accel thermal calibration on next boot", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "System", "longDesc": "Enable auto start of barometer thermal calibration at the next power up\n\n0 : Set to 0 to do nothing\n1 : Set to 1 to start a calibration at next boot\nThis parameter is reset to zero when the temperature calibration starts.\n\ndefault (0, no calibration)\n", "max": 1, "min": 0, "name": "SYS_CAL_BARO", "shortDesc": "Auto start baro thermal calibration on next boot", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "System", "longDesc": "Enable auto start of rate gyro thermal calibration at the next power up\n\n0 : Set to 0 to do nothing\n1 : Set to 1 to start a calibration at next boot\nThis parameter is reset to zero when the temperature calibration starts.\n\ndefault (0, no calibration)\n", "max": 1, "min": 0, "name": "SYS_CAL_GYRO", "shortDesc": "Auto start gyro thermal calibration on next boot", "type": "Int32"}, {"category": "Standard", "default": 24, "group": "System", "longDesc": "A temperature increase greater than this value is required during calibration.\nCalibration will complete for each sensor when the temperature increase above the starting temperature exceeds the value set by SYS_CAL_TDEL.\nIf the temperature rise is insufficient, the calibration will continue indefinitely and the board will need to be repowered to exit.\n", "min": 10, "name": "SYS_CAL_TDEL", "shortDesc": "Required temperature rise during thermal calibration", "type": "Int32", "units": "celcius"}, {"category": "Standard", "default": 10, "group": "System", "longDesc": "Temperature calibration will not start if the temperature of any sensor is higher than the value set by SYS_CAL_TMAX.\n", "name": "SYS_CAL_TMAX", "shortDesc": "Maximum starting temperature for thermal calibration", "type": "Int32", "units": "celcius"}, {"category": "Standard", "default": 5, "group": "System", "longDesc": "Temperature calibration for each sensor will ignore data if the temperature is lower than the value set by SYS_CAL_TMIN.\n", "name": "SYS_CAL_TMIN", "shortDesc": "Minimum starting temperature for thermal calibration", "type": "Int32", "units": "celcius"}, {"category": "Standard", "default": 0, "group": "System", "longDesc": "If the board supports persistent storage (i.e., the KConfig variable DATAMAN_PERSISTENT_STORAGE is set),\nthe 'Default storage' backend uses a file on persistent storage. If not supported, this backend uses\nnon-persistent storage in RAM.\n", "name": "SYS_DM_BACKEND", "rebootRequired": true, "shortDesc": "Dataman storage backend", "type": "Int32", "values": [{"description": "Dataman disabled", "value": -1}, {"description": "Default storage", "value": 0}, {"description": "RAM storage", "value": 1}]}, {"category": "Standard", "default": 0, "group": "System", "longDesc": "If enabled, future sensor calibrations will be stored to /fs/mtd_caldata.\n\nNote: this is only supported on boards with a separate calibration storage\n/fs/mtd_caldata.\n", "name": "SYS_FAC_CAL_MODE", "shortDesc": "Enable factory calibration mode", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "All sensors", "value": 1}, {"description": "All sensors except mag", "value": 2}]}, {"category": "Standard", "default": 1, "group": "System", "longDesc": "Disable this if the board has no barometer, such as some of the Omnibus\nF4 SD variants.\nIf disabled, the preflight checks will not check for the presence of a\nbarometer.\n", "name": "SYS_HAS_BARO", "rebootRequired": true, "shortDesc": "Control if the vehicle has a barometer", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 1, "group": "System", "longDesc": "Disable this if the system has no GPS.\nIf disabled, the sensors hub will not process sensor_gnss,\nand GPS will not be available for the rest of the system.\n", "name": "SYS_HAS_GPS", "rebootRequired": true, "shortDesc": "Control if the vehicle has a GPS", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 1, "group": "System", "longDesc": "0: System has no magnetometer, preflight checks should pass without one.\n1-N: Require the presence of N magnetometer sensors for check to pass.\n", "name": "SYS_HAS_MAG", "rebootRequired": true, "shortDesc": "Control if and how many magnetometers are expected", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "System", "longDesc": "Set this to 0 if the board has no airspeed sensor.\nIf set to 0, the preflight checks will not check for the presence of an\nairspeed sensor.\n", "max": 1, "min": 0, "name": "SYS_HAS_NUM_ASPD", "shortDesc": "Control if the vehicle has an airspeed sensor", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "System", "longDesc": "The preflight check will fail if fewer than this number of distance sensors with valid data is present.\n\nDisable the check with 0.\n", "max": 4, "min": 0, "name": "SYS_HAS_NUM_DIST", "shortDesc": "Number of distance sensors to check being available", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "System", "longDesc": "0: No minimum receiver count required. Position divergence between two receivers\nand loss of a GNSS receiver still produce a warning but never trigger the\nCOM_GNSSLOSS_ACT failsafe action.\n1-N: Require the presence of N GNSS receivers for arming.\nIf the active count drops below this value in flight, COM_GNSSLOSS_ACT is triggered.\nWhen set to 2, position divergence between the two receivers also blocks arming when not armed and triggers COM_GNSSLOSS_ACT in flight.\n", "max": 2, "min": 0, "name": "SYS_HAS_NUM_GNSS", "shortDesc": "Control if and how many GNSS receivers are required", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "System", "longDesc": "The preflight check will fail if fewer than this number of optical flow sensors with valid data are present.\n", "max": 1, "min": 0, "name": "SYS_HAS_NUM_OF", "shortDesc": "Number of optical flow sensors required to be available", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "System", "longDesc": "While enabled the system will boot in Hardware-In-The-Loop (HITL)\nor Simulation-In-Hardware (SIH) mode and not enable all sensors and checks.\nWhen disabled the same vehicle can be flown normally.\n\nSet to 'external HITL', if the system should perform as if it were a real\nvehicle (the only difference to a real system is then only the parameter\nvalue, which can be used for log analysis).\n", "name": "SYS_HITL", "rebootRequired": true, "shortDesc": "Enable HITL/SIH mode on next boot", "type": "Int32", "values": [{"description": "external HITL", "value": -1}, {"description": "HITL and SIH disabled", "value": 0}, {"description": "HITL enabled", "value": 1}, {"description": "SIH enabled", "value": 2}]}, {"category": "Standard", "default": 1, "group": "System", "longDesc": "This is used internally only: an airframe configuration might set an expected\nparameter version value via PARAM_DEFAULTS_VER. This is checked on bootup\nagainst SYS_PARAM_VER, and if they do not match, parameters are reset and\nreloaded from the airframe configuration.\n", "min": 0, "name": "SYS_PARAM_VER", "shortDesc": "Parameter version", "type": "Int32"}, {"category": "Standard", "default": 1.0, "group": "System", "longDesc": "Set to 0 to disable, 1 for maximum brightness\n", "name": "SYS_RGB_MAXBRT", "shortDesc": "RGB Led brightness limit", "type": "Float", "units": "%"}, {"category": "Standard", "default": 1, "group": "System", "name": "SYS_STCK_EN", "shortDesc": "Enable stack checking", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"bitmask": [{"description": "GPS time", "index": 0}, {"description": "MAVLink time", "index": 1}, {"description": "Software RTC time", "index": 2}, {"description": "DDS time", "index": 3}, {"description": "Input simulation time", "index": 4}], "category": "Standard", "default": 31, "group": "System", "longDesc": "This parameter selects the source allowed to set the system time.\nThe default value enables all sources.\n", "max": 31, "min": 0, "name": "SYS_TIME_SRC", "rebootRequired": true, "shortDesc": "Select the source of the system time", "type": "Int32"}, {"category": "Standard", "default": 2, "group": "Testing", "name": "TEST_1", "shortDesc": "TEST_1", "type": "Int32"}, {"category": "Standard", "default": 4, "group": "Testing", "name": "TEST_2", "shortDesc": "TEST_2", "type": "Int32"}, {"category": "Standard", "default": 5.0, "group": "Testing", "name": "TEST_3", "shortDesc": "TEST_3", "type": "Float"}, {"category": "Standard", "default": 0.01, "group": "Testing", "name": "TEST_D", "shortDesc": "TEST_D", "type": "Float"}, {"category": "Standard", "default": 2.0, "group": "Testing", "name": "TEST_DEV", "shortDesc": "TEST_DEV", "type": "Float"}, {"category": "Standard", "default": 10.0, "group": "Testing", "name": "TEST_D_LP", "shortDesc": "TEST_D_LP", "type": "Float"}, {"category": "Standard", "default": 10.0, "group": "Testing", "name": "TEST_HP", "shortDesc": "TEST_HP", "type": "Float"}, {"category": "Standard", "default": 0.1, "group": "Testing", "name": "TEST_I", "shortDesc": "TEST_I", "type": "Float"}, {"category": "Standard", "default": 1.0, "group": "Testing", "name": "TEST_I_MAX", "shortDesc": "TEST_I_MAX", "type": "Float"}, {"category": "Standard", "default": 10.0, "group": "Testing", "name": "TEST_LP", "shortDesc": "TEST_LP", "type": "Float"}, {"category": "Standard", "default": 1.0, "group": "Testing", "name": "TEST_MAX", "shortDesc": "TEST_MAX", "type": "Float"}, {"category": "Standard", "default": 1.0, "group": "Testing", "name": "TEST_MEAN", "shortDesc": "TEST_MEAN", "type": "Float"}, {"category": "Standard", "default": -1.0, "group": "Testing", "name": "TEST_MIN", "shortDesc": "TEST_MIN", "type": "Float"}, {"category": "Standard", "default": 0.2, "group": "Testing", "name": "TEST_P", "shortDesc": "TEST_P", "type": "Float"}, {"category": "Standard", "default": 12345678, "group": "Testing", "name": "TEST_PARAMS", "shortDesc": "TEST_PARAMS", "type": "Int32"}, {"category": "Standard", "default": 16, "group": "Testing", "name": "TEST_RC2_X", "shortDesc": "TEST_RC2_X", "type": "Int32"}, {"category": "Standard", "default": 8, "group": "Testing", "name": "TEST_RC_X", "shortDesc": "TEST_RC_X", "type": "Int32"}, {"category": "Standard", "default": 0.5, "group": "Testing", "name": "TEST_TRIM", "shortDesc": "TEST_TRIM", "type": "Float"}, {"category": "System", "default": 0, "group": "Thermal Compensation", "name": "TC_A0_ID", "shortDesc": "ID of Accelerometer that the calibration is for", "type": "Int32"}, {"category": "System", "default": 100.0, "group": "Thermal Compensation", "name": "TC_A0_TMAX", "shortDesc": "Accelerometer calibration maximum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A0_TMIN", "shortDesc": "Accelerometer calibration minimum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 25.0, "group": "Thermal Compensation", "name": "TC_A0_TREF", "shortDesc": "Accelerometer calibration reference temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A0_X0_0", "shortDesc": "Accelerometer offset temperature ^0 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A0_X0_1", "shortDesc": "Accelerometer offset temperature ^0 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A0_X0_2", "shortDesc": "Accelerometer offset temperature ^0 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A0_X1_0", "shortDesc": "Accelerometer offset temperature ^1 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A0_X1_1", "shortDesc": "Accelerometer offset temperature ^1 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A0_X1_2", "shortDesc": "Accelerometer offset temperature ^1 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A0_X2_0", "shortDesc": "Accelerometer offset temperature ^2 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A0_X2_1", "shortDesc": "Accelerometer offset temperature ^2 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A0_X2_2", "shortDesc": "Accelerometer offset temperature ^2 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A0_X3_0", "shortDesc": "Accelerometer offset temperature ^3 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A0_X3_1", "shortDesc": "Accelerometer offset temperature ^3 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A0_X3_2", "shortDesc": "Accelerometer offset temperature ^3 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0, "group": "Thermal Compensation", "name": "TC_A1_ID", "shortDesc": "ID of Accelerometer that the calibration is for", "type": "Int32"}, {"category": "System", "default": 100.0, "group": "Thermal Compensation", "name": "TC_A1_TMAX", "shortDesc": "Accelerometer calibration maximum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A1_TMIN", "shortDesc": "Accelerometer calibration minimum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 25.0, "group": "Thermal Compensation", "name": "TC_A1_TREF", "shortDesc": "Accelerometer calibration reference temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A1_X0_0", "shortDesc": "Accelerometer offset temperature ^0 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A1_X0_1", "shortDesc": "Accelerometer offset temperature ^0 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A1_X0_2", "shortDesc": "Accelerometer offset temperature ^0 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A1_X1_0", "shortDesc": "Accelerometer offset temperature ^1 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A1_X1_1", "shortDesc": "Accelerometer offset temperature ^1 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A1_X1_2", "shortDesc": "Accelerometer offset temperature ^1 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A1_X2_0", "shortDesc": "Accelerometer offset temperature ^2 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A1_X2_1", "shortDesc": "Accelerometer offset temperature ^2 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A1_X2_2", "shortDesc": "Accelerometer offset temperature ^2 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A1_X3_0", "shortDesc": "Accelerometer offset temperature ^3 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A1_X3_1", "shortDesc": "Accelerometer offset temperature ^3 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A1_X3_2", "shortDesc": "Accelerometer offset temperature ^3 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0, "group": "Thermal Compensation", "name": "TC_A2_ID", "shortDesc": "ID of Accelerometer that the calibration is for", "type": "Int32"}, {"category": "System", "default": 100.0, "group": "Thermal Compensation", "name": "TC_A2_TMAX", "shortDesc": "Accelerometer calibration maximum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A2_TMIN", "shortDesc": "Accelerometer calibration minimum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 25.0, "group": "Thermal Compensation", "name": "TC_A2_TREF", "shortDesc": "Accelerometer calibration reference temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A2_X0_0", "shortDesc": "Accelerometer offset temperature ^0 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A2_X0_1", "shortDesc": "Accelerometer offset temperature ^0 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A2_X0_2", "shortDesc": "Accelerometer offset temperature ^0 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A2_X1_0", "shortDesc": "Accelerometer offset temperature ^1 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A2_X1_1", "shortDesc": "Accelerometer offset temperature ^1 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A2_X1_2", "shortDesc": "Accelerometer offset temperature ^1 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A2_X2_0", "shortDesc": "Accelerometer offset temperature ^2 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A2_X2_1", "shortDesc": "Accelerometer offset temperature ^2 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A2_X2_2", "shortDesc": "Accelerometer offset temperature ^2 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A2_X3_0", "shortDesc": "Accelerometer offset temperature ^3 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A2_X3_1", "shortDesc": "Accelerometer offset temperature ^3 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A2_X3_2", "shortDesc": "Accelerometer offset temperature ^3 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0, "group": "Thermal Compensation", "name": "TC_A3_ID", "shortDesc": "ID of Accelerometer that the calibration is for", "type": "Int32"}, {"category": "System", "default": 100.0, "group": "Thermal Compensation", "name": "TC_A3_TMAX", "shortDesc": "Accelerometer calibration maximum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A3_TMIN", "shortDesc": "Accelerometer calibration minimum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 25.0, "group": "Thermal Compensation", "name": "TC_A3_TREF", "shortDesc": "Accelerometer calibration reference temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A3_X0_0", "shortDesc": "Accelerometer offset temperature ^0 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A3_X0_1", "shortDesc": "Accelerometer offset temperature ^0 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A3_X0_2", "shortDesc": "Accelerometer offset temperature ^0 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A3_X1_0", "shortDesc": "Accelerometer offset temperature ^1 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A3_X1_1", "shortDesc": "Accelerometer offset temperature ^1 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A3_X1_2", "shortDesc": "Accelerometer offset temperature ^1 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A3_X2_0", "shortDesc": "Accelerometer offset temperature ^2 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A3_X2_1", "shortDesc": "Accelerometer offset temperature ^2 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A3_X2_2", "shortDesc": "Accelerometer offset temperature ^2 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A3_X3_0", "shortDesc": "Accelerometer offset temperature ^3 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A3_X3_1", "shortDesc": "Accelerometer offset temperature ^3 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_A3_X3_2", "shortDesc": "Accelerometer offset temperature ^3 polynomial coefficient - Z axis", "type": "Float"}, {"category": "Standard", "default": 0, "group": "Thermal Compensation", "name": "TC_A_ENABLE", "rebootRequired": true, "shortDesc": "Thermal compensation for accelerometer sensors", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "System", "default": 0, "group": "Thermal Compensation", "name": "TC_B0_ID", "shortDesc": "ID of Barometer that the calibration is for", "type": "Int32"}, {"category": "System", "default": 75.0, "group": "Thermal Compensation", "name": "TC_B0_TMAX", "shortDesc": "Barometer calibration maximum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 5.0, "group": "Thermal Compensation", "name": "TC_B0_TMIN", "shortDesc": "Barometer calibration minimum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 40.0, "group": "Thermal Compensation", "name": "TC_B0_TREF", "shortDesc": "Barometer calibration reference temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B0_X0", "shortDesc": "Barometer offset temperature ^0 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B0_X1", "shortDesc": "Barometer offset temperature ^1 polynomial coefficients", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B0_X2", "shortDesc": "Barometer offset temperature ^2 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B0_X3", "shortDesc": "Barometer offset temperature ^3 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B0_X4", "shortDesc": "Barometer offset temperature ^4 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B0_X5", "shortDesc": "Barometer offset temperature ^5 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0, "group": "Thermal Compensation", "name": "TC_B1_ID", "shortDesc": "ID of Barometer that the calibration is for", "type": "Int32"}, {"category": "System", "default": 75.0, "group": "Thermal Compensation", "name": "TC_B1_TMAX", "shortDesc": "Barometer calibration maximum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 5.0, "group": "Thermal Compensation", "name": "TC_B1_TMIN", "shortDesc": "Barometer calibration minimum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 40.0, "group": "Thermal Compensation", "name": "TC_B1_TREF", "shortDesc": "Barometer calibration reference temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B1_X0", "shortDesc": "Barometer offset temperature ^0 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B1_X1", "shortDesc": "Barometer offset temperature ^1 polynomial coefficients", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B1_X2", "shortDesc": "Barometer offset temperature ^2 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B1_X3", "shortDesc": "Barometer offset temperature ^3 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B1_X4", "shortDesc": "Barometer offset temperature ^4 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B1_X5", "shortDesc": "Barometer offset temperature ^5 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0, "group": "Thermal Compensation", "name": "TC_B2_ID", "shortDesc": "ID of Barometer that the calibration is for", "type": "Int32"}, {"category": "System", "default": 75.0, "group": "Thermal Compensation", "name": "TC_B2_TMAX", "shortDesc": "Barometer calibration maximum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 5.0, "group": "Thermal Compensation", "name": "TC_B2_TMIN", "shortDesc": "Barometer calibration minimum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 40.0, "group": "Thermal Compensation", "name": "TC_B2_TREF", "shortDesc": "Barometer calibration reference temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B2_X0", "shortDesc": "Barometer offset temperature ^0 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B2_X1", "shortDesc": "Barometer offset temperature ^1 polynomial coefficients", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B2_X2", "shortDesc": "Barometer offset temperature ^2 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B2_X3", "shortDesc": "Barometer offset temperature ^3 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B2_X4", "shortDesc": "Barometer offset temperature ^4 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B2_X5", "shortDesc": "Barometer offset temperature ^5 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0, "group": "Thermal Compensation", "name": "TC_B3_ID", "shortDesc": "ID of Barometer that the calibration is for", "type": "Int32"}, {"category": "System", "default": 75.0, "group": "Thermal Compensation", "name": "TC_B3_TMAX", "shortDesc": "Barometer calibration maximum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 5.0, "group": "Thermal Compensation", "name": "TC_B3_TMIN", "shortDesc": "Barometer calibration minimum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 40.0, "group": "Thermal Compensation", "name": "TC_B3_TREF", "shortDesc": "Barometer calibration reference temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B3_X0", "shortDesc": "Barometer offset temperature ^0 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B3_X1", "shortDesc": "Barometer offset temperature ^1 polynomial coefficients", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B3_X2", "shortDesc": "Barometer offset temperature ^2 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B3_X3", "shortDesc": "Barometer offset temperature ^3 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B3_X4", "shortDesc": "Barometer offset temperature ^4 polynomial coefficient", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_B3_X5", "shortDesc": "Barometer offset temperature ^5 polynomial coefficient", "type": "Float"}, {"category": "Standard", "default": 0, "group": "Thermal Compensation", "name": "TC_B_ENABLE", "rebootRequired": true, "shortDesc": "Thermal compensation for barometric pressure sensors", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "System", "default": 0, "group": "Thermal Compensation", "name": "TC_G0_ID", "shortDesc": "ID of Gyro that the calibration is for", "type": "Int32"}, {"category": "System", "default": 100.0, "group": "Thermal Compensation", "name": "TC_G0_TMAX", "shortDesc": "Gyro calibration maximum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G0_TMIN", "shortDesc": "Gyro calibration minimum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 25.0, "group": "Thermal Compensation", "name": "TC_G0_TREF", "shortDesc": "Gyro calibration reference temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G0_X0_0", "shortDesc": "Gyro rate offset temperature ^0 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G0_X0_1", "shortDesc": "Gyro rate offset temperature ^0 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G0_X0_2", "shortDesc": "Gyro rate offset temperature ^0 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G0_X1_0", "shortDesc": "Gyro rate offset temperature ^1 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G0_X1_1", "shortDesc": "Gyro rate offset temperature ^1 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G0_X1_2", "shortDesc": "Gyro rate offset temperature ^1 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G0_X2_0", "shortDesc": "Gyro rate offset temperature ^2 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G0_X2_1", "shortDesc": "Gyro rate offset temperature ^2 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G0_X2_2", "shortDesc": "Gyro rate offset temperature ^2 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G0_X3_0", "shortDesc": "Gyro rate offset temperature ^3 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G0_X3_1", "shortDesc": "Gyro rate offset temperature ^3 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G0_X3_2", "shortDesc": "Gyro rate offset temperature ^3 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0, "group": "Thermal Compensation", "name": "TC_G1_ID", "shortDesc": "ID of Gyro that the calibration is for", "type": "Int32"}, {"category": "System", "default": 100.0, "group": "Thermal Compensation", "name": "TC_G1_TMAX", "shortDesc": "Gyro calibration maximum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G1_TMIN", "shortDesc": "Gyro calibration minimum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 25.0, "group": "Thermal Compensation", "name": "TC_G1_TREF", "shortDesc": "Gyro calibration reference temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G1_X0_0", "shortDesc": "Gyro rate offset temperature ^0 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G1_X0_1", "shortDesc": "Gyro rate offset temperature ^0 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G1_X0_2", "shortDesc": "Gyro rate offset temperature ^0 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G1_X1_0", "shortDesc": "Gyro rate offset temperature ^1 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G1_X1_1", "shortDesc": "Gyro rate offset temperature ^1 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G1_X1_2", "shortDesc": "Gyro rate offset temperature ^1 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G1_X2_0", "shortDesc": "Gyro rate offset temperature ^2 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G1_X2_1", "shortDesc": "Gyro rate offset temperature ^2 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G1_X2_2", "shortDesc": "Gyro rate offset temperature ^2 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G1_X3_0", "shortDesc": "Gyro rate offset temperature ^3 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G1_X3_1", "shortDesc": "Gyro rate offset temperature ^3 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G1_X3_2", "shortDesc": "Gyro rate offset temperature ^3 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0, "group": "Thermal Compensation", "name": "TC_G2_ID", "shortDesc": "ID of Gyro that the calibration is for", "type": "Int32"}, {"category": "System", "default": 100.0, "group": "Thermal Compensation", "name": "TC_G2_TMAX", "shortDesc": "Gyro calibration maximum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G2_TMIN", "shortDesc": "Gyro calibration minimum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 25.0, "group": "Thermal Compensation", "name": "TC_G2_TREF", "shortDesc": "Gyro calibration reference temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G2_X0_0", "shortDesc": "Gyro rate offset temperature ^0 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G2_X0_1", "shortDesc": "Gyro rate offset temperature ^0 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G2_X0_2", "shortDesc": "Gyro rate offset temperature ^0 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G2_X1_0", "shortDesc": "Gyro rate offset temperature ^1 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G2_X1_1", "shortDesc": "Gyro rate offset temperature ^1 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G2_X1_2", "shortDesc": "Gyro rate offset temperature ^1 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G2_X2_0", "shortDesc": "Gyro rate offset temperature ^2 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G2_X2_1", "shortDesc": "Gyro rate offset temperature ^2 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G2_X2_2", "shortDesc": "Gyro rate offset temperature ^2 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G2_X3_0", "shortDesc": "Gyro rate offset temperature ^3 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G2_X3_1", "shortDesc": "Gyro rate offset temperature ^3 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G2_X3_2", "shortDesc": "Gyro rate offset temperature ^3 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0, "group": "Thermal Compensation", "name": "TC_G3_ID", "shortDesc": "ID of Gyro that the calibration is for", "type": "Int32"}, {"category": "System", "default": 100.0, "group": "Thermal Compensation", "name": "TC_G3_TMAX", "shortDesc": "Gyro calibration maximum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G3_TMIN", "shortDesc": "Gyro calibration minimum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 25.0, "group": "Thermal Compensation", "name": "TC_G3_TREF", "shortDesc": "Gyro calibration reference temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G3_X0_0", "shortDesc": "Gyro rate offset temperature ^0 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G3_X0_1", "shortDesc": "Gyro rate offset temperature ^0 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G3_X0_2", "shortDesc": "Gyro rate offset temperature ^0 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G3_X1_0", "shortDesc": "Gyro rate offset temperature ^1 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G3_X1_1", "shortDesc": "Gyro rate offset temperature ^1 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G3_X1_2", "shortDesc": "Gyro rate offset temperature ^1 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G3_X2_0", "shortDesc": "Gyro rate offset temperature ^2 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G3_X2_1", "shortDesc": "Gyro rate offset temperature ^2 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G3_X2_2", "shortDesc": "Gyro rate offset temperature ^2 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G3_X3_0", "shortDesc": "Gyro rate offset temperature ^3 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G3_X3_1", "shortDesc": "Gyro rate offset temperature ^3 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_G3_X3_2", "shortDesc": "Gyro rate offset temperature ^3 polynomial coefficient - Z axis", "type": "Float"}, {"category": "Standard", "default": 0, "group": "Thermal Compensation", "name": "TC_G_ENABLE", "rebootRequired": true, "shortDesc": "Thermal compensation for rate gyro sensors", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "System", "default": 0, "group": "Thermal Compensation", "name": "TC_M0_ID", "shortDesc": "ID of Magnetometer that the calibration is for", "type": "Int32"}, {"category": "System", "default": 100.0, "group": "Thermal Compensation", "name": "TC_M0_TMAX", "shortDesc": "Magnetometer calibration maximum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M0_TMIN", "shortDesc": "Magnetometer calibration minimum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 25.0, "group": "Thermal Compensation", "name": "TC_M0_TREF", "shortDesc": "Magnetometer calibration reference temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M0_X0_0", "shortDesc": "Magnetometer offset temperature ^0 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M0_X0_1", "shortDesc": "Magnetometer offset temperature ^0 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M0_X0_2", "shortDesc": "Magnetometer offset temperature ^0 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M0_X1_0", "shortDesc": "Magnetometer offset temperature ^1 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M0_X1_1", "shortDesc": "Magnetometer offset temperature ^1 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M0_X1_2", "shortDesc": "Magnetometer offset temperature ^1 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M0_X2_0", "shortDesc": "Magnetometer offset temperature ^2 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M0_X2_1", "shortDesc": "Magnetometer offset temperature ^2 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M0_X2_2", "shortDesc": "Magnetometer offset temperature ^2 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M0_X3_0", "shortDesc": "Magnetometer offset temperature ^3 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M0_X3_1", "shortDesc": "Magnetometer offset temperature ^3 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M0_X3_2", "shortDesc": "Magnetometer offset temperature ^3 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0, "group": "Thermal Compensation", "name": "TC_M1_ID", "shortDesc": "ID of Magnetometer that the calibration is for", "type": "Int32"}, {"category": "System", "default": 100.0, "group": "Thermal Compensation", "name": "TC_M1_TMAX", "shortDesc": "Magnetometer calibration maximum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M1_TMIN", "shortDesc": "Magnetometer calibration minimum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 25.0, "group": "Thermal Compensation", "name": "TC_M1_TREF", "shortDesc": "Magnetometer calibration reference temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M1_X0_0", "shortDesc": "Magnetometer offset temperature ^0 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M1_X0_1", "shortDesc": "Magnetometer offset temperature ^0 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M1_X0_2", "shortDesc": "Magnetometer offset temperature ^0 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M1_X1_0", "shortDesc": "Magnetometer offset temperature ^1 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M1_X1_1", "shortDesc": "Magnetometer offset temperature ^1 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M1_X1_2", "shortDesc": "Magnetometer offset temperature ^1 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M1_X2_0", "shortDesc": "Magnetometer offset temperature ^2 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M1_X2_1", "shortDesc": "Magnetometer offset temperature ^2 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M1_X2_2", "shortDesc": "Magnetometer offset temperature ^2 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M1_X3_0", "shortDesc": "Magnetometer offset temperature ^3 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M1_X3_1", "shortDesc": "Magnetometer offset temperature ^3 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M1_X3_2", "shortDesc": "Magnetometer offset temperature ^3 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0, "group": "Thermal Compensation", "name": "TC_M2_ID", "shortDesc": "ID of Magnetometer that the calibration is for", "type": "Int32"}, {"category": "System", "default": 100.0, "group": "Thermal Compensation", "name": "TC_M2_TMAX", "shortDesc": "Magnetometer calibration maximum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M2_TMIN", "shortDesc": "Magnetometer calibration minimum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 25.0, "group": "Thermal Compensation", "name": "TC_M2_TREF", "shortDesc": "Magnetometer calibration reference temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M2_X0_0", "shortDesc": "Magnetometer offset temperature ^0 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M2_X0_1", "shortDesc": "Magnetometer offset temperature ^0 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M2_X0_2", "shortDesc": "Magnetometer offset temperature ^0 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M2_X1_0", "shortDesc": "Magnetometer offset temperature ^1 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M2_X1_1", "shortDesc": "Magnetometer offset temperature ^1 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M2_X1_2", "shortDesc": "Magnetometer offset temperature ^1 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M2_X2_0", "shortDesc": "Magnetometer offset temperature ^2 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M2_X2_1", "shortDesc": "Magnetometer offset temperature ^2 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M2_X2_2", "shortDesc": "Magnetometer offset temperature ^2 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M2_X3_0", "shortDesc": "Magnetometer offset temperature ^3 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M2_X3_1", "shortDesc": "Magnetometer offset temperature ^3 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M2_X3_2", "shortDesc": "Magnetometer offset temperature ^3 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0, "group": "Thermal Compensation", "name": "TC_M3_ID", "shortDesc": "ID of Magnetometer that the calibration is for", "type": "Int32"}, {"category": "System", "default": 100.0, "group": "Thermal Compensation", "name": "TC_M3_TMAX", "shortDesc": "Magnetometer calibration maximum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M3_TMIN", "shortDesc": "Magnetometer calibration minimum temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 25.0, "group": "Thermal Compensation", "name": "TC_M3_TREF", "shortDesc": "Magnetometer calibration reference temperature", "type": "Float", "units": "celcius"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M3_X0_0", "shortDesc": "Magnetometer offset temperature ^0 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M3_X0_1", "shortDesc": "Magnetometer offset temperature ^0 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M3_X0_2", "shortDesc": "Magnetometer offset temperature ^0 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M3_X1_0", "shortDesc": "Magnetometer offset temperature ^1 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M3_X1_1", "shortDesc": "Magnetometer offset temperature ^1 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M3_X1_2", "shortDesc": "Magnetometer offset temperature ^1 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M3_X2_0", "shortDesc": "Magnetometer offset temperature ^2 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M3_X2_1", "shortDesc": "Magnetometer offset temperature ^2 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M3_X2_2", "shortDesc": "Magnetometer offset temperature ^2 polynomial coefficient - Z axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M3_X3_0", "shortDesc": "Magnetometer offset temperature ^3 polynomial coefficient - X axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M3_X3_1", "shortDesc": "Magnetometer offset temperature ^3 polynomial coefficient - Y axis", "type": "Float"}, {"category": "System", "default": 0.0, "group": "Thermal Compensation", "name": "TC_M3_X3_2", "shortDesc": "Magnetometer offset temperature ^3 polynomial coefficient - Z axis", "type": "Float"}, {"category": "Standard", "default": 0, "group": "Thermal Compensation", "name": "TC_M_ENABLE", "rebootRequired": true, "shortDesc": "Thermal compensation for magnetometer sensors", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 12, "group": "UUV Attitude Control", "max": 16, "min": 0, "name": "UUV_HGT_B_DOWN", "shortDesc": "Height rc-button down", "type": "Int32"}, {"category": "Standard", "default": 11, "group": "UUV Attitude Control", "max": 16, "min": 0, "name": "UUV_HGT_B_UP", "shortDesc": "Height rc-button up", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "UUV Attitude Control", "name": "UUV_HGT_D", "shortDesc": "Height differential gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.2, "group": "UUV Attitude Control", "name": "UUV_HGT_I", "shortDesc": "Height integrational gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "UUV Attitude Control", "name": "UUV_HGT_I_SPD", "shortDesc": "sum speed of error for integrational gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "UUV Attitude Control", "longDesc": "maximum Height distance controlled by manual input. Diff between actual and desired Height cannot be higher than that\n", "name": "UUV_HGT_MAX_DIFF", "shortDesc": "Max height error from manual input", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "UUV Attitude Control", "name": "UUV_HGT_P", "shortDesc": "Height proportional gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "UUV Attitude Control", "name": "UUV_HGT_STR", "shortDesc": "Height change strength from manual input", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.05, "group": "UUV Attitude Control", "min": 0.0, "name": "UUV_MGM_PITCH", "shortDesc": "Pitch gain for manual inputs in manual control mode", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.05, "group": "UUV Attitude Control", "min": 0.0, "name": "UUV_MGM_ROLL", "shortDesc": "Roll gain for manual inputs in manual control mode", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "UUV Attitude Control", "min": 0.0, "name": "UUV_MGM_THRTL", "shortDesc": "Throttle gain for manual inputs in manual control mode", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.05, "group": "UUV Attitude Control", "min": 0.0, "name": "UUV_MGM_YAW", "shortDesc": "Yaw gain for manual inputs in manual control mode", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 2.0, "group": "UUV Attitude Control", "name": "UUV_PITCH_D", "shortDesc": "Pitch differential gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 4.0, "group": "UUV Attitude Control", "name": "UUV_PITCH_P", "shortDesc": "Pitch proportional gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 100.0, "group": "UUV Attitude Control", "min": 0.0, "name": "UUV_RGM_PITCH", "shortDesc": "Pitch gain for manual inputs in rate control mode", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 100.0, "group": "UUV Attitude Control", "min": 0.0, "name": "UUV_RGM_ROLL", "shortDesc": "Roll gain for manual inputs in rate control mode", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 10.0, "group": "UUV Attitude Control", "min": 0.0, "name": "UUV_RGM_THRTL", "shortDesc": "Throttle gain for manual inputs in rate control mode", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 100.0, "group": "UUV Attitude Control", "min": 0.0, "name": "UUV_RGM_YAW", "shortDesc": "Yaw gain for manual inputs in rate control mode", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.5, "group": "UUV Attitude Control", "name": "UUV_ROLL_D", "shortDesc": "Roll differential gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 4.0, "group": "UUV Attitude Control", "name": "UUV_ROLL_P", "shortDesc": "Roll proportional gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.5, "group": "UUV Attitude Control", "min": 0.0, "name": "UUV_SGM_PITCH", "shortDesc": "Pitch gain for manual inputs in attitude control mode", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.5, "group": "UUV Attitude Control", "min": 0.0, "name": "UUV_SGM_ROLL", "shortDesc": "Roll gain for manual inputs in attitude control mode", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "UUV Attitude Control", "min": 0.0, "name": "UUV_SGM_THRTL", "shortDesc": "Throttle gain for manual inputs in attitude control mode", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.5, "group": "UUV Attitude Control", "min": 0.0, "name": "UUV_SGM_YAW", "shortDesc": "Yaw gain for manual inputs in attitude control mode", "type": "Float"}, {"category": "Standard", "default": 2.0, "group": "UUV Attitude Control", "name": "UUV_SP_MAX_AGE", "shortDesc": "Maximum time before resetting setpoint", "type": "Float", "units": "s"}, {"category": "Standard", "default": 0, "group": "UUV Attitude Control", "longDesc": "Stick mode selector (0=Heave/sway control, roll/pitch leveled; 1=Pitch/roll control)\n", "max": 1, "min": 0, "name": "UUV_STICK_MODE", "shortDesc": "UUV stick input mode", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "UUV Attitude Control", "max": 1.0, "min": 0.0, "name": "UUV_THRUST_SAT", "shortDesc": "UUV Thrust setpoint Saturation", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "UUV Attitude Control", "max": 1.0, "min": 0.0, "name": "UUV_TORQUE_SAT", "shortDesc": "UUV Torque setpoint Saturation", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 2.0, "group": "UUV Attitude Control", "name": "UUV_YAW_D", "shortDesc": "Yaw differential gain", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 4.0, "group": "UUV Attitude Control", "name": "UUV_YAW_P", "shortDesc": "Yaw proportional gain", "type": "Float"}, {"category": "Standard", "default": 0.2, "group": "UUV Position Control", "name": "UUV_GAIN_X_D", "shortDesc": "Gain of D controller X", "type": "Float"}, {"category": "Standard", "default": 1.0, "group": "UUV Position Control", "name": "UUV_GAIN_X_P", "shortDesc": "Gain of P controller X", "type": "Float"}, {"category": "Standard", "default": 0.2, "group": "UUV Position Control", "name": "UUV_GAIN_Y_D", "shortDesc": "Gain of D controller Y", "type": "Float"}, {"category": "Standard", "default": 1.0, "group": "UUV Position Control", "name": "UUV_GAIN_Y_P", "shortDesc": "Gain of P controller Y", "type": "Float"}, {"category": "Standard", "default": 0.2, "group": "UUV Position Control", "name": "UUV_GAIN_Z_D", "shortDesc": "Gain of D controller Z", "type": "Float"}, {"category": "Standard", "default": 1.0, "group": "UUV Position Control", "name": "UUV_GAIN_Z_P", "shortDesc": "Gain of P controller Z", "type": "Float"}, {"category": "Standard", "default": 0.5, "group": "UUV Position Control", "name": "UUV_PGM_VEL", "shortDesc": "Gain for position control velocity setpoint update", "type": "Float"}, {"category": "Standard", "default": 1, "group": "UUV Position Control", "name": "UUV_POS_MODE", "shortDesc": "Stabilization mode(1) or Position Control(0)", "type": "Int32", "values": [{"description": "Moves position setpoint in world frame", "value": 0}, {"description": "Moves position setpoint in body frame", "value": 1}]}, {"category": "Standard", "default": 0.1, "group": "UUV Position Control", "name": "UUV_POS_STICK_DB", "shortDesc": "Deadband for changing position setpoint", "type": "Float"}, {"category": "Standard", "default": 1, "group": "UUV Position Control", "name": "UUV_STAB_MODE", "shortDesc": "Stabilization mode(1) or Position Control(0)", "type": "Int32", "values": [{"description": "Tracks previous attitude setpoint", "value": 0}, {"description": "Tracks horizontal attitude (allows yaw change)", "value": 1}]}, {"category": "Standard", "default": 2130706433, "group": "UXRCE-DDS Client", "longDesc": "If ethernet is enabled and is the selected configuration for uXRCE-DDS,\nthe selected Agent IP address will be set and used.\nDecimal dot notation is not supported. IP address must be provided\nin int32 format. For example, 192.168.1.2 is mapped to -1062731518;\n127.0.0.1 is mapped to 2130706433.\n\n", "name": "UXRCE_DDS_AG_IP", "rebootRequired": true, "shortDesc": "uXRCE-DDS Agent IP address", "type": "Int32"}, {"category": "System", "default": 0, "group": "UXRCE-DDS Client", "longDesc": "uXRCE-DDS domain ID\n", "name": "UXRCE_DDS_DOM_ID", "rebootRequired": true, "shortDesc": "uXRCE-DDS domain ID", "type": "Int32"}, {"category": "System", "default": 0, "group": "UXRCE-DDS Client", "longDesc": "This is used to enable flow control for the serial uXRCE instance.\nUsed for reliable high bandwidth communication.\n\n", "name": "UXRCE_DDS_FLCTRL", "rebootRequired": true, "shortDesc": "Enable serial flow control for UXRCE interface", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "System", "default": 1, "group": "UXRCE-DDS Client", "longDesc": "uXRCE-DDS key, must be different from zero.\nIn a single agent - multi client configuration, each client\nmust have a unique session key.\n\n", "name": "UXRCE_DDS_KEY", "rebootRequired": true, "shortDesc": "uXRCE-DDS session key", "type": "Int32"}, {"category": "System", "default": -1, "group": "UXRCE-DDS Client", "longDesc": "Defines an index-based namespace for DDS messages, e.g, uav_0, uav_1, up to uav_9999\nA value less than zero leaves the namespace empty\n\n", "max": 9999, "min": -1, "name": "UXRCE_DDS_NS_IDX", "rebootRequired": true, "shortDesc": "Define an index-based message namespace", "type": "Int32"}, {"category": "Standard", "default": 8888, "group": "UXRCE-DDS Client", "longDesc": "If ethernet is enabled and is the selected configuration for uXRCE-DDS,\nthe selected UDP port will be set and used.\n\n", "max": 65535, "min": 0, "name": "UXRCE_DDS_PRT", "rebootRequired": true, "shortDesc": "uXRCE-DDS UDP port", "type": "Int32"}, {"category": "System", "default": 0, "group": "UXRCE-DDS Client", "longDesc": "Set the participant configuration on the Agent's system.\n0: Use the default configuration.\n1: Restrict messages to localhost\n(use in combination with ROS_LOCALHOST_ONLY=1).\n2: Use a custom participant with the profile name \"px4_participant\".\n\n", "max": 2, "min": 0, "name": "UXRCE_DDS_PTCFG", "rebootRequired": true, "shortDesc": "uXRCE-DDS participant configuration", "type": "Int32", "values": [{"description": "Default", "value": 0}, {"description": "Localhost-only", "value": 1}, {"description": "Custom participant", "value": 2}]}, {"category": "System", "default": -1, "group": "UXRCE-DDS Client", "longDesc": "Specifies after how many seconds without receiving data the DDS connection is reestablished.\nA value less than one disables the RX rate timeout.\n\n", "name": "UXRCE_DDS_RX_TO", "rebootRequired": true, "shortDesc": "RX rate timeout configuration", "type": "Int32", "units": "s"}, {"category": "System", "default": 0, "group": "UXRCE-DDS Client", "longDesc": "When enabled along with UXRCE_DDS_SYNCT, uxrce_dds_client will set the system clock using the agents UTC timestamp.\n", "name": "UXRCE_DDS_SYNCC", "rebootRequired": true, "shortDesc": "Enable uXRCE-DDS system clock synchronization", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "System", "default": 1, "group": "UXRCE-DDS Client", "longDesc": "When enabled, uxrce_dds_client will synchronize the timestamps of the incoming and outgoing messages measuring the offset between the Agent OS time and the PX4 time.\n", "name": "UXRCE_DDS_SYNCT", "rebootRequired": true, "shortDesc": "Enable uXRCE-DDS timestamp synchronization", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "System", "default": 3, "group": "UXRCE-DDS Client", "longDesc": "Specifies after how many seconds without sending data the DDS connection is reestablished.\nA value less than one disables the TX rate timeout.\n\n", "name": "UXRCE_DDS_TX_TO", "rebootRequired": true, "shortDesc": "TX rate timeout configuration", "type": "Int32", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 8.0, "group": "VTOL Attitude Control", "increment": 1.0, "longDesc": "Airspeed at which we can start blending both fw and mc controls. Set to 0 to disable.\n", "max": 30.0, "min": 0.0, "name": "VT_ARSP_BLEND", "shortDesc": "Transition blending airspeed", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 10.0, "group": "VTOL Attitude Control", "increment": 1.0, "longDesc": "Airspeed at which we can switch to fw mode\n", "max": 30.0, "min": 0.0, "name": "VT_ARSP_TRANS", "shortDesc": "Transition airspeed", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 1.0, "group": "VTOL Attitude Control", "increment": 0.1, "longDesc": "Time in seconds it takes to tilt form VT_TILT_FW to VT_TILT_MC.\n", "max": 10.0, "min": 0.1, "name": "VT_BT_TILT_DUR", "shortDesc": "Duration motor tilt up in backtransition", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "VTOL Attitude Control", "increment": 0.05, "max": 0.3, "min": 0.0, "name": "VT_B_DEC_I", "shortDesc": "Backtransition deceleration setpoint to tilt I gain", "type": "Float", "units": "rad s/m"}, {"category": "Standard", "decimalPlaces": 2, "default": 2.0, "group": "VTOL Attitude Control", "increment": 0.1, "longDesc": "Used to calculate back transition distance in an auto mode.\nFor standard vtol and tiltrotors a controller is used to track this value during the transition.\n", "max": 10.0, "min": 0.5, "name": "VT_B_DEC_MSS", "shortDesc": "Approximate deceleration during back transition", "type": "Float", "units": "m/s^2"}, {"category": "Standard", "decimalPlaces": 2, "default": 10.0, "group": "VTOL Attitude Control", "increment": 1.0, "longDesc": "Transition is also declared over if the groundspeed drops below MPC_XY_CRUISE.\n", "max": 20.0, "min": 0.1, "name": "VT_B_TRANS_DUR", "shortDesc": "Maximum duration of a back transition", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "VTOL Attitude Control", "increment": 0.1, "longDesc": "This sets the duration during which the MC motors ramp up to the commanded thrust during the back transition stage.\n", "max": 20.0, "min": 0.0, "name": "VT_B_TRANS_RAMP", "shortDesc": "Back transition MC motor ramp up time", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.4, "group": "VTOL Attitude Control", "increment": 0.01, "longDesc": "Has to be below the highest pusher assist throttle, which VT_FWD_THRUST_SC, VT_PITCH_MIN and MPC_TILTMAX_AIR set.\n", "max": 0.9, "min": 0.0, "name": "VT_EF_THROT", "shortDesc": "Pusher failure detection throttle threshold", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 5.0, "group": "VTOL Attitude Control", "increment": 0.1, "longDesc": "A pusher failure is detected in multicopter mode when, for this time, the pusher assist throttle is above VT_EF_THROT, but the forward velocity stays more than VT_EF_VEL_ERR below its setpoint. It is handled as a quad-chute that blocks front transitions until reboot or until disabled. Only used by standard VTOLs when VT_FWD_THRUST_EN is enabled. Set to 0 to disable.\n", "max": 20.0, "min": 0.0, "name": "VT_EF_TIME", "shortDesc": "Pusher failure detection time", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.5, "group": "VTOL Attitude Control", "increment": 0.1, "longDesc": "Forward velocity setpoint minus forward velocity above which pusher assist above VT_EF_THROT is considered ineffective, see VT_EF_TIME.\n", "max": 10.0, "min": 0.5, "name": "VT_EF_VEL_ERR", "shortDesc": "Pusher failure detection forward velocity error", "type": "Float", "units": "m/s"}, {"category": "Standard", "default": 1, "group": "VTOL Attitude Control", "longDesc": "If set to 1 the control surfaces are locked at the disarmed value in multicopter mode.\n", "name": "VT_ELEV_MC_LOCK", "shortDesc": "Lock control surfaces in hover", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "VTOL Attitude Control", "longDesc": "Prevents downforce from pitching the body down when facing wind.\nUses puller/pusher (standard VTOL), or forward-tilt (tiltrotor VTOL) to accelerate forward instead.\nOnly active if demanded pitch is below VT_PITCH_MIN.\nUse VT_FWD_THRUST_SC to tune it.\nDescend mode is treated as Landing too.\n\nOnly active (if enabled) in height-rate controlled modes.\n", "name": "VT_FWD_THRUST_EN", "shortDesc": "Use fixed-wing actuation in hover to accelerate forward", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled (except LANDING)", "value": 1}, {"description": "Enabled if above MPC_LAND_ALT1", "value": 2}, {"description": "Enabled if above MPC_LAND_ALT2", "value": 3}, {"description": "Enabled constantly", "value": 4}, {"description": "Enabled if above MPC_LAND_ALT1 (except LANDING)", "value": 5}, {"description": "Enabled if above MPC_LAND_ALT2 (except LANDING)", "value": 6}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.7, "group": "VTOL Attitude Control", "increment": 0.01, "longDesc": "Scale applied to the demanded pitch (below VT_PITCH_MIN) to get the fixed-wing forward actuation in hover mode.\nEnabled via VT_FWD_THRUST_EN.\n", "max": 5.0, "min": 0.0, "name": "VT_FWD_THRUST_SC", "shortDesc": "Fixed-wing actuation thrust scale in hover", "type": "Float"}, {"bitmask": [{"description": "Yaw", "index": 0}, {"description": "Roll", "index": 1}, {"description": "Pitch", "index": 2}], "category": "Standard", "default": 0, "group": "VTOL Attitude Control", "longDesc": "Enable differential thrust separately for roll, pitch, yaw in forward (fixed-wing) mode.\nThe effectiveness of differential thrust around the corresponding axis can be\ntuned by setting VT_FW_DIFTHR_S_R / VT_FW_DIFTHR_S_P / VT_FW_DIFTHR_S_Y.\n", "max": 7, "min": 0, "name": "VT_FW_DIFTHR_EN", "shortDesc": "Differential thrust in forwards flight", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "VTOL Attitude Control", "increment": 0.1, "longDesc": "Differential thrust in forward flight is enabled via VT_FW_DIFTHR_EN.\n", "max": 2.0, "min": 0.0, "name": "VT_FW_DIFTHR_S_P", "shortDesc": "Pitch differential thrust factor in forward flight", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "VTOL Attitude Control", "increment": 0.1, "longDesc": "Differential thrust in forward flight is enabled via VT_FW_DIFTHR_EN.\n", "max": 2.0, "min": 0.0, "name": "VT_FW_DIFTHR_S_R", "shortDesc": "Roll differential thrust factor in forward flight", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "VTOL Attitude Control", "increment": 0.1, "longDesc": "Differential thrust in forward flight is enabled via VT_FW_DIFTHR_EN.\n", "max": 2.0, "min": 0.0, "name": "VT_FW_DIFTHR_S_Y", "shortDesc": "Yaw differential thrust factor in forward flight", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "VTOL Attitude Control", "increment": 1.0, "longDesc": "Minimum altitude for fixed-wing flight. When the vehicle is in fixed-wing mode\nand the altitude drops below this altitude (relative altitude above local origin),\nit will instantly switch back to MC mode and execute behavior defined in COM_QC_ACT.\n", "max": 200.0, "min": 0.0, "name": "VT_FW_MIN_ALT", "shortDesc": "Quad-chute altitude", "type": "Float", "units": "m"}, {"category": "Standard", "default": 0, "group": "VTOL Attitude Control", "increment": 1, "longDesc": "Maximum height above the ground (if available, otherwise above\nHome if available, otherwise above the local origin) where triggering a quad-chute is possible.\nAt high altitudes there is a big risk to deplete the battery and therefore crash if quad-chuting there.\n", "min": 0, "name": "VT_FW_QC_HMAX", "shortDesc": "Quad-chute maximum height", "type": "Int32", "units": "m"}, {"category": "Standard", "default": 0, "group": "VTOL Attitude Control", "longDesc": "Absolute pitch threshold for quad-chute triggering in FW mode.\nAbove this the vehicle will transition back to MC mode and execute behavior defined in COM_QC_ACT.\nSet to 0 do disable this threshold.\n", "max": 180, "min": 0, "name": "VT_FW_QC_P", "shortDesc": "Quad-chute max pitch threshold", "type": "Int32", "units": "deg"}, {"category": "Standard", "default": 0, "group": "VTOL Attitude Control", "longDesc": "Absolute roll threshold for quad-chute triggering in FW mode.\nAbove this the vehicle will transition back to MC mode and execute behavior defined in COM_QC_ACT.\nSet to 0 do disable this threshold.\n", "max": 180, "min": 0, "name": "VT_FW_QC_R", "shortDesc": "Quad-chute max roll threshold", "type": "Int32", "units": "deg"}, {"category": "Standard", "decimalPlaces": 2, "default": 5.0, "group": "VTOL Attitude Control", "increment": 1.0, "longDesc": "Time in seconds used for a transition\n", "max": 20.0, "min": 0.1, "name": "VT_F_TRANS_DUR", "shortDesc": "Duration of a front transition", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "VTOL Attitude Control", "increment": 0.01, "longDesc": "Scaled by the square root of the weight ratio (WEIGHT_GROSS / WEIGHT_BASE).\n", "max": 1.0, "min": 0.0, "name": "VT_F_TRANS_THR", "shortDesc": "Target throttle value for the transition to fixed-wing flight", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 1, "default": 6.0, "group": "VTOL Attitude Control", "increment": 0.5, "longDesc": "The duration of the front transition when there is no airspeed feedback available.\nWhen airspeed is used, transition timeout is declared if airspeed does not\nreach VT_ARSP_BLEND after this time.\n", "max": 30.0, "min": 1.0, "name": "VT_F_TR_OL_TM", "shortDesc": "Airspeed-less front transition time (open loop)", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "VTOL Attitude Control", "increment": 0.1, "longDesc": "Overrides VT_PITCH_MIN when the vehicle is in LAND mode (hovering).\nDuring landing it can be beneficial to reduce the pitch angle to reduce the generated lift in head wind.\n", "max": 45.0, "min": -10.0, "name": "VT_LND_PITCH_MIN", "shortDesc": "Minimum pitch angle during hover landing", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "VTOL Attitude Control", "increment": 0.1, "longDesc": "Any pitch setpoint below this value is translated to a forward force by the fixed-wing forward actuation if\nVT_FWD_TRHUST_EN is set.\n", "max": 45.0, "min": -10.0, "name": "VT_PITCH_MIN", "shortDesc": "Minimum pitch angle during hover", "type": "Float", "units": "deg"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.33, "group": "VTOL Attitude Control", "increment": 0.01, "longDesc": "Defines the slew rate of the puller/pusher throttle during transitions.\nZero will deactivate the slew rate limiting and thus produce an instant throttle\nrise to the transition throttle VT_F_TRANS_THR.\n", "min": 0.0, "name": "VT_PSHER_SLEW", "shortDesc": "Pusher throttle ramp up slew rate", "type": "Float", "units": "1/s"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "VTOL Attitude Control", "increment": 1.0, "longDesc": "Altitude error threshold for quad-chute triggering during fixed-wing flight.\nThe check is only active if altitude is controlled and the vehicle is below the current altitude reference.\nThe altitude error is relative to the highest altitude the vehicle has achieved since it has flown below the current\naltitude reference.\n\nSet to 0 do disable.\n", "max": 200.0, "min": 0.0, "name": "VT_QC_ALT_LOSS", "shortDesc": "Quad-chute uncommanded descent threshold", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 20.0, "group": "VTOL Attitude Control", "increment": 1.0, "longDesc": "Altitude loss threshold for quad-chute triggering during VTOL transition to fixed-wing flight\nin altitude-controlled flight modes.\nActive until 5s after completing transition to fixed-wing.\nIf the current altitude is more than this value below the altitude at the beginning of the\ntransition, it will instantly switch back to MC mode and execute behavior defined in COM_QC_ACT.\n\nSet to 0 do disable this threshold.\n", "max": 50.0, "min": 0.0, "name": "VT_QC_T_ALT_LOSS", "shortDesc": "Quad-chute transition altitude loss threshold", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 1, "default": 0.0, "group": "VTOL Attitude Control", "increment": 0.1, "max": 1.0, "min": -1.0, "name": "VT_SPOILER_MC_LD", "shortDesc": "Spoiler setting while landing (hover)", "type": "Float", "units": "norm"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "VTOL Attitude Control", "increment": 0.01, "max": 1.0, "min": 0.0, "name": "VT_TILT_FW", "shortDesc": "Normalized tilt in FW", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.0, "group": "VTOL Attitude Control", "increment": 0.01, "max": 1.0, "min": 0.0, "name": "VT_TILT_MC", "shortDesc": "Normalized tilt in Hover", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.4, "group": "VTOL Attitude Control", "increment": 0.01, "max": 1.0, "min": 0.0, "name": "VT_TILT_TRANS", "shortDesc": "Normalized tilt in transition to FW", "type": "Float"}, {"category": "Standard", "decimalPlaces": 1, "default": 2.0, "group": "VTOL Attitude Control", "increment": 0.1, "longDesc": "Minimum time in seconds for front transition.\n", "max": 20.0, "min": 0.0, "name": "VT_TRANS_MIN_TM", "shortDesc": "Front transition minimum time", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.5, "group": "VTOL Attitude Control", "increment": 0.01, "longDesc": "Time in seconds it takes to tilt form VT_TILT_TRANS to VT_TILT_FW.\n", "max": 5.0, "min": 0.1, "name": "VT_TRANS_P2_DUR", "shortDesc": "Duration of front transition phase 2", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 2, "default": 15.0, "group": "VTOL Attitude Control", "increment": 1.0, "longDesc": "Time in seconds after which transition will be cancelled.\n", "max": 30.0, "min": 0.1, "name": "VT_TRANS_TIMEOUT", "shortDesc": "Front transition timeout", "type": "Float", "units": "s"}, {"category": "Standard", "default": 0, "group": "VTOL Attitude Control", "max": 2, "min": 0, "name": "VT_TYPE", "rebootRequired": true, "shortDesc": "VTOL Type (Tailsitter=0, Tiltrotor=1, Standard=2)", "type": "Int32", "values": [{"description": "Tailsitter", "value": 0}, {"description": "Tiltrotor", "value": 1}, {"description": "Standard", "value": 2}]}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "VTOL Attitude Control", "increment": 0.01, "longDesc": "The desired gain to convert roll sp into yaw rate sp.\n", "max": 3.0, "min": 0.0, "name": "WV_GAIN", "shortDesc": "Weather-vane roll angle to yawrate", "type": "Float", "units": "Hz"}, {"category": "Standard", "decimalPlaces": 1, "default": 80.0, "group": "VTOL Takeoff", "increment": 1.0, "longDesc": "Altitude relative to home at which vehicle will loiter after front transition.\n", "max": 300.0, "min": 20.0, "name": "VTO_LOITER_ALT", "shortDesc": "VTOL Takeoff relative loiter altitude", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 4, "default": 0.02, "group": "Vision Target Estimator", "longDesc": "UAV velocity variance growth rate from acceleration noise (m^2/s^3), independent of update rate.\nHigher values follow measurements faster and reject fewer outliers.\n", "min": 0.0001, "name": "VTE_ACC_D_UNC", "shortDesc": "UAV acceleration white-noise power spectral density", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "Vision Target Estimator", "longDesc": "Target acceleration variance growth rate (m^2/s^5), independent of update rate. Moving-target builds only.\nHigher values track manoeuvres faster and reject fewer outliers.\n", "min": 0.01, "name": "VTE_ACC_T_UNC", "shortDesc": "Target acceleration random-walk process noise", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.1, "group": "Vision Target Estimator", "longDesc": "Initial absolute target-acceleration variance per axis (moving-target builds only).\nChanges apply at initialization/reset. Use VTE_ACC_T_UNC for ongoing manoeuvre tracking.\n", "min": 0.001, "name": "VTE_ACC_UNC_IN", "shortDesc": "Initial target absolute acceleration uncertainty", "type": "Float", "units": "(m/s^2)^2"}, {"bitmask": [{"description": "Target GNSS position (receiver on the target)", "index": 0}, {"description": "UAV GNSS velocity", "index": 1}, {"description": "Vision relative position", "index": 2}, {"description": "Mission land position (precision landing)", "index": 3}, {"description": "Target GNSS velocity (moving-target builds only)", "index": 4}, {"description": "Home position (precision takeoff)", "index": 5}], "category": "Standard", "default": 14, "group": "Vision Target Estimator", "longDesc": "Absolute target references (bits 0, 3, 5) require vehicle GNSS; their offset from vision is estimated as a bias.\nBit 0 overrides bits 3 and 5, which are ignored in moving-target builds.\n", "max": 63, "min": 0, "name": "VTE_AID_MASK", "shortDesc": "Integer bitmask controlling data fusion and aiding methods", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 4, "default": 0.001, "group": "Vision Target Estimator", "longDesc": "GNSS/vision position-bias variance growth rate (m^2/s), independent of update rate.\nHigher values track reference drift faster; lower values keep the bias steadier.\n", "min": 0.0001, "name": "VTE_BIAS_UNC", "shortDesc": "Bias random-walk process noise", "type": "Float"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "Vision Target Estimator", "longDesc": "Maximum 3D difference between raw and filtered bias to finish averaging after GNSS-first startup.\nLower values require steadier samples. Requires 5 consecutive matches and at least 0.6 s, or VTE_BIA_AVG_TOUT.\nSet to 0 to disable averaging.\n", "min": 0.0, "name": "VTE_BIA_AVG_THR", "shortDesc": "Initial GNSS/vision bias averaging threshold", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Vision Target Estimator", "longDesc": "Maximum time to average the GNSS/vision bias when starting from GNSS position. Vision fusion waits meanwhile.\nIf GNSS expires, switch to vision with the filtered bias. Set to 0 to disable averaging.\n", "min": 0.0, "name": "VTE_BIA_AVG_TOUT", "shortDesc": "Initial GNSS/vision bias averaging timeout", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "Vision Target Estimator", "longDesc": "Initial GNSS/vision position-bias variance per axis. Higher values allow larger initial bias corrections.\nApplied at initialization/reset and bias activation. Use VTE_BIAS_UNC for ongoing drift.\n", "min": 0.001, "name": "VTE_BIA_UNC_IN", "shortDesc": "Initial GPS bias uncertainty", "type": "Float", "units": "m^2"}, {"category": "Standard", "decimalPlaces": 1, "default": 3.0, "group": "Vision Target Estimator", "increment": 0.5, "longDesc": "Reset after this long without accepted position or yaw updates, tracked separately.\nVelocity updates do not prevent position resets.\n", "max": 50.0, "min": 0.1, "name": "VTE_BTOUT", "shortDesc": "Vision target timeout", "type": "Float", "units": "s"}, {"category": "Standard", "default": 1, "group": "Vision Target Estimator", "name": "VTE_EN", "rebootRequired": true, "shortDesc": "Vision Target Estimator module enable", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 0.07, "group": "Vision Target Estimator", "longDesc": "Minimum vision yaw noise; used only when reported noise is lower. Default: about 4 deg.\nLower values increase trust in yaw measurements and can cause control oscillations.\n", "min": 0.05, "name": "VTE_EVA_NOISE", "shortDesc": "Minimum standard deviation for vision yaw observations", "type": "Float", "units": "rad"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.1, "group": "Vision Target Estimator", "longDesc": "Minimum vision position noise; used only when reported noise is lower.\nIncrease to reduce trust in position measurements.\n", "min": 0.01, "name": "VTE_EVP_NOISE", "shortDesc": "Minimum standard deviation for vision relative-position observations", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.5, "group": "Vision Target Estimator", "longDesc": "Minimum GNSS position noise for target, mission or home aiding; used only when reported noise is lower.\nIncrease to reduce trust in position measurements.\n", "max": 10.0, "min": 0.01, "name": "VTE_GPS_P_NOISE", "shortDesc": "Minimum standard deviation for GPS position observations", "type": "Float", "units": "m"}, {"category": "Standard", "decimalPlaces": 2, "default": 0.3, "group": "Vision Target Estimator", "longDesc": "Minimum GNSS velocity noise; used only when reported noise is lower.\nIncrease to reduce trust in velocity measurements.\n", "max": 5.0, "min": 0.01, "name": "VTE_GPS_V_NOISE", "shortDesc": "Minimum standard deviation for GPS velocity observations", "type": "Float", "units": "m/s"}, {"category": "Standard", "decimalPlaces": 2, "default": 1.0, "group": "Vision Target Estimator", "increment": 0.05, "longDesc": "Maximum raw measurement age allowed for fusion.\n", "max": 10.0, "min": 0.1, "name": "VTE_M_REC_TOUT", "shortDesc": "Measurement recent timeout", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.1, "group": "Vision Target Estimator", "increment": 0.01, "longDesc": "Maximum age of local position, velocity and antenna-offset corrections. GNSS-to-vision alignment may span the measurement recent timeout.\n", "max": 5.0, "min": 0.01, "name": "VTE_M_UPD_TOUT", "shortDesc": "Measurement updated timeout", "type": "Float", "units": "s"}, {"category": "Standard", "default": 1, "group": "Vision Target Estimator", "name": "VTE_POS_EN", "rebootRequired": true, "shortDesc": "Vision Target Estimator module enable position estimation", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 3.84, "group": "Vision Target Estimator", "longDesc": "Per-axis outlier gate for position and velocity measurements. Lower values reject more samples.\nFor Gaussian innovations, 3.84 rejects about 5% of valid samples; 6.63 rejects 1%.\n", "max": 10.83, "min": 0.46, "name": "VTE_POS_NIS_THRE", "shortDesc": "Normalized innovation squared threshold for the position estimator", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.5, "group": "Vision Target Estimator", "longDesc": "Minimum initial variance of the relative target position in x, y, and z direction.\nThe variance reported by the initializing observation is used if it is larger.\nApplied at initialization/reset and GNSS/vision bias activation.\n", "min": 0.001, "name": "VTE_POS_UNC_IN", "shortDesc": "Initial target and drone relative position uncertainty", "type": "Float", "units": "m^2"}, {"bitmask": [{"description": "precision landing", "index": 0}, {"description": "DEBUG, always active", "index": 1}, {"description": "precision takeoff", "index": 2}], "category": "Standard", "default": 1, "group": "Vision Target Estimator", "max": 7, "min": 0, "name": "VTE_TASK_MASK", "shortDesc": "Integer bitmask controlling the tasks of the target estimator", "type": "Int32"}, {"category": "Standard", "decimalPlaces": 2, "default": 2.0, "group": "Vision Target Estimator", "increment": 0.25, "longDesc": "Maximum time without accepted position or yaw updates before that estimate becomes invalid.\nKeep below VTE_BTOUT.\n", "max": 50.0, "min": 0.1, "name": "VTE_TGT_TOUT", "shortDesc": "Target validity timeout", "type": "Float", "units": "s"}, {"category": "Standard", "decimalPlaces": 3, "default": 0.5, "group": "Vision Target Estimator", "longDesc": "Initial velocity variance per axis, applied separately to the UAV and moving target.\nChanges apply at initialization/reset.\n", "min": 0.001, "name": "VTE_VEL_UNC_IN", "shortDesc": "Initial target and drone relative velocity uncertainty", "type": "Float", "units": "(m/s)^2"}, {"category": "Standard", "decimalPlaces": 4, "default": 0.004, "group": "Vision Target Estimator", "longDesc": "Yaw-rate variance growth rate from acceleration noise (rad^2/s^3), independent of update rate.\nHigher values track heading changes faster; lower values smooth yaw more.\n", "min": 0.0, "name": "VTE_YAW_ACC_UNC", "shortDesc": "Yaw acceleration white-noise power spectral density", "type": "Float"}, {"category": "Standard", "default": 0, "group": "Vision Target Estimator", "name": "VTE_YAW_EN", "rebootRequired": true, "shortDesc": "Vision Target Estimator module enable orientation estimation", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "decimalPlaces": 2, "default": 3.84, "group": "Vision Target Estimator", "longDesc": "Yaw outlier gate. Lower values reject more samples.\nFor Gaussian innovations, 3.84 rejects about 5% of valid samples; 6.63 rejects 1%.\n", "max": 10.83, "min": 0.46, "name": "VTE_YAW_NIS_THRE", "shortDesc": "Normalized innovation squared threshold for the orientation estimator", "type": "Float"}, {"category": "Standard", "decimalPlaces": 3, "default": 1.0, "group": "Vision Target Estimator", "longDesc": "Initial yaw variance (rad^2); also used for yaw-rate variance ((rad/s)^2).\nChanges apply at initialization/reset.\n", "min": 0.001, "name": "VTE_YAW_UNC_IN", "shortDesc": "Initial orientation uncertainty", "type": "Float"}, {"category": "System", "default": 0, "group": "Zenoh", "longDesc": "Set true (1) to start the Zenoh driver module (a.k.a the \"Zenoh-Pico Node\").\nSee https://docs.px4.io/main/en/middleware/zenoh and\nhttps://docs.px4.io/main/en/modules/modules_driver.html#zenoh\n\n", "name": "ZENOH_ENABLE", "rebootRequired": true, "shortDesc": "Enable Zenoh", "type": "Int32", "values": [{"description": "Disabled", "value": 0}, {"description": "Enabled", "value": 1}]}, {"category": "Standard", "default": 0, "group": "Miscellaneous", "max": 232, "min": 0, "name": "ZENOH_DOMAIN_ID", "shortDesc": "ROS2 RMW_ZENOH_CPP Domain id", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "Miscellaneous", "max": 1, "min": 0, "name": "ZENOH_PUB_CC", "rebootRequired": true, "shortDesc": "Zenoh publisher congestion control (global default)", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "Miscellaneous", "max": 1, "min": 0, "name": "ZENOH_PUB_EXPR", "rebootRequired": true, "shortDesc": "Zenoh publisher express mode (global default)", "type": "Int32"}, {"category": "Standard", "default": 5, "group": "Miscellaneous", "max": 7, "min": 1, "name": "ZENOH_PUB_PRIO", "rebootRequired": true, "shortDesc": "Zenoh publisher priority (global default)", "type": "Int32"}, {"category": "Standard", "default": 0, "group": "Miscellaneous", "max": 1, "min": 0, "name": "ZENOH_PUB_REL", "rebootRequired": true, "shortDesc": "Zenoh publisher reliability (global default)", "type": "Int32"}], "translation": {"items": {"parameters": {"list": {"items": {"bitmask": {"list": {"key": "index", "translate": ["description"]}}, "values": {"list": {"key": "value", "translate": ["description"]}}}, "key": "name", "translate": ["shortDesc", "longDesc"], "translate-global": ["category", "group"]}}}}, "version": 1} \ No newline at end of file diff --git a/msg/FailureDetectorStatus.msg b/msg/FailureDetectorStatus.msg index 092848932ea..8de88d03463 100644 --- a/msg/FailureDetectorStatus.msg +++ b/msg/FailureDetectorStatus.msg @@ -1,8 +1,7 @@ uint64 timestamp # time since system start (microseconds) # FailureDetector status -bool fd_roll -bool fd_pitch +bool fd_tilt bool fd_alt bool fd_ext bool fd_arm_escs diff --git a/msg/TelemetryStatus.msg b/msg/TelemetryStatus.msg index 56aff0c02b2..141bc8d0f80 100644 --- a/msg/TelemetryStatus.msg +++ b/msg/TelemetryStatus.msg @@ -34,6 +34,7 @@ uint32 rx_parse_errors # number of parse errors uint32 rx_packet_drop_count # number of packet drops uint32 rx_unknown_message_count # number of messages not in the dialect, not processed uint32 rx_bad_signature_count # number of messages with missing or invalid signature, not processed +uint32 rx_bad_crc_count # number of known messages dropped for a bad CRC float32 rx_message_lost_rate # fraction of messages lost (0 to 1) diff --git a/msg/VehicleOpticalFlow.msg b/msg/VehicleOpticalFlow.msg index 23472b4c97f..a79444a4692 100644 --- a/msg/VehicleOpticalFlow.msg +++ b/msg/VehicleOpticalFlow.msg @@ -19,3 +19,5 @@ float32 max_flow_rate # (radians/s) Magnitude of maximum angular which float32 min_ground_distance # (meters) Minimum distance from ground at which the optical flow sensor operates reliably float32 max_ground_distance # (meters) Maximum distance from ground at which the optical flow sensor operates reliably + +float32[3] position_offset # (meters) Position of the sensor focal point in body FRD frame, relative to the vehicle centre of gravity diff --git a/msg/versioned/VehicleCommand.msg b/msg/versioned/VehicleCommand.msg index 55230902f24..90fc4fd81c5 100644 --- a/msg/versioned/VehicleCommand.msg +++ b/msg/versioned/VehicleCommand.msg @@ -115,7 +115,7 @@ uint16 VEHICLE_CMD_EXTERNAL_WIND_ESTIMATE = 43004 uint16 VEHICLE_CMD_ESTIMATOR_SENSOR_ENABLE = 43006 # Enable/disable estimator sensor fusion. |Source (FUSION_SOURCE_*)|Sensor instance (0-based)|Enable (1) or Disable (0)|Estimator Instance (NaN: not used)|Empty|Empty|Empty| # Sensor fusion source types for VEHICLE_CMD_ESTIMATOR_SENSOR_ENABLE uint8 FUSION_SOURCE_GPS = 0 # GNSS (EKF2_GPS{i}_CTRL, use instance param) -uint8 FUSION_SOURCE_OF = 1 # Optical Flow (EKF2_OF_CTRL) +uint8 FUSION_SOURCE_OF = 1 # Optical Flow (toggles all sensors, per-slot config via EKF2_OF{i}_CTRL) uint8 FUSION_SOURCE_EV = 2 # External Vision (EKF2_EV_CTRL) uint8 FUSION_SOURCE_AGP = 3 # Auxiliary Global Position (EKF2_AGP{i}_CTRL, use instance param) uint8 FUSION_SOURCE_BARO = 4 # Barometer (EKF2_BARO_CTRL) diff --git a/platforms/nuttx/NuttX/CMakeLists.txt b/platforms/nuttx/NuttX/CMakeLists.txt index 3f6134d0e37..bc22671b711 100644 --- a/platforms/nuttx/NuttX/CMakeLists.txt +++ b/platforms/nuttx/NuttX/CMakeLists.txt @@ -38,6 +38,10 @@ set(APPS_DIR ${NUTTX_SRC_DIR}/apps) # NuttX build ############################################################################### +# The NuttX libraries and apps are built by make invocations that ninja treats +# as single opaque steps. Run them through a wrapper that adds parallel jobs. +set(NUTTX_MAKE ${CMAKE_CURRENT_SOURCE_DIR}/tools/px4_nuttx_make.sh) + configure_file(${PX4_SOURCE_DIR}/platforms/nuttx/NuttX/Make.defs.in ${CMAKE_CURRENT_BINARY_DIR}/nuttx/Make.defs) set(EXTRA_NUTTX_CONFIG_FILE ${CMAKE_CURRENT_BINARY_DIR}/extra_config_options) @@ -155,7 +159,7 @@ add_custom_command(OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/apps/libapps.a COMMAND ${CMAKE_COMMAND} -E copy_if_different ${CMAKE_CURRENT_BINARY_DIR}/px4.pdat ${APPS_DIR}/builtin/registry/px4.pdat COMMAND ${CMAKE_COMMAND} -E touch_nocreate ${APPS_DIR}/builtin/registry/.updated COMMAND ${CMAKE_COMMAND} -E touch_nocreate ${APPS_DIR}/builtin/builtin_list.c - COMMAND make --no-print-directory --silent TOPDIR="${NUTTX_DIR}" > ${CMAKE_CURRENT_BINARY_DIR}/nuttx_apps.log + COMMAND ${NUTTX_MAKE} --no-print-directory --silent TOPDIR="${NUTTX_DIR}" > ${CMAKE_CURRENT_BINARY_DIR}/nuttx_apps.log COMMAND ${CMAKE_COMMAND} -E copy_if_different ${APPS_DIR}/libapps.a ${CMAKE_CURRENT_BINARY_DIR}/apps/libapps.a DEPENDS ${nuttx_apps_files} nuttx_context ${NUTTX_DIR}/include/nuttx/config.h ${CMAKE_CURRENT_BINARY_DIR}/px4.bdat @@ -190,7 +194,7 @@ function(add_nuttx_dir nuttx_lib nuttx_lib_dir kernel extra target) add_custom_command(OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/nuttx/${nuttx_lib_dir}/lib${nuttx_lib}.a BYPRODUCTS ${nuttx_${nuttx_lib}_byproducts} - COMMAND make -C ${nuttx_lib_dir} --no-print-directory --silent ${nuttx_lib_target} TOPDIR="${NUTTX_DIR}" KERNEL=${kernel} EXTRAFLAGS=${extra} ${bindir_arg} + COMMAND ${NUTTX_MAKE} -C ${nuttx_lib_dir} --no-print-directory --silent ${nuttx_lib_target} TOPDIR="${NUTTX_DIR}" KERNEL=${kernel} EXTRAFLAGS=${extra} ${bindir_arg} COMMAND ${CMAKE_COMMAND} -E copy_if_different ${NUTTX_DIR}/${nuttx_lib_dir}/lib${nuttx_lib}.a ${CMAKE_CURRENT_BINARY_DIR}/nuttx/${nuttx_lib_dir}/lib${nuttx_lib}.a DEPENDS ${nuttx_lib_files} diff --git a/platforms/nuttx/NuttX/Make.defs.in b/platforms/nuttx/NuttX/Make.defs.in index ef5485303a4..1f5fae6830b 100644 --- a/platforms/nuttx/NuttX/Make.defs.in +++ b/platforms/nuttx/NuttX/Make.defs.in @@ -84,6 +84,17 @@ NM = ${CMAKE_NM} OBJCOPY = ${CMAKE_OBJCOPY} OBJDUMP = ${CMAKE_OBJDUMP} +# Config.mk defines these as exported recursive variables that run a shell +# script on every expansion. Because they are exported, make expands them for +# every recipe it spawns, serially in its main process, which caps the NuttX +# library builds at a few compiles per second regardless of -j. The toplevel +# NuttX make avoids this by passing the expanded values down to its sub-makes +# through the environment; PX4 invokes the sub-makes directly, so evaluate them +# once here now that CC is known. +DEFINE_PREFIX := $(DEFINE_PREFIX) +INCDIR_PREFIX := $(INCDIR_PREFIX) +INCSYSDIR_PREFIX := $(INCSYSDIR_PREFIX) + CINCPATH := $(INCSYSDIR_PREFIX)$(TOPDIR)$(DELIM)include CXXINCPATH := $(INCSYSDIR_PREFIX)$(TOPDIR)$(DELIM)include$(DELIM)cxx diff --git a/platforms/nuttx/NuttX/tools/px4_nuttx_make.sh b/platforms/nuttx/NuttX/tools/px4_nuttx_make.sh new file mode 100755 index 00000000000..d7197f8b1f2 --- /dev/null +++ b/platforms/nuttx/NuttX/tools/px4_nuttx_make.sh @@ -0,0 +1,16 @@ +#!/bin/sh +# Run make for a NuttX library or the NuttX apps with parallel jobs. +# +# If the build was started with an explicit job count, e.g. +# `make px4_fmu-v5x_default -j1`, MAKEFLAGS carries it (and with GNU make 4.4 +# its jobserver) through ninja to here, so honour it. Otherwise use the number +# of CPUs this process may run on, which, unlike the host's core count, +# respects limits like docker --cpuset-cpus. The load limit keeps the NuttX +# makes that ninja runs concurrently from oversubscribing the host. + +case " ${MAKEFLAGS} " in + *" -j"*) exec make "$@" ;; +esac + +jobs=$(nproc 2>/dev/null || getconf _NPROCESSORS_ONLN 2>/dev/null || echo 1) +exec make -j"${jobs}" -l"${jobs}" "$@" diff --git a/platforms/nuttx/src/px4/nxp/imxrt/include/px4_arch/px4io_serial.h b/platforms/nuttx/src/px4/nxp/imxrt/include/px4_arch/px4io_serial.h index 27e5a30ec2d..7d622298830 100644 --- a/platforms/nuttx/src/px4/nxp/imxrt/include/px4_arch/px4io_serial.h +++ b/platforms/nuttx/src/px4/nxp/imxrt/include/px4_arch/px4io_serial.h @@ -46,7 +46,7 @@ #include #include -#include +#include class PX4IO_serial : public device::Device { diff --git a/platforms/nuttx/src/px4/nxp/rt106x/px4io_serial/CMakeLists.txt b/platforms/nuttx/src/px4/nxp/rt106x/px4io_serial/CMakeLists.txt index df450593b1b..9ded6f86408 100644 --- a/platforms/nuttx/src/px4/nxp/rt106x/px4io_serial/CMakeLists.txt +++ b/platforms/nuttx/src/px4/nxp/rt106x/px4io_serial/CMakeLists.txt @@ -34,3 +34,4 @@ px4_add_library(arch_px4io_serial px4io_serial.cpp ) +target_link_libraries(arch_px4io_serial PRIVATE px4io_protocol) diff --git a/platforms/nuttx/src/px4/nxp/rt117x/px4io_serial/CMakeLists.txt b/platforms/nuttx/src/px4/nxp/rt117x/px4io_serial/CMakeLists.txt index df450593b1b..9ded6f86408 100644 --- a/platforms/nuttx/src/px4/nxp/rt117x/px4io_serial/CMakeLists.txt +++ b/platforms/nuttx/src/px4/nxp/rt117x/px4io_serial/CMakeLists.txt @@ -34,3 +34,4 @@ px4_add_library(arch_px4io_serial px4io_serial.cpp ) +target_link_libraries(arch_px4io_serial PRIVATE px4io_protocol) diff --git a/platforms/nuttx/src/px4/stm/stm32_common/include/px4_arch/px4io_serial.h b/platforms/nuttx/src/px4/stm/stm32_common/include/px4_arch/px4io_serial.h index bf33426d3ce..bc55077144e 100644 --- a/platforms/nuttx/src/px4/stm/stm32_common/include/px4_arch/px4io_serial.h +++ b/platforms/nuttx/src/px4/stm/stm32_common/include/px4_arch/px4io_serial.h @@ -46,7 +46,7 @@ #include #include -#include +#include class PX4IO_serial : public device::Device { diff --git a/platforms/nuttx/src/px4/stm/stm32f4/px4io_serial/CMakeLists.txt b/platforms/nuttx/src/px4/stm/stm32f4/px4io_serial/CMakeLists.txt index df450593b1b..9ded6f86408 100644 --- a/platforms/nuttx/src/px4/stm/stm32f4/px4io_serial/CMakeLists.txt +++ b/platforms/nuttx/src/px4/stm/stm32f4/px4io_serial/CMakeLists.txt @@ -34,3 +34,4 @@ px4_add_library(arch_px4io_serial px4io_serial.cpp ) +target_link_libraries(arch_px4io_serial PRIVATE px4io_protocol) diff --git a/platforms/nuttx/src/px4/stm/stm32f7/px4io_serial/CMakeLists.txt b/platforms/nuttx/src/px4/stm/stm32f7/px4io_serial/CMakeLists.txt index df450593b1b..9ded6f86408 100644 --- a/platforms/nuttx/src/px4/stm/stm32f7/px4io_serial/CMakeLists.txt +++ b/platforms/nuttx/src/px4/stm/stm32f7/px4io_serial/CMakeLists.txt @@ -34,3 +34,4 @@ px4_add_library(arch_px4io_serial px4io_serial.cpp ) +target_link_libraries(arch_px4io_serial PRIVATE px4io_protocol) diff --git a/platforms/nuttx/src/px4/stm/stm32h7/px4io_serial/CMakeLists.txt b/platforms/nuttx/src/px4/stm/stm32h7/px4io_serial/CMakeLists.txt index df450593b1b..9ded6f86408 100644 --- a/platforms/nuttx/src/px4/stm/stm32h7/px4io_serial/CMakeLists.txt +++ b/platforms/nuttx/src/px4/stm/stm32h7/px4io_serial/CMakeLists.txt @@ -34,3 +34,4 @@ px4_add_library(arch_px4io_serial px4io_serial.cpp ) +target_link_libraries(arch_px4io_serial PRIVATE px4io_protocol) diff --git a/platforms/qurt/src/px4/tasks.cpp b/platforms/qurt/src/px4/tasks.cpp index 568f9af03b9..2c5c1987561 100644 --- a/platforms/qurt/src/px4/tasks.cpp +++ b/platforms/qurt/src/px4/tasks.cpp @@ -38,6 +38,7 @@ #include #include +#include #include #include "hrt_work.h" @@ -51,6 +52,7 @@ typedef struct task_entry { pthread_t tid; + px4_task_t id; char name[PX4_TASK_MAX_NAME_LENGTH + 4]; char stack[PX4_TASK_STACK_SIZE]; pthread_attr_t attr; @@ -59,14 +61,135 @@ typedef struct task_entry { char argv_storage[PX4_TASK_MAX_ARGC][PX4_TASK_MAX_ARGV_LENGTH]; char *argv[PX4_TASK_MAX_ARGC]; bool isused; + bool exiting; + bool joining; + bool waiting; - task_entry() : isused(false) {} + task_entry() : tid(0), id(-1), isused(false), exiting(false), joining(false), waiting(false) {} } task_entry_t; static task_entry_t taskmap[PX4_MAX_TASKS]; -static bool task_mutex_initialized = false; -static pthread_mutex_t task_mutex; +static pthread_mutex_t task_mutex = PTHREAD_MUTEX_INITIALIZER; +static pthread_cond_t task_cond = PTHREAD_COND_INITIALIZER; + +// Task handles must not alias a new task when a table slot is reused. Every +// successfully issued handle below next_task_id is either still in taskmap or +// has already been joined. This also lets a late px4_task_join() succeed after +// automatic reaping, without retaining an unbounded list of completed tasks. +static unsigned int next_task_id = 0; + +// All taskmap helpers require task_mutex to be held. +static task_entry_t *find_task(px4_task_t id) +{ + for (task_entry_t &task : taskmap) { + if (task.isused && task.id == id) { + return &task; + } + } + + return nullptr; +} + +static task_entry_t *find_current_task() +{ + const pthread_t tid = pthread_self(); + + for (task_entry_t &task : taskmap) { + // A joined pthread's native ID can be reused before its joiner gets + // task_mutex back. Do not mistake that old entry for the new thread. + if (task.isused && !task.exiting && task.tid == tid) { + return &task; + } + } + + return nullptr; +} + +// Construct and destroy with task_mutex held. Cancelling a task while it owns +// a join or waits on task_cond could strand a reserved slot or a locked mutex. +// QuRT does not expose pthread cleanup handlers, so deletion returns EBUSY +// during these waits instead. Cooperative task shutdown is unaffected. +class TaskWaitGuard +{ +public: + TaskWaitGuard() : _task(find_current_task()) + { + if (_task) { _task->waiting = true; } + } + + ~TaskWaitGuard() + { + if (_task) { _task->waiting = false; } + } + +private: + task_entry_t *_task; +}; + +static int join_task(task_entry_t &task) +{ + // Keep the slot reserved while the mutex is released. Only one caller may + // join this pthread, and it must terminate before its argv/attributes can + // be reused. In particular, never hold task_mutex across pthread_join(). + task.joining = true; + const pthread_t tid = task.tid; + TaskWaitGuard wait_guard; + pthread_mutex_unlock(&task_mutex); + const int ret = pthread_join(tid, nullptr); + pthread_mutex_lock(&task_mutex); + + if (ret == 0) { + pthread_attr_destroy(&task.attr); + task.tid = 0; + task.isused = false; + } + + task.joining = false; + pthread_cond_broadcast(&task_cond); + return ret; +} + +static int wait_for_task(px4_task_t id) +{ + if (id < 0 || static_cast(id) >= next_task_id) { + return -EINVAL; + } + + while (task_entry_t *task = find_task(id)) { + if (!task->exiting && task->tid == pthread_self()) { + return -EINVAL; + } + + if (!task->joining) { + return join_task(*task); + } + + // Another join/delete/spawn owns the pthread_join(). Recheck the + // handle after waking because its slot may already have been reused. + TaskWaitGuard wait_guard; + const int ret = pthread_cond_wait(&task_cond, &task_mutex); + + if (ret != 0) { + return ret; + } + } + + return 0; // This handle was already reaped. +} + +static void reap_exiting_tasks() +{ + for (task_entry_t &task : taskmap) { + if (task.isused && task.exiting && !task.joining && task.tid != pthread_self()) { + const int ret = join_task(task); + + if (ret != 0) { + PX4_ERR("Couldn't join exited task %d (%d)", task.id, ret); + } + } + } +} // These are some Qurt pthread stubs needed for compilation and linking extern "C" { @@ -114,12 +237,13 @@ static void *entry_adapter(void *ptr) { task_entry_t *data; data = (task_entry_t *) ptr; + int ret = -1; - if (data->main_entry) { data->main_entry(data->argc, data->argv); } + if (data->main_entry) { ret = data->main_entry(data->argc, data->argv); } else { PX4_ERR("No valid task entry points"); } - pthread_exit(nullptr); + px4_task_exit(ret); return nullptr; } @@ -133,13 +257,19 @@ static px4_task_t px4_task_spawn_internal(const char *name, int priority, px4_ma PX4_INFO("Creating pthread %s", name); - if (task_mutex_initialized == false) { - task_mutex_initialized = true; - pthread_mutex_init(&task_mutex, nullptr); - } - pthread_mutex_lock(&task_mutex); + // Normal module shutdown does not call px4_task_join(). Reap completed + // threads here so both their slots and pthread resources can be reused. + reap_exiting_tasks(); + + // Do not wrap task handles and risk operating on a replacement task. + if (next_task_id > static_cast(INT_MAX)) { + pthread_mutex_unlock(&task_mutex); + PX4_ERR("Task handles exhausted"); + return -1; + } + for (task_index = 0; task_index < PX4_MAX_TASKS; task_index++) { if (taskmap[task_index].isused == false) { break; } } @@ -256,10 +386,15 @@ static px4_task_t px4_task_spawn_internal(const char *name, int priority, px4_ma } taskmap[task_index].isused = true; + taskmap[task_index].exiting = false; + taskmap[task_index].joining = false; + taskmap[task_index].waiting = false; + const px4_task_t task_id = static_cast(next_task_id++); + taskmap[task_index].id = task_id; pthread_mutex_unlock(&task_mutex); - return task_index; + return task_id; } px4_task_t px4_task_spawn_cmd(const char *name, int scheduler, int priority, int stack_size, px4_main_t entry, @@ -275,126 +410,79 @@ px4_task_t px4_task_spawn_cmd(const char *name, int scheduler, int priority, int int px4_task_join(px4_task_t id) { - if (id < 0 || id >= PX4_MAX_TASKS) { - return -EINVAL; - } - - if (!task_mutex_initialized) { - return -EINVAL; - } - pthread_mutex_lock(&task_mutex); - pthread_t pid = taskmap[id].tid; + const int ret = wait_for_task(id); pthread_mutex_unlock(&task_mutex); - - if (pid == 0 || pthread_self() == pid) { - return -EINVAL; - } - - int rv = pthread_join(pid, nullptr); - - if (rv == 0) { - pthread_mutex_lock(&task_mutex); - - if (taskmap[id].isused && taskmap[id].tid == pid) { - pthread_attr_destroy(&taskmap[id].attr); - taskmap[id].isused = false; - } - - pthread_mutex_unlock(&task_mutex); - } - - return rv; + return ret; } int px4_task_delete(px4_task_t id) { - int rv = 0; + pthread_mutex_lock(&task_mutex); - PX4_ERR("Ignoring px4_task_delete for task %d", id); - - pthread_t pid; - PX4_WARN("Called px4_task_delete"); - - if (id < PX4_MAX_TASKS && taskmap[id].isused) { - pid = taskmap[id].tid; - - } else { + if (id < 0 || static_cast(id) >= next_task_id) { + pthread_mutex_unlock(&task_mutex); return -EINVAL; } - pthread_mutex_lock(&task_mutex); + task_entry_t *task = find_task(id); - if (pthread_self() == pid) { - pthread_join(pid, nullptr); - pthread_attr_destroy(&taskmap[id].attr); - taskmap[id].isused = false; + if (task == nullptr) { pthread_mutex_unlock(&task_mutex); - pthread_exit(nullptr); - - } else { - rv = pthread_cancel(pid); - pthread_mutex_unlock(&task_mutex); - - if (rv == 0) { - pthread_join(pid, nullptr); - } - - pthread_mutex_lock(&task_mutex); + return 0; // Already reaped; never cancel a replacement task. } - pthread_attr_destroy(&taskmap[id].attr); - taskmap[id].isused = false; - pthread_mutex_unlock(&task_mutex); + if (!task->exiting && pthread_self() == task->tid) { + pthread_mutex_unlock(&task_mutex); + px4_task_exit(0); + return 0; + } - return rv; + if (task->waiting) { + pthread_mutex_unlock(&task_mutex); + return -EBUSY; + } + + if (!task->exiting) { + const int ret = pthread_cancel(task->tid); + + if (ret != 0) { + pthread_mutex_unlock(&task_mutex); + return ret; + } + + // Cancellation may bypass px4_task_exit(). Prevent another caller + // from cancelling/signalling a native ID that has already been joined. + task->exiting = true; + } + + const int ret = wait_for_task(id); + pthread_mutex_unlock(&task_mutex); + return ret; } void px4_task_exit(int ret) { - PX4_ERR("Ignoring px4_task_exit with return value %d", ret); + pthread_mutex_lock(&task_mutex); + task_entry_t *task = find_current_task(); - int i; - pthread_t pid = pthread_self(); - - for (i = 0; i < PX4_MAX_TASKS; ++i) { - if (taskmap[i].tid == pid) { - pthread_mutex_lock(&task_mutex); - pthread_attr_destroy(&taskmap[i].attr); - taskmap[i].isused = false; - break; - } - } - - if (i >= PX4_MAX_TASKS) { - PX4_ERR("px4_task_exit: self task not found!"); - - } else { - PX4_DEBUG("px4_task_exit: %s", taskmap[i].name); - pthread_mutex_unlock(&task_mutex); + if (task) { + // Retain the slot until another thread has joined us. Clearing it + // here would permit reuse before pthread_exit() has completed. + task->exiting = true; } + pthread_mutex_unlock(&task_mutex); pthread_exit((void *)(unsigned long)ret); } int px4_task_kill(px4_task_t id, int sig) { - int rv = 0; - pthread_t pid; - PX4_DEBUG("Called px4_task_kill %d, taskname %s", sig, taskmap[id].name); - - if (id < PX4_MAX_TASKS && taskmap[id].tid != 0) { - pthread_mutex_lock(&task_mutex); - pid = taskmap[id].tid; - pthread_mutex_unlock(&task_mutex); - - } else { - return -EINVAL; - } - - rv = pthread_kill(pid, sig); - - return rv; + pthread_mutex_lock(&task_mutex); + task_entry_t *task = find_task(id); + const int ret = (task != nullptr && !task->exiting) ? pthread_kill(task->tid, sig) : -EINVAL; + pthread_mutex_unlock(&task_mutex); + return ret; } void px4_show_tasks() @@ -403,15 +491,18 @@ void px4_show_tasks() int count = 0; PX4_INFO("Active Tasks:"); + pthread_mutex_lock(&task_mutex); for (; idx < PX4_MAX_TASKS; idx++) { - if (taskmap[idx].isused) { + if (taskmap[idx].isused && !taskmap[idx].exiting) { PX4_INFO(" %-10s %u", taskmap[idx].name, (unsigned int) taskmap[idx].tid); count++; } } + pthread_mutex_unlock(&task_mutex); + if (count == 0) { PX4_INFO("No running tasks"); } @@ -419,17 +510,9 @@ void px4_show_tasks() px4_task_t px4_getpid() { - pthread_t pid = pthread_self(); - px4_task_t ret = -1; - pthread_mutex_lock(&task_mutex); - - for (int i = 0; i < PX4_MAX_TASKS; i++) { - if (taskmap[i].isused && taskmap[i].tid == pid) { - ret = i; - } - } - + task_entry_t *task = find_current_task(); + const px4_task_t ret = task ? task->id : -1; pthread_mutex_unlock(&task_mutex); return ret; @@ -438,17 +521,9 @@ px4_task_t px4_getpid() const char *px4_get_taskname() { - pthread_t pid = pthread_self(); - const char *prog_name = "UnknownApp"; - pthread_mutex_lock(&task_mutex); - - for (int i = 0; i < PX4_MAX_TASKS; i++) { - if (taskmap[i].isused && taskmap[i].tid == pid) { - prog_name = taskmap[i].name; - } - } - + task_entry_t *task = find_current_task(); + const char *prog_name = task ? task->name : "UnknownApp"; pthread_mutex_unlock(&task_mutex); return prog_name; @@ -485,12 +560,10 @@ int px4_prctl(int option, const char *arg2, px4_task_t pid) pthread_mutex_lock(&task_mutex); - for (int i = 0; i < PX4_MAX_TASKS; i++) { - if (taskmap[i].isused && taskmap[i].tid == (pthread_t) pid) { - rv = pthread_attr_setthreadname(&taskmap[i].attr, arg2); - pthread_mutex_unlock(&task_mutex); - return rv; - } + task_entry_t *task = find_task(pid); + + if (task != nullptr && !task->exiting) { + rv = pthread_attr_setthreadname(&task->attr, arg2); } pthread_mutex_unlock(&task_mutex); diff --git a/posix-configs/rpi/navigator/sub.config b/posix-configs/rpi/navigator/sub.config index 20aa57d9fec..d1c49de30af 100644 --- a/posix-configs/rpi/navigator/sub.config +++ b/posix-configs/rpi/navigator/sub.config @@ -19,7 +19,7 @@ param set EKF2_BARO_CTRL 1 param set EKF2_HGT_REF 0 param set EKF2_RNG_CTRL 0 -param set EKF2_OF_CTRL 0 +param set EKF2_OF0_CTRL 0 param set EKF2_EV_CTRL 0 dataman start diff --git a/src/drivers/actuators/vertiq_io/vertiq_io.cpp b/src/drivers/actuators/vertiq_io/vertiq_io.cpp index bdef50b5f22..0b1fc5f2ca7 100644 --- a/src/drivers/actuators/vertiq_io/vertiq_io.cpp +++ b/src/drivers/actuators/vertiq_io/vertiq_io.cpp @@ -55,7 +55,7 @@ VertiqIo::VertiqIo(const char *port) : //Make sure we get the correct initial values for our parameters updateParams(); - _configuration_handler.InitConfigurationClients((uint8_t)_param_vertiq_target_module_id.get()); + _configuration_handler.InitConfigurationClients((uint8_t)_param_vtq_trgt_mod_id.get()); _configuration_handler.InitClientEntryWrappers(); _client_manager.AddNewClient(&_operational_ifci); @@ -76,22 +76,22 @@ VertiqIo::~VertiqIo() //called by our task_spawn function bool VertiqIo::init() { - _serial_interface.InitSerial(_port, _param_vertiq_baud.get()); + _serial_interface.InitSerial(_port, _param_vtq_baud.get()); #ifdef CONFIG_USE_IFCI_CONFIGURATION //Grab the number of IFCI control values the user wants to use - _cvs_in_use = (uint8_t)_param_vertiq_number_of_cvs.get(); + _cvs_in_use = (uint8_t)_param_vtq_num_cvs.get(); //Grab the bitmask that we're going to use to decide who we get telemetry from - _telemetry_ids_1 = (uint32_t)_param_vertiq_telem_ids_1.get(); - _telemetry_ids_2 = (uint32_t)_param_vertiq_telem_ids_2.get(); + _telemetry_ids_1 = (uint32_t)_param_vtq_telem_ids_1.get(); + _telemetry_ids_2 = (uint32_t)_param_vtq_telem_ids_2.get(); _telem_bitmask = ((uint64_t)(_telemetry_ids_2) << 32) | _telemetry_ids_1; _transmission_message.num_cvs = _cvs_in_use; #endif //Initialize our telemetry handler - _telem_manager.Init(_telem_bitmask, (uint8_t)_param_vertiq_target_module_id.get()); + _telem_manager.Init(_telem_bitmask, (uint8_t)_param_vtq_trgt_mod_id.get()); _telem_manager.StartPublishing(&_esc_status_pub); //Make sure we get our thread into execution @@ -164,19 +164,19 @@ void VertiqIo::parameters_update() updateParams(); //If the target module ID changed, we need to update all of our parameters - if (_param_vertiq_target_module_id.get() != _configuration_handler.GetObjectIdNow()) { - _configuration_handler.UpdateClientsToNewObjId(_param_vertiq_target_module_id.get()); + if (_param_vtq_trgt_mod_id.get() != _configuration_handler.GetObjectIdNow()) { + _configuration_handler.UpdateClientsToNewObjId(_param_vtq_trgt_mod_id.get()); //Make sure we start a new read! - _param_vertiq_trigger_read.set(true); - _param_vertiq_trigger_read.commit_no_notification(); + _param_vtq_redo_read.set(true); + _param_vtq_redo_read.commit_no_notification(); } //If you're set to re-read from the motor, mark all of the IQUART parameters for reinitialization, reset the trigger, and then update the IFCI params - if (_param_vertiq_trigger_read.get()) { + if (_param_vtq_redo_read.get()) { _configuration_handler.MarkConfigurationEntriesForRefresh(); - _param_vertiq_trigger_read.set(false); - _param_vertiq_trigger_read.commit_no_notification(); + _param_vtq_redo_read.set(false); + _param_vtq_redo_read.commit_no_notification(); } _configuration_handler.UpdateIquartConfigParams(); @@ -201,7 +201,7 @@ bool VertiqIo::updateOutputs(float outputs[MAX_ACTUATORS], unsigned num_outputs, if (_mixing_output.armed().armed) { - if (_param_vertiq_arm_behavior.get() == FORCE_ARMING && _send_forced_arm) { + if (_param_vtq_arm_behave.get() == FORCE_ARMING && _send_forced_arm) { _broadcast_arming_handler.motor_armed_.set(*_serial_interface.GetIquartInterface(), 1); _send_forced_arm = false; } @@ -218,7 +218,7 @@ bool VertiqIo::updateOutputs(float outputs[MAX_ACTUATORS], unsigned num_outputs, } else { //Put the modules into coast - switch (_param_vertiq_disarm_behavior.get()) { + switch (_param_vtq_disarm_trig.get()) { case TRIGGER_MOTOR_DISARM: _broadcast_arming_handler.motor_armed_.set(*_serial_interface.GetIquartInterface(), 0); break; @@ -229,7 +229,7 @@ bool VertiqIo::updateOutputs(float outputs[MAX_ACTUATORS], unsigned num_outputs, case SEND_PREDEFINED_VELOCITY: _broadcast_prop_motor_control.ctrl_velocity_.set(*_serial_interface.GetIquartInterface(), - _param_vertiq_disarm_velocity.get()); + _param_vtq_disarm_velo.get()); break; default: diff --git a/src/drivers/actuators/vertiq_io/vertiq_io.hpp b/src/drivers/actuators/vertiq_io/vertiq_io.hpp index eb0079dc434..cbe1ed08824 100644 --- a/src/drivers/actuators/vertiq_io/vertiq_io.hpp +++ b/src/drivers/actuators/vertiq_io/vertiq_io.hpp @@ -175,32 +175,32 @@ private: //We need to bring in the parameters that we define in module.yaml in order to view them in the //control station, as well as to use them in the firmware DEFINE_PARAMETERS( - (ParamInt) _param_vertiq_baud, - (ParamInt) _param_vertiq_target_module_id, - (ParamBool) _param_vertiq_trigger_read, - (ParamInt) _param_vertiq_control_mode, - (ParamFloat) _param_vertiq_max_velo, - (ParamFloat) _param_vertiq_max_volts, - (ParamInt) _param_vertiq_motor_direction, - (ParamInt) _param_vertiq_fc_direction + (ParamInt) _param_vtq_baud, + (ParamInt) _param_vtq_trgt_mod_id, + (ParamBool) _param_vtq_redo_read, + (ParamInt) _param_vtq_control_mode, + (ParamFloat) _param_vtq_max_velocity, + (ParamFloat) _param_vtq_max_volts, + (ParamInt) _param_vtq_motor_dir, + (ParamInt) _param_vtq_fc_dir #ifdef CONFIG_USE_IFCI_CONFIGURATION - , (ParamInt) _param_vertiq_number_of_cvs - , (ParamInt) _param_vertiq_disarm_velocity - , (ParamInt) _param_vertiq_disarm_behavior - , (ParamInt) _param_vertiq_arm_behavior - , (ParamInt) _param_vertiq_throttle_cvi - , (ParamInt) _param_vertiq_telem_ids_1 - , (ParamInt) _param_vertiq_telem_ids_2 + , (ParamInt) _param_vtq_num_cvs + , (ParamInt) _param_vtq_disarm_velo + , (ParamInt) _param_vtq_disarm_trig + , (ParamInt) _param_vtq_arm_behave + , (ParamInt) _param_vtq_throttle_cvi + , (ParamInt) _param_vtq_telem_ids_1 + , (ParamInt) _param_vtq_telem_ids_2 #endif //CONFIG_USE_IFCI_CONFIGURATION #ifdef CONFIG_USE_PULSING_CONFIGURATION - , (ParamInt) _param_vertiq_pulse_volt_mode - , (ParamInt) _param_vertiq_pulse_x_cvi - , (ParamInt) _param_vertiq_pulse_y_cvi - , (ParamFloat) _param_vertiq_pulse_zero_angle - , (ParamFloat) _param_vertiq_pulse_velo_cutoff - , (ParamFloat) _param_vertiq_pulse_torque_offset_angle - , (ParamFloat) _param_vertiq_pulse_voltage_limit + , (ParamInt) _param_vtq_pulse_v_mode + , (ParamInt) _param_vtq_x_cvi + , (ParamInt) _param_vtq_y_cvi + , (ParamFloat) _param_vtq_zero_angle + , (ParamFloat) _param_vtq_velo_cutoff + , (ParamFloat) _param_vtq_tque_off_ang + , (ParamFloat) _param_vtq_pulse_v_lim #endif //CONFIG_USE_PULSING_CONFIGURATION ) }; diff --git a/src/drivers/adc/ads7128/ads7128.cpp b/src/drivers/adc/ads7128/ads7128.cpp index 4d95adf2849..f9939ba6cad 100644 --- a/src/drivers/adc/ads7128/ads7128.cpp +++ b/src/drivers/adc/ads7128/ads7128.cpp @@ -82,7 +82,7 @@ int ADS7128::init() } _adc_report.device_id = this->get_device_id(); - _adc_report.v_ref = _adc_ads7128_refv.get(); + _adc_report.v_ref = _param_adc_ads7128_refv.get(); _adc_report.resolution = 4096; ScheduleNow(); diff --git a/src/drivers/adc/ads7128/ads7128.h b/src/drivers/adc/ads7128/ads7128.h index 020e8d795c1..420868c6be1 100644 --- a/src/drivers/adc/ads7128/ads7128.h +++ b/src/drivers/adc/ads7128/ads7128.h @@ -65,7 +65,7 @@ private: adc_report_s _adc_report{}; DEFINE_PARAMETERS( - (ParamFloat) _adc_ads7128_refv + (ParamFloat) _param_adc_ads7128_refv ) int init_reset(); diff --git a/src/drivers/adc/ads7953/ADS7953.cpp b/src/drivers/adc/ads7953/ADS7953.cpp index 8a25b56c5be..66daec35969 100644 --- a/src/drivers/adc/ads7953/ADS7953.cpp +++ b/src/drivers/adc/ads7953/ADS7953.cpp @@ -32,7 +32,7 @@ int ADS7953::init() } _adc_report.device_id = this->get_device_id(); - _adc_report.v_ref = _adc_ads7953_refv.get(); + _adc_report.v_ref = _param_adc_ads7953_refv.get(); _adc_report.resolution = 4096; for (unsigned i = 0; i < PX4_MAX_ADC_CHANNELS; ++i) { diff --git a/src/drivers/adc/ads7953/ADS7953.h b/src/drivers/adc/ads7953/ADS7953.h index 7d955a274fe..7a51db495e6 100644 --- a/src/drivers/adc/ads7953/ADS7953.h +++ b/src/drivers/adc/ads7953/ADS7953.h @@ -36,7 +36,7 @@ private: perf_counter_t _comms_errors; DEFINE_PARAMETERS( - (ParamFloat) _adc_ads7953_refv + (ParamFloat) _param_adc_ads7953_refv ) adc_report_s _adc_report{}; diff --git a/src/drivers/adc/tla2528/tla2528.cpp b/src/drivers/adc/tla2528/tla2528.cpp index e537a3ca61b..73d224212db 100644 --- a/src/drivers/adc/tla2528/tla2528.cpp +++ b/src/drivers/adc/tla2528/tla2528.cpp @@ -79,7 +79,7 @@ int TLA2528::init() } _adc_report.device_id = this->get_device_id(); - _adc_report.v_ref = _adc_tla2528_refv.get(); + _adc_report.v_ref = _param_adc_tla2528_refv.get(); _adc_report.resolution = 4096; ScheduleClear(); diff --git a/src/drivers/adc/tla2528/tla2528.h b/src/drivers/adc/tla2528/tla2528.h index b95aaf364eb..5dbacfc21c7 100644 --- a/src/drivers/adc/tla2528/tla2528.h +++ b/src/drivers/adc/tla2528/tla2528.h @@ -65,7 +65,7 @@ private: adc_report_s _adc_report{}; DEFINE_PARAMETERS( - (ParamFloat) _adc_tla2528_refv + (ParamFloat) _param_adc_tla2528_refv ) int init_reset(); diff --git a/src/drivers/cdcacm_autostart/cdcacm_autostart.cpp b/src/drivers/cdcacm_autostart/cdcacm_autostart.cpp index fdab5f80483..be06f784368 100644 --- a/src/drivers/cdcacm_autostart/cdcacm_autostart.cpp +++ b/src/drivers/cdcacm_autostart/cdcacm_autostart.cpp @@ -221,7 +221,7 @@ void CdcAcmAutostart::state_connecting() // /dev/ttyACM0 immediately, but open() returns -ENOTCONN until the host has // enumerated. mavlink exits if its own open retries run out, so only spawn it // once the port is known to be openable, then release the probe. - if (_sys_usb_auto.get() == 2) { + if (_param_sys_usb_auto.get() == 2) { if (_ttyacm_fd < 0) { _ttyacm_fd = px4_open(USB_DEVICE_PATH, O_RDONLY | O_NONBLOCK); } @@ -247,7 +247,7 @@ void CdcAcmAutostart::state_connecting() } // SYS_USB_AUTO=0: sercon only, no protocol. - if (_sys_usb_auto.get() == 0) { + if (_param_sys_usb_auto.get() == 0) { close_ttyacm(); _state = UsbAutoStartState::connected; _active_protocol = UsbProtocol::none; @@ -520,7 +520,7 @@ bool CdcAcmAutostart::scan_buffer_for_ublox_bytes() bool CdcAcmAutostart::start_mavlink() { char mavlink_mode_string[16]; - snprintf(mavlink_mode_string, sizeof(mavlink_mode_string), "%ld", _usb_mav_mode.get()); + snprintf(mavlink_mode_string, sizeof(mavlink_mode_string), "%ld", _param_usb_mav_mode.get()); // Non-static argv: NuttX task_spawn copies argv into the new task stack before return. char *argv[] { (char *)"mavlink", (char *)"start", (char *)"-d", (char *)USB_DEVICE_PATH, @@ -656,7 +656,7 @@ int CdcAcmAutostart::print_status() PX4_INFO("State: %s", state); PX4_INFO("Protocol: %s", protocol); PX4_INFO("VBUS: %s", _vbus_present ? "present" : "absent"); - PX4_INFO("SYS_USB_AUTO: %ld", _sys_usb_auto.get()); + PX4_INFO("SYS_USB_AUTO: %ld", _param_sys_usb_auto.get()); return PX4_OK; } diff --git a/src/drivers/cdcacm_autostart/cdcacm_autostart.h b/src/drivers/cdcacm_autostart/cdcacm_autostart.h index fe3f3879f5d..5e4a9d58175 100644 --- a/src/drivers/cdcacm_autostart/cdcacm_autostart.h +++ b/src/drivers/cdcacm_autostart/cdcacm_autostart.h @@ -123,7 +123,7 @@ private: uint32_t _reschedule_time{0}; DEFINE_PARAMETERS( - (ParamInt) _sys_usb_auto, - (ParamInt) _usb_mav_mode + (ParamInt) _param_sys_usb_auto, + (ParamInt) _param_usb_mav_mode ) }; diff --git a/src/drivers/cyphal/CanardHandle.cpp b/src/drivers/cyphal/CanardHandle.cpp index 96a170c2403..3e5e7d1aeee 100644 --- a/src/drivers/cyphal/CanardHandle.cpp +++ b/src/drivers/cyphal/CanardHandle.cpp @@ -84,6 +84,13 @@ CanardHandle::CanardHandle(uint32_t node_id, const size_t capacity, const size_t } +void CanardHandle::close() +{ + if (_can_interface) { + _can_interface->close(); + } +} + CanardHandle::~CanardHandle() { if (_can_interface) { diff --git a/src/drivers/cyphal/CanardHandle.hpp b/src/drivers/cyphal/CanardHandle.hpp index 63682442e6d..8e5991cd091 100644 --- a/src/drivers/cyphal/CanardHandle.hpp +++ b/src/drivers/cyphal/CanardHandle.hpp @@ -56,6 +56,10 @@ public: void receive(); void transmit(); + /// Close the CAN interface. File descriptors are per task group on NuttX, + /// so this must be called from the thread that opened it (the work queue). + void close(); + int32_t TxPush(const CanardMicrosecond tx_deadline_usec, const CanardTransferMetadata *const metadata, const size_t payload_size, diff --git a/src/drivers/cyphal/CanardNuttXCDev.hpp b/src/drivers/cyphal/CanardNuttXCDev.hpp index 6b7047a2e77..990d78564e1 100644 --- a/src/drivers/cyphal/CanardNuttXCDev.hpp +++ b/src/drivers/cyphal/CanardNuttXCDev.hpp @@ -36,6 +36,7 @@ #include #include +#include #include "CanardInterface.hpp" @@ -61,6 +62,18 @@ public: /// The return value is number of bytes received, negative value on error. int16_t receive(CanardRxFrame *rxf); + /// Close the CAN device + int close() override + { + if (_fd < 0) { + return 0; + } + + const int ret = ::close(_fd); + _fd = -1; + return ret; + } + private: int _fd{-1}; bool _can_fd{false}; diff --git a/src/drivers/cyphal/CanardSocketCAN.hpp b/src/drivers/cyphal/CanardSocketCAN.hpp index f7ddc73b5cb..941da777688 100644 --- a/src/drivers/cyphal/CanardSocketCAN.hpp +++ b/src/drivers/cyphal/CanardSocketCAN.hpp @@ -64,7 +64,13 @@ public: /// Close socket connection int close() { - return ::close(_fd); + if (_fd < 0) { + return 0; + } + + const int ret = ::close(_fd); + _fd = -1; + return ret; } /// Send a CanardFrame to the CanardSocketInstance socket diff --git a/src/drivers/cyphal/Cyphal.cpp b/src/drivers/cyphal/Cyphal.cpp index f6b411ac657..5846c867390 100644 --- a/src/drivers/cyphal/Cyphal.cpp +++ b/src/drivers/cyphal/Cyphal.cpp @@ -225,6 +225,10 @@ void CyphalNode::Run() if (_instance && _task_should_exit.load()) { ScheduleClear(); + // The CAN fd belongs to the work queue task group, so close it here + // and not in the destructor, which runs in the shell calling stop. + _canard_handle.close(); + if (_initialized) { _initialized = false; } diff --git a/src/drivers/cyphal/Cyphal.hpp b/src/drivers/cyphal/Cyphal.hpp index 10495c2160c..083f5449cb5 100644 --- a/src/drivers/cyphal/Cyphal.hpp +++ b/src/drivers/cyphal/Cyphal.hpp @@ -160,9 +160,9 @@ private: CanardTransferID _uavcan_node_heartbeat_transfer_id{0}; DEFINE_PARAMETERS( - (ParamInt) _param_uavcan_v1_enable, - (ParamInt) _param_uavcan_v1_id, - (ParamInt) _param_uavcan_v1_baud + (ParamInt) _param_cyphal_enable, + (ParamInt) _param_cyphal_id, + (ParamInt) _param_cyphal_baud ) UavcanParamManager _param_manager; diff --git a/src/drivers/differential_pressure/dlvr/DLVR.cpp b/src/drivers/differential_pressure/dlvr/DLVR.cpp index 97a25dd3b58..0ee183b0009 100644 --- a/src/drivers/differential_pressure/dlvr/DLVR.cpp +++ b/src/drivers/differential_pressure/dlvr/DLVR.cpp @@ -246,7 +246,7 @@ void DLVR::publish_pressure(const float pressure_p, const float temperature_c, differential_pressure.differential_pressure_pa = pressure_p; //If differential pressure reverse param set, swap positive and negative - if (_param_dpres_rev.get() == 1) { + if (_param_sens_dpres_rev.get() == 1) { differential_pressure.differential_pressure_pa = -1.0f * pressure_p; } diff --git a/src/drivers/differential_pressure/dlvr/DLVR.hpp b/src/drivers/differential_pressure/dlvr/DLVR.hpp index abc75e94f66..89b7f51ba2b 100644 --- a/src/drivers/differential_pressure/dlvr/DLVR.hpp +++ b/src/drivers/differential_pressure/dlvr/DLVR.hpp @@ -77,7 +77,7 @@ private: float process_temperature_raw(const float temperature_raw) const; DEFINE_PARAMETERS( - (ParamInt) _param_dpres_rev, + (ParamInt) _param_sens_dpres_rev, (ParamInt) _param_sens_en_dlvr ) diff --git a/src/drivers/distance_sensor/broadcom/afbrs50/AFBRS50.cpp b/src/drivers/distance_sensor/broadcom/afbrs50/AFBRS50.cpp index 50e5b506bc2..35317f143ed 100644 --- a/src/drivers/distance_sensor/broadcom/afbrs50/AFBRS50.cpp +++ b/src/drivers/distance_sensor/broadcom/afbrs50/AFBRS50.cpp @@ -75,7 +75,7 @@ AFBRS50::AFBRS50(): px4_sem_init(&_wake_sem, 0, 0); px4_sem_setprotocol(&_wake_sem, SEM_PRIO_NONE); - int32_t rotation = _p_sens_afbr_rot.get(); + int32_t rotation = _param_sens_afbr_rot.get(); // Valid orientations from distance_sensor_s: ROTATION_YAW_* (0-7), ROTATION_UPWARD_FACING (24), ROTATION_DOWNWARD_FACING (25). const bool is_yaw = (rotation >= 0 && rotation <= 7); @@ -226,7 +226,7 @@ int AFBRS50::init() // A negative mode parameter selects the module's default measurement mode // as defined by the API; a mode the API rejects falls back to it as well. - int32_t mode_param = _p_sens_afbr_mode.get(); + int32_t mode_param = _param_sens_afbr_mode.get(); if (mode_param > 4) { PX4_ERR("Invalid SENS_AFBR_MODE %ld, using module default mode", (long)mode_param); @@ -427,7 +427,7 @@ void AFBRS50::run_state_configure() } status_t status = STATUS_OK; - const int32_t dfm_param = _p_sens_afbr_dfm.get(); + const int32_t dfm_param = _param_sens_afbr_dfm.get(); if (dfm_param >= 0 && dfm_param <= DFM_MODE_8X) { status = setDfm(static_cast(dfm_param)); @@ -446,7 +446,7 @@ void AFBRS50::run_state_configure() } if (status == STATUS_OK) { - const int32_t rate_param = _p_sens_afbr_rate.get(); + const int32_t rate_param = _param_sens_afbr_rate.get(); uint32_t rate_hz = (rate_param > 0) ? (uint32_t)rate_param : defaultRate(); if (rate_hz > 0) { @@ -488,7 +488,7 @@ void AFBRS50::run_state_configure() return; } - int32_t snm_mode = _p_sens_afbr_snm.get(); + int32_t snm_mode = _param_sens_afbr_snm.get(); if (snm_mode < 0 || snm_mode > SNM_MODE_DYNAMIC_PLUS) { PX4_ERR("Invalid SENS_AFBR_SNM %ld, using dynamic plus", (long)snm_mode); @@ -507,8 +507,8 @@ void AFBRS50::run_state_configure() // calibration loaded at init. Zero means "not calibrated": leave the // factory global offsets untouched. The smallest representable offset is // 1/32768 m, so the epsilon separates a real calibration from 0.0. - const float ofs_lo = _p_sens_afbr_ofs_lo.get(); - const float ofs_hi = _p_sens_afbr_ofs_hi.get(); + const float ofs_lo = _param_sens_afbr_ofs_lo.get(); + const float ofs_hi = _param_sens_afbr_ofs_hi.get(); if ((fabsf(ofs_lo) > 1e-6f) || (fabsf(ofs_hi) > 1e-6f)) { // Non-fatal: a rejected offset write must not block measurements. @@ -615,7 +615,7 @@ void AFBRS50::run_state_collect() float distance = static_cast(result_mm) / 1000.f; int8_t quality = res.Bin.SignalQuality; - if ((_p_sens_afbr_qmin.get() > 0) && (quality < _p_sens_afbr_qmin.get())) { + if ((_param_sens_afbr_qmin.get() > 0) && (quality < _param_sens_afbr_qmin.get())) { perf_count(_quality_gated_perf); quality = 0; } @@ -819,7 +819,7 @@ status_t AFBRS50::setRate(uint32_t rate_hz) const AFBRS50::RateDfmProfile *AFBRS50::profile() const { - int32_t index = _p_sens_afbr_prof.get(); + int32_t index = _param_sens_afbr_prof.get(); if ((index < 0) || (index >= (int32_t)kProfileCount)) { index = 0; @@ -873,7 +873,7 @@ void AFBRS50::updateMaxDistanceFromApi() argus_mode_t AFBRS50::argusModeFromParameter() { - int32_t mode_param = _p_sens_afbr_mode.get(); + int32_t mode_param = _param_sens_afbr_mode.get(); argus_mode_t mode = ARGUS_MODE_SHORT_RANGE; if (mode_param < 0 || mode_param > 4) { @@ -938,7 +938,7 @@ int AFBRS50::print_status() } PX4_INFO_RAW("profile: %ld quality gate: %ld\n", - (long)_p_sens_afbr_prof.get(), (long)_p_sens_afbr_qmin.get()); + (long)_param_sens_afbr_prof.get(), (long)_param_sens_afbr_qmin.get()); PX4_INFO_RAW("distance: %.3fm\n", (double)_current_distance); PX4_INFO_RAW("rate: %u Hz\n", (uint)(1000000 / _measurement_inverval)); diff --git a/src/drivers/distance_sensor/broadcom/afbrs50/AFBRS50.hpp b/src/drivers/distance_sensor/broadcom/afbrs50/AFBRS50.hpp index c886566c50d..adf6ae990a6 100644 --- a/src/drivers/distance_sensor/broadcom/afbrs50/AFBRS50.hpp +++ b/src/drivers/distance_sensor/broadcom/afbrs50/AFBRS50.hpp @@ -228,14 +228,14 @@ private: uint32_t _measurement_inverval {1000000 / 50}; // 50Hz DEFINE_PARAMETERS( - (ParamInt) _p_sens_afbr_mode, - (ParamInt) _p_sens_afbr_rate, - (ParamInt) _p_sens_afbr_dfm, - (ParamInt) _p_sens_afbr_snm, - (ParamInt) _p_sens_afbr_rot, - (ParamInt) _p_sens_afbr_prof, - (ParamInt) _p_sens_afbr_qmin, - (ParamFloat) _p_sens_afbr_ofs_lo, - (ParamFloat) _p_sens_afbr_ofs_hi + (ParamInt) _param_sens_afbr_mode, + (ParamInt) _param_sens_afbr_rate, + (ParamInt) _param_sens_afbr_dfm, + (ParamInt) _param_sens_afbr_snm, + (ParamInt) _param_sens_afbr_rot, + (ParamInt) _param_sens_afbr_prof, + (ParamInt) _param_sens_afbr_qmin, + (ParamFloat) _param_sens_afbr_ofs_lo, + (ParamFloat) _param_sens_afbr_ofs_hi ); }; diff --git a/src/drivers/distance_sensor/broadcom/afbrs50/AFBRS50_Calibration.cpp b/src/drivers/distance_sensor/broadcom/afbrs50/AFBRS50_Calibration.cpp index 3ac86734793..84594b3eef2 100644 --- a/src/drivers/distance_sensor/broadcom/afbrs50/AFBRS50_Calibration.cpp +++ b/src/drivers/distance_sensor/broadcom/afbrs50/AFBRS50_Calibration.cpp @@ -174,8 +174,8 @@ void AFBRS50::runCalibration() // params so the CONFIGURE state re-applies them on the next boot. Argus_GetCalibrationGlobalRangeOffsets(_hnd, &_cal_offset_low, &_cal_offset_high); - _p_sens_afbr_ofs_lo.commit_no_notification((float)_cal_offset_low / 32768.f); - _p_sens_afbr_ofs_hi.commit_no_notification((float)_cal_offset_high / 32768.f); + _param_sens_afbr_ofs_lo.commit_no_notification((float)_cal_offset_low / 32768.f); + _param_sens_afbr_ofs_hi.commit_no_notification((float)_cal_offset_high / 32768.f); _cal_state = CalState::DONE; PX4_INFO("calibration done, offsets persisted: low=%.4f m high=%.4f m", @@ -224,7 +224,7 @@ void AFBRS50::printCalInfo() PX4_INFO_RAW(" offset_low: %.4f m\n", (double)((float)_cal_offset_low / 32768.f)); PX4_INFO_RAW(" offset_high: %.4f m\n", (double)((float)_cal_offset_high / 32768.f)); PX4_INFO_RAW(" stored (params, applied at boot): low=%.4f m high=%.4f m\n", - (double)_p_sens_afbr_ofs_lo.get(), (double)_p_sens_afbr_ofs_hi.get()); + (double)_param_sens_afbr_ofs_lo.get(), (double)_param_sens_afbr_ofs_hi.get()); } int AFBRS50::calibrationCommand(int argc, char *argv[]) diff --git a/src/drivers/distance_sensor/cm8jl65/CM8JL65.cpp b/src/drivers/distance_sensor/cm8jl65/CM8JL65.cpp index 89f71ee1c0b..c896efa5956 100644 --- a/src/drivers/distance_sensor/cm8jl65/CM8JL65.cpp +++ b/src/drivers/distance_sensor/cm8jl65/CM8JL65.cpp @@ -283,7 +283,7 @@ int CM8JL65::open_serial_port(const speed_t speed) { // File descriptor initialized? - if (_file_descriptor > 0) { + if (_file_descriptor >= 0) { // PX4_INFO("serial port already open"); return PX4_OK; } @@ -315,7 +315,7 @@ CM8JL65::open_serial_port(const speed_t speed) if (termios_state < 0) { PX4_ERR("CFG: %d ISPD", termios_state); - ::close(_file_descriptor); + close_serial_port(); return PX4_ERROR; } @@ -324,7 +324,7 @@ CM8JL65::open_serial_port(const speed_t speed) if (termios_state < 0) { PX4_ERR("CFG: %d OSPD", termios_state); - ::close(_file_descriptor); + close_serial_port(); return PX4_ERROR; } @@ -333,7 +333,7 @@ CM8JL65::open_serial_port(const speed_t speed) if (termios_state < 0) { PX4_ERR("baud %d ATTR", termios_state); - ::close(_file_descriptor); + close_serial_port(); return PX4_ERROR; } @@ -351,6 +351,13 @@ CM8JL65::print_info() void CM8JL65::Run() { + if (_stop_requested.load()) { + ScheduleClear(); + close_serial_port(); + _stopped.store(true); + return; + } + // Ensure the serial port is open. open_serial_port(); @@ -361,6 +368,9 @@ CM8JL65::Run() void CM8JL65::start() { + _stop_requested.store(false); + _stopped.store(false); + // Schedule the driver at regular intervals. ScheduleOnInterval(CM8JL65_MEASURE_INTERVAL); @@ -370,9 +380,24 @@ CM8JL65::start() void CM8JL65::stop() { - // Clear the work queue schedule. - ScheduleClear(); + // The serial port is opened in Run() on the work queue. File descriptors are + // per task group on NuttX, so it must also be closed there and not from the + // shell calling stop. Let Run() close it and wait until it has. + _stop_requested.store(true); + ScheduleNow(); - // Ensure the serial port is closed. - ::close(_file_descriptor); + for (int i = 0; i < 100 && !_stopped.load(); i++) { + px4_usleep(10000); + } + + ScheduleClear(); +} + +void +CM8JL65::close_serial_port() +{ + if (_file_descriptor >= 0) { + ::close(_file_descriptor); + _file_descriptor = -1; + } } diff --git a/src/drivers/distance_sensor/cm8jl65/CM8JL65.hpp b/src/drivers/distance_sensor/cm8jl65/CM8JL65.hpp index aa12c3d1406..1e5be87e82d 100644 --- a/src/drivers/distance_sensor/cm8jl65/CM8JL65.hpp +++ b/src/drivers/distance_sensor/cm8jl65/CM8JL65.hpp @@ -49,6 +49,8 @@ #include #include #include +#include +#include #include @@ -146,6 +148,11 @@ private: */ void stop(); + /** + * Closes the serial port, must be called from the thread that opened it. + */ + void close_serial_port(); + PX4Rangefinder _px4_rangefinder; @@ -155,6 +162,9 @@ private: int _file_descriptor{-1}; + px4::atomic_bool _stop_requested{false}; + px4::atomic_bool _stopped{false}; + uint8_t _linebuf[25] {}; uint16_t _crc16{0}; diff --git a/src/drivers/distance_sensor/leddar_one/LeddarOne.cpp b/src/drivers/distance_sensor/leddar_one/LeddarOne.cpp index 5dd1a58d9d7..e3eb65af935 100644 --- a/src/drivers/distance_sensor/leddar_one/LeddarOne.cpp +++ b/src/drivers/distance_sensor/leddar_one/LeddarOne.cpp @@ -168,7 +168,7 @@ LeddarOne::init() if (collect() == PX4_OK) { // The file descriptor can only be accessed by the process that opened it, // so closing here allows the port to be opened from scheduled work queue. - stop(); + close_serial_port(); return PX4_OK; } } @@ -178,6 +178,7 @@ LeddarOne::init() } PX4_ERR("No readings from LeddarOne"); + close_serial_port(); return PX4_ERROR; } @@ -203,7 +204,7 @@ int LeddarOne::open_serial_port(const speed_t speed) { // File descriptor already initialized? - if (_file_descriptor > 0) { + if (_file_descriptor >= 0) { // PX4_INFO("serial port already open"); return PX4_OK; } @@ -224,8 +225,7 @@ LeddarOne::open_serial_port(const speed_t speed) // Store the current port configuration. attributes. if (tcgetattr(_file_descriptor, &uart_config)) { PX4_ERR("Unable to get termios from %s.", _serial_port); - ::close(_file_descriptor); - _file_descriptor = -1; + close_serial_port(); return PX4_ERROR; } @@ -246,7 +246,7 @@ LeddarOne::open_serial_port(const speed_t speed) if (termios_state < 0) { PX4_ERR("CFG: %d ISPD", termios_state); - ::close(_file_descriptor); + close_serial_port(); return PX4_ERROR; } @@ -255,7 +255,7 @@ LeddarOne::open_serial_port(const speed_t speed) if (termios_state < 0) { PX4_ERR("CFG: %d OSPD", termios_state); - ::close(_file_descriptor); + close_serial_port(); return PX4_ERROR; } @@ -264,7 +264,7 @@ LeddarOne::open_serial_port(const speed_t speed) if (termios_state < 0) { PX4_ERR("baud %d ATTR", termios_state); - ::close(_file_descriptor); + close_serial_port(); return PX4_ERROR; } @@ -286,6 +286,13 @@ LeddarOne::print_info() void LeddarOne::Run() { + if (_stop_requested.load()) { + ScheduleClear(); + close_serial_port(); + _stopped.store(true); + return; + } + // Ensure the serial port is open. open_serial_port(); @@ -295,6 +302,9 @@ LeddarOne::Run() void LeddarOne::start() { + _stop_requested.store(false); + _stopped.store(false); + // Schedule the driver at regular intervals. ScheduleOnInterval(LEDDAR_ONE_MEASURE_INTERVAL, LEDDAR_ONE_MEASURE_INTERVAL); } @@ -302,10 +312,24 @@ LeddarOne::start() void LeddarOne::stop() { - // Ensure the serial port is closed. - ::close(_file_descriptor); - _file_descriptor = -1; + // The serial port is opened in Run() on the work queue. File descriptors are + // per task group on NuttX, so it must also be closed there and not from the + // shell calling stop. Let Run() close it and wait until it has. + _stop_requested.store(true); + ScheduleNow(); + + for (int i = 0; i < 100 && !_stopped.load(); i++) { + px4_usleep(10000); + } - // Clear the work queue schedule. ScheduleClear(); } + +void +LeddarOne::close_serial_port() +{ + if (_file_descriptor >= 0) { + ::close(_file_descriptor); + _file_descriptor = -1; + } +} diff --git a/src/drivers/distance_sensor/leddar_one/LeddarOne.hpp b/src/drivers/distance_sensor/leddar_one/LeddarOne.hpp index d1841a369ab..f3f5690af46 100644 --- a/src/drivers/distance_sensor/leddar_one/LeddarOne.hpp +++ b/src/drivers/distance_sensor/leddar_one/LeddarOne.hpp @@ -39,6 +39,8 @@ #include #include #include +#include +#include #include #include @@ -117,6 +119,11 @@ public: */ void stop(); + /** + * Closes the serial port, must be called from the thread that opened it. + */ + void close_serial_port(); + private: /** @@ -150,6 +157,9 @@ private: int _file_descriptor{-1}; + px4::atomic_bool _stop_requested{false}; + px4::atomic_bool _stopped{false}; + uint8_t _buffer[sizeof(reading_msg)]; uint8_t _buffer_len{0}; diff --git a/src/drivers/distance_sensor/lightware_laser_serial/lightware_laser_serial.cpp b/src/drivers/distance_sensor/lightware_laser_serial/lightware_laser_serial.cpp index 7bba405adb5..52bf0e6e054 100644 --- a/src/drivers/distance_sensor/lightware_laser_serial/lightware_laser_serial.cpp +++ b/src/drivers/distance_sensor/lightware_laser_serial/lightware_laser_serial.cpp @@ -250,6 +250,8 @@ void LightwareLaserSerial::start() { /* reset the report ring and state machine */ _collect_phase = false; + _stop_requested.store(false); + _stopped.store(false); /* schedule a cycle to start things */ ScheduleNow(); @@ -257,12 +259,28 @@ void LightwareLaserSerial::start() void LightwareLaserSerial::stop() { + // The serial port is opened in Run() on the work queue. File descriptors are + // per task group on NuttX, so it must also be closed there and not from the + // shell calling stop. Let Run() close it and wait until it has. + _stop_requested.store(true); + ScheduleNow(); + + for (int i = 0; i < 100 && !_stopped.load(); i++) { + px4_usleep(10000); + } + ScheduleClear(); - _uart.close(); } void LightwareLaserSerial::Run() { + if (_stop_requested.load()) { + ScheduleClear(); + _uart.close(); + _stopped.store(true); + return; + } + if (!_uart.isOpen()) { if (!_uart.setPort(_port)) { PX4_ERR("failed to configure port %s", _port); diff --git a/src/drivers/distance_sensor/lightware_laser_serial/lightware_laser_serial.hpp b/src/drivers/distance_sensor/lightware_laser_serial/lightware_laser_serial.hpp index 513ab7e98c0..dcb4b1a23ec 100644 --- a/src/drivers/distance_sensor/lightware_laser_serial/lightware_laser_serial.hpp +++ b/src/drivers/distance_sensor/lightware_laser_serial/lightware_laser_serial.hpp @@ -42,6 +42,8 @@ #pragma once #include +#include +#include #include #include #include @@ -72,6 +74,9 @@ private: PX4Rangefinder _px4_rangefinder; device::Serial _uart; + px4::atomic_bool _stop_requested{false}; + px4::atomic_bool _stopped{false}; + char _port[20] {}; int _interval{100000}; bool _collect_phase{false}; diff --git a/src/drivers/distance_sensor/mappydot/MappyDot.cpp b/src/drivers/distance_sensor/mappydot/MappyDot.cpp index c04e95cb670..a3fb1d631e1 100644 --- a/src/drivers/distance_sensor/mappydot/MappyDot.cpp +++ b/src/drivers/distance_sensor/mappydot/MappyDot.cpp @@ -202,19 +202,19 @@ private: perf_counter_t _sample_perf{perf_alloc(PC_ELAPSED, "mappydot_sample_perf")}; DEFINE_PARAMETERS( - (ParamInt) _p_sensor_enabled, - (ParamInt) _p_sensor0_rot, - (ParamInt) _p_sensor1_rot, - (ParamInt) _p_sensor2_rot, - (ParamInt) _p_sensor3_rot, - (ParamInt) _p_sensor4_rot, - (ParamInt) _p_sensor5_rot, - (ParamInt) _p_sensor6_rot, - (ParamInt) _p_sensor7_rot, - (ParamInt) _p_sensor8_rot, - (ParamInt) _p_sensor9_rot, - (ParamInt) _p_sensor10_rot, - (ParamInt) _p_sensor11_rot + (ParamInt) _param_sens_en_mpdt, + (ParamInt) _param_sens_mpdt0_rot, + (ParamInt) _param_sens_mpdt1_rot, + (ParamInt) _param_sens_mpdt2_rot, + (ParamInt) _param_sens_mpdt3_rot, + (ParamInt) _param_sens_mpdt4_rot, + (ParamInt) _param_sens_mpdt5_rot, + (ParamInt) _param_sens_mpdt6_rot, + (ParamInt) _param_sens_mpdt7_rot, + (ParamInt) _param_sens_mpdt8_rot, + (ParamInt) _param_sens_mpdt9_rot, + (ParamInt) _param_sens_mpdt10_rot, + (ParamInt) _param_sens_mpdt11_rot ); }; @@ -287,29 +287,29 @@ int MappyDot::get_sensor_rotation(const size_t index) { switch (index) { - case 0: return _p_sensor0_rot.get(); + case 0: return _param_sens_mpdt0_rot.get(); - case 1: return _p_sensor1_rot.get(); + case 1: return _param_sens_mpdt1_rot.get(); - case 2: return _p_sensor2_rot.get(); + case 2: return _param_sens_mpdt2_rot.get(); - case 3: return _p_sensor3_rot.get(); + case 3: return _param_sens_mpdt3_rot.get(); - case 4: return _p_sensor4_rot.get(); + case 4: return _param_sens_mpdt4_rot.get(); - case 5: return _p_sensor5_rot.get(); + case 5: return _param_sens_mpdt5_rot.get(); - case 6: return _p_sensor6_rot.get(); + case 6: return _param_sens_mpdt6_rot.get(); - case 7: return _p_sensor7_rot.get(); + case 7: return _param_sens_mpdt7_rot.get(); - case 8: return _p_sensor8_rot.get(); + case 8: return _param_sens_mpdt8_rot.get(); - case 9: return _p_sensor9_rot.get(); + case 9: return _param_sens_mpdt9_rot.get(); - case 10: return _p_sensor10_rot.get(); + case 10: return _param_sens_mpdt10_rot.get(); - case 11: return _p_sensor11_rot.get(); + case 11: return _param_sens_mpdt11_rot.get(); default: return PX4_ERROR; } @@ -318,7 +318,7 @@ MappyDot::get_sensor_rotation(const size_t index) int MappyDot::init() { - if (_p_sensor_enabled.get() == 0) { + if (_param_sens_en_mpdt.get() == 0) { PX4_WARN("disabled"); return PX4_ERROR; } diff --git a/src/drivers/distance_sensor/mb12xx/mb12xx.cpp b/src/drivers/distance_sensor/mb12xx/mb12xx.cpp index 1785c22d2aa..8d0f12bacbe 100644 --- a/src/drivers/distance_sensor/mb12xx/mb12xx.cpp +++ b/src/drivers/distance_sensor/mb12xx/mb12xx.cpp @@ -157,19 +157,19 @@ private: perf_counter_t _sample_perf{perf_alloc(PC_COUNT, "mb12xx_sample_perf")}; DEFINE_PARAMETERS( - (ParamInt) _p_sensor_enabled, - (ParamInt) _p_sensor0_rot, - (ParamInt) _p_sensor1_rot, - (ParamInt) _p_sensor2_rot, - (ParamInt) _p_sensor3_rot, - (ParamInt) _p_sensor4_rot, - (ParamInt) _p_sensor5_rot, - (ParamInt) _p_sensor6_rot, - (ParamInt) _p_sensor7_rot, - (ParamInt) _p_sensor8_rot, - (ParamInt) _p_sensor9_rot, - (ParamInt) _p_sensor10_rot, - (ParamInt) _p_sensor11_rot + (ParamInt) _param_sens_en_mb12xx, + (ParamInt) _param_sens_mb12_0_rot, + (ParamInt) _param_sens_mb12_1_rot, + (ParamInt) _param_sens_mb12_2_rot, + (ParamInt) _param_sens_mb12_3_rot, + (ParamInt) _param_sens_mb12_4_rot, + (ParamInt) _param_sens_mb12_5_rot, + (ParamInt) _param_sens_mb12_6_rot, + (ParamInt) _param_sens_mb12_7_rot, + (ParamInt) _param_sens_mb12_8_rot, + (ParamInt) _param_sens_mb12_9_rot, + (ParamInt) _param_sens_mb12_10_rot, + (ParamInt) _param_sens_mb12_11_rot ); }; @@ -249,29 +249,29 @@ int MB12XX::get_sensor_rotation(const size_t index) { switch (index) { - case 0: return _p_sensor0_rot.get(); + case 0: return _param_sens_mb12_0_rot.get(); - case 1: return _p_sensor1_rot.get(); + case 1: return _param_sens_mb12_1_rot.get(); - case 2: return _p_sensor2_rot.get(); + case 2: return _param_sens_mb12_2_rot.get(); - case 3: return _p_sensor3_rot.get(); + case 3: return _param_sens_mb12_3_rot.get(); - case 4: return _p_sensor4_rot.get(); + case 4: return _param_sens_mb12_4_rot.get(); - case 5: return _p_sensor5_rot.get(); + case 5: return _param_sens_mb12_5_rot.get(); - case 6: return _p_sensor6_rot.get(); + case 6: return _param_sens_mb12_6_rot.get(); - case 7: return _p_sensor7_rot.get(); + case 7: return _param_sens_mb12_7_rot.get(); - case 8: return _p_sensor8_rot.get(); + case 8: return _param_sens_mb12_8_rot.get(); - case 9: return _p_sensor9_rot.get(); + case 9: return _param_sens_mb12_9_rot.get(); - case 10: return _p_sensor10_rot.get(); + case 10: return _param_sens_mb12_10_rot.get(); - case 11: return _p_sensor11_rot.get(); + case 11: return _param_sens_mb12_11_rot.get(); default: return PX4_ERROR; } @@ -280,7 +280,7 @@ MB12XX::get_sensor_rotation(const size_t index) int MB12XX::init() { - if (_p_sensor_enabled.get() == 0) { + if (_param_sens_en_mb12xx.get() == 0) { PX4_WARN("disabled"); return PX4_ERROR; } diff --git a/src/drivers/distance_sensor/sony/sony_asdt1.cpp b/src/drivers/distance_sensor/sony/sony_asdt1.cpp index b0299c663e6..f0e867b5464 100644 --- a/src/drivers/distance_sensor/sony/sony_asdt1.cpp +++ b/src/drivers/distance_sensor/sony/sony_asdt1.cpp @@ -139,6 +139,9 @@ int AS_DT1::init() PX4_WARN("flshow: no complete response after %u tries", static_cast(FLSHOW_RETRY_LIMIT)); } + // Opened in the shell task, so close it here as well. + close_port(); + } else { start(); } @@ -226,18 +229,36 @@ void AS_DT1::print_info() void AS_DT1::start() { + _stop_requested.store(false); + _stopped.store(false); _current_baud = ASDT1_DESIRED_BAUD; ScheduleNow(); } void AS_DT1::stop() { + // The serial port is opened in Run() on the work queue. File descriptors are + // per task group on NuttX, so it must also be closed there and not from the + // shell calling stop. Let Run() close it and wait until it has. + _stop_requested.store(true); + ScheduleNow(); + + for (int i = 0; i < 100 && !_stopped.load(); i++) { + px4_usleep(10000); + } + ScheduleClear(); - close_port(); } void AS_DT1::Run() { + if (_stop_requested.load()) { + ScheduleClear(); + close_port(); + _stopped.store(true); + return; + } + if (_fd < 0) { if (open_port() != PX4_OK) { return; diff --git a/src/drivers/distance_sensor/sony/sony_asdt1.hpp b/src/drivers/distance_sensor/sony/sony_asdt1.hpp index e1195e6a022..4559dab8125 100644 --- a/src/drivers/distance_sensor/sony/sony_asdt1.hpp +++ b/src/drivers/distance_sensor/sony/sony_asdt1.hpp @@ -41,6 +41,8 @@ #include #include +#include +#include #include #include #include @@ -169,6 +171,9 @@ private: uORB::Publication _obstacle_distance_pub{ORB_ID(obstacle_distance)}; int _fd{-1}; + + px4::atomic_bool _stop_requested{false}; + px4::atomic_bool _stopped{false}; int _read_interval_us{2000}; char _device[20] {}; bool _print_config_only{false}; diff --git a/src/drivers/distance_sensor/ulanding_radar/AerotennaULanding.cpp b/src/drivers/distance_sensor/ulanding_radar/AerotennaULanding.cpp index ffd2c81a7ab..28b36269a3c 100644 --- a/src/drivers/distance_sensor/ulanding_radar/AerotennaULanding.cpp +++ b/src/drivers/distance_sensor/ulanding_radar/AerotennaULanding.cpp @@ -146,7 +146,7 @@ int AerotennaULanding::collect() int AerotennaULanding::open_serial_port(const speed_t speed) { // File descriptor initialized? - if (_file_descriptor > 0) { + if (_file_descriptor >= 0) { PX4_DEBUG("serial port already open"); return PX4_OK; } @@ -164,6 +164,7 @@ int AerotennaULanding::open_serial_port(const speed_t speed) if (!isatty(_file_descriptor)) { PX4_WARN("not a serial device"); + close_serial_port(); return PX4_ERROR; } @@ -188,7 +189,7 @@ int AerotennaULanding::open_serial_port(const speed_t speed) if (termios_state < 0) { PX4_ERR("CFG: %d ISPD", termios_state); - ::close(_file_descriptor); + close_serial_port(); return PX4_ERROR; } @@ -197,7 +198,7 @@ int AerotennaULanding::open_serial_port(const speed_t speed) if (termios_state < 0) { PX4_ERR("CFG: %d OSPD", termios_state); - ::close(_file_descriptor); + close_serial_port(); return PX4_ERROR; } @@ -206,7 +207,7 @@ int AerotennaULanding::open_serial_port(const speed_t speed) if (termios_state < 0) { PX4_ERR("baud %d ATTR", termios_state); - ::close(_file_descriptor); + close_serial_port(); return PX4_ERROR; } @@ -216,6 +217,13 @@ int AerotennaULanding::open_serial_port(const speed_t speed) void AerotennaULanding::Run() { + if (_stop_requested.load()) { + ScheduleClear(); + close_serial_port(); + _stopped.store(true); + return; + } + // Ensure the serial port is open. open_serial_port(); @@ -224,19 +232,36 @@ void AerotennaULanding::Run() void AerotennaULanding::start() { + _stop_requested.store(false); + _stopped.store(false); + // Schedule the driver at regular intervals. ScheduleOnInterval(ULANDING_MEASURE_INTERVAL, 0); } void AerotennaULanding::stop() { - // Ensure the serial port is closed. - ::close(_file_descriptor); + // The serial port is opened in Run() on the work queue. File descriptors are + // per task group on NuttX, so it must also be closed there and not from the + // shell calling stop. Let Run() close it and wait until it has. + _stop_requested.store(true); + ScheduleNow(); + + for (int i = 0; i < 100 && !_stopped.load(); i++) { + px4_usleep(10000); + } - // Clear the work queue schedule. ScheduleClear(); } +void AerotennaULanding::close_serial_port() +{ + if (_file_descriptor >= 0) { + ::close(_file_descriptor); + _file_descriptor = -1; + } +} + void AerotennaULanding::print_info() { perf_print_counter(_sample_perf); diff --git a/src/drivers/distance_sensor/ulanding_radar/AerotennaULanding.hpp b/src/drivers/distance_sensor/ulanding_radar/AerotennaULanding.hpp index 98d1c0ab904..e25bdd837cc 100644 --- a/src/drivers/distance_sensor/ulanding_radar/AerotennaULanding.hpp +++ b/src/drivers/distance_sensor/ulanding_radar/AerotennaULanding.hpp @@ -50,6 +50,8 @@ #include #include #include +#include +#include #include #include #include @@ -107,12 +109,20 @@ private: void start(); void stop(); + /** + * Closes the serial port, must be called from the thread that opened it. + */ + void close_serial_port(); + PX4Rangefinder _px4_rangefinder; char _port[20] {}; int _file_descriptor{-1}; + px4::atomic_bool _stop_requested{false}; + px4::atomic_bool _stopped{false}; + uint8_t _buffer[ULANDING_BUFFER_LENGTH] {}; perf_counter_t _comms_errors{perf_alloc(PC_COUNT, MODULE_NAME": com_err")}; diff --git a/src/drivers/heater/heater.cpp b/src/drivers/heater/heater.cpp index c5fcab43896..614c8b1531f 100644 --- a/src/drivers/heater/heater.cpp +++ b/src/drivers/heater/heater.cpp @@ -107,8 +107,6 @@ Heater::Heater(uint8_t instance) : ModuleParams(nullptr), _instance(instance) { - initialize_heater_io(); - char name[32]; // Dynamically locate the parameter handle corresponding to the current instance @@ -366,6 +364,9 @@ bool Heater::initialize_topics() (unsigned)_instance, use_hygro ? "hygrometer" : "accel", selected_instance, (unsigned long)_sensor_device_id); + // Called from Run(), so the PX4IO fd is opened on the work queue thread. + initialize_heater_io(); + return true; } @@ -374,18 +375,22 @@ bool Heater::initialize_topics() void Heater::Run() { if (_should_exit) { -#if defined(HEATER_PX4IO) - - // must be closed from wq thread - if (_io_fd >= 0) { - px4_close(_io_fd); - } - -#endif ScheduleClear(); // Ensure heating is turned off (avoid leaving it in the ON position). heater_off(); + disable_heater(); + +#if defined(HEATER_PX4IO) + + // File descriptors are per task group, so the PX4IO fd is only valid + // on the work queue thread: open, use and close it only from here. + if (_io_fd >= 0) { + px4_close(_io_fd); + _io_fd = -1; + } + +#endif delete Heater::g_heater[_instance - 1]; Heater::g_heater[_instance - 1] = nullptr; @@ -573,8 +578,9 @@ int Heater::start() void Heater::stop() { + // Turning the heater off is done in Run() on the work queue thread, + // which owns the PX4IO file descriptor. _should_exit = true; - heater_off(); ScheduleNow(); } diff --git a/src/drivers/imu/murata/sch16t/SCH16T.cpp b/src/drivers/imu/murata/sch16t/SCH16T.cpp index 5a57033ddc0..51d50abc8e2 100644 --- a/src/drivers/imu/murata/sch16t/SCH16T.cpp +++ b/src/drivers/imu/murata/sch16t/SCH16T.cpp @@ -412,7 +412,7 @@ void SCH16T::ConfigurationFromParameters() _px4_accel.set_scale(1.f / 3200.f); // 3200 LSB/(m/s2) // Gyro filter - switch (_sch16t_gyro_filt.get()) { + switch (_param_sch16t_gyro_filt.get()) { case 0: filt_rate.bits.FILT_SEL_RATE_X = FILTER_13_HZ; filt_rate.bits.FILT_SEL_RATE_Y = FILTER_13_HZ; @@ -457,7 +457,7 @@ void SCH16T::ConfigurationFromParameters() } // ACC12 / ACC3 filter - switch (_sch16t_acc_filt.get()) { + switch (_param_sch16t_acc_filt.get()) { case 0: filt_acc12.bits.FILT_SEL_ACC_X12 = FILTER_13_HZ; filt_acc12.bits.FILT_SEL_ACC_Y12 = FILTER_13_HZ; @@ -530,7 +530,7 @@ void SCH16T::ConfigurationFromParameters() } // Gyro decimation (only affects channel 2, ie RATE2) - switch (_sch16t_decim.get()) { + switch (_param_sch16t_decim.get()) { case 0: _sample_interval_us = 85; rate_ctrl.bits.DEC_RATE_X2 = DECIMATION_NONE; diff --git a/src/drivers/imu/murata/sch16t/SCH16T.hpp b/src/drivers/imu/murata/sch16t/SCH16T.hpp index 0e51f4dc40b..ea48e0aeaeb 100644 --- a/src/drivers/imu/murata/sch16t/SCH16T.hpp +++ b/src/drivers/imu/murata/sch16t/SCH16T.hpp @@ -154,8 +154,8 @@ private: perf_counter_t _perf_doing_initialization{perf_counter_t(perf_alloc(PC_COUNT, MODULE_NAME": re-initializing"))}; DEFINE_PARAMETERS( - (ParamInt) _sch16t_gyro_filt, - (ParamInt) _sch16t_acc_filt, - (ParamInt) _sch16t_decim + (ParamInt) _param_sch16t_gyro_filt, + (ParamInt) _param_sch16t_acc_filt, + (ParamInt) _param_sch16t_decim ) }; diff --git a/src/drivers/ins/microstrain/MicroStrain.cpp b/src/drivers/ins/microstrain/MicroStrain.cpp index 5fa99be5569..048e0b8cd73 100755 --- a/src/drivers/ins/microstrain/MicroStrain.cpp +++ b/src/drivers/ins/microstrain/MicroStrain.cpp @@ -58,7 +58,7 @@ MicroStrain::MicroStrain(const char *uart_port) : // The scheduling rate (in microseconds) is set higher than the highest data rate param (in Hz) const int max_param_rate = math::max(math::max(_param_ms_imu_rate_hz.get(), _param_ms_mag_rate_hz.get(), - _param_ms_baro_rate_hz.get()), _param_ms_filter_rate_hz.get()); + _param_ms_baro_rate_hz.get()), _param_ms_filt_rate_hz.get()); // We always want the schedule rate faster than the highest sensor data rate _ms_schedule_rate_us = (1e6) / (2 * max_param_rate); @@ -80,48 +80,48 @@ MicroStrain::MicroStrain(const char *uart_port) : _sensor_baro.temperature = 0; _sensor_baro.error_count = 0; - gnss_antenna_offset1[0] = _param_ms_gnss_offset1_x.get(); - gnss_antenna_offset1[1] = _param_ms_gnss_offset1_y.get(); - gnss_antenna_offset1[2] = _param_ms_gnss_offset1_z.get(); - PX4_DEBUG("GNSS antenna offset 1: %f/%f/%f", (double)_param_ms_gnss_offset1_x.get(), - (double)_param_ms_gnss_offset1_y.get(), - (double)_param_ms_gnss_offset1_z.get()); + gnss_antenna_offset1[0] = _param_ms_gnss_off1_x.get(); + gnss_antenna_offset1[1] = _param_ms_gnss_off1_y.get(); + gnss_antenna_offset1[2] = _param_ms_gnss_off1_z.get(); + PX4_DEBUG("GNSS antenna offset 1: %f/%f/%f", (double)_param_ms_gnss_off1_x.get(), + (double)_param_ms_gnss_off1_y.get(), + (double)_param_ms_gnss_off1_z.get()); - gnss_antenna_offset2[0] = _param_ms_gnss_offset2_x.get(); - gnss_antenna_offset2[1] = _param_ms_gnss_offset2_y.get(); - gnss_antenna_offset2[2] = _param_ms_gnss_offset2_z.get(); - PX4_DEBUG("GNSS antenna offset 2: %f/%f/%f", (double)_param_ms_gnss_offset2_x.get(), - (double)_param_ms_gnss_offset2_y.get(), - (double)_param_ms_gnss_offset2_z.get()); + gnss_antenna_offset2[0] = _param_ms_gnss_off2_x.get(); + gnss_antenna_offset2[1] = _param_ms_gnss_off2_y.get(); + gnss_antenna_offset2[2] = _param_ms_gnss_off2_z.get(); + PX4_DEBUG("GNSS antenna offset 2: %f/%f/%f", (double)_param_ms_gnss_off2_x.get(), + (double)_param_ms_gnss_off2_y.get(), + (double)_param_ms_gnss_off2_z.get()); - optical_flow_offset[0] = _param_ms_oflow_offset_x.get(); - optical_flow_offset[1] = _param_ms_oflow_offset_y.get(); - optical_flow_offset[2] = _param_ms_oflow_offset_z.get(); - PX4_DEBUG("Optical flow offset: %f/%f/%f", (double)_param_ms_oflow_offset_x.get(), - (double)_param_ms_oflow_offset_y.get(), - (double)_param_ms_oflow_offset_z.get()); + optical_flow_offset[0] = _param_ms_oflw_off_x.get(); + optical_flow_offset[1] = _param_ms_oflw_off_y.get(); + optical_flow_offset[2] = _param_ms_oflw_off_z.get(); + PX4_DEBUG("Optical flow offset: %f/%f/%f", (double)_param_ms_oflw_off_x.get(), + (double)_param_ms_oflw_off_y.get(), + (double)_param_ms_oflw_off_z.get()); rotation_sens.euler[0] = _param_ms_sensor_roll.get(); - rotation_sens.euler[1] = _param_ms_sensor_pitch.get(); + rotation_sens.euler[1] = _param_ms_sensor_ptch.get(); rotation_sens.euler[2] = _param_ms_sensor_yaw.get(); PX4_DEBUG("Device Roll/Pitch/Yaw: %f/%f/%f", (double)_param_ms_sensor_roll.get(), - (double)_param_ms_sensor_pitch.get(), + (double)_param_ms_sensor_ptch.get(), (double)_param_ms_sensor_yaw.get()); rotation_ext_mag.euler[0] = _param_ms_emag_roll.get(); - rotation_ext_mag.euler[1] = _param_ms_emag_pitch.get(); + rotation_ext_mag.euler[1] = _param_ms_emag_ptch.get(); rotation_ext_mag.euler[2] = _param_ms_emag_yaw.get(); PX4_DEBUG("External magnetometer Roll/Pitch/Yaw: %f/%f/%f", (double)_param_ms_emag_roll.get(), - (double)_param_ms_emag_pitch.get(), + (double)_param_ms_emag_ptch.get(), (double)_param_ms_emag_yaw.get()); rotation_ext_heading.euler[2] = _param_ms_ehead_yaw.get(); PX4_DEBUG("External heading yaw: %f", (double)_param_ms_ehead_yaw.get()); ext_mag_uncert = _param_ms_emag_uncert.get(); - opt_flow_uncert = _param_ms_oflow_uncert.get(); + opt_flow_uncert = _param_ms_oflw_uncert.get(); PX4_DEBUG("External Mag Uncertainty: %f", (double)_param_ms_emag_uncert.get()); - PX4_DEBUG("Optical Flow Uncertainty: %f", (double)_param_ms_oflow_uncert.get()); + PX4_DEBUG("Optical Flow Uncertainty: %f", (double)_param_ms_oflw_uncert.get()); _sensor_baro_pub.advertise(); _sensor_selection_pub.advertise(); @@ -349,9 +349,9 @@ mip_cmd_result MicroStrain::configureImuRange() mip_cmd_result res = MIP_ACK_OK; // Checks if the accel range is to be configured - if (_param_ms_accel_range_setting.get() != -1) { + if (_param_ms_accel_range.get() != -1) { if (supportsDescriptor(MIP_3DM_CMD_DESC_SET, MIP_CMD_DESC_3DM_SENSOR_RANGE)) { - res = mip_3dm_write_sensor_range(&_device, MIP_SENSOR_RANGE_TYPE_ACCEL, _param_ms_accel_range_setting.get()); + res = mip_3dm_write_sensor_range(&_device, MIP_SENSOR_RANGE_TYPE_ACCEL, _param_ms_accel_range.get()); } else { PX4_ERR("Accel sensor range write command is not supported"); @@ -364,9 +364,9 @@ mip_cmd_result MicroStrain::configureImuRange() } // Checks if the gyro range is to be configured - if (_param_ms_gyro_range_setting.get() != -1) { + if (_param_ms_gyro_range.get() != -1) { if (supportsDescriptor(MIP_3DM_CMD_DESC_SET, MIP_CMD_DESC_3DM_SENSOR_RANGE)) { - res = mip_3dm_write_sensor_range(&_device, MIP_SENSOR_RANGE_TYPE_GYRO, _param_ms_gyro_range_setting.get()); + res = mip_3dm_write_sensor_range(&_device, MIP_SENSOR_RANGE_TYPE_GYRO, _param_ms_gyro_range.get()); } else { PX4_ERR("Gyro sensor range write command is not supported"); @@ -544,7 +544,7 @@ mip_cmd_result MicroStrain::configureImuMessageFormat() } if (supportsDescriptor(MIP_SENSOR_DATA_DESC_SET, MIP_DATA_DESC_SHARED_GPS_TIME) - && _param_ms_filter_rate_hz.get() > 0) { + && _param_ms_filt_rate_hz.get() > 0) { const int max_param_rate = math::max(_param_ms_imu_rate_hz.get(), _param_ms_mag_rate_hz.get(), _param_ms_baro_rate_hz.get()); uint16_t gps_time_decimation = base_rate / max_param_rate; @@ -580,73 +580,73 @@ mip_cmd_result MicroStrain::configureFilterMessageFormat() // Configure the Message Format depending on if the device supports the descriptor uint16_t filter_decimation = 250; - if (_param_ms_filter_rate_hz.get() != 0) { - filter_decimation = base_rate / (uint16_t)_param_ms_filter_rate_hz.get(); + if (_param_ms_filt_rate_hz.get() != 0) { + filter_decimation = base_rate / (uint16_t)_param_ms_filt_rate_hz.get(); PX4_DEBUG("Filter decimation: %i", filter_decimation); } if (supportsDescriptor(MIP_FILTER_DATA_DESC_SET, MIP_DATA_DESC_FILTER_POS_LLH) - && _param_ms_filter_rate_hz.get() > 0) { + && _param_ms_filt_rate_hz.get() > 0) { filter_descriptors[num_filter_descriptors++] = mip_descriptor_rate { MIP_DATA_DESC_FILTER_POS_LLH, filter_decimation}; PX4_DEBUG("Filter: LLH pos enabled"); } if (supportsDescriptor(MIP_FILTER_DATA_DESC_SET, MIP_DATA_DESC_FILTER_ATT_QUATERNION) - && _param_ms_filter_rate_hz.get() > 0) { + && _param_ms_filt_rate_hz.get() > 0) { filter_descriptors[num_filter_descriptors++] = mip_descriptor_rate { MIP_DATA_DESC_FILTER_ATT_QUATERNION, filter_decimation}; PX4_DEBUG("Filter: Attitude quaternion enabled"); } if (supportsDescriptor(MIP_FILTER_DATA_DESC_SET, MIP_DATA_DESC_FILTER_VEL_NED) - && _param_ms_filter_rate_hz.get() > 0) { + && _param_ms_filt_rate_hz.get() > 0) { filter_descriptors[num_filter_descriptors++] = mip_descriptor_rate { MIP_DATA_DESC_FILTER_VEL_NED, filter_decimation}; PX4_DEBUG("Filter: Velocity NED enabled"); } if (supportsDescriptor(MIP_FILTER_DATA_DESC_SET, MIP_DATA_DESC_FILTER_LINEAR_ACCELERATION) - && _param_ms_filter_rate_hz.get() > 0) { + && _param_ms_filt_rate_hz.get() > 0) { filter_descriptors[num_filter_descriptors++] = mip_descriptor_rate { MIP_DATA_DESC_FILTER_LINEAR_ACCELERATION, filter_decimation}; PX4_DEBUG("Filter: Linear accel FRD enabled"); } if (supportsDescriptor(MIP_FILTER_DATA_DESC_SET, MIP_DATA_DESC_FILTER_POS_UNCERTAINTY) - && _param_ms_filter_rate_hz.get() > 0) { + && _param_ms_filt_rate_hz.get() > 0) { filter_descriptors[num_filter_descriptors++] = mip_descriptor_rate { MIP_DATA_DESC_FILTER_POS_UNCERTAINTY, filter_decimation}; PX4_DEBUG("Filter: Position uncertainty enabled"); } if (supportsDescriptor(MIP_FILTER_DATA_DESC_SET, MIP_DATA_DESC_FILTER_VEL_UNCERTAINTY) - && _param_ms_filter_rate_hz.get() > 0) { + && _param_ms_filt_rate_hz.get() > 0) { filter_descriptors[num_filter_descriptors++] = mip_descriptor_rate { MIP_DATA_DESC_FILTER_VEL_UNCERTAINTY, filter_decimation}; PX4_DEBUG("Filter: Velocity uncertainty enabled"); } if (supportsDescriptor(MIP_FILTER_DATA_DESC_SET, MIP_DATA_DESC_FILTER_ATT_UNCERTAINTY_EULER) - && _param_ms_filter_rate_hz.get() > 0) { + && _param_ms_filt_rate_hz.get() > 0) { filter_descriptors[num_filter_descriptors++] = mip_descriptor_rate { MIP_DATA_DESC_FILTER_ATT_UNCERTAINTY_EULER, filter_decimation}; PX4_DEBUG("Filter: Attitude euler uncertainty enabled"); } if (supportsDescriptor(MIP_FILTER_DATA_DESC_SET, MIP_DATA_DESC_FILTER_COMPENSATED_ANGULAR_RATE) - && _param_ms_filter_rate_hz.get() > 0) { + && _param_ms_filt_rate_hz.get() > 0) { filter_descriptors[num_filter_descriptors++] = mip_descriptor_rate { MIP_DATA_DESC_FILTER_COMPENSATED_ANGULAR_RATE, filter_decimation}; PX4_DEBUG("Filter: Compensated angular rate enabled"); } if (supportsDescriptor(MIP_FILTER_DATA_DESC_SET, MIP_DATA_DESC_FILTER_FILTER_STATUS) - && _param_ms_filter_rate_hz.get() > 0) { + && _param_ms_filt_rate_hz.get() > 0) { filter_descriptors[num_filter_descriptors++] = mip_descriptor_rate { MIP_DATA_DESC_FILTER_FILTER_STATUS, filter_decimation}; PX4_DEBUG("Filter: Status enabled"); } if (supportsDescriptor(MIP_FILTER_DATA_DESC_SET, MIP_DATA_DESC_FILTER_GNSS_DUAL_ANTENNA_STATUS) - && _param_ms_filter_rate_hz.get() > 0) { + && _param_ms_filt_rate_hz.get() > 0) { filter_descriptors[num_filter_descriptors++] = mip_descriptor_rate { MIP_DATA_DESC_FILTER_GNSS_DUAL_ANTENNA_STATUS, filter_decimation}; PX4_DEBUG("Filter: GNSS Dual antenna status enabled"); } if (supportsDescriptor(MIP_FILTER_DATA_DESC_SET, MIP_DATA_DESC_SHARED_GPS_TIME) - && _param_ms_filter_rate_hz.get() > 0) { + && _param_ms_filt_rate_hz.get() > 0) { filter_descriptors[num_filter_descriptors++] = mip_descriptor_rate { MIP_DATA_DESC_SHARED_GPS_TIME, filter_decimation}; PX4_DEBUG("Filter: GPS Time enabled"); } @@ -660,7 +660,7 @@ mip_cmd_result MicroStrain::configureFilterMessageFormat() mip_cmd_result MicroStrain::configureGnssMessageFormat(uint8_t descriptor_set) { - if (_param_ms_gnss_aid_src_ctrl.get() == MIP_FILTER_GNSS_SOURCE_COMMAND_SOURCE_EXT) { + if (_param_ms_gnss_aid_src.get() == MIP_FILTER_GNSS_SOURCE_COMMAND_SOURCE_EXT) { PX4_DEBUG("External GNSS aiding source detected, skipping GNSS message format config"); return MIP_ACK_OK; } @@ -832,7 +832,7 @@ mip_cmd_result MicroStrain::configureGnssAiding() // Sets up the GNSS aiding source if (supportsDescriptor(MIP_FILTER_CMD_DESC_SET, MIP_CMD_DESC_FILTER_GNSS_SOURCE_CONTROL)) { - res = mip_filter_write_gnss_source(&_device, (uint8_t)_param_ms_gnss_aid_src_ctrl.get()); + res = mip_filter_write_gnss_source(&_device, (uint8_t)_param_ms_gnss_aid_src.get()); if (!mip_cmd_result_is_ack(res)) { PX4_ERR("Could not write the gnss aiding source"); @@ -840,7 +840,7 @@ mip_cmd_result MicroStrain::configureGnssAiding() } // Checks if the gnss aiding source is external - if (_param_ms_gnss_aid_src_ctrl.get() == MIP_FILTER_GNSS_SOURCE_COMMAND_SOURCE_EXT) { + if (_param_ms_gnss_aid_src.get() == MIP_FILTER_GNSS_SOURCE_COMMAND_SOURCE_EXT) { _ext_pos_vel_aiding = true; // Sets up the aiding frame for the external source @@ -880,7 +880,7 @@ mip_cmd_result MicroStrain::configureGnssAiding() // Selectively enables dual antenna heading as an aiding measurement res = enableAidingSource(MIP_FILTER_AIDING_MEASUREMENT_ENABLE_COMMAND_AIDING_SOURCE_GNSS_HEADING, - _param_ms_int_heading_en.get(), + _param_ms_int_head_en.get(), 0, 0, nullptr, mip_aiding_frame_config_command_rotation{}, 0, _int_aiding, "dual antenna heading"); @@ -938,7 +938,7 @@ mip_cmd_result MicroStrain::configureAidingSources() // Selectively turn on body frame velocity as an aiding source res = enableAidingSource(MIP_FILTER_AIDING_MEASUREMENT_ENABLE_COMMAND_AIDING_SOURCE_VEHICLE_FRAME_VEL, - _param_ms_ext_opt_flow_en.get(), + _param_ms_opt_flow_en.get(), 3, MIP_AIDING_FRAME_CONFIG_COMMAND_FORMAT_EULER, optical_flow_offset, rotation_oflow, MIP_CMD_DESC_AIDING_VEL_ODOM, @@ -951,7 +951,7 @@ mip_cmd_result MicroStrain::configureAidingSources() // Selectively turn on external heading as an aiding source res = enableAidingSource(MIP_FILTER_AIDING_MEASUREMENT_ENABLE_COMMAND_AIDING_SOURCE_EXTERNAL_HEADING, - _param_ms_ext_heading_en.get(), + _param_ms_ext_head_en.get(), 4, MIP_AIDING_FRAME_CONFIG_COMMAND_FORMAT_EULER, ext_heading_offset, rotation_ext_heading, MIP_CMD_DESC_AIDING_HEADING_TRUE, diff --git a/src/drivers/ins/microstrain/MicroStrain.hpp b/src/drivers/ins/microstrain/MicroStrain.hpp index 4a2ad032d55..04347871fac 100755 --- a/src/drivers/ins/microstrain/MicroStrain.hpp +++ b/src/drivers/ins/microstrain/MicroStrain.hpp @@ -247,36 +247,36 @@ private: (ParamInt) _param_ms_imu_rate_hz, (ParamInt) _param_ms_mag_rate_hz, (ParamInt) _param_ms_baro_rate_hz, - (ParamInt) _param_ms_filter_rate_hz, + (ParamInt) _param_ms_filt_rate_hz, (ParamInt) _param_ms_gnss_rate_hz, (ParamInt) _param_ms_alignment, - (ParamInt) _param_ms_gnss_aid_src_ctrl, + (ParamInt) _param_ms_gnss_aid_src, (ParamInt) _param_ms_int_mag_en, (ParamInt) _param_ms_ext_mag_en, - (ParamInt) _param_ms_int_heading_en, - (ParamInt) _param_ms_ext_heading_en, - (ParamInt) _param_ms_ext_opt_flow_en, + (ParamInt) _param_ms_int_head_en, + (ParamInt) _param_ms_ext_head_en, + (ParamInt) _param_ms_opt_flow_en, (ParamInt) _param_ms_svt_en, - (ParamInt) _param_ms_accel_range_setting, - (ParamInt) _param_ms_gyro_range_setting, - (ParamFloat) _param_ms_gnss_offset1_x, - (ParamFloat) _param_ms_gnss_offset1_y, - (ParamFloat) _param_ms_gnss_offset1_z, - (ParamFloat) _param_ms_gnss_offset2_x, - (ParamFloat) _param_ms_gnss_offset2_y, - (ParamFloat) _param_ms_gnss_offset2_z, + (ParamInt) _param_ms_accel_range, + (ParamInt) _param_ms_gyro_range, + (ParamFloat) _param_ms_gnss_off1_x, + (ParamFloat) _param_ms_gnss_off1_y, + (ParamFloat) _param_ms_gnss_off1_z, + (ParamFloat) _param_ms_gnss_off2_x, + (ParamFloat) _param_ms_gnss_off2_y, + (ParamFloat) _param_ms_gnss_off2_z, (ParamFloat) _param_ms_sensor_roll, - (ParamFloat) _param_ms_sensor_pitch, + (ParamFloat) _param_ms_sensor_ptch, (ParamFloat) _param_ms_sensor_yaw, (ParamFloat) _param_ms_emag_roll, - (ParamFloat) _param_ms_emag_pitch, + (ParamFloat) _param_ms_emag_ptch, (ParamFloat) _param_ms_emag_yaw, - (ParamFloat) _param_ms_oflow_offset_x, - (ParamFloat) _param_ms_oflow_offset_y, - (ParamFloat) _param_ms_oflow_offset_z, + (ParamFloat) _param_ms_oflw_off_x, + (ParamFloat) _param_ms_oflw_off_y, + (ParamFloat) _param_ms_oflw_off_z, (ParamFloat) _param_ms_ehead_yaw, (ParamFloat) _param_ms_emag_uncert, - (ParamFloat) _param_ms_oflow_uncert + (ParamFloat) _param_ms_oflw_uncert ) // Sensor types needed for message creation / updating / publishing diff --git a/src/drivers/osd/atxxxx/atxxxx.cpp b/src/drivers/osd/atxxxx/atxxxx.cpp index df9969eb467..66344976481 100644 --- a/src/drivers/osd/atxxxx/atxxxx.cpp +++ b/src/drivers/osd/atxxxx/atxxxx.cpp @@ -76,10 +76,8 @@ OSDatxxxx::init() } // clear the screen - int num_rows = (_param_osd_atxxxx_cfg.get() == 1 ? OSD_NUM_ROWS_NTSC : OSD_NUM_ROWS_PAL); - for (int i = 0; i < OSD_CHARS_PER_ROW; i++) { - for (int j = 0; j < num_rows; j++) { + for (int j = 0; j < _num_rows; j++) { add_character_to_screen(' ', i, j); } } @@ -119,11 +117,9 @@ int OSDatxxxx::init_osd() { int ret = PX4_OK; - uint8_t data = OSD_ZERO_BYTE; - - if (_param_osd_atxxxx_cfg.get() == 2) { - data |= OSD_PAL_TX_MODE; - } + const bool pal = (_param_osd_atxxxx_cfg.get() == 2); + const uint8_t data = pal ? OSD_PAL_TX_MODE : OSD_ZERO_BYTE; + _num_rows = pal ? OSD_NUM_ROWS_PAL : OSD_NUM_ROWS_NTSC; ret |= writeRegister(0x00, data); ret |= writeRegister(0x04, OSD_ZERO_BYTE); @@ -174,23 +170,14 @@ int OSDatxxxx::add_character_to_screen(char c, uint8_t pos_x, uint8_t pos_y) { uint16_t position = (OSD_CHARS_PER_ROW * pos_y) + pos_x; - uint8_t position_lsb = 0; - int ret = PX4_ERROR; - if (position > 0xFF) { - position_lsb = static_cast(position) - 0xFF; - ret = writeRegister(0x05, 0x01); //DMAH - - } else { - position_lsb = static_cast(position); - ret = writeRegister(0x05, 0x00); //DMAH - } + int ret = writeRegister(0x05, position > 0xFF ? 0x01 : 0x00); //DMAH if (ret != 0) { return ret; } - ret = writeRegister(0x06, position_lsb); //DMAL + ret = writeRegister(0x06, static_cast(position)); //DMAL if (ret != 0) { return ret; @@ -324,7 +311,7 @@ OSDatxxxx::enable_screen() int ret = PX4_OK; ret |= readRegister(0x00, &data, 1); - ret |= writeRegister(0x00, data | 0x48); + ret |= writeRegister(0x00, data | 0x08); return ret; } @@ -477,17 +464,21 @@ OSDatxxxx::update_screen() clear_line(1, 3, 10); } + // Placed relative to the bottom row, since NTSC shows 13 rows and PAL 16. + const uint8_t flight_mode_row = _num_rows - 4; + const uint8_t flight_time_row = _num_rows - 2; + const char *flight_mode = ""; if (_arming_state == vehicle_status_s::ARMING_STATE_ARMED) { float flight_time_sec = static_cast((hrt_absolute_time() - _arming_timestamp) / (1e6f)); - ret |= add_flighttime(flight_time_sec, 1, 14); + ret |= add_flighttime(flight_time_sec, 1, flight_time_row); } else { flight_mode = get_flight_mode(_nav_state); } - add_string_to_screen_centered(flight_mode, 12, 10); + add_string_to_screen_centered(flight_mode, flight_mode_row, 10); return ret; } diff --git a/src/drivers/osd/atxxxx/atxxxx.h b/src/drivers/osd/atxxxx/atxxxx.h index 100a2a7ac4e..72912c5dcc8 100644 --- a/src/drivers/osd/atxxxx/atxxxx.h +++ b/src/drivers/osd/atxxxx/atxxxx.h @@ -127,6 +127,8 @@ private: // flight mode uint8_t _nav_state{0}; + uint8_t _num_rows{OSD_NUM_ROWS_NTSC}; + DEFINE_PARAMETERS( (ParamInt) _param_osd_atxxxx_cfg ) diff --git a/src/drivers/px4io/CMakeLists.txt b/src/drivers/px4io/CMakeLists.txt index 20bd7932a25..1e5f463a7e2 100644 --- a/src/drivers/px4io/CMakeLists.txt +++ b/src/drivers/px4io/CMakeLists.txt @@ -47,6 +47,7 @@ px4_add_module( button_publisher circuit_breaker mixer_module + px4io_protocol ) # include the px4io binary in ROMFS diff --git a/src/drivers/px4io/px4io.cpp b/src/drivers/px4io/px4io.cpp index b6173903ad6..742e0db2226 100644 --- a/src/drivers/px4io/px4io.cpp +++ b/src/drivers/px4io/px4io.cpp @@ -78,7 +78,7 @@ #include -#include +#include #include "uploader.h" @@ -336,7 +336,7 @@ private: (ParamInt) _param_rc_rssi_pwm_chan, (ParamInt) _param_rc_rssi_pwm_max, (ParamInt) _param_rc_rssi_pwm_min, - (ParamInt) _param_sens_en_themal + (ParamInt) _param_sens_en_thermal ) }; @@ -595,9 +595,9 @@ void PX4IO::Run() /* Tell IO that it can terminate the flight if FMU is not responding or if a failure has been reported by the FailureDetector logic */ io_reg_set(PX4IO_PAGE_SETUP, PX4IO_P_SETUP_ENABLE_FLIGHTTERMINATION, !disable_flighttermination); - if (_param_sens_en_themal.get() != _thermal_control || _param_update_force) { + if (_param_sens_en_thermal.get() != _thermal_control || _param_update_force) { - _thermal_control = _param_sens_en_themal.get(); + _thermal_control = _param_sens_en_thermal.get(); /* set power management state for thermal */ uint16_t tctrl; diff --git a/src/drivers/transponder/sagetech_mxs/SagetechMXS.cpp b/src/drivers/transponder/sagetech_mxs/SagetechMXS.cpp index 9c251f9006e..1d0cba09f8d 100644 --- a/src/drivers/transponder/sagetech_mxs/SagetechMXS.cpp +++ b/src/drivers/transponder/sagetech_mxs/SagetechMXS.cpp @@ -110,18 +110,17 @@ int SagetechMXS::task_spawn(int argc, char *argv[]) bool SagetechMXS::init() { - ScheduleOnInterval(UPDATE_INTERVAL_US); // 50Hz mxs_state.initialized = false; mxs_state.init_failed = false; if (vehicle_list == nullptr) { - if (_adsb_list_max.get() > MAX_VEHICLES_LIMIT) { // Safety Check - _adsb_list_max.set(MAX_VEHICLES_LIMIT); - _adsb_list_max.commit(); + if (_param_adsb_list_max.get() > MAX_VEHICLES_LIMIT) { // Safety Check + _param_adsb_list_max.set(MAX_VEHICLES_LIMIT); + _param_adsb_list_max.commit(); list_size_allocated = MAX_VEHICLES_LIMIT; } - vehicle_list = new transponder_report_s[_adsb_list_max.get()]; + vehicle_list = new transponder_report_s[_param_adsb_list_max.get()]; if (vehicle_list == nullptr) { mxs_state.init_failed = true; @@ -129,9 +128,14 @@ bool SagetechMXS::init() return false; } - list_size_allocated = _adsb_list_max.get(); + list_size_allocated = _param_adsb_list_max.get(); } + // Schedule only once init succeeded: on failure the instance is deleted in + // the shell, which must not happen after Run() opened the serial port on the + // work queue (file descriptors are per task group on NuttX). + ScheduleOnInterval(UPDATE_INTERVAL_US); // 50Hz + return true; } @@ -158,8 +162,8 @@ int SagetechMXS::custom_command(int argc, char *argv[]) } if (!strcmp(verb, "ident")) { - get_instance(desc)->_adsb_ident.set(1); - return get_instance(desc)->_adsb_ident.commit(); + get_instance(desc)->_param_adsb_ident.set(1); + return get_instance(desc)->_param_adsb_ident.commit(); } if (!strcmp(verb, "opmode")) { @@ -170,20 +174,20 @@ int SagetechMXS::custom_command(int argc, char *argv[]) return PX4_ERROR; } else if (!strcmp(opmode, "off") || !strcmp(opmode, "0")) { - get_instance(desc)->_mxs_op_mode.set(0); - return get_instance(desc)->_mxs_op_mode.commit(); + get_instance(desc)->_param_mxs_op_mode.set(0); + return get_instance(desc)->_param_mxs_op_mode.commit(); } else if (!strcmp(opmode, "on") || !strcmp(opmode, "1")) { - get_instance(desc)->_mxs_op_mode.set(1); - return get_instance(desc)->_mxs_op_mode.commit(); + get_instance(desc)->_param_mxs_op_mode.set(1); + return get_instance(desc)->_param_mxs_op_mode.commit(); } else if (!strcmp(opmode, "stby") || !strcmp(opmode, "2")) { - get_instance(desc)->_mxs_op_mode.set(2); - return get_instance(desc)->_mxs_op_mode.commit(); + get_instance(desc)->_param_mxs_op_mode.set(2); + return get_instance(desc)->_param_mxs_op_mode.commit(); } else if (!strcmp(opmode, "alt") || !strcmp(opmode, "3")) { - get_instance(desc)->_mxs_op_mode.set(3); - return get_instance(desc)->_mxs_op_mode.commit(); + get_instance(desc)->_param_mxs_op_mode.set(3); + return get_instance(desc)->_param_mxs_op_mode.commit(); } else { print_usage("Invalid Op Mode"); @@ -207,8 +211,8 @@ int SagetechMXS::custom_command(int argc, char *argv[]) return PX4_ERROR; } else { - get_instance(desc)->_adsb_squawk.set(sqk); - return get_instance(desc)->_adsb_squawk.commit(); + get_instance(desc)->_param_adsb_squawk.set(sqk); + return get_instance(desc)->_param_adsb_squawk.commit(); } } @@ -299,15 +303,15 @@ void SagetechMXS::Run() mxs_state.init_failed = true; } - if (!_mxs_ext_cfg.get()) { + if (!_param_mxs_ext_cfg.get()) { // Auto configuration auto_config_operating(); - if (_adsb_icao.get() >= 0) { + if (_param_adsb_icao_id.get() >= 0) { auto_config_installation(); auto_config_flightid(); - _mxs_op_mode.set(sg_op_mode_t::modeStby); - _mxs_op_mode.commit(); + _param_mxs_op_mode.set(sg_op_mode_t::modeStby); + _param_mxs_op_mode.commit(); } send_targetreq_msg(); @@ -370,7 +374,7 @@ void SagetechMXS::Run() if (!(_loop_count % ONE_HZ_MOD)) { // 1Hz Timer (Operating Message/GPS Ground) // PX4_INFO("1 Hz callback"); - if (!mxs_state.initialized && _mxs_ext_cfg.get()) { + if (!mxs_state.initialized && _param_mxs_ext_cfg.get()) { // External Configuration send_data_req(dataInstall); } @@ -389,7 +393,7 @@ void SagetechMXS::Run() _parameter_update_sub.copy(¶m_update); ModuleParams::updateParams(); - if (mxs_state.treq.transmitPort != (sg_transmitport_t)_mxs_targ_port.get()) { + if (mxs_state.treq.transmitPort != (sg_transmitport_t)_param_mxs_targ_port.get()) { send_targetreq_msg(); } } @@ -697,7 +701,7 @@ void SagetechMXS::send_data_req(const sg_datatype_t dataReqType) void SagetechMXS::send_install_msg() { - const int32_t adsb_icao = _adsb_icao.get(); + const int32_t adsb_icao = _param_adsb_icao_id.get(); if (adsb_icao < 0) { return; @@ -710,9 +714,9 @@ void SagetechMXS::send_install_msg() } mxs_state.inst.icao = static_cast(adsb_icao); - mxs_state.inst.emitter = convert_emitter_type_to_sg(_adsb_emit_type.get()); - mxs_state.inst.size = (sg_size_t)_adsb_len_width.get(); - mxs_state.inst.maxSpeed = (sg_airspeed_t)_adsb_max_speed.get(); + mxs_state.inst.emitter = convert_emitter_type_to_sg(_param_adsb_emit_type.get()); + mxs_state.inst.size = (sg_size_t)_param_adsb_len_width.get(); + mxs_state.inst.maxSpeed = (sg_airspeed_t)_param_adsb_max_speed.get(); mxs_state.inst.antenna = sg_antenna_t::antBottom; last.msg.type = SG_MSG_TYPE_HOST_INSTALL; @@ -733,11 +737,11 @@ void SagetechMXS::send_operating_msg() { // In auto-conf mode ADSB_ICAO_ID=-1 disables ADS-B Out. Keep the transponder // off so a retained installation from an earlier setup cannot transmit. - const bool adsb_out_disabled = !_mxs_ext_cfg.get() && _adsb_icao.get() < 0; - mxs_state.op.opMode = adsb_out_disabled ? sg_op_mode_t::modeOff : (sg_op_mode_t)_mxs_op_mode.get(); + const bool adsb_out_disabled = !_param_mxs_ext_cfg.get() && _param_adsb_icao_id.get() < 0; + mxs_state.op.opMode = adsb_out_disabled ? sg_op_mode_t::modeOff : (sg_op_mode_t)_param_mxs_op_mode.get(); - if (check_valid_squawk(_adsb_squawk.get())) { - mxs_state.op.squawk = convert_base_to_decimal(BASE_OCTAL, _adsb_squawk.get()); + if (check_valid_squawk(_param_adsb_squawk.get())) { + mxs_state.op.squawk = convert_base_to_decimal(BASE_OCTAL, _param_adsb_squawk.get()); } else { mxs_state.op.squawk = convert_base_to_decimal(BASE_OCTAL, INVALID_SQUAWK); @@ -758,11 +762,11 @@ void SagetechMXS::send_operating_msg() mxs_state.op.altitude = static_cast(_gnss.altitude_msl * SAGETECH_SCALE_M_TO_FT); // Height above sealevel in feet - mxs_state.op.identOn = _adsb_ident.get(); + mxs_state.op.identOn = _param_adsb_ident.get(); if (mxs_state.op.identOn) { - _adsb_ident.set(0); - _adsb_ident.commit(); + _param_adsb_ident.set(0); + _param_adsb_ident.commit(); } if (_gnss.vel_ned_valid) { @@ -861,9 +865,9 @@ void SagetechMXS::send_gps_msg() void SagetechMXS::send_targetreq_msg() { mxs_state.treq.reqType = sg_reporttype_t::reportAuto; - mxs_state.treq.transmitPort = (sg_transmitport_t)_mxs_targ_port.get(); + mxs_state.treq.transmitPort = (sg_transmitport_t)_param_mxs_targ_port.get(); mxs_state.treq.maxTargets = list_size_allocated; - mxs_state.treq.icao = _adsb_icao_specl.get(); + mxs_state.treq.icao = _param_adsb_icao_specl.get(); mxs_state.treq.stateVector = true; mxs_state.treq.modeStatus = true; mxs_state.treq.targetState = false; @@ -1086,7 +1090,7 @@ int SagetechMXS::open_serial_port() uart_config.c_cflag &= ~CRTSCTS; // Set Baud Rate - unsigned baud = convert_to_px4_baud(_ser_mxs_baud.get()); + unsigned baud = convert_to_px4_baud(_param_ser_mxs_baud.get()); if ((cfsetispeed(&uart_config, baud) < 0) || (cfsetospeed(&uart_config, baud) < 0)) { PX4_ERR("ERR SET BAUD %s: %d\n", _port, termios_state); @@ -1258,14 +1262,14 @@ int SagetechMXS::handle_fid(const char *fid) int SagetechMXS::store_inst_resp() { - _mxs_op_mode.set(mxs_state.ack.opMode); - _mxs_op_mode.commit(); - _adsb_icao.set(mxs_state.inst.icao); - _adsb_icao.commit(); - _adsb_len_width.set(mxs_state.inst.size); - _adsb_len_width.commit(); - _adsb_emit_type.set(convert_sg_to_emitter_type(mxs_state.inst.emitter)); - _adsb_emit_type.commit(); + _param_mxs_op_mode.set(mxs_state.ack.opMode); + _param_mxs_op_mode.commit(); + _param_adsb_icao_id.set(mxs_state.inst.icao); + _param_adsb_icao_id.commit(); + _param_adsb_len_width.set(mxs_state.inst.size); + _param_adsb_len_width.commit(); + _param_adsb_emit_type.set(convert_sg_to_emitter_type(mxs_state.inst.emitter)); + _param_adsb_emit_type.commit(); return PX4_OK; } @@ -1273,11 +1277,11 @@ int SagetechMXS::store_inst_resp() void SagetechMXS::auto_config_operating() { mxs_state.op.opMode = sg_op_mode_t::modeOff; - _mxs_op_mode.set(sg_op_mode_t::modeOff); - _mxs_op_mode.commit(); + _param_mxs_op_mode.set(sg_op_mode_t::modeOff); + _param_mxs_op_mode.commit(); - if (check_valid_squawk(_adsb_squawk.get())) { - mxs_state.op.squawk = convert_base_to_decimal(BASE_OCTAL, _adsb_squawk.get()); + if (check_valid_squawk(_param_adsb_squawk.get())) { + mxs_state.op.squawk = convert_base_to_decimal(BASE_OCTAL, _param_adsb_squawk.get()); } else { mxs_state.op.squawk = convert_base_to_decimal(BASE_OCTAL, INVALID_SQUAWK); @@ -1288,7 +1292,7 @@ void SagetechMXS::auto_config_operating() mxs_state.op.enableXBit = false; // Enable the x-bit mxs_state.op.milEmergency = false; // Broadcast a military emergency mxs_state.op.emergcType = (sg_emergc_t) - _adsb_emergc.get(); // Enumerated civilian emergency type + _param_adsb_emergc.get(); // Enumerated civilian emergency type mxs_state.op.altUseIntrnl = true; // True = Report altitude from internal pressure sensor (will ignore other bits in the field) @@ -1327,7 +1331,7 @@ void SagetechMXS::auto_config_operating() void SagetechMXS::auto_config_installation() { - const int32_t adsb_icao = _adsb_icao.get(); + const int32_t adsb_icao = _param_adsb_icao_id.get(); if (adsb_icao < 0) { return; @@ -1345,9 +1349,9 @@ void SagetechMXS::auto_config_installation() mxs_state.inst.sil = sg_sil_t::silUnknown; mxs_state.inst.sda = sg_sda_t::sdaUnknown; - mxs_state.inst.emitter = convert_emitter_type_to_sg(_adsb_emit_type.get()); - mxs_state.inst.size = (sg_size_t)_adsb_len_width.get(); - mxs_state.inst.maxSpeed = (sg_airspeed_t) _adsb_max_speed.get(); + mxs_state.inst.emitter = convert_emitter_type_to_sg(_param_adsb_emit_type.get()); + mxs_state.inst.size = (sg_size_t)_param_adsb_len_width.get(); + mxs_state.inst.maxSpeed = (sg_airspeed_t) _param_adsb_max_speed.get(); mxs_state.inst.altOffset = 0; // Alt encoder offset is legacy field that should always be 0. mxs_state.inst.antenna = sg_antenna_t::antBottom; diff --git a/src/drivers/transponder/sagetech_mxs/SagetechMXS.hpp b/src/drivers/transponder/sagetech_mxs/SagetechMXS.hpp index 330a5a663bb..aa891e284cb 100644 --- a/src/drivers/transponder/sagetech_mxs/SagetechMXS.hpp +++ b/src/drivers/transponder/sagetech_mxs/SagetechMXS.hpp @@ -91,21 +91,21 @@ public: private: // Parameters DEFINE_PARAMETERS( - (ParamInt) _adsb_squawk, - (ParamInt) _adsb_ident, - (ParamInt) _adsb_list_max, - (ParamInt) _adsb_icao, - (ParamInt) _adsb_len_width, - (ParamInt) _adsb_emit_type, - (ParamInt) _adsb_max_speed, - (ParamInt) _adsb_icao_specl, - (ParamInt) _adsb_emergc, - (ParamInt) _mxs_op_mode, - (ParamInt) _mxs_targ_port, - // (ParamInt) _mxs_com0_baud, - // (ParamInt) _mxs_com1_baud, - (ParamInt) _mxs_ext_cfg, - (ParamInt) _ser_mxs_baud + (ParamInt) _param_adsb_squawk, + (ParamInt) _param_adsb_ident, + (ParamInt) _param_adsb_list_max, + (ParamInt) _param_adsb_icao_id, + (ParamInt) _param_adsb_len_width, + (ParamInt) _param_adsb_emit_type, + (ParamInt) _param_adsb_max_speed, + (ParamInt) _param_adsb_icao_specl, + (ParamInt) _param_adsb_emergc, + (ParamInt) _param_mxs_op_mode, + (ParamInt) _param_mxs_targ_port, + // (ParamInt) _param_mxs_com0_baud, + // (ParamInt) _param_mxs_com1_baud, + (ParamInt) _param_mxs_ext_cfg, + (ParamInt) _param_ser_mxs_baud ); // Serial Port Variables @@ -256,7 +256,7 @@ private: bool find_index(const transponder_report_s &vehicle, uint16_t *index) const; void set_vehicle(const uint16_t index, const transponder_report_s &vehicle); void delete_vehicle(const uint16_t index); - bool is_special_vehicle(uint32_t icao) const {return (_adsb_icao_specl.get() != 0) && (_adsb_icao_specl.get() == (int32_t) icao);} + bool is_special_vehicle(uint32_t icao) const {return (_param_adsb_icao_specl.get() != 0) && (_param_adsb_icao_specl.get() == (int32_t) icao);} void handle_vehicle(const transponder_report_s &vehicle); void determine_furthest_aircraft(); void send_data_req(const sg_datatype_t dataReqType); diff --git a/src/drivers/uavcan/actuators/servo.cpp b/src/drivers/uavcan/actuators/servo.cpp index c991c44602f..11178661e73 100644 --- a/src/drivers/uavcan/actuators/servo.cpp +++ b/src/drivers/uavcan/actuators/servo.cpp @@ -43,7 +43,7 @@ UavcanServoController::UavcanServoController(uavcan::INode &node) : _uavcan_pub_array_cmd(node) { _uavcan_pub_array_cmd.setPriority(UAVCAN_COMMAND_TRANSFER_PRIORITY); - _max_rate_hz = (unsigned)_param_sv_rtmax.get(); + _max_rate_hz = (unsigned)_param_uavcan_sv_rtmax.get(); } void UavcanServoController::update_outputs(float outputs[MAX_ACTUATORS], unsigned num_outputs) diff --git a/src/drivers/uavcan/actuators/servo.hpp b/src/drivers/uavcan/actuators/servo.hpp index cb53caff257..fe9ab658413 100644 --- a/src/drivers/uavcan/actuators/servo.hpp +++ b/src/drivers/uavcan/actuators/servo.hpp @@ -64,6 +64,6 @@ private: uavcan::Publisher _uavcan_pub_array_cmd; DEFINE_PARAMETERS( - (ParamInt) _param_sv_rtmax + (ParamInt) _param_uavcan_sv_rtmax ) }; diff --git a/src/drivers/uavcannode/UavcanNode.cpp b/src/drivers/uavcannode/UavcanNode.cpp index bf9b376ed59..34a1a531809 100644 --- a/src/drivers/uavcannode/UavcanNode.cpp +++ b/src/drivers/uavcannode/UavcanNode.cpp @@ -860,6 +860,14 @@ void UavcanNode::Run() if (_task_should_exit.load()) { ScheduleClear(); + +#if defined(CONFIG_UAVCANNODE_COMMAND_SHELL) + // The shell pipes were opened on this work queue and file descriptors + // are per task group, so close them here rather than in the destructor + // (which runs in the shell calling stop). Closing gives the shell EOF. + close_shell(); +#endif // CONFIG_UAVCANNODE_COMMAND_SHELL + _instance = nullptr; } } diff --git a/src/drivers/uwb/uwb_sr150/uwb_sr150.cpp b/src/drivers/uwb/uwb_sr150/uwb_sr150.cpp index c18eee94986..5bf62a8d379 100644 --- a/src/drivers/uwb/uwb_sr150/uwb_sr150.cpp +++ b/src/drivers/uwb/uwb_sr150/uwb_sr150.cpp @@ -253,9 +253,11 @@ int UWB_SR150::task_spawn(int argc, char *argv[]) desc.object.store(instance); desc.task_id = task_id_is_work_queue; - instance->ScheduleOnInterval(5000_us); - + // Initialize before scheduling: on failure the instance is deleted here in + // the shell, which must not happen after Run() opened the UART on the + // work queue (file descriptors are per task group on NuttX). if (instance->init()) { + instance->ScheduleOnInterval(5000_us); return PX4_OK; } @@ -372,10 +374,10 @@ int UWB_SR150::collectData() _sensor_uwb.aoa_dest_elevation_fom = - double(_distance_result_msg.measurements.aoa_dest_elevation) / 128; /* Sensor physical offset*/ //for now we propagate the physical configuration via Uorb - _sensor_uwb.orientation = _sensor_rot.get(); - _sensor_uwb.offset_x = _offset_x.get(); - _sensor_uwb.offset_y = _offset_y.get(); - _sensor_uwb.offset_z = _offset_z.get(); + _sensor_uwb.orientation = _param_uwb_sens_rot.get(); + _sensor_uwb.offset_x = _param_uwb_init_off_x.get(); + _sensor_uwb.offset_y = _param_uwb_init_off_y.get(); + _sensor_uwb.offset_z = _param_uwb_init_off_z.get(); _sensor_uwb_pub.publish(_sensor_uwb); diff --git a/src/drivers/uwb/uwb_sr150/uwb_sr150.h b/src/drivers/uwb/uwb_sr150/uwb_sr150.h index 24f0999ecd1..496c867b068 100644 --- a/src/drivers/uwb/uwb_sr150/uwb_sr150.h +++ b/src/drivers/uwb/uwb_sr150/uwb_sr150.h @@ -130,11 +130,11 @@ private: // Parameters DEFINE_PARAMETERS( - (ParamInt) _uwb_port_cfg, - (ParamFloat) _offset_x, - (ParamFloat) _offset_y, - (ParamFloat) _offset_z, - (ParamInt) _sensor_rot + (ParamInt) _param_uwb_port_cfg, + (ParamFloat) _param_uwb_init_off_x, + (ParamFloat) _param_uwb_init_off_y, + (ParamFloat) _param_uwb_init_off_z, + (ParamInt) _param_uwb_sens_rot ) // Performance (perf) counters perf_counter_t _read_count_perf; diff --git a/src/lib/CMakeLists.txt b/src/lib/CMakeLists.txt index d355829ad6c..1c4296baa3a 100644 --- a/src/lib/CMakeLists.txt +++ b/src/lib/CMakeLists.txt @@ -1,6 +1,6 @@ ############################################################################ # -# Copyright (c) 2017-2023 PX4 Development Team. All rights reserved. +# Copyright (c) 2017-2026 PX4 Development Team. All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions @@ -53,6 +53,7 @@ add_subdirectory(dijkstra EXCLUDE_FROM_ALL) add_subdirectory(drivers EXCLUDE_FROM_ALL) add_subdirectory(failure_injection EXCLUDE_FROM_ALL) add_subdirectory(field_sensor_bias_estimator EXCLUDE_FROM_ALL) +add_subdirectory(fw_performance_model EXCLUDE_FROM_ALL) add_subdirectory(gen_nav EXCLUDE_FROM_ALL) add_subdirectory(geo EXCLUDE_FROM_ALL) add_subdirectory(geofence EXCLUDE_FROM_ALL) @@ -61,18 +62,18 @@ add_subdirectory(heatshrink EXCLUDE_FROM_ALL) add_subdirectory(hysteresis EXCLUDE_FROM_ALL) add_subdirectory(lat_lon_alt EXCLUDE_FROM_ALL) add_subdirectory(led EXCLUDE_FROM_ALL) -add_subdirectory(matrix EXCLUDE_FROM_ALL) add_subdirectory(mathlib EXCLUDE_FROM_ALL) +add_subdirectory(matrix EXCLUDE_FROM_ALL) add_subdirectory(mixer_module EXCLUDE_FROM_ALL) add_subdirectory(motion_planning EXCLUDE_FROM_ALL) add_subdirectory(motor_failure_detector EXCLUDE_FROM_ALL) add_subdirectory(npfg EXCLUDE_FROM_ALL) add_subdirectory(open_drone_id EXCLUDE_FROM_ALL) add_subdirectory(perf EXCLUDE_FROM_ALL) -add_subdirectory(fw_performance_model EXCLUDE_FROM_ALL) add_subdirectory(pid EXCLUDE_FROM_ALL) add_subdirectory(pid_design EXCLUDE_FROM_ALL) add_subdirectory(pure_pursuit EXCLUDE_FROM_ALL) +add_subdirectory(px4io_protocol EXCLUDE_FROM_ALL) add_subdirectory(rate_control EXCLUDE_FROM_ALL) add_subdirectory(rc EXCLUDE_FROM_ALL) add_subdirectory(ringbuffer EXCLUDE_FROM_ALL) @@ -80,11 +81,12 @@ add_subdirectory(rl_tools EXCLUDE_FROM_ALL) add_subdirectory(rover_control EXCLUDE_FROM_ALL) add_subdirectory(rtl EXCLUDE_FROM_ALL) add_subdirectory(sensor_calibration EXCLUDE_FROM_ALL) +add_subdirectory(sensor_slot_binder EXCLUDE_FROM_ALL) add_subdirectory(slew_rate EXCLUDE_FROM_ALL) -add_subdirectory(sticks EXCLUDE_FROM_ALL) add_subdirectory(stick_yaw EXCLUDE_FROM_ALL) -add_subdirectory(systemlib EXCLUDE_FROM_ALL) +add_subdirectory(sticks EXCLUDE_FROM_ALL) add_subdirectory(system_identification EXCLUDE_FROM_ALL) +add_subdirectory(systemlib EXCLUDE_FROM_ALL) add_subdirectory(tecs EXCLUDE_FROM_ALL) add_subdirectory(tensorflow_lite_micro EXCLUDE_FROM_ALL) add_subdirectory(terrain_estimation EXCLUDE_FROM_ALL) diff --git a/src/lib/adsb/f3442_standard/DaaF3442.cpp b/src/lib/adsb/f3442_standard/DaaF3442.cpp index 7415b9aee90..cb641985bf7 100644 --- a/src/lib/adsb/f3442_standard/DaaF3442.cpp +++ b/src/lib/adsb/f3442_standard/DaaF3442.cpp @@ -57,9 +57,9 @@ bool DaaF3442::try_setting_params() { updateParams(); - const matrix::Vector2f nmac_bounds{_param_daa_lvl_critical_rad.get(), _param_daa_lvl_critical_hgt.get()}; + const matrix::Vector2f nmac_bounds{_param_daa_lvl_crit_rad.get(), _param_daa_lvl_crit_hgt.get()}; const matrix::Vector2f wc_bounds{_param_daa_lvl_high_rad.get(), _param_daa_lvl_high_hgt.get()}; - const int32_t nmac_latency = _param_daa_lvl_medium_time.get(); + const int32_t nmac_latency = _param_daa_lvl_med_time.get(); const int32_t wc_latency = _param_daa_lvl_low_time.get(); const bool nmac_ok = nmac_bounds.isAllFinite() && nmac_bounds.min() > 0.f; diff --git a/src/lib/adsb/f3442_standard/DaaF3442.h b/src/lib/adsb/f3442_standard/DaaF3442.h index 1f3a3fbdf82..81f3effd27e 100644 --- a/src/lib/adsb/f3442_standard/DaaF3442.h +++ b/src/lib/adsb/f3442_standard/DaaF3442.h @@ -97,11 +97,11 @@ private: float _aug_wc_latency_s{33.f}; DEFINE_PARAMETERS( - (ParamFloat) _param_daa_lvl_critical_rad, - (ParamFloat) _param_daa_lvl_critical_hgt, + (ParamFloat) _param_daa_lvl_crit_rad, + (ParamFloat) _param_daa_lvl_crit_hgt, (ParamFloat) _param_daa_lvl_high_rad, (ParamFloat) _param_daa_lvl_high_hgt, - (ParamInt) _param_daa_lvl_medium_time, + (ParamInt) _param_daa_lvl_med_time, (ParamInt) _param_daa_lvl_low_time ) }; diff --git a/src/lib/failure_injection/FailureInjection.cpp b/src/lib/failure_injection/FailureInjection.cpp index 735190105ed..2d435a47222 100644 --- a/src/lib/failure_injection/FailureInjection.cpp +++ b/src/lib/failure_injection/FailureInjection.cpp @@ -37,6 +37,8 @@ #include +#include +#include #include #include #include @@ -167,6 +169,40 @@ bool process_gnss(const Config &config, uint8_t uorb_instance, sensor_gnss_s &se return true; } +bool process_airspeed(const Config &config, uint8_t uorb_instance, differential_pressure_s &differential_pressure, + AirspeedState &state) +{ + using namespace time_literals; + + static constexpr float blockage_fraction = 0.7f; // max blockage (fully ramped) + static constexpr float blockage_rampup_time = 30_s; // time to reach max blockage, linear ramp + + const Mode mode = config.mode(failure_injection_s::FAILURE_UNIT_SENSOR_AIRSPEED, uorb_instance + 1); + + if (mode != Mode::Wrong) { + state.blocked_timestamp = 0; + } + + // Off and Stuck are message-agnostic; run them first so the Stuck cache keeps the + // unblocked sample. + if (!process(mode, differential_pressure, state.stuck)) { + return false; + } + + if (mode == Mode::Wrong) { + // Simulate pitot blockage: start the ramp on the rising edge and keep it running. + if (state.blocked_timestamp == 0) { + state.blocked_timestamp = differential_pressure.timestamp; + } + + const float blockage_scale = math::constrain(1.f - (differential_pressure.timestamp - state.blocked_timestamp) / + blockage_rampup_time, 1.f - blockage_fraction, 1.f); + differential_pressure.differential_pressure_pa *= blockage_scale; + } + + return true; +} + esc_status_s process_esc(const Config &config, const esc_status_s &status) { esc_status_s result = status; diff --git a/src/lib/failure_injection/FailureInjection.hpp b/src/lib/failure_injection/FailureInjection.hpp index 8d73b2a3224..c73ef416e8c 100644 --- a/src/lib/failure_injection/FailureInjection.hpp +++ b/src/lib/failure_injection/FailureInjection.hpp @@ -52,6 +52,7 @@ #include #include #include +#include #include #include @@ -222,6 +223,24 @@ bool process_battery(const Config &config, uint8_t instance, battery_status_s &b bool process_gnss(const Config &config, uint8_t uorb_instance, sensor_gnss_s &sensor_gnss, Stuck &stuck); +/** Per-consumer airspeed failure state: the last good sample for Stuck and the blockage start for Wrong. */ +struct AirspeedState { + Stuck stuck; + uint64_t blocked_timestamp{0}; +}; + +/** + * Airspeed counterpart to process(): on FAILURE_UNIT_SENSOR_AIRSPEED for the sensor publishing on + * the given 0-based uORB instance, Off and Stuck behave as in the generic process() and Wrong + * simulates a pitot blockage, ramping the differential pressure down linearly from the onset of + * the failure (taken from differential_pressure.timestamp) to a fixed fraction of the true value. + * + * @param uorb_instance 0-based uORB instance of the publisher (not the 1-based failure instance). + * @return false if the differential_pressure publication must be suppressed (Off), true otherwise. + */ +bool process_airspeed(const Config &config, uint8_t uorb_instance, differential_pressure_s &differential_pressure, + AirspeedState &state); + /** * ESC counterpart to process(): apply the active FAILURE_UNIT_SYSTEM_ESC failures to a copy of * status (matched per ESC by actuator_function). Off zeroes the ESC's telemetry (keeping only @@ -327,6 +346,9 @@ template struct Stuck { }; +struct AirspeedState { +}; + template bool process(Mode, MsgT &, Stuck &) { return true; } @@ -341,6 +363,8 @@ inline bool process_battery(const Config &, uint8_t, battery_status_s &) { retur inline bool process_gnss(const Config &, uint8_t, sensor_gnss_s &, Stuck &) { return true; } +inline bool process_airspeed(const Config &, uint8_t, differential_pressure_s &, AirspeedState &) { return true; } + inline esc_status_s process_esc(const Config &, const esc_status_s &status) { return status; } inline MotorFailureMasks process_motor(const Config &) { return {}; } diff --git a/src/lib/fw_performance_model/PerformanceModel.cpp b/src/lib/fw_performance_model/PerformanceModel.cpp index 7eb39d90fb8..c8b0d390bc8 100644 --- a/src/lib/fw_performance_model/PerformanceModel.cpp +++ b/src/lib/fw_performance_model/PerformanceModel.cpp @@ -104,7 +104,7 @@ float PerformanceModel::getMaximumClimbRate(float air_density) const air_density = sanitiseAirDensity(air_density); float climbrate_max = _param_fw_t_clmb_max.get(); - const float service_ceiling = _param_service_ceiling.get(); + const float service_ceiling = _param_fw_service_ceil.get(); if (service_ceiling > FLT_EPSILON) { const float ceiling_pressure = getPressureFromAltitude(service_ceiling); diff --git a/src/lib/fw_performance_model/PerformanceModel.hpp b/src/lib/fw_performance_model/PerformanceModel.hpp index 123cef528e7..600a71c0835 100644 --- a/src/lib/fw_performance_model/PerformanceModel.hpp +++ b/src/lib/fw_performance_model/PerformanceModel.hpp @@ -158,7 +158,7 @@ private: (ParamFloat) _param_weight_base, (ParamFloat) _param_weight_gross, (ParamFloat) _param_weight_fuel, - (ParamFloat) _param_service_ceiling, + (ParamFloat) _param_fw_service_ceil, (ParamFloat) _param_fw_thr_trim, (ParamFloat) _param_fw_thr_max, (ParamFloat) _param_fw_thr_min, diff --git a/src/lib/geofence/GeofenceUtilsTest.cpp b/src/lib/geofence/GeofenceUtilsTest.cpp index 1a7c408ff74..2f98900e48a 100644 --- a/src/lib/geofence/GeofenceUtilsTest.cpp +++ b/src/lib/geofence/GeofenceUtilsTest.cpp @@ -437,6 +437,19 @@ TEST(GeofenceUtilsTest, AddApproxCircleRejectsOutOfBounds) } +// Routes run along the edges of the k-gon, so the edges, not only the vertices, must keep the margin. +TEST(GeofenceUtilsTest, ApproxExclusionCircleKeepsTheMarginAlongItsEdges) +{ + geofence_utils::PlannerPolygons polys; + ASSERT_EQ(polys.addApproxCircle(matrix::Vector2f(0, 0), 100.f, 10.f, false), AddResult::Success); + + for (int i = 0; i < polys.numVertices(); i++) { + // The middle of an edge is its point closest to the circle. Nodes are stored in cm. + const matrix::Vector2f middle = (polys.node(1 + i) + polys.node(1 + (i + 1) % polys.numVertices())) * 0.5f; + EXPECT_GE(middle.norm(), 110.f - 0.02f) << "edge " << i; + } +} + // =========================================================================== // addPolygon rejects non-simple input // =========================================================================== diff --git a/src/lib/geofence/geofence_utils.cpp b/src/lib/geofence/geofence_utils.cpp index ca2acfb8c71..e5cac1afbeb 100644 --- a/src/lib/geofence/geofence_utils.cpp +++ b/src/lib/geofence/geofence_utils.cpp @@ -270,7 +270,7 @@ PlannerPolygons::AddResult PlannerPolygons::addApproxCircle(const matrix::Vector // - under-approximation of circle shrunk by margin, if inclusion const float k_gon_radius = is_inclusion_zone ? circle_radius - margin - : circle_radius / cosf(M_PI_F / kCircleApproxVertices) + margin; + : (circle_radius + margin) / cosf(M_PI_F / kCircleApproxVertices); if (k_gon_radius <= FLT_EPSILON) { // Negative radius - circle empty return AddResult::Degenerate; diff --git a/src/lib/parameters/CMakeLists.txt b/src/lib/parameters/CMakeLists.txt index 2eaa077d061..ab2b6bf2071 100644 --- a/src/lib/parameters/CMakeLists.txt +++ b/src/lib/parameters/CMakeLists.txt @@ -91,6 +91,7 @@ add_custom_command(OUTPUT ${generated_serial_params_file} ${generated_module_par --params-file ${generated_serial_params_file} --serial-ports ${board_serial_ports} ${added_arguments} ${constrained_flash_arg} --config-files ${module_config_files} + --board-config ${BOARD_CONFIG} #--verbose COMMAND ${PYTHON_EXECUTABLE} ${PX4_SOURCE_DIR}/Tools/module_config/generate_params.py --params-file ${generated_module_params_file} diff --git a/src/lib/parameters/param_translation.cpp b/src/lib/parameters/param_translation.cpp index db08f173e52..067f0de94b0 100644 --- a/src/lib/parameters/param_translation.cpp +++ b/src/lib/parameters/param_translation.cpp @@ -210,6 +210,37 @@ param_modify_on_import_ret param_modify_on_import(bson_node_t node) } } + // 2026-08-19: translate the single-sensor optical flow params to sensor slot 0 + { + static constexpr const char *renames[][2] = { + {"EKF2_OF_CTRL", "EKF2_OF0_CTRL"}, + {"EKF2_OF_GYR_SRC", "EKF2_OF0_GYR_SRC"}, + {"EKF2_OF_N_MIN", "EKF2_OF0_N_MIN"}, + {"EKF2_OF_N_MAX", "EKF2_OF0_N_MAX"}, + {"EKF2_OF_QMIN", "EKF2_OF0_QMIN"}, + {"EKF2_OF_QMIN_GND", "EKF2_OF0_QMINGND"}, + {"EKF2_OF_GATE", "EKF2_OF0_GATE"}, + {"EKF2_OF_DELAY", "SENS_FLOW0_DELAY"}, + {"EKF2_OF_POS_X", "SENS_FLOW0_POS_X"}, + {"EKF2_OF_POS_Y", "SENS_FLOW0_POS_Y"}, + {"EKF2_OF_POS_Z", "SENS_FLOW0_POS_Z"}, + {"SENS_FLOW_MINHGT", "SENS_FLOW0_HMIN"}, + {"SENS_FLOW_MAXHGT", "SENS_FLOW0_HMAX"}, + {"SENS_FLOW_MAXR", "SENS_FLOW0_MAXR"}, + {"SENS_FLOW_ROT", "SENS_FLOW0_ROT"}, + {"SENS_FLOW_RATE", "SENS_FLOW0_RATE"}, + {"SENS_FLOW_SCALE", "SENS_FLOW0_SCALE"}, + }; + + for (const auto &rename : renames) { + if (strcmp(rename[0], node->name) == 0) { + strcpy(node->name, rename[1]); + PX4_INFO("migrating %s -> %s", rename[0], rename[1]); + return param_modify_on_import_ret::PARAM_MODIFIED; + } + } + } + // 2026-03-11: translate MOT_POLE_COUNT to per-motor DSHOT_MOT_POL1-12 { if ((node->type == bson_type_t::BSON_INT32) && (strcmp("MOT_POLE_COUNT", node->name) == 0)) { @@ -474,5 +505,27 @@ param_modify_on_import_ret param_modify_on_import(bson_node_t node) } } + // 2026-11-17: the failure detector checks the tilt error from the attitude setpoint instead of absolute roll and pitch. + // The old limits and trigger times mean something else now and are not taken over, only a check disabled for both + // roll and pitch stays disabled. The other old parameter may still follow in the import, so both are tracked. + { + static bool roll_disabled = false, pitch_disabled = false; // FD_FAIL_R and FD_FAIL_P default to 60° + + const bool is_roll = (node->type == bson_type_t::BSON_INT32) && (strcmp("FD_FAIL_R", node->name) == 0); + const bool is_pitch = (node->type == bson_type_t::BSON_INT32) && (strcmp("FD_FAIL_P", node->name) == 0); + + if (is_roll || is_pitch) { + (is_roll ? roll_disabled : pitch_disabled) = (node->i32 == 0); + + if (roll_disabled && pitch_disabled) { + float max_tilt_error_deg = -1.f; + param_set(param_find("FD_TILT_ERROR"), &max_tilt_error_deg); + PX4_INFO("migrating FD_FAIL_R and FD_FAIL_P -> FD_TILT_ERROR (disabled)"); + } + + return param_modify_on_import_ret::PARAM_SKIP_IMPORT; + } + } + return param_modify_on_import_ret::PARAM_NOT_MODIFIED; } diff --git a/src/lib/px4io_protocol/CMakeLists.txt b/src/lib/px4io_protocol/CMakeLists.txt new file mode 100644 index 00000000000..cde1cdaa34a --- /dev/null +++ b/src/lib/px4io_protocol/CMakeLists.txt @@ -0,0 +1,36 @@ +############################################################################ +# +# Copyright (c) 2026 PX4 Development Team. All rights reserved. +# +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions +# are met: +# +# 1. Redistributions of source code must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# 2. Redistributions in binary form must reproduce the above copyright +# notice, this list of conditions and the following disclaimer in +# the documentation and/or other materials provided with the +# distribution. +# 3. Neither the name PX4 nor the names of its contributors may be +# used to endorse or promote products derived from this software +# without specific prior written permission. +# +# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS +# FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE +# COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, +# BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS +# OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED +# AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN +# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE +# POSSIBILITY OF SUCH DAMAGE. +# +############################################################################ + +px4_add_library(px4io_protocol + px4io_protocol.c +) diff --git a/src/modules/px4iofirmware/protocol.h b/src/lib/px4io_protocol/protocol.h similarity index 86% rename from src/modules/px4iofirmware/protocol.h rename to src/lib/px4io_protocol/protocol.h index effca63a7c6..e15031607ef 100644 --- a/src/modules/px4iofirmware/protocol.h +++ b/src/lib/px4io_protocol/protocol.h @@ -244,52 +244,12 @@ struct IOPacket { #define PKT_CODE(_p) ((_p).count_code & PKT_CODE_MASK) #define PKT_SIZE(_p) ((size_t)((uint8_t *)&((_p).regs[PKT_COUNT(_p)]) - ((uint8_t *)&(_p)))) -static const uint8_t crc8_tab[256] __attribute__((unused)) = { - 0x00, 0x07, 0x0E, 0x09, 0x1C, 0x1B, 0x12, 0x15, - 0x38, 0x3F, 0x36, 0x31, 0x24, 0x23, 0x2A, 0x2D, - 0x70, 0x77, 0x7E, 0x79, 0x6C, 0x6B, 0x62, 0x65, - 0x48, 0x4F, 0x46, 0x41, 0x54, 0x53, 0x5A, 0x5D, - 0xE0, 0xE7, 0xEE, 0xE9, 0xFC, 0xFB, 0xF2, 0xF5, - 0xD8, 0xDF, 0xD6, 0xD1, 0xC4, 0xC3, 0xCA, 0xCD, - 0x90, 0x97, 0x9E, 0x99, 0x8C, 0x8B, 0x82, 0x85, - 0xA8, 0xAF, 0xA6, 0xA1, 0xB4, 0xB3, 0xBA, 0xBD, - 0xC7, 0xC0, 0xC9, 0xCE, 0xDB, 0xDC, 0xD5, 0xD2, - 0xFF, 0xF8, 0xF1, 0xF6, 0xE3, 0xE4, 0xED, 0xEA, - 0xB7, 0xB0, 0xB9, 0xBE, 0xAB, 0xAC, 0xA5, 0xA2, - 0x8F, 0x88, 0x81, 0x86, 0x93, 0x94, 0x9D, 0x9A, - 0x27, 0x20, 0x29, 0x2E, 0x3B, 0x3C, 0x35, 0x32, - 0x1F, 0x18, 0x11, 0x16, 0x03, 0x04, 0x0D, 0x0A, - 0x57, 0x50, 0x59, 0x5E, 0x4B, 0x4C, 0x45, 0x42, - 0x6F, 0x68, 0x61, 0x66, 0x73, 0x74, 0x7D, 0x7A, - 0x89, 0x8E, 0x87, 0x80, 0x95, 0x92, 0x9B, 0x9C, - 0xB1, 0xB6, 0xBF, 0xB8, 0xAD, 0xAA, 0xA3, 0xA4, - 0xF9, 0xFE, 0xF7, 0xF0, 0xE5, 0xE2, 0xEB, 0xEC, - 0xC1, 0xC6, 0xCF, 0xC8, 0xDD, 0xDA, 0xD3, 0xD4, - 0x69, 0x6E, 0x67, 0x60, 0x75, 0x72, 0x7B, 0x7C, - 0x51, 0x56, 0x5F, 0x58, 0x4D, 0x4A, 0x43, 0x44, - 0x19, 0x1E, 0x17, 0x10, 0x05, 0x02, 0x0B, 0x0C, - 0x21, 0x26, 0x2F, 0x28, 0x3D, 0x3A, 0x33, 0x34, - 0x4E, 0x49, 0x40, 0x47, 0x52, 0x55, 0x5C, 0x5B, - 0x76, 0x71, 0x78, 0x7F, 0x6A, 0x6D, 0x64, 0x63, - 0x3E, 0x39, 0x30, 0x37, 0x22, 0x25, 0x2C, 0x2B, - 0x06, 0x01, 0x08, 0x0F, 0x1A, 0x1D, 0x14, 0x13, - 0xAE, 0xA9, 0xA0, 0xA7, 0xB2, 0xB5, 0xBC, 0xBB, - 0x96, 0x91, 0x98, 0x9F, 0x8A, 0x8D, 0x84, 0x83, - 0xDE, 0xD9, 0xD0, 0xD7, 0xC2, 0xC5, 0xCC, 0xCB, - 0xE6, 0xE1, 0xE8, 0xEF, 0xFA, 0xFD, 0xF4, 0xF3 -}; +#ifdef __cplusplus +extern "C" { +#endif -static uint8_t crc_packet(struct IOPacket *pkt) __attribute__((unused)); -static uint8_t -crc_packet(struct IOPacket *pkt) -{ - uint8_t *end = (uint8_t *)(&pkt->regs[PKT_COUNT(*pkt)]); - uint8_t *p = (uint8_t *)pkt; - uint8_t c = 0; +uint8_t crc_packet(struct IOPacket *pkt); - while (p < end) { - c = crc8_tab[c ^ * (p++)]; - } - - return c; +#ifdef __cplusplus } +#endif diff --git a/src/lib/px4io_protocol/px4io_protocol.c b/src/lib/px4io_protocol/px4io_protocol.c new file mode 100644 index 00000000000..7c9d199a16e --- /dev/null +++ b/src/lib/px4io_protocol/px4io_protocol.c @@ -0,0 +1,90 @@ +/**************************************************************************** + * + * Copyright (c) 2026 PX4 Development Team. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name PX4 nor the names of its contributors may be + * used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + * + ****************************************************************************/ + +/** + * @file px4io_protocol.c + * + * CRC-8 for the PX4IO serial protocol, shared by the IO firmware and the + * flight controller driver so each image carries one copy of the table. + */ + +#include "protocol.h" + +static const uint8_t crc8_tab[256] = { + 0x00, 0x07, 0x0E, 0x09, 0x1C, 0x1B, 0x12, 0x15, + 0x38, 0x3F, 0x36, 0x31, 0x24, 0x23, 0x2A, 0x2D, + 0x70, 0x77, 0x7E, 0x79, 0x6C, 0x6B, 0x62, 0x65, + 0x48, 0x4F, 0x46, 0x41, 0x54, 0x53, 0x5A, 0x5D, + 0xE0, 0xE7, 0xEE, 0xE9, 0xFC, 0xFB, 0xF2, 0xF5, + 0xD8, 0xDF, 0xD6, 0xD1, 0xC4, 0xC3, 0xCA, 0xCD, + 0x90, 0x97, 0x9E, 0x99, 0x8C, 0x8B, 0x82, 0x85, + 0xA8, 0xAF, 0xA6, 0xA1, 0xB4, 0xB3, 0xBA, 0xBD, + 0xC7, 0xC0, 0xC9, 0xCE, 0xDB, 0xDC, 0xD5, 0xD2, + 0xFF, 0xF8, 0xF1, 0xF6, 0xE3, 0xE4, 0xED, 0xEA, + 0xB7, 0xB0, 0xB9, 0xBE, 0xAB, 0xAC, 0xA5, 0xA2, + 0x8F, 0x88, 0x81, 0x86, 0x93, 0x94, 0x9D, 0x9A, + 0x27, 0x20, 0x29, 0x2E, 0x3B, 0x3C, 0x35, 0x32, + 0x1F, 0x18, 0x11, 0x16, 0x03, 0x04, 0x0D, 0x0A, + 0x57, 0x50, 0x59, 0x5E, 0x4B, 0x4C, 0x45, 0x42, + 0x6F, 0x68, 0x61, 0x66, 0x73, 0x74, 0x7D, 0x7A, + 0x89, 0x8E, 0x87, 0x80, 0x95, 0x92, 0x9B, 0x9C, + 0xB1, 0xB6, 0xBF, 0xB8, 0xAD, 0xAA, 0xA3, 0xA4, + 0xF9, 0xFE, 0xF7, 0xF0, 0xE5, 0xE2, 0xEB, 0xEC, + 0xC1, 0xC6, 0xCF, 0xC8, 0xDD, 0xDA, 0xD3, 0xD4, + 0x69, 0x6E, 0x67, 0x60, 0x75, 0x72, 0x7B, 0x7C, + 0x51, 0x56, 0x5F, 0x58, 0x4D, 0x4A, 0x43, 0x44, + 0x19, 0x1E, 0x17, 0x10, 0x05, 0x02, 0x0B, 0x0C, + 0x21, 0x26, 0x2F, 0x28, 0x3D, 0x3A, 0x33, 0x34, + 0x4E, 0x49, 0x40, 0x47, 0x52, 0x55, 0x5C, 0x5B, + 0x76, 0x71, 0x78, 0x7F, 0x6A, 0x6D, 0x64, 0x63, + 0x3E, 0x39, 0x30, 0x37, 0x22, 0x25, 0x2C, 0x2B, + 0x06, 0x01, 0x08, 0x0F, 0x1A, 0x1D, 0x14, 0x13, + 0xAE, 0xA9, 0xA0, 0xA7, 0xB2, 0xB5, 0xBC, 0xBB, + 0x96, 0x91, 0x98, 0x9F, 0x8A, 0x8D, 0x84, 0x83, + 0xDE, 0xD9, 0xD0, 0xD7, 0xC2, 0xC5, 0xCC, 0xCB, + 0xE6, 0xE1, 0xE8, 0xEF, 0xFA, 0xFD, 0xF4, 0xF3 +}; + +uint8_t +crc_packet(struct IOPacket *pkt) +{ + uint8_t *end = (uint8_t *)(&pkt->regs[PKT_COUNT(*pkt)]); + uint8_t *p = (uint8_t *)pkt; + uint8_t c = 0; + + while (p < end) { + c = crc8_tab[c ^ * (p++)]; + } + + return c; +} diff --git a/src/lib/rover_control/RoverControl.cpp b/src/lib/rover_control/RoverControl.cpp index ce8e2148452..17eb8db9e49 100644 --- a/src/lib/rover_control/RoverControl.cpp +++ b/src/lib/rover_control/RoverControl.cpp @@ -73,7 +73,10 @@ float throttleControl(SlewRate &motor_setpoint, const float throttle_setp return NAN; } - const bool accelerating = fabsf(throttle_setpoint) > fabsf(current_motor_setpoint); + // Accelerating towards a larger setpoint of the same sign, otherwise decelerating + // Without a deceleration limit, only the magnitudes are compared + const bool accelerating = (throttle_setpoint * current_motor_setpoint >= 0.f || max_decel <= FLT_EPSILON) + && fabsf(throttle_setpoint) > fabsf(current_motor_setpoint); if (accelerating && max_accel > FLT_EPSILON && max_thr_spd > FLT_EPSILON) { // Acceleration slew rate motor_setpoint.setSlewRate(max_accel / max_thr_spd); @@ -142,7 +145,13 @@ float speedControl(SlewRate &speed_with_rate_limit, PID &pid_speed, const } // Apply acceleration and deceleration limit - if (fabsf(speed_setpoint) >= fabsf(vehicle_speed) && max_accel > FLT_EPSILON) { + // Accelerating towards a larger setpoint of the same sign as the vehicle speed or the rate limited setpoint, + // otherwise decelerating. Without a deceleration limit, only the magnitudes are compared + const bool accelerating = (speed_setpoint * vehicle_speed >= 0.f + || speed_setpoint * speed_with_rate_limit.getState() >= 0.f || max_decel <= FLT_EPSILON) + && fabsf(speed_setpoint) >= fabsf(vehicle_speed); + + if (accelerating && max_accel > FLT_EPSILON) { speed_with_rate_limit.setSlewRate(max_accel); speed_with_rate_limit.update(speed_setpoint, dt); @@ -152,7 +161,7 @@ float speedControl(SlewRate &speed_with_rate_limit, PID &pid_speed, const speed_with_rate_limit.setForcedValue(speed_setpoint); } - } else if (fabsf(speed_setpoint) < fabsf(vehicle_speed) && max_decel > FLT_EPSILON) { + } else if (!accelerating && max_decel > FLT_EPSILON) { speed_with_rate_limit.setSlewRate(max_decel); speed_with_rate_limit.update(speed_setpoint, dt); diff --git a/src/lib/rover_control/RoverControlTest.cpp b/src/lib/rover_control/RoverControlTest.cpp index 29965d9576c..724ed3ba85c 100644 --- a/src/lib/rover_control/RoverControlTest.cpp +++ b/src/lib/rover_control/RoverControlTest.cpp @@ -226,3 +226,76 @@ TEST(mapSticks, mappings) expectSticks(0, 0.1f, 0.2f, 0.4f); expectSticks(5, 0.1f, 0.2f, 0.4f); } + +TEST(throttleControl, decelerationLimitOnSignChange) +{ + // Distinct limits so the applied one can be read from a single step + const float max_accel = 1.f; // [m/s^2] + const float max_decel = 4.f; // [m/s^2] + const float no_limit = -1.f; + const float max_thr_spd = 2.f; // [m/s] + const float dt = 0.1f; // [s] + const float accel_step = max_accel / max_thr_spd * dt; + const float decel_step = max_decel / max_thr_spd * dt; + SlewRate motor_setpoint; + + const auto step = [&](float throttle_setpoint, float current_motor_setpoint, float accel, float decel) { + motor_setpoint.setForcedValue(current_motor_setpoint); + return RoverControl::throttleControl(motor_setpoint, throttle_setpoint, current_motor_setpoint, accel, decel, + max_thr_spd, dt); + }; + + // Full reverse while driving forwards (and vice versa) brakes towards zero first: deceleration limit + EXPECT_NEAR(step(-1.f, 0.5f, max_accel, max_decel), 0.5f - decel_step, 1e-6f); + EXPECT_NEAR(step(1.f, -0.5f, max_accel, max_decel), -0.5f + decel_step, 1e-6f); + EXPECT_NEAR(step(-0.2f, 0.5f, max_accel, max_decel), 0.5f - decel_step, 1e-6f); + EXPECT_NEAR(step(-1.f, 0.5f, no_limit, max_decel), 0.5f - decel_step, 1e-6f); + + // Once the sign has changed or from standstill: acceleration limit + EXPECT_NEAR(step(-1.f, -0.2f, max_accel, max_decel), -0.2f - accel_step, 1e-6f); + EXPECT_NEAR(step(1.f, 0.2f, max_accel, max_decel), 0.2f + accel_step, 1e-6f); + EXPECT_NEAR(step(-1.f, 0.f, max_accel, max_decel), -accel_step, 1e-6f); + + // Without a deceleration limit the acceleration limit applies as before + EXPECT_NEAR(step(-1.f, 0.5f, max_accel, no_limit), 0.5f - accel_step, 1e-6f); +} + +TEST(speedControl, decelerationLimitOnSignChange) +{ + // Distinct limits so the applied one can be read from a single step + const float max_accel = 1.f; // [m/s^2] + const float max_decel = 4.f; // [m/s^2] + const float no_limit = -1.f; + const float max_thr_speed = 0.f; // [m/s] No feed forward, only the rate limited speed setpoint is checked + const float dt = 0.1f; // [s] + SlewRate speed_with_rate_limit; + PID pid_speed; + + // One update starting from the rate limited setpoint adjusted_speed + const auto step = [&](float speed_setpoint, float vehicle_speed, float adjusted_speed, float accel, float decel) { + speed_with_rate_limit.setForcedValue(adjusted_speed); + RoverControl::speedControl(speed_with_rate_limit, pid_speed, speed_setpoint, vehicle_speed, accel, decel, + max_thr_speed, dt); + return speed_with_rate_limit.getState(); + }; + + // Reverse setpoint while driving forwards (and vice versa) brakes towards zero first: deceleration limit + EXPECT_NEAR(step(-1.f, 1.f, 1.f, max_accel, max_decel), 1.f - max_decel * dt, 1e-6f); + EXPECT_NEAR(step(1.f, -1.f, -1.f, max_accel, max_decel), -1.f + max_decel * dt, 1e-6f); + EXPECT_NEAR(step(-2.f, 1.f, 1.f, max_accel, max_decel), 1.f - max_decel * dt, 1e-6f); + EXPECT_NEAR(step(-1.f, 1.f, 1.f, no_limit, max_decel), 1.f - max_decel * dt, 1e-6f); + + // Smaller setpoint of the same sign: deceleration limit + EXPECT_NEAR(step(0.1f, 0.5f, 0.5f, max_accel, max_decel), 0.5f - max_decel * dt, 1e-6f); + + // Once the sign has changed or from standstill: acceleration limit + EXPECT_NEAR(step(-1.f, -0.5f, -0.5f, max_accel, max_decel), -0.5f - max_accel * dt, 1e-6f); + EXPECT_NEAR(step(1.f, 0.5f, 0.5f, max_accel, max_decel), 0.5f + max_accel * dt, 1e-6f); + EXPECT_NEAR(step(-1.f, 0.f, 0.f, max_accel, max_decel), -max_accel * dt, 1e-6f); + + // The rate limited setpoint has changed sign while the vehicle speed lags behind: acceleration limit + EXPECT_NEAR(step(-1.f, 0.5f, -0.1f, max_accel, max_decel), -0.1f - max_accel * dt, 1e-6f); + + // Without a deceleration limit the acceleration limit applies as before + EXPECT_NEAR(step(-1.f, 1.f, 1.f, max_accel, no_limit), 1.f - max_accel * dt, 1e-6f); +} diff --git a/src/lib/sensor_slot_binder/CMakeLists.txt b/src/lib/sensor_slot_binder/CMakeLists.txt new file mode 100644 index 00000000000..b3093f4ee7b --- /dev/null +++ b/src/lib/sensor_slot_binder/CMakeLists.txt @@ -0,0 +1,35 @@ +############################################################################ +# +# Copyright (c) 2026 PX4 Development Team. All rights reserved. +# +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions +# are met: +# +# 1. Redistributions of source code must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# 2. Redistributions in binary form must reproduce the above copyright +# notice, this list of conditions and the following disclaimer in +# the documentation and/or other materials provided with the +# distribution. +# 3. Neither the name PX4 nor the names of its contributors may be +# used to endorse or promote products derived from this software +# without specific prior written permission. +# +# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS +# FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE +# COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, +# BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS +# OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED +# AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN +# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE +# POSSIBILITY OF SUCH DAMAGE. +# +############################################################################ + +# header-only, SensorSlotBinder.hpp is included directly +px4_add_functional_gtest(SRC SensorSlotBinderTest.cpp LINKLIBS parameters) diff --git a/src/lib/sensor_slot_binder/SensorSlotBinder.hpp b/src/lib/sensor_slot_binder/SensorSlotBinder.hpp new file mode 100644 index 00000000000..dc2d052c895 --- /dev/null +++ b/src/lib/sensor_slot_binder/SensorSlotBinder.hpp @@ -0,0 +1,162 @@ +/**************************************************************************** + * + * Copyright (c) 2026 PX4 Development Team. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name PX4 nor the names of its contributors may be + * used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + * + ****************************************************************************/ + +#pragma once + +#include +#include +#include +#include + +#include +#include +#include + +// Maps uORB instances to fixed sensor slots by device ID: an unknown sensor is bound to the +// first free slot (ID param 0) and the assignment is persisted so it stays stable across reboots. +class SensorSlotBinder +{ +public: + static constexpr uint8_t kMaxSlots = 4; + + void init(const char *id_param_format, uint8_t num_slots) + { + _num_slots = (num_slots <= kMaxSlots) ? num_slots : kMaxSlots; + + for (uint8_t slot = 0; slot < _num_slots; slot++) { + char param_name[17] {}; + snprintf(param_name, sizeof(param_name), id_param_format, static_cast(slot)); + _id_param_handles[slot] = param_find(param_name); + + if (_id_param_handles[slot] != PARAM_INVALID) { + param_get(_id_param_handles[slot], &_ids[slot]); + } + } + } + + bool isSlotBound(uint8_t slot) const { return (slot < _num_slots) && (_ids[slot] != 0); } + + int8_t slotForInstance(uint8_t instance, uint32_t device_id) + { + if (instance >= _num_slots) { + return -1; + } + + if ((_instance_slot_map[instance] < 0) || (_instance_device_id[instance] != device_id)) { + _instance_slot_map[instance] = mapToSlot(device_id); + _instance_device_id[instance] = device_id; + } + + return _instance_slot_map[instance]; + } + + // a sensor without a device ID uses the slot of its uORB instance while no other sensor is bound to it + int8_t slotForInstanceWithFallback(uint8_t instance, uint32_t device_id) + { + const int8_t slot = slotForInstance(instance, device_id); + + if ((slot < 0) && (device_id == 0) && (instance < _num_slots) && !isSlotBound(instance)) { + return instance; + } + + return slot; + } + +private: + int8_t mapToSlot(uint32_t device_id) + { + if (device_id == 0) { + return -1; + } + + for (uint8_t slot = 0; slot < _num_slots; slot++) { + if (_ids[slot] == static_cast(device_id)) { + return slot; + } + } + + for (uint8_t slot = 0; slot < _num_slots; slot++) { + if (_ids[slot] == 0) { + const int32_t id = static_cast(device_id); + + _ids[slot] = id; + + if (param_set_no_notification(_id_param_handles[slot], &id) == PX4_OK) { + PX4_INFO("device ID %" PRIu32 " bound to %s", device_id, param_name(_id_param_handles[slot])); + + } else { + PX4_WARN("device ID %" PRIu32 " bound to slot %" PRIu8 " (not persisted)", device_id, slot); + } + + return slot; + } + } + + return -1; + } + + param_t _id_param_handles[kMaxSlots] {PARAM_INVALID, PARAM_INVALID, PARAM_INVALID, PARAM_INVALID}; + int32_t _ids[kMaxSlots] {}; + int8_t _instance_slot_map[kMaxSlots] {-1, -1, -1, -1}; + uint32_t _instance_device_id[kMaxSlots] {}; + uint8_t _num_slots{0}; +}; + +// One publication per slot. uORB numbers instances in advertise order and sensors arrive in any order, +// so every lower slot is advertised first to keep the uORB instance equal to the slot. +template +class SlotPublications +{ +public: + bool publish(uint8_t slot, const T &data) + { + if (slot >= N) { + return false; + } + + for (uint8_t i = 0; i <= slot; i++) { + if (!_pubs[i].advertised()) { + _pubs[i].advertise(); + } + } + + return _pubs[slot].publish(data); + } + +private: + struct Pub : public uORB::PublicationMulti { + Pub() : uORB::PublicationMulti(Id) {} + }; + + Pub _pubs[N] {}; +}; diff --git a/src/lib/sensor_slot_binder/SensorSlotBinderTest.cpp b/src/lib/sensor_slot_binder/SensorSlotBinderTest.cpp new file mode 100644 index 00000000000..77cbfa92027 --- /dev/null +++ b/src/lib/sensor_slot_binder/SensorSlotBinderTest.cpp @@ -0,0 +1,157 @@ +/**************************************************************************** + * + * Copyright (c) 2026 PX4 Development Team. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name PX4 nor the names of its contributors may be + * used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + * + ****************************************************************************/ + +#include +#include + +static constexpr const char *kIdParamFormat = "SENS_FLOW%u_ID"; +static constexpr uint32_t kDeviceA = 0x0A0B01; +static constexpr uint32_t kDeviceB = 0x0A0B02; +static constexpr uint32_t kDeviceC = 0x0A0B03; + +class SensorSlotBinderTest : public ::testing::Test +{ +public: + void SetUp() override + { + param_control_autosave(false); + + for (uint8_t slot = 0; slot < 2; slot++) { + param_reset(idParamHandle(slot)); + } + } + + param_t idParamHandle(uint8_t slot) + { + char param_name[17] {}; + snprintf(param_name, sizeof(param_name), kIdParamFormat, static_cast(slot)); + return param_find(param_name); + } + + int32_t idParam(uint8_t slot) + { + int32_t id = 0; + param_get(idParamHandle(slot), &id); + return id; + } + + void setIdParam(uint8_t slot, int32_t id) + { + param_set_no_notification(idParamHandle(slot), &id); + } +}; + +TEST_F(SensorSlotBinderTest, bindsUnknownSensorsInArrivalOrder) +{ + SensorSlotBinder binder; + binder.init(kIdParamFormat, 2); + + // the first sensor reporting data takes the first free slot, whatever its uORB instance + EXPECT_EQ(binder.slotForInstance(1, kDeviceA), 0); + EXPECT_EQ(binder.slotForInstance(0, kDeviceB), 1); + + // and the assignment is persisted + EXPECT_EQ(idParam(0), static_cast(kDeviceA)); + EXPECT_EQ(idParam(1), static_cast(kDeviceB)); + EXPECT_TRUE(binder.isSlotBound(0)); + EXPECT_TRUE(binder.isSlotBound(1)); +} + +TEST_F(SensorSlotBinderTest, keepsPersistedBinding) +{ + setIdParam(1, kDeviceA); + + SensorSlotBinder binder; + binder.init(kIdParamFormat, 2); + + EXPECT_EQ(binder.slotForInstance(0, kDeviceA), 1); + EXPECT_EQ(binder.slotForInstance(1, kDeviceB), 0); +} + +TEST_F(SensorSlotBinderTest, rejectsSensorWithoutDeviceId) +{ + SensorSlotBinder binder; + binder.init(kIdParamFormat, 2); + + EXPECT_EQ(binder.slotForInstance(0, 0), -1); + EXPECT_FALSE(binder.isSlotBound(0)); + EXPECT_EQ(idParam(0), 0); +} + +TEST_F(SensorSlotBinderTest, fallsBackToInstanceWithoutDeviceId) +{ + SensorSlotBinder binder; + binder.init(kIdParamFormat, 2); + + // a sensor without a device ID keeps its uORB instance as long as that slot is free + EXPECT_EQ(binder.slotForInstanceWithFallback(1, 0), 1); + EXPECT_FALSE(binder.isSlotBound(1)); + + // but never takes a slot bound to another sensor + EXPECT_EQ(binder.slotForInstanceWithFallback(0, kDeviceA), 0); + EXPECT_EQ(binder.slotForInstanceWithFallback(1, kDeviceB), 1); + EXPECT_EQ(binder.slotForInstanceWithFallback(1, 0), -1); +} + +TEST_F(SensorSlotBinderTest, followsDeviceChangeOnInstance) +{ + SensorSlotBinder binder; + binder.init(kIdParamFormat, 2); + + EXPECT_EQ(binder.slotForInstance(0, kDeviceA), 0); + EXPECT_EQ(binder.slotForInstance(0, kDeviceB), 1); + EXPECT_EQ(binder.slotForInstance(0, kDeviceA), 0); +} + +TEST_F(SensorSlotBinderTest, rejectsSensorWhenAllSlotsBound) +{ + SensorSlotBinder binder; + binder.init(kIdParamFormat, 2); + + EXPECT_EQ(binder.slotForInstance(0, kDeviceA), 0); + EXPECT_EQ(binder.slotForInstance(1, kDeviceB), 1); + EXPECT_EQ(binder.slotForInstance(0, kDeviceC), -1); + EXPECT_EQ(binder.slotForInstance(1, kDeviceB), 1); +} + +TEST_F(SensorSlotBinderTest, claimsSlotWhenBindingCannotBePersisted) +{ + // no such parameter: the binding lives in RAM only + SensorSlotBinder binder; + binder.init("NOPARAM%u_ID", 2); + + // a second sensor must not share the slot of the first one + EXPECT_EQ(binder.slotForInstance(0, kDeviceA), 0); + EXPECT_EQ(binder.slotForInstance(1, kDeviceB), 1); + EXPECT_TRUE(binder.isSlotBound(0)); +} diff --git a/src/modules/airspeed_selector/airspeed_selector_main.cpp b/src/modules/airspeed_selector/airspeed_selector_main.cpp index a5aa4670807..66c0ff0a94a 100644 --- a/src/modules/airspeed_selector/airspeed_selector_main.cpp +++ b/src/modules/airspeed_selector/airspeed_selector_main.cpp @@ -189,7 +189,7 @@ private: */ int primary_validator_index() const { - const int configured = _param_airspeed_primary_index.get() - 1; + const int configured = _param_aspd_primary.get() - 1; if ((configured < 0) || (configured >= MAX_NUM_AIRSPEED_SENSORS)) { return -1; @@ -225,22 +225,22 @@ private: DEFINE_PARAMETERS( (ParamFloat) _param_aspd_wind_nsd, - (ParamFloat) _param_west_tas_noise, + (ParamFloat) _param_aspd_tas_noise, (ParamInt) _param_aspd_scale_apply, - (ParamFloat) _param_airspeed_scale_1, - (ParamFloat) _param_airspeed_scale_2, - (ParamFloat) _param_airspeed_scale_3, - (ParamInt) _param_airspeed_primary_index, - (ParamInt) _param_airspeed_checks_on, - (ParamInt) _param_airspeed_fallback, + (ParamFloat) _param_aspd_scale_1, + (ParamFloat) _param_aspd_scale_2, + (ParamFloat) _param_aspd_scale_3, + (ParamInt) _param_aspd_primary, + (ParamInt) _param_aspd_do_checks, + (ParamInt) _param_aspd_fallback, - (ParamFloat) _tas_innov_threshold, /**< innovation check threshold */ - (ParamFloat) _tas_innov_integ_threshold, /**< innovation check integrator threshold */ - (ParamFloat) _checks_fail_delay, /**< delay to declare airspeed invalid */ - (ParamFloat) _checks_clear_delay, /**< delay to declare airspeed valid again */ + (ParamFloat) _param_aspd_fs_innov, /**< innovation check threshold */ + (ParamFloat) _param_aspd_fs_integ, /**< innovation check integrator threshold */ + (ParamFloat) _param_aspd_fs_t_stop, /**< delay to declare airspeed invalid */ + (ParamFloat) _param_aspd_fs_t_start, /**< delay to declare airspeed valid again */ - (ParamFloat) _param_wind_sigma_max_synth_tas, - (ParamFloat) _aspd_fp_t_window, + (ParamFloat) _param_aspd_werr_thr, + (ParamFloat) _param_aspd_fp_t_window, // external parameters (ParamFloat) _param_fw_airspd_stall, @@ -322,7 +322,7 @@ AirspeedModule::init() resolve_sensor_indices(); // Set the default sensor - const int32_t primary_param = _param_airspeed_primary_index.get(); + const int32_t primary_param = _param_aspd_primary.get(); const bool sensor_configured = (primary_param >= 1) && (primary_param <= MAX_NUM_AIRSPEED_SENSORS); const int primary = primary_validator_index(); @@ -356,7 +356,7 @@ AirspeedModule::check_for_connected_airspeed_sensors() // check for new connected airspeed sensor int detected_airspeed_sensors = 0; - if (_param_airspeed_primary_index.get() > 0 && _param_airspeed_primary_index.get() <= MAX_NUM_AIRSPEED_SENSORS) { + if (_param_aspd_primary.get() > 0 && _param_aspd_primary.get() <= MAX_NUM_AIRSPEED_SENSORS) { for (int i = 0; i < _airspeed_subs.size(); i++) { if (!_airspeed_subs[i].advertised()) { @@ -514,18 +514,18 @@ AirspeedModule::Run() switch (scale_index) { case 0: - _param_airspeed_scale_1.set(_airspeed_validator[i].get_CAS_scale_validated()); - _param_airspeed_scale_1.commit_no_notification(); + _param_aspd_scale_1.set(_airspeed_validator[i].get_CAS_scale_validated()); + _param_aspd_scale_1.commit_no_notification(); break; case 1: - _param_airspeed_scale_2.set(_airspeed_validator[i].get_CAS_scale_validated()); - _param_airspeed_scale_2.commit_no_notification(); + _param_aspd_scale_2.set(_airspeed_validator[i].get_CAS_scale_validated()); + _param_aspd_scale_2.commit_no_notification(); break; case 2: - _param_airspeed_scale_3.set(_airspeed_validator[i].get_CAS_scale_validated()); - _param_airspeed_scale_3.commit_no_notification(); + _param_aspd_scale_3.set(_airspeed_validator[i].get_CAS_scale_validated()); + _param_aspd_scale_3.commit_no_notification(); break; } @@ -565,9 +565,9 @@ void AirspeedModule::update_params() _param_airspeed_scale[2] }; - _param_airspeed_scale[0] = _param_airspeed_scale_1.get(); - _param_airspeed_scale[1] = _param_airspeed_scale_2.get(); - _param_airspeed_scale[2] = _param_airspeed_scale_3.get(); + _param_airspeed_scale[0] = _param_aspd_scale_1.get(); + _param_airspeed_scale[1] = _param_aspd_scale_2.get(); + _param_airspeed_scale[2] = _param_aspd_scale_3.get(); resolve_sensor_indices(); @@ -585,28 +585,28 @@ void AirspeedModule::update_params() for (int i = 0; i < MAX_NUM_AIRSPEED_SENSORS; i++) { _airspeed_validator[i].set_wind_estimator_wind_process_noise_spectral_density(_param_aspd_wind_nsd.get()); - _airspeed_validator[i].set_wind_estimator_tas_noise(_param_west_tas_noise.get()); + _airspeed_validator[i].set_wind_estimator_tas_noise(_param_aspd_tas_noise.get()); _airspeed_validator[i].set_tas_scale_apply(_param_aspd_scale_apply.get()); _airspeed_validator[i].set_wind_estimator_tas_scale_init(_param_airspeed_scale[_config_index[i]]); - _airspeed_validator[i].set_tas_innov_threshold(_tas_innov_threshold.get()); - _airspeed_validator[i].set_tas_innov_integ_threshold(_tas_innov_integ_threshold.get()); - _airspeed_validator[i].set_checks_fail_delay(_checks_fail_delay.get()); - _airspeed_validator[i].set_checks_clear_delay(_checks_clear_delay.get()); + _airspeed_validator[i].set_tas_innov_threshold(_param_aspd_fs_innov.get()); + _airspeed_validator[i].set_tas_innov_integ_threshold(_param_aspd_fs_integ.get()); + _airspeed_validator[i].set_checks_fail_delay(_param_aspd_fs_t_stop.get()); + _airspeed_validator[i].set_checks_clear_delay(_param_aspd_fs_t_start.get()); _airspeed_validator[i].set_airspeed_stall(_param_fw_airspd_stall.get()); - _airspeed_validator[i].set_enable_data_stuck_check(_param_airspeed_checks_on.get() & + _airspeed_validator[i].set_enable_data_stuck_check(_param_aspd_do_checks.get() & CheckTypeBits::CHECK_TYPE_DATA_STUCK_BIT); - _airspeed_validator[i].set_enable_innovation_check(_param_airspeed_checks_on.get() & + _airspeed_validator[i].set_enable_innovation_check(_param_aspd_do_checks.get() & CheckTypeBits::CHECK_TYPE_INNOVATION_BIT); - _airspeed_validator[i].set_enable_load_factor_check(_param_airspeed_checks_on.get() & + _airspeed_validator[i].set_enable_load_factor_check(_param_aspd_do_checks.get() & CheckTypeBits::CHECK_TYPE_LOAD_FACTOR_BIT); - _airspeed_validator[i].set_enable_first_principle_check(_param_airspeed_checks_on.get() & + _airspeed_validator[i].set_enable_first_principle_check(_param_aspd_do_checks.get() & CheckTypeBits::CHECK_TYPE_FIRST_PRINCIPLE_BIT); _airspeed_validator[i].set_psp_off_param(math::radians(_param_pitch_sp_offset)); _airspeed_validator[i].set_throttle_max_param(_param_fw_thr_max); - _airspeed_validator[i].set_fp_t_window(_aspd_fp_t_window.get()); + _airspeed_validator[i].set_fp_t_window(_param_aspd_fp_t_window.get()); } } @@ -748,7 +748,7 @@ void AirspeedModule::update_ground_minus_wind_airspeed() { const float wind_uncertainty = sqrtf(_wind_estimate_sideslip.variance_north + _wind_estimate_sideslip.variance_east); - if (_wind_estimator_sideslip.is_estimate_valid() && wind_uncertainty < _param_wind_sigma_max_synth_tas.get()) { + if (_wind_estimator_sideslip.is_estimate_valid() && wind_uncertainty < _param_aspd_werr_thr.get()) { // calculate airspeed estimate based on groundspeed-windspeed const float TAS_north = _vehicle_local_position.vx - _wind_estimate_sideslip.windspeed_north; const float TAS_east = _vehicle_local_position.vy - _wind_estimate_sideslip.windspeed_east; @@ -776,8 +776,8 @@ void AirspeedModule::select_airspeed_and_publish() } const bool airspeed_sensor_switching_allowed = _number_of_airspeed_sensors > 0 && - _param_airspeed_primary_index.get() > static_cast(AirspeedSource::GROUND_MINUS_WIND) - && _param_airspeed_checks_on.get(); + _param_aspd_primary.get() > static_cast(AirspeedSource::GROUND_MINUS_WIND) + && _param_aspd_do_checks.get(); const bool airspeed_sensor_added = _prev_number_of_airspeed_sensors < _number_of_airspeed_sensors; @@ -807,12 +807,12 @@ void AirspeedModule::select_airspeed_and_publish() // _gnss_lpos_valid determines if ground-wind estimate is valid if (_gnss_lpos_valid && - (_param_airspeed_fallback.get() == 1 - || _param_airspeed_primary_index.get() == static_cast(AirspeedSource::GROUND_MINUS_WIND))) { + (_param_aspd_fallback.get() == 1 + || _param_aspd_primary.get() == static_cast(AirspeedSource::GROUND_MINUS_WIND))) { _valid_airspeed_src = AirspeedSource::GROUND_MINUS_WIND; - } else if ((_param_airspeed_fallback.get() == 2 - || _param_airspeed_primary_index.get() == static_cast(AirspeedSource::SYNTHETIC)) + } else if ((_param_aspd_fallback.get() == 2 + || _param_aspd_primary.get() == static_cast(AirspeedSource::SYNTHETIC)) && _vehicle_status.vehicle_type == vehicle_status_s::VEHICLE_TYPE_FIXED_WING) { _valid_airspeed_src = AirspeedSource::SYNTHETIC; diff --git a/src/modules/attitude_estimator_q/attitude_estimator_q_main.cpp b/src/modules/attitude_estimator_q/attitude_estimator_q_main.cpp index 87165751bd2..f1adc8ecf10 100644 --- a/src/modules/attitude_estimator_q/attitude_estimator_q_main.cpp +++ b/src/modules/attitude_estimator_q/attitude_estimator_q_main.cpp @@ -168,7 +168,7 @@ private: (ParamInt) _param_att_mag_decl_a, (ParamInt) _param_att_ext_hdg_m, (ParamInt) _param_att_acc_comp, - (ParamFloat) _param_att_bias_mas, + (ParamFloat) _param_att_bias_max, (ParamInt) _param_sys_has_mag ) }; diff --git a/src/modules/commander/HealthAndArmingChecks/checks/escCheck.cpp b/src/modules/commander/HealthAndArmingChecks/checks/escCheck.cpp index 09774e8d673..1d9b776f6d2 100644 --- a/src/modules/commander/HealthAndArmingChecks/checks/escCheck.cpp +++ b/src/modules/commander/HealthAndArmingChecks/checks/escCheck.cpp @@ -359,7 +359,7 @@ void EscChecks::checkEscTemperature(Report &reporter, const esc_status_s &esc_st if (max_temperature >= warn_temp) { if (!_esc_over_temp_warned && reporter.mavlink_log_pub()) { - mavlink_log_warning(reporter.mavlink_log_pub(), "High ESC temperature. Reduce throttle!"); + mavlink_log_warning(reporter.mavlink_log_pub(), "High ESC temperature. Reduce throttle!\t"); _esc_over_temp_warned = true; } @@ -429,7 +429,7 @@ uint16_t EscChecks::checkMotorStatus(const Context &context, Report &reporter, c events::Log::Critical, "Motor {1} undercurrent detected", motor + 1); if (reporter.mavlink_log_pub()) { - mavlink_log_critical(reporter.mavlink_log_pub(), "Motor failure: Motor %d undercurrent detected", motor + 1); + mavlink_log_critical(reporter.mavlink_log_pub(), "Motor failure: Motor %d undercurrent detected\t", motor + 1); } } else if (failure == MotorFailureDetector::Failure::Overcurrent) { @@ -444,7 +444,7 @@ uint16_t EscChecks::checkMotorStatus(const Context &context, Report &reporter, c events::Log::Critical, "Motor {1} overcurrent detected", motor + 1); if (reporter.mavlink_log_pub()) { - mavlink_log_critical(reporter.mavlink_log_pub(), "Motor failure: Motor %d overcurrent detected", motor + 1); + mavlink_log_critical(reporter.mavlink_log_pub(), "Motor failure: Motor %d overcurrent detected\t", motor + 1); } } } @@ -492,7 +492,7 @@ void EscChecks::updateEscsStatus(const Context &context, Report &reporter, const events::Log::Critical, "Not all ESCs are armed"); if (reporter.mavlink_log_pub()) { - mavlink_log_critical(reporter.mavlink_log_pub(), "ESC failure: Not all ESCs are armed. Land now!"); + mavlink_log_critical(reporter.mavlink_log_pub(), "ESC failure: Not all ESCs are armed. Land now!\t"); } reporter.failsafeFlags().fd_esc_arming_failure = true; diff --git a/src/modules/commander/HealthAndArmingChecks/checks/estimatorCheck.cpp b/src/modules/commander/HealthAndArmingChecks/checks/estimatorCheck.cpp index b8080aad3fe..80787eef624 100644 --- a/src/modules/commander/HealthAndArmingChecks/checks/estimatorCheck.cpp +++ b/src/modules/commander/HealthAndArmingChecks/checks/estimatorCheck.cpp @@ -769,7 +769,7 @@ void EstimatorChecks::lowPositionAccuracy(const Context &context, Report &report && !reporter.failsafeFlags().global_position_invalid_relaxed) || (reporter.failsafeFlags().mode_req_local_position && !reporter.failsafeFlags().local_position_invalid)) { - position_valid_but_low_accuracy = (_param_com_low_eph.get() > FLT_EPSILON && lpos.eph > _param_com_low_eph.get()); + position_valid_but_low_accuracy = (_param_com_pos_low_eph.get() > FLT_EPSILON && lpos.eph > _param_com_pos_low_eph.get()); } if (position_valid_but_low_accuracy && _param_com_pos_low_act.get()) { diff --git a/src/modules/commander/HealthAndArmingChecks/checks/estimatorCheck.hpp b/src/modules/commander/HealthAndArmingChecks/checks/estimatorCheck.hpp index 700d9339e99..53c4359cb91 100644 --- a/src/modules/commander/HealthAndArmingChecks/checks/estimatorCheck.hpp +++ b/src/modules/commander/HealthAndArmingChecks/checks/estimatorCheck.hpp @@ -150,7 +150,7 @@ private: (ParamBool) _param_sys_has_gps, (ParamFloat) _param_com_pos_fs_eph, (ParamFloat) _param_com_vel_fs_evh, - (ParamFloat) _param_com_low_eph, + (ParamFloat) _param_com_pos_low_eph, (ParamInt) _param_com_pos_low_act ) }; diff --git a/src/modules/commander/HealthAndArmingChecks/checks/failureDetectorCheck.cpp b/src/modules/commander/HealthAndArmingChecks/checks/failureDetectorCheck.cpp index 0304ea1fbc1..fdeb76e42ef 100644 --- a/src/modules/commander/HealthAndArmingChecks/checks/failureDetectorCheck.cpp +++ b/src/modules/commander/HealthAndArmingChecks/checks/failureDetectorCheck.cpp @@ -44,36 +44,20 @@ void FailureDetectorChecks::checkAndReport(const Context &context, Report &repor // don't warn while the vehicle is tilted during calibration const bool report_attitude_failure = !context.status().calibration_enabled; - if (report_attitude_failure && fd_status.fd_roll) { + if (report_attitude_failure && fd_status.fd_tilt) { /* EVENT * @description - * The vehicle exceeded the maximum configured roll angle. + * The vehicle tilt deviated from the attitude setpoint, by more than the configured angle. * * - * This check can be configured via FD_FAIL_R parameter. + * This check can be configured via FD_TILT_ERROR parameter. * */ - reporter.armingCheckFailure(NavModes::All, health_component_t::system, events::ID("check_failure_detector_roll"), + reporter.armingCheckFailure(NavModes::All, health_component_t::system, events::ID("check_failure_detector_tilt"), events::Log::Critical, "Attitude failure detected"); if (reporter.mavlink_log_pub()) { - mavlink_log_critical(reporter.mavlink_log_pub(), "Preflight Fail: Attitude failure (roll)"); - } - - } else if (report_attitude_failure && fd_status.fd_pitch) { - /* EVENT - * @description - * The vehicle exceeded the maximum configured pitch angle. - * - * - * This check can be configured via FD_FAIL_P parameter. - * - */ - reporter.armingCheckFailure(NavModes::All, health_component_t::system, events::ID("check_failure_detector_pitch"), - events::Log::Critical, "Attitude failure detected"); - - if (reporter.mavlink_log_pub()) { - mavlink_log_critical(reporter.mavlink_log_pub(), "Preflight Fail: Attitude failure (pitch)"); + mavlink_log_critical(reporter.mavlink_log_pub(), "Preflight Fail: Attitude failure (tilt)"); } } @@ -103,7 +87,7 @@ void FailureDetectorChecks::checkAndReport(const Context &context, Report &repor } } - reporter.failsafeFlags().fd_critical_failure = fd_status.fd_roll || fd_status.fd_pitch || fd_status.fd_ext; + reporter.failsafeFlags().fd_critical_failure = fd_status.fd_tilt || fd_status.fd_ext; reporter.failsafeFlags().fd_alt_loss = fd_status.fd_alt; reporter.failsafeFlags().fd_imbalanced_prop = fd_status.fd_imbalanced_prop; diff --git a/src/modules/commander/HealthAndArmingChecks/checks/geofenceCheck.cpp b/src/modules/commander/HealthAndArmingChecks/checks/geofenceCheck.cpp index d6576d5424e..2c96a61edd1 100644 --- a/src/modules/commander/HealthAndArmingChecks/checks/geofenceCheck.cpp +++ b/src/modules/commander/HealthAndArmingChecks/checks/geofenceCheck.cpp @@ -61,7 +61,7 @@ void GeofenceChecks::checkAndReport(const Context &context, Report &reporter) events::Log::Error, "Geofence violation: exceeding maximum distance to Home"); if (reporter.mavlink_log_pub()) { - mavlink_log_critical(reporter.mavlink_log_pub(), "Geofence: exceeding maximum distance to Home"); + mavlink_log_critical(reporter.mavlink_log_pub(), "Geofence: exceeding maximum distance to Home\t"); } } @@ -77,7 +77,7 @@ void GeofenceChecks::checkAndReport(const Context &context, Report &reporter) events::Log::Error, "Geofence violation: exceeding maximum altitude above Home"); if (reporter.mavlink_log_pub()) { - mavlink_log_critical(reporter.mavlink_log_pub(), "Geofence: exceeding maximum altitude above Home"); + mavlink_log_critical(reporter.mavlink_log_pub(), "Geofence: exceeding maximum altitude above Home\t"); } } @@ -93,7 +93,7 @@ void GeofenceChecks::checkAndReport(const Context &context, Report &reporter) events::Log::Error, "Geofence violation: approaching or outside geofence"); if (reporter.mavlink_log_pub()) { - mavlink_log_critical(reporter.mavlink_log_pub(), "Geofence: approaching or outside geofence"); + mavlink_log_critical(reporter.mavlink_log_pub(), "Geofence: approaching or outside geofence\t"); } } } diff --git a/src/modules/commander/HealthAndArmingChecks/checks/opticalFlowCheck.cpp b/src/modules/commander/HealthAndArmingChecks/checks/opticalFlowCheck.cpp index c01c8cf5655..2960377bed7 100644 --- a/src/modules/commander/HealthAndArmingChecks/checks/opticalFlowCheck.cpp +++ b/src/modules/commander/HealthAndArmingChecks/checks/opticalFlowCheck.cpp @@ -39,11 +39,19 @@ void OpticalFlowCheck::checkAndReport(const Context &context, Report &reporter) return; } - const bool exists = _vehicle_optical_flow_sub.advertised(); + bool exists = false; + bool valid = false; + + for (auto &sub : _vehicle_optical_flow_subs) { + if (sub.advertised()) { + exists = true; + + vehicle_optical_flow_s flow_sens; + valid |= sub.copy(&flow_sens) && (hrt_elapsed_time(&flow_sens.timestamp) < 1_s); + } + } if (exists) { - vehicle_optical_flow_s flow_sens; - const bool valid = _vehicle_optical_flow_sub.copy(&flow_sens) && (hrt_elapsed_time(&flow_sens.timestamp) < 1_s); reporter.setIsPresent(health_component_t::optical_flow); if (!valid) { diff --git a/src/modules/commander/HealthAndArmingChecks/checks/opticalFlowCheck.hpp b/src/modules/commander/HealthAndArmingChecks/checks/opticalFlowCheck.hpp index 4eaa47f1f41..647b3ea949e 100644 --- a/src/modules/commander/HealthAndArmingChecks/checks/opticalFlowCheck.hpp +++ b/src/modules/commander/HealthAndArmingChecks/checks/opticalFlowCheck.hpp @@ -35,7 +35,7 @@ #include "../Common.hpp" -#include +#include #include class OpticalFlowCheck : public HealthAndArmingCheckBase @@ -47,7 +47,7 @@ public: void checkAndReport(const Context &context, Report &reporter) override; private: - uORB::Subscription _vehicle_optical_flow_sub{ORB_ID::vehicle_optical_flow}; + uORB::SubscriptionMultiArray _vehicle_optical_flow_subs{ORB_ID::vehicle_optical_flow}; DEFINE_PARAMETERS_CUSTOM_PARENT(HealthAndArmingCheckBase, (ParamInt) _param_sys_has_num_of diff --git a/src/modules/commander/HealthAndArmingChecks/checks/sdcardCheck.cpp b/src/modules/commander/HealthAndArmingChecks/checks/sdcardCheck.cpp index 695f87c5b25..efcfba45c1b 100644 --- a/src/modules/commander/HealthAndArmingChecks/checks/sdcardCheck.cpp +++ b/src/modules/commander/HealthAndArmingChecks/checks/sdcardCheck.cpp @@ -73,7 +73,7 @@ void SdCardChecks::checkAndReport(const Context &context, Report &reporter) #ifdef __PX4_NUTTX // Check for hardfault files - if (!_hardfault_checked_once && _param_com_arm_hardfault_check.get()) { + if (!_hardfault_checked_once && _param_com_arm_hflt_chk.get()) { _hardfault_checked_once = true; DIR *dp = opendir(PX4_STORAGEDIR); @@ -94,7 +94,7 @@ void SdCardChecks::checkAndReport(const Context &context, Report &reporter) } } - if (_hardfault_file_present && _param_com_arm_hardfault_check.get()) { + if (_hardfault_file_present && _param_com_arm_hflt_chk.get()) { /* EVENT * @description * The SD card contains crash dump files, service the vehicle before continuing to fly. @@ -118,7 +118,7 @@ void SdCardChecks::checkAndReport(const Context &context, Report &reporter) #if CONFIG_MODULES_TASK_WATCHDOG // Check for task watchdog dump files - if (!_watchdog_checked_once && _param_com_arm_hardfault_check.get()) { + if (!_watchdog_checked_once && _param_com_arm_hflt_chk.get()) { _watchdog_checked_once = true; DIR *wdp = opendir(PX4_STORAGEDIR "/task_watchdog"); @@ -144,7 +144,7 @@ void SdCardChecks::checkAndReport(const Context &context, Report &reporter) } } - if (_watchdog_file_present && _param_com_arm_hardfault_check.get()) { + if (_watchdog_file_present && _param_com_arm_hflt_chk.get()) { /* EVENT * @description * The SD card contains task watchdog dump files from a previous task starvation event. diff --git a/src/modules/commander/HealthAndArmingChecks/checks/sdcardCheck.hpp b/src/modules/commander/HealthAndArmingChecks/checks/sdcardCheck.hpp index 96fe1e306e3..a40233a4e0d 100644 --- a/src/modules/commander/HealthAndArmingChecks/checks/sdcardCheck.hpp +++ b/src/modules/commander/HealthAndArmingChecks/checks/sdcardCheck.hpp @@ -58,6 +58,6 @@ private: #endif // PX4_STORAGEDIR DEFINE_PARAMETERS_CUSTOM_PARENT(HealthAndArmingCheckBase, - (ParamBool) _param_com_arm_hardfault_check + (ParamBool) _param_com_arm_hflt_chk ) }; diff --git a/src/modules/commander/MulticopterThrowLaunch/MulticopterThrowLaunch.cpp b/src/modules/commander/MulticopterThrowLaunch/MulticopterThrowLaunch.cpp index 2915e5683e4..d9d6a2ce463 100644 --- a/src/modules/commander/MulticopterThrowLaunch/MulticopterThrowLaunch.cpp +++ b/src/modules/commander/MulticopterThrowLaunch/MulticopterThrowLaunch.cpp @@ -64,7 +64,7 @@ void MulticopterThrowLaunch::update(const bool armed) break; case ThrowLaunchState::ARMED: - if (_last_velocity.longerThan(_param_com_throw_min_speed.get())) { + if (_last_velocity.longerThan(_param_com_throw_speed.get())) { PX4_INFO("Throw detected, motors will start once falling"); _throw_launch_state = ThrowLaunchState::UNSAFE; } diff --git a/src/modules/commander/MulticopterThrowLaunch/MulticopterThrowLaunch.hpp b/src/modules/commander/MulticopterThrowLaunch/MulticopterThrowLaunch.hpp index cfcfe3fea31..9b5c1fcc3f4 100644 --- a/src/modules/commander/MulticopterThrowLaunch/MulticopterThrowLaunch.hpp +++ b/src/modules/commander/MulticopterThrowLaunch/MulticopterThrowLaunch.hpp @@ -86,6 +86,6 @@ private: DEFINE_PARAMETERS( (ParamBool) _param_com_throw_en, - (ParamFloat) _param_com_throw_min_speed + (ParamFloat) _param_com_throw_speed ); }; diff --git a/src/modules/commander/commander_params.yaml b/src/modules/commander/commander_params.yaml index 7ff0cbf87af..8015d6f4c3e 100644 --- a/src/modules/commander/commander_params.yaml +++ b/src/modules/commander/commander_params.yaml @@ -128,6 +128,7 @@ parameters: when SYS_HAS_NUM_GNSS=0), or when two receivers report positions inconsistent with their reported accuracy and SYS_HAS_NUM_GNSS=2 (otherwise warning only). The reported accuracy of each receiver is floored with EKF2_GPS_P_NOISE. + Return and Land are skipped if the failure clears during the COM_FAIL_ACT_T Hold. Any value above Warning also blocks arming. type: enum values: diff --git a/src/modules/commander/failsafe/failsafe.cpp b/src/modules/commander/failsafe/failsafe.cpp index a8658655548..db981057064 100644 --- a/src/modules/commander/failsafe/failsafe.cpp +++ b/src/modules/commander/failsafe/failsafe.cpp @@ -431,11 +431,13 @@ FailsafeBase::ActionOptions Failsafe::fromGnssLossActParam(int param_value) case gps_redundancy_failsafe_mode::Return_mode: options.action = Action::RTL; options.clear_condition = ClearCondition::OnModeChangeOrDisarm; + options.clear_during_delay = true; // a short loss only causes a Hold break; case gps_redundancy_failsafe_mode::Land_mode: options.action = Action::Land; options.clear_condition = ClearCondition::OnModeChangeOrDisarm; + options.clear_during_delay = true; // a short loss only causes a Hold break; case gps_redundancy_failsafe_mode::Terminate: @@ -729,7 +731,7 @@ void Failsafe::checkStateAndMode(const hrt_abstime &time_us, const State &state, } CHECK_FAILSAFE(status_flags, fd_imbalanced_prop, Action::Warn); - CHECK_FAILSAFE(status_flags, fd_motor_failure, fromActuatorFailureActParam(_param_com_actuator_failure_act.get())); + CHECK_FAILSAFE(status_flags, fd_motor_failure, fromActuatorFailureActParam(_param_com_act_fail_act.get())); CHECK_FAILSAFE(status_flags, gnss_lost, fromGnssLossActParam(_param_com_gnssloss_act.get())); diff --git a/src/modules/commander/failsafe/failsafe.h b/src/modules/commander/failsafe/failsafe.h index e804c5b8c76..9beeb58af3d 100644 --- a/src/modules/commander/failsafe/failsafe.h +++ b/src/modules/commander/failsafe/failsafe.h @@ -228,7 +228,7 @@ private: (ParamInt) _param_gf_action, (ParamFloat) _param_com_spoolup_time, (ParamInt) _param_cbrk_flightterm, - (ParamInt) _param_com_actuator_failure_act, + (ParamInt) _param_com_act_fail_act, (ParamInt) _param_com_low_bat_act, (ParamInt) _param_com_obl_rc_act, (ParamInt) _param_com_qc_act, diff --git a/src/modules/commander/failsafe/failsafe_test.cpp b/src/modules/commander/failsafe/failsafe_test.cpp index aed63a22820..669fe7afec5 100644 --- a/src/modules/commander/failsafe/failsafe_test.cpp +++ b/src/modules/commander/failsafe/failsafe_test.cpp @@ -1218,3 +1218,92 @@ TEST_F(FailsafeTest, BatteryFailsafeUsesLowBatActParam) EXPECT_EQ(selectedActionFor(4, kEmergency, false), FailsafeBase::Action::Terminate); EXPECT_EQ(selectedActionFor(6, kEmergency, false), FailsafeBase::Action::Terminate); } + +TEST_F(FailsafeTest, GnssLostRecoversDuringHoldDelay) +{ + int32_t com_gnssloss_act = 1; // Return + param_set(param_handle(px4::params::COM_GNSSLOSS_ACT), &com_gnssloss_act); + + Failsafe failsafe(nullptr); + + failsafe_flags_s failsafe_flags{}; + mode_util::getModeRequirements(vehicle_status_s::VEHICLE_TYPE_ROTARY_WING, failsafe_flags); + + FailsafeBase::State state{}; + state.armed = true; + state.user_intended_mode = vehicle_status_s::NAVIGATION_STATE_AUTO_MISSION; + state.vehicle_type = vehicle_status_s::VEHICLE_TYPE_ROTARY_WING; + hrt_abstime time = 5_s; + + failsafe.update(time, state, false, false, failsafe_flags); + ASSERT_EQ(failsafe.selectedAction(), FailsafeBase::Action::None); + + // GNSS lost -> Hold + time += 10_ms; + failsafe_flags.gnss_lost = true; + failsafe.update(time, state, false, false, failsafe_flags); + ASSERT_EQ(failsafe.selectedAction(), FailsafeBase::Action::Hold); + + // Recovers during the Hold delay -> back to the mission + time += 300_ms; + failsafe_flags.gnss_lost = false; + uint8_t updated_user_intented_mode = failsafe.update(time, state, false, false, failsafe_flags); + ASSERT_EQ(failsafe.selectedAction(), FailsafeBase::Action::None); + ASSERT_EQ(updated_user_intented_mode, state.user_intended_mode); + + // Lost for longer than the Hold delay -> RTL + time += 20_s; + failsafe_flags.gnss_lost = true; + failsafe.update(time, state, false, false, failsafe_flags); + ASSERT_EQ(failsafe.selectedAction(), FailsafeBase::Action::Hold); + time += 6_s; + failsafe.update(time, state, false, false, failsafe_flags); + ASSERT_EQ(failsafe.selectedAction(), FailsafeBase::Action::RTL); + + // Recovering now does not abort the RTL + time += 10_ms; + failsafe_flags.gnss_lost = false; + failsafe.update(time, state, false, false, failsafe_flags); + ASSERT_EQ(failsafe.selectedAction(), FailsafeBase::Action::RTL); +} + +TEST_F(FailsafeTest, GnssRecoveryDoesNotAbortRtlWhenAnotherFailsafeStartsADelay) +{ + int32_t com_gnssloss_act = 1; // Return + param_set(param_handle(px4::params::COM_GNSSLOSS_ACT), &com_gnssloss_act); + + Failsafe failsafe(nullptr); + + failsafe_flags_s failsafe_flags{}; + mode_util::getModeRequirements(vehicle_status_s::VEHICLE_TYPE_ROTARY_WING, failsafe_flags); + + FailsafeBase::State state{}; + state.armed = true; + state.user_intended_mode = vehicle_status_s::NAVIGATION_STATE_AUTO_MISSION; + state.vehicle_type = vehicle_status_s::VEHICLE_TYPE_ROTARY_WING; + hrt_abstime time = 5_s; + + failsafe.update(time, state, false, false, failsafe_flags); + ASSERT_EQ(failsafe.selectedAction(), FailsafeBase::Action::None); + + // GNSS lost for longer than the Hold delay -> RTL + time += 10_ms; + failsafe_flags.gnss_lost = true; + failsafe.update(time, state, false, false, failsafe_flags); + ASSERT_EQ(failsafe.selectedAction(), FailsafeBase::Action::Hold); + time += 6_s; + failsafe.update(time, state, false, false, failsafe_flags); + ASSERT_EQ(failsafe.selectedAction(), FailsafeBase::Action::RTL); + + // Let the start delay refill, so that a new failsafe starts a delay again + time += 8_s; + failsafe.update(time, state, false, false, failsafe_flags); + ASSERT_EQ(failsafe.selectedAction(), FailsafeBase::Action::RTL); + + // Another failsafe starts a delay on the same update as GNSS recovers: the RTL continues + time += 10_ms; + failsafe_flags.navigator_failure = true; + failsafe_flags.gnss_lost = false; + failsafe.update(time, state, false, false, failsafe_flags); + ASSERT_EQ(failsafe.selectedAction(), FailsafeBase::Action::RTL); +} diff --git a/src/modules/commander/failsafe/framework.cpp b/src/modules/commander/failsafe/framework.cpp index 53e9b6586aa..a0661c4b85e 100644 --- a/src/modules/commander/failsafe/framework.cpp +++ b/src/modules/commander/failsafe/framework.cpp @@ -404,7 +404,12 @@ void FailsafeBase::removeAction(ActionOptions &action) const // clear_condition to avoid triggering a failsafe after deferring is disabled. const bool remove_while_deferring = _defer_failsafes && action.can_be_deferred; - if (action.clear_condition == ClearCondition::WhenConditionClears || remove_while_deferring) { + // The action did not start yet (still in the delayed Hold), so recovering is allowed. + // _current_delay is shared, so also check that no action beyond Hold is already running. + const bool remove_during_delay = action.clear_during_delay && _current_delay > 0 + && _selected_action <= Action::Hold; + + if (action.clear_condition == ClearCondition::WhenConditionClears || remove_while_deferring || remove_during_delay) { // Remove action PX4_DEBUG("Caller %i: state changed to valid, removing action", action.id); action.setInvalid(); diff --git a/src/modules/commander/failsafe/framework.h b/src/modules/commander/failsafe/framework.h index 7c1c8f01ec1..23be7df1637 100644 --- a/src/modules/commander/failsafe/framework.h +++ b/src/modules/commander/failsafe/framework.h @@ -195,6 +195,7 @@ protected: Cause cause{Cause::Generic}; UserTakeoverAllowed allow_user_takeover{UserTakeoverAllowed::Auto}; bool can_be_deferred{true}; + bool clear_during_delay{false}; ///< also clear if the condition clears during the Hold delay (COM_FAIL_ACT_T) bool state_failure{false}; ///< used when the clear_condition isn't set to clear immediately bool activated{false}; ///< true if checkFailsafe was called during current update diff --git a/src/modules/commander/failure_detector/CMakeLists.txt b/src/modules/commander/failure_detector/CMakeLists.txt index d42c0993b59..968f69ef423 100644 --- a/src/modules/commander/failure_detector/CMakeLists.txt +++ b/src/modules/commander/failure_detector/CMakeLists.txt @@ -40,3 +40,7 @@ set_property(GLOBAL APPEND PROPERTY PX4_MODULE_CONFIG_FILES ${CMAKE_CURRENT_SOUR px4_add_functional_gtest(SRC FailureDetectorAltitudeLossTest.cpp LINKLIBS failure_detector hysteresis ) + +px4_add_functional_gtest(SRC FailureDetectorTiltTest.cpp + LINKLIBS failure_detector hysteresis +) diff --git a/src/modules/commander/failure_detector/FailureDetector.cpp b/src/modules/commander/failure_detector/FailureDetector.cpp index a8a7555316a..785feb1b73c 100644 --- a/src/modules/commander/failure_detector/FailureDetector.cpp +++ b/src/modules/commander/failure_detector/FailureDetector.cpp @@ -65,8 +65,8 @@ bool FailureDetector::update(const vehicle_status_s &vehicle_status, const vehic } } else { - _failure_detector_status.flags.roll = false; - _failure_detector_status.flags.pitch = false; + _failure_detector_status.flags.tilt = false; + _tilt_failure_hysteresis.set_state_and_update(false, hrt_absolute_time()); _failure_detector_status.flags.alt = false; _failure_detector_status.flags.ext = false; // Reset altitude loss state so it reinitialises cleanly when altitude control re-engages. @@ -86,8 +86,7 @@ void FailureDetector::publishStatus(bool esc_arm_status, uint16_t motor_failure_ const uint16_t injected_motor_failure_mask = _injected_motor_masks.failure_mask; failure_detector_status_s failure_detector_status{}; - failure_detector_status.fd_roll = _failure_detector_status.flags.roll; - failure_detector_status.fd_pitch = _failure_detector_status.flags.pitch; + failure_detector_status.fd_tilt = _failure_detector_status.flags.tilt; failure_detector_status.fd_alt = _failure_detector_status.flags.alt; failure_detector_status.fd_ext = _failure_detector_status.flags.ext; failure_detector_status.fd_arm_escs = esc_arm_status || (motor_failure_mask != 0); @@ -107,48 +106,55 @@ void FailureDetector::updateAttitudeStatus(const vehicle_status_s &vehicle_statu if (_vehicle_attitude_sub.update(&attitude)) { - const matrix::Eulerf euler(matrix::Quatf(attitude.q)); - float roll(euler.phi()); - float pitch(euler.theta()); + matrix::Quatf q(attitude.q); - // special handling for tailsitter - if (vehicle_status.is_vtol_tailsitter) { - if (vehicle_status.in_transition_mode) { - // disable attitude check during tailsitter transition - roll = 0.f; - pitch = 0.f; - - } else if (vehicle_status.vehicle_type == vehicle_status_s::VEHICLE_TYPE_FIXED_WING) { - // in FW flight rotate the attitude by 90° around pitch (level FW flight = 0° pitch) - const matrix::Eulerf euler_rotated = matrix::Eulerf(matrix::Quatf(attitude.q) * matrix::Quatf(matrix::Eulerf(0.f, - M_PI_2_F, 0.f))); - roll = euler_rotated.phi(); - pitch = euler_rotated.theta(); - } + if (vehicle_status.is_vtol_tailsitter && !vehicle_status.in_transition_mode + && vehicle_status.vehicle_type == vehicle_status_s::VEHICLE_TYPE_FIXED_WING) { + // tailsitter FW attitude setpoints are in the FW frame, rotated by 90° around pitch + q = q * matrix::Quatf(matrix::Eulerf(0.f, M_PI_2_F, 0.f)); } - const float max_roll_deg = _param_fd_fail_r.get(); - const float max_pitch_deg = _param_fd_fail_p.get(); - const float max_roll(fabsf(math::radians(max_roll_deg))); - const float max_pitch(fabsf(math::radians(max_pitch_deg))); + vehicle_attitude_setpoint_s attitude_setpoint{}; + _vehicle_attitude_setpoint_sub.copy(&attitude_setpoint); + // level unless there is a recent attitude setpoint, e.g. on rovers + matrix::Vector3f z_setpoint(0.f, 0.f, 1.f); - const bool roll_status = (max_roll > FLT_EPSILON) && (fabsf(roll) > max_roll); - const bool pitch_status = (max_pitch > FLT_EPSILON) && (fabsf(pitch) > max_pitch); + if (attitude.timestamp < attitude_setpoint.timestamp + 500_ms) { + z_setpoint = matrix::Quatf(attitude_setpoint.q_d).dcm_z(); + } - hrt_abstime now = hrt_absolute_time(); + const float max_tilt_error_deg = _param_fd_tilt_error.get(); + const float tilt_error = acosf(math::constrain(q.dcm_z().dot(z_setpoint), -1.f, 1.f)); + const bool vtol_skipped_back_transition = checkVtolSkippedBackTransition(attitude.timestamp); + const bool tilt_status = (max_tilt_error_deg > 0.f) && !vtol_skipped_back_transition + && (tilt_error > math::radians(max_tilt_error_deg)); - // Update hysteresis - _roll_failure_hysteresis.set_hysteresis_time_from(false, (hrt_abstime)(1_s * _param_fd_fail_r_ttri.get())); - _pitch_failure_hysteresis.set_hysteresis_time_from(false, (hrt_abstime)(1_s * _param_fd_fail_p_ttri.get())); - _roll_failure_hysteresis.set_state_and_update(roll_status, now); - _pitch_failure_hysteresis.set_state_and_update(pitch_status, now); - - // Update status - _failure_detector_status.flags.roll = _roll_failure_hysteresis.get_state(); - _failure_detector_status.flags.pitch = _pitch_failure_hysteresis.get_state(); + _tilt_failure_hysteresis.set_hysteresis_time_from(false, (hrt_abstime)(1_s * _param_fd_tilt_error_t.get())); + _tilt_failure_hysteresis.set_state_and_update(tilt_status, attitude.timestamp); + _failure_detector_status.flags.tilt = _tilt_failure_hysteresis.get_state(); } } +// True for 5 s after a VTOL switched to multicopter without back-transition, i.e. a quad-chute or an aborted +// front transition, while it recovers from fixed-wing flight with a large tilt error +bool FailureDetector::checkVtolSkippedBackTransition(hrt_abstime now) +{ + vtol_vehicle_status_s vtol_vehicle_status; + + if (_vtol_vehicle_status_sub.update(&vtol_vehicle_status)) { + const bool from_fixed_wing = (_vtol_state_prev == vtol_vehicle_status_s::VEHICLE_VTOL_STATE_FW) + || (_vtol_state_prev == vtol_vehicle_status_s::VEHICLE_VTOL_STATE_TRANSITION_TO_FW); + + if (from_fixed_wing && (vtol_vehicle_status.vehicle_vtol_state == vtol_vehicle_status_s::VEHICLE_VTOL_STATE_MC)) { + _vtol_skipped_back_transition_timestamp = vtol_vehicle_status.timestamp; + } + + _vtol_state_prev = vtol_vehicle_status.vehicle_vtol_state; + } + + return (_vtol_skipped_back_transition_timestamp != 0) && (now < _vtol_skipped_back_transition_timestamp + 5_s); +} + void FailureDetector::updateAltitudeStatus(const vehicle_status_s &vehicle_status, const vehicle_control_mode_s &vehicle_control_mode) { @@ -219,7 +225,7 @@ void FailureDetector::updateAltitudeStatus(const vehicle_status_s &vehicle_statu if (reference_valid) { const bool is_below_threshold = (lpos.z - _alt_loss_ref_z) > threshold; - _alt_loss_hysteresis.set_hysteresis_time_from(false, (hrt_abstime)(1_s * _param_fd_alt_loss_ttri.get())); + _alt_loss_hysteresis.set_hysteresis_time_from(false, (hrt_abstime)(1_s * _param_fd_alt_loss_t.get())); _alt_loss_hysteresis.set_state_and_update(is_below_threshold, now); } else { diff --git a/src/modules/commander/failure_detector/FailureDetector.hpp b/src/modules/commander/failure_detector/FailureDetector.hpp index cbc67615812..fd9fb633dcb 100644 --- a/src/modules/commander/failure_detector/FailureDetector.hpp +++ b/src/modules/commander/failure_detector/FailureDetector.hpp @@ -64,13 +64,13 @@ #include #include #include +#include using namespace time_literals; union failure_detector_status_u { struct { - uint16_t roll : 1; - uint16_t pitch : 1; + uint16_t tilt : 1; uint16_t alt : 1; uint16_t ext : 1; uint16_t battery : 1; @@ -101,8 +101,10 @@ private: failure_detector_status_u _failure_detector_status{}; - systemlib::Hysteresis _roll_failure_hysteresis{false}; - systemlib::Hysteresis _pitch_failure_hysteresis{false}; + systemlib::Hysteresis _tilt_failure_hysteresis{false}; + bool checkVtolSkippedBackTransition(hrt_abstime now); + uint8_t _vtol_state_prev{vtol_vehicle_status_s::VEHICLE_VTOL_STATE_UNDEFINED}; + hrt_abstime _vtol_skipped_back_transition_timestamp{0}; // last switch to multicopter without back-transition, e.g. quad-chute systemlib::Hysteresis _alt_loss_hysteresis{false}; systemlib::Hysteresis _ext_ats_failure_hysteresis{false}; @@ -119,11 +121,13 @@ private: uORB::Subscription _vehicle_attitude_sub{ORB_ID(vehicle_attitude)}; + uORB::Subscription _vehicle_attitude_setpoint_sub{ORB_ID(vehicle_attitude_setpoint)}; uORB::Subscription _vehicle_local_position_sub{ORB_ID(vehicle_local_position)}; uORB::Subscription _vehicle_local_position_setpoint_sub{ORB_ID(vehicle_local_position_setpoint)}; uORB::Subscription _pwm_input_sub{ORB_ID(pwm_input)}; uORB::Subscription _sensor_selection_sub{ORB_ID(sensor_selection)}; uORB::Subscription _vehicle_imu_status_sub{ORB_ID(vehicle_imu_status)}; + uORB::Subscription _vtol_vehicle_status_sub{ORB_ID(vtol_vehicle_status)}; uORB::Publication _failure_detector_status_pub{ORB_ID(failure_detector_status)}; @@ -131,14 +135,12 @@ private: failure_injection::MotorFailureMasks _injected_motor_masks{}; DEFINE_PARAMETERS( - (ParamInt) _param_fd_fail_p, - (ParamInt) _param_fd_fail_r, - (ParamFloat) _param_fd_fail_r_ttri, - (ParamFloat) _param_fd_fail_p_ttri, + (ParamFloat) _param_fd_tilt_error, + (ParamFloat) _param_fd_tilt_error_t, (ParamBool) _param_fd_ext_ats_en, (ParamInt) _param_fd_ext_ats_trig, (ParamInt) _param_fd_imb_prop_thr, (ParamFloat) _param_fd_alt_loss, - (ParamFloat) _param_fd_alt_loss_ttri + (ParamFloat) _param_fd_alt_loss_t ) }; diff --git a/src/modules/commander/failure_detector/FailureDetectorAltitudeLossTest.cpp b/src/modules/commander/failure_detector/FailureDetectorAltitudeLossTest.cpp index dcbd641c9f4..0c07755f899 100644 --- a/src/modules/commander/failure_detector/FailureDetectorAltitudeLossTest.cpp +++ b/src/modules/commander/failure_detector/FailureDetectorAltitudeLossTest.cpp @@ -43,21 +43,23 @@ using namespace time_literals; -class FailureDetectorAltitudeLossTest : public ::testing::Test +// The fixture is the detector's parameter parent, like Commander in flight +class FailureDetectorAltitudeLossTest : public ::testing::Test, public ModuleParams { public: + FailureDetectorAltitudeLossTest() : ModuleParams(nullptr) {} + void SetUp() override { param_control_autosave(false); + setParams(5.f, 0.f); + } - // FD_ALT_LOSS = 5m, FD_ALT_LOSS_T = 0s - param_t param = param_handle(px4::params::FD_ALT_LOSS); - float threshold = 5.f; - param_set(param, &threshold); - - param = param_handle(px4::params::FD_ALT_LOSS_T); - float ttri = 0.f; - param_set(param, &ttri); + void setParams(float threshold, float trigger_time_s) + { + param_set(param_handle(px4::params::FD_ALT_LOSS), &threshold); + param_set(param_handle(px4::params::FD_ALT_LOSS_T), &trigger_time_s); + updateParams(); } // Publish position and setpoint, then run the detector. Returns the alt flag state. @@ -110,7 +112,7 @@ public: } private: - FailureDetector _fd{nullptr}; + FailureDetector _fd{this}; hrt_abstime _timestamp{1_s}; uORB::Publication _lpos_pub{ORB_ID(vehicle_local_position)}; @@ -119,9 +121,7 @@ private: TEST_F(FailureDetectorAltitudeLossTest, NoTriggerWhenDisabled) { - param_t param = param_handle(px4::params::FD_ALT_LOSS); - float threshold = 0.f; - param_set(param, &threshold); + setParams(0.f, 0.f); EXPECT_FALSE(update(-90.f, -100.f)); } diff --git a/src/modules/commander/failure_detector/FailureDetectorTiltTest.cpp b/src/modules/commander/failure_detector/FailureDetectorTiltTest.cpp new file mode 100644 index 00000000000..279514f8d3f --- /dev/null +++ b/src/modules/commander/failure_detector/FailureDetectorTiltTest.cpp @@ -0,0 +1,320 @@ +/**************************************************************************** + * + * Copyright (c) 2026 PX4 Development Team. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name PX4 nor the names of its contributors may be + * used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + * + ****************************************************************************/ + +#include + +#include "FailureDetector.hpp" + +#include +#include +#include +#include +#include + +// to run: make tests TESTFILTER=FailureDetectorTilt + +using namespace time_literals; +using matrix::AxisAnglef; +using matrix::Eulerf; +using matrix::Quatf; +using matrix::Vector3f; + +static constexpr float kMaxTiltErrorDeg = 60.f; + +// Tilt by angle around a horizontal axis, direction 0° tilts around the x-axis (roll), 90° around the y-axis (pitch) +static Quatf tilt(float angle_deg, float direction_deg = 0.f) +{ + const float direction = math::radians(direction_deg); + return Quatf(AxisAnglef(Vector3f(cosf(direction), sinf(direction), 0.f), math::radians(angle_deg))); +} + +// Tailsitter attitude in the multicopter body frame from the attitude in the fixed-wing frame +static Quatf tailsitterMcFromFw(const Quatf &q_fw) +{ + return q_fw * Quatf(Eulerf(0.f, M_PI_2_F, 0.f)).inversed(); +} + +// The fixture is the detector's parameter parent, like Commander in flight +class FailureDetectorTiltTest : public ::testing::Test, public ModuleParams +{ +public: + FailureDetectorTiltTest() : ModuleParams(nullptr) {} + + void SetUp() override + { + param_control_autosave(false); + setParams(kMaxTiltErrorDeg, 0.1f); + _status.vehicle_type = vehicle_status_s::VEHICLE_TYPE_ROTARY_WING; + } + + void setParams(float max_tilt_error_deg, float trigger_time_s) + { + param_set(param_handle(px4::params::FD_TILT_ERROR), &max_tilt_error_deg); + param_set(param_handle(px4::params::FD_TILT_ERROR_T), &trigger_time_s); + updateParams(); + } + + // Publish attitude and setpoint, then run the detector. Returns the tilt flag state. + // setpoint_age is the age of the attitude setpoint relative to the attitude sample. + bool update(const Quatf &q, const Quatf &q_sp = Quatf(), hrt_abstime setpoint_age = 0, bool attitude_control = true) + { + // The trigger time runs on the attitude timestamp + _timestamp += 10_ms; + + vehicle_attitude_setpoint_s attitude_setpoint{}; + attitude_setpoint.timestamp = _timestamp - setpoint_age; + q_sp.copyTo(attitude_setpoint.q_d); + _attitude_setpoint_pub.publish(attitude_setpoint); + + vehicle_attitude_s attitude{}; + attitude.timestamp = _timestamp; + q.copyTo(attitude.q); + _attitude_pub.publish(attitude); + + vehicle_control_mode_s control_mode{}; + control_mode.flag_control_attitude_enabled = attitude_control; + + _fd.update(_status, control_mode); + return _fd.getStatus().flags.tilt; + } + + // Keep the condition for longer than the 0.1s trigger time + bool updateAfterTriggerTime(const Quatf &q, const Quatf &q_sp = Quatf(), hrt_abstime setpoint_age = 0) + { + update(q, q_sp, setpoint_age); + advance(150_ms); + return update(q, q_sp, setpoint_age); + } + + void advance(hrt_abstime dt) { _timestamp += dt; } + + // Publish the VTOL state and run the detector to see it + void setVtolState(uint8_t vtol_state) + { + vtol_vehicle_status_s vtol_vehicle_status{}; + vtol_vehicle_status.timestamp = _timestamp; + vtol_vehicle_status.vehicle_vtol_state = vtol_state; + _vtol_vehicle_status_pub.publish(vtol_vehicle_status); + update(Quatf()); + } + + void resetDetector() { update(Quatf(), Quatf(), 0, false); } + + vehicle_status_s _status{}; + +private: + FailureDetector _fd{this}; + hrt_abstime _timestamp{10_s}; + + uORB::Publication _attitude_pub{ORB_ID(vehicle_attitude)}; + uORB::Publication _attitude_setpoint_pub{ORB_ID(vehicle_attitude_setpoint)}; + uORB::Publication _vtol_vehicle_status_pub{ORB_ID(vtol_vehicle_status)}; +}; + +TEST_F(FailureDetectorTiltTest, NoTriggerWhenLevel) +{ + EXPECT_FALSE(updateAfterTriggerTime(Quatf())); +} + +TEST_F(FailureDetectorTiltTest, ThresholdInAllDirections) +{ + for (float direction_deg = 0.f; direction_deg < 360.f; direction_deg += 45.f) { + SCOPED_TRACE(direction_deg); + resetDetector(); + EXPECT_FALSE(updateAfterTriggerTime(tilt(kMaxTiltErrorDeg - 1.f, direction_deg))); + resetDetector(); + EXPECT_TRUE(updateAfterTriggerTime(tilt(kMaxTiltErrorDeg + 1.f, direction_deg))); + } +} + +TEST_F(FailureDetectorTiltTest, CombinedRollAndPitch) +{ + // 45° roll and 45° pitch are each below the threshold but the tilt is ~60.0° + EXPECT_FALSE(updateAfterTriggerTime(Quatf(Eulerf(math::radians(44.f), math::radians(44.f), 0.f)))); + resetDetector(); + EXPECT_TRUE(updateAfterTriggerTime(Quatf(Eulerf(math::radians(46.f), math::radians(46.f), 0.f)))); +} + +TEST_F(FailureDetectorTiltTest, TriggerUpsideDown) +{ + EXPECT_TRUE(updateAfterTriggerTime(tilt(180.f))); +} + +TEST_F(FailureDetectorTiltTest, YawErrorIgnored) +{ + EXPECT_FALSE(updateAfterTriggerTime(Quatf(Eulerf(0.f, 0.f, M_PI_F)), Quatf())); + EXPECT_FALSE(updateAfterTriggerTime(Quatf(Eulerf(math::radians(30.f), 0.f, M_PI_F)), + Quatf(Eulerf(math::radians(30.f), 0.f, 0.f)))); +} + +TEST_F(FailureDetectorTiltTest, ErrorRelativeToSetpoint) +{ + // Following a setpoint tilted beyond the threshold is fine + EXPECT_FALSE(updateAfterTriggerTime(tilt(80.f), tilt(80.f))); + EXPECT_FALSE(updateAfterTriggerTime(tilt(130.f), tilt(80.f))); + EXPECT_FALSE(updateAfterTriggerTime(tilt(80.f + kMaxTiltErrorDeg - 1.f), tilt(80.f))); + resetDetector(); + EXPECT_TRUE(updateAfterTriggerTime(tilt(80.f + kMaxTiltErrorDeg + 1.f), tilt(80.f))); + + // Staying level while a tilt is commanded is an error as well + resetDetector(); + EXPECT_FALSE(updateAfterTriggerTime(Quatf(), tilt(kMaxTiltErrorDeg - 1.f, 90.f))); + resetDetector(); + EXPECT_TRUE(updateAfterTriggerTime(Quatf(), tilt(kMaxTiltErrorDeg + 1.f, 90.f))); + + // Same tilt angle in a different direction: 50° roll vs 50° pitch is a ~65.6° error + resetDetector(); + EXPECT_TRUE(updateAfterTriggerTime(tilt(50.f, 0.f), tilt(50.f, 90.f))); +} + +TEST_F(FailureDetectorTiltTest, StaleSetpointFallsBackToLevel) +{ + EXPECT_FALSE(updateAfterTriggerTime(tilt(80.f), tilt(80.f), 400_ms)); + EXPECT_TRUE(updateAfterTriggerTime(tilt(80.f), tilt(80.f), 600_ms)); + resetDetector(); + EXPECT_FALSE(updateAfterTriggerTime(tilt(kMaxTiltErrorDeg - 1.f), tilt(80.f), 600_ms)); +} + +TEST_F(FailureDetectorTiltTest, NoTriggerWhenDisabled) +{ + setParams(-1.f, 0.1f); + EXPECT_FALSE(updateAfterTriggerTime(tilt(180.f))); + + // 0 also disables for backwards compatibility + setParams(0.f, 0.1f); + EXPECT_FALSE(updateAfterTriggerTime(tilt(180.f))); +} + +TEST_F(FailureDetectorTiltTest, TriggerOnlyAfterTriggerTime) +{ + // Each update advances the time by 10ms + setParams(kMaxTiltErrorDeg, 0.5f); + EXPECT_FALSE(update(tilt(90.f))); // t = 0 + advance(480_ms); + EXPECT_FALSE(update(tilt(90.f))); // t = 490ms + EXPECT_TRUE(update(tilt(90.f))); // t = 500ms +} + +TEST_F(FailureDetectorTiltTest, TriggerTimeRestartsWhenErrorRecovers) +{ + setParams(kMaxTiltErrorDeg, 0.5f); + EXPECT_FALSE(update(tilt(90.f))); // t = 0 + advance(470_ms); + EXPECT_FALSE(update(tilt(90.f))); // t = 480ms + EXPECT_FALSE(update(tilt(kMaxTiltErrorDeg - 1.f))); // t = 490ms, short recovery + EXPECT_FALSE(update(tilt(90.f))); // t = 500ms, trigger time restarts + advance(480_ms); + EXPECT_FALSE(update(tilt(90.f))); // t = 990ms + EXPECT_TRUE(update(tilt(90.f))); // t = 1000ms +} + +TEST_F(FailureDetectorTiltTest, ClearsImmediatelyWhenErrorRecovers) +{ + EXPECT_TRUE(updateAfterTriggerTime(tilt(90.f))); + EXPECT_FALSE(update(tilt(kMaxTiltErrorDeg - 1.f))); +} + +TEST_F(FailureDetectorTiltTest, ResetWithoutAttitudeControl) +{ + setParams(kMaxTiltErrorDeg, 0.5f); + EXPECT_FALSE(update(tilt(90.f))); // t = 0 + advance(470_ms); + EXPECT_FALSE(update(tilt(90.f))); // t = 480ms + EXPECT_FALSE(update(tilt(90.f), Quatf(), 0, false)); // t = 490ms, e.g. Acro, pending trigger is dropped + EXPECT_FALSE(update(tilt(90.f))); // t = 500ms, trigger time restarts + advance(480_ms); + EXPECT_FALSE(update(tilt(90.f))); // t = 990ms + EXPECT_TRUE(update(tilt(90.f))); // t = 1000ms + EXPECT_FALSE(update(tilt(90.f), Quatf(), 0, false)); // flag clears when attitude control is off +} + +TEST_F(FailureDetectorTiltTest, TailsitterFixedWingSetpointInFixedWingFrame) +{ + _status.is_vtol = true; + _status.is_vtol_tailsitter = true; + _status.vehicle_type = vehicle_status_s::VEHICLE_TYPE_FIXED_WING; + + // Level fixed-wing flight is pitched by 90° in the multicopter frame + EXPECT_FALSE(updateAfterTriggerTime(tailsitterMcFromFw(Quatf()), Quatf())); + EXPECT_FALSE(updateAfterTriggerTime(tailsitterMcFromFw(tilt(kMaxTiltErrorDeg - 1.f)), Quatf())); + resetDetector(); + EXPECT_TRUE(updateAfterTriggerTime(tailsitterMcFromFw(tilt(kMaxTiltErrorDeg + 1.f)), Quatf())); + resetDetector(); + EXPECT_TRUE(updateAfterTriggerTime(tailsitterMcFromFw(tilt(kMaxTiltErrorDeg + 1.f, 90.f)), Quatf())); +} + +TEST_F(FailureDetectorTiltTest, TailsitterTransitionSetpointInMulticopterFrame) +{ + _status.is_vtol = true; + _status.is_vtol_tailsitter = true; + _status.in_transition_mode = true; + const Quatf q_transition = tailsitterMcFromFw(tilt(20.f, 90.f)); // 70° from hover towards fixed-wing + + for (const uint8_t vehicle_type : {vehicle_status_s::VEHICLE_TYPE_ROTARY_WING, vehicle_status_s::VEHICLE_TYPE_FIXED_WING}) { + SCOPED_TRACE(static_cast(vehicle_type)); + _status.vehicle_type = vehicle_type; + resetDetector(); + EXPECT_FALSE(updateAfterTriggerTime(q_transition, q_transition)); + EXPECT_TRUE(updateAfterTriggerTime(Quatf(), q_transition)); + } +} + +TEST_F(FailureDetectorTiltTest, PausedAfterSkippedBackTransition) +{ + _status.is_vtol = true; + setVtolState(vtol_vehicle_status_s::VEHICLE_VTOL_STATE_FW); + + // Quad-chute: recovering from fixed-wing flight in multicopter mode + setVtolState(vtol_vehicle_status_s::VEHICLE_VTOL_STATE_MC); // t = 0 + EXPECT_FALSE(update(tilt(90.f))); // t = 10ms + advance(4980_ms); + EXPECT_FALSE(update(tilt(90.f))); // t = 5000ms, pause over, trigger time starts + advance(80_ms); + EXPECT_FALSE(update(tilt(90.f))); // t = 5090ms + EXPECT_TRUE(update(tilt(90.f))); // t = 5100ms + + // Aborted front transition + setVtolState(vtol_vehicle_status_s::VEHICLE_VTOL_STATE_TRANSITION_TO_FW); + resetDetector(); + setVtolState(vtol_vehicle_status_s::VEHICLE_VTOL_STATE_MC); + EXPECT_FALSE(updateAfterTriggerTime(tilt(90.f))); +} + +TEST_F(FailureDetectorTiltTest, NotPausedAfterBackTransition) +{ + _status.is_vtol = true; + setVtolState(vtol_vehicle_status_s::VEHICLE_VTOL_STATE_FW); + setVtolState(vtol_vehicle_status_s::VEHICLE_VTOL_STATE_TRANSITION_TO_MC); + setVtolState(vtol_vehicle_status_s::VEHICLE_VTOL_STATE_MC); + EXPECT_TRUE(updateAfterTriggerTime(tilt(90.f))); +} diff --git a/src/modules/commander/failure_detector/failure_detector_params.yaml b/src/modules/commander/failure_detector/failure_detector_params.yaml index 7448bd77202..6f9c37969da 100644 --- a/src/modules/commander/failure_detector/failure_detector_params.yaml +++ b/src/modules/commander/failure_detector/failure_detector_params.yaml @@ -2,56 +2,31 @@ module_name: failure_detector parameters: - group: Failure Detector definitions: - FD_FAIL_R: + FD_TILT_ERROR: description: - short: FailureDetector Max Roll + short: FailureDetector Max Tilt Error long: |- - Maximum roll angle before FailureDetector triggers the attitude_failure flag. + Maximum angle between the vehicle tilt and the attitude setpoint tilt before FailureDetector triggers the attitude_failure flag. + Without a recent attitude setpoint, e.g. on rovers, the tilt from level is checked instead. The flag triggers flight termination (if @CBRK_FLIGHTTERM = 0), which sets outputs to their failsafe values. On takeoff the flag triggers lockdown (irrespective of @CBRK_FLIGHTTERM), which disarms motors but does not set outputs to failsafe values. + The check is paused for the first 5 s after a VTOL quad-chute or aborted front transition. - Setting this parameter to 0 disables the check - type: int32 + Set to -1 to disable. + type: float default: 60 - min: 0 + min: -1 max: 180 unit: deg - FD_FAIL_P: + decimal: 0 + FD_TILT_ERROR_T: description: - short: FailureDetector Max Pitch - long: |- - Maximum pitch angle before FailureDetector triggers the attitude_failure flag. - The flag triggers flight termination (if @CBRK_FLIGHTTERM = 0), - which sets outputs to their failsafe values. - On takeoff the flag triggers lockdown (irrespective of @CBRK_FLIGHTTERM), - which disarms motors but does not set outputs to failsafe values. - - Setting this parameter to 0 disables the check - type: int32 - default: 60 - min: 0 - max: 180 - unit: deg - FD_FAIL_R_TTRI: - description: - short: Roll failure trigger time - long: Seconds (decimal) that roll has to exceed FD_FAIL_R before being considered - as a failure. + short: Tilt failure trigger time + long: Seconds (decimal) that the tilt error has to exceed FD_TILT_ERROR before being considered as a failure. type: float - default: 0.3 - unit: s - min: 0.02 - max: 5 - decimal: 2 - FD_FAIL_P_TTRI: - description: - short: Pitch failure trigger time - long: Seconds (decimal) that pitch has to exceed FD_FAIL_P before being considered - as a failure. - type: float - default: 0.3 + default: 1.0 unit: s min: 0.02 max: 5 diff --git a/src/modules/control_allocator/ControlAllocator.cpp b/src/modules/control_allocator/ControlAllocator.cpp index 82bbb624fae..f2bf1b82eb3 100644 --- a/src/modules/control_allocator/ControlAllocator.cpp +++ b/src/modules/control_allocator/ControlAllocator.cpp @@ -528,7 +528,7 @@ ControlAllocator::update_effectiveness_matrix_if_needed(EffectivenessUpdateReaso // Failure recovery: a forward propeller driven in reverse makes only a fraction of its forward thrust minimum[selected_matrix](actuator_idx_matrix[selected_matrix]) = -_param_ca_rev_thr_frac.get(); - } else if (_param_r_rev.get() & (1u << actuator_type_idx)) { + } else if (_param_ca_r_rev.get() & (1u << actuator_type_idx)) { // Statically reversible thruster (symmetric): full reverse authority minimum[selected_matrix](actuator_idx_matrix[selected_matrix]) = -1.f; @@ -719,7 +719,7 @@ ControlAllocator::publish_control_allocator_status(int matrix_index) float ControlAllocator::get_ice_shedding_output(hrt_abstime now) { - const float period_sec = _param_ice_shedding_period.get(); + const float period_sec = _param_ca_ice_period.get(); const bool feature_disabled_by_param = period_sec <= FLT_EPSILON; const bool in_forward_flight = _actuator_effectiveness->getFlightPhase() == ActuatorEffectiveness::FlightPhase::FORWARD_FLIGHT; @@ -756,7 +756,7 @@ ControlAllocator::publish_actuator_controls() actuator_servos.timestamp = actuator_motors.timestamp; actuator_servos.timestamp_sample = _timestamp_sample; - actuator_motors.reversible_flags = _param_r_rev.get() | _runtime_reversible_bitmask; + actuator_motors.reversible_flags = _param_ca_r_rev.get() | _runtime_reversible_bitmask; int actuator_idx = 0; int actuator_idx_matrix[ActuatorEffectiveness::MAX_NUM_MATRICES] {}; diff --git a/src/modules/control_allocator/ControlAllocator.hpp b/src/modules/control_allocator/ControlAllocator.hpp index e79a1c6b189..a3b951342f9 100644 --- a/src/modules/control_allocator/ControlAllocator.hpp +++ b/src/modules/control_allocator/ControlAllocator.hpp @@ -254,9 +254,9 @@ private: (ParamInt) _param_ca_airframe, (ParamInt) _param_ca_method, (ParamInt) _param_ca_failure_mode, - (ParamInt) _param_r_rev, + (ParamInt) _param_ca_r_rev, (ParamFloat) _param_ca_rev_thr_frac, - (ParamFloat) _param_ice_shedding_period + (ParamFloat) _param_ca_ice_period ) }; diff --git a/src/modules/control_allocator/VehicleActuatorEffectiveness/ActuatorEffectivenessControlSurfaces.cpp b/src/modules/control_allocator/VehicleActuatorEffectiveness/ActuatorEffectivenessControlSurfaces.cpp index 3bf16306d94..5a21b8e41c1 100644 --- a/src/modules/control_allocator/VehicleActuatorEffectiveness/ActuatorEffectivenessControlSurfaces.cpp +++ b/src/modules/control_allocator/VehicleActuatorEffectiveness/ActuatorEffectivenessControlSurfaces.cpp @@ -60,7 +60,7 @@ ActuatorEffectivenessControlSurfaces::ActuatorEffectivenessControlSurfaces(Modul _param_handles[i].scale_spoiler = param_find(buffer); } - _flaps_setpoint_with_slewrate.setSlewRate(_param_ca_flap_slew.get()); + _flaps_setpoint_with_slewrate.setSlewRate(_param_ca_sv_flap_slew.get()); _spoilers_setpoint_with_slewrate.setSlewRate(kSpoilersSlewRate); _count_handle = param_find("CA_SV_CS_COUNT"); @@ -86,7 +86,7 @@ void ActuatorEffectivenessControlSurfaces::updateParams() } // Update flap slewrates - _flaps_setpoint_with_slewrate.setSlewRate(_param_ca_flap_slew.get()); + _flaps_setpoint_with_slewrate.setSlewRate(_param_ca_sv_flap_slew.get()); // Helper to check if a PWM center parameter is enabled, and clamp it to valid range auto check_pwm_center = [](const char *prefix, int channel) -> bool { diff --git a/src/modules/control_allocator/VehicleActuatorEffectiveness/ActuatorEffectivenessControlSurfaces.hpp b/src/modules/control_allocator/VehicleActuatorEffectiveness/ActuatorEffectivenessControlSurfaces.hpp index 7da030fc187..1bc2676ac10 100644 --- a/src/modules/control_allocator/VehicleActuatorEffectiveness/ActuatorEffectivenessControlSurfaces.hpp +++ b/src/modules/control_allocator/VehicleActuatorEffectiveness/ActuatorEffectivenessControlSurfaces.hpp @@ -114,6 +114,6 @@ private: SlewRate _flaps_setpoint_with_slewrate; SlewRate _spoilers_setpoint_with_slewrate; DEFINE_PARAMETERS( - (ParamFloat) _param_ca_flap_slew + (ParamFloat) _param_ca_sv_flap_slew ) }; diff --git a/src/modules/ekf2/CMakeLists.txt b/src/modules/ekf2/CMakeLists.txt index 979000fc855..d3911804107 100644 --- a/src/modules/ekf2/CMakeLists.txt +++ b/src/modules/ekf2/CMakeLists.txt @@ -203,6 +203,7 @@ endif() if(CONFIG_EKF2_OPTICAL_FLOW) list(APPEND EKF_SRCS + EKF/aid_sources/optical_flow/optical_flow.cpp EKF/aid_sources/optical_flow/optical_flow_control.cpp EKF/aid_sources/optical_flow/optical_flow_fusion.cpp ) diff --git a/src/modules/ekf2/EKF/aid_sources/magnetometer/mag_control.cpp b/src/modules/ekf2/EKF/aid_sources/magnetometer/mag_control.cpp index bb56ef22ed4..c75a5896eb2 100644 --- a/src/modules/ekf2/EKF/aid_sources/magnetometer/mag_control.cpp +++ b/src/modules/ekf2/EKF/aid_sources/magnetometer/mag_control.cpp @@ -240,7 +240,10 @@ void Ekf::controlMagFusion(const imuSample &imu_sample) // declination angle over time. const bool update_all_states = _control_status.flags.mag_3D || _control_status.flags.mag_hdg; const bool update_tilt = _control_status.flags.mag_3D; - fuseMag(R_MAG, H, aid_src, update_all_states, update_tilt); + + if (fuseMag(R_MAG, H, aid_src, update_all_states, update_tilt)) { + updateMagBiasObservability(); + } // the innovation variance contribution from the state covariances is negative which means the covariance matrix is badly conditioned if (update_all_states && update_tilt) { @@ -280,8 +283,9 @@ void Ekf::controlMagFusion(const imuSample &imu_sample) if (is_fusion_failing) { if (no_ne_aiding_or_not_moving) { ECL_WARN("%s fusion failing, resetting", AID_SRC_NAME); - const bool reset_heading = isHeadingResetToMagAllowed(); - resetMagStates(_mag_lpf.getState(), reset_heading); + // Keep the heading: a field rejected for this long is more likely disturbed + // than the heading wrong, and a wrong heading is recovered by yawing + resetMagStates(_mag_lpf.getState(), false); aid_src.time_last_fuse = imu_sample.time_us; } else { @@ -344,9 +348,9 @@ void Ekf::stopMagFusion() resetMagBiasCov(); if (_control_status.flags.yaw_align && (_control_status.flags.mag_3D || _control_status.flags.mag_hdg)) { - // reset yaw alignment from mag unless yaw is observable through North-East aiding - - if (!isNorthEastAidingActive()) { + // Before takeoff, we do not want to continue to rely on a heading that came from the mag, + // unless yaw is observable through North-East aiding or was set manually + if (!_control_status.flags.in_air && !isNorthEastAidingActive() && !_control_status.flags.yaw_manual) { _control_status.flags.yaw_align = false; } } @@ -375,6 +379,17 @@ void Ekf::stopMagFusion() } } +void Ekf::updateMagBiasObservability() +{ + // Yawing separates the body-fixed bias from the earth field + static constexpr float heading_change_min = math::radians(90.f); + const float heading_change = wrap_pi(getEulerYaw(_R_to_earth) - _mag_bias_reset_heading); + + if (fabsf(heading_change) > heading_change_min) { + _mag_bias_observable = true; + } +} + bool Ekf::isMagInFlightAlignmentRequired() const { #if defined(CONFIG_EKF2_TERRAIN) @@ -395,6 +410,7 @@ bool Ekf::isMagInFlightAlignmentRequired() const bool Ekf::isHeadingResetToMagAllowed() const { return (_control_status.flags.mag_hdg || _control_status.flags.mag_3D) + && !_control_status.flags.in_air // a heading jump is only harmless on the ground && !_control_status.flags.yaw_manual; // do not override manual reset } diff --git a/src/modules/ekf2/EKF/aid_sources/optical_flow/optical_flow.cpp b/src/modules/ekf2/EKF/aid_sources/optical_flow/optical_flow.cpp new file mode 100644 index 00000000000..2ff3ef79233 --- /dev/null +++ b/src/modules/ekf2/EKF/aid_sources/optical_flow/optical_flow.cpp @@ -0,0 +1,223 @@ +/**************************************************************************** + * + * Copyright (c) 2026 PX4 Development Team. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name PX4 nor the names of its contributors may be + * used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + * + ****************************************************************************/ + +#include "ekf.h" + +#if defined(CONFIG_EKF2_OPTICAL_FLOW) && defined(MODULE_NAME) + +#include + +using namespace time_literals; +using matrix::Vector2f; +using matrix::Vector3f; + +void OpticalFlowSource::initParams() +{ + char param_name[20] {}; + snprintf(param_name, sizeof(param_name), "EKF2_OF%d_CTRL", _slot); + _param_handles.ctrl = param_find(param_name); + + snprintf(param_name, sizeof(param_name), "SENS_FLOW%d_DELAY", _slot); + _param_handles.delay = param_find(param_name); + + updateParams(); +} + +void OpticalFlowSource::updateParams() +{ + if (_param_handles.ctrl == PARAM_INVALID) { + return; + } + + param_get(_param_handles.ctrl, ¶ms.ctrl); + + // the tuning of a disabled slot stays hidden from the GCS until the slot is enabled + if (params.ctrl == 0) { + return; + } + + _aid_src_pub.advertise(); + _vel_pub.advertise(); + + if (_param_handles.gyr_src == PARAM_INVALID) { + char param_name[20] {}; + + snprintf(param_name, sizeof(param_name), "EKF2_OF%d_GYR_SRC", _slot); + _param_handles.gyr_src = param_find(param_name); + + snprintf(param_name, sizeof(param_name), "EKF2_OF%d_N_MIN", _slot); + _param_handles.n_min = param_find(param_name); + + snprintf(param_name, sizeof(param_name), "EKF2_OF%d_N_MAX", _slot); + _param_handles.n_max = param_find(param_name); + + snprintf(param_name, sizeof(param_name), "EKF2_OF%d_QMIN", _slot); + _param_handles.qmin = param_find(param_name); + + snprintf(param_name, sizeof(param_name), "EKF2_OF%d_QMINGND", _slot); + _param_handles.qmin_gnd = param_find(param_name); + + snprintf(param_name, sizeof(param_name), "EKF2_OF%d_GATE", _slot); + _param_handles.gate = param_find(param_name); + } + + param_get(_param_handles.gyr_src, ¶ms.gyr_src); + param_get(_param_handles.n_min, ¶ms.n_min); + param_get(_param_handles.n_max, ¶ms.n_max); + param_get(_param_handles.qmin, ¶ms.qmin); + param_get(_param_handles.qmin_gnd, ¶ms.qmin_gnd); + param_get(_param_handles.gate, ¶ms.gate); +} + +float OpticalFlowSource::delayMs() const +{ + // read live, EKF2 checks the delays before the EKF parameters are updated + int32_t ctrl = 0; + float delay_ms = 0.f; + + if ((param_get(_param_handles.ctrl, &ctrl) == PX4_OK) && (ctrl != 0)) { + param_get(_param_handles.delay, &delay_ms); + } + + return delay_ms; +} + +void OpticalFlowSource::publish(const Ekf &ekf) +{ + const hrt_abstime now = hrt_absolute_time(); + + _aid_src.timestamp = now; + _aid_src_pub.publish(_aid_src); + + vehicle_optical_flow_vel_s flow_vel{}; + flow_vel.timestamp_sample = _aid_src.timestamp_sample; + + _vel_body.copyTo(flow_vel.vel_body); + ekf.getFlowVelNE(_slot).copyTo(flow_vel.vel_ne); + + _vel_body_lpf.getState().copyTo(flow_vel.vel_body_filtered); + ekf.getFilteredFlowVelNE(_slot).copyTo(flow_vel.vel_ne_filtered); + + _sample_delayed.flow_rate.copyTo(flow_vel.flow_rate_uncompensated); + _rate_compensated.copyTo(flow_vel.flow_rate_compensated); + + _sample_delayed.gyro_rate.copyTo(flow_vel.gyro_rate); + + _gyro_bias.copyTo(flow_vel.gyro_bias); + _ref_body_rate.copyTo(flow_vel.ref_gyro); + + flow_vel.timestamp = now; + _vel_pub.publish(flow_vel); +} + +bool OpticalFlowSource::updateSample(Ekf &ekf, vehicle_optical_flow_s &optical_flow) +{ + if (!_sub.update(&optical_flow)) { + return false; + } + + const float dt = 1e-6f * (float)optical_flow.integration_timespan_us; + Vector2f flow_rate; + Vector3f gyro_rate; + + if (dt > FLT_EPSILON) { + // NOTE: the EKF uses the reverse sign convention to the flow sensor. EKF assumes positive LOS rate + // is produced by a RH rotation of the image about the sensor axis. + flow_rate = Vector2f(-optical_flow.pixel_flow[0], -optical_flow.pixel_flow[1]) / dt; + gyro_rate = Vector3f(-optical_flow.delta_angle[0], -optical_flow.delta_angle[1], -optical_flow.delta_angle[2]) / dt; + + } else if (optical_flow.quality == 0) { + // handle special case of SITL and PX4Flow where dt is forced to zero when the quaity is 0 + flow_rate.zero(); + gyro_rate.zero(); + } + + estimator::flowSample flow { + .time_us = optical_flow.timestamp_sample - optical_flow.integration_timespan_us / 2, // correct timestamp to midpoint of integration interval as the data is converted to rates + .flow_rate = flow_rate, + .gyro_rate = gyro_rate, + .quality = optical_flow.quality, + .device_id = optical_flow.device_id + }; + + if (Vector2f(optical_flow.pixel_flow).isAllFinite() && optical_flow.integration_timespan_us < 1e6) { + setLimits(optical_flow.max_flow_rate, optical_flow.min_ground_distance, optical_flow.max_ground_distance); + setPositionBody(Vector3f(optical_flow.position_offset)); + setData(flow, ekf._imu_buffer_length, ekf._min_obs_interval_us, ekf._dt_ekf_avg); + } + + return true; +} + +void OpticalFlowAiding::updateParams() +{ + for (auto &source : _sources) { + source.updateParams(); + } +} + +void OpticalFlowAiding::updateSamples(Ekf &ekf) +{ + for (uint8_t slot = 0; slot < estimator::MAX_OF_INSTANCES; slot++) { + vehicle_optical_flow_s optical_flow; + + if (!_sources[slot].updateSample(ekf, optical_flow)) { + continue; + } + +#if defined(CONFIG_EKF2_RANGE_FINDER) + + if ((_range_instance < 0) && PX4_ISFINITE(optical_flow.distance_m) && (optical_flow.distance_m > 0.f)) { + _range_instance = slot; + } + + // the distance measured by the flow sensor substitutes a missing range finder + if ((slot == _range_instance) && PX4_ISFINITE(optical_flow.distance_m) + && !ekf.isNewestSampleRecent(ekf._time_last_range_sensor_data, 1_s)) { + + int8_t quality = static_cast(optical_flow.quality) / static_cast(UINT8_MAX) * 100.f; + + estimator::sensor::rangeSample range_sample { + .time_us = optical_flow.timestamp_sample, + .rng = optical_flow.distance_m, + .quality = quality, + }; + ekf.pushRangeData(range_sample); + ekf.set_rangefinder_limits(optical_flow.min_ground_distance, optical_flow.max_ground_distance); + } + +#endif // CONFIG_EKF2_RANGE_FINDER + } +} + +#endif // CONFIG_EKF2_OPTICAL_FLOW && MODULE_NAME diff --git a/src/modules/ekf2/EKF/aid_sources/optical_flow/optical_flow_control.cpp b/src/modules/ekf2/EKF/aid_sources/optical_flow/optical_flow_control.cpp index 523f75f4dcc..10ff21cd413 100644 --- a/src/modules/ekf2/EKF/aid_sources/optical_flow/optical_flow_control.cpp +++ b/src/modules/ekf2/EKF/aid_sources/optical_flow/optical_flow_control.cpp @@ -40,65 +40,242 @@ #include -void Ekf::controlOpticalFlowFusion(const imuSample &imu_delayed) +void OpticalFlowAiding::update(Ekf &ekf, const imuSample &imu_delayed) { - _fc.of.available = (_params.ekf2_of_ctrl != 0); +#if defined(MODULE_NAME) + updateSamples(ekf); +#endif // MODULE_NAME - if (!_flow_buffer || !_fc.of.intended()) { - stopFlowFusion(); + bool any_ctrl_enabled = false; + + for (uint8_t slot = 0; slot < MAX_OF_INSTANCES; slot++) { + any_ctrl_enabled |= (_sources[slot].params.ctrl != 0); + } + + ekf._fc.of.available = any_ctrl_enabled; + + for (uint8_t slot = 0; slot < MAX_OF_INSTANCES; slot++) { + bool other_slot_fusing = false; + + for (uint8_t other = 0; other < MAX_OF_INSTANCES; other++) { + other_slot_fusing |= (other != slot) && _sources[other].isFusing(ekf); + } + + _sources[slot].update(ekf, imu_delayed, other_slot_fusing); + } + + bool any_active = false; + bool any_terrain = false; + + for (uint8_t i = 0; i < MAX_OF_INSTANCES; i++) { + any_active |= _sources[i]._active; + any_terrain |= _sources[i]._terrain; + } + + ekf._control_status.flags.opt_flow = any_active; + ekf._control_status.flags.opt_flow_terrain = any_terrain; + + if (!any_active) { + ekf._fault_status.flags.bad_optflow_X = false; + ekf._fault_status.flags.bad_optflow_Y = false; + } +} + +uint8_t OpticalFlowAiding::primarySlot() const +{ + for (uint8_t i = 0; i < MAX_OF_INSTANCES; i++) { + if (_sources[i]._active) { + return i; + } + } + + for (uint8_t i = 0; i < MAX_OF_INSTANCES; i++) { + if (_sources[i]._aid_src.timestamp_sample != 0) { + return i; + } + } + + return 0; +} + +uint64_t OpticalFlowAiding::timeLastFuse() const +{ + uint64_t latest = 0; + + for (uint8_t i = 0; i < MAX_OF_INSTANCES; i++) { + latest = math::max(latest, _sources[i]._aid_src.time_last_fuse); + } + + return latest; +} + +uint64_t OpticalFlowAiding::latestSampleTimestamp() const +{ + uint64_t latest = 0; + + for (uint8_t i = 0; i < MAX_OF_INSTANCES; i++) { + latest = math::max(latest, _sources[i]._aid_src.timestamp_sample); + } + + return latest; +} + +float OpticalFlowAiding::maxActiveInnovNorm() const +{ + float innov_norm = 0.f; + + for (uint8_t i = 0; i < MAX_OF_INSTANCES; i++) { + if (_sources[i]._active) { + innov_norm = math::max(innov_norm, Vector2f(_sources[i]._aid_src.innovation).norm()); + } + } + + return innov_norm; +} + +float OpticalFlowAiding::maxActiveTestRatioFiltered() const +{ + float test_ratio = 0.f; + + for (uint8_t i = 0; i < MAX_OF_INSTANCES; i++) { + if (_sources[i]._active) { + for (const auto &test_ratio_filtered : _sources[i]._aid_src.test_ratio_filtered) { + test_ratio = math::max(test_ratio, fabsf(test_ratio_filtered)); + } + } + } + + return test_ratio; +} + +void OpticalFlowAiding::getLimits(const Ekf &ekf, float &hagl_min, float &hagl_max, float &max_rate) const +{ + // combined envelope of all sensors currently delivering data + // (sensors with different ranges hand over as the height changes) + hagl_min = INFINITY; + hagl_max = 0.f; + max_rate = 0.f; + bool any_flow_source = false; + + for (uint8_t i = 0; i < MAX_OF_INSTANCES; i++) { + if (ekf._fc.of.intended() && (_sources[i].params.ctrl != 0) + && ekf.isRecent(_sources[i]._time_last_data, (uint64_t)1e6)) { + hagl_min = math::min(hagl_min, _sources[i]._min_distance); + hagl_max = math::max(hagl_max, _sources[i]._max_distance); + max_rate = math::max(max_rate, _sources[i]._max_rate); + any_flow_source = true; + } + } + + if (!any_flow_source) { + // no flow source delivering data, fall back to the primary slot's limits + const uint8_t slot = primarySlot(); + hagl_min = _sources[slot]._min_distance; + hagl_max = _sources[slot]._max_distance; + max_rate = _sources[slot]._max_rate; + } +} + +void OpticalFlowSource::setData(const flowSample &flow, const uint8_t buffer_length, const uint64_t min_obs_interval_us, + const float dt_ekf_avg) +{ + if (params.ctrl == 0) { return; } - VectorState H; + // allocated on the first sample of an enabled slot, so that a slot can be enabled at runtime + if (_buffer == nullptr) { + _buffer = new TimestampedRingBuffer(buffer_length); + + if (_buffer == nullptr || !_buffer->valid()) { + delete _buffer; + _buffer = nullptr; + ECL_ERR("optical flow %d buffer allocation failed", _slot); + return; + } + } + + // the measurement delay is already compensated in the sample timestamp (SENS_FLOW_DELAY) + const int64_t time_us = flow.time_us + - static_cast(dt_ekf_avg * 5e5f); // seconds to microseconds divided by 2 + + // limit data rate to prevent data being lost + if (time_us >= static_cast(_buffer->get_newest().time_us + min_obs_interval_us)) { + + flowSample optflow_sample_new{flow}; + optflow_sample_new.time_us = time_us; + + _buffer->push(optflow_sample_new); + _time_last_data = optflow_sample_new.time_us; + + } else { + ECL_WARN("optical flow %d data too fast %" PRIi64 " < %" PRIu64 " + %" PRIu64, _slot, time_us, + _buffer->get_newest().time_us, min_obs_interval_us); + } +} + +bool OpticalFlowSource::isFusing(const Ekf &ekf) const +{ + return _active && !ekf.isTimedOut(_aid_src.time_last_fuse, ekf._params.no_aid_timeout_max); +} + +void OpticalFlowSource::update(Ekf &ekf, const imuSample &imu_delayed, const bool other_slot_fusing) +{ + if (!_buffer || !ekf._fc.of.intended() || (params.ctrl == 0)) { + stop(); + return; + } + + Ekf::VectorState H; // New optical flow data is available and is ready to be fused when the midpoint of the sample falls behind the fusion time horizon - if (_flow_buffer->pop_first_older_than(imu_delayed.time_us, &_flow_sample_delayed)) { + if (_buffer->pop_first_older_than(imu_delayed.time_us, &_sample_delayed)) { // flow gyro has opposite sign convention - _ref_body_rate = -(imu_delayed.delta_ang / imu_delayed.delta_ang_dt - getGyroBias()); + _ref_body_rate = -(imu_delayed.delta_ang / imu_delayed.delta_ang_dt - ekf.getGyroBias()); // ensure valid flow sample gyro rate before proceeding - switch (static_cast(_params.ekf2_of_gyr_src)) { + switch (static_cast(params.gyr_src)) { default: /* FALLTHROUGH */ case FlowGyroSource::Auto: - if (!PX4_ISFINITE(_flow_sample_delayed.gyro_rate(0)) || !PX4_ISFINITE(_flow_sample_delayed.gyro_rate(1))) { - _flow_sample_delayed.gyro_rate = _ref_body_rate; + if (!PX4_ISFINITE(_sample_delayed.gyro_rate(0)) || !PX4_ISFINITE(_sample_delayed.gyro_rate(1))) { + _sample_delayed.gyro_rate = _ref_body_rate; } - if (!PX4_ISFINITE(_flow_sample_delayed.gyro_rate(2))) { + if (!PX4_ISFINITE(_sample_delayed.gyro_rate(2))) { // Some flow modules only provide X ind Y angular rates. If this is the case, complete the vector with our own Z gyro - _flow_sample_delayed.gyro_rate(2) = _ref_body_rate(2); + _sample_delayed.gyro_rate(2) = _ref_body_rate(2); } break; case FlowGyroSource::Internal: - _flow_sample_delayed.gyro_rate = _ref_body_rate; + _sample_delayed.gyro_rate = _ref_body_rate; break; } - const flowSample &flow_sample = _flow_sample_delayed; + const flowSample &flow_sample = _sample_delayed; - const int32_t min_quality = _control_status.flags.in_air - ? _params.ekf2_of_qmin - : _params.ekf2_of_qmin_gnd; + const int32_t min_quality = ekf._control_status.flags.in_air + ? params.qmin + : params.qmin_gnd; const bool is_quality_good = (flow_sample.quality >= min_quality); bool is_tilt_good = true; #if defined(CONFIG_EKF2_RANGE_FINDER) - is_tilt_good = (_R_to_earth(2, 2) > _params.range_cos_max_tilt); + is_tilt_good = (ekf._R_to_earth(2, 2) > ekf._params.range_cos_max_tilt); #endif // CONFIG_EKF2_RANGE_FINDER - calcOptFlowBodyRateComp(flow_sample); + calcBodyRateComp(); // calculate optical LOS rates using optical flow rates that have had the body angular rate contribution removed // correct for gyro bias errors in the data used to do the motion compensation // Note the sign convention used: A positive LOS rate is a RH rotation of the scene about that axis. - const Vector3f flow_gyro_corrected = flow_sample.gyro_rate - _flow_gyro_bias; + const Vector3f flow_gyro_corrected = flow_sample.gyro_rate - _gyro_bias; const Vector2f flow_compensated = flow_sample.flow_rate - flow_gyro_corrected.xy(); // calculate the optical flow observation variance @@ -106,197 +283,197 @@ void Ekf::controlOpticalFlowFusion(const imuSample &imu_delayed) const float epsilon = 1e-3f; Vector2f innov_var; - sym::ComputeFlowXyInnovVarAndHx(_state.vector(), P, R_LOS, epsilon, &innov_var, &H); + sym::ComputeFlowXyInnovVarAndHx(ekf._state.vector(), ekf.P, R_LOS, epsilon, &innov_var, &H); + + _aid_src.device_id = flow_sample.device_id; // run the innovation consistency check and record result - updateAidSourceStatus(_aid_src_optical_flow, - flow_sample.time_us, // sample timestamp - flow_compensated, // observation - Vector2f{R_LOS, R_LOS}, // observation variance - predictFlow(flow_gyro_corrected) - flow_compensated, // innovation - innov_var, // innovation variance - math::max(_params.ekf2_of_gate, 1.f)); // innovation gate + ekf.updateAidSourceStatus(_aid_src, + flow_sample.time_us, // sample timestamp + flow_compensated, // observation + Vector2f{R_LOS, R_LOS}, // observation variance + ekf.predictFlow(_pos_body, flow_gyro_corrected) - flow_compensated, // innovation + innov_var, // innovation variance + math::max(params.gate, 1.f)); // innovation gate // logging - _flow_rate_compensated = flow_compensated; + _rate_compensated = flow_compensated; // compute the velocities in body and local frames from corrected optical flow measurement for logging only - const float range = predictFlowRange(); - _flow_vel_body(0) = -flow_compensated(1) * range; - _flow_vel_body(1) = flow_compensated(0) * range; + const float range = ekf.predictFlowRange(_pos_body); + _vel_body(0) = -flow_compensated(1) * range; + _vel_body(1) = flow_compensated(0) * range; - if (_flow_counter == 0) { - _flow_vel_body_lpf.reset(_flow_vel_body); - _flow_rate_compensated_lpf.reset(_flow_rate_compensated); - _flow_lpf_time_last_us = flow_sample.time_us; - _flow_counter = 1; + if (_counter == 0) { + _vel_body_lpf.setParameters(ekf._dt_ekf_avg, ekf._kSensorLpfTimeConstant); + _rate_compensated_lpf.setParameters(ekf._dt_ekf_avg, ekf._kSensorLpfTimeConstant); + + _vel_body_lpf.reset(_vel_body); + _rate_compensated_lpf.reset(_rate_compensated); + _lpf_time_last_us = flow_sample.time_us; + _counter = 1; } else { // the filters run once per flow sample, not once per EKF update - const uint64_t flow_dt_us = flow_sample.time_us - _flow_lpf_time_last_us; - _flow_vel_body_lpf.update(_flow_vel_body, flow_dt_us); - _flow_rate_compensated_lpf.update(_flow_rate_compensated, flow_dt_us); - _flow_lpf_time_last_us = flow_sample.time_us; - _flow_counter++; + const uint64_t flow_dt_us = flow_sample.time_us - _lpf_time_last_us; + _vel_body_lpf.update(_vel_body, flow_dt_us); + _rate_compensated_lpf.update(_rate_compensated, flow_dt_us); + _lpf_time_last_us = flow_sample.time_us; + _counter++; } // Check if we are in-air and require optical flow to control position drift - bool is_flow_required = _control_status.flags.in_air - && (_control_status.flags.inertial_dead_reckoning // is doing inertial dead-reckoning so must constrain drift urgently - || isOnlyActiveSourceOfHorizontalAiding(_control_status.flags.opt_flow)); + bool is_flow_required = ekf._control_status.flags.in_air + && (ekf._control_status.flags.inertial_dead_reckoning // is doing inertial dead-reckoning so must constrain drift urgently + || ekf.isOnlyActiveSourceOfHorizontalAiding(ekf._control_status.flags.opt_flow)); - const bool is_within_sensor_dist = (getHagl() >= _flow_min_distance) && (getHagl() <= _flow_max_distance); + const bool is_within_sensor_dist = (ekf.getHagl() >= _min_distance) && (ekf.getHagl() <= _max_distance); const bool is_magnitude_good = flow_sample.flow_rate.isAllFinite() - && !flow_sample.flow_rate.longerThan(_flow_max_rate) - && !flow_compensated.longerThan(_flow_max_rate); + && !flow_sample.flow_rate.longerThan(_max_rate) + && !flow_compensated.longerThan(_max_rate); - const bool continuing_conditions_passing = _fc.of.intended() - && _control_status.flags.tilt_align + const bool continuing_conditions_passing = ekf._fc.of.intended() && (params.ctrl != 0) + && ekf._control_status.flags.tilt_align && is_within_sensor_dist; const bool starting_conditions_passing = continuing_conditions_passing && is_quality_good && is_magnitude_good && is_tilt_good - && (_flow_counter > 10) - && (isHeightAboveGroundEstimateValid() || isHorizontalAidingActive()) - && isTimedOut(_aid_src_optical_flow.time_last_fuse, (uint64_t)2e6); // Prevent rapid switching + && (_counter > 10) + && (ekf.isHeightAboveGroundEstimateValid() || ekf.isHorizontalAidingActive()) + && ekf.isTimedOut(_aid_src.time_last_fuse, (uint64_t)2e6); // Prevent rapid switching // If the height is relative to the ground, terrain height cannot be observed. - _control_status.flags.opt_flow_terrain = _control_status.flags.opt_flow && !(_height_sensor_ref == HeightSensor::RANGE); + _terrain = _active && !(ekf._height_sensor_ref == HeightSensor::RANGE); - if (_control_status.flags.opt_flow) { + if (_active) { if (continuing_conditions_passing) { if (is_quality_good && is_magnitude_good && is_tilt_good) { - fuseOptFlow(H, _control_status.flags.opt_flow_terrain); + fuse(ekf, H, _terrain); } // handle the case when we have optical flow, are reliant on it, but have not been using it for an extended period - if (isTimedOut(_aid_src_optical_flow.time_last_fuse, _params.no_aid_timeout_max)) { - if (is_flow_required && is_quality_good && is_magnitude_good) { - resetFlowFusion(flow_sample); + // (if another flow sensor is still being fused, this one is the inconsistent one and must not reset the state) + if (ekf.isTimedOut(_aid_src.time_last_fuse, ekf._params.no_aid_timeout_max)) { + if (is_flow_required && is_quality_good && is_magnitude_good && !other_slot_fusing) { + reset(ekf); - if (_control_status.flags.opt_flow_terrain && !isTerrainEstimateValid()) { - resetTerrainToFlow(); + if (_terrain && !ekf.isTerrainEstimateValid()) { + resetTerrain(ekf); } } else { - stopFlowFusion(); + stop(); } } } else { - stopFlowFusion(); + stop(); } } else { if (starting_conditions_passing) { // If the height is relative to the ground, terrain height cannot be observed. - _control_status.flags.opt_flow_terrain = (_height_sensor_ref != HeightSensor::RANGE); + const bool terrain_observable = (ekf._height_sensor_ref != HeightSensor::RANGE); - if (isHorizontalAidingActive()) { - if (fuseOptFlow(H, _control_status.flags.opt_flow_terrain)) { - ECL_INFO("starting optical flow"); - _control_status.flags.opt_flow = true; + // another slot may have started during this update, before the aiding flags are updated + if (ekf.isHorizontalAidingActive() || other_slot_fusing) { + if (fuse(ekf, H, terrain_observable)) { + ECL_INFO("starting optical flow %d", _slot); + _active = true; - } else if (_control_status.flags.opt_flow_terrain && !_control_status.flags.rng_terrain) { - ECL_INFO("starting optical flow, resetting terrain"); - resetTerrainToFlow(); - _control_status.flags.opt_flow = true; + } else if (terrain_observable && !ekf._control_status.flags.rng_terrain && !other_slot_fusing) { + // only when no other flow sensor observes the terrain, otherwise retry on the next sample + ECL_INFO("starting optical flow %d, resetting terrain", _slot); + resetTerrain(ekf); + _active = true; } } else { - if (isHeightAboveGroundEstimateValid()) { - ECL_INFO("starting optical flow, resetting"); - resetFlowFusion(flow_sample); - _control_status.flags.opt_flow = true; + if (ekf.isHeightAboveGroundEstimateValid()) { + ECL_INFO("starting optical flow %d, resetting", _slot); + reset(ekf); + _active = true; - } else if (_control_status.flags.opt_flow_terrain) { - ECL_INFO("starting optical flow, resetting terrain"); - resetTerrainToFlow(); - _control_status.flags.opt_flow = true; + } else if (terrain_observable) { + ECL_INFO("starting optical flow %d, resetting terrain", _slot); + resetTerrain(ekf); + _active = true; } } - _control_status.flags.opt_flow_terrain = _control_status.flags.opt_flow && !(_height_sensor_ref == HeightSensor::RANGE); + _terrain = _active && terrain_observable; } } - } else if (_control_status.flags.opt_flow && isTimedOut(_flow_sample_delayed.time_us, _params.reset_timeout_max)) { - stopFlowFusion(); +#if defined(MODULE_NAME) + publish(ekf); +#endif // MODULE_NAME + + } else if (_active && ekf.isTimedOut(_sample_delayed.time_us, ekf._params.reset_timeout_max)) { + stop(); } } -void Ekf::resetFlowFusion(const flowSample &flow_sample) +bool OpticalFlowSource::fuse(Ekf &ekf, Ekf::VectorState &H, const bool update_terrain) { - ECL_INFO("reset velocity to flow"); - _information_events.flags.reset_vel_to_flow = true; - - const float flow_vel_var = sq(predictFlowRange()) * calcOptFlowMeasVar(flow_sample); - resetHorizontalVelocityTo(getFilteredFlowVelNE(), flow_vel_var); - - resetAidSourceStatusZeroInnovation(_aid_src_optical_flow); + return ekf.fuseOptFlow(_aid_src, H, update_terrain); } -void Ekf::resetTerrainToFlow() +void OpticalFlowSource::reset(Ekf &ekf) { - ECL_INFO("reset hagl to flow"); + ECL_INFO("reset velocity to flow %d", _slot); + ekf._information_events.flags.reset_vel_to_flow = true; - float new_terrain = -_gpos.altitude() + _params.ekf2_min_rng; + const float flow_vel_var = sq(ekf.predictFlowRange(_pos_body)) * calcOptFlowMeasVar(_sample_delayed); + ekf.resetHorizontalVelocityTo(ekf.getFilteredFlowVelNE(_slot), flow_vel_var); - if (isOtherSourceOfHorizontalAidingThan(_control_status.flags.opt_flow)) { + ekf.resetAidSourceStatusZeroInnovation(_aid_src); +} + +void OpticalFlowSource::resetTerrain(Ekf &ekf) +{ + ECL_INFO("reset hagl to flow %d", _slot); + + float new_terrain = -ekf._gpos.altitude() + ekf._params.ekf2_min_rng; + + if (ekf.isOtherSourceOfHorizontalAidingThan(ekf._control_status.flags.opt_flow)) { // ||vel_NE|| = ||( R * flow_body * range).xy()|| // range = ||vel_NE|| / ||P * R * flow_body|| constexpr float kProjXY[2][3] = {{1.f, 0.f, 0.f}, {0.f, 1.f, 0.f}}; const matrix::Matrix proj(kProjXY); - const Vector3f flow_body(-_flow_rate_compensated_lpf.getState()(1), _flow_rate_compensated_lpf.getState()(0), 0.f); - const float denom = Vector2f(proj * _R_to_earth * flow_body).norm(); + const Vector3f flow_body(-_rate_compensated_lpf.getState()(1), _rate_compensated_lpf.getState()(0), 0.f); + const float denom = Vector2f(proj * ekf._R_to_earth * flow_body).norm(); if (denom > 1e-6f) { - const float range = _state.vel.xy().norm() / denom; - new_terrain = -_gpos.altitude() + max(range, _params.ekf2_min_rng); + const float range = ekf._state.vel.xy().norm() / denom; + new_terrain = -ekf._gpos.altitude() + math::max(range, ekf._params.ekf2_min_rng); } } - const float delta_terrain = new_terrain - _state.terrain; - _state.terrain = new_terrain; - P.uncorrelateCovarianceSetVariance(State::terrain.idx, 100.f); - - resetAidSourceStatusZeroInnovation(_aid_src_optical_flow); - - // record the state change - if (_state_reset_status.reset_count.hagl == _state_reset_count_prev.hagl) { - _state_reset_status.hagl_change = delta_terrain; - - } else { - // there's already a reset this update, accumulate total delta - _state_reset_status.hagl_change += delta_terrain; - } - - _state_reset_status.reset_count.hagl++; + ekf.resetTerrainTo(new_terrain, 100.f); + ekf.resetAidSourceStatusZeroInnovation(_aid_src); } -void Ekf::stopFlowFusion() +void OpticalFlowSource::stop() { - if (_control_status.flags.opt_flow) { - ECL_INFO("stopping optical flow fusion"); - _control_status.flags.opt_flow = false; - _control_status.flags.opt_flow_terrain = false; + if (_active) { + ECL_INFO("stopping optical flow fusion %d", _slot); + _active = false; + _terrain = false; - _fault_status.flags.bad_optflow_X = false; - _fault_status.flags.bad_optflow_Y = false; - - _flow_counter = 0; + _counter = 0; } } -void Ekf::calcOptFlowBodyRateComp(const flowSample &flow_sample) +void OpticalFlowSource::calcBodyRateComp() { // calculate the bias estimate using a combined LPF and spike filter - _flow_gyro_bias = 0.99f * _flow_gyro_bias - + 0.01f * matrix::constrain(flow_sample.gyro_rate - _ref_body_rate, -0.1f, 0.1f); + _gyro_bias = 0.99f * _gyro_bias + + 0.01f * matrix::constrain(_sample_delayed.gyro_rate - _ref_body_rate, -0.1f, 0.1f); } diff --git a/src/modules/ekf2/EKF/aid_sources/optical_flow/optical_flow_fusion.cpp b/src/modules/ekf2/EKF/aid_sources/optical_flow/optical_flow_fusion.cpp index 38a5a853ece..24fee2f4bff 100644 --- a/src/modules/ekf2/EKF/aid_sources/optical_flow/optical_flow_fusion.cpp +++ b/src/modules/ekf2/EKF/aid_sources/optical_flow/optical_flow_fusion.cpp @@ -42,12 +42,12 @@ #include #include -bool Ekf::fuseOptFlow(VectorState &H, const bool update_terrain) +bool Ekf::fuseOptFlow(estimator_aid_source2d_s &aid_src, VectorState &H, const bool update_terrain) { const auto state_vector = _state.vector(); // if either axis fails we abort the fusion - if (_aid_src_optical_flow.innovation_rejected) { + if (aid_src.innovation_rejected) { return false; } @@ -60,12 +60,12 @@ bool Ekf::fuseOptFlow(VectorState &H, const bool update_terrain) } else if (index == 1) { // recalculate innovation variance because state covariances have changed due to previous fusion (linearise using the same initial state for all axes) - const float R_LOS = _aid_src_optical_flow.observation_variance[1]; + const float R_LOS = aid_src.observation_variance[1]; const float epsilon = 1e-3f; - sym::ComputeFlowYInnovVarAndH(state_vector, P, R_LOS, epsilon, &_aid_src_optical_flow.innovation_variance[1], &H); + sym::ComputeFlowYInnovVarAndH(state_vector, P, R_LOS, epsilon, &aid_src.innovation_variance[1], &H); } - if (_aid_src_optical_flow.innovation_variance[index] < _aid_src_optical_flow.observation_variance[index]) { + if (aid_src.innovation_variance[index] < aid_src.observation_variance[index]) { // we need to reinitialise the covariance matrix and abort this fusion step ECL_ERR("Opt flow error - covariance reset"); @@ -75,14 +75,14 @@ bool Ekf::fuseOptFlow(VectorState &H, const bool update_terrain) return false; } - VectorState Kfusion = computeKalmanGain(H, _aid_src_optical_flow.innovation_variance[index]); + VectorState Kfusion = computeKalmanGain(H, aid_src.innovation_variance[index]); if (!update_terrain) { Kfusion(State::terrain.idx) = 0.f; } - accumulateMeasurementUpdate(Kfusion, H, _aid_src_optical_flow.observation_variance[index], - _aid_src_optical_flow.innovation[index], state_correction); + accumulateMeasurementUpdate(Kfusion, H, aid_src.observation_variance[index], aid_src.innovation[index], + state_correction); } applyStateCorrection(state_correction); @@ -90,8 +90,8 @@ bool Ekf::fuseOptFlow(VectorState &H, const bool update_terrain) _fault_status.flags.bad_optflow_X = false; _fault_status.flags.bad_optflow_Y = false; - _aid_src_optical_flow.time_last_fuse = _time_delayed_us; - _aid_src_optical_flow.fused = true; + aid_src.time_last_fuse = _time_delayed_us; + aid_src.fused = true; _time_last_hor_vel_fuse = _time_delayed_us; @@ -102,10 +102,10 @@ bool Ekf::fuseOptFlow(VectorState &H, const bool update_terrain) return true; } -float Ekf::predictFlowHagl() const +float Ekf::predictFlowHagl(const Vector3f &sensor_pos_body) const { // calculate the sensor position relative to the IMU - const Vector3f pos_offset_body = _params.flow_pos_body - _params.imu_pos_body; + const Vector3f pos_offset_body = sensor_pos_body - _params.imu_pos_body; // calculate the sensor position relative to the IMU in earth frame const Vector3f pos_offset_earth = _R_to_earth * pos_offset_body; @@ -120,17 +120,18 @@ float Ekf::predictFlowHagl() const return fmaxf(height_above_gnd_est, min_hagl); } -float Ekf::predictFlowRange() const + +float Ekf::predictFlowRange(const Vector3f &sensor_pos_body) const { // calculate range from focal point to centre of image // absolute distance to the frame region in view - return predictFlowHagl() / _R_to_earth(2, 2); + return predictFlowHagl(sensor_pos_body) / _R_to_earth(2, 2); } -Vector2f Ekf::predictFlow(const Vector3f &flow_gyro) const +Vector2f Ekf::predictFlow(const Vector3f &sensor_pos_body, const Vector3f &flow_gyro) const { // calculate the sensor position relative to the IMU - const Vector3f pos_offset_body = _params.flow_pos_body - _params.imu_pos_body; + const Vector3f pos_offset_body = sensor_pos_body - _params.imu_pos_body; // calculate the velocity of the sensor relative to the imu in body frame // Note: flow gyro is the negative of the body angular velocity, thus use minus sign @@ -143,22 +144,22 @@ Vector2f Ekf::predictFlow(const Vector3f &flow_gyro) const const Vector2f vel_body = _state.quat_nominal.rotateVectorInverse(vel_rel_earth).xy(); // calculate range from focal point to centre of image - const float scale = _R_to_earth(2, 2) / predictFlowHagl(); + const float scale = _R_to_earth(2, 2) / predictFlowHagl(sensor_pos_body); return Vector2f(vel_body(1) * scale, -vel_body(0) * scale); } -float Ekf::calcOptFlowMeasVar(const flowSample &flow_sample) const +float OpticalFlowSource::calcOptFlowMeasVar(const flowSample &flow_sample) const { // calculate the observation noise variance - scaling noise linearly across flow quality range - const float R_LOS_best = fmaxf(_params.ekf2_of_n_min, 0.05f); - const float R_LOS_worst = fmaxf(_params.ekf2_of_n_max, 0.05f); + const float R_LOS_best = fmaxf(params.n_min, 0.05f); + const float R_LOS_worst = fmaxf(params.n_max, 0.05f); // calculate a weighting that varies between 1 when flow quality is best and 0 when flow quality is worst - float weighting = (255.f - (float)_params.ekf2_of_qmin); + float weighting = (255.f - (float)params.qmin); if (weighting >= 1.f) { - weighting = math::constrain((float)(flow_sample.quality - _params.ekf2_of_qmin) / weighting, 0.f, 1.f); + weighting = math::constrain((float)(flow_sample.quality - params.qmin) / weighting, 0.f, 1.f); } else { weighting = 0.0f; diff --git a/src/modules/ekf2/EKF/aid_sources/optical_flow/optical_flow_source.hpp b/src/modules/ekf2/EKF/aid_sources/optical_flow/optical_flow_source.hpp new file mode 100644 index 00000000000..c28dbf6594b --- /dev/null +++ b/src/modules/ekf2/EKF/aid_sources/optical_flow/optical_flow_source.hpp @@ -0,0 +1,227 @@ +/**************************************************************************** + * + * Copyright (c) 2026 PX4 Development Team. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name PX4 nor the names of its contributors may be + * used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + * + ****************************************************************************/ + +#ifndef EKF_OPTICAL_FLOW_SOURCE_HPP +#define EKF_OPTICAL_FLOW_SOURCE_HPP + +#include "../../common.h" + +#if defined(CONFIG_EKF2_OPTICAL_FLOW) + +#include +#include +#include +#include + +#if defined(MODULE_NAME) +# include +# include +# include +# include +# include +#endif // MODULE_NAME + +class Ekf; + +class OpticalFlowSource +{ +public: + struct Params { + int32_t ctrl{0}; + int32_t gyr_src{static_cast(estimator::FlowGyroSource::Auto)}; + float n_min{0.15f}; ///< best quality observation noise for optical flow LOS rate measurements (rad/sec) + float n_max{0.5f}; ///< worst quality observation noise for optical flow LOS rate measurements (rad/sec) + int32_t qmin{1}; ///< minimum acceptable quality integer from the flow sensor when in air + int32_t qmin_gnd{0}; ///< minimum acceptable quality integer from the flow sensor when on ground + float gate{3.0f}; ///< optical flow fusion innovation consistency gate size (STD) + }; + + Params params{}; + + ~OpticalFlowSource() { delete _buffer; } + + void setSlot(uint8_t slot) + { + _slot = slot; +#if defined(MODULE_NAME) + _sub = uORB::Subscription(ORB_ID(vehicle_optical_flow), slot); + initParams(); +#endif // MODULE_NAME + } + + void setData(const estimator::flowSample &sample, uint8_t buffer_length, uint64_t min_obs_interval_us, float dt_ekf_avg); + + void setLimits(float max_flow_rate, float min_dist, float max_dist) + { + _max_rate = max_flow_rate; + _min_distance = min_dist; + _max_distance = max_dist; + } + + void setPositionBody(const matrix::Vector3f &pos) { _pos_body = pos; } + + // other_slot_fusing: another flow sensor currently constrains the velocity drift + void update(Ekf &ekf, const estimator::imuSample &imu_delayed, bool other_slot_fusing); + + bool isFusing(const Ekf &ekf) const; + + void stop(); + +#if defined(MODULE_NAME) + // configured SENS_FLOW_DELAY, 0 while the slot is disabled + float delayMs() const; + +#endif // MODULE_NAME + +private: + friend class Ekf; + friend class OpticalFlowAiding; + +#if defined(MODULE_NAME) + void initParams(); + void updateParams(); + + // buffers a new vehicle_optical_flow sample of this slot + bool updateSample(Ekf &ekf, vehicle_optical_flow_s &optical_flow); + + struct ParamHandles { + param_t ctrl{PARAM_INVALID}; + param_t delay{PARAM_INVALID}; + param_t gyr_src{PARAM_INVALID}; + param_t n_min{PARAM_INVALID}; + param_t n_max{PARAM_INVALID}; + param_t qmin{PARAM_INVALID}; + param_t qmin_gnd{PARAM_INVALID}; + param_t gate{PARAM_INVALID}; + } _param_handles{}; + + uORB::Subscription _sub{ORB_ID(vehicle_optical_flow)}; + + uORB::PublicationMulti _aid_src_pub{ORB_ID(estimator_aid_src_optical_flow)}; + uORB::PublicationMulti _vel_pub{ORB_ID(estimator_optical_flow_vel)}; + + void publish(const Ekf &ekf); +#endif // MODULE_NAME + + bool fuse(Ekf &ekf, matrix::Vector &H, bool update_terrain); + + void reset(Ekf &ekf); + void resetTerrain(Ekf &ekf); + + void calcBodyRateComp(); + + float calcOptFlowMeasVar(const estimator::flowSample &flow_sample) const; + + TimestampedRingBuffer *_buffer{nullptr}; + uint64_t _time_last_data{0}; ///< time of the newest sample pushed to the buffer (us) + estimator::flowSample _sample_delayed{}; + + estimator_aid_source2d_s _aid_src{}; + + matrix::Vector3f _pos_body{}; ///< xyz position of the sensor focal point in body frame (m) + + matrix::Vector3f _gyro_bias{}; ///< bias errors in optical flow sensor rate gyro outputs (rad/sec) + matrix::Vector3f _ref_body_rate{}; ///< body rates from the EKF gyro data, flow sign convention (rad/s) + matrix::Vector2f _vel_body{}; ///< velocity from corrected flow measurement (body frame)(m/s) + AlphaFilter _vel_body_lpf{}; ///< filtered velocity from corrected flow measurement (body frame)(m/s) + matrix::Vector2f _rate_compensated{}; ///< measured angular rate of the image about the X and Y body axes after removal of body rotation (rad/s), RH rotation is positive + AlphaFilter _rate_compensated_lpf{}; + uint64_t _lpf_time_last_us{0}; + uint32_t _counter{0}; ///< number of flow samples read for initialization + + // Sensor limitations + float _max_rate{1.0f}; ///< maximum angular flow rate that the optical flow sensor can measure (rad/s) + float _min_distance{0.0f}; ///< minimum distance that the optical flow sensor can operate at (m) + float _max_distance{10.f}; ///< maximum distance that the optical flow sensor can operate at (m) + + bool _active{false}; + bool _terrain{false}; + + uint8_t _slot{0}; +}; + +class OpticalFlowAiding +{ +public: + OpticalFlowAiding() + { + for (uint8_t i = 0; i < estimator::MAX_OF_INSTANCES; i++) { + _sources[i].setSlot(i); + } + } + + void update(Ekf &ekf, const estimator::imuSample &imu_delayed); + + void setData(const estimator::flowSample &flow, uint8_t instance, uint8_t buffer_length, uint64_t min_obs_interval_us, + float dt_ekf_avg) + { + if (instance < estimator::MAX_OF_INSTANCES) { + _sources[instance].setData(flow, buffer_length, min_obs_interval_us, dt_ekf_avg); + } + } + + OpticalFlowSource &source(uint8_t instance) { return _sources[instance]; } + const OpticalFlowSource &source(uint8_t instance) const { return _sources[instance]; } + + // lowest slot currently fusing, otherwise lowest slot with data (for single-instance legacy consumers) + uint8_t primarySlot() const; + + // most recent fusion / sample activity across all slots + uint64_t timeLastFuse() const; + uint64_t latestSampleTimestamp() const; + + float maxActiveInnovNorm() const; + float maxActiveTestRatioFiltered() const; + + // combined limits of the slots currently delivering data, falling back to the primary slot + void getLimits(const Ekf &ekf, float &hagl_min, float &hagl_max, float &max_rate) const; + +#if defined(MODULE_NAME) + void updateParams(); +#endif // MODULE_NAME + +private: +#if defined(MODULE_NAME) + void updateSamples(Ekf &ekf); +#endif // MODULE_NAME + + OpticalFlowSource _sources[estimator::MAX_OF_INSTANCES] {}; + +#if defined(MODULE_NAME) && defined(CONFIG_EKF2_RANGE_FINDER) + int8_t _range_instance {-1}; ///< first instance providing a distance, used as range finder fallback +#endif // MODULE_NAME && CONFIG_EKF2_RANGE_FINDER +}; + +#endif // CONFIG_EKF2_OPTICAL_FLOW + +#endif // !EKF_OPTICAL_FLOW_SOURCE_HPP diff --git a/src/modules/ekf2/EKF/common.h b/src/modules/ekf2/EKF/common.h index 19b667be6b6..d864f7a8ffe 100644 --- a/src/modules/ekf2/EKF/common.h +++ b/src/modules/ekf2/EKF/common.h @@ -239,6 +239,7 @@ struct flowSample { Vector2f flow_rate{}; ///< measured angular rate of the image about the X and Y body axes (rad/s), RH rotation is positive Vector3f gyro_rate{}; ///< measured angular rate of the inertial frame about the body axes obtained from rate gyro measurements (rad/s), RH rotation is positive uint8_t quality{}; ///< quality indicator between 0 and 255 + uint32_t device_id{}; ///< unique device ID for the sensor that does not change between power cycles }; #if defined(CONFIG_EKF2_EXTERNAL_VISION) @@ -295,6 +296,7 @@ struct systemFlagUpdate { // Runtime fusion control. Populated by EKF2 module, read by EKF core. static constexpr uint8_t MAX_AGP_INSTANCES = 4; +static constexpr uint8_t MAX_OF_INSTANCES = 2; struct FusionSensor { bool enabled{false}; // runtime toggleable via MAVLink @@ -483,21 +485,6 @@ struct parameters { float ekf2_grav_noise{1.0f}; ///< accelerometer measurement gaussian noise (m/s**2) #endif // CONFIG_EKF2_GRAVITY_FUSION -#if defined(CONFIG_EKF2_OPTICAL_FLOW) - int32_t ekf2_of_ctrl {0}; - int32_t ekf2_of_gyr_src {static_cast(FlowGyroSource::Auto)}; - float ekf2_of_delay{5.0f}; ///< optical flow measurement delay relative to the IMU (mSec) - this is to the middle of the optical flow integration interval - - // optical flow fusion - float ekf2_of_n_min{0.15f}; ///< observation noise for optical flow LOS rate measurements (rad/sec) - float ekf2_of_n_max{0.5f}; ///< observation noise for optical flow LOS rate measurements when flow sensor quality is at the minimum useable (rad/sec) - int32_t ekf2_of_qmin{1}; ///< minimum acceptable quality integer from the flow sensor - int32_t ekf2_of_qmin_gnd{0}; ///< minimum acceptable quality integer from the flow sensor when on ground - float ekf2_of_gate{3.0f}; ///< optical flow fusion innovation consistency gate size (STD) - - Vector3f flow_pos_body{}; ///< xyz position of range sensor focal point in body frame (m) -#endif // CONFIG_EKF2_OPTICAL_FLOW - // XYZ offset of sensors in body axes (m) Vector3f imu_pos_body{}; ///< xyz position of IMU in body frame (m) diff --git a/src/modules/ekf2/EKF/control.cpp b/src/modules/ekf2/EKF/control.cpp index b1c35f81894..3fee37ca5bd 100644 --- a/src/modules/ekf2/EKF/control.cpp +++ b/src/modules/ekf2/EKF/control.cpp @@ -110,7 +110,7 @@ void Ekf::controlFusionModes(const imuSample &imu_delayed) #endif // CONFIG_EKF2_MAGNETOMETER #if defined(CONFIG_EKF2_OPTICAL_FLOW) - controlOpticalFlowFusion(imu_delayed); + _flow_aiding.update(*this, imu_delayed); #endif // CONFIG_EKF2_OPTICAL_FLOW #if defined(CONFIG_EKF2_GNSS) @@ -177,31 +177,4 @@ void Ekf::controlFusionModes(const imuSample &imu_delayed) // North/East aiding only constrains the heading when the vehicle accelerates horizontally, never at rest const bool ne_aiding_heading = isNorthEastAidingActive() && !_control_status.flags.vehicle_at_rest; _control_status.flags.heading_observable = ne_aiding_heading || yaw_aiding; - - updateYawManualValidity(); -} - -void Ekf::updateYawManualValidity() -{ - const bool heading_observation_fusing = !isTimedOut(_time_last_heading_fuse, _params.no_aid_timeout_max); - - if (!_control_status.flags.yaw_manual || !heading_observation_fusing) { - _time_heading_fusion_start = 0; - return; - } - - if (_time_heading_fusion_start == 0) { - _time_heading_fusion_start = _time_delayed_us; - return; - } - - // A manually set heading is protected from automatic heading resets, but only until the - // heading aiding sources have had the opportunity to drive the heading themselves. After - // that the estimate is aiding derived and the manual value is stale, so keeping the - // protection would only block recovery resets. - static constexpr uint64_t kHeadingFusionTimeToClearYawManual = 30'000'000; - - if ((_time_delayed_us - _time_heading_fusion_start) > kHeadingFusionTimeToClearYawManual) { - _control_status.flags.yaw_manual = false; - } } diff --git a/src/modules/ekf2/EKF/covariance.cpp b/src/modules/ekf2/EKF/covariance.cpp index 4975c8729f5..d5b21cae106 100644 --- a/src/modules/ekf2/EKF/covariance.cpp +++ b/src/modules/ekf2/EKF/covariance.cpp @@ -394,5 +394,8 @@ void Ekf::resetMagBiasCov() ECL_INFO("reset mag bias covariance"); P.uncorrelateCovarianceSetVariance(State::mag_B.idx, sq(_params.ekf2_mag_noise)); + + _mag_bias_reset_heading = getEulerYaw(_R_to_earth); + _mag_bias_observable = false; } #endif // CONFIG_EKF2_MAGNETOMETER diff --git a/src/modules/ekf2/EKF/ekf.cpp b/src/modules/ekf2/EKF/ekf.cpp index fecfcb6d8c3..245d7647d03 100644 --- a/src/modules/ekf2/EKF/ekf.cpp +++ b/src/modules/ekf2/EKF/ekf.cpp @@ -112,7 +112,6 @@ void Ekf::reset() _time_last_ver_vel_fuse = 0; _time_last_heading_fuse = 0; _time_last_terrain_fuse = 0; - _time_heading_fusion_start = 0; _last_known_gpos.setZero(); @@ -460,6 +459,10 @@ void Ekf::updateParameters() _aux_global_position.paramsUpdated(); #endif // CONFIG_EKF2_AUX_GLOBAL_POSITION + +#if defined(CONFIG_EKF2_OPTICAL_FLOW) && defined(MODULE_NAME) + _flow_aiding.updateParams(); +#endif // CONFIG_EKF2_OPTICAL_FLOW && MODULE_NAME } template @@ -586,7 +589,11 @@ void Ekf::print_status() #endif // CONFIG_EKF2_MAGNETOMETER #if defined(CONFIG_EKF2_OPTICAL_FLOW) - printRingBuffer("flow buffer", _flow_buffer); + + for (uint8_t i = 0; i < MAX_OF_INSTANCES; i++) { + printRingBuffer("flow buffer", _flow_aiding.source(i)._buffer); + } + #endif // CONFIG_EKF2_OPTICAL_FLOW #if defined(CONFIG_EKF2_RANGE_FINDER) diff --git a/src/modules/ekf2/EKF/ekf.h b/src/modules/ekf2/EKF/ekf.h index aae313c2945..d2e7f7fd976 100644 --- a/src/modules/ekf2/EKF/ekf.h +++ b/src/modules/ekf2/EKF/ekf.h @@ -137,20 +137,15 @@ public: #endif // CONFIG_EKF2_RANGE_FINDER #if defined(CONFIG_EKF2_OPTICAL_FLOW) - const auto &aid_src_optical_flow() const { return _aid_src_optical_flow; } + const auto &aid_src_optical_flow(uint8_t slot = 0) const { return _flow_aiding.source(slot)._aid_src; } - const Vector2f &getFlowVelBody() const { return _flow_vel_body; } - Vector2f getFlowVelNE() const { return Vector2f(_R_to_earth * Vector3f(getFlowVelBody()(0), getFlowVelBody()(1), 0.f)); } + const Vector2f &getFlowVelBody(uint8_t slot = 0) const { return _flow_aiding.source(slot)._vel_body; } + Vector2f getFlowVelNE(uint8_t slot = 0) const { return Vector2f(_R_to_earth * Vector3f(getFlowVelBody(slot)(0), getFlowVelBody(slot)(1), 0.f)); } - const Vector2f &getFilteredFlowVelBody() const { return _flow_vel_body_lpf.getState(); } - Vector2f getFilteredFlowVelNE() const { return Vector2f(_R_to_earth * Vector3f(getFilteredFlowVelBody()(0), getFilteredFlowVelBody()(1), 0.f)); } + const Vector2f &getFilteredFlowVelBody(uint8_t slot = 0) const { return _flow_aiding.source(slot)._vel_body_lpf.getState(); } + Vector2f getFilteredFlowVelNE(uint8_t slot = 0) const { return Vector2f(_R_to_earth * Vector3f(getFilteredFlowVelBody(slot)(0), getFilteredFlowVelBody(slot)(1), 0.f)); } - const Vector2f &getFlowCompensated() const { return _flow_rate_compensated; } - const Vector2f &getFlowUncompensated() const { return _flow_sample_delayed.flow_rate; } - - const Vector3f getFlowGyro() const { return _flow_sample_delayed.gyro_rate; } - const Vector3f &getFlowGyroBias() const { return _flow_gyro_bias; } - const Vector3f &getFlowRefBodyRate() const { return _ref_body_rate; } + uint8_t getPrimaryFlowSlot() const { return _flow_aiding.primarySlot(); } #endif // CONFIG_EKF2_OPTICAL_FLOW #if defined(CONFIG_EKF2_AUX_GLOBAL_POSITION) && defined(MODULE_NAME) @@ -324,6 +319,7 @@ public: const Vector3f &getMagBias() const { return _state.mag_B; } Vector3f getMagBiasVariance() const { return getStateVariance(); } // get the mag bias variance in Gauss float getMagBiasLimit() const { return 0.5f; } // 0.5 Gauss + bool isMagBiasObservable() const { return _mag_bias_observable; } #endif // CONFIG_EKF2_MAGNETOMETER bool accel_bias_inhibited() const { return _accel_bias_inhibit[0] || _accel_bias_inhibit[1] || _accel_bias_inhibit[2]; } @@ -487,6 +483,8 @@ public: friend class AuxGlobalPosition; friend class AgpSource; friend class EkfFlowFusionOrderTest; + friend class OpticalFlowAiding; + friend class OpticalFlowSource; private: @@ -551,7 +549,6 @@ private: uint64_t _time_last_hor_vel_fuse{0}; ///< time the last fusion of horizontal velocity measurements was performed (uSec) uint64_t _time_last_ver_vel_fuse{0}; ///< time the last fusion of verticalvelocity measurements was performed (uSec) uint64_t _time_last_heading_fuse{0}; - uint64_t _time_heading_fusion_start{0}; ///< start of the current uninterrupted period of heading observation fusion, while yaw was set manually (uSec) uint64_t _time_last_terrain_fuse{0}; LatLonAlt _last_known_gpos{}; @@ -588,22 +585,6 @@ private: estimator_aid_source1d_s _aid_src_rng_hgt {}; #endif // CONFIG_EKF2_RANGE_FINDER -#if defined(CONFIG_EKF2_OPTICAL_FLOW) - estimator_aid_source2d_s _aid_src_optical_flow {}; - - // optical flow processing - Vector3f _flow_gyro_bias{}; ///< bias errors in optical flow sensor rate gyro outputs (rad/sec) - Vector3f _ref_body_rate{}; - - Vector2f _flow_vel_body{}; ///< velocity from corrected flow measurement (body frame)(m/s) - AlphaFilter _flow_vel_body_lpf{_kSensorLpfTimeConstant}; ///< filtered velocity from corrected flow measurement (body frame)(m/s) - uint32_t _flow_counter{0}; ///< number of flow samples read for initialization - - Vector2f _flow_rate_compensated{}; ///< measured angular rate of the image about the X and Y body axes after removal of body rotation (rad/s), RH rotation is positive - AlphaFilter _flow_rate_compensated_lpf{_kSensorLpfTimeConstant}; - uint64_t _flow_lpf_time_last_us{0}; -#endif // CONFIG_EKF2_OPTICAL_FLOW - #if defined(CONFIG_EKF2_AIRSPEED) estimator_aid_source1d_s _aid_src_airspeed {}; #endif // CONFIG_EKF2_AIRSPEED @@ -696,6 +677,9 @@ private: // Variables used to control activation of post takeoff functionality uint64_t _flt_mag_align_start_time{0}; ///< time that inflight magnetic field alignment started (uSec) uint64_t _time_last_mag_check_failing{0}; + + float _mag_bias_reset_heading{0.f}; ///< heading at the last mag bias reset, moved along with heading resets (rad) + bool _mag_bias_observable{false}; ///< true when the vehicle has yawed enough since the last mag bias reset #endif // CONFIG_EKF2_MAGNETOMETER // variables used to inhibit accel bias learning @@ -833,6 +817,7 @@ private: #if defined(CONFIG_EKF2_TERRAIN) void initTerrain(); + void resetTerrainTo(float new_terrain, float var); float getTerrainVPos() const { return isTerrainEstimateValid() ? _state.terrain : _last_on_ground_posD; } void controlTerrainFakeFusion(); @@ -846,10 +831,6 @@ private: float getRngVar() const; # endif // CONFIG_EKF2_RANGE_FINDER -# if defined(CONFIG_EKF2_OPTICAL_FLOW) - void resetTerrainToFlow(); -# endif // CONFIG_EKF2_OPTICAL_FLOW - #endif // CONFIG_EKF2_TERRAIN #if defined(CONFIG_EKF2_RANGE_FINDER) @@ -861,27 +842,12 @@ private: #endif // CONFIG_EKF2_RANGE_FINDER #if defined(CONFIG_EKF2_OPTICAL_FLOW) - // control fusion of optical flow observations - void controlOpticalFlowFusion(const imuSample &imu_delayed); - void resetFlowFusion(const flowSample &flow_sample); - void stopFlowFusion(); - - void updateOnGroundMotionForOpticalFlowChecks(); - void resetOnGroundMotionForOpticalFlowChecks(); - - // calculate the measurement variance for the optical flow sensor (rad/sec)^2 - float calcOptFlowMeasVar(const flowSample &flow_sample) const; - - // calculate optical flow body angular rate compensation - void calcOptFlowBodyRateComp(const flowSample &flow_sample); - - float predictFlowHagl() const; - float predictFlowRange() const; - Vector2f predictFlow(const Vector3f &flow_gyro) const; + float predictFlowHagl(const Vector3f &sensor_pos_body) const; + float predictFlowRange(const Vector3f &sensor_pos_body) const; + Vector2f predictFlow(const Vector3f &sensor_pos_body, const Vector3f &flow_gyro) const; // fuse optical flow line of sight rate measurements - bool fuseOptFlow(VectorState &H, bool update_terrain); - + bool fuseOptFlow(estimator_aid_source2d_s &aid_src, VectorState &H, bool update_terrain); #endif // CONFIG_EKF2_OPTICAL_FLOW #if defined(CONFIG_EKF2_MAGNETOMETER) @@ -909,8 +875,6 @@ private: // Control the filter fusion modes void controlFusionModes(const imuSample &imu_delayed); - void updateYawManualValidity(); - #if defined(CONFIG_EKF2_EXTERNAL_VISION) // control fusion of external vision observations void controlExternalVisionFusion(const imuSample &imu_sample); @@ -1019,6 +983,7 @@ private: bool haglYawResetReq(); void checkMagHeadingConsistency(const magSample &mag_sample); + void updateMagBiasObservability(); bool checkMagField(const Vector3f &mag); static bool isMeasuredMatchingExpected(float measured, float expected, float gate); diff --git a/src/modules/ekf2/EKF/ekf_helper.cpp b/src/modules/ekf2/EKF/ekf_helper.cpp index 73d6c5da0a7..6b3cb2bc66e 100644 --- a/src/modules/ekf2/EKF/ekf_helper.cpp +++ b/src/modules/ekf2/EKF/ekf_helper.cpp @@ -342,7 +342,7 @@ void Ekf::get_ekf_vel_accuracy(float *ekf_evh, float *ekf_evv) const if (_control_status.flags.opt_flow) { float gndclearance = math::max(_params.ekf2_min_rng, 0.1f); - vel_err_conservative = math::max(getHagl(), gndclearance) * Vector2f(_aid_src_optical_flow.innovation).norm(); + vel_err_conservative = math::max(getHagl(), gndclearance) * _flow_aiding.maxActiveInnovNorm(); } #endif // CONFIG_EKF2_OPTICAL_FLOW @@ -408,9 +408,10 @@ void Ekf::get_ekf_ctrl_limits(float *vxy_max, float *vz_max, float *hagl_min, fl const bool relying_on_optical_flow = isOnlyActiveSourceOfHorizontalAiding(_control_status.flags.opt_flow); if (relying_on_optical_flow) { - // Calculate optical flow limits - float flow_hagl_min = _flow_min_distance; - float flow_hagl_max = _flow_max_distance; + float flow_hagl_min; + float flow_hagl_max; + float flow_max_rate; + _flow_aiding.getLimits(*this, flow_hagl_min, flow_hagl_max, flow_max_rate); // only limit optical flow height is dependent on range finder or terrain estimate invalid (precaution) if ((!_control_status.flags.opt_flow_terrain && _control_status.flags.rng_terrain) @@ -423,7 +424,7 @@ void Ekf::get_ekf_ctrl_limits(float *vxy_max, float *vz_max, float *hagl_min, fl const float flow_constrained_height = math::constrain(getHagl(), flow_hagl_min, flow_hagl_max); // Allow ground relative velocity to use 50% of available flow sensor range to allow for angular motion - float flow_vxy_max = 0.5f * _flow_max_rate * flow_constrained_height; + float flow_vxy_max = 0.5f * flow_max_rate * flow_constrained_height; flow_hagl_max = math::max(flow_hagl_max * 0.9f, flow_hagl_max - 1.0f); *vxy_max = flow_vxy_max; @@ -518,9 +519,7 @@ float Ekf::getHorizontalVelocityInnovationTestRatio() const #if defined(CONFIG_EKF2_OPTICAL_FLOW) if (isOnlyActiveSourceOfHorizontalAiding(_control_status.flags.opt_flow)) { - for (auto &test_ratio_filtered : _aid_src_optical_flow.test_ratio_filtered) { - test_ratio = math::max(test_ratio, fabsf(test_ratio_filtered)); - } + test_ratio = math::max(test_ratio, _flow_aiding.maxActiveTestRatioFiltered()); } #endif // CONFIG_EKF2_OPTICAL_FLOW @@ -687,10 +686,14 @@ float Ekf::getHeightAboveGroundInnovationTestRatio() const # if defined(CONFIG_EKF2_OPTICAL_FLOW) - if (_control_status.flags.opt_flow_terrain) { - hagl_sum += sqrtf(math::max(fabsf(_aid_src_optical_flow.test_ratio_filtered[0]), - _aid_src_optical_flow.test_ratio_filtered[1])); - n_hagl_sources++; + for (uint8_t i = 0; i < MAX_OF_INSTANCES; i++) { + const OpticalFlowSource &src = _flow_aiding.source(i); + + if (src._terrain) { + hagl_sum += sqrtf(math::max(fabsf(src._aid_src.test_ratio_filtered[0]), + src._aid_src.test_ratio_filtered[1])); + n_hagl_sources++; + } } # endif // CONFIG_EKF2_OPTICAL_FLOW @@ -868,13 +871,13 @@ void Ekf::updateHorizontalDeadReckoningstatus() // optical flow active if (_control_status.flags.opt_flow - && isRecent(_aid_src_optical_flow.time_last_fuse, _params.no_aid_timeout_max) + && isRecent(_flow_aiding.timeLastFuse(), _params.no_aid_timeout_max) ) { inertial_dead_reckoning = false; } else { if (!_control_status.flags.in_air && _fc.of.intended() - && isRecent(_aid_src_optical_flow.timestamp_sample, _params.no_aid_timeout_max) + && isRecent(_flow_aiding.latestSampleTimestamp(), _params.no_aid_timeout_max) ) { // currently landed, but optical flow aiding should be possible once in air aiding_expected_in_air = true; diff --git a/src/modules/ekf2/EKF/estimator_interface.cpp b/src/modules/ekf2/EKF/estimator_interface.cpp index 6520f0e8ad6..09dd6dc3c00 100644 --- a/src/modules/ekf2/EKF/estimator_interface.cpp +++ b/src/modules/ekf2/EKF/estimator_interface.cpp @@ -64,9 +64,6 @@ EstimatorInterface::~EstimatorInterface() #if defined(CONFIG_EKF2_AIRSPEED) delete _airspeed_buffer; #endif // CONFIG_EKF2_AIRSPEED -#if defined(CONFIG_EKF2_OPTICAL_FLOW) - delete _flow_buffer; -#endif // CONFIG_EKF2_OPTICAL_FLOW #if defined(CONFIG_EKF2_EXTERNAL_VISION) delete _ext_vision_buffer; #endif // CONFIG_EKF2_EXTERNAL_VISION @@ -324,6 +321,12 @@ void EstimatorInterface::setRangeData(const sensor::rangeSample &range_sample) return; } + _time_last_range_sensor_data = _time_latest_us; + pushRangeData(range_sample); +} + +void EstimatorInterface::pushRangeData(const sensor::rangeSample &range_sample) +{ // Allocate the required buffer size if not previously done if (_range_buffer == nullptr) { _range_buffer = new TimestampedRingBuffer(_obs_buffer_length); @@ -357,40 +360,13 @@ void EstimatorInterface::setRangeData(const sensor::rangeSample &range_sample) #endif // CONFIG_EKF2_RANGE_FINDER #if defined(CONFIG_EKF2_OPTICAL_FLOW) -void EstimatorInterface::setOpticalFlowData(const flowSample &flow) +void EstimatorInterface::setOpticalFlowData(const flowSample &flow, uint8_t instance) { if (!_initialised) { return; } - // Allocate the required buffer size if not previously done - if (_flow_buffer == nullptr) { - _flow_buffer = new TimestampedRingBuffer(_imu_buffer_length); - - if (_flow_buffer == nullptr || !_flow_buffer->valid()) { - delete _flow_buffer; - _flow_buffer = nullptr; - printBufferAllocationFailed("flow"); - return; - } - } - - const int64_t time_us = flow.time_us - - static_cast(_params.ekf2_of_delay * 1000) - - static_cast(_dt_ekf_avg * 5e5f); // seconds to microseconds divided by 2 - - // limit data rate to prevent data being lost - if (time_us >= static_cast(_flow_buffer->get_newest().time_us + _min_obs_interval_us)) { - - flowSample optflow_sample_new{flow}; - optflow_sample_new.time_us = time_us; - - _flow_buffer->push(optflow_sample_new); - - } else { - ECL_WARN("optical flow data too fast %" PRIi64 " < %" PRIu64 " + %d", time_us, _flow_buffer->get_newest().time_us, - _min_obs_interval_us); - } + _flow_aiding.setData(flow, instance, _imu_buffer_length, _min_obs_interval_us, _dt_ekf_avg); } #endif // CONFIG_EKF2_OPTICAL_FLOW diff --git a/src/modules/ekf2/EKF/estimator_interface.h b/src/modules/ekf2/EKF/estimator_interface.h index 9cd1c963eec..faa47ba407d 100644 --- a/src/modules/ekf2/EKF/estimator_interface.h +++ b/src/modules/ekf2/EKF/estimator_interface.h @@ -71,6 +71,10 @@ # include "aid_sources/range_finder/sensor_range_finder.hpp" #endif // CONFIG_EKF2_RANGE_FINDER +#if defined(CONFIG_EKF2_OPTICAL_FLOW) +# include "aid_sources/optical_flow/optical_flow_source.hpp" +#endif // CONFIG_EKF2_OPTICAL_FLOW + #include #include #include @@ -123,15 +127,10 @@ public: #if defined(CONFIG_EKF2_OPTICAL_FLOW) // if optical flow sensor gyro delta angles are not available, set gyro_rate vector fields to NaN and the EKF will use its internal gyro data instead - void setOpticalFlowData(const flowSample &flow); + void setOpticalFlowData(const flowSample &flow, uint8_t instance = 0); - // set sensor limitations reported by the optical flow sensor - void set_optical_flow_limits(float max_flow_rate, float min_distance, float max_distance) - { - _flow_max_rate = max_flow_rate; - _flow_min_distance = min_distance; - _flow_max_distance = max_distance; - } + OpticalFlowSource &flowSource(uint8_t instance) { return _flow_aiding.source(instance); } + const OpticalFlowSource &flowSource(uint8_t instance) const { return _flow_aiding.source(instance); } #endif // CONFIG_EKF2_OPTICAL_FLOW #if defined(CONFIG_EKF2_EXTERNAL_VISION) @@ -332,6 +331,7 @@ public: protected: EstimatorInterface() = default; + virtual ~EstimatorInterface(); virtual bool init(uint64_t timestamp) = 0; @@ -372,22 +372,18 @@ protected: #endif // CONFIG_EKF2_EXTERNAL_VISION #if defined(CONFIG_EKF2_RANGE_FINDER) + void pushRangeData(const sensor::rangeSample &range_sample); + TimestampedRingBuffer *_range_buffer {nullptr}; uint64_t _time_last_range_buffer_push{0}; + uint64_t _time_last_range_sensor_data{0}; ///< last sample from a range finder, the optical flow fallback excluded sensor::SensorRangeFinder _range_sensor{}; RangeFinderConsistencyCheck _rng_consistency_check; #endif // CONFIG_EKF2_RANGE_FINDER #if defined(CONFIG_EKF2_OPTICAL_FLOW) - TimestampedRingBuffer *_flow_buffer {nullptr}; - - flowSample _flow_sample_delayed{}; - - // Sensor limitations - float _flow_max_rate{1.0f}; ///< maximum angular flow rate that the optical flow sensor can measure (rad/s) - float _flow_min_distance{0.0f}; ///< minimum distance that the optical flow sensor can operate at (m) - float _flow_max_distance{10.f}; ///< maximum distance that the optical flow sensor can operate at (m) + OpticalFlowAiding _flow_aiding {}; #endif // CONFIG_EKF2_OPTICAL_FLOW float _air_density{atmosphere::kAirDensitySeaLevelStandardAtmos}; // air density (kg/m**3) diff --git a/src/modules/ekf2/EKF/terrain_control.cpp b/src/modules/ekf2/EKF/terrain_control.cpp index df3b88cc672..c28171e707e 100644 --- a/src/modules/ekf2/EKF/terrain_control.cpp +++ b/src/modules/ekf2/EKF/terrain_control.cpp @@ -49,6 +49,25 @@ void Ekf::initTerrain() P.uncorrelateCovarianceSetVariance(State::terrain.idx, sq(_params.ekf2_min_rng)); } +void Ekf::resetTerrainTo(const float new_terrain, const float var) +{ + const float delta_terrain = new_terrain - _state.terrain; + + _state.terrain = new_terrain; + P.uncorrelateCovarianceSetVariance(State::terrain.idx, var); + + // record the state change + if (_state_reset_status.reset_count.hagl == _state_reset_count_prev.hagl) { + _state_reset_status.hagl_change = delta_terrain; + + } else { + // there's already a reset this update, accumulate total delta + _state_reset_status.hagl_change += delta_terrain; + } + + _state_reset_status.reset_count.hagl++; +} + void Ekf::controlTerrainFakeFusion() { // If we are on ground, store the local position and time to use as a reference @@ -84,7 +103,7 @@ void Ekf::updateTerrainValidity() #if defined(CONFIG_EKF2_OPTICAL_FLOW) if (_control_status.flags.opt_flow_terrain - && isRecent(_aid_src_optical_flow.time_last_fuse, _params.hgt_fusion_timeout_max) + && isRecent(_flow_aiding.timeLastFuse(), _params.hgt_fusion_timeout_max) ) { valid_opt_flow_terrain = true; } diff --git a/src/modules/ekf2/EKF/yaw_fusion.cpp b/src/modules/ekf2/EKF/yaw_fusion.cpp index 816d3f842a0..163cf99a514 100644 --- a/src/modules/ekf2/EKF/yaw_fusion.cpp +++ b/src/modules/ekf2/EKF/yaw_fusion.cpp @@ -158,6 +158,12 @@ void Ekf::propagateQuatReset(const Quatf &quat_before_reset) #endif // CONFIG_EKF2_EXTERNAL_VISION +#if defined(CONFIG_EKF2_MAGNETOMETER) + // The reference follows heading resets, so that only a rotation of the vehicle counts + const float heading_change = wrap_pi(getEulerYaw(_state.quat_nominal) - getEulerYaw(quat_before_reset)); + _mag_bias_reset_heading = wrap_pi(_mag_bias_reset_heading + heading_change); +#endif // CONFIG_EKF2_MAGNETOMETER + // record the state change if (_state_reset_status.reset_count.quat == _state_reset_count_prev.quat) { _state_reset_status.quat_change = q_error; diff --git a/src/modules/ekf2/EKF2.cpp b/src/modules/ekf2/EKF2.cpp index ac8207b56f7..52a6854008c 100644 --- a/src/modules/ekf2/EKF2.cpp +++ b/src/modules/ekf2/EKF2.cpp @@ -212,19 +212,6 @@ EKF2::EKF2(bool multi_mode, const px4::wq_config_t &config, bool replay_mode): _param_ekf2_ev_pos_y(_params->ev_pos_body(1)), _param_ekf2_ev_pos_z(_params->ev_pos_body(2)), #endif // CONFIG_EKF2_EXTERNAL_VISION -#if defined(CONFIG_EKF2_OPTICAL_FLOW) - _param_ekf2_of_ctrl(_params->ekf2_of_ctrl), - _param_ekf2_of_gyr_src(_params->ekf2_of_gyr_src), - _param_ekf2_of_delay(_params->ekf2_of_delay), - _param_ekf2_of_n_min(_params->ekf2_of_n_min), - _param_ekf2_of_n_max(_params->ekf2_of_n_max), - _param_ekf2_of_qmin(_params->ekf2_of_qmin), - _param_ekf2_of_qmin_gnd(_params->ekf2_of_qmin_gnd), - _param_ekf2_of_gate(_params->ekf2_of_gate), - _param_ekf2_of_pos_x(_params->flow_pos_body(0)), - _param_ekf2_of_pos_y(_params->flow_pos_body(1)), - _param_ekf2_of_pos_z(_params->flow_pos_body(2)), -#endif // CONFIG_EKF2_OPTICAL_FLOW #if defined(CONFIG_EKF2_DRAG_FUSION) _param_ekf2_drag_ctrl(_params->ekf2_drag_ctrl), _param_ekf2_drag_noise(_params->ekf2_drag_noise), @@ -384,15 +371,6 @@ void EKF2::AdvertiseTopics() #endif // CONFIG_EKF2_MAGNETOMETER -#if defined(CONFIG_EKF2_OPTICAL_FLOW) - - if (_param_ekf2_of_ctrl.get()) { - _estimator_optical_flow_vel_pub.advertise(); - _estimator_aid_src_optical_flow_pub.advertise(); - } - -#endif // CONFIG_EKF2_OPTICAL_FLOW - #if defined(CONFIG_EKF2_RANGE_FINDER) // RNG advertise @@ -489,6 +467,7 @@ void EKF2::Run() // update parameters from storage updateParams(); + initFusionControl(); VerifyParams(); @@ -858,9 +837,6 @@ void EKF2::Run() #if defined(CONFIG_EKF2_EXTERNAL_VISION) UpdateExtVisionSample(ekf2_timestamps); #endif // CONFIG_EKF2_EXTERNAL_VISION -#if defined(CONFIG_EKF2_OPTICAL_FLOW) - UpdateFlowSample(ekf2_timestamps); -#endif // CONFIG_EKF2_OPTICAL_FLOW #if defined(CONFIG_EKF2_GNSS) UpdateGnssSample(ekf2_timestamps); # if defined(CONFIG_EKF2_GNSS_YAW) @@ -929,10 +905,6 @@ void EKF2::Run() PublishYawEstimatorStatus(now); #endif // CONFIG_EKF2_GNSS -#if defined(CONFIG_EKF2_OPTICAL_FLOW) - PublishOpticalFlowVel(now); -#endif // CONFIG_EKF2_OPTICAL_FLOW - UpdateAccelCalibration(now); UpdateGyroCalibration(now); #if defined(CONFIG_EKF2_MAGNETOMETER) @@ -1033,8 +1005,8 @@ void EKF2::VerifyParams() #if defined(CONFIG_EKF2_OPTICAL_FLOW) - if (_param_ekf2_of_delay.get() > delay_max) { - delay_max = _param_ekf2_of_delay.get(); + for (uint8_t i = 0; i < MAX_OF_INSTANCES; i++) { + delay_max = math::max(delay_max, _ekf.flowSource(i).delayMs()); } #endif // CONFIG_EKF2_OPTICAL_FLOW @@ -1244,11 +1216,6 @@ void EKF2::PublishAidSourceStatus(const hrt_abstime ×tamp) PublishAidSourceStatus(timestamp, _ekf.aid_src_aux_vel(), _status_aux_vel_pub_last, _estimator_aid_src_aux_vel_pub); #endif // CONFIG_EKF2_AUXVEL -#if defined(CONFIG_EKF2_OPTICAL_FLOW) - // optical flow - PublishAidSourceStatus(timestamp, _ekf.aid_src_optical_flow(), _status_optical_flow_pub_last, - _estimator_aid_src_optical_flow_pub); -#endif // CONFIG_EKF2_OPTICAL_FLOW } void EKF2::PublishAttitude(const hrt_abstime ×tamp) @@ -1489,9 +1456,9 @@ void EKF2::PublishInnovations(const hrt_abstime ×tamp) #endif // CONFIG_EKF2_AUXVEL #if defined(CONFIG_EKF2_OPTICAL_FLOW) - // Optical flow - innovations.flow[0] = _ekf.aid_src_optical_flow().innovation[0]; - innovations.flow[1] = _ekf.aid_src_optical_flow().innovation[1]; + // Optical flow (primary slot only, per-slot data is in estimator_aid_src_optical_flow) + innovations.flow[0] = _ekf.aid_src_optical_flow(_ekf.getPrimaryFlowSlot()).innovation[0]; + innovations.flow[1] = _ekf.aid_src_optical_flow(_ekf.getPrimaryFlowSlot()).innovation[1]; #endif // CONFIG_EKF2_OPTICAL_FLOW // heading @@ -1582,9 +1549,9 @@ void EKF2::PublishInnovationTestRatios(const hrt_abstime ×tamp) #endif // CONFIG_EKF2_AUXVEL #if defined(CONFIG_EKF2_OPTICAL_FLOW) - // Optical flow - test_ratios.flow[0] = _ekf.aid_src_optical_flow().test_ratio[0]; - test_ratios.flow[1] = _ekf.aid_src_optical_flow().test_ratio[1]; + // Optical flow (primary slot only, per-slot data is in estimator_aid_src_optical_flow) + test_ratios.flow[0] = _ekf.aid_src_optical_flow(_ekf.getPrimaryFlowSlot()).test_ratio[0]; + test_ratios.flow[1] = _ekf.aid_src_optical_flow(_ekf.getPrimaryFlowSlot()).test_ratio[1]; #endif // CONFIG_EKF2_OPTICAL_FLOW // heading @@ -1675,9 +1642,9 @@ void EKF2::PublishInnovationVariances(const hrt_abstime ×tamp) #endif // CONFIG_EKF2_AUXVEL #if defined(CONFIG_EKF2_OPTICAL_FLOW) - // Optical flow - variances.flow[0] = _ekf.aid_src_optical_flow().innovation_variance[0]; - variances.flow[1] = _ekf.aid_src_optical_flow().innovation_variance[1]; + // Optical flow (primary slot only, per-slot data is in estimator_aid_src_optical_flow) + variances.flow[0] = _ekf.aid_src_optical_flow(_ekf.getPrimaryFlowSlot()).innovation_variance[0]; + variances.flow[1] = _ekf.aid_src_optical_flow(_ekf.getPrimaryFlowSlot()).innovation_variance[1]; #endif // CONFIG_EKF2_OPTICAL_FLOW // heading @@ -2246,39 +2213,6 @@ void EKF2::PublishWindEstimate(const hrt_abstime ×tamp) } #endif // CONFIG_EKF2_WIND -#if defined(CONFIG_EKF2_OPTICAL_FLOW) -void EKF2::PublishOpticalFlowVel(const hrt_abstime ×tamp) -{ - const hrt_abstime timestamp_sample = _ekf.aid_src_optical_flow().timestamp_sample; - - if ((timestamp_sample != 0) && (timestamp_sample > _optical_flow_vel_pub_last)) { - - vehicle_optical_flow_vel_s flow_vel{}; - flow_vel.timestamp_sample = _ekf.aid_src_optical_flow().timestamp_sample; - - _ekf.getFlowVelBody().copyTo(flow_vel.vel_body); - _ekf.getFlowVelNE().copyTo(flow_vel.vel_ne); - - _ekf.getFilteredFlowVelBody().copyTo(flow_vel.vel_body_filtered); - _ekf.getFilteredFlowVelNE().copyTo(flow_vel.vel_ne_filtered); - - _ekf.getFlowUncompensated().copyTo(flow_vel.flow_rate_uncompensated); - _ekf.getFlowCompensated().copyTo(flow_vel.flow_rate_compensated); - - _ekf.getFlowGyro().copyTo(flow_vel.gyro_rate); - - _ekf.getFlowGyroBias().copyTo(flow_vel.gyro_bias); - _ekf.getFlowRefBodyRate().copyTo(flow_vel.ref_gyro); - - flow_vel.timestamp = _replay_mode ? timestamp : hrt_absolute_time(); - - _estimator_optical_flow_vel_pub.publish(flow_vel); - - _optical_flow_vel_pub_last = timestamp_sample; - } -} -#endif // CONFIG_EKF2_OPTICAL_FLOW - #if defined(CONFIG_EKF2_AIRSPEED) void EKF2::UpdateAirspeedSample(ekf2_timestamps_s &ekf2_timestamps) { @@ -2582,77 +2516,6 @@ bool EKF2::UpdateExtVisionSample(ekf2_timestamps_s &ekf2_timestamps) } #endif // CONFIG_EKF2_EXTERNAL_VISION -#if defined(CONFIG_EKF2_OPTICAL_FLOW) -bool EKF2::UpdateFlowSample(ekf2_timestamps_s &ekf2_timestamps) -{ - // EKF flow sample - bool new_optical_flow = false; - vehicle_optical_flow_s optical_flow; - - if (_vehicle_optical_flow_sub.update(&optical_flow)) { - - const float dt = 1e-6f * (float)optical_flow.integration_timespan_us; - Vector2f flow_rate; - Vector3f gyro_rate; - - if (dt > FLT_EPSILON) { - // NOTE: the EKF uses the reverse sign convention to the flow sensor. EKF assumes positive LOS rate - // is produced by a RH rotation of the image about the sensor axis. - flow_rate = Vector2f(-optical_flow.pixel_flow[0], -optical_flow.pixel_flow[1]) / dt; - gyro_rate = Vector3f(-optical_flow.delta_angle[0], -optical_flow.delta_angle[1], -optical_flow.delta_angle[2]) / dt; - - } else if (optical_flow.quality == 0) { - // handle special case of SITL and PX4Flow where dt is forced to zero when the quaity is 0 - flow_rate.zero(); - gyro_rate.zero(); - } - - flowSample flow { - .time_us = optical_flow.timestamp_sample - optical_flow.integration_timespan_us / 2, // correct timestamp to midpoint of integration interval as the data is converted to rates - .flow_rate = flow_rate, - .gyro_rate = gyro_rate, - .quality = optical_flow.quality - }; - - if (Vector2f(optical_flow.pixel_flow).isAllFinite() && optical_flow.integration_timespan_us < 1e6) { - - // Save sensor limits reported by the optical flow sensor - _ekf.set_optical_flow_limits(optical_flow.max_flow_rate, optical_flow.min_ground_distance, - optical_flow.max_ground_distance); - - _ekf.setOpticalFlowData(flow); - - new_optical_flow = true; - } - -#if defined(CONFIG_EKF2_RANGE_FINDER) - - // use optical_flow distance as range sample if distance_sensor unavailable - if (PX4_ISFINITE(optical_flow.distance_m) && (ekf2_timestamps.timestamp > _last_range_sensor_update + 1_s)) { - - int8_t quality = static_cast(optical_flow.quality) / static_cast(UINT8_MAX) * 100.f; - - estimator::sensor::rangeSample range_sample { - .time_us = optical_flow.timestamp_sample, - .rng = optical_flow.distance_m, - .quality = quality, - }; - _ekf.setRangeData(range_sample); - - // set sensor limits - _ekf.set_rangefinder_limits(optical_flow.min_ground_distance, optical_flow.max_ground_distance); - } - -#endif // CONFIG_EKF2_RANGE_FINDER - - ekf2_timestamps.optical_flow_timestamp_rel = (int16_t)((int64_t)optical_flow.timestamp / 100 - - (int64_t)ekf2_timestamps.timestamp / 100); - } - - return new_optical_flow; -} -#endif // CONFIG_EKF2_OPTICAL_FLOW - #if defined(CONFIG_EKF2_GNSS) void EKF2::UpdateGnssSample(ekf2_timestamps_s &ekf2_timestamps) { @@ -3030,6 +2893,7 @@ void EKF2::UpdateMagCalibration(const hrt_abstime ×tamp) const bool bias_valid = (_ekf.fault_status().value == 0) && _ekf.control_status_flags().yaw_align + && _ekf.isMagBiasObservable() && mag_bias_var.longerThan(0.f) && !mag_bias_var.longerThan(0.02f); const bool learning_valid = bias_valid && _ekf.control_status_flags().mag; diff --git a/src/modules/ekf2/EKF2.hpp b/src/modules/ekf2/EKF2.hpp index a1fb2c67652..0f9b932ab41 100644 --- a/src/modules/ekf2/EKF2.hpp +++ b/src/modules/ekf2/EKF2.hpp @@ -112,11 +112,6 @@ # include #endif // CONFIG_EKF2_MAGNETOMETER -#if defined(CONFIG_EKF2_OPTICAL_FLOW) -# include -# include -#endif // CONFIG_EKF2_OPTICAL_FLOW - #if defined(CONFIG_EKF2_RANGE_FINDER) # include #endif // CONFIG_EKF2_RANGE_FINDER @@ -230,10 +225,6 @@ private: void UpdateGnssYawSample(); # endif // CONFIG_EKF2_GNSS_YAW #endif // CONFIG_EKF2_GNSS -#if defined(CONFIG_EKF2_OPTICAL_FLOW) - bool UpdateFlowSample(ekf2_timestamps_s &ekf2_timestamps); - void PublishOpticalFlowVel(const hrt_abstime ×tamp); -#endif // CONFIG_EKF2_OPTICAL_FLOW #if defined(CONFIG_EKF2_MAGNETOMETER) void UpdateMagSample(ekf2_timestamps_s &ekf2_timestamps); #endif // CONFIG_EKF2_MAGNETOMETER @@ -346,15 +337,6 @@ private: uORB::Subscription _ranging_beacon_sub {ORB_ID(ranging_beacon)}; #endif // CONFIG_EKF2_RANGING_BEACON -#if defined(CONFIG_EKF2_OPTICAL_FLOW) - uORB::Subscription _vehicle_optical_flow_sub {ORB_ID(vehicle_optical_flow)}; - uORB::PublicationMulti _estimator_optical_flow_vel_pub{ORB_ID(estimator_optical_flow_vel)}; - - uORB::PublicationMulti _estimator_aid_src_optical_flow_pub{ORB_ID(estimator_aid_src_optical_flow)}; - hrt_abstime _status_optical_flow_pub_last{0}; - hrt_abstime _optical_flow_vel_pub_last{0}; -#endif // CONFIG_EKF2_OPTICAL_FLOW - #if defined(CONFIG_EKF2_BAROMETER) uint8_t _baro_calibration_count {0}; uint32_t _device_id_baro{0}; @@ -687,32 +669,6 @@ private: (ParamExtFloat) _param_ekf2_ev_pos_z, ///< Z position of VI sensor focal point in body frame (m) #endif // CONFIG_EKF2_EXTERNAL_VISION -#if defined(CONFIG_EKF2_OPTICAL_FLOW) - // optical flow fusion - (ParamExtInt) - _param_ekf2_of_ctrl, - (ParamExtInt) - _param_ekf2_of_gyr_src, - (ParamExtFloat) - _param_ekf2_of_delay, ///< optical flow measurement delay relative to the IMU (mSec) - this is to the middle of the optical flow integration interval - (ParamExtFloat) - _param_ekf2_of_n_min, ///< best quality observation noise for optical flow LOS rate measurements (rad/sec) - (ParamExtFloat) - _param_ekf2_of_n_max, ///< worst quality observation noise for optical flow LOS rate measurements (rad/sec) - (ParamExtInt) - _param_ekf2_of_qmin, ///< minimum acceptable quality integer from the flow sensor when in air - (ParamExtInt) - _param_ekf2_of_qmin_gnd, ///< minimum acceptable quality integer from the flow sensor when on ground - (ParamExtFloat) - _param_ekf2_of_gate, ///< optical flow fusion innovation consistency gate size (STD) - (ParamExtFloat) - _param_ekf2_of_pos_x, ///< X position of optical flow sensor focal point in body frame (m) - (ParamExtFloat) - _param_ekf2_of_pos_y, ///< Y position of optical flow sensor focal point in body frame (m) - (ParamExtFloat) - _param_ekf2_of_pos_z, ///< Z position of optical flow sensor focal point in body frame (m) -#endif // CONFIG_EKF2_OPTICAL_FLOW - #if defined(CONFIG_EKF2_DRAG_FUSION) (ParamExtInt) _param_ekf2_drag_ctrl, ///< drag fusion selection // Multi-rotor drag specific force fusion diff --git a/src/modules/ekf2/EKF2Selector.cpp b/src/modules/ekf2/EKF2Selector.cpp index 96425d852d2..7e15d36d626 100644 --- a/src/modules/ekf2/EKF2Selector.cpp +++ b/src/modules/ekf2/EKF2Selector.cpp @@ -174,8 +174,8 @@ bool EKF2Selector::UpdateErrorScores() _last_update_us = sensors_status_imu.timestamp; { - const float angle_rate_threshold = radians(_param_ekf2_sel_imu_angle_rate.get()); - const float angle_threshold = radians(_param_ekf2_sel_imu_angle.get()); + const float angle_rate_threshold = radians(_param_ekf2_sel_imu_rat.get()); + const float angle_threshold = radians(_param_ekf2_sel_imu_ang.get()); uint8_t n_gyros = 0; uint8_t n_gyro_exceedances = 0; float largest_accumulated_gyro_error = 0.0f; @@ -217,8 +217,8 @@ bool EKF2Selector::UpdateErrorScores() } { - const float accel_threshold = _param_ekf2_sel_imu_accel.get(); - const float velocity_threshold = _param_ekf2_sel_imu_velocity.get(); + const float accel_threshold = _param_ekf2_sel_imu_acc.get(); + const float velocity_threshold = _param_ekf2_sel_imu_vel.get(); uint8_t n_accels = 0; uint8_t n_accel_exceedances = 0; float largest_accumulated_accel_error = 0.0f; diff --git a/src/modules/ekf2/EKF2Selector.hpp b/src/modules/ekf2/EKF2Selector.hpp index e83bc2d7018..67b61ce09f9 100644 --- a/src/modules/ekf2/EKF2Selector.hpp +++ b/src/modules/ekf2/EKF2Selector.hpp @@ -243,10 +243,10 @@ private: DEFINE_PARAMETERS( (ParamFloat) _param_ekf2_sel_err_red, - (ParamFloat) _param_ekf2_sel_imu_angle_rate, - (ParamFloat) _param_ekf2_sel_imu_angle, - (ParamFloat) _param_ekf2_sel_imu_accel, - (ParamFloat) _param_ekf2_sel_imu_velocity + (ParamFloat) _param_ekf2_sel_imu_rat, + (ParamFloat) _param_ekf2_sel_imu_ang, + (ParamFloat) _param_ekf2_sel_imu_acc, + (ParamFloat) _param_ekf2_sel_imu_vel ) }; #endif // !EKF2SELECTOR_HPP diff --git a/src/modules/ekf2/params_optical_flow.yaml b/src/modules/ekf2/params_optical_flow.yaml index 8df8d5ede1f..3d7324b473e 100644 --- a/src/modules/ekf2/params_optical_flow.yaml +++ b/src/modules/ekf2/params_optical_flow.yaml @@ -1,30 +1,20 @@ +__max_num_of_instances: &max_num_of_instances 2 + module_name: ekf2 parameters: - group: EKF2 definitions: - EKF2_OF_CTRL: + EKF2_OF${i}_CTRL: description: - short: Optical flow aiding - long: Enable optical flow fusion. + short: Optical flow sensor ${i} aiding + long: Enable optical flow fusion for sensor slot ${i}. type: boolean - default: 1 - EKF2_OF_DELAY: + default: [1, 0] + num_instances: *max_num_of_instances + instance_start: 0 + EKF2_OF${i}_GATE: description: - short: Optical flow measurement delay relative to IMU measurements - long: |- - Assumes measurement is timestamped at trailing edge of integration - period. The default matches a DroneCAN flow node, whose frame reaches - the flight controller about 7 ms after its integration window closes. - type: float - default: 7 - min: 0 - max: 300 - unit: ms - reboot_required: true - decimal: 1 - EKF2_OF_GATE: - description: - short: Gate size for optical flow fusion + short: Gate size for optical flow sensor ${i} fusion long: Sets the number of standard deviations used by the innovation consistency test. type: float @@ -32,9 +22,11 @@ parameters: min: 1.0 unit: SD decimal: 1 - EKF2_OF_N_MIN: + num_instances: *max_num_of_instances + instance_start: 0 + EKF2_OF${i}_N_MIN: description: - short: Optical flow minimum noise + short: Optical flow sensor ${i} minimum noise long: Measurement noise for the optical flow sensor when it's reported quality metric is at the maximum type: float @@ -42,9 +34,11 @@ parameters: min: 0.05 unit: rad/s decimal: 2 - EKF2_OF_N_MAX: + num_instances: *max_num_of_instances + instance_start: 0 + EKF2_OF${i}_N_MAX: description: - short: Optical flow maximum noise + short: Optical flow sensor ${i} maximum noise long: Measurement noise for the optical flow sensor when it's reported quality metric is at the minimum type: float @@ -52,27 +46,33 @@ parameters: min: 0.05 unit: rad/s decimal: 2 - EKF2_OF_QMIN: + num_instances: *max_num_of_instances + instance_start: 0 + EKF2_OF${i}_QMIN: description: - short: In air optical flow minimum quality + short: In air optical flow sensor ${i} minimum quality long: Optical Flow data will only be used in air if the sensor reports a - quality metric >= EKF2_OF_QMIN + quality metric >= EKF2_OF${i}_QMIN type: int32 default: 1 min: 0 max: 255 - EKF2_OF_QMIN_GND: + num_instances: *max_num_of_instances + instance_start: 0 + EKF2_OF${i}_QMINGND: description: - short: On ground optical flow minimum quality + short: On ground optical flow sensor ${i} minimum quality long: Optical Flow data will only be used on the ground if the sensor reports - a quality metric >= EKF2_OF_QMIN_GND + a quality metric >= EKF2_OF${i}_QMINGND type: int32 default: 0 min: 0 max: 255 - EKF2_OF_GYR_SRC: + num_instances: *max_num_of_instances + instance_start: 0 + EKF2_OF${i}_GYR_SRC: description: - short: Optical flow angular rate compensation source + short: Optical flow sensor ${i} angular rate compensation source long: 'Auto: use gyro from optical flow message if available, internal gyro otherwise. Internal: always use internal gyro' type: enum @@ -80,27 +80,5 @@ parameters: 0: Auto 1: Internal default: 0 - EKF2_OF_POS_X: - description: - short: X position of optical flow focal point in body frame - long: Forward axis with origin relative to vehicle centre of gravity - type: float - default: 0.0 - unit: m - decimal: 3 - EKF2_OF_POS_Y: - description: - short: Y position of optical flow focal point in body frame - long: Forward axis with origin relative to vehicle centre of gravity - type: float - default: 0.0 - unit: m - decimal: 3 - EKF2_OF_POS_Z: - description: - short: Z position of optical flow focal point in body frame - long: Forward axis with origin relative to vehicle centre of gravity - type: float - default: 0.0 - unit: m - decimal: 3 + num_instances: *max_num_of_instances + instance_start: 0 diff --git a/src/modules/ekf2/test/CMakeLists.txt b/src/modules/ekf2/test/CMakeLists.txt index bbaf7a46418..c464042ab6f 100644 --- a/src/modules/ekf2/test/CMakeLists.txt +++ b/src/modules/ekf2/test/CMakeLists.txt @@ -44,6 +44,7 @@ px4_add_unit_gtest(SRC test_EKF_externalVision.cpp LINKLIBS ecl_EKF ecl_sensor_s px4_add_unit_gtest(SRC test_EKF_fake_pos.cpp LINKLIBS ecl_EKF ecl_sensor_sim ecl_test_helper) px4_add_unit_gtest(SRC test_EKF_flow.cpp LINKLIBS ecl_EKF ecl_sensor_sim ecl_test_helper) px4_add_unit_gtest(SRC test_EKF_flow_fusion_order.cpp LINKLIBS ecl_EKF) +px4_add_unit_gtest(SRC test_EKF_flow_multi.cpp LINKLIBS ecl_EKF ecl_sensor_sim) px4_add_unit_gtest(SRC test_EKF_flow_generated.cpp LINKLIBS ecl_EKF ecl_sensor_sim ecl_test_helper) px4_add_unit_gtest(SRC test_EKF_gen_nav.cpp LINKLIBS ecl_EKF ecl_sensor_sim gen_nav) px4_add_unit_gtest(SRC test_EKF_gyroscope.cpp LINKLIBS ecl_EKF ecl_sensor_sim) diff --git a/src/modules/ekf2/test/sensor_simulator/ekf_wrapper.cpp b/src/modules/ekf2/test/sensor_simulator/ekf_wrapper.cpp index 8bd5b821089..6a02607d805 100644 --- a/src/modules/ekf2/test/sensor_simulator/ekf_wrapper.cpp +++ b/src/modules/ekf2/test/sensor_simulator/ekf_wrapper.cpp @@ -173,15 +173,15 @@ bool EkfWrapper::isIntendingGpsHeadingFusion() const return _ekf->control_status_flags().gnss_yaw; } -void EkfWrapper::enableFlowFusion() +void EkfWrapper::enableFlowFusion(uint8_t slot) { - _ekf_params->ekf2_of_ctrl = 1; + _ekf->flowSource(slot).params.ctrl = 1; _fc->of.enabled = true; } -void EkfWrapper::disableFlowFusion() +void EkfWrapper::disableFlowFusion(uint8_t slot) { - _ekf_params->ekf2_of_ctrl = 0; + _ekf->flowSource(slot).params.ctrl = 0; } bool EkfWrapper::isIntendingFlowFusion() const @@ -189,9 +189,9 @@ bool EkfWrapper::isIntendingFlowFusion() const return _ekf->control_status_flags().opt_flow; } -void EkfWrapper::setFlowOffset(const Vector3f &offset) +void EkfWrapper::setFlowOffset(const Vector3f &offset, uint8_t slot) { - _ekf_params->flow_pos_body = offset; + _ekf->flowSource(slot).setPositionBody(offset); } void EkfWrapper::enableExternalVisionPositionFusion() diff --git a/src/modules/ekf2/test/sensor_simulator/ekf_wrapper.h b/src/modules/ekf2/test/sensor_simulator/ekf_wrapper.h index b94311cd481..44bf686fb0a 100644 --- a/src/modules/ekf2/test/sensor_simulator/ekf_wrapper.h +++ b/src/modules/ekf2/test/sensor_simulator/ekf_wrapper.h @@ -87,10 +87,10 @@ public: void disableGpsHeadingFusion(); bool isIntendingGpsHeadingFusion() const; - void enableFlowFusion(); - void disableFlowFusion(); + void enableFlowFusion(uint8_t slot = 0); + void disableFlowFusion(uint8_t slot = 0); bool isIntendingFlowFusion() const; - void setFlowOffset(const matrix::Vector3f &offset); + void setFlowOffset(const matrix::Vector3f &offset, uint8_t slot = 0); void enableExternalVisionPositionFusion(); void disableExternalVisionPositionFusion(); diff --git a/src/modules/ekf2/test/sensor_simulator/flow.cpp b/src/modules/ekf2/test/sensor_simulator/flow.cpp index 929a57a0968..e9894a572c0 100644 --- a/src/modules/ekf2/test/sensor_simulator/flow.cpp +++ b/src/modules/ekf2/test/sensor_simulator/flow.cpp @@ -5,7 +5,7 @@ namespace sensor_simulator namespace sensor { -Flow::Flow(std::shared_ptr ekf): Sensor(ekf) +Flow::Flow(std::shared_ptr ekf, uint8_t instance): Sensor(ekf), _instance(instance) { } @@ -15,8 +15,8 @@ Flow::~Flow() void Flow::send(uint64_t time) { - _flow_data.time_us = time; - _ekf->setOpticalFlowData(_flow_data); + _flow_data.time_us = time - _latency_us; + _ekf->setOpticalFlowData(_flow_data, _instance); } void Flow::setData(const flowSample &flow) diff --git a/src/modules/ekf2/test/sensor_simulator/flow.h b/src/modules/ekf2/test/sensor_simulator/flow.h index 2c0cdf94fcc..61241f453ec 100644 --- a/src/modules/ekf2/test/sensor_simulator/flow.h +++ b/src/modules/ekf2/test/sensor_simulator/flow.h @@ -48,14 +48,17 @@ namespace sensor class Flow: public Sensor { public: - Flow(std::shared_ptr ekf); + Flow(std::shared_ptr ekf, uint8_t instance = 0); ~Flow(); void setData(const flowSample &flow); + void setLatencyUs(uint64_t latency_us) { _latency_us = latency_us; } flowSample dataAtRest(); private: flowSample _flow_data; + uint8_t _instance; + uint64_t _latency_us{0}; void send(uint64_t time) override; diff --git a/src/modules/ekf2/test/sensor_simulator/sensor_simulator.cpp b/src/modules/ekf2/test/sensor_simulator/sensor_simulator.cpp index 1e5f4998672..b572a794ea5 100644 --- a/src/modules/ekf2/test/sensor_simulator/sensor_simulator.cpp +++ b/src/modules/ekf2/test/sensor_simulator/sensor_simulator.cpp @@ -5,6 +5,7 @@ SensorSimulator::SensorSimulator(std::shared_ptr ekf): _airspeed(ekf), _baro(ekf), _flow(ekf), + _flow1(ekf, 1), _gps(ekf), _gnss_yaw(ekf), _imu(ekf), @@ -130,6 +131,7 @@ void SensorSimulator::setSensorRateToDefault() _gps.setRateHz(5); _gnss_yaw.setRateHz(5); _flow.setRateHz(50); + _flow1.setRateHz(50); _rng.setRateHz(30); _vio.setRateHz(30); _airspeed.setRateHz(100); @@ -140,6 +142,7 @@ void SensorSimulator::setSensorDataToDefault() _airspeed.setData(0.0f, 0.0f); _baro.setData(122.2f); _flow.setData(_flow.dataAtRest()); + _flow1.setData(_flow1.dataAtRest()); _gps.setData(_gps.getDefaultGpsData()); _imu.setData(Vector3f{0.0f, 0.0f, -CONSTANTS_ONE_G}, Vector3f{0.0f, 0.0f, 0.0f}); _mag.setData(Vector3f{0.218f, 0.f, 0.43f}); @@ -187,6 +190,7 @@ void SensorSimulator::updateSensors() _gps.update(_time); _gnss_yaw.update(_time); _flow.update(_time); + _flow1.update(_time); _rng.update(_time); _vio.update(_time); _airspeed.update(_time); @@ -358,6 +362,11 @@ void SensorSimulator::setSensorDataFromTrajectory() const Vector3f vel_world{_trajectory[0].getCurrentVelocity(), _trajectory[1].getCurrentVelocity(), _trajectory[2].getCurrentVelocity()}; + const Vector3f pos_world{_trajectory[0].getCurrentPosition(), + _trajectory[1].getCurrentPosition(), + _trajectory[2].getCurrentPosition()}; + const Vector3f delta_pos_world = pos_world - _trajectory_position_prev; + _trajectory_position_prev = pos_world; // IMU const Vector3f earth_gravity = {0.0f, 0.0f, -CONSTANTS_ONE_G}; @@ -387,19 +396,23 @@ void SensorSimulator::setSensorDataFromTrajectory() } // Optical flow - if (_flow.isRunning()) { - flowSample flow_sample = _flow.dataAtRest(); - const Vector3f vel_body = R_world_to_body * vel_world; - flow_sample.flow_rate = - Vector2f(vel_body(1) / distance_to_ground, - -vel_body(0) / distance_to_ground); - _flow.setData(flow_sample); + for (Flow *flow : {&_flow, &_flow1}) { + if (flow->isRunning()) { + flowSample flow_sample = flow->dataAtRest(); + const Vector3f vel_body = R_world_to_body * vel_world; + flow_sample.flow_rate = + Vector2f(vel_body(1) / distance_to_ground, + -vel_body(0) / distance_to_ground); + flow->setData(flow_sample); + } } if (_gps.isRunning()) { - /* _gps.setAltitude(); */ - /* _gps.setLatitude(); */ - /* _gps.setLongitude(); */ + LatLonAlt gps_position(_gps.getData().lat, _gps.getData().lon, _gps.getData().alt); + gps_position += delta_pos_world; + _gps.setLatitude(gps_position.latitude_deg()); + _gps.setLongitude(gps_position.longitude_deg()); + _gps.setAltitude(gps_position.altitude()); _gps.setVelocity(vel_world); } } diff --git a/src/modules/ekf2/test/sensor_simulator/sensor_simulator.h b/src/modules/ekf2/test/sensor_simulator/sensor_simulator.h index d77a88255ed..147305c3b69 100644 --- a/src/modules/ekf2/test/sensor_simulator/sensor_simulator.h +++ b/src/modules/ekf2/test/sensor_simulator/sensor_simulator.h @@ -102,6 +102,9 @@ public: void startFlow() { _flow.start(); } void stopFlow() { _flow.stop(); } + void startFlow1() { _flow1.start(); } + void stopFlow1() { _flow1.stop(); } + void startRangeFinder() { _rng.start(); } void stopRangeFinder() { _rng.stop(); } @@ -126,6 +129,7 @@ public: Airspeed _airspeed; Baro _baro; Flow _flow; + Flow _flow1; // second optical flow sensor (slot 1) Gps _gps; GnssYaw _gnss_yaw; Imu _imu; @@ -134,6 +138,7 @@ public: Vio _vio; VelocitySmoothing _trajectory[3]; + Vector3f _trajectory_position_prev{}; private: void setSensorDataToDefault(); diff --git a/src/modules/ekf2/test/test_EKF_basics.cpp b/src/modules/ekf2/test/test_EKF_basics.cpp index 72f8efcc6f3..ffa00a8d355 100644 --- a/src/modules/ekf2/test/test_EKF_basics.cpp +++ b/src/modules/ekf2/test/test_EKF_basics.cpp @@ -384,7 +384,7 @@ TEST_F(EkfBasicsTest, global_position_from_opt_flow) const float max_flow_rate = 5.f; const float min_ground_distance = 0.f; const float max_ground_distance = 50.f; - _ekf->set_optical_flow_limits(max_flow_rate, min_ground_distance, max_ground_distance); + _ekf->flowSource(0).setLimits(max_flow_rate, min_ground_distance, max_ground_distance); _sensor_simulator.startFlow(); _ekf_wrapper.enableFlowFusion(); _sensor_simulator.startRangeFinder(); diff --git a/src/modules/ekf2/test/test_EKF_flow.cpp b/src/modules/ekf2/test/test_EKF_flow.cpp index f1d535f4863..3cb00a1b1d3 100644 --- a/src/modules/ekf2/test/test_EKF_flow.cpp +++ b/src/modules/ekf2/test/test_EKF_flow.cpp @@ -62,7 +62,7 @@ public: const float max_flow_rate = 5.f; const float min_ground_distance = 0.f; const float max_ground_distance = 50.f; - _ekf->set_optical_flow_limits(max_flow_rate, min_ground_distance, max_ground_distance); + _ekf->flowSource(0).setLimits(max_flow_rate, min_ground_distance, max_ground_distance); // run briefly to init, then manually set in air and at rest (default for a real vehicle) _ekf->init(0); diff --git a/src/modules/ekf2/test/test_EKF_flow_fusion_order.cpp b/src/modules/ekf2/test/test_EKF_flow_fusion_order.cpp index de8f1b769f4..651a06e2978 100644 --- a/src/modules/ekf2/test/test_EKF_flow_fusion_order.cpp +++ b/src/modules/ekf2/test/test_EKF_flow_fusion_order.cpp @@ -53,11 +53,14 @@ public: using SquareMatrixState = Ekf::SquareMatrixState; using Vector25 = Vector; + static constexpr float kGate = 3.f; + std::shared_ptr _ekf{std::make_shared()}; StateSample _x0{}; LatLonAlt _gpos0{0.0, 0.0, 0.f}; SquareMatrixState _P0{}; + estimator_aid_source2d_s _aid_src{}; void SetUp() override { @@ -66,10 +69,6 @@ public: _ekf->_control_status.flags.heading_observable = true; _ekf->_control_status.flags.mag = false; _ekf->_time_delayed_us = 1'000'000; - _ekf->_params.ekf2_of_gate = 3.f; - _ekf->_flow_gyro_bias.setZero(); - _ekf->_flow_sample_delayed.gyro_rate.setZero(); - _ekf->_flow_sample_delayed.quality = 255; } // a priori state and covariance: uncertain velocity, attitude and terrain with cross-correlations; @@ -130,7 +129,7 @@ public: const StateSample &state() const { return _ekf->_state; } const SquareMatrixState &covariance() const { return _ekf->P; } - const estimator_aid_source2d_s &flowAidSrc() const { return _ekf->_aid_src_optical_flow; } + const estimator_aid_source2d_s &flowAidSrc() const { return _aid_src; } // observation jacobians and innovation variances of both flow components at the prior void lineariseFlow(float R, VectorState &Hx, VectorState &Hy, Vector2f &innov_var) @@ -178,11 +177,11 @@ public: { restorePrior(); // PX4 convention: innovation = prediction - observation - const Vector2f observation = _ekf->predictFlow(_ekf->_flow_sample_delayed.gyro_rate) - innov; - _ekf->updateAidSourceStatus(_ekf->_aid_src_optical_flow, _ekf->_time_delayed_us, observation, Vector2f(R, R), - innov, innov_var, _ekf->_params.ekf2_of_gate); + const Vector2f observation = _ekf->predictFlow(Vector3f(), Vector3f()) - innov; + _ekf->updateAidSourceStatus(_aid_src, _ekf->_time_delayed_us, observation, Vector2f(R, R), + innov, innov_var, kGate); VectorState H = Hx; - return _ekf->fuseOptFlow(H, true); + return _ekf->fuseOptFlow(_aid_src, H, true); } // generic sequential fusion of two scalar observations through the helpers, in the given order diff --git a/src/modules/ekf2/test/test_EKF_flow_multi.cpp b/src/modules/ekf2/test/test_EKF_flow_multi.cpp new file mode 100644 index 00000000000..37bb5351e00 --- /dev/null +++ b/src/modules/ekf2/test/test_EKF_flow_multi.cpp @@ -0,0 +1,313 @@ +/**************************************************************************** + * + * Copyright (c) 2026 PX4 Development Team. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name PX4 nor the names of its contributors may be + * used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS + * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + * + ****************************************************************************/ + +/** + * Test the fusion of two optical flow sensors + */ + +#include +#include "EKF/ekf.h" +#include "sensor_simulator/sensor_simulator.h" +#include "sensor_simulator/ekf_wrapper.h" + + +class EkfFlowMultiTest : public ::testing::Test +{ +public: + using Flow = sensor_simulator::sensor::Flow; + + EkfFlowMultiTest(): ::testing::Test(), + _ekf{std::make_shared()}, + _sensor_simulator(_ekf), + _ekf_wrapper(_ekf) {}; + + std::shared_ptr _ekf; + SensorSimulator _sensor_simulator; + EkfWrapper _ekf_wrapper; + + static constexpr float kDistanceToGround = 5.f; + + void SetUp() override + { + for (uint8_t slot = 0; slot < 2; slot++) { + _ekf->flowSource(slot).setLimits(5.f, 0.f, 50.f); + } + + // run briefly to init, then manually set in air and at rest (default for a real vehicle) + _ekf->init(0); + _sensor_simulator.runSeconds(0.1); + _ekf->set_in_air_status(false); + _ekf->set_vehicle_at_rest(true); + + _sensor_simulator.runSeconds(7); + } + + // hover above the ground with the range finder fusing, flow is the only horizontal aiding source + void startHoverWithRangeFinder() + { + _sensor_simulator._trajectory[2].setCurrentPosition(-kDistanceToGround); + _sensor_simulator._rng.setData(kDistanceToGround, 100); + _sensor_simulator._rng.setLimits(0.1f, 9.f); + _sensor_simulator.startRangeFinder(); + + _ekf->set_in_air_status(true); + _ekf->set_vehicle_at_rest(false); + + _sensor_simulator.runSeconds(5.f); + } + + void startFlow(uint8_t slot) + { + Flow &flow = (slot == 0) ? _sensor_simulator._flow : _sensor_simulator._flow1; + flow.setData(flow.dataAtRest()); + _ekf_wrapper.enableFlowFusion(slot); + flow.start(); + } + + // flow measured by a sensor that disagrees with the vehicle motion (e.g. wrong scale or rotation) + void setInconsistentFlow(uint8_t slot) + { + Flow &flow = (slot == 0) ? _sensor_simulator._flow : _sensor_simulator._flow1; + flowSample flow_sample = flow.dataAtRest(); + flow_sample.flow_rate = Vector2f(1.f, 0.f); + flow.setData(flow_sample); + } +}; + +TEST_F(EkfFlowMultiTest, inconsistentSensorDoesNotResetVelocity) +{ + // GIVEN: two flow sensors fused while hovering + startHoverWithRangeFinder(); + startFlow(0); + startFlow(1); + _sensor_simulator.runSeconds(3.f); + + ASSERT_TRUE(_ekf->control_status_flags().opt_flow); + ASSERT_TRUE(_ekf->aid_src_optical_flow(0).fused); + ASSERT_TRUE(_ekf->aid_src_optical_flow(1).fused); + + const uint8_t vel_reset_count = _ekf->get_velNE_reset_count(); + + // WHEN: the second sensor starts to disagree with the vehicle motion + setInconsistentFlow(1); + _sensor_simulator.runSeconds(5.f); + + // THEN: the second sensor is rejected and never resets the velocity + // while the first one keeps constraining the drift + EXPECT_EQ(_ekf->get_velNE_reset_count(), vel_reset_count); + EXPECT_LT(Vector2f(_ekf->getVelocity()).norm(), 0.1f); + + EXPECT_TRUE(_ekf->control_status_flags().opt_flow); + EXPECT_TRUE(_ekf->aid_src_optical_flow(0).fused); + EXPECT_FALSE(_ekf->aid_src_optical_flow(1).fused); +} + +TEST_F(EkfFlowMultiTest, simultaneousStartResetsVelocityOnce) +{ + // GIVEN: no horizontal aiding, both sensors deliver their samples in the same updates + startHoverWithRangeFinder(); + const uint8_t vel_reset_count = _ekf->get_velNE_reset_count(); + + // WHEN: both sensors start + startFlow(0); + startFlow(1); + _sensor_simulator.runSeconds(2.f); + + // THEN: one sensor resets the velocity, the other one starts fusing on top of it + EXPECT_TRUE(_ekf->aid_src_optical_flow(0).fused); + EXPECT_TRUE(_ekf->aid_src_optical_flow(1).fused); + EXPECT_EQ(_ekf->get_velNE_reset_count(), vel_reset_count + 1); +} + +TEST_F(EkfFlowMultiTest, sensorStartDoesNotResetTerrain) +{ + // GIVEN: one flow sensor estimating the terrain after the range finder stopped + startHoverWithRangeFinder(); + startFlow(0); + _sensor_simulator.runSeconds(3.f); + + _sensor_simulator.stopRangeFinder(); + _sensor_simulator.runSeconds(5.f); + + ASSERT_TRUE(_ekf->control_status_flags().opt_flow_terrain); + ASSERT_FALSE(_ekf->control_status_flags().rng_terrain); + ASSERT_NEAR(_ekf->getHagl(), kDistanceToGround, 0.2f); + + const uint8_t hagl_reset_count = _ekf->get_hagl_reset_count(); + + // WHEN: a second sensor whose first measurements are rejected becomes available + startFlow(1); + setInconsistentFlow(1); + _sensor_simulator.runSeconds(3.f); + + // THEN: the terrain estimate of the first sensor is kept + EXPECT_EQ(_ekf->get_hagl_reset_count(), hagl_reset_count); + EXPECT_NEAR(_ekf->getHagl(), kDistanceToGround, 0.2f); + EXPECT_TRUE(_ekf->aid_src_optical_flow(0).fused); + EXPECT_FALSE(_ekf->aid_src_optical_flow(1).fused); +} + +TEST_F(EkfFlowMultiTest, sensorEnabledAtRuntimeIsFused) +{ + // GIVEN: two flow sensors publishing data, the second one disabled + startHoverWithRangeFinder(); + startFlow(0); + _ekf_wrapper.disableFlowFusion(1); + _sensor_simulator._flow1.setData(_sensor_simulator._flow1.dataAtRest()); + _sensor_simulator.startFlow1(); + _sensor_simulator.runSeconds(3.f); + + EXPECT_TRUE(_ekf->aid_src_optical_flow(0).fused); + EXPECT_EQ(_ekf->aid_src_optical_flow(1).timestamp_sample, 0u); + + // WHEN: the second sensor gets enabled in flight + _ekf_wrapper.enableFlowFusion(1); + _sensor_simulator.runSeconds(3.f); + + // THEN: it is fused without a reboot + EXPECT_TRUE(_ekf->aid_src_optical_flow(1).fused); + EXPECT_TRUE(_ekf->aid_src_optical_flow(0).fused); +} + +TEST_F(EkfFlowMultiTest, bothSensorsFusedInMotion) +{ + // GIVEN: two flow sensors while hovering + startHoverWithRangeFinder(); + startFlow(0); + startFlow(1); + _sensor_simulator.runSeconds(3.f); + + // WHEN: the vehicle moves horizontally + const Vector3f simulated_velocity(0.8f, -0.5f, 0.f); + _sensor_simulator.setTrajectoryTargetVelocity(simulated_velocity); + _sensor_simulator.runTrajectorySeconds(_sensor_simulator._trajectory[0].getTotalTime() + 2.f); + + // THEN: both sensors keep being fused and the velocity estimate follows + EXPECT_TRUE(_ekf->aid_src_optical_flow(0).fused); + EXPECT_TRUE(_ekf->aid_src_optical_flow(1).fused); + EXPECT_NEAR(_ekf->getVelocity()(0), simulated_velocity(0), 0.05f); + EXPECT_NEAR(_ekf->getVelocity()(1), simulated_velocity(1), 0.05f); +} + +TEST_F(EkfFlowMultiTest, handoverBetweenSensorRanges) +{ + // GIVEN: a short range (up to 3 m) and a long range sensor while hovering at 5 m + _ekf->flowSource(0).setLimits(5.f, 0.f, 3.f); + startHoverWithRangeFinder(); + startFlow(0); + startFlow(1); + _sensor_simulator.runSeconds(3.f); + + // THEN: only the long range sensor is fused + EXPECT_FALSE(_ekf->aid_src_optical_flow(0).fused); + EXPECT_TRUE(_ekf->aid_src_optical_flow(1).fused); + EXPECT_TRUE(_ekf->control_status_flags().opt_flow); + + // WHEN: descending into the range of the short range sensor + _sensor_simulator.setTrajectoryTargetVelocity(Vector3f(0.f, 0.f, 1.f)); + _sensor_simulator.runTrajectorySeconds(3.f); + _sensor_simulator.setTrajectoryTargetVelocity(Vector3f(0.f, 0.f, 0.f)); + _sensor_simulator.runTrajectorySeconds(3.f); + + // THEN: it starts being fused as well + ASSERT_LT(_ekf->getHagl(), 2.5f); + EXPECT_TRUE(_ekf->aid_src_optical_flow(0).fused); + EXPECT_TRUE(_ekf->aid_src_optical_flow(1).fused); +} + +TEST_F(EkfFlowMultiTest, disablingOneSensorKeepsTheOther) +{ + // GIVEN: two flow sensors fused while hovering + startHoverWithRangeFinder(); + startFlow(0); + startFlow(1); + _sensor_simulator.runSeconds(3.f); + + // WHEN: the second sensor is disabled + _ekf_wrapper.disableFlowFusion(1); + _sensor_simulator.runSeconds(3.f); + + // THEN: only the first one is still fused + EXPECT_TRUE(_ekf->control_status_flags().opt_flow); + EXPECT_TRUE(_ekf->aid_src_optical_flow(0).fused); + EXPECT_GT(_ekf->time_delayed_us() - _ekf->aid_src_optical_flow(1).time_last_fuse, 2'000'000u); +} + +TEST_F(EkfFlowMultiTest, fusionControlStopsAllSensors) +{ + // GIVEN: two flow sensors fused while hovering + startHoverWithRangeFinder(); + startFlow(0); + startFlow(1); + _sensor_simulator.runSeconds(3.f); + ASSERT_TRUE(_ekf->control_status_flags().opt_flow); + + // WHEN: optical flow fusion is disabled at runtime (EKF2_SENS_EN / FUSION_SOURCE_OF) + _ekf->getFusionControlHandle()->of.enabled = false; + _sensor_simulator.runSeconds(1.f); + + // THEN: no flow sensor is fused anymore + EXPECT_FALSE(_ekf->control_status_flags().opt_flow); + EXPECT_FALSE(_ekf->control_status_flags().opt_flow_terrain); + + // AND WHEN: enabled again + _ekf->getFusionControlHandle()->of.enabled = true; + _sensor_simulator.runSeconds(3.f); + + // THEN: flow fusion resumes + EXPECT_TRUE(_ekf->control_status_flags().opt_flow); +} + +TEST_F(EkfFlowMultiTest, lateSensorExtendsHeightLimit) +{ + // GIVEN: a short range sensor (up to 3 m) and a long range sensor whose samples arrive + // behind the fusion horizon, so that each sample is consumed at the next update + _ekf->flowSource(0).setLimits(5.f, 0.f, 3.f); + _sensor_simulator._flow1.setLatencyUs(150'000); + _sensor_simulator._flow1.setRateHz(10); + startHoverWithRangeFinder(); + startFlow(0); + startFlow(1); + _sensor_simulator.runSeconds(3.f); + + ASSERT_TRUE(_ekf->aid_src_optical_flow(1).fused); + + // THEN: the height limit follows the long range sensor at every update + for (int i = 0; i < 100; i++) { + _sensor_simulator.runMicroseconds(10'000); + + float vxy_max, vz_max, hagl_min, hagl_max_z, hagl_max_xy; + _ekf->get_ekf_ctrl_limits(&vxy_max, &vz_max, &hagl_min, &hagl_max_z, &hagl_max_xy); + ASSERT_GT(hagl_max_xy, kDistanceToGround) << "update " << i; + } +} diff --git a/src/modules/ekf2/test/test_EKF_fusionLogic.cpp b/src/modules/ekf2/test/test_EKF_fusionLogic.cpp index b62690e7abe..4df710ac399 100644 --- a/src/modules/ekf2/test/test_EKF_fusionLogic.cpp +++ b/src/modules/ekf2/test/test_EKF_fusionLogic.cpp @@ -181,7 +181,7 @@ TEST_F(EkfFusionLogicTest, fallbackFromGpsToFlow) const float max_flow_rate = 5.f; const float min_ground_distance = 0.f; const float max_ground_distance = 50.f; - _ekf->set_optical_flow_limits(max_flow_rate, min_ground_distance, max_ground_distance); + _ekf->flowSource(0).setLimits(max_flow_rate, min_ground_distance, max_ground_distance); _sensor_simulator.startFlow(); _sensor_simulator.startRangeFinder(); _ekf_wrapper.enableFlowFusion(); @@ -220,7 +220,7 @@ TEST_F(EkfFusionLogicTest, doFlowFusion) const float max_flow_rate = 5.f; const float min_ground_distance = 0.f; const float max_ground_distance = 50.f; - _ekf->set_optical_flow_limits(max_flow_rate, min_ground_distance, max_ground_distance); + _ekf->flowSource(0).setLimits(max_flow_rate, min_ground_distance, max_ground_distance); _sensor_simulator.startFlow(); _sensor_simulator.startRangeFinder(); _ekf->set_vehicle_at_rest(false); diff --git a/src/modules/ekf2/test/test_EKF_mag.cpp b/src/modules/ekf2/test/test_EKF_mag.cpp index 1150c52dbf1..f332a2eedb1 100644 --- a/src/modules/ekf2/test/test_EKF_mag.cpp +++ b/src/modules/ekf2/test/test_EKF_mag.cpp @@ -170,6 +170,56 @@ public: const Vector3f mag_earth = _ekf->getMagEarthField(); EXPECT_NEAR(atan2f(mag_earth(1), mag_earth(0)), atan2f(mag_earth_wmm(1), mag_earth_wmm(0)), radians(1.f)); } + + // The mag stops for good in flight without North-East aiding and the heading drifts, then + // GNSS fusion starts while the vehicle accelerates horizontally + void checkGnssStartAfterMagLossInFlight(float heading_drift, int expected_yaw_emergency_resets) + { + _sensor_simulator._mag.setData(Vector3f(0.218f, 0.f, 0.43f)); + _sensor_simulator.runSeconds(_init_duration_s); + ASSERT_NO_FATAL_FAILURE(climbToInFlightAlignment(Vector3f())); + _sensor_simulator.runSeconds(5); + + ASSERT_NEAR(_ekf_wrapper.getYawAngle(), 0.f, radians(1.f)); + + _sensor_simulator._mag.stop(); + _sensor_simulator.runSeconds(2); + + const float drift_rate = radians(10.f); + const Vector3f specific_force(0.f, 0.f, -CONSTANTS_ONE_G); + _sensor_simulator._imu.setData(specific_force, Vector3f(0.f, 0.f, drift_rate)); + _sensor_simulator.runSeconds(heading_drift / drift_rate); + _sensor_simulator._imu.setData(specific_force, Vector3f()); + + // the wrong heading is still considered aligned + ASSERT_TRUE(_ekf->control_status_flags().yaw_align); + ASSERT_NEAR(wrap_pi(_ekf_wrapper.getYawAngle() - heading_drift), 0.f, radians(1.f)); + const int quat_reset_counter = _ekf_wrapper.getQuaternionResetCounter(); + + _sensor_simulator._gps.setMinRequiredGnssHealthTime(1e6); + _ekf_wrapper.enableGpsFusion(); + _sensor_simulator.startGps(); + + const Vector3f velocity_targets[] = {{5.f, 0.f, 0.f}, {0.f, 5.f, 0.f}, {-5.f, 0.f, 0.f}, {0.f, -5.f, 0.f}}; + bool yaw_emergency_reset = false; + + for (int i = 0; i < 40; i++) { + _sensor_simulator.setTrajectoryTargetVelocity(velocity_targets[(i / 5) % 4]); + + for (int k = 0; k < 100; k++) { + _sensor_simulator.runTrajectorySeconds(0.01f); + + yaw_emergency_reset = yaw_emergency_reset || _ekf->information_event_flags().yaw_aligned_to_imu_gps; + } + } + + EXPECT_EQ(yaw_emergency_reset, expected_yaw_emergency_resets > 0); + EXPECT_EQ(_ekf_wrapper.getQuaternionResetCounter(), quat_reset_counter + expected_yaw_emergency_resets); + EXPECT_TRUE(_ekf->control_status_flags().gnss_vel); + EXPECT_TRUE(_ekf->control_status_flags().gnss_pos); + EXPECT_NEAR(_ekf_wrapper.getYawAngle(), 0.f, radians(5.f)) + << "Yaw: " << degrees(_ekf_wrapper.getYawAngle()) << " deg"; + } }; TEST_F(EkfMagTest, fusionStartWithReset) @@ -346,17 +396,20 @@ TEST_F(EkfMagTest, velocityRotationOnYawReset) const matrix::Dcm2f R_ned_to_body_before(-yaw_before); const Vector2f vel_body_before = R_ned_to_body_before * Vector2f(vel_before); - // WHEN: Mag heading suddenly changes by more than 0.3 rad (90 degrees) - const float new_mag_heading = yaw_before + M_PI_F / 2.f; - mag_data = Vector3f(0.2f * cosf(new_mag_heading), -0.2f * sinf(new_mag_heading), 0.4f); - _sensor_simulator._mag.setData(mag_data); - _sensor_simulator.runSeconds(8.f); + // WHEN: GNSS yaw fusion starts with a heading that differs by more than 0.3 rad (90 degrees) + const float new_heading = yaw_before + M_PI_F / 2.f; + _ekf_wrapper.enableGpsHeadingFusion(); + _sensor_simulator._gnss_yaw.setYaw(new_heading); + _sensor_simulator.startGnssYaw(); + _sensor_simulator.runSeconds(2.f); - // THEN: the yaw should be reset to the new mag heading + ASSERT_FALSE(_ekf->isNorthEastAidingActive()); + + // THEN: the yaw should be reset to the GNSS heading const float yaw_after = _ekf_wrapper.getYawAngle(); - EXPECT_NEAR(yaw_after, new_mag_heading, radians(5.0f)) + EXPECT_NEAR(yaw_after, new_heading, radians(5.0f)) << "Yaw after: " << degrees(yaw_after) - << " Expected: " << degrees(new_mag_heading); + << " Expected: " << degrees(new_heading); // AND: the NED velocity should be rotated to maintain consistent body-frame velocity const Vector3f vel_after = _ekf->getVelocity(); @@ -378,40 +431,6 @@ TEST_F(EkfMagTest, velocityRotationOnYawReset) EXPECT_GT(yaw_change, 0.3f) << "Yaw change: " << degrees(yaw_change) << " deg"; } -TEST_F(EkfMagTest, manualYawExpiresWhenHeadingIsFused) -{ - // GIVEN: mag fusion is aligned in flight, so the mag remains the heading source - // even after a manual heading reset - const float mag_heading = M_PI_F / 4.f; - _sensor_simulator._mag.setData(Vector3f(0.2f * cosf(mag_heading), -0.2f * sinf(mag_heading), 0.4f)); - _sensor_simulator.runSeconds(_init_duration_s); - - _ekf->set_in_air_status(true); - _ekf->set_vehicle_at_rest(false); - _sensor_simulator._rng.setData(5.f, 100); - _sensor_simulator.startRangeFinder(); - _sensor_simulator.runSeconds(5.f); - - ASSERT_TRUE(_ekf_wrapper.isIntendingMagHeadingFusion() || _ekf_wrapper.isIntendingMag3DFusion()); - ASSERT_FALSE(_ekf->control_status_flags().yaw_manual); - - // WHEN: the heading is set manually - _ekf->resetHeadingToExternalObservation(mag_heading + radians(30.f), radians(2.f)); - _sensor_simulator.runSeconds(1.f); - - // THEN: the manual heading is protected from being overridden by the mag - EXPECT_TRUE(_ekf->control_status_flags().yaw_manual); - - // AND WHEN: the mag keeps being fused as heading source for a long time - _sensor_simulator.runSeconds(20.f); - EXPECT_TRUE(_ekf->control_status_flags().yaw_manual); - - _sensor_simulator.runSeconds(15.f); - - // THEN: the heading is mag derived again and the manual reset no longer protected - EXPECT_FALSE(_ekf->control_status_flags().yaw_manual); -} - TEST_F(EkfMagTest, manualYawSurvivesWithGnssAidingOnly) { // GIVEN: the vehicle sits on the ground with GNSS velocity and position fused @@ -461,9 +480,7 @@ TEST_F(EkfMagTest, manualYawOnGroundBlocksMagHeadingFusionIndefinitely) EXPECT_FALSE(_ekf_wrapper.isIntendingMagHeadingFusion()); EXPECT_FALSE(_ekf_wrapper.isIntendingMag3DFusion()); - // AND: this does not resolve itself while the vehicle stays on the ground. No heading - // observation is fused, so the manual heading never expires, which in turn keeps mag - // heading fusion disabled. + // AND: this does not resolve itself while the vehicle stays on the ground _sensor_simulator.runSeconds(120.f); EXPECT_TRUE(_ekf->control_status_flags().yaw_manual); @@ -481,7 +498,7 @@ TEST_F(EkfMagTest, manualYawOnGroundBlocksMagHeadingFusionIndefinitely) EXPECT_FALSE(_ekf->control_status_flags().mag_field_disturbed); } -TEST_F(EkfMagTest, manualYawSurvivesTakeoffUntilHeadingFused) +TEST_F(EkfMagTest, manualYawSurvivesTakeoffAndMagFusion) { // GIVEN: the heading was set manually on the ground, before any in-flight mag alignment const float mag_heading = M_PI_F / 4.f; @@ -503,21 +520,19 @@ TEST_F(EkfMagTest, manualYawSurvivesTakeoffUntilHeadingFused) _sensor_simulator.startRangeFinder(); _sensor_simulator.runSeconds(5.f); - // THEN: the mag becomes the heading source again, but the manual heading is neither - // overridden by the alignment nor immediately declared stale by it + // THEN: the mag becomes the heading source again, without overriding the manual heading EXPECT_TRUE(_ekf->control_status_flags().mag_aligned_in_flight); EXPECT_TRUE(_ekf_wrapper.isIntendingMag3DFusion()); EXPECT_TRUE(_ekf->control_status_flags().yaw_manual); EXPECT_NEAR(_ekf_wrapper.getYawAngle(), manual_heading, radians(1.f)); - // AND WHEN: the mag has been driving the heading for long enough - _sensor_simulator.runSeconds(20.f); + // AND WHEN: the mag keeps being fused as heading source for a long time + _sensor_simulator.runSeconds(60.f); + + // THEN: the manual heading is still kept + EXPECT_TRUE(_ekf_wrapper.isIntendingMag3DFusion()); EXPECT_TRUE(_ekf->control_status_flags().yaw_manual); - - _sensor_simulator.runSeconds(15.f); - - // THEN: the manual heading expires - EXPECT_FALSE(_ekf->control_status_flags().yaw_manual); + EXPECT_NEAR(_ekf_wrapper.getYawAngle(), manual_heading, radians(1.f)); } TEST_F(EkfMagTest, magHeadingChangeRateLimited) @@ -724,3 +739,341 @@ TEST_F(EkfMagTest, inFlightRecoveryFromGroundAnomalyHeadingError) // THEN: the heading converges to the true one as the bias learned at the alignment decays checkInFlightRecoveryFromGroundHeadingError(false); } + +TEST_F(EkfMagTest, fusionFailingKeepsHeading) +{ + // GIVEN: a vehicle flying without North-East aiding, fusing the mag in 3D with the WMM known + const Vector3f mag_earth_wmm = getWmmEarthField(); + _sensor_simulator._mag.setData(mag_earth_wmm); + alignOnGroundWithWmmThenLoseGnss(); + ASSERT_NO_FATAL_FAILURE(climbToInFlightAlignment(Vector3f())); + _sensor_simulator.runSeconds(5); + + ASSERT_FALSE(_ekf->isNorthEastAidingActive()); + ASSERT_TRUE(_ekf_wrapper.isIntendingMag3DFusion()); + ASSERT_NEAR(_ekf_wrapper.getYawAngle(), 0.f, radians(1.f)); + const int quat_reset_counter = _ekf_wrapper.getQuaternionResetCounter(); + + // WHEN: the measured field suddenly rotates by 90 degrees, so that the fusion fails + const Vector3f disturbance = Dcmf(Eulerf(0.f, 0.f, radians(90.f))).transpose() * mag_earth_wmm - mag_earth_wmm; + _sensor_simulator._mag.setBias(disturbance); + _sensor_simulator.runSeconds(30); + + // THEN: the heading is not reset to the disturbed field + EXPECT_EQ(_ekf_wrapper.getQuaternionResetCounter(), quat_reset_counter); + EXPECT_NEAR(_ekf_wrapper.getYawAngle(), 0.f, radians(1.f)) + << "Yaw: " << degrees(_ekf_wrapper.getYawAngle()) << " deg"; + + // AND: the disturbance is attributed to the body + const Vector3f mag_bias = _ekf->getMagBias(); + EXPECT_TRUE(isEqual(mag_bias, disturbance, 0.01f)) + << "Mag bias: " << mag_bias(0) << ", " << mag_bias(1) << ", " << mag_bias(2); +} + +TEST_F(EkfMagTest, fusionFailingWithoutWmmKeepsHeading) +{ + // GIVEN: a vehicle flying without North-East aiding, fusing the mag in 3D without a WMM + const Vector3f mag_earth(0.2f, 0.f, 0.4f); + _sensor_simulator._mag.setData(mag_earth); + _sensor_simulator.runSeconds(_init_duration_s); + ASSERT_NO_FATAL_FAILURE(climbToInFlightAlignment(Vector3f())); + _sensor_simulator.runSeconds(5); + + ASSERT_TRUE(_ekf_wrapper.isIntendingMag3DFusion()); + ASSERT_NEAR(_ekf_wrapper.getYawAngle(), 0.f, radians(1.f)); + const int quat_reset_counter = _ekf_wrapper.getQuaternionResetCounter(); + + // WHEN: the measured field suddenly rotates by 90 degrees, so that the fusion fails + _sensor_simulator._mag.setData(Dcmf(Eulerf(0.f, 0.f, radians(90.f))).transpose() * mag_earth); + + // THEN: the heading is not reset to the disturbed field. The declination fusion then + // only pulls it by a few degrees + for (int i = 0; i < 40; i++) { + _sensor_simulator.runSeconds(2); + EXPECT_EQ(_ekf_wrapper.getQuaternionResetCounter(), quat_reset_counter); + EXPECT_NEAR(_ekf_wrapper.getYawAngle(), 0.f, radians(10.f)) + << "Yaw: " << degrees(_ekf_wrapper.getYawAngle()) << " deg"; + } +} + +TEST_F(EkfMagTest, wmmUpdateInFlightKeepsHeading) +{ + // GIVEN: a heading aligned on the ground without a WMM, using a saved declination that is 20 + // degrees off, and a vehicle then flying without North-East aiding + const gnssSample gnss = _sensor_simulator._gps.getDefaultGpsData(); + const float declination_error = radians(20.f); + _ekf->getParamHandle()->ekf2_mag_decl = get_mag_declination_degrees(gnss.lat, gnss.lon) - degrees(declination_error); + + const Vector3f mag_earth_wmm = getWmmEarthField(); + _sensor_simulator._mag.setRateHz(15); + _sensor_simulator._mag.setData(mag_earth_wmm); + _sensor_simulator.runSeconds(_init_duration_s); + ASSERT_NO_FATAL_FAILURE(climbToInFlightAlignment(Vector3f())); + _sensor_simulator.runSeconds(10); + + ASSERT_FALSE(_ekf->isNorthEastAidingActive()); + ASSERT_TRUE(_ekf_wrapper.isIntendingMag3DFusion()); + ASSERT_NEAR(_ekf_wrapper.getYawAngle(), -declination_error, radians(1.f)); + const int quat_reset_counter = _ekf_wrapper.getQuaternionResetCounter(); + + // WHEN: the origin is set, which makes the WMM available + ASSERT_TRUE(_ekf->setEkfGlobalOrigin(gnss.lat, gnss.lon, gnss.alt)); + _sensor_simulator.runSeconds(10); + + // THEN: the earth field is reset to the WMM, without resetting the heading + Vector3f mag_earth = _ekf->getMagEarthField(); + EXPECT_NEAR(atan2f(mag_earth(1), mag_earth(0)), atan2f(mag_earth_wmm(1), mag_earth_wmm(0)), radians(1.f)); + EXPECT_EQ(_ekf_wrapper.getQuaternionResetCounter(), quat_reset_counter); + EXPECT_NEAR(_ekf_wrapper.getYawAngle(), -declination_error, radians(1.f)) + << "Yaw: " << degrees(_ekf_wrapper.getYawAngle()) << " deg"; + + // AND WHEN: the vehicle yaws + float heading = 0.f; + yawAtConstantRate(radians(10.f), 60.f, mag_earth_wmm, heading); + + // THEN: the heading converges to the true one without being reset + EXPECT_EQ(_ekf_wrapper.getQuaternionResetCounter(), quat_reset_counter); + EXPECT_NEAR(wrap_pi(_ekf_wrapper.getYawAngle() - heading), 0.f, radians(2.f)) + << "Yaw: " << degrees(_ekf_wrapper.getYawAngle()) << " deg, true: " << degrees(heading) << " deg"; +} + +TEST_F(EkfMagTest, wmmUpdateOnGroundKeepsManualHeading) +{ + // GIVEN: a vehicle on the ground without a WMM, with the heading set manually + const gnssSample gnss = _sensor_simulator._gps.getDefaultGpsData(); + const Vector3f mag_earth_wmm = getWmmEarthField(); + _sensor_simulator._mag.setRateHz(15); + _sensor_simulator._mag.setData(mag_earth_wmm); + _sensor_simulator.runSeconds(_init_duration_s); + + const float manual_heading = radians(30.f); + _ekf->resetHeadingToExternalObservation(manual_heading, radians(2.f)); + _sensor_simulator.runSeconds(2); + const int quat_reset_counter = _ekf_wrapper.getQuaternionResetCounter(); + + // WHEN: the origin is set, which makes the WMM available + ASSERT_TRUE(_ekf->setEkfGlobalOrigin(gnss.lat, gnss.lon, gnss.alt)); + _sensor_simulator.runSeconds(10); + + // THEN: the earth field is reset to the WMM, and the manual heading is kept + const Vector3f mag_earth = _ekf->getMagEarthField(); + EXPECT_NEAR(atan2f(mag_earth(1), mag_earth(0)), atan2f(mag_earth_wmm(1), mag_earth_wmm(0)), radians(1.f)); + EXPECT_EQ(_ekf_wrapper.getQuaternionResetCounter(), quat_reset_counter); + EXPECT_NEAR(_ekf_wrapper.getYawAngle(), manual_heading, radians(1.f)) + << "Yaw: " << degrees(_ekf_wrapper.getYawAngle()) << " deg"; +} + +TEST_F(EkfMagTest, magDropoutInFlightKeepsHeading) +{ + // GIVEN: a vehicle flying without North-East aiding, with the mag as heading source + const Vector3f mag_earth(0.2f, 0.f, 0.4f); + _sensor_simulator._mag.setData(mag_earth); + _sensor_simulator.runSeconds(_init_duration_s); + ASSERT_NO_FATAL_FAILURE(climbToInFlightAlignment(Vector3f())); + _sensor_simulator.runSeconds(5); + + ASSERT_TRUE(_ekf_wrapper.isIntendingMag3DFusion()); + ASSERT_NEAR(_ekf_wrapper.getYawAngle(), 0.f, radians(1.f)); + const int quat_reset_counter = _ekf_wrapper.getQuaternionResetCounter(); + + // WHEN: the mag data stops + _sensor_simulator._mag.stop(); + _sensor_simulator.runSeconds(2); + + // THEN: the mag fusion stops, and the heading is still considered aligned + EXPECT_FALSE(_ekf->control_status_flags().mag); + EXPECT_TRUE(_ekf->control_status_flags().yaw_align); + + // AND WHEN: the mag data comes back with the field rotated by 90 degrees + _sensor_simulator._mag.setData(Dcmf(Eulerf(0.f, 0.f, radians(90.f))).transpose() * mag_earth); + _sensor_simulator._mag.start(); + _sensor_simulator.runSeconds(10); + + // THEN: the mag fusion resumes without resetting the heading to the new field + EXPECT_TRUE(_ekf_wrapper.isIntendingMag3DFusion()); + EXPECT_EQ(_ekf_wrapper.getQuaternionResetCounter(), quat_reset_counter); + EXPECT_NEAR(_ekf_wrapper.getYawAngle(), 0.f, radians(5.f)) + << "Yaw: " << degrees(_ekf_wrapper.getYawAngle()) << " deg"; +} + +TEST_F(EkfMagTest, magDropoutOnGroundRealignsHeading) +{ + // GIVEN: a vehicle on the ground without North-East aiding, with the mag as heading source + const Vector3f mag_earth(0.2f, 0.f, 0.4f); + _sensor_simulator._mag.setData(mag_earth); + _sensor_simulator.runSeconds(_init_duration_s); + + ASSERT_TRUE(_ekf_wrapper.isIntendingMagHeadingFusion()); + ASSERT_NEAR(_ekf_wrapper.getYawAngle(), 0.f, radians(1.f)); + + // WHEN: the mag data stops + _sensor_simulator._mag.stop(); + _sensor_simulator.runSeconds(2); + + // THEN: the heading is no longer considered aligned + EXPECT_FALSE(_ekf->control_status_flags().yaw_align); + + // AND WHEN: the mag data comes back with the field rotated by 90 degrees + _sensor_simulator._mag.setData(Dcmf(Eulerf(0.f, 0.f, radians(90.f))).transpose() * mag_earth); + _sensor_simulator._mag.start(); + _sensor_simulator.runSeconds(2); + + // THEN: the heading is re-aligned to the new field + EXPECT_TRUE(_ekf->control_status_flags().yaw_align); + EXPECT_NEAR(_ekf_wrapper.getYawAngle(), radians(90.f), radians(2.f)) + << "Yaw: " << degrees(_ekf_wrapper.getYawAngle()) << " deg"; +} + +TEST_F(EkfMagTest, magDropoutOnGroundKeepsManualHeading) +{ + // GIVEN: a heading set manually, then a flight that made the mag the heading source, and the + // vehicle back on the ground without North-East aiding + const Vector3f mag_earth(0.2f, 0.f, 0.4f); + _sensor_simulator._mag.setData(mag_earth); + _sensor_simulator.runSeconds(_init_duration_s); + + const float manual_heading = radians(30.f); + _ekf->resetHeadingToExternalObservation(manual_heading, radians(2.f)); + _sensor_simulator.runSeconds(2); + ASSERT_NO_FATAL_FAILURE(climbToInFlightAlignment(Vector3f())); + _sensor_simulator.runSeconds(5); + + _ekf->set_in_air_status(false); + _ekf->set_vehicle_at_rest(true); + _sensor_simulator.runSeconds(5); + + ASSERT_TRUE(_ekf->control_status_flags().yaw_manual); + ASSERT_TRUE(_ekf_wrapper.isIntendingMag3DFusion()); + ASSERT_NEAR(_ekf_wrapper.getYawAngle(), manual_heading, radians(1.f)); + const int quat_reset_counter = _ekf_wrapper.getQuaternionResetCounter(); + + // WHEN: the mag data stops + _sensor_simulator._mag.stop(); + _sensor_simulator.runSeconds(2); + + // THEN: the mag fusion stops, and the heading is still considered aligned + EXPECT_FALSE(_ekf->control_status_flags().mag); + EXPECT_TRUE(_ekf->control_status_flags().yaw_align); + + // AND WHEN: the mag data comes back with the field rotated by 90 degrees + _sensor_simulator._mag.setData(Dcmf(Eulerf(0.f, 0.f, radians(90.f))).transpose() * mag_earth); + _sensor_simulator._mag.start(); + _sensor_simulator.runSeconds(10); + + // THEN: the manual heading is kept + EXPECT_EQ(_ekf_wrapper.getQuaternionResetCounter(), quat_reset_counter); + EXPECT_NEAR(_ekf_wrapper.getYawAngle(), manual_heading, radians(5.f)) + << "Yaw: " << degrees(_ekf_wrapper.getYawAngle()) << " deg"; +} + +TEST_F(EkfMagTest, gnssStartAfterMagLossInFlightCorrectsHeadingError) +{ + // GIVEN: a mag lost in flight without North-East aiding, and a heading that drifted by 60 degrees + // WHEN: GNSS fusion starts while the vehicle accelerates horizontally + // THEN: the GNSS data is accepted and corrects the heading without a reset + checkGnssStartAfterMagLossInFlight(radians(60.f), 0); +} + +TEST_F(EkfMagTest, gnssStartAfterMagLossInFlightResetsReversedHeading) +{ + // GIVEN: a mag lost in flight without North-East aiding, and a heading that drifted by 180 degrees + // WHEN: GNSS fusion starts while the vehicle accelerates horizontally + // THEN: the GNSS data is rejected and a single yaw emergency reset recovers the heading + checkGnssStartAfterMagLossInFlight(radians(180.f), 1); +} + +TEST_F(EkfMagTest, magBiasObservableAfterYawing) +{ + // GIVEN: a vehicle hovering after the in-flight alignment + const Vector3f mag_earth_wmm = getWmmEarthField(); + _sensor_simulator._mag.setData(mag_earth_wmm); + alignOnGroundWithWmmThenLoseGnss(); + ASSERT_NO_FATAL_FAILURE(climbToInFlightAlignment(Vector3f())); + _sensor_simulator.runSeconds(30); + + ASSERT_FALSE(_ekf->isMagBiasObservable()); + + // WHEN: it yaws by 100 degrees + float heading = 0.f; + yawAtConstantRate(radians(10.f), 10.f, mag_earth_wmm, heading); + + // THEN: the mag bias is observable + EXPECT_TRUE(_ekf->isMagBiasObservable()); + + // AND: it stays so when the vehicle yaws back + yawAtConstantRate(radians(-10.f), 10.f, mag_earth_wmm, heading); + EXPECT_TRUE(_ekf->isMagBiasObservable()); +} + +TEST_F(EkfMagTest, magBiasNotObservableWhenYawingBackAndForth) +{ + // GIVEN: a vehicle hovering after the in-flight alignment + const Vector3f mag_earth_wmm = getWmmEarthField(); + _sensor_simulator._mag.setData(mag_earth_wmm); + alignOnGroundWithWmmThenLoseGnss(); + ASSERT_NO_FATAL_FAILURE(climbToInFlightAlignment(Vector3f())); + + // WHEN: it keeps yawing back and forth by 5 degrees + float heading = 0.f; + + for (int i = 0; i < 20; i++) { + yawAtConstantRate(radians(10.f), 0.5f, mag_earth_wmm, heading); + yawAtConstantRate(radians(-10.f), 1.f, mag_earth_wmm, heading); + yawAtConstantRate(radians(10.f), 0.5f, mag_earth_wmm, heading); + } + + // THEN: the mag bias is not observable + EXPECT_FALSE(_ekf->isMagBiasObservable()); +} + +TEST_F(EkfMagTest, fusionFailingMakesMagBiasUnobservable) +{ + // GIVEN: a vehicle flying without North-East aiding, that yawed a full turn + const Vector3f mag_earth_wmm = getWmmEarthField(); + _sensor_simulator._mag.setData(mag_earth_wmm); + alignOnGroundWithWmmThenLoseGnss(); + ASSERT_NO_FATAL_FAILURE(climbToInFlightAlignment(Vector3f())); + float heading = 0.f; + yawAtConstantRate(radians(20.f), 18.f, mag_earth_wmm, heading); + + ASSERT_TRUE(_ekf->isMagBiasObservable()); + + // WHEN: the measured field suddenly rotates by 90 degrees, so that the fusion fails and the + // error is attributed to the mag bias + const Vector3f disturbance = Dcmf(Eulerf(0.f, 0.f, radians(90.f))).transpose() * mag_earth_wmm - mag_earth_wmm; + _sensor_simulator._mag.setBias(disturbance); + _sensor_simulator.runSeconds(30); + + ASSERT_TRUE(isEqual(_ekf->getMagBias(), disturbance, 0.01f)); + + // THEN: the new mag bias is not observable + EXPECT_FALSE(_ekf->isMagBiasObservable()); + + // AND: it becomes observable once the vehicle yaws again + yawAtConstantRate(radians(10.f), 10.f, mag_earth_wmm, heading); + EXPECT_TRUE(_ekf->isMagBiasObservable()); +} + +TEST_F(EkfMagTest, headingResetDoesNotMakeMagBiasObservable) +{ + // GIVEN: a vehicle hovering after the in-flight alignment + const Vector3f mag_earth_wmm = getWmmEarthField(); + _sensor_simulator._mag.setData(mag_earth_wmm); + alignOnGroundWithWmmThenLoseGnss(); + ASSERT_NO_FATAL_FAILURE(climbToInFlightAlignment(Vector3f())); + + ASSERT_FALSE(_ekf->isMagBiasObservable()); + + // WHEN: the heading is reset by 120 degrees without the vehicle rotating, and the mag is fused + // at the new heading + const float heading = radians(120.f); + _ekf->resetHeadingToExternalObservation(heading, radians(2.f)); + _sensor_simulator._mag.setData(Dcmf(Eulerf(0.f, 0.f, heading)).transpose() * mag_earth_wmm); + _sensor_simulator.runSeconds(5); + + ASSERT_NEAR(_ekf_wrapper.getYawAngle(), heading, radians(2.f)); + ASSERT_TRUE(_ekf->aid_src_mag().fused); + + // THEN: the mag bias is not observable + EXPECT_FALSE(_ekf->isMagBiasObservable()); +} diff --git a/src/modules/ekf2/test/test_EKF_terrain.cpp b/src/modules/ekf2/test/test_EKF_terrain.cpp index bd52227c25d..35216c42aef 100644 --- a/src/modules/ekf2/test/test_EKF_terrain.cpp +++ b/src/modules/ekf2/test/test_EKF_terrain.cpp @@ -103,7 +103,7 @@ public: const float max_flow_rate = 5.f; const float min_ground_distance = 0.f; const float max_ground_distance = 50.f; - _ekf->set_optical_flow_limits(max_flow_rate, min_ground_distance, max_ground_distance); + _ekf->flowSource(0).setLimits(max_flow_rate, min_ground_distance, max_ground_distance); _sensor_simulator.startFlow(); _ekf->set_in_air_status(true); diff --git a/src/modules/failure_injection_manager/FailureInjectionConfigTest.cpp b/src/modules/failure_injection_manager/FailureInjectionConfigTest.cpp index 32a0f352781..34147a4bb31 100644 --- a/src/modules/failure_injection_manager/FailureInjectionConfigTest.cpp +++ b/src/modules/failure_injection_manager/FailureInjectionConfigTest.cpp @@ -103,6 +103,7 @@ sensor_gnss_s clean_gnss() constexpr uint8_t GYRO = failure_injection_s::FAILURE_UNIT_SENSOR_GYRO; constexpr uint8_t GPS = failure_injection_s::FAILURE_UNIT_SENSOR_GPS; +constexpr uint8_t AIRSPEED = failure_injection_s::FAILURE_UNIT_SENSOR_AIRSPEED; constexpr uint8_t MOTOR = failure_injection_s::FAILURE_UNIT_SYSTEM_MOTOR; constexpr uint8_t ESC = failure_injection_s::FAILURE_UNIT_SYSTEM_ESC; constexpr uint8_t BATTERY = failure_injection_s::FAILURE_UNIT_SYSTEM_BATTERY; @@ -447,6 +448,112 @@ TEST(FailureInjectionConfig, ProcessGnssRecoveryUsesLiveSample) EXPECT_DOUBLE_EQ(recovered.latitude, 48.0); } +// =========================================================================== +// process_airspeed(): Off / Stuck / Wrong (pitot blockage ramp) +// =========================================================================== + +namespace +{ + +differential_pressure_s make_differential_pressure(uint64_t timestamp, float differential_pressure_pa) +{ + differential_pressure_s differential_pressure{}; + differential_pressure.timestamp = timestamp; + differential_pressure.timestamp_sample = timestamp; + differential_pressure.differential_pressure_pa = differential_pressure_pa; + return differential_pressure; +} + +} // namespace + +TEST(FailureInjectionConfig, ProcessAirspeedWrongRampsDownToBlockageFloor) +{ + Config config; + config.set(make_config(AIRSPEED, 0x1, WRONG)); + + AirspeedState state; + const uint64_t onset = 1'000'000; + + // The ramp starts at the first Wrong sample: no blockage yet. + differential_pressure_s differential_pressure = make_differential_pressure(onset, 100.f); + EXPECT_TRUE(process_airspeed(config, 0, differential_pressure, state)); + EXPECT_FLOAT_EQ(differential_pressure.differential_pressure_pa, 100.f); + + // Halfway through the 30 s ramp the pressure is linearly scaled. + differential_pressure = make_differential_pressure(onset + 15'000'000, 100.f); + EXPECT_TRUE(process_airspeed(config, 0, differential_pressure, state)); + EXPECT_NEAR(differential_pressure.differential_pressure_pa, 50.f, 1e-3f); + + // Past the ramp it holds at 30 % of the true value (70 % blockage). + differential_pressure = make_differential_pressure(onset + 60'000'000, 100.f); + EXPECT_TRUE(process_airspeed(config, 0, differential_pressure, state)); + EXPECT_NEAR(differential_pressure.differential_pressure_pa, 30.f, 1e-3f); +} + +TEST(FailureInjectionConfig, ProcessAirspeedClearingWrongRestartsRamp) +{ + Config config; + config.set(make_config(AIRSPEED, 0x1, WRONG)); + + AirspeedState state; + differential_pressure_s differential_pressure = make_differential_pressure(1'000'000, 100.f); + EXPECT_TRUE(process_airspeed(config, 0, differential_pressure, state)); + + config.set(failure_injection_s{}); + differential_pressure = make_differential_pressure(61'000'000, 100.f); + EXPECT_TRUE(process_airspeed(config, 0, differential_pressure, state)); + EXPECT_FLOAT_EQ(differential_pressure.differential_pressure_pa, 100.f); + + // A new Wrong starts a fresh ramp from no blockage. + config.set(make_config(AIRSPEED, 0x1, WRONG)); + differential_pressure = make_differential_pressure(62'000'000, 100.f); + EXPECT_TRUE(process_airspeed(config, 0, differential_pressure, state)); + EXPECT_FLOAT_EQ(differential_pressure.differential_pressure_pa, 100.f); +} + +TEST(FailureInjectionConfig, ProcessAirspeedWrongLeavesUnselectedInstanceUntouched) +{ + Config config; + config.set(make_config(AIRSPEED, 0x2, WRONG)); // failure instance 2 -> uORB instance 1 + + AirspeedState state; + differential_pressure_s differential_pressure = make_differential_pressure(1'000'000, 100.f); + EXPECT_TRUE(process_airspeed(config, 0, differential_pressure, state)); + + differential_pressure = make_differential_pressure(61'000'000, 100.f); + EXPECT_TRUE(process_airspeed(config, 0, differential_pressure, state)); + EXPECT_FLOAT_EQ(differential_pressure.differential_pressure_pa, 100.f); +} + +TEST(FailureInjectionConfig, ProcessAirspeedOffSuppressesPublication) +{ + Config config; + config.set(make_config(AIRSPEED, 0x1, OFF)); + + AirspeedState state; + differential_pressure_s differential_pressure = make_differential_pressure(1'000'000, 100.f); + + EXPECT_FALSE(process_airspeed(config, 0, differential_pressure, state)); + EXPECT_FLOAT_EQ(differential_pressure.differential_pressure_pa, 100.f); +} + +TEST(FailureInjectionConfig, ProcessAirspeedStuckReplaysLastGoodSample) +{ + Config config; + AirspeedState state; + + differential_pressure_s good = make_differential_pressure(1'000'000, 100.f); + EXPECT_TRUE(process_airspeed(config, 0, good, state)); + + config.set(make_config(AIRSPEED, 0x1, STUCK)); + + differential_pressure_s moved = make_differential_pressure(2'000'000, 250.f); + EXPECT_TRUE(process_airspeed(config, 0, moved, state)); + EXPECT_FLOAT_EQ(moved.differential_pressure_pa, 100.f); + EXPECT_EQ(moved.timestamp, 2'000'000u); + EXPECT_EQ(moved.timestamp_sample, 2'000'000u); +} + // =========================================================================== // process_esc(): ESC Off / Wrong on the multi-instance esc_status // =========================================================================== diff --git a/src/modules/flight_mode_manager/tasks/ManualAccelerationSlow/FlightTaskManualAccelerationSlow.cpp b/src/modules/flight_mode_manager/tasks/ManualAccelerationSlow/FlightTaskManualAccelerationSlow.cpp index dd2ca1da596..54ee389f02f 100644 --- a/src/modules/flight_mode_manager/tasks/ManualAccelerationSlow/FlightTaskManualAccelerationSlow.cpp +++ b/src/modules/flight_mode_manager/tasks/ManualAccelerationSlow/FlightTaskManualAccelerationSlow.cpp @@ -136,7 +136,7 @@ bool FlightTaskManualAccelerationSlow::update() _gimbal.acquireGimbalControlIfNeeded(); // the exact same _yawspeed_setpoint is setpoint for the gimbal and vehicle feed-forward - const float pitchrate_setpoint = getInputFromSanitizedAuxParameterIndex(_param_mc_slow_map_pitch.get()) * yaw_rate; + const float pitchrate_setpoint = getInputFromSanitizedAuxParameterIndex(_param_mc_slow_map_ptch.get()) * yaw_rate; _yawspeed_setpoint = _sticks.getYaw() * yaw_rate; _gimbal.publishGimbalManagerSetAttitude(Gimbal::FLAGS_ALL_AXES_LOCKED, Quatf(NAN, NAN, NAN, NAN), diff --git a/src/modules/flight_mode_manager/tasks/ManualAccelerationSlow/FlightTaskManualAccelerationSlow.hpp b/src/modules/flight_mode_manager/tasks/ManualAccelerationSlow/FlightTaskManualAccelerationSlow.hpp index 66b2de4a8f8..ec829fcc70d 100644 --- a/src/modules/flight_mode_manager/tasks/ManualAccelerationSlow/FlightTaskManualAccelerationSlow.hpp +++ b/src/modules/flight_mode_manager/tasks/ManualAccelerationSlow/FlightTaskManualAccelerationSlow.hpp @@ -91,6 +91,6 @@ private: (ParamFloat) _param_mpc_z_vel_max_up, (ParamFloat) _param_mpc_z_vel_max_dn, (ParamFloat) _param_mpc_man_y_max, - (ParamInt) _param_mc_slow_map_pitch + (ParamInt) _param_mc_slow_map_ptch ) }; diff --git a/src/modules/fw_att_control/FixedwingAttitudeControl.cpp b/src/modules/fw_att_control/FixedwingAttitudeControl.cpp index cad11d80716..2f20707303b 100644 --- a/src/modules/fw_att_control/FixedwingAttitudeControl.cpp +++ b/src/modules/fw_att_control/FixedwingAttitudeControl.cpp @@ -319,7 +319,7 @@ void FixedwingAttitudeControl::Run() /* add yaw rate setpoint from sticks in all attitude-controlled modes */ if (_vcontrol_mode.flag_control_manual_enabled) { - body_rates_setpoint(2) += math::constrain(_manual_control_setpoint.yaw * radians(_param_man_yr_max.get()), + body_rates_setpoint(2) += math::constrain(_manual_control_setpoint.yaw * radians(_param_fw_man_yr_max.get()), -radians(_param_fw_y_rmax.get()), radians(_param_fw_y_rmax.get())); } diff --git a/src/modules/fw_att_control/FixedwingAttitudeControl.hpp b/src/modules/fw_att_control/FixedwingAttitudeControl.hpp index 311c4cee558..c820fd91b06 100644 --- a/src/modules/fw_att_control/FixedwingAttitudeControl.hpp +++ b/src/modules/fw_att_control/FixedwingAttitudeControl.hpp @@ -182,7 +182,7 @@ private: (ParamFloat) _param_fw_wr_p, (ParamFloat) _param_fw_y_rmax, - (ParamFloat) _param_man_yr_max + (ParamFloat) _param_fw_man_yr_max ) matrix::Vector3f _proportional_gain; diff --git a/src/modules/fw_autotune_attitude_control/fw_autotune_attitude_control.cpp b/src/modules/fw_autotune_attitude_control/fw_autotune_attitude_control.cpp index 108299db24f..9a784c5b7b1 100644 --- a/src/modules/fw_autotune_attitude_control/fw_autotune_attitude_control.cpp +++ b/src/modules/fw_autotune_attitude_control/fw_autotune_attitude_control.cpp @@ -819,7 +819,7 @@ const Vector3f FwAutotuneAttitudeControl::getIdentificationSignal() const float t = static_cast(now - _state_start_time) * 1e-6f; float signal = 0.0f; - switch (_param_fw_sysid_signal_type.get()) { + switch (_param_fw_at_sysid_type.get()) { case static_cast(SignalType::kStep): { if (_steps_counter > _max_steps) { _signal_sign = (_signal_sign == 1) ? 0 : 1; @@ -842,13 +842,13 @@ const Vector3f FwAutotuneAttitudeControl::getIdentificationSignal() signal = signal_generator::getLinearSineSweep(_param_fw_at_sysid_f0.get(), _param_fw_at_sysid_f1.get(), - _param_fw_sysid_time.get(), t); + _param_fw_at_sysid_time.get(), t); } break; case static_cast(SignalType::kLogSineSweep): { signal = signal_generator::getLogSineSweep(_param_fw_at_sysid_f0.get(), _param_fw_at_sysid_f1.get(), - _param_fw_sysid_time.get(), t); + _param_fw_at_sysid_time.get(), t); } break; diff --git a/src/modules/fw_autotune_attitude_control/fw_autotune_attitude_control.hpp b/src/modules/fw_autotune_attitude_control/fw_autotune_attitude_control.hpp index d95cad7b925..25421c647d4 100644 --- a/src/modules/fw_autotune_attitude_control/fw_autotune_attitude_control.hpp +++ b/src/modules/fw_autotune_attitude_control/fw_autotune_attitude_control.hpp @@ -242,8 +242,8 @@ private: (ParamFloat) _param_fw_at_sysid_f0, (ParamFloat) _param_fw_at_sysid_f1, - (ParamFloat) _param_fw_sysid_time, - (ParamInt) _param_fw_sysid_signal_type + (ParamFloat) _param_fw_at_sysid_time, + (ParamInt) _param_fw_at_sysid_type ) static constexpr float _publishing_dt_s = 20e-3f; diff --git a/src/modules/fw_lateral_longitudinal_control/FwLateralLongitudinalControl.cpp b/src/modules/fw_lateral_longitudinal_control/FwLateralLongitudinalControl.cpp index 1b6b1478e1c..fed6374bd4f 100644 --- a/src/modules/fw_lateral_longitudinal_control/FwLateralLongitudinalControl.cpp +++ b/src/modules/fw_lateral_longitudinal_control/FwLateralLongitudinalControl.cpp @@ -92,7 +92,7 @@ FwLateralLongitudinalControl::FwLateralLongitudinalControl(bool is_vtol) : _airspeed_slew_rate_controller.setSlewRate(ASPD_SP_SLEW_RATE); _tecs_alt_time_const_slew_rate.setSlewRate(TECS_ALT_TIME_CONST_SLEW_RATE); - _tecs_alt_time_const_slew_rate.setForcedValue(_param_fw_t_h_error_tc.get() * _param_fw_thrtc_sc.get()); + _tecs_alt_time_const_slew_rate.setForcedValue(_param_fw_t_alt_tc.get() * _param_fw_lnd_thrtc_sc.get()); } FwLateralLongitudinalControl::~FwLateralLongitudinalControl() @@ -113,17 +113,17 @@ FwLateralLongitudinalControl::parameters_update() _tecs.set_equivalent_airspeed_max(_performance_model.getMaximumCalibratedAirspeed()); _tecs.set_throttle_damp(_param_fw_t_thr_damping.get()); _tecs.set_integrator_gain_throttle(_param_fw_t_thr_integ.get()); - _tecs.set_integrator_gain_pitch(_param_fw_t_I_gain_pit.get()); + _tecs.set_integrator_gain_pitch(_param_fw_t_i_gain_pit.get()); _tecs.set_throttle_slewrate(_param_fw_thr_slew_max.get()); _tecs.set_vertical_accel_limit(_param_fw_t_vert_acc.get()); _tecs.set_roll_throttle_compensation(_param_fw_t_rll2thr.get()); _tecs.set_pitch_damping(_param_fw_t_ptch_damp.get()); - _tecs.set_altitude_error_time_constant(_param_fw_t_h_error_tc.get()); - _tecs.set_fast_descend_altitude_error(_param_fw_t_fast_alt_err.get()); + _tecs.set_altitude_error_time_constant(_param_fw_t_alt_tc.get()); + _tecs.set_fast_descend_altitude_error(_param_fw_t_f_alt_err.get()); _tecs.set_altitude_rate_ff(_param_fw_t_hrate_ff.get()); - _tecs.set_airspeed_error_time_constant(_param_fw_t_tas_error_tc.get()); - _tecs.set_ste_rate_time_const(_param_ste_rate_time_const.get()); - _tecs.set_seb_rate_ff_gain(_param_seb_rate_ff.get()); + _tecs.set_airspeed_error_time_constant(_param_fw_t_tas_tc.get()); + _tecs.set_ste_rate_time_const(_param_fw_t_ste_r_tc.get()); + _tecs.set_seb_rate_ff_gain(_param_fw_t_seb_r_ff.get()); _tecs.set_level_flight_pitch(radians(_param_fw_psp_off.get())); _roll_slew_rate.setSlewRate(radians(_param_fw_pn_r_slew_max.get())); @@ -787,11 +787,11 @@ bool FwLateralLongitudinalControl::checkLowHeightConditions() const void FwLateralLongitudinalControl::updateTECSAltitudeTimeConstant(const bool is_low_height, const float dt) { // Target time constant for the TECS altitude tracker - float alt_tracking_tc = _param_fw_t_h_error_tc.get(); + float alt_tracking_tc = _param_fw_t_alt_tc.get(); if (is_low_height) { // If low-height conditions satisfied, compute target time constant for altitude tracking - alt_tracking_tc *= _param_fw_thrtc_sc.get(); + alt_tracking_tc *= _param_fw_lnd_thrtc_sc.get(); } _tecs_alt_time_const_slew_rate.update(alt_tracking_tc, dt); @@ -869,8 +869,8 @@ void FwLateralLongitudinalControl::setDefaultLongitudinalControlConfiguration(hr _long_configuration.pitch_max = radians(_param_fw_p_lim_max.get()); _long_configuration.throttle_min = _param_fw_thr_min.get(); _long_configuration.throttle_max = _param_fw_thr_max.get(); - _long_configuration.climb_rate_target = _param_climbrate_target.get(); - _long_configuration.sink_rate_target = _param_sinkrate_target.get(); + _long_configuration.climb_rate_target = _param_fw_t_clmb_r_sp.get(); + _long_configuration.sink_rate_target = _param_fw_t_sink_r_sp.get(); _long_configuration.disable_underspeed_protection = false; _long_configuration.enforce_low_height_condition = false; } @@ -905,19 +905,19 @@ void FwLateralLongitudinalControl::updateLongitudinalControlConfiguration(const if (PX4_ISFINITE(configuration_in.climb_rate_target)) { _long_configuration.climb_rate_target = math::max(0.0f, configuration_in.climb_rate_target); } else { - _long_configuration.climb_rate_target = _param_climbrate_target.get(); + _long_configuration.climb_rate_target = _param_fw_t_clmb_r_sp.get(); } if (PX4_ISFINITE(configuration_in.sink_rate_target)) { _long_configuration.sink_rate_target = math::max(0.0f, configuration_in.sink_rate_target); } else { - _long_configuration.sink_rate_target = _param_sinkrate_target.get(); + _long_configuration.sink_rate_target = _param_fw_t_sink_r_sp.get(); } if (PX4_ISFINITE(configuration_in.speed_weight)) { _long_configuration.speed_weight = math::constrain(configuration_in.speed_weight, 0.f, 2.f); } else { - _long_configuration.speed_weight = _param_t_spdweight.get(); + _long_configuration.speed_weight = _param_fw_t_spdweight.get(); } // the landing sets this to scale the TECS altitude time constant by FW_LND_THRTC_SC diff --git a/src/modules/fw_lateral_longitudinal_control/FwLateralLongitudinalControl.hpp b/src/modules/fw_lateral_longitudinal_control/FwLateralLongitudinalControl.hpp index 268c2fa6de1..fcf3123aa75 100644 --- a/src/modules/fw_lateral_longitudinal_control/FwLateralLongitudinalControl.hpp +++ b/src/modules/fw_lateral_longitudinal_control/FwLateralLongitudinalControl.hpp @@ -151,25 +151,25 @@ private: (ParamFloat) _param_fw_p_lim_min, (ParamFloat) _param_fw_pn_r_slew_max, (ParamFloat) _param_fw_t_hrate_ff, - (ParamFloat) _param_fw_t_h_error_tc, - (ParamFloat) _param_fw_t_fast_alt_err, + (ParamFloat) _param_fw_t_alt_tc, + (ParamFloat) _param_fw_t_f_alt_err, (ParamFloat) _param_fw_t_thr_integ, - (ParamFloat) _param_fw_t_I_gain_pit, + (ParamFloat) _param_fw_t_i_gain_pit, (ParamFloat) _param_fw_t_ptch_damp, (ParamFloat) _param_fw_t_rll2thr, (ParamFloat) _param_fw_t_sink_max, - (ParamFloat) _param_fw_t_tas_error_tc, + (ParamFloat) _param_fw_t_tas_tc, (ParamFloat) _param_fw_t_thr_damping, (ParamFloat) _param_fw_t_vert_acc, - (ParamFloat) _param_ste_rate_time_const, - (ParamFloat) _param_seb_rate_ff, - (ParamFloat) _param_t_spdweight, - (ParamFloat) _param_climbrate_target, - (ParamFloat) _param_sinkrate_target, + (ParamFloat) _param_fw_t_ste_r_tc, + (ParamFloat) _param_fw_t_seb_r_ff, + (ParamFloat) _param_fw_t_spdweight, + (ParamFloat) _param_fw_t_clmb_r_sp, + (ParamFloat) _param_fw_t_sink_r_sp, (ParamFloat) _param_fw_thr_max, (ParamFloat) _param_fw_thr_min, (ParamFloat) _param_fw_thr_slew_max, - (ParamFloat) _param_fw_thrtc_sc, + (ParamFloat) _param_fw_lnd_thrtc_sc, (ParamFloat) _param_fw_t_thr_low_hgt, (ParamFloat) _param_fw_wind_arsp_sc, (ParamFloat) _param_fw_gnd_spd_min, diff --git a/src/modules/fw_mode_manager/FixedWingModeManager.cpp b/src/modules/fw_mode_manager/FixedWingModeManager.cpp index 3a47757f312..81dcbc4aab1 100644 --- a/src/modules/fw_mode_manager/FixedWingModeManager.cpp +++ b/src/modules/fw_mode_manager/FixedWingModeManager.cpp @@ -99,11 +99,11 @@ FixedWingModeManager::parameters_update() _directional_guidance.setPeriod(_param_npfg_period.get()); _directional_guidance.setDamping(_param_npfg_damping.get()); - _directional_guidance.enablePeriodLB(_param_npfg_en_period_lb.get()); - _directional_guidance.enablePeriodUB(_param_npfg_en_period_ub.get()); - _directional_guidance.setRollTimeConst(_param_npfg_roll_time_const.get()); - _directional_guidance.setSwitchDistanceMultiplier(_param_npfg_switch_distance_multiplier.get()); - _directional_guidance.setPeriodSafetyFactor(_param_npfg_period_safety_factor.get()); + _directional_guidance.enablePeriodLB(_param_npfg_lb_period.get()); + _directional_guidance.enablePeriodUB(_param_npfg_ub_period.get()); + _directional_guidance.setRollTimeConst(_param_npfg_roll_tc.get()); + _directional_guidance.setSwitchDistanceMultiplier(_param_npfg_sw_dst_mlt.get()); + _directional_guidance.setPeriodSafetyFactor(_param_npfg_period_sf.get()); } void @@ -354,11 +354,11 @@ FixedWingModeManager::getManualHeightRateSetpoint() if (_manual_control_setpoint_for_height_rate >= FLT_EPSILON) { height_rate_setpoint = math::interpolate(math::deadzone(_manual_control_setpoint_for_height_rate, - kStickDeadBand), 0, 1.f, 0.f, -_param_sinkrate_target.get()); + kStickDeadBand), 0, 1.f, 0.f, -_param_fw_t_sink_r_sp.get()); } else { height_rate_setpoint = math::interpolate(math::deadzone(_manual_control_setpoint_for_height_rate, - kStickDeadBand), -1., 0.f, _param_climbrate_target.get(), 0.f); + kStickDeadBand), -1., 0.f, _param_fw_t_clmb_r_sp.get(), 0.f); } return height_rate_setpoint; @@ -487,7 +487,7 @@ FixedWingModeManager::set_control_mode_current(const hrt_abstime &now) // we handle loss of position control during backtransition as a special case _control_mode_current = FW_POSCTRL_MODE_TRANSITION_TO_HOVER_HEADING_HOLD; - } else if (hrt_elapsed_time(&_time_in_fixed_bank_loiter) < (_param_nav_gpsf_lt.get() * 1_s) + } else if (hrt_elapsed_time(&_time_in_fixed_bank_loiter) < (_param_fw_gpsf_lt.get() * 1_s) && !_vehicle_status.in_transition_mode) { if (previous_position_control_mode != FW_POSCTRL_MODE_AUTO_ALTITUDE) { // Need to init because last loop iteration was in a different mode @@ -693,7 +693,7 @@ FixedWingModeManager::control_auto_fixed_bank_alt_hold() fixed_wing_lateral_setpoint_s lateral_ctrl_sp = empty_lateral_control_setpoint; lateral_ctrl_sp.timestamp = hrt_absolute_time(); - const float roll_body = math::radians(_param_nav_gpsf_r.get()); // open loop loiter bank angle + const float roll_body = math::radians(_param_fw_gpsf_r.get()); // open loop loiter bank angle lateral_ctrl_sp.lateral_acceleration = rollAngleToLateralAccel(roll_body); _lateral_ctrl_sp_pub.publish(lateral_ctrl_sp); } @@ -723,7 +723,7 @@ FixedWingModeManager::control_auto_descend() fixed_wing_lateral_setpoint_s lateral_ctrl_sp = empty_lateral_control_setpoint; lateral_ctrl_sp.timestamp = now; - const float roll_body = math::radians(_param_nav_gpsf_r.get()); // open loop loiter bank angle + const float roll_body = math::radians(_param_fw_gpsf_r.get()); // open loop loiter bank angle lateral_ctrl_sp.lateral_acceleration = rollAngleToLateralAccel(roll_body); _lateral_ctrl_sp_pub.publish(lateral_ctrl_sp); } @@ -1171,7 +1171,7 @@ FixedWingModeManager::control_auto_takeoff(const hrt_abstime &now, const float c _ctrl_configuration_handler.setLateralAccelMax(rollAngleToLateralAccel(roll_wingtip_strike)); const float pitch_max = _runway_takeoff.getMaxPitch(math::radians(_param_fw_p_lim_max.get())); - const float pitch_min = _runway_takeoff.getMinPitch(math::radians(_takeoff_pitch_min.get()), + const float pitch_min = _runway_takeoff.getMinPitch(math::radians(_param_fw_tko_pitch_min.get()), math::radians(_param_fw_p_lim_min.get())); // a time based climbout has to keep climbing for the whole window, so command the climb rate @@ -1301,7 +1301,7 @@ FixedWingModeManager::control_auto_takeoff(const hrt_abstime &now, const float c _longitudinal_ctrl_sp_pub.publish(fw_longitudinal_control_sp); - _ctrl_configuration_handler.setPitchMin(radians(_takeoff_pitch_min.get())); + _ctrl_configuration_handler.setPitchMin(radians(_param_fw_tko_pitch_min.get())); _ctrl_configuration_handler.setThrottleMax(max_takeoff_throttle); _ctrl_configuration_handler.setClimbRateTarget(_param_fw_t_clmb_max.get()); _ctrl_configuration_handler.setDisableUnderspeedProtection(true); @@ -1317,7 +1317,7 @@ FixedWingModeManager::control_auto_takeoff(const hrt_abstime &now, const float c fixed_wing_longitudinal_setpoint_s long_control_sp{empty_longitudinal_control_setpoint}; long_control_sp.timestamp = now; - long_control_sp.pitch_direct = radians(_takeoff_pitch_min.get()); + long_control_sp.pitch_direct = radians(_param_fw_tko_pitch_min.get()); long_control_sp.throttle_direct = _param_fw_thr_idle.get(); _longitudinal_ctrl_sp_pub.publish(long_control_sp); } @@ -1377,7 +1377,7 @@ FixedWingModeManager::control_auto_takeoff_no_nav(const hrt_abstime &now, const _lateral_ctrl_sp_pub.publish(fw_lateral_ctrl_sp); const float pitch_max = _runway_takeoff.getMaxPitch(math::radians(_param_fw_p_lim_max.get())); - const float pitch_min = _runway_takeoff.getMinPitch(math::radians(_takeoff_pitch_min.get()), + const float pitch_min = _runway_takeoff.getMinPitch(math::radians(_param_fw_tko_pitch_min.get()), math::radians(_param_fw_p_lim_min.get())); const fixed_wing_longitudinal_setpoint_s fw_longitudinal_control_sp = { @@ -1454,7 +1454,7 @@ FixedWingModeManager::control_auto_takeoff_no_nav(const hrt_abstime &now, const _longitudinal_ctrl_sp_pub.publish(fw_longitudinal_control_sp); - _ctrl_configuration_handler.setPitchMin(radians(_takeoff_pitch_min.get())); + _ctrl_configuration_handler.setPitchMin(radians(_param_fw_tko_pitch_min.get())); _ctrl_configuration_handler.setThrottleMax(max_takeoff_throttle); _ctrl_configuration_handler.setClimbRateTarget(_param_fw_t_clmb_max.get()); _ctrl_configuration_handler.setDisableUnderspeedProtection(true); @@ -1691,7 +1691,7 @@ FixedWingModeManager::control_auto_landing_straight(const hrt_abstime &now, cons // Open the desired max sink rate to encompass the glide slope. // x/sqrt(x^2+1) = sin(arctan(x)) const float glide_slope_sink_rate = airspeed_land * glide_slope / sqrtf(glide_slope * glide_slope + 1.0f); - const float desired_max_sinkrate = math::max(glide_slope_sink_rate, _param_sinkrate_target.get()); + const float desired_max_sinkrate = math::max(glide_slope_sink_rate, _param_fw_t_sink_r_sp.get()); const fixed_wing_longitudinal_setpoint_s fw_longitudinal_control_sp = { .timestamp = hrt_absolute_time(), @@ -1869,7 +1869,7 @@ FixedWingModeManager::control_auto_landing_circular(const hrt_abstime &now, cons // x/sqrt(x^2+1) = sin(arctan(x)) const float glide_slope = math::radians(_param_fw_lnd_ang.get()); const float glide_slope_sink_rate = airspeed_land * glide_slope / sqrtf(glide_slope * glide_slope + 1.0f); - const float desired_max_sinkrate = math::max(glide_slope_sink_rate, _param_sinkrate_target.get()); + const float desired_max_sinkrate = math::max(glide_slope_sink_rate, _param_fw_t_sink_r_sp.get()); const fixed_wing_longitudinal_setpoint_s fw_longitudinal_control_sp = { .timestamp = now, @@ -2332,7 +2332,7 @@ FixedWingModeManager::Run() _spoilers_setpoint = 0.f; // by default set speed weight to the param value, can be overwritten inside the methods below - _ctrl_configuration_handler.setSpeedWeight(_param_t_spdweight.get()); + _ctrl_configuration_handler.setSpeedWeight(_param_fw_t_spdweight.get()); if (_control_mode_current != FW_POSCTRL_MODE_AUTO_LANDING_STRAIGHT && _control_mode_current != FW_POSCTRL_MODE_AUTO_LANDING_CIRCULAR) { diff --git a/src/modules/fw_mode_manager/FixedWingModeManager.hpp b/src/modules/fw_mode_manager/FixedWingModeManager.hpp index e506eb236b6..c9ee90a66b6 100644 --- a/src/modules/fw_mode_manager/FixedWingModeManager.hpp +++ b/src/modules/fw_mode_manager/FixedWingModeManager.hpp @@ -863,11 +863,11 @@ private: (ParamFloat) _param_npfg_period, (ParamFloat) _param_npfg_damping, - (ParamBool) _param_npfg_en_period_lb, - (ParamBool) _param_npfg_en_period_ub, - (ParamFloat) _param_npfg_roll_time_const, - (ParamFloat) _param_npfg_switch_distance_multiplier, - (ParamFloat) _param_npfg_period_safety_factor, + (ParamBool) _param_npfg_lb_period, + (ParamBool) _param_npfg_ub_period, + (ParamFloat) _param_npfg_roll_tc, + (ParamFloat) _param_npfg_sw_dst_mlt, + (ParamFloat) _param_npfg_period_sf, (ParamFloat) _param_fw_wp_rst_dist, @@ -884,8 +884,8 @@ private: (ParamFloat) _param_fw_p_lim_max, (ParamFloat) _param_fw_p_lim_min, - (ParamFloat) _param_climbrate_target, - (ParamFloat) _param_sinkrate_target, + (ParamFloat) _param_fw_t_clmb_r_sp, + (ParamFloat) _param_fw_t_sink_r_sp, (ParamFloat) _param_fw_thr_idle, (ParamFloat) _param_fw_thr_max, (ParamFloat) _param_fw_thr_min, @@ -893,9 +893,9 @@ private: (ParamFloat) _param_fw_flaps_to_scl, (ParamFloat) _param_fw_spoilers_lnd, (ParamInt) _param_fw_pos_stk_conf, - (ParamInt) _param_nav_gpsf_lt, - (ParamFloat) _param_nav_gpsf_r, - (ParamFloat) _param_t_spdweight, + (ParamInt) _param_fw_gpsf_lt, + (ParamFloat) _param_fw_gpsf_r, + (ParamFloat) _param_fw_t_spdweight, // Launch detection parameters (ParamBool) _param_fw_laun_detcn_on, @@ -905,7 +905,7 @@ private: // external parameters (ParamBool) _param_fw_use_airspd, (ParamFloat) _param_nav_loiter_rad, - (ParamFloat) _takeoff_pitch_min, + (ParamFloat) _param_fw_tko_pitch_min, (ParamFloat) _param_nav_fw_alt_rad, (ParamFloat) _param_fw_wing_span, (ParamFloat) _param_fw_wing_height, diff --git a/src/modules/fw_mode_manager/launchdetection/LaunchDetector.cpp b/src/modules/fw_mode_manager/launchdetection/LaunchDetector.cpp index 88b5ce5ed0b..9b5849c9d5c 100644 --- a/src/modules/fw_mode_manager/launchdetection/LaunchDetector.cpp +++ b/src/modules/fw_mode_manager/launchdetection/LaunchDetector.cpp @@ -59,14 +59,14 @@ void LaunchDetector::update(const float dt, const float accel_norm) } /* Detect an acceleration that is longer and stronger than the minimum given by the params */ - if (accel_norm > param_fw_laun_ac_thld_.get()) { + if (accel_norm > _param_fw_laun_ac_thld.get()) { acceleration_detected_counter_ += dt; - if (acceleration_detected_counter_ > param_fw_laun_ac_t_.get()) { - if (param_fw_laun_mot_del_.get() > 0.f) { + if (acceleration_detected_counter_ > _param_fw_laun_ac_t.get()) { + if (_param_fw_laun_mot_del.get() > 0.f) { state_ = launch_detection_status_s::STATE_LAUNCH_DETECTED_DISABLED_MOTOR; events::send(events::ID("launch_detection_wait_for_throttle"), {events::Log::Info, events::LogInternal::Info}, - "Launch detected: enablecontrol, waiting {1:.1}s until full throttle", (double)param_fw_laun_mot_del_.get()); + "Launch detected: enablecontrol, waiting {1:.1}s until full throttle", (double)_param_fw_laun_mot_del.get()); } else { /* No motor delay set: go directly to enablemotors state */ @@ -87,7 +87,7 @@ void LaunchDetector::update(const float dt, const float accel_norm) * over to allow full throttle */ motor_delay_counter_ += dt; - if (motor_delay_counter_ > param_fw_laun_mot_del_.get()) { + if (motor_delay_counter_ > _param_fw_laun_mot_del.get()) { events::send(events::ID("launch_detection_enable_motors"), {events::Log::Info, events::LogInternal::Info}, "Launch detected: enable motors"); state_ = launch_detection_status_s::STATE_FLYING; diff --git a/src/modules/fw_mode_manager/launchdetection/LaunchDetector.h b/src/modules/fw_mode_manager/launchdetection/LaunchDetector.h index 5ed19c1b595..267f24a6a65 100644 --- a/src/modules/fw_mode_manager/launchdetection/LaunchDetector.h +++ b/src/modules/fw_mode_manager/launchdetection/LaunchDetector.h @@ -106,9 +106,9 @@ private: uint state_{launch_detection_status_s::STATE_WAITING_FOR_LAUNCH}; DEFINE_PARAMETERS( - (ParamFloat) param_fw_laun_ac_thld_, - (ParamFloat) param_fw_laun_ac_t_, - (ParamFloat) param_fw_laun_mot_del_ + (ParamFloat) _param_fw_laun_ac_thld, + (ParamFloat) _param_fw_laun_ac_t, + (ParamFloat) _param_fw_laun_mot_del ) }; diff --git a/src/modules/fw_mode_manager/runway_takeoff/RunwayTakeoff.cpp b/src/modules/fw_mode_manager/runway_takeoff/RunwayTakeoff.cpp index 96cffebb52b..c1eaef78197 100644 --- a/src/modules/fw_mode_manager/runway_takeoff/RunwayTakeoff.cpp +++ b/src/modules/fw_mode_manager/runway_takeoff/RunwayTakeoff.cpp @@ -64,14 +64,14 @@ void RunwayTakeoff::update(const hrt_abstime &time_now, const float takeoff_airs { switch (takeoff_state_) { case RunwayTakeoffState::THROTTLE_RAMP: - if ((time_now - time_initialized_) > (param_rwto_ramp_time_.get() * 1_s)) { + if ((time_now - time_initialized_) > (_param_rwto_ramp_time.get() * 1_s)) { takeoff_state_ = RunwayTakeoffState::CLAMPED_TO_RUNWAY; } break; case RunwayTakeoffState::CLAMPED_TO_RUNWAY: { - const float rotation_airspeed = (param_rwto_rot_airspd_.get() > FLT_EPSILON) ? math::min(param_rwto_rot_airspd_.get(), + const float rotation_airspeed = (_param_rwto_rot_airspd.get() > FLT_EPSILON) ? math::min(_param_rwto_rot_airspd.get(), takeoff_airspeed) : 0.9f * takeoff_airspeed; if (calibrated_airspeed > rotation_airspeed) { @@ -100,7 +100,7 @@ void RunwayTakeoff::update(const hrt_abstime &time_now, const float takeoff_airs float RunwayTakeoff::getPitch() { if (takeoff_state_ <= RunwayTakeoffState::CLAMPED_TO_RUNWAY) { - return math::radians(param_rwto_psp_.get()); + return math::radians(_param_rwto_psp.get()); } return NAN; @@ -123,14 +123,14 @@ float RunwayTakeoff::getThrottle(const float idle_throttle) const switch (takeoff_state_) { case RunwayTakeoffState::THROTTLE_RAMP: - throttle = interpolateValuesOverAbsoluteTime(idle_throttle, param_rwto_max_thr_.get(), time_initialized_, - param_rwto_ramp_time_.get()); + throttle = interpolateValuesOverAbsoluteTime(idle_throttle, _param_rwto_max_thr.get(), time_initialized_, + _param_rwto_ramp_time.get()); break; case RunwayTakeoffState::CLAMPED_TO_RUNWAY: case RunwayTakeoffState::CLIMBOUT: - throttle = param_rwto_max_thr_.get(); + throttle = _param_rwto_max_thr.get(); break; @@ -145,13 +145,13 @@ float RunwayTakeoff::getMinPitch(float min_pitch_in_climbout, float min_pitch) c { if (takeoff_state_ < RunwayTakeoffState::CLIMBOUT) { // constrain to the taxi pitch setpoint - return math::radians(param_rwto_psp_.get() - 0.01f); + return math::radians(_param_rwto_psp.get() - 0.01f); } else if (takeoff_state_ < RunwayTakeoffState::FLYING) { // ramp in the climbout pitch constraint over the rotation transition time - const float taxi_pitch_min = math::radians(param_rwto_psp_.get() - 0.01f); + const float taxi_pitch_min = math::radians(_param_rwto_psp.get() - 0.01f); return interpolateValuesOverAbsoluteTime(taxi_pitch_min, min_pitch_in_climbout, takeoff_time_, - param_rwto_rot_time_.get()); + _param_rwto_rot_time.get()); } else { return min_pitch; @@ -162,12 +162,12 @@ float RunwayTakeoff::getMaxPitch(const float max_pitch) const { if (takeoff_state_ < RunwayTakeoffState::CLIMBOUT) { // constrain to the taxi pitch setpoint - return math::radians(param_rwto_psp_.get() + 0.01f); + return math::radians(_param_rwto_psp.get() + 0.01f); } else if (takeoff_state_ < RunwayTakeoffState::FLYING) { // ramp in the climbout pitch constraint over the rotation transition time - const float taxi_pitch_max = math::radians(param_rwto_psp_.get() + 0.01f); - return interpolateValuesOverAbsoluteTime(taxi_pitch_max, max_pitch, takeoff_time_, param_rwto_rot_time_.get()); + const float taxi_pitch_max = math::radians(_param_rwto_psp.get() + 0.01f); + return interpolateValuesOverAbsoluteTime(taxi_pitch_max, max_pitch, takeoff_time_, _param_rwto_rot_time.get()); } else { return max_pitch; diff --git a/src/modules/fw_mode_manager/runway_takeoff/RunwayTakeoff.h b/src/modules/fw_mode_manager/runway_takeoff/RunwayTakeoff.h index 5b77426bca6..6b0c2f732f3 100644 --- a/src/modules/fw_mode_manager/runway_takeoff/RunwayTakeoff.h +++ b/src/modules/fw_mode_manager/runway_takeoff/RunwayTakeoff.h @@ -98,7 +98,7 @@ public: /** * @return Runway takeoff is enabled */ - bool runwayTakeoffEnabled() { return param_rwto_tkoff_.get(); } + bool runwayTakeoffEnabled() { return _param_rwto_tkoff.get(); } /** * @return Pitch angle setpoint (limited while plane is on runway) [rad] @@ -176,12 +176,12 @@ private: hrt_abstime takeoff_time_{0}; DEFINE_PARAMETERS( - (ParamBool) param_rwto_tkoff_, - (ParamFloat) param_rwto_max_thr_, - (ParamFloat) param_rwto_psp_, - (ParamFloat) param_rwto_ramp_time_, - (ParamFloat) param_rwto_rot_airspd_, - (ParamFloat) param_rwto_rot_time_ + (ParamBool) _param_rwto_tkoff, + (ParamFloat) _param_rwto_max_thr, + (ParamFloat) _param_rwto_psp, + (ParamFloat) _param_rwto_ramp_time, + (ParamFloat) _param_rwto_rot_airspd, + (ParamFloat) _param_rwto_rot_time ) }; diff --git a/src/modules/fw_rate_control/FixedwingRateControl.cpp b/src/modules/fw_rate_control/FixedwingRateControl.cpp index 9fa252ba16c..e2a3ef2c134 100644 --- a/src/modules/fw_rate_control/FixedwingRateControl.cpp +++ b/src/modules/fw_rate_control/FixedwingRateControl.cpp @@ -189,6 +189,7 @@ float FixedwingRateControl::get_airspeed_and_update_scaling(float dt) * For scaling our actuators using anything less than the stall * speed doesn't make any sense - its the strongest reasonable deflection we * want to do in flight and it's the baseline a human pilot would choose. + * When landed the scale is limited to >=1 to avoid servo oscillation. * * Forcing the scaling to this value allows reasonable handheld tests. */ @@ -199,6 +200,10 @@ float FixedwingRateControl::get_airspeed_and_update_scaling(float dt) const float airspeed_constrained = math::max(airspeed, min_airspeed); _airspeed_scaling = _param_fw_airspd_trim.get() / airspeed_constrained; + if (_landed) { + _airspeed_scaling = math::min(_airspeed_scaling, 1.f); + } + } else { _airspeed_scaling = 1.0f; } diff --git a/src/modules/hardfault_stream/HardfaultStream.cpp b/src/modules/hardfault_stream/HardfaultStream.cpp index bd14ab0a8db..a3b0c8b5c8d 100644 --- a/src/modules/hardfault_stream/HardfaultStream.cpp +++ b/src/modules/hardfault_stream/HardfaultStream.cpp @@ -157,6 +157,7 @@ void HardfaultStream::Run() if (should_exit()) { ScheduleClear(); exit_and_cleanup(desc); + return; } switch (_state) { diff --git a/src/modules/internal_combustion_engine_control/InternalCombustionEngineControl.cpp b/src/modules/internal_combustion_engine_control/InternalCombustionEngineControl.cpp index 9aa946cd253..e2dfe7ede57 100644 --- a/src/modules/internal_combustion_engine_control/InternalCombustionEngineControl.cpp +++ b/src/modules/internal_combustion_engine_control/InternalCombustionEngineControl.cpp @@ -245,7 +245,7 @@ void InternalCombustionEngineControl::Run() _starting_retry_cycle = 0; PX4_INFO("ICE: Stopped"); - } else if (!_is_engine_running && _param_ice_running_fault_detection.get()) { + } else if (!_is_engine_running && _param_ice_run_fault_d.get()) { // without RPM feedback we assume the engine is running after the // starting procedure but only switch state if fault detection is enabled _state = State::Starting; @@ -395,11 +395,11 @@ bool InternalCombustionEngineControl::isStartingPermitted(const hrt_abstime now) bool InternalCombustionEngineControl::maximumAttemptsReached() { // First and only attempt - if (_param_ice_strt_attempts.get() == 0) { + if (_param_ice_strt_attempt.get() == 0) { return _starting_retry_cycle > 0; } - return _starting_retry_cycle >= _param_ice_strt_attempts.get(); + return _starting_retry_cycle >= _param_ice_strt_attempt.get(); } int InternalCombustionEngineControl::print_usage(const char *reason) diff --git a/src/modules/internal_combustion_engine_control/InternalCombustionEngineControl.hpp b/src/modules/internal_combustion_engine_control/InternalCombustionEngineControl.hpp index 14fad215f1e..404adff5ccb 100644 --- a/src/modules/internal_combustion_engine_control/InternalCombustionEngineControl.hpp +++ b/src/modules/internal_combustion_engine_control/InternalCombustionEngineControl.hpp @@ -156,8 +156,8 @@ private: (ParamFloat) _param_ice_choke_st_dur, (ParamFloat) _param_ice_strt_dur, (ParamFloat) _param_ice_min_run_rpm, - (ParamInt) _param_ice_strt_attempts, - (ParamInt) _param_ice_running_fault_detection, + (ParamInt) _param_ice_strt_attempt, + (ParamInt) _param_ice_run_fault_d, (ParamFloat) _param_ice_strt_thr, (ParamInt) _param_ice_stop_choke, (ParamFloat) _param_ice_thr_slew, diff --git a/src/modules/land_detector/FixedwingLandDetector.cpp b/src/modules/land_detector/FixedwingLandDetector.cpp index 0b27d331417..7cce622b38b 100644 --- a/src/modules/land_detector/FixedwingLandDetector.cpp +++ b/src/modules/land_detector/FixedwingLandDetector.cpp @@ -166,10 +166,10 @@ bool FixedwingLandDetector::_get_landed_state() && airspeed_invalid) ? math::radians(_param_lndfw_rot_max.get()) : INFINITY; // Crude land detector for fixedwing. - landDetected = _airspeed_filtered < _param_lndfw_airspd.get() + landDetected = _airspeed_filtered < _param_lndfw_airspd_max.get() && _velocity_xy_filtered < vel_xy_max_threshold && _velocity_z_filtered < _param_lndfw_vel_z_max.get() - && _xy_accel_filtered < _param_lndfw_xyaccel_max.get() + && _xy_accel_filtered < _param_lndfw_xyacc_max.get() && _velocity_rot_filtered < max_rotation_threshold; } else { diff --git a/src/modules/land_detector/FixedwingLandDetector.h b/src/modules/land_detector/FixedwingLandDetector.h index 4fc745b9f80..886219c1845 100644 --- a/src/modules/land_detector/FixedwingLandDetector.h +++ b/src/modules/land_detector/FixedwingLandDetector.h @@ -79,8 +79,8 @@ private: DEFINE_PARAMETERS_CUSTOM_PARENT( LandDetector, - (ParamFloat) _param_lndfw_xyaccel_max, - (ParamFloat) _param_lndfw_airspd, + (ParamFloat) _param_lndfw_xyacc_max, + (ParamFloat) _param_lndfw_airspd_max, (ParamFloat) _param_lndfw_vel_xy_max, (ParamFloat) _param_lndfw_vel_z_max, (ParamFloat) _param_lndfw_rot_max, diff --git a/src/modules/land_detector/LandDetector.cpp b/src/modules/land_detector/LandDetector.cpp index e4f8cccb676..b3daf1aa1db 100644 --- a/src/modules/land_detector/LandDetector.cpp +++ b/src/modules/land_detector/LandDetector.cpp @@ -89,8 +89,8 @@ void LandDetector::Run() updateParams(); _update_params(); - _total_flight_time = static_cast(_param_total_flight_time_high.get()) << 32; - _total_flight_time |= static_cast(_param_total_flight_time_low.get()); + _total_flight_time = static_cast(_param_lnd_flight_t_hi.get()) << 32; + _total_flight_time |= static_cast(_param_lnd_flight_t_lo.get()); } actuator_armed_s actuator_armed; @@ -103,6 +103,25 @@ void LandDetector::Run() if (_vehicle_acceleration_sub.update(&vehicle_acceleration)) { _acceleration = matrix::Vector3f{vehicle_acceleration.xyz}; + + const bool first_sample = (_time_last_acceleration_sample_us == 0); + const float dt_s = (vehicle_acceleration.timestamp_sample - _time_last_acceleration_sample_us) * 1e-6f; + _time_last_acceleration_sample_us = vehicle_acceleration.timestamp_sample; + + if (first_sample || (dt_s > 1.f)) { + _specific_force_fast.reset(_acceleration); + _specific_force_slow.reset(_acceleration); + } + + // Catches smooth accelerations, such as a takeoff roll, that the high-passed vibration metrics miss. + static constexpr float kSpecificForceChangeMax = 0.3f; + + const matrix::Vector3f specific_force_change = _specific_force_fast.update(_acceleration, dt_s) + - _specific_force_slow.update(_acceleration, dt_s); + + if (specific_force_change.longerThan(kSpecificForceChangeMax)) { + _time_last_move_detect_us = vehicle_acceleration.timestamp_sample; + } } vehicle_angular_velocity_s vehicle_angular_velocity{}; @@ -117,7 +136,20 @@ void LandDetector::Run() } } - _vehicle_local_position_sub.update(&_vehicle_local_position); + if (_vehicle_local_position_sub.update(&_vehicle_local_position)) { + // Catches constant velocity motion where the acceleration and vibration checks would fail. + static constexpr float kAidedVelocityMax = 1.f; + static constexpr float kAidedVelocityStdDevMax = 5.f; + + const matrix::Vector2f velocity_xy{_vehicle_local_position.vx, _vehicle_local_position.vy}; + const float velocity_threshold = math::max(kAidedVelocityMax, kAidedVelocityStdDevMax * _vehicle_local_position.evh); + + if (_vehicle_local_position.v_xy_valid && !_vehicle_local_position.dead_reckoning + && velocity_xy.longerThan(velocity_threshold)) { + _time_last_move_detect_us = _vehicle_local_position.timestamp_sample; + } + } + _vehicle_status_sub.update(&_vehicle_status); _update_topics(); @@ -180,13 +212,13 @@ void LandDetector::Run() uint32_t flight_time = (_total_flight_time >> 32) & 0xffffffff; - _param_total_flight_time_high.set(flight_time); - _param_total_flight_time_high.commit_no_notification(); + _param_lnd_flight_t_hi.set(flight_time); + _param_lnd_flight_t_hi.commit_no_notification(); flight_time = _total_flight_time & 0xffffffff; - _param_total_flight_time_low.set(flight_time); - _param_total_flight_time_low.commit_no_notification(); + _param_lnd_flight_t_lo.set(flight_time); + _param_lnd_flight_t_lo.commit_no_notification(); } _previous_armed_state = _armed; diff --git a/src/modules/land_detector/LandDetector.h b/src/modules/land_detector/LandDetector.h index 7e82641d19b..841be2d79d7 100644 --- a/src/modules/land_detector/LandDetector.h +++ b/src/modules/land_detector/LandDetector.h @@ -46,6 +46,7 @@ #include #include +#include #include #include #include @@ -167,6 +168,10 @@ private: hrt_abstime _total_flight_time{0}; ///< total vehicle flight time in microseconds hrt_abstime _time_last_move_detect_us{0}; // timestamp of last movement detection event in microseconds + hrt_abstime _time_last_acceleration_sample_us{0}; + + AlphaFilter _specific_force_fast{0.5f}; + AlphaFilter _specific_force_slow{5.f}; perf_counter_t _cycle_perf{perf_alloc(PC_ELAPSED, MODULE_NAME": cycle")}; @@ -189,8 +194,8 @@ private: DEFINE_PARAMETERS_CUSTOM_PARENT( ModuleParams, - (ParamInt) _param_total_flight_time_high, - (ParamInt) _param_total_flight_time_low + (ParamInt) _param_lnd_flight_t_hi, + (ParamInt) _param_lnd_flight_t_lo ); }; diff --git a/src/modules/land_detector/MulticopterLandDetector.cpp b/src/modules/land_detector/MulticopterLandDetector.cpp index 2992f8a0121..c54c1c48908 100644 --- a/src/modules/land_detector/MulticopterLandDetector.cpp +++ b/src/modules/land_detector/MulticopterLandDetector.cpp @@ -212,8 +212,8 @@ bool MulticopterLandDetector::_get_ground_contact_state() _land_detected.horizontal_movement |= _horizontal_movement; - if (lpos_available && _vehicle_local_position.dist_bottom_valid && _param_lndmc_alt_gnd_effect.get() > 0) { - _below_gnd_effect_hgt = _vehicle_local_position.dist_bottom < _param_lndmc_alt_gnd_effect.get(); + if (lpos_available && _vehicle_local_position.dist_bottom_valid && _param_lndmc_alt_gnd.get() > 0) { + _below_gnd_effect_hgt = _vehicle_local_position.dist_bottom < _param_lndmc_alt_gnd.get(); } else { _below_gnd_effect_hgt = false; diff --git a/src/modules/land_detector/MulticopterLandDetector.h b/src/modules/land_detector/MulticopterLandDetector.h index 63e6fa40abb..ff2a92ccc72 100644 --- a/src/modules/land_detector/MulticopterLandDetector.h +++ b/src/modules/land_detector/MulticopterLandDetector.h @@ -122,7 +122,7 @@ private: (ParamFloat) _param_lndmc_rot_max, (ParamFloat) _param_lndmc_xy_vel_max, (ParamFloat) _param_lndmc_z_vel_max, - (ParamFloat) _param_lndmc_alt_gnd_effect + (ParamFloat) _param_lndmc_alt_gnd ); }; diff --git a/src/modules/logger/logged_topics.cpp b/src/modules/logger/logged_topics.cpp index 198056da08d..b4fc0cf6bc1 100644 --- a/src/modules/logger/logged_topics.cpp +++ b/src/modules/logger/logged_topics.cpp @@ -253,7 +253,7 @@ void LoggedTopics::add_default_topics() add_topic_multi("vehicle_imu", 500, 4); add_topic_multi("vehicle_imu_status", 1000, 4); add_optional_topic_multi("vehicle_magnetometer", 500, 4); - add_topic("vehicle_optical_flow", 500); + add_topic_multi("vehicle_optical_flow", 500); add_topic_multi("aux_global_position", 500); add_optional_topic("pps_capture"); @@ -355,7 +355,7 @@ void LoggedTopics::add_estimator_replay_topics() // current EKF2 subscriptions add_topic("airspeed"); add_topic("airspeed_validated"); - add_topic("vehicle_optical_flow"); + add_topic_multi("vehicle_optical_flow"); add_topic("sensor_combined"); add_topic("sensor_selection"); add_topic("vehicle_air_data"); diff --git a/src/modules/logger/logger.cpp b/src/modules/logger/logger.cpp index d08b623accb..a6b66cafdeb 100644 --- a/src/modules/logger/logger.cpp +++ b/src/modules/logger/logger.cpp @@ -1377,7 +1377,7 @@ int Logger::get_log_file_name(LogType type, char *file_name, size_t file_name_si const char *crypto_suffix = ""; #if defined(PX4_CRYPTO) - if (_param_sdlog_crypto_algorithm.get() != 0) { + if (_param_sdlog_algorithm.get() != 0) { crypto_suffix = "e"; } @@ -1528,9 +1528,9 @@ void Logger::start_log_file(LogType type) #if defined(PX4_CRYPTO) _writer.set_encryption_parameters( - (px4_crypto_algorithm_t)_param_sdlog_crypto_algorithm.get(), - _param_sdlog_crypto_key.get(), - _param_sdlog_crypto_exchange_key.get()); + (px4_crypto_algorithm_t)_param_sdlog_algorithm.get(), + _param_sdlog_key.get(), + _param_sdlog_exch_key.get()); #endif // PX4_CRYPTO if (_writer.start_log_file(type, file_name)) { diff --git a/src/modules/logger/logger.h b/src/modules/logger/logger.h index ec3926f3fb8..17d665a176c 100644 --- a/src/modules/logger/logger.h +++ b/src/modules/logger/logger.h @@ -420,9 +420,9 @@ private: (ParamBool) _param_sdlog_boot_bat, (ParamBool) _param_sdlog_uuid #if defined(PX4_CRYPTO) - , (ParamInt) _param_sdlog_crypto_algorithm, - (ParamInt) _param_sdlog_crypto_key, - (ParamInt) _param_sdlog_crypto_exchange_key + , (ParamInt) _param_sdlog_algorithm, + (ParamInt) _param_sdlog_key, + (ParamInt) _param_sdlog_exch_key #endif // PX4_CRYPTO ) }; diff --git a/src/modules/mag_bias_estimator/params.yaml b/src/modules/mag_bias_estimator/params.yaml index ca26245f565..63274877f1f 100644 --- a/src/modules/mag_bias_estimator/params.yaml +++ b/src/modules/mag_bias_estimator/params.yaml @@ -9,7 +9,7 @@ parameters: This enables continuous calibration of the magnetometers before takeoff using gyro data. type: boolean - default: 1 + default: 0 reboot_required: true MBE_LEARN_GAIN: description: diff --git a/src/modules/manual_control/ManualControl.cpp b/src/modules/manual_control/ManualControl.cpp index 491f07b01a2..d7b47be8c93 100644 --- a/src/modules/manual_control/ManualControl.cpp +++ b/src/modules/manual_control/ManualControl.cpp @@ -462,32 +462,32 @@ void ManualControl::evaluateModeSlot(uint8_t mode_slot) case manual_control_switches_s::MODE_SLOT_1: sendActionRequest(action_request_s::ACTION_SWITCH_MODE, action_request_s::SOURCE_RC_MODE_SLOT, - navStateFromParam(_param_fltmode_1.get())); + navStateFromParam(_param_com_fltmode1.get())); break; case manual_control_switches_s::MODE_SLOT_2: sendActionRequest(action_request_s::ACTION_SWITCH_MODE, action_request_s::SOURCE_RC_MODE_SLOT, - navStateFromParam(_param_fltmode_2.get())); + navStateFromParam(_param_com_fltmode2.get())); break; case manual_control_switches_s::MODE_SLOT_3: sendActionRequest(action_request_s::ACTION_SWITCH_MODE, action_request_s::SOURCE_RC_MODE_SLOT, - navStateFromParam(_param_fltmode_3.get())); + navStateFromParam(_param_com_fltmode3.get())); break; case manual_control_switches_s::MODE_SLOT_4: sendActionRequest(action_request_s::ACTION_SWITCH_MODE, action_request_s::SOURCE_RC_MODE_SLOT, - navStateFromParam(_param_fltmode_4.get())); + navStateFromParam(_param_com_fltmode4.get())); break; case manual_control_switches_s::MODE_SLOT_5: sendActionRequest(action_request_s::ACTION_SWITCH_MODE, action_request_s::SOURCE_RC_MODE_SLOT, - navStateFromParam(_param_fltmode_5.get())); + navStateFromParam(_param_com_fltmode5.get())); break; case manual_control_switches_s::MODE_SLOT_6: sendActionRequest(action_request_s::ACTION_SWITCH_MODE, action_request_s::SOURCE_RC_MODE_SLOT, - navStateFromParam(_param_fltmode_6.get())); + navStateFromParam(_param_com_fltmode6.get())); break; default: diff --git a/src/modules/manual_control/ManualControl.hpp b/src/modules/manual_control/ManualControl.hpp index 93d4593fb88..86348519564 100644 --- a/src/modules/manual_control/ManualControl.hpp +++ b/src/modules/manual_control/ManualControl.hpp @@ -157,11 +157,11 @@ private: (ParamFloat) _param_man_kill_gest_t, (ParamBool) _param_com_arm_swisbtn, (ParamInt) _param_rc_map_pay_sw, - (ParamInt) _param_fltmode_1, - (ParamInt) _param_fltmode_2, - (ParamInt) _param_fltmode_3, - (ParamInt) _param_fltmode_4, - (ParamInt) _param_fltmode_5, - (ParamInt) _param_fltmode_6 + (ParamInt) _param_com_fltmode1, + (ParamInt) _param_com_fltmode2, + (ParamInt) _param_com_fltmode3, + (ParamInt) _param_com_fltmode4, + (ParamInt) _param_com_fltmode5, + (ParamInt) _param_com_fltmode6 ) }; diff --git a/src/modules/mavlink/Kconfig b/src/modules/mavlink/Kconfig index 8fb9219d9d6..0a09b66b190 100644 --- a/src/modules/mavlink/Kconfig +++ b/src/modules/mavlink/Kconfig @@ -11,6 +11,16 @@ depends on MODULES_MAVLINK ---help--- Select the Mavlink dialect to generate and use. +menuconfig MAVLINK_NUM_CONFIG_INSTANCES +depends on MODULES_MAVLINK + int "Number of MAVLink instance configurations" + default 3 + range 1 3 if BOARD_CONSTRAINED_MEMORY + range 1 5 + ---help--- + Number of MAV_x_* parameter sets. At most 6 MAVLink instances can + run at once (4 on constrained-memory boards), and USB takes one. + menuconfig MAVLINK_UAVCAN_PARAMETERS depends on MODULES_MAVLINK && DRIVERS_UAVCAN bool "Mavlink UAVCAN parameter support" diff --git a/src/modules/mavlink/mavlink_events.cpp b/src/modules/mavlink/mavlink_events.cpp index 9cfb5cbb918..da87fdbac74 100644 --- a/src/modules/mavlink/mavlink_events.cpp +++ b/src/modules/mavlink/mavlink_events.cpp @@ -188,6 +188,10 @@ void SendProtocol::handle_request_event(const mavlink_message_t &msg) const const uint16_t end_sequence = request_event.last_sequence + 1; + // Called from the receiver thread: lock_send() serializes access to the + // shared per-channel mavlink_status_t with Mavlink::task_main. + _mavlink.lock_send(); + for (uint16_t sequence = request_event.first_sequence; sequence != end_sequence; ++sequence) { if (_buffer.get_event(sequence, e)) { PX4_DEBUG("sending requested event %i", sequence); @@ -203,6 +207,8 @@ void SendProtocol::handle_request_event(const mavlink_message_t &msg) const mavlink_msg_send_struct_target(_mavlink.get_channel(), RESPONSE_EVENT_ERROR, &event_error, msg.sysid); } } + + _mavlink.unlock_send(); } void SendProtocol::send_event(const Event &event) const diff --git a/src/modules/mavlink/mavlink_log_handler.cpp b/src/modules/mavlink/mavlink_log_handler.cpp index 23a98431040..0689fb6ad29 100644 --- a/src/modules/mavlink/mavlink_log_handler.cpp +++ b/src/modules/mavlink/mavlink_log_handler.cpp @@ -122,6 +122,12 @@ void MavlinkLogHandler::state_idle() } } +void MavlinkLogHandler::close_files() +{ + close_current_entry(); + _state = LogHandlerState::Idle; +} + void MavlinkLogHandler::close_current_entry() { if (_current_entry.fp) { diff --git a/src/modules/mavlink/mavlink_log_handler.h b/src/modules/mavlink/mavlink_log_handler.h index 9634d7f9239..399a1e0d5b0 100644 --- a/src/modules/mavlink/mavlink_log_handler.h +++ b/src/modules/mavlink/mavlink_log_handler.h @@ -59,6 +59,15 @@ public: void send(); void handle_message(const mavlink_message_t *msg); + /** + * Close any open log file. Must be called from the thread that handles the + * log messages (the receiver thread): on NuttX a FILE belongs to the task + * group that opened it, and fclose() from another task (e.g. the destructor + * running in 'mavlink stop') frees it while it stays linked in the owner's + * stream list, which then frees it again on exit (double free). + */ + void close_files(); + /// True while LOG_DATA is streaming out. bool sending_data() const { return _state == LogHandlerState::SendingData; } diff --git a/src/modules/mavlink/mavlink_main.cpp b/src/modules/mavlink/mavlink_main.cpp index bb2de514880..c0d50db983b 100644 --- a/src/modules/mavlink/mavlink_main.cpp +++ b/src/modules/mavlink/mavlink_main.cpp @@ -1666,7 +1666,7 @@ Mavlink::update_rate_mult() } else if (_radio_status_available) { // check for RADIO_STATUS timeout and reset - if (hrt_elapsed_time(&_rstatus.timestamp) > (_param_mav_radio_timeout.get() * 1_s)) { + if (hrt_elapsed_time(&_rstatus.timestamp) > (_param_mav_radio_tout.get() * 1_s)) { _radio_status_available = false; log_radio_timeout = true; @@ -3432,7 +3432,7 @@ void Mavlink::publish_telemetry_status() void Mavlink::configure_sik_radio() { /* radio config check */ - if (_uart_fd >= 0 && _param_sik_radio_id.get() != 0) { + if (_uart_fd >= 0 && _param_mav_sik_radio_id.get() != 0) { /* request to configure radio and radio is present */ FILE *fs = fdopen(_uart_fd, "w"); @@ -3443,9 +3443,9 @@ void Mavlink::configure_sik_radio() fflush(fs); px4_usleep(1200000); - if (_param_sik_radio_id.get() > 0) { + if (_param_mav_sik_radio_id.get() > 0) { /* set channel */ - fprintf(fs, "ATS3=%" PRIu32 "\r\n", _param_sik_radio_id.get()); + fprintf(fs, "ATS3=%" PRIu32 "\r\n", _param_mav_sik_radio_id.get()); px4_usleep(200000); } else { @@ -3476,8 +3476,8 @@ void Mavlink::configure_sik_radio() } /* reset param and save */ - _param_sik_radio_id.set(0); - _param_sik_radio_id.commit_no_notification(); + _param_mav_sik_radio_id.set(0); + _param_mav_sik_radio_id.commit_no_notification(); } } @@ -3643,6 +3643,7 @@ Mavlink::display_status() printf("\t rx loss: %.1f%%\n", (double)_tstatus.rx_message_lost_rate * 100.0); printf("\t rx unknown messages: %" PRIu32 "\n", _tstatus.rx_unknown_message_count); printf("\t rx bad signatures: %" PRIu32 "\n", _tstatus.rx_bad_signature_count); + printf("\t rx bad CRCs: %" PRIu32 "\n", _tstatus.rx_bad_crc_count); #if !defined(CONSTRAINED_FLASH) _receiver.print_detailed_rx_stats(); diff --git a/src/modules/mavlink/mavlink_main.h b/src/modules/mavlink/mavlink_main.h index a117351a20c..02422c8d06e 100644 --- a/src/modules/mavlink/mavlink_main.h +++ b/src/modules/mavlink/mavlink_main.h @@ -512,7 +512,7 @@ public: bool failure_injection_enabled() const { #if defined(CONFIG_MODULES_FAILURE_INJECTION_MANAGER) - return _param_sys_failure_injection_enabled.get(); + return _param_sys_failure_en.get(); #else return false; #endif // CONFIG_MODULES_FAILURE_INJECTION_MANAGER @@ -766,16 +766,16 @@ private: (ParamInt) _param_mav_sys_id, (ParamInt) _param_mav_comp_id, (ParamInt) _param_mav_proto_ver, - (ParamInt) _param_sik_radio_id, + (ParamInt) _param_mav_sik_radio_id, (ParamInt) _param_mav_type, (ParamBool) _param_mav_usehilgps, (ParamBool) _param_mav_fwdextsp, (ParamBool) _param_mav_hash_chk_en, (ParamBool) _param_mav_hb_forw_en, - (ParamInt) _param_mav_radio_timeout, + (ParamInt) _param_mav_radio_tout, (ParamInt) _param_sys_hitl #if defined(CONFIG_MODULES_FAILURE_INJECTION_MANAGER) - , (ParamBool) _param_sys_failure_injection_enabled + , (ParamBool) _param_sys_failure_en #endif // CONFIG_MODULES_FAILURE_INJECTION_MANAGER ) diff --git a/src/modules/mavlink/mavlink_mission.cpp b/src/modules/mavlink/mavlink_mission.cpp index 9dab758a5c6..938b9f6a968 100644 --- a/src/modules/mavlink/mavlink_mission.cpp +++ b/src/modules/mavlink/mavlink_mission.cpp @@ -1037,8 +1037,6 @@ MavlinkMissionManager::handle_mission_count(const mavlink_message_t *msg) _transfer_land_marker = -1; } else if (_state == MAVLINK_WPM_STATE_GETLIST) { - _time_last_recv = hrt_absolute_time(); - if (msg->sysid != _transfer_partner_sysid || msg->compid != _transfer_partner_compid) { PX4_DEBUG("WPM: Request from another partner while receiveing. Ignore"); @@ -1046,6 +1044,8 @@ MavlinkMissionManager::handle_mission_count(const mavlink_message_t *msg) return; } + _time_last_recv = hrt_absolute_time(); + if (_transfer_seq == 0) { /* looks like our MISSION_REQUEST was lost, try again */ PX4_DEBUG("WPM: MISSION_COUNT %u from ID %" PRIu32 " (again)", wpc.count, msg->sysid); diff --git a/src/modules/mavlink/mavlink_receiver.cpp b/src/modules/mavlink/mavlink_receiver.cpp index 8a939c31ebc..22d648cfc31 100644 --- a/src/modules/mavlink/mavlink_receiver.cpp +++ b/src/modules/mavlink/mavlink_receiver.cpp @@ -2814,10 +2814,10 @@ MavlinkReceiver::publish_hil_battery() hil_battery_status.timestamp = hrt_absolute_time(); - hil_battery_status.cell_count = _param_bat_cells_count.get(); + hil_battery_status.cell_count = _param_bat1_n_cells.get(); hil_battery_status.remaining = 0.70f; - float cells_v = _param_bat_v_empty.get() * (1.f - hil_battery_status.remaining) - + hil_battery_status.remaining * _param_bat_v_charged.get(); + float cells_v = _param_bat1_v_empty.get() * (1.f - hil_battery_status.remaining) + + hil_battery_status.remaining * _param_bat1_v_charged.get(); hil_battery_status.voltage_v = hil_battery_status.cell_count * cells_v; hil_battery_status.current_a = 10.0f; @@ -4158,7 +4158,7 @@ MavlinkReceiver::run() const FrameCheck frame_check = check_frame(framing, msg); - if (frame_check == FrameCheck::Invalid) { + if (frame_check == FrameCheck::BadCrc || frame_check == FrameCheck::Invalid) { reset_parser_after_rejected_frame(buf[i]); } @@ -4203,6 +4203,11 @@ MavlinkReceiver::run() } else if (frame_check == FrameCheck::BadSignature) { _bad_signature_counter++; + + } else if (frame_check == FrameCheck::BadCrc && msg.sysid != 0 && msg.compid != 0 + && component_was_seen(msg.sysid, msg.compid)) { + // Header may be corrupted too: count only known senders (0 is a wildcard) + _bad_crc_counter++; } if (frame_check == FrameCheck::Ok || frame_check == FrameCheck::ForwardOnly) { @@ -4222,6 +4227,7 @@ MavlinkReceiver::run() tstatus.rx_message_lost_count = _total_lost_counter; tstatus.rx_unknown_message_count = _unknown_message_counter; tstatus.rx_bad_signature_count = _bad_signature_counter; + tstatus.rx_bad_crc_count = _bad_crc_counter; const uint64_t total_messages = _total_received_counter + _total_lost_counter; tstatus.rx_message_lost_rate = (total_messages > 0) ? static_cast(_total_lost_counter) / static_cast(total_messages) : 0.f; @@ -4283,6 +4289,9 @@ MavlinkReceiver::run() _tune_publisher->publish_next_tune(t); } } + + // Release files opened by this thread while still in its task group (see close_files()) + _mavlink_log_handler.close_files(); } MavlinkReceiver::FrameCheck MavlinkReceiver::check_frame(uint8_t framing, const mavlink_message_t &message) @@ -4303,9 +4312,13 @@ MavlinkReceiver::FrameCheck MavlinkReceiver::check_frame(uint8_t framing, const return FrameCheck::Incomplete; } - // Messages which are not in our dialect can't have their CRC checked and - // are reported as bad CRC by the parser. They can still be forwarded. - if ((mavlink_get_msg_entry(message.msgid) != nullptr) || (_status.flags & MAVLINK_STATUS_FLAG_IN_MAVLINK1)) { + // Known message: corrupted frame or different message definition on the sender + if (mavlink_get_msg_entry(message.msgid) != nullptr) { + return FrameCheck::BadCrc; + } + + // Unknown MAVLink 1 message + if (_status.flags & MAVLINK_STATUS_FLAG_IN_MAVLINK1) { return FrameCheck::Invalid; } diff --git a/src/modules/mavlink/mavlink_receiver.h b/src/modules/mavlink/mavlink_receiver.h index 3f4230e99cd..3ff788b6ed1 100644 --- a/src/modules/mavlink/mavlink_receiver.h +++ b/src/modules/mavlink/mavlink_receiver.h @@ -296,7 +296,8 @@ private: Ok, ///< valid, handle and forward ForwardOnly, ///< not in our dialect, can't be handled but can be forwarded BadSignature, ///< signature missing or not valid with our key, drop - Invalid, ///< bad CRC, drop + BadCrc, ///< known message with a bad CRC, drop + Invalid, ///< unknown MAVLink 1 message, drop }; FrameCheck check_frame(uint8_t framing, const mavlink_message_t &message); @@ -360,6 +361,7 @@ private: uint64_t _total_lost_counter{0}; ///< Total messages lost during transmission. uint32_t _unknown_message_counter{0}; ///< Messages not in our dialect uint32_t _bad_signature_counter{0}; ///< Messages with missing or invalid signature + uint32_t _bad_crc_counter{0}; ///< Known messages dropped for a bad CRC uint8_t _mavlink_status_last_buffer_overrun{0}; uint8_t _mavlink_status_last_parse_error{0}; @@ -509,9 +511,9 @@ private: (ParamFloat) _param_bat_crit_thr, (ParamFloat) _param_bat_emergen_thr, (ParamFloat) _param_bat_low_thr, - (ParamInt) _param_bat_cells_count, - (ParamFloat) _param_bat_v_charged, - (ParamFloat) _param_bat_v_empty + (ParamInt) _param_bat1_n_cells, + (ParamFloat) _param_bat1_v_charged, + (ParamFloat) _param_bat1_v_empty ); #if defined(CONFIG_BOARD_HAS_RID_EEPROM) diff --git a/src/modules/mavlink/mavlink_timesync.cpp b/src/modules/mavlink/mavlink_timesync.cpp index a127d27bc13..1b5b91a8e31 100644 --- a/src/modules/mavlink/mavlink_timesync.cpp +++ b/src/modules/mavlink/mavlink_timesync.cpp @@ -70,7 +70,11 @@ MavlinkTimesync::handle_message(const mavlink_message_t *msg) rsync.ts1 = tsync.ts1; rsync.target_component = msg->compid; + // Runs on the receiver thread: lock_send() serializes access to the + // shared per-channel mavlink_status_t with Mavlink::task_main. + _mavlink.lock_send(); mavlink_msg_send_struct_target(_mavlink.get_channel(), TIMESYNC, &rsync, msg->sysid); + _mavlink.unlock_send(); return; diff --git a/src/modules/mavlink/module.yaml b/src/modules/mavlink/module.yaml index f29a2d792b0..fa64ef3aa33 100644 --- a/src/modules/mavlink/module.yaml +++ b/src/modules/mavlink/module.yaml @@ -1,4 +1,6 @@ -__max_num_config_instances: &max_num_config_instances 3 +__max_num_config_instances: &max_num_config_instances + kconfig: MAVLINK_NUM_CONFIG_INSTANCES + default: 3 module_name: MAVLink serial_config: @@ -48,6 +50,7 @@ serial_config: # 0: Telem1 Port (Telemetry Link) # 1: Telem2 Port (Companion Link). Disabled by default to reduce RAM usage # 2: Board-specific / no fixed function or port + # 3+: Optional (CONFIG_MAVLINK_NUM_CONFIG_INSTANCES), defaults as instance 2 default: [TEL1, "", ""] num_instances: *max_num_config_instances supports_networking: true diff --git a/src/modules/mavlink/streams/OPTICAL_FLOW_RAD.hpp b/src/modules/mavlink/streams/OPTICAL_FLOW_RAD.hpp index 02f368b4c31..c80bfe09899 100644 --- a/src/modules/mavlink/streams/OPTICAL_FLOW_RAD.hpp +++ b/src/modules/mavlink/streams/OPTICAL_FLOW_RAD.hpp @@ -49,47 +49,60 @@ public: unsigned get_size() override { - return _vehicle_optical_flow_sub.advertised() ? (MAVLINK_MSG_ID_OPTICAL_FLOW_RAD_LEN + MAVLINK_NUM_NON_PAYLOAD_BYTES) : - 0; + unsigned size = 0; + + for (auto &sub : _vehicle_optical_flow_subs) { + if (sub.advertised()) { + size += MAVLINK_MSG_ID_OPTICAL_FLOW_RAD_LEN + MAVLINK_NUM_NON_PAYLOAD_BYTES; + } + } + + return size; } private: explicit MavlinkStreamOpticalFlowRad(Mavlink *mavlink) : MavlinkStream(mavlink) {} - uORB::Subscription _vehicle_optical_flow_sub{ORB_ID(vehicle_optical_flow)}; + uORB::Subscription _vehicle_optical_flow_subs[2] { + {ORB_ID(vehicle_optical_flow), 0}, + {ORB_ID(vehicle_optical_flow), 1}, + }; bool send() override { - vehicle_optical_flow_s flow; + bool sent = false; - if (_vehicle_optical_flow_sub.update(&flow)) { - mavlink_optical_flow_rad_t msg{}; + for (auto &sub : _vehicle_optical_flow_subs) { + vehicle_optical_flow_s flow; - msg.time_usec = flow.timestamp_sample; - msg.sensor_id = _vehicle_optical_flow_sub.get_instance(); - msg.integration_time_us = flow.integration_timespan_us; - msg.integrated_x = flow.pixel_flow[0]; - msg.integrated_y = flow.pixel_flow[1]; - msg.integrated_xgyro = flow.delta_angle[0]; - msg.integrated_ygyro = flow.delta_angle[1]; - msg.integrated_zgyro = flow.delta_angle[2]; - // msg.temperature = 0; - msg.quality = flow.quality; - // msg.time_delta_distance_us = 0; + if (sub.update(&flow)) { + mavlink_optical_flow_rad_t msg{}; - if (PX4_ISFINITE(flow.distance_m)) { - msg.distance = flow.distance_m; + msg.time_usec = flow.timestamp_sample; + msg.sensor_id = sub.get_instance(); + msg.integration_time_us = flow.integration_timespan_us; + msg.integrated_x = flow.pixel_flow[0]; + msg.integrated_y = flow.pixel_flow[1]; + msg.integrated_xgyro = flow.delta_angle[0]; + msg.integrated_ygyro = flow.delta_angle[1]; + msg.integrated_zgyro = flow.delta_angle[2]; + // msg.temperature = 0; + msg.quality = flow.quality; + // msg.time_delta_distance_us = 0; - } else { - msg.distance = -1; + if (PX4_ISFINITE(flow.distance_m)) { + msg.distance = flow.distance_m; + + } else { + msg.distance = -1; + } + + mavlink_msg_optical_flow_rad_send_struct(_mavlink->get_channel(), &msg); + sent = true; } - - mavlink_msg_optical_flow_rad_send_struct(_mavlink->get_channel(), &msg); - - return true; } - return false; + return sent; } }; diff --git a/src/modules/mavlink/streams/UAVIONIX_ADSB_OUT_CFG.hpp b/src/modules/mavlink/streams/UAVIONIX_ADSB_OUT_CFG.hpp index afcd6d02fe3..34e9ff6a62f 100644 --- a/src/modules/mavlink/streams/UAVIONIX_ADSB_OUT_CFG.hpp +++ b/src/modules/mavlink/streams/UAVIONIX_ADSB_OUT_CFG.hpp @@ -67,8 +67,8 @@ private: } } - int32_t callsign_part1 = _adsb_callsign_part1.get(); - int32_t callsign_part2 = _adsb_callsign_part2.get(); + int32_t callsign_part1 = _param_adsb_callsign_1.get(); + int32_t callsign_part2 = _param_adsb_callsign_2.get(); bool success = false; @@ -90,13 +90,13 @@ private: } DEFINE_PARAMETERS( - (ParamInt) _adsb_icao, - (ParamInt) _adsb_len_width, - (ParamInt) _adsb_emit_type, - (ParamInt) _adsb_gps_offset_lat, - (ParamInt) _adsb_gps_offset_lon, - (ParamInt) _adsb_callsign_part1, - (ParamInt) _adsb_callsign_part2 + (ParamInt) _param_adsb_icao_id, + (ParamInt) _param_adsb_len_width, + (ParamInt) _param_adsb_emit_type, + (ParamInt) _param_adsb_gps_off_lat, + (ParamInt) _param_adsb_gps_off_lon, + (ParamInt) _param_adsb_callsign_1, + (ParamInt) _param_adsb_callsign_2 ); uint16_t _stall_speed{0}; // [cm/s] @@ -124,7 +124,7 @@ private: bool send() override { // Required update for static message is 0.1 [Hz] - const int32_t adsb_icao = _adsb_icao.get(); + const int32_t adsb_icao = _param_adsb_icao_id.get(); const bool adsb_out_enabled = adsb_icao >= 0; // ADSB_ICAO_ID controls transmission only. Keep the receiver enabled so // uAvionix traffic reports remain available to ADS-B In and DAA. @@ -138,10 +138,10 @@ private: .ICAO = adsb_out_enabled ? static_cast(adsb_icao) : 0, .stallSpeed = _stall_speed, .callsign = {'\0'}, - .emitterType = static_cast(_adsb_emit_type.get()), - .aircraftSize = static_cast(_adsb_len_width.get()), - .gpsOffsetLat = static_cast(_adsb_gps_offset_lat.get()), - .gpsOffsetLon = static_cast(_adsb_gps_offset_lon.get()), + .emitterType = static_cast(_param_adsb_emit_type.get()), + .aircraftSize = static_cast(_param_adsb_len_width.get()), + .gpsOffsetLat = static_cast(_param_adsb_gps_off_lat.get()), + .gpsOffsetLon = static_cast(_param_adsb_gps_off_lon.get()), .rfSelect = rf_select }; diff --git a/src/modules/mavlink/streams/UAVIONIX_ADSB_OUT_DYNAMIC.hpp b/src/modules/mavlink/streams/UAVIONIX_ADSB_OUT_DYNAMIC.hpp index af2c2c2e7df..23c6201f508 100644 --- a/src/modules/mavlink/streams/UAVIONIX_ADSB_OUT_DYNAMIC.hpp +++ b/src/modules/mavlink/streams/UAVIONIX_ADSB_OUT_DYNAMIC.hpp @@ -66,8 +66,8 @@ private: uORB::Subscription _vehicle_status_sub{ORB_ID(vehicle_status)}; DEFINE_PARAMETERS( - (ParamInt) _adsb_squawk, - (ParamInt) _adsb_emergc + (ParamInt) _param_adsb_squawk, + (ParamInt) _param_adsb_emergc ); @@ -106,10 +106,10 @@ private: .velNS = static_cast(vehicle_gnss.receiver.vel_north * 100.0f), // convert [m/s] to [cm/s] .VelEW = static_cast(vehicle_gnss.receiver.vel_east * 100.0f), // convert [m/s] to [cm/s] .state = UAVIONIX_ADSB_OUT_DYNAMIC_STATE_ON_GROUND, - .squawk = static_cast(_adsb_squawk.get()), + .squawk = static_cast(_param_adsb_squawk.get()), .gpsFix = vehicle_gnss.receiver.fix_type, .numSats = vehicle_gnss.receiver.satellites_used, - .emergencyStatus = static_cast(_adsb_emergc.get()) + .emergencyStatus = static_cast(_param_adsb_emergc.get()) }; if (vehicle_status.arming_state == vehicle_status_s::ARMING_STATE_ARMED) { diff --git a/src/modules/mc_nn_control/mc_nn_control.cpp b/src/modules/mc_nn_control/mc_nn_control.cpp index 15c0bae4ed8..84aa2ca5176 100644 --- a/src/modules/mc_nn_control/mc_nn_control.cpp +++ b/src/modules/mc_nn_control/mc_nn_control.cpp @@ -96,9 +96,9 @@ bool MulticopterNeuralNetworkControl::init() void MulticopterNeuralNetworkControl::UpdateMotorLimits() { - const float thrust_coeff = _param_thrust_coeff.get(); - const float min_rpm = _param_min_rpm.get(); - const float max_rpm = _param_max_rpm.get(); + const float thrust_coeff = _param_mc_nn_thrst_coef.get(); + const float min_rpm = _param_mc_nn_min_rpm.get(); + const float max_rpm = _param_mc_nn_max_rpm.get(); if (!nn_control::valid_motor_limits(thrust_coeff, min_rpm, max_rpm)) { // The mapping keeps whatever was valid before, so a write while flying does @@ -141,7 +141,7 @@ void MulticopterNeuralNetworkControl::ReportInvalidLimits() */ events::send(events::ID("mc_nn_control_motor_limits_invalid"), events::Log::Error, "Neural control: invalid motor limits, MC_NN_MIN_RPM {2}, MC_NN_MAX_RPM {1}, MC_NN_THRST_COEF {3:.2}", - (int32_t)_param_max_rpm.get(), (int32_t)_param_min_rpm.get(), _param_thrust_coeff.get()); + (int32_t)_param_mc_nn_max_rpm.get(), (int32_t)_param_mc_nn_min_rpm.get(), _param_mc_nn_thrst_coef.get()); } void MulticopterNeuralNetworkControl::CheckObservations() @@ -724,7 +724,7 @@ void MulticopterNeuralNetworkControl::Run() reset_trajectory_setpoint(_position); } - if (_param_manual_control.get()) { + if (_param_mc_nn_manl_ctrl.get()) { // Run manual control mode _manual_control_setpoint_sub.update(&_manual_control_setpoint); diff --git a/src/modules/mc_nn_control/mc_nn_control.hpp b/src/modules/mc_nn_control/mc_nn_control.hpp index 62f241316e2..f2db6e0b17a 100644 --- a/src/modules/mc_nn_control/mc_nn_control.hpp +++ b/src/modules/mc_nn_control/mc_nn_control.hpp @@ -197,9 +197,9 @@ private: manual_control_setpoint_s _manual_control_setpoint{}; DEFINE_PARAMETERS( - (ParamInt) _param_max_rpm, - (ParamInt) _param_min_rpm, - (ParamFloat) _param_thrust_coeff, - (ParamBool) _param_manual_control + (ParamInt) _param_mc_nn_max_rpm, + (ParamInt) _param_mc_nn_min_rpm, + (ParamFloat) _param_mc_nn_thrst_coef, + (ParamBool) _param_mc_nn_manl_ctrl ) }; diff --git a/src/modules/mc_raptor/mc_raptor.cpp b/src/modules/mc_raptor/mc_raptor.cpp index df27d927ab1..d7aa3ade7a9 100644 --- a/src/modules/mc_raptor/mc_raptor.cpp +++ b/src/modules/mc_raptor/mc_raptor.cpp @@ -258,7 +258,7 @@ bool Raptor::init() register_ext_component_request.px4_ros2_api_version = register_ext_component_request_s::LATEST_PX4_ROS2_API_VERSION; register_ext_component_request.register_arming_check = true; register_ext_component_request.register_mode = true; - register_ext_component_request.enable_replace_internal_mode = _param_mc_raptor_offboard.get(); + register_ext_component_request.enable_replace_internal_mode = _param_mc_raptor_offb.get(); register_ext_component_request.replace_internal_mode = vehicle_status_s::NAVIGATION_STATE_OFFBOARD; register_ext_component_request.request_offboard_setpoints = true; _register_ext_component_request_pub.publish(register_ext_component_request); diff --git a/src/modules/mc_raptor/mc_raptor.hpp b/src/modules/mc_raptor/mc_raptor.hpp index 95f024ad7a8..f9229c54239 100644 --- a/src/modules/mc_raptor/mc_raptor.hpp +++ b/src/modules/mc_raptor/mc_raptor.hpp @@ -276,7 +276,7 @@ private: LissajousParameters lissajous_params{}; // Set via 'mc_raptor intref lissajous ...' command DEFINE_PARAMETERS( (ParamInt) _param_imu_gyro_ratemax, - (ParamBool) _param_mc_raptor_offboard, + (ParamBool) _param_mc_raptor_offb, (ParamInt) _param_mc_raptor_intref ) diff --git a/src/modules/navigator/DetectAndAvoid/detect_and_avoid.cpp b/src/modules/navigator/DetectAndAvoid/detect_and_avoid.cpp index 030dba1fdc2..f3167cd6af5 100644 --- a/src/modules/navigator/DetectAndAvoid/detect_and_avoid.cpp +++ b/src/modules/navigator/DetectAndAvoid/detect_and_avoid.cpp @@ -431,11 +431,11 @@ void DetectAndAvoid::evaluate_and_publish_action() void DetectAndAvoid::refresh_ownship_ids() { _ownship_ids = {}; - _ownship_ids.icao = _vehicle_adsb_icao.get(); - _ownship_ids.icao_2 = _vehicle_adsb_icao_2.get(); + _ownship_ids.icao = _param_adsb_icao_id.get(); + _ownship_ids.icao_2 = _param_adsb_icao_id_2.get(); - _ownship_ids.callsign = DaaEncodedId::callsign_params_to_uint64(_vehicle_adsb_callsign_1.get(), - _vehicle_adsb_callsign_2.get()); + _ownship_ids.callsign = DaaEncodedId::callsign_params_to_uint64(_param_adsb_callsign_1.get(), + _param_adsb_callsign_2.get()); #ifndef BOARD_HAS_NO_UUID px4_guid_t px4_guid {}; diff --git a/src/modules/navigator/DetectAndAvoid/detect_and_avoid.h b/src/modules/navigator/DetectAndAvoid/detect_and_avoid.h index 74795ddbfdd..8442a13915c 100644 --- a/src/modules/navigator/DetectAndAvoid/detect_and_avoid.h +++ b/src/modules/navigator/DetectAndAvoid/detect_and_avoid.h @@ -249,9 +249,9 @@ private: #else (ParamInt) _param_nav_traff_avoid, #endif // CONFIG_NAVIGATOR_ADSB_F3442 - (ParamInt) _vehicle_adsb_icao, - (ParamInt) _vehicle_adsb_icao_2, - (ParamInt) _vehicle_adsb_callsign_1, - (ParamInt) _vehicle_adsb_callsign_2 + (ParamInt) _param_adsb_icao_id, + (ParamInt) _param_adsb_icao_id_2, + (ParamInt) _param_adsb_callsign_1, + (ParamInt) _param_adsb_callsign_2 ) }; diff --git a/src/modules/navigator/navigator.h b/src/modules/navigator/navigator.h index 994d200e927..33f896eb8fe 100644 --- a/src/modules/navigator/navigator.h +++ b/src/modules/navigator/navigator.h @@ -330,7 +330,7 @@ public: void geofence_breach_check(); // Param access - int get_loiter_min_alt() const { return _param_min_ltr_alt.get(); } + int get_loiter_min_alt() const { return _param_nav_min_ltr_alt.get(); } int get_landing_abort_min_alt() const { return _param_mis_lnd_abrt_alt.get(); } float get_param_mis_takeoff_alt() const { return _param_mis_takeoff_alt.get(); } float get_yaw_timeout() const { return _param_mis_yaw_tmt.get(); } @@ -514,7 +514,7 @@ private: _param_nav_fw_altl_rad, /**< acceptance rad for fixedwing alt before landing*/ (ParamFloat) _param_nav_mc_alt_rad, /**< acceptance rad for multicopter alt */ (ParamInt) _param_nav_force_vt, /**< acceptance radius for multicopter alt */ - (ParamFloat) _param_min_ltr_alt, /**< minimum altitude in Loiter mode*/ + (ParamFloat) _param_nav_min_ltr_alt, /**< minimum altitude in Loiter mode*/ (ParamFloat) _param_nav_min_gnd_dist, /**< minimum distance to ground (Mission and Return)*/ diff --git a/src/modules/navigator/rtl.cpp b/src/modules/navigator/rtl.cpp index 691ba3d7624..1bef1c7f421 100644 --- a/src/modules/navigator/rtl.cpp +++ b/src/modules/navigator/rtl.cpp @@ -56,15 +56,14 @@ using namespace math; static constexpr float MIN_DIST_THRESHOLD = 2.f; // Named constants for RTL_TYPE parameter values (must match value tags in rtl_params.yaml). +static constexpr int RTL_TYPE_CLOSEST_HOME_OR_SAFE_POINT = 0; +static constexpr int RTL_TYPE_MISSION_LAND_OR_SAFE_POINT = 1; static constexpr int RTL_TYPE_MISSION_FAST = 2; static constexpr int RTL_TYPE_DIRECT_WITH_MISSION_LAND = 3; static constexpr int RTL_TYPE_MISSION_FAST_OR_REVERSE = 4; static constexpr int RTL_TYPE_SAFE_POINT_DIRECT = 5; static constexpr int RTL_TYPE_HOME_OR_SAFE_POINT_DIRECT = 6; static constexpr hrt_abstime RTL_REPLAN_INTERVAL{2_s}; -static constexpr uint8_t RTL_STATUS_NO_SAFE_POINT{UINT8_MAX}; -static_assert(DM_KEY_SAFE_POINTS_MAX < RTL_STATUS_NO_SAFE_POINT, - "rtl_status.safe_point_index must represent every configured safe-point slot"); RTL::RTL(Navigator *navigator) : @@ -218,105 +217,114 @@ void RTL::runExecutors() void RTL::setRtlTypeAndDestination() { - uint8_t safe_point_index = RTL_STATUS_NO_SAFE_POINT; - RtlType new_rtl_type{RtlType::RTL_DIRECT}; - const MissionRouteCache &mission_route_cache = _navigator->get_mission_route_cache(); + applyReturn(selectReturn()); +} - // init destination with Home (used also with Type 2 and 4 as backup) - DestinationType destination_type = DestinationType::DESTINATION_TYPE_HOME; +RTL::ReturnSelection RTL::selectReturn() +{ + const int32_t rtl_type = _param_rtl_type.get(); + + // Start at Home, the fallback of every type but 5, which keeps only its yaw. + ReturnSelection selection{}; + selection.destination = homeDestination(); + + switch (rtl_type) { + case RTL_TYPE_MISSION_FAST: + case RTL_TYPE_MISSION_FAST_OR_REVERSE: + selectMissionPath(rtl_type, selection); + break; + + case RTL_TYPE_SAFE_POINT_DIRECT: + selectSafePoint(selection); + break; + + case RTL_TYPE_HOME_OR_SAFE_POINT_DIRECT: + selectHomeIfReachable(selection); + break; + + default: + // 0, 1 and 3, and any other value + selectClosest(rtl_type, selection); + break; + } + + return selection; +} + +PositionYawSetpoint RTL::homeDestination() const +{ PositionYawSetpoint destination; destination.lat = _home_pos_sub.get().lat; destination.lon = _home_pos_sub.get().lon; destination.alt = _home_pos_sub.get().alt; destination.yaw = _home_pos_sub.get().yaw; + return destination; +} - loiter_point_s landing_loiter; - landing_loiter.lat = destination.lat; - landing_loiter.lon = destination.lon; - landing_loiter.height_m = NAN; +void RTL::selectMissionPath(int32_t rtl_type, ReturnSelection &selection) const +{ + // Without a valid mission, go direct to Home. + const bool follow_to_landing = hasMissionLandStart() + && ((rtl_type == RTL_TYPE_MISSION_FAST) || reverseIsFurther()); - // Not every type looks for approaches: report only those this evaluation finds. - _home_has_land_approach = false; - _one_rally_point_has_land_approach = false; + if (follow_to_landing) { + selection.executor = RtlType::RTL_MISSION_FAST; - if (_param_rtl_type.get() == RTL_TYPE_MISSION_FAST) { - if (hasMissionLandStart()) { - new_rtl_type = RtlType::RTL_MISSION_FAST; - - } else if (hasValidMission()) { - new_rtl_type = RtlType::RTL_MISSION_FAST_REVERSE; - - } else { - // no valid mission, go direct to home - new_rtl_type = RtlType::RTL_DIRECT; - } - - } else if (_param_rtl_type.get() == RTL_TYPE_MISSION_FAST_OR_REVERSE) { - if (hasMissionLandStart() && reverseIsFurther()) { - new_rtl_type = RtlType::RTL_MISSION_FAST; - - } else if (hasValidMission()) { - new_rtl_type = RtlType::RTL_MISSION_FAST_REVERSE; - - } else { - // no valid mission, go direct to home - new_rtl_type = RtlType::RTL_DIRECT; - } - - } else if (_param_rtl_type.get() == RTL_TYPE_HOME_OR_SAFE_POINT_DIRECT) { + } else if (hasValidMission()) { + selection.executor = RtlType::RTL_MISSION_FAST_REVERSE; + } +} +void RTL::selectHomeIfReachable(ReturnSelection &selection) +{ #if defined(CONFIG_MODULES_VTOL_ATT_CONTROL) && CONFIG_MODULES_VTOL_ATT_CONTROL - _home_has_land_approach = mission_route::hasVtolLandApproachesNearLocation(mission_route_cache, destination, - _home_pos_sub.get().alt); + selection.home_has_land_approach = mission_route::hasVtolLandApproachesNearLocation( + _navigator->get_mission_route_cache(), selection.destination, _home_pos_sub.get().alt); #endif - // Set _rtl_direct with the home destination so calc_rtl_time_estimate() can check its reachability - const float rtl_alt_home = computeReturnAltitude(destination); - _rtl_direct.setRtlAlt(rtl_alt_home); - _rtl_direct.setRtlPosition(destination, landing_loiter); + const rtl_time_estimate_s time_to_home = estimateTimeToHome(); - const rtl_time_estimate_s time_to_home = _rtl_direct.calc_rtl_time_estimate(); + const float worst_battery_time_s = worstBatteryTimeRemaining(); - const float worst_battery_time_s = worstBatteryTimeRemaining(); + const bool home_within_reach = time_to_home.valid + && PX4_ISFINITE(worst_battery_time_s) + && (time_to_home.safe_time_estimate < worst_battery_time_s); - const bool home_within_reach = time_to_home.valid - && PX4_ISFINITE(worst_battery_time_s) - && (time_to_home.safe_time_estimate < worst_battery_time_s); + if (!home_within_reach) { + // Home is out of reach or not estimated: a rally point replaces Home only if it is closer + const float home_dist = get_distance_to_next_waypoint(_global_pos_sub.get().lat, _global_pos_sub.get().lon, + _home_pos_sub.get().lat, _home_pos_sub.get().lon); - if (!home_within_reach) { - // If battery data is valid, home is out of range: pick the closest rally point unconditionally - // If battery data is unavailable (NaN), we cannot assess reachability: pick the closest home or rally point - const float min_dist = PX4_ISFINITE(worst_battery_time_s) - ? FLT_MAX - : get_distance_to_next_waypoint(_global_pos_sub.get().lat, - _global_pos_sub.get().lon, - _home_pos_sub.get().lat, - _home_pos_sub.get().lon); + PositionYawSetpoint safe_point = findClosestSafePoint(home_dist, /*skip_near_home=*/false, + selection.safe_point_index, selection.rally_point_has_land_approach); - PositionYawSetpoint safe_point = findClosestSafePoint(min_dist, safe_point_index); - - if (safe_point_index != UINT8_MAX) { - destination = safe_point; - destination_type = DestinationType::DESTINATION_TYPE_SAFE_POINT; - } - - // If no rally points are closer (or none are defined), fall back to home (already set as the destination) + if (selection.safe_point_index != RTL_STATUS_NO_SAFE_POINT) { + selection.destination = safe_point; + selection.destination_type = DestinationType::DESTINATION_TYPE_SAFE_POINT; } - new_rtl_type = RtlType::RTL_DIRECT; - - } else { - // check the closest allowed destination. - findRtlDestination(destination_type, destination, safe_point_index); - - if (destination_type == DestinationType::DESTINATION_TYPE_MISSION_LAND) { - new_rtl_type = RtlType::RTL_DIRECT_MISSION_LAND; - - } else { - - new_rtl_type = RtlType::RTL_DIRECT; - } + // If no rally points are closer (or none are defined), fall back to home (already set as the destination) } +} + +rtl_time_estimate_s RTL::estimateTimeToHome() +{ + const PositionYawSetpoint home = homeDestination(); + loiter_point_s home_loiter; + home_loiter.lat = home.lat; + home_loiter.lon = home.lon; + home_loiter.height_m = NAN; + + _rtl_direct.setRtlAlt(computeReturnAltitude(home)); + _rtl_direct.setRtlPosition(home, home_loiter); + return _rtl_direct.calc_rtl_time_estimate(); +} + +void RTL::applyReturn(const ReturnSelection &selection) +{ + RtlType new_rtl_type = selection.executor; + const PositionYawSetpoint &destination = selection.destination; + const MissionRouteCache &mission_route_cache = _navigator->get_mission_route_cache(); const float rtl_alt = computeReturnAltitude(destination); @@ -346,6 +354,9 @@ void RTL::setRtlTypeAndDestination() _rtl_mission_type_handle->setRtlAlt(rtl_alt); } + // Only RtlDirect flies it + loiter_point_s landing_loiter{}; + if (new_rtl_type == RtlType::RTL_DIRECT) { #if defined(CONFIG_MODULES_VTOL_ATT_CONTROL) && CONFIG_MODULES_VTOL_ATT_CONTROL landing_loiter = selectLandingApproach(destination); @@ -360,7 +371,7 @@ void RTL::setRtlTypeAndDestination() _rtl_direct.setRtlAlt(rtl_alt); _rtl_direct.setRtlPosition(destination, landing_loiter, - destination_type == DestinationType::DESTINATION_TYPE_CURRENT_POSITION); + selection.destination_type == DestinationType::DESTINATION_TYPE_CURRENT_POSITION); _rtl_type = new_rtl_type; @@ -398,14 +409,14 @@ void RTL::setRtlTypeAndDestination() rtl_status.safe_points_id = mission_route_cache.safePointsId(); rtl_status.is_evaluation_pending = !mission_route_cache.safePointsReady() || mission_route_cache.missionLandItemUpdatePending(); - rtl_status.has_vtol_approach = _home_has_land_approach || _one_rally_point_has_land_approach; + rtl_status.has_vtol_approach = selection.home_has_land_approach || selection.rally_point_has_land_approach; rtl_status.rtl_type = static_cast(_rtl_type); - rtl_status.safe_point_index = safe_point_index; + rtl_status.safe_point_index = selection.safe_point_index; rtl_status.timestamp = hrt_absolute_time(); _rtl_status_pub.publish(rtl_status); } -// Keep out of setRtlTypeAndDestination(): inlined, the battery_status_s copy would stay +// Keep out of selectHomeIfReachable(): inlined, the battery_status_s copy would stay // on its stack while it selects the destination. float RTL::worstBatteryTimeRemaining() { @@ -430,7 +441,8 @@ float RTL::worstBatteryTimeRemaining() return worst_battery_time_s; } -PositionYawSetpoint RTL::findClosestSafePoint(float min_dist, uint8_t &safe_point_index) +PositionYawSetpoint RTL::findClosestSafePoint(float min_dist, bool skip_near_home, uint8_t &safe_point_index, + bool &has_land_approach) const { #if defined(CONFIG_MODULES_VTOL_ATT_CONTROL) && CONFIG_MODULES_VTOL_ATT_CONTROL const bool vtol_in_fw_mode = _vehicle_status_sub.get().is_vtol @@ -439,7 +451,7 @@ PositionYawSetpoint RTL::findClosestSafePoint(float min_dist, uint8_t &safe_poin const MissionRouteCache &mission_route_cache = _navigator->get_mission_route_cache(); PositionYawSetpoint closest_safe_point{static_cast(NAN), static_cast(NAN), NAN, NAN}; - _one_rally_point_has_land_approach = false; + has_land_approach = false; if (!mission_route_cache.safePointsReady()) { return closest_safe_point; @@ -475,8 +487,7 @@ PositionYawSetpoint RTL::findClosestSafePoint(float min_dist, uint8_t &safe_poin const bool far_from_home = get_distance_to_next_waypoint(_home_pos_sub.get().lat, _home_pos_sub.get().lon, candidate_setpoint.lat, candidate_setpoint.lon) > mission_route::kLandApproachAssociationDistanceM; - if (far_from_home || (_param_rtl_type.get() == RTL_TYPE_SAFE_POINT_DIRECT) - || (_param_rtl_type.get() == RTL_TYPE_HOME_OR_SAFE_POINT_DIRECT)) { + if (far_from_home || !skip_near_home) { const float dist{get_distance_to_next_waypoint(_global_pos_sub.get().lat, _global_pos_sub.get().lon, candidate_setpoint.lat, candidate_setpoint.lon)}; @@ -486,7 +497,7 @@ PositionYawSetpoint RTL::findClosestSafePoint(float min_dist, uint8_t &safe_poin _home_pos_sub.get().alt) }; - _one_rally_point_has_land_approach |= current_safe_point_has_approaches; + has_land_approach |= current_safe_point_has_approaches; const bool approach_requirement_satisfied = !vtol_in_fw_mode || (_param_rtl_appr_force.get() == 0) || current_safe_point_has_approaches; #else @@ -504,7 +515,7 @@ PositionYawSetpoint RTL::findClosestSafePoint(float min_dist, uint8_t &safe_poin return closest_safe_point; } -void RTL::findRtlDestination(DestinationType &destination_type, PositionYawSetpoint &destination, uint8_t &safe_point_index) +void RTL::selectClosest(int32_t rtl_type, ReturnSelection &selection) { const bool vtol_in_rw_mode = _vehicle_status_sub.get().is_vtol && (_vehicle_status_sub.get().vehicle_type == vehicle_status_s::VEHICLE_TYPE_ROTARY_WING); @@ -512,94 +523,109 @@ void RTL::findRtlDestination(DestinationType &destination_type, PositionYawSetpo const MissionRouteCache &mission_route_cache = _navigator->get_mission_route_cache(); float min_dist = FLT_MAX; - if (_param_rtl_type.get() != RTL_TYPE_SAFE_POINT_DIRECT) { #if defined(CONFIG_MODULES_VTOL_ATT_CONTROL) && CONFIG_MODULES_VTOL_ATT_CONTROL - const bool vtol_in_fw_mode = _vehicle_status_sub.get().is_vtol - && (_vehicle_status_sub.get().vehicle_type == vehicle_status_s::VEHICLE_TYPE_FIXED_WING); - _home_has_land_approach = mission_route::hasVtolLandApproachesNearLocation(mission_route_cache, destination, - _home_pos_sub.get().alt); + const bool vtol_in_fw_mode = _vehicle_status_sub.get().is_vtol + && (_vehicle_status_sub.get().vehicle_type == vehicle_status_s::VEHICLE_TYPE_FIXED_WING); + selection.home_has_land_approach = mission_route::hasVtolLandApproachesNearLocation(mission_route_cache, + selection.destination, + _home_pos_sub.get().alt); #endif - const bool prioritize_safe_points_over_home = ((_param_rtl_type.get() == 1) && !vtol_in_rw_mode); + const bool prioritize_safe_points_over_home = ((rtl_type == RTL_TYPE_MISSION_LAND_OR_SAFE_POINT) && !vtol_in_rw_mode); #if defined(CONFIG_MODULES_VTOL_ATT_CONTROL) && CONFIG_MODULES_VTOL_ATT_CONTROL - const bool required_approach_missing_for_home = (vtol_in_fw_mode && (_param_rtl_appr_force.get() == 1) && !_home_has_land_approach); + const bool required_approach_missing_for_home = (vtol_in_fw_mode && (_param_rtl_appr_force.get() == 1) + && !selection.home_has_land_approach); #else - constexpr bool required_approach_missing_for_home = false; + constexpr bool required_approach_missing_for_home = false; #endif - // Set minimum distance to maximum value when RTL_TYPE is set to 1 and we are not in RW mode or we force approach landing for vtol in fw and it is not defined for home. - const bool deprioritize_home = prioritize_safe_points_over_home || required_approach_missing_for_home; + // Set minimum distance to maximum value when RTL_TYPE is set to 1 and we are not in RW mode or we force approach landing for vtol in fw and it is not defined for home. + const bool deprioritize_home = prioritize_safe_points_over_home || required_approach_missing_for_home; - if (!deprioritize_home) { - // distance to home position - min_dist = get_distance_to_next_waypoint(_global_pos_sub.get().lat, _global_pos_sub.get().lon, destination.lat, destination.lon); - } + if (!deprioritize_home) { + // distance to home position + min_dist = get_distance_to_next_waypoint(_global_pos_sub.get().lat, _global_pos_sub.get().lon, selection.destination.lat, + selection.destination.lon); + } - // Mission landing - if (((_param_rtl_type.get() == 1) || (_param_rtl_type.get() == RTL_TYPE_DIRECT_WITH_MISSION_LAND) - || (fabsf(FLT_MAX - min_dist) < FLT_EPSILON)) && hasMissionLandStart()) { - mission_item_s land_mission_item; - int32_t land_index = -1; - const bool success = mission_route_cache.getMissionLandItem(land_index, land_mission_item); + // Mission landing + if (((rtl_type == RTL_TYPE_MISSION_LAND_OR_SAFE_POINT) || (rtl_type == RTL_TYPE_DIRECT_WITH_MISSION_LAND) + || (fabsf(FLT_MAX - min_dist) < FLT_EPSILON)) && hasMissionLandStart()) { + mission_item_s land_mission_item; + int32_t land_index = -1; + const bool success = mission_route_cache.getMissionLandItem(land_index, land_mission_item); - if (!success) { - const mission_s &mission = _mission_sub.get(); - const bool same_reported_source = _mission_land_failure_reported - && _mission_land_failure_mission_id == mission.mission_id - && _mission_land_failure_count == mission.count - && _mission_land_failure_index == mission.land_index - && _mission_land_failure_dataman_id == mission.mission_dataman_id; + if (!success) { + const mission_s &mission = _mission_sub.get(); + const bool same_reported_source = _mission_land_failure_reported + && _mission_land_failure_mission_id == mission.mission_id + && _mission_land_failure_count == mission.count + && _mission_land_failure_index == mission.land_index + && _mission_land_failure_dataman_id == mission.mission_dataman_id; - if (!same_reported_source) { - _mission_land_failure_reported = false; - } - - // A cache miss is expected while Navigator is asynchronously loading the item. - if ((!mission_route_cache.missionLandItemUpdatePending() - || mission_route_cache.missionLandItemAttemptFailed()) && !_mission_land_failure_reported) { - mavlink_log_critical(_navigator->get_mavlink_log_pub(), "Mission land item could not be read.\t"); - events::send(events::ID("rtl_failed_to_read_land_item"), events::Log::Error, - "Mission land item could not be read"); - _mission_land_failure_mission_id = mission.mission_id; - _mission_land_failure_count = mission.count; - _mission_land_failure_index = mission.land_index; - _mission_land_failure_dataman_id = mission.mission_dataman_id; - _mission_land_failure_reported = true; - } - - } else { + if (!same_reported_source) { _mission_land_failure_reported = false; - const float dist{get_distance_to_next_waypoint(_global_pos_sub.get().lat, _global_pos_sub.get().lon, land_mission_item.lat, land_mission_item.lon)}; + } - if ((dist + MIN_DIST_THRESHOLD) < min_dist) { - if (_param_rtl_type.get() != 0) { - min_dist = dist; + // A cache miss is expected while Navigator is asynchronously loading the item. + if ((!mission_route_cache.missionLandItemUpdatePending() + || mission_route_cache.missionLandItemAttemptFailed()) && !_mission_land_failure_reported) { + mavlink_log_critical(_navigator->get_mavlink_log_pub(), "Mission land item could not be read.\t"); + events::send(events::ID("rtl_failed_to_read_land_item"), events::Log::Error, + "Mission land item could not be read"); + _mission_land_failure_mission_id = mission.mission_id; + _mission_land_failure_count = mission.count; + _mission_land_failure_index = mission.land_index; + _mission_land_failure_dataman_id = mission.mission_dataman_id; + _mission_land_failure_reported = true; + } - } else { - // Mission landing is not allowed, but home has no approaches. Still use mission landing. - min_dist = FLT_MAX; - } + } else { + _mission_land_failure_reported = false; + const float dist{get_distance_to_next_waypoint(_global_pos_sub.get().lat, _global_pos_sub.get().lon, land_mission_item.lat, land_mission_item.lon)}; - setLandPosAsDestination(destination, land_mission_item); - destination_type = DestinationType::DESTINATION_TYPE_MISSION_LAND; + if ((dist + MIN_DIST_THRESHOLD) < min_dist) { + if (rtl_type != RTL_TYPE_CLOSEST_HOME_OR_SAFE_POINT) { + min_dist = dist; + + } else { + // Mission landing is not allowed, but home has no approaches. Still use mission landing. + min_dist = FLT_MAX; } + + setLandPosAsDestination(selection.destination, land_mission_item); + selection.destination_type = DestinationType::DESTINATION_TYPE_MISSION_LAND; + selection.executor = RtlType::RTL_DIRECT_MISSION_LAND; } } } // Safe/rally points - PositionYawSetpoint safe_point = findClosestSafePoint(min_dist, safe_point_index); + PositionYawSetpoint safe_point = findClosestSafePoint(min_dist, /*skip_near_home=*/true, + selection.safe_point_index, selection.rally_point_has_land_approach); - if (safe_point_index != RTL_STATUS_NO_SAFE_POINT) { - destination = safe_point; - destination_type = DestinationType::DESTINATION_TYPE_SAFE_POINT; + if (selection.safe_point_index != RTL_STATUS_NO_SAFE_POINT) { + selection.destination = safe_point; + selection.destination_type = DestinationType::DESTINATION_TYPE_SAFE_POINT; + selection.executor = RtlType::RTL_DIRECT; + } +} - } else if (_param_rtl_type.get() == RTL_TYPE_SAFE_POINT_DIRECT) { - // for RTL_TYPE=5: if no rally point is found fallback to current position - destination.alt = _global_pos_sub.get().alt; - destination.lat = _global_pos_sub.get().lat; - destination.lon = _global_pos_sub.get().lon; - destination_type = DestinationType::DESTINATION_TYPE_CURRENT_POSITION; +void RTL::selectSafePoint(ReturnSelection &selection) const +{ + const PositionYawSetpoint safe_point = findClosestSafePoint(FLT_MAX, /*skip_near_home=*/false, + selection.safe_point_index, selection.rally_point_has_land_approach); + + if (selection.safe_point_index != RTL_STATUS_NO_SAFE_POINT) { + selection.destination = safe_point; + selection.destination_type = DestinationType::DESTINATION_TYPE_SAFE_POINT; + + } else { + // if no rally point is found fallback to current position, which keeps Home's yaw + selection.destination.alt = _global_pos_sub.get().alt; + selection.destination.lat = _global_pos_sub.get().lat; + selection.destination.lon = _global_pos_sub.get().lon; + selection.destination_type = DestinationType::DESTINATION_TYPE_CURRENT_POSITION; } } diff --git a/src/modules/navigator/rtl.h b/src/modules/navigator/rtl.h index c776211b488..1c3a88ab058 100644 --- a/src/modules/navigator/rtl.h +++ b/src/modules/navigator/rtl.h @@ -116,8 +116,43 @@ private: */ bool reverseIsFurther() const; + /** rtl_status.safe_point_index if no rally point was chosen */ + static constexpr uint8_t RTL_STATUS_NO_SAFE_POINT{UINT8_MAX}; + static_assert(DM_KEY_SAFE_POINTS_MAX < RTL_STATUS_NO_SAFE_POINT, + "rtl_status.safe_point_index must represent every configured safe-point slot"); + + /** Where Return goes and which executor flies there. */ + struct ReturnSelection { + RtlType executor{RtlType::RTL_DIRECT}; + DestinationType destination_type{DestinationType::DESTINATION_TYPE_HOME}; + PositionYawSetpoint destination{}; + uint8_t safe_point_index{RTL_STATUS_NO_SAFE_POINT}; + bool home_has_land_approach{false}; ///< Home has a VTOL land approach, for the types that look + bool rally_point_has_land_approach{false}; ///< A rally point searched for this selection has one + }; + + /** Selects the destination of the current RTL_TYPE, then applies it. */ void setRtlTypeAndDestination(); + /** Starts at Home, then lets the policy of the current RTL_TYPE change the selection. */ + ReturnSelection selectReturn(); + /** RTL_TYPE 0, 1 and 3: the closest allowed of Home, the mission landing and the rally points. */ + void selectClosest(int32_t rtl_type, ReturnSelection &selection); + /** RTL_TYPE 2 and 4: follow the mission, or go to Home without a valid mission. */ + void selectMissionPath(int32_t rtl_type, ReturnSelection &selection) const; + /** RTL_TYPE 5: the closest rally point, or the current position. */ + void selectSafePoint(ReturnSelection &selection) const; + /** RTL_TYPE 6: Home if the battery reaches it, else the closest rally point. */ + void selectHomeIfReachable(ReturnSelection &selection); + + /** Creates and configures the executor, updates the avoidance planner and publishes rtl_status. */ + void applyReturn(const ReturnSelection &selection); + + PositionYawSetpoint homeDestination() const; + + /** Configures RtlDirect for Home to estimate it; applyReturn() then configures the selected destination. */ + rtl_time_estimate_s estimateTimeToHome(); + /** * @brief Publish the remaining time estimate to go to the Return landing point. * @@ -125,16 +160,13 @@ private: void publishRemainingTimeEstimate(); /** - * @brief Find return destination. + * @brief Find the closest rally point within min_dist * + * @param[in] skip_near_home ignore rally points within 10 m of Home + * @param[out] has_land_approach a rally point looked at has a VTOL land approach */ - void findRtlDestination(DestinationType &destination_type, PositionYawSetpoint &destination, uint8_t &safe_point_index); - - /** - * @brief Find return destination if only safe points are considered - * - */ - PositionYawSetpoint findClosestSafePoint(float min_dist, uint8_t &safe_point_index); + PositionYawSetpoint findClosestSafePoint(float min_dist, bool skip_near_home, uint8_t &safe_point_index, + bool &has_land_approach) const; /** * @brief Smallest remaining time [s] of the connected batteries, NAN if none reports one. @@ -188,9 +220,6 @@ private: uint8_t _mission_land_failure_dataman_id{DM_KEY_WAYPOINTS_OFFBOARD_0}; bool _mission_land_failure_reported{false}; - bool _home_has_land_approach{false}; ///< Flag if the home position has a land approach defined - bool _one_rally_point_has_land_approach{false}; ///< Flag if a rally point has a land approach defined - RtlDirect _rtl_direct; bool _enforce_rtl_alt{false}; diff --git a/src/modules/navigator/rtl_params.yaml b/src/modules/navigator/rtl_params.yaml index 222f97a90f2..c7b4bdce814 100644 --- a/src/modules/navigator/rtl_params.yaml +++ b/src/modules/navigator/rtl_params.yaml @@ -66,7 +66,7 @@ parameters: - 5 (Direct to rally point only): Return directly to safe landing point (do not consider mission landing and Home). - - 6 (Home if battery allows, else rally point): Return to home if time estimate to home is less than battery remaining estimate, else return to the closest rally point. If battery remaining estimate is not available, return to the closest safe point (home or rally point). + - 6 (Home if battery allows, else rally point): Return to home if time estimate to home is less than battery remaining estimate. Otherwise, or if battery remaining estimate is not available, return to the closest safe point (home or rally point). type: enum values: 0: Direct to home or rally point diff --git a/src/modules/navigator/test/test_RTL.cpp b/src/modules/navigator/test/test_RTL.cpp index df8a797763e..d1112452d29 100644 --- a/src/modules/navigator/test/test_RTL.cpp +++ b/src/modules/navigator/test/test_RTL.cpp @@ -386,7 +386,8 @@ protected: param_control_autosave(true); } - void loadSafePointsIntoRouteCache(const std::vector &items) + // Also loads the land item of a mission with a landing, which Return reads when it selects. + void loadSafePointsIntoRouteCache(const std::vector &items, mission_s mission = {}) { for (size_t i = 0; i < items.size(); ++i) { mission_item_s copy = items[i]; @@ -401,15 +402,15 @@ protected: ASSERT_TRUE(_dataman_client.writeSync(DM_KEY_SAFE_POINTS_STATE, 0, reinterpret_cast(&stats), sizeof(stats))); - mission_s mission{}; mission.timestamp = hrt_absolute_time(); mission.safe_points_id = ++_safe_points_id; mission.safepoint_dataman_id = DM_KEY_SAFE_POINTS_0; + const bool has_land_item = mission.land_index >= 0 && mission.land_index < mission.count; MissionRouteCache &mission_route_cache = _navigator.get_mission_route_cache(); ASSERT_TRUE(MissionRouteCacheTestPeer::runCacheUntil(mission_route_cache, mission, - [&] { return mission_route_cache.safePointsReady(); })) - << "test safe points did not load"; + [&] { return mission_route_cache.safePointsReady() && (!has_land_item || mission_route_cache.missionLandItemReady()); })) + << "the route cache did not load"; } void publishHomePosition(const PositionYawSetpoint &position, uint32_t update_count = 0) @@ -711,6 +712,268 @@ TEST_F(RTLTest, DirectMissionLandKeepsVtolInMulticopterMode) EXPECT_EQ(direct_mission_land.activeNavCommand(), NAV_CMD_DO_LAND_START); } +namespace +{ + +enum ReturnVehicle : uint8_t { kMulticopter, kVtolInHover, kVtolInFixedWing }; +enum ReturnGoal : uint8_t { kHome, kRallyPoint, kRallyPointApproach, kHere, kExecutorOnly }; + +constexpr uint8_t kDirect = rtl_status_s::RTL_STATUS_TYPE_DIRECT_SAFE_POINT; +constexpr uint8_t kMissionLand = rtl_status_s::RTL_STATUS_TYPE_DIRECT_MISSION_LAND; +constexpr uint8_t kFollow = rtl_status_s::RTL_STATUS_TYPE_FOLLOW_MISSION; +constexpr uint8_t kReverse = rtl_status_s::RTL_STATUS_TYPE_FOLLOW_MISSION_REVERSE; + +// Positions are meters north of the vehicle; NAN leaves the item out. +struct ReturnSelectionCase { + const char *test_name; + int32_t rtl_type; + ReturnVehicle vehicle; + float home_north_m; + float rally_north_m; + bool mission; + float land_north_m; + int32_t current_seq; + float battery_remaining_s; + int32_t approach_force; + uint8_t executor; + ReturnGoal goal; + bool rally_approach{true}; // only a VTOL in fixed-wing flight gets one +}; + +} // namespace + +class RTLSelectionTest : public RTLTest, public ::testing::WithParamInterface +{ +protected: + void TearDown() override + { + for (orb_advert_t &battery_pub : _battery_pubs) { + if (battery_pub != nullptr) { + orb_unadvertise(battery_pub); + battery_pub = nullptr; + } + } + + // the dataman is shared by every case in this binary + EXPECT_TRUE(_dataman_client.clearSync(DM_KEY_WAYPOINTS_OFFBOARD_0)); + RTLTest::TearDown(); + } + + orb_advert_t _battery_pubs[3] {}; +}; + +// WHY: each RTL_TYPE chooses between Home, rally points and the mission landing in its own way. +// WHAT: cases for each RTL_TYPE and for what tells types 0, 1 and 3 apart. Return starts 100 m above the +// scene, so its first setpoint is the destination. +TEST_P(RTLSelectionTest, ReturnTypeChoosesItsDestination) +{ + const ReturnSelectionCase &c = GetParam(); + const auto north = [](float north_m, float alt) { return makePositionYawSetpointFromOffset(kBaseLat, kBaseLon, north_m, 0.f, alt); }; + // Types 2 and 4 follow the mission; the others only read its landing, from the route cache. + const bool mission_path = c.rtl_type == 2 || c.rtl_type == 4; + + int32_t rtl_type = c.rtl_type; + int32_t approach_force = c.approach_force; + ASSERT_EQ(param_set(param_find("RTL_TYPE"), &rtl_type), PX4_OK); + ASSERT_EQ(param_set(param_find("RTL_APPR_FORCE"), &approach_force), PX4_OK); + _rtl.updateParamsForTest(); + + publishVehicleStatus(c.vehicle != kMulticopter, c.vehicle == kVtolInFixedWing ? + vehicle_status_s::VEHICLE_TYPE_FIXED_WING : vehicle_status_s::VEHICLE_TYPE_ROTARY_WING); + publishGlobalPosition(kBaseLat, kBaseLon, kAlt + 100.f); + publishLandDetected(false); + const PositionYawSetpoint home = north(c.home_north_m, kAlt); + publishHomePosition(home); + + // GIVEN: the mission, the rally point and the battery of the case + mission_s mission{}; + mission.land_start_index = -1; + mission.land_index = -1; + + if (c.mission) { + std::vector items; + + if (mission_path) { + for (float north_m : {100.f, 150.f, 200.f}) { + const PositionYawSetpoint waypoint = north(north_m, kAlt + 50.f); + items.push_back(makeSafePointItem(waypoint.lat, waypoint.lon, waypoint.alt, NAV_FRAME_GLOBAL, NAV_CMD_WAYPOINT)); + } + } + + if (PX4_ISFINITE(c.land_north_m)) { + const PositionYawSetpoint land = north(c.land_north_m, kAlt); + mission.land_start_index = static_cast(items.size()); + items.push_back(makeSafePointItem(0., 0., 0.f, NAV_FRAME_GLOBAL, NAV_CMD_DO_LAND_START)); + mission.land_index = static_cast(items.size()); + items.push_back(makeSafePointItem(land.lat, land.lon, kAlt, NAV_FRAME_GLOBAL, NAV_CMD_LAND)); + } + + for (mission_item_s &item : items) { + item.autocontinue = true; + } + + writeMissionToDataman(DM_KEY_WAYPOINTS_OFFBOARD_0, items); + mission.timestamp = hrt_absolute_time(); + mission.mission_id = 61; + mission.count = static_cast(items.size()); + mission.current_seq = c.current_seq; + mission.mission_dataman_id = DM_KEY_WAYPOINTS_OFFBOARD_0; + setMissionResultValid(mission); + } + + std::vector rally_points; + + if (PX4_ISFINITE(c.rally_north_m)) { + const PositionYawSetpoint rally_point = north(c.rally_north_m, kAlt); + rally_points.push_back(makeSafePointItem(rally_point.lat, rally_point.lon, kAlt, NAV_FRAME_GLOBAL)); + + if (c.vehicle == kVtolInFixedWing && c.rally_approach) { + // with RTL_APPR_FORCE, a VTOL in fixed-wing flight only takes a rally point with a landing approach + const PositionYawSetpoint approach = north(c.rally_north_m + 50.f, kAlt + 20.f); + rally_points.push_back(makeLandApproachItem(approach.lat, approach.lon, approach.alt, kApproachRadius)); + } + } + + // Loading a mission into the cache takes a while, and the mission path types do not need it there. + loadSafePointsIntoRouteCache(rally_points, mission_path ? mission_s{} : mission); + publishMission(mission); + + if (c.rtl_type == 6) { + // Type 6 judges Home by the battery that runs out first, here the middle one of three, + // so reading only the first or the last battery fails. + const float others_s = PX4_ISFINITE(c.battery_remaining_s) ? 3600.f : NAN; + const float time_remaining_s[3] {others_s, c.battery_remaining_s, others_s}; + + for (int i = 0; i < 3; ++i) { + battery_status_s battery{}; + battery.timestamp = hrt_absolute_time(); + battery.connected = true; + battery.time_remaining_s = time_remaining_s[i]; + int instance = 0; + _battery_pubs[i] = orb_advertise_multi(ORB_ID(battery_status), &battery, &instance); + } + } + + // WHEN: Return is inactive for a cycle, then activates + uORB::SubscriptionData rtl_status_sub{ORB_ID(rtl_status)}; + _rtl.run(false); + _rtl.run(true); + + // THEN: it reports its executor and rally point, and a direct Return flies to the destination first + ASSERT_TRUE(rtl_status_sub.update()); + EXPECT_EQ(rtl_status_sub.get().rtl_type, c.executor); + EXPECT_EQ(rtl_status_sub.get().safe_point_index, (c.goal == kRallyPoint || c.goal == kRallyPointApproach) ? 0 : UINT8_MAX); + + if (c.goal != kExecutorOnly) { + const float expected_north_m = c.goal == kHome ? c.home_north_m : c.goal == kRallyPoint ? c.rally_north_m + : c.goal == kRallyPointApproach ? c.rally_north_m + 50.f : 0.f; + const PositionYawSetpoint expected = north(expected_north_m, kAlt); + const position_setpoint_s ¤t = _navigator.get_position_setpoint_triplet()->current; + ASSERT_TRUE(current.valid); + EXPECT_NEAR(current.lat, expected.lat, 1e-7); + EXPECT_NEAR(current.lon, expected.lon, 1e-7); + } +} + +INSTANTIATE_TEST_SUITE_P( + RTL, + RTLSelectionTest, + ::testing::Values( + // name, RTL_TYPE, vehicle, Home, rally point, mission, its landing, its current item, battery s, RTL_APPR_FORCE, executor, goal[, rally point approach] + ReturnSelectionCase{"Type0IgnoresCloserMissionLanding", 0, kMulticopter, -100.f, 300.f, true, 50.f, 0, NAN, 0, kDirect, kHome}, + ReturnSelectionCase{"Type0ClosestIsRallyPoint", 0, kMulticopter, -300.f, 100.f, false, NAN, 0, NAN, 0, kDirect, kRallyPoint}, + ReturnSelectionCase{"Type0IgnoresRallyPointNearHome", 0, kMulticopter, -300.f, -291.f, false, NAN, 0, NAN, 0, kDirect, kHome}, + ReturnSelectionCase{"Type0VtolWithoutHomeApproachUsesMissionLanding", 0, kVtolInFixedWing, -100.f, NAN, true, 300.f, 0, NAN, 1, kMissionLand, kExecutorOnly}, + ReturnSelectionCase{"Type0VtolWithHomeApproachIgnoresMissionLanding", 0, kVtolInFixedWing, -100.f, -100.f, true, 50.f, 0, NAN, 1, kDirect, kExecutorOnly}, + ReturnSelectionCase{"Type0VtolPrefersRallyPointToLastResortLanding", 0, kVtolInFixedWing, -100.f, 300.f, true, 100.f, 0, NAN, 1, kDirect, kRallyPointApproach}, + ReturnSelectionCase{"Type0VtolSkipsRallyPointWithoutApproach", 0, kVtolInFixedWing, -100.f, 300.f, true, 100.f, 0, NAN, 1, kMissionLand, kExecutorOnly, false}, + ReturnSelectionCase{"Type1PrefersRallyPoint", 1, kMulticopter, -100.f, 300.f, false, NAN, 0, NAN, 0, kDirect, kRallyPoint}, + ReturnSelectionCase{"Type1PrefersMissionLandingToCloserHome", 1, kMulticopter, -100.f, 300.f, true, 200.f, 0, NAN, 0, kMissionLand, kExecutorOnly}, + ReturnSelectionCase{"Type1VtolInHoverTakesCloserHome", 1, kVtolInHover, -100.f, 300.f, false, NAN, 0, NAN, 0, kDirect, kHome}, + ReturnSelectionCase{"Type2FollowsMissionToItsLanding", 2, kMulticopter, -100.f, NAN, true, 300.f, 0, NAN, 0, kFollow, kExecutorOnly}, + ReturnSelectionCase{"Type2ReversesMissionWithoutLanding", 2, kMulticopter, -100.f, NAN, true, NAN, 0, NAN, 0, kReverse, kExecutorOnly}, + ReturnSelectionCase{"Type2WithoutMissionGoesHome", 2, kMulticopter, -100.f, NAN, false, NAN, 0, NAN, 0, kDirect, kHome}, + ReturnSelectionCase{"Type3ClosestIsMissionLanding", 3, kMulticopter, -200.f, 300.f, true, 100.f, 0, NAN, 0, kMissionLand, kExecutorOnly}, + ReturnSelectionCase{"Type3TakesCloserHome", 3, kMulticopter, -100.f, 300.f, true, 200.f, 0, NAN, 0, kDirect, kHome}, + ReturnSelectionCase{"Type4FollowsShorterWayToLanding", 4, kMulticopter, -100.f, NAN, true, 300.f, 2, NAN, 0, kFollow, kExecutorOnly}, + ReturnSelectionCase{"Type4ReversesShorterWayToStart", 4, kMulticopter, -100.f, NAN, true, 300.f, 1, NAN, 0, kReverse, kExecutorOnly}, + ReturnSelectionCase{"Type5IgnoresCloserHome", 5, kMulticopter, -100.f, 300.f, false, NAN, 0, NAN, 0, kDirect, kRallyPoint}, + ReturnSelectionCase{"Type5KeepsRallyPointNearHome", 5, kMulticopter, -300.f, -291.f, false, NAN, 0, NAN, 0, kDirect, kRallyPoint}, + ReturnSelectionCase{"Type5WithoutRallyPointStaysHere", 5, kMulticopter, -100.f, NAN, false, NAN, 0, NAN, 0, kDirect, kHere}, + ReturnSelectionCase{"Type6GoesHomeWithinBattery", 6, kMulticopter, -300.f, 100.f, false, NAN, 0, 3600.f, 0, kDirect, kHome}, + ReturnSelectionCase{"Type6TakesRallyPointBeyondBattery", 6, kMulticopter, -300.f, -291.f, false, NAN, 0, 1.f, 0, kDirect, kRallyPoint}, + ReturnSelectionCase{"Type6WithoutRallyPointGoesHomeBeyondBattery", 6, kMulticopter, -100.f, NAN, false, NAN, 0, 1.f, 0, kDirect, kHome}, + ReturnSelectionCase{"Type6WithoutBatteryEstimateTakesClosest", 6, kMulticopter, -300.f, 100.f, false, NAN, 0, NAN, 0, kDirect, kRallyPoint}, + ReturnSelectionCase{"Type6WithoutBatteryEstimateGoesHomeWhenCloser", 6, kMulticopter, -100.f, 300.f, false, NAN, 0, NAN, 0, kDirect, kHome}), + [](const ::testing::TestParamInfo ¶m_info) +{ + return std::string(param_info.param.test_name); +}); + +#if defined(CONFIG_MODULES_VTOL_ATT_CONTROL) && CONFIG_MODULES_VTOL_ATT_CONTROL +// WHY: the mission check reads rtl_status.has_vtol_approach for the Return type in use. It is set when Home +// or any rally point the type checks has an approach, not only the destination. +// WHAT: RTL_TYPE 6 going Home reports Home's approach, with no rally point searched. +TEST_F(RTLTest, Type6ReportsTheApproachAtHome) +{ + const ApproachGeometry geometry = makeApproachGeometry(); + publishVehicleStatus(true, vehicle_status_s::VEHICLE_TYPE_FIXED_WING); + publishGlobalPosition(kBaseLat, kBaseLon, kAlt + 100.f); + publishLandDetected(false); + publishHomePosition(geometry.land); + loadSafePointsIntoRouteCache({ + makeSafePointItem(geometry.land.lat, geometry.land.lon, geometry.land.alt, NAV_FRAME_GLOBAL), + makeLandApproachItem(geometry.north.lat, geometry.north.lon, geometry.north.alt, kApproachRadius), + }); + battery_status_s battery{}; + battery.timestamp = hrt_absolute_time(); + battery.connected = true; + battery.time_remaining_s = 3600.f; + orb_advert_t battery_pub = orb_advertise(ORB_ID(battery_status), &battery); + uORB::SubscriptionData rtl_status_sub{ORB_ID(rtl_status)}; + + _rtl.evaluateReturnTypeForTest(6); + + EXPECT_TRUE(rtl_status_sub.update()); + EXPECT_EQ(rtl_status_sub.get().safe_point_index, UINT8_MAX); + EXPECT_TRUE(rtl_status_sub.get().has_vtol_approach); + orb_unadvertise(battery_pub); +} + +// WHY: the mission check reads rtl_status.has_vtol_approach for the Return type in use. +// WHAT: RTL_TYPE 5, and 6 beyond the battery, report the approach of a rally point they check. +TEST_F(RTLTest, Types5And6ReportTheApproachAtTheRallyPoint) +{ + const ApproachGeometry geometry = makeApproachGeometry(); + publishVehicleStatus(true, vehicle_status_s::VEHICLE_TYPE_FIXED_WING); + publishGlobalPosition(kBaseLat, kBaseLon, kAlt + 100.f); + publishLandDetected(false); + // Home farther than the rally point, which return.md requires for type 6 to take it + publishHomePosition(makePositionYawSetpointFromOffset(kBaseLat, kBaseLon, -300.f, 0.f, kAlt)); + loadSafePointsIntoRouteCache({ + makeSafePointItem(geometry.land.lat, geometry.land.lon, geometry.land.alt, NAV_FRAME_GLOBAL), + makeLandApproachItem(geometry.north.lat, geometry.north.lon, geometry.north.alt, kApproachRadius), + }); + battery_status_s battery{}; + battery.timestamp = hrt_absolute_time(); + battery.connected = true; + battery.time_remaining_s = 1.f; + orb_advert_t battery_pub = orb_advertise(ORB_ID(battery_status), &battery); + uORB::SubscriptionData rtl_status_sub{ORB_ID(rtl_status)}; + + for (const int32_t rtl_type : {5, 6}) { + SCOPED_TRACE(::testing::Message() << "RTL_TYPE=" << rtl_type); + _rtl.evaluateReturnTypeForTest(rtl_type); + + EXPECT_TRUE(rtl_status_sub.update()); + EXPECT_EQ(rtl_status_sub.get().safe_point_index, 0); + EXPECT_TRUE(rtl_status_sub.get().has_vtol_approach); + } + + orb_unadvertise(battery_pub); +} +#endif + class RTLClimbUpdateTest : public RTLTest, public ::testing::WithParamInterface> {}; TEST_P(RTLClimbUpdateTest, KeepsPendingClimbAcrossCursorUpdates) @@ -3115,3 +3378,49 @@ TEST_F(RTLTest, RallyPointReturnWithoutRallyPointEstimatesNoFixedWingLanding) ASSERT_TRUE(no_delay.valid && hold.valid); EXPECT_FLOAT_EQ(no_delay.time_estimate, hold.time_estimate); } + +// WHY: Return compares destinations only by straight-line distance, +// so it has no reason to prefer a rally point that is farther away than Home. +// WHAT: RTL_TYPE 6 keeps Home while the battery reaches it. When the battery does not reach Home, +// it takes a rally point only if it is closer than Home. +TEST_F(RTLTest, Type6BeyondBatteryTakesOnlyCloserRallyPoint) +{ + // GIVEN: Home 300 m away + publishVehicleStatus(false, vehicle_status_s::VEHICLE_TYPE_ROTARY_WING); + publishGlobalPosition(kBaseLat, kBaseLon, kAlt + 100.f); + publishLandDetected(false); + publishHomePosition(makePositionYawSetpointFromOffset(kBaseLat, kBaseLon, -300.f, 0.f, kAlt)); + battery_status_s battery{}; + battery.timestamp = hrt_absolute_time(); + battery.connected = true; + orb_advert_t battery_pub = orb_advertise(ORB_ID(battery_status), &battery); + uORB::SubscriptionData rtl_status_sub{ORB_ID(rtl_status)}; + + const struct { + float battery_remaining_s; + float rally_north_m; + bool takes_rally_point; + } cases[] { + {3600.f, 200.f, false}, // the battery reaches Home + {1.f, 400.f, false}, + {1.f, 200.f, true}, + }; + + for (const auto &c : cases) { + SCOPED_TRACE(::testing::Message() << "battery " << c.battery_remaining_s << " s, rally point " << c.rally_north_m << " m away"); + battery.timestamp = hrt_absolute_time(); + battery.time_remaining_s = c.battery_remaining_s; + orb_publish(ORB_ID(battery_status), battery_pub, &battery); + const PositionYawSetpoint rally_point = makePositionYawSetpointFromOffset(kBaseLat, kBaseLon, c.rally_north_m, 0.f, kAlt); + loadSafePointsIntoRouteCache({makeSafePointItem(rally_point.lat, rally_point.lon, kAlt, NAV_FRAME_GLOBAL)}); + + // WHEN: Return evaluates type 6 + _rtl.evaluateReturnTypeForTest(6); + + // THEN: it keeps Home unless the battery does not reach Home and the rally point is closer + EXPECT_TRUE(rtl_status_sub.update()); + EXPECT_EQ(rtl_status_sub.get().safe_point_index, c.takes_rally_point ? 0 : UINT8_MAX); + } + + orb_unadvertise(battery_pub); +} diff --git a/src/modules/navigator/vtol_takeoff.cpp b/src/modules/navigator/vtol_takeoff.cpp index 76dc4c8b3d4..b7ababbda08 100644 --- a/src/modules/navigator/vtol_takeoff.cpp +++ b/src/modules/navigator/vtol_takeoff.cpp @@ -132,7 +132,7 @@ VtolTakeoff::on_active() _mission_item.time_inside = 1.f; _mission_item.loiter_radius = _navigator->get_default_loiter_rad(); _mission_item.acceptance_radius = _navigator->get_acceptance_radius(); - _mission_item.altitude = _takeoff_alt_msl + _param_loiter_alt.get(); + _mission_item.altitude = _takeoff_alt_msl + _param_vto_loiter_alt.get(); mission_item_to_position_setpoint(_mission_item, &pos_sp_triplet->current); pos_sp_triplet->current.lat = _loiter_location(0); diff --git a/src/modules/navigator/vtol_takeoff.h b/src/modules/navigator/vtol_takeoff.h index 162209893d2..8e19070a814 100644 --- a/src/modules/navigator/vtol_takeoff.h +++ b/src/modules/navigator/vtol_takeoff.h @@ -77,7 +77,7 @@ private: float _transition_direction_deg{NAN}; DEFINE_PARAMETERS( - (ParamFloat) _param_loiter_alt + (ParamFloat) _param_vto_loiter_alt ) void set_takeoff_position(); diff --git a/src/modules/payload_deliverer/payload_deliverer.cpp b/src/modules/payload_deliverer/payload_deliverer.cpp index 08e99962098..bba0f7b7a4e 100644 --- a/src/modules/payload_deliverer/payload_deliverer.cpp +++ b/src/modules/payload_deliverer/payload_deliverer.cpp @@ -59,9 +59,9 @@ void PayloadDeliverer::configure_gripper() // If gripper instance is invalid, and user enabled the gripper, try initializing it if (!_gripper.is_valid()) { GripperConfig config{}; - config.type = (GripperConfig::GripperType)_param_gripper_type.get(); + config.type = (GripperConfig::GripperType)_param_pd_gripper_type.get(); config.sensor = GripperConfig::GripperSensorType::NONE; // Feedback sensor isn't supported for now - config.timeout_us = hrt_abstime(_param_gripper_timeout_s.get() * 1000000ULL); + config.timeout_us = hrt_abstime(_param_pd_gripper_to.get() * 1000000ULL); _gripper.init(config); if (!_gripper.is_valid()) { diff --git a/src/modules/payload_deliverer/payload_deliverer.h b/src/modules/payload_deliverer/payload_deliverer.h index 8c61a0a0b0a..aa1eb08227d 100644 --- a/src/modules/payload_deliverer/payload_deliverer.h +++ b/src/modules/payload_deliverer/payload_deliverer.h @@ -160,7 +160,7 @@ private: uORB::Publication _vehicle_command_pub{ORB_ID(vehicle_command)}; DEFINE_PARAMETERS( - (ParamFloat) _param_gripper_timeout_s, - (ParamInt) _param_gripper_type + (ParamFloat) _param_pd_gripper_to, + (ParamInt) _param_pd_gripper_type ) }; diff --git a/src/modules/px4iofirmware/CMakeLists.txt b/src/modules/px4iofirmware/CMakeLists.txt index 970a960e242..dde085f9c32 100644 --- a/src/modules/px4iofirmware/CMakeLists.txt +++ b/src/modules/px4iofirmware/CMakeLists.txt @@ -53,6 +53,7 @@ target_link_libraries(px4iofirmware nuttx_arch nuttx_c nuttx_mm + px4io_protocol rc ) diff --git a/src/modules/px4iofirmware/px4io.h b/src/modules/px4iofirmware/px4io.h index 99cba83e677..4c0219f213d 100644 --- a/src/modules/px4iofirmware/px4io.h +++ b/src/modules/px4iofirmware/px4io.h @@ -48,7 +48,7 @@ #include -#include "protocol.h" +#include __BEGIN_DECLS diff --git a/src/modules/px4iofirmware/registers.c b/src/modules/px4iofirmware/registers.c index 0791345a545..1211298d112 100644 --- a/src/modules/px4iofirmware/registers.c +++ b/src/modules/px4iofirmware/registers.c @@ -52,7 +52,7 @@ #include #include "px4io.h" -#include "protocol.h" +#include static int registers_set_one(uint8_t page, uint8_t offset, uint16_t value); static void pwm_configure_rates(uint16_t map, uint16_t defaultrate, uint16_t altrate); diff --git a/src/modules/replay/ReplayEkf2.cpp b/src/modules/replay/ReplayEkf2.cpp index 33cbe8817a0..c8493cfda20 100644 --- a/src/modules/replay/ReplayEkf2.cpp +++ b/src/modules/replay/ReplayEkf2.cpp @@ -235,7 +235,7 @@ ReplayEkf2::publishEkf2Topics(const ekf2_timestamps_s &ekf2_timestamps, std::ifs handle_sensor_publication(ekf2_timestamps.airspeed_timestamp_rel, _airspeed_msg_id); handle_sensor_publication(ekf2_timestamps.airspeed_validated_timestamp_rel, _airspeed_validated_msg_id); handle_multi_sensor_publication(ekf2_timestamps.distance_sensor_timestamp_rel, _distance_sensor_msg_ids); - handle_multi_sensor_publication(ekf2_timestamps.optical_flow_timestamp_rel, _optical_flow_msg_ids); + handle_multi_sensor_publication(0, _optical_flow_msg_ids); handle_sensor_publication(ekf2_timestamps.vehicle_air_data_timestamp_rel, _vehicle_air_data_msg_id); handle_sensor_publication(ekf2_timestamps.vehicle_magnetometer_timestamp_rel, _vehicle_magnetometer_msg_id); handle_sensor_publication(ekf2_timestamps.visual_odometry_timestamp_rel, _vehicle_visual_odometry_msg_id); diff --git a/src/modules/rover_ackermann/AckermannActControl/AckermannActControl.cpp b/src/modules/rover_ackermann/AckermannActControl/AckermannActControl.cpp index 6cccb99840a..3eb9b4b79c6 100644 --- a/src/modules/rover_ackermann/AckermannActControl/AckermannActControl.cpp +++ b/src/modules/rover_ackermann/AckermannActControl/AckermannActControl.cpp @@ -48,12 +48,12 @@ void AckermannActControl::updateParams() { ModuleParams::updateParams(); - if (_param_ra_str_rate_limit.get() > FLT_EPSILON && _param_ra_max_str_ang.get() > FLT_EPSILON) { - _servo_setpoint.setSlewRate((M_DEG_TO_RAD_F * _param_ra_str_rate_limit.get()) / _param_ra_max_str_ang.get()); + if (_param_ra_str_rate_lim.get() > FLT_EPSILON && _param_ra_max_str_ang.get() > FLT_EPSILON) { + _servo_setpoint.setSlewRate((M_DEG_TO_RAD_F * _param_ra_str_rate_lim.get()) / _param_ra_max_str_ang.get()); } - if (_param_ro_accel_limit.get() > FLT_EPSILON && _param_ro_max_thr_speed.get() > FLT_EPSILON) { - _motor_setpoint.setSlewRate(_param_ro_accel_limit.get() / _param_ro_max_thr_speed.get()); + if (_param_ro_accel_lim.get() > FLT_EPSILON && _param_ro_max_thr_speed.get() > FLT_EPSILON) { + _motor_setpoint.setSlewRate(_param_ro_accel_lim.get() / _param_ro_max_thr_speed.get()); } } @@ -74,10 +74,10 @@ void AckermannActControl::updateActControl() actuator_motors_s actuator_motors_sub{}; _actuator_motors_sub.copy(&actuator_motors_sub); actuator_motors_s actuator_motors{}; - actuator_motors.reversible_flags = _param_r_rev.get(); + actuator_motors.reversible_flags = _param_ca_r_rev.get(); actuator_motors.control[0] = RoverControl::throttleControl(_motor_setpoint, - _throttle_setpoint, actuator_motors_sub.control[0], _param_ro_accel_limit.get(), - _param_ro_decel_limit.get(), _param_ro_max_thr_speed.get(), dt); + _throttle_setpoint, actuator_motors_sub.control[0], _param_ro_accel_lim.get(), + _param_ro_decel_lim.get(), _param_ro_max_thr_speed.get(), dt); actuator_motors.timestamp = _timestamp; _actuator_motors_pub.publish(actuator_motors); @@ -94,7 +94,7 @@ void AckermannActControl::updateActControl() actuator_servos_s actuator_servos_sub{}; _actuator_servos_sub.copy(&actuator_servos_sub); - if (_param_ra_str_rate_limit.get() > FLT_EPSILON + if (_param_ra_str_rate_lim.get() > FLT_EPSILON && _param_ra_max_str_ang.get() > FLT_EPSILON) { // Apply slew rate if configured if (fabsf(_servo_setpoint.getState() - actuator_servos_sub.control[0]) > fabsf( _steering_setpoint - @@ -119,7 +119,7 @@ void AckermannActControl::stopVehicle() { _timestamp = hrt_absolute_time(); actuator_motors_s actuator_motors{}; - actuator_motors.reversible_flags = _param_r_rev.get(); + actuator_motors.reversible_flags = _param_ca_r_rev.get(); actuator_motors.control[0] = 0.f; actuator_motors.timestamp = _timestamp; _actuator_motors_pub.publish(actuator_motors); diff --git a/src/modules/rover_ackermann/AckermannActControl/AckermannActControl.hpp b/src/modules/rover_ackermann/AckermannActControl/AckermannActControl.hpp index bace583cfee..993ce8aeb03 100644 --- a/src/modules/rover_ackermann/AckermannActControl/AckermannActControl.hpp +++ b/src/modules/rover_ackermann/AckermannActControl/AckermannActControl.hpp @@ -105,11 +105,11 @@ private: // Parameters DEFINE_PARAMETERS( - (ParamInt) _param_r_rev, - (ParamFloat) _param_ra_str_rate_limit, + (ParamInt) _param_ca_r_rev, + (ParamFloat) _param_ra_str_rate_lim, (ParamFloat) _param_ra_max_str_ang, - (ParamFloat) _param_ro_accel_limit, - (ParamFloat) _param_ro_decel_limit, + (ParamFloat) _param_ro_accel_lim, + (ParamFloat) _param_ro_decel_lim, (ParamFloat) _param_ro_max_thr_speed ) }; diff --git a/src/modules/rover_ackermann/AckermannAttControl/AckermannAttControl.cpp b/src/modules/rover_ackermann/AckermannAttControl/AckermannAttControl.cpp index 7299ed82319..eb4124de45c 100644 --- a/src/modules/rover_ackermann/AckermannAttControl/AckermannAttControl.cpp +++ b/src/modules/rover_ackermann/AckermannAttControl/AckermannAttControl.cpp @@ -48,8 +48,8 @@ void AckermannAttControl::updateParams() { ModuleParams::updateParams(); - if (_param_ro_yaw_rate_limit.get() > FLT_EPSILON) { - _max_yaw_rate = _param_ro_yaw_rate_limit.get() * M_DEG_TO_RAD_F; + if (_param_ro_yaw_rate_lim.get() > FLT_EPSILON) { + _max_yaw_rate = _param_ro_yaw_rate_lim.get() * M_DEG_TO_RAD_F; } // Set up PID controller @@ -135,7 +135,7 @@ bool AckermannAttControl::runSanityChecks() ret = false; } - if (_param_ro_yaw_rate_limit.get() < FLT_EPSILON) { + if (_param_ro_yaw_rate_lim.get() < FLT_EPSILON) { ret = false; } diff --git a/src/modules/rover_ackermann/AckermannAttControl/AckermannAttControl.hpp b/src/modules/rover_ackermann/AckermannAttControl/AckermannAttControl.hpp index 24667054310..b934b3861cb 100644 --- a/src/modules/rover_ackermann/AckermannAttControl/AckermannAttControl.hpp +++ b/src/modules/rover_ackermann/AckermannAttControl/AckermannAttControl.hpp @@ -123,7 +123,7 @@ private: (ParamFloat) _param_ro_max_thr_speed, (ParamFloat) _param_ra_wheel_base, (ParamFloat) _param_ra_max_str_ang, - (ParamFloat) _param_ro_yaw_rate_limit, + (ParamFloat) _param_ro_yaw_rate_lim, (ParamFloat) _param_ro_yaw_p, (ParamFloat) _param_ro_yaw_stick_dz ) diff --git a/src/modules/rover_ackermann/AckermannDriveModes/AckermannAutoMode/AckermannAutoMode.cpp b/src/modules/rover_ackermann/AckermannDriveModes/AckermannAutoMode/AckermannAutoMode.cpp index d02d7489461..c743f8dffbb 100644 --- a/src/modules/rover_ackermann/AckermannDriveModes/AckermannAutoMode/AckermannAutoMode.cpp +++ b/src/modules/rover_ackermann/AckermannDriveModes/AckermannAutoMode/AckermannAutoMode.cpp @@ -45,7 +45,7 @@ AckermannAutoMode::AckermannAutoMode(ModuleParams *parent) : ModuleParams(parent void AckermannAutoMode::updateParams() { ModuleParams::updateParams(); - _max_yaw_rate = _param_ro_yaw_rate_limit.get() * M_DEG_TO_RAD_F; + _max_yaw_rate = _param_ro_yaw_rate_lim.get() * M_DEG_TO_RAD_F; if (_param_ra_wheel_base.get() > FLT_EPSILON && _max_yaw_rate > FLT_EPSILON && _param_ra_max_str_ang.get() > FLT_EPSILON) { @@ -108,7 +108,7 @@ void AckermannAutoMode::updateWaypointsAndAcceptanceRadius() // Waypoint cruising speed _cruising_speed = position_setpoint_triplet.current.cruising_speed > 0.f ? math::constrain( - position_setpoint_triplet.current.cruising_speed, 0.f, _param_ro_speed_limit.get()) : _param_ro_speed_limit.get(); + position_setpoint_triplet.current.cruising_speed, 0.f, _param_ro_speed_lim.get()) : _param_ro_speed_lim.get(); } float AckermannAutoMode::updateAcceptanceRadius(const float waypoint_transition_angle, @@ -181,7 +181,7 @@ void AckermannAutoMode::guidedCourse() surface_vehicle_course_setpoint.timestamp = hrt_absolute_time(); // The navigator publishes the course in [0, 2pi) surface_vehicle_course_setpoint.course = matrix::wrap_pi(current.course); - surface_vehicle_course_setpoint.speed = math::min(_course_speed, _param_ro_speed_limit.get()); + surface_vehicle_course_setpoint.speed = math::min(_course_speed, _param_ro_speed_lim.get()); surface_vehicle_course_setpoint.yaw = NAN; _surface_vehicle_course_setpoint_pub.publish(surface_vehicle_course_setpoint); } diff --git a/src/modules/rover_ackermann/AckermannDriveModes/AckermannAutoMode/AckermannAutoMode.hpp b/src/modules/rover_ackermann/AckermannDriveModes/AckermannAutoMode/AckermannAutoMode.hpp index fed8208807a..0aa1acc5236 100644 --- a/src/modules/rover_ackermann/AckermannDriveModes/AckermannAutoMode/AckermannAutoMode.hpp +++ b/src/modules/rover_ackermann/AckermannDriveModes/AckermannAutoMode/AckermannAutoMode.hpp @@ -148,8 +148,8 @@ private: float _course_speed{NAN}; // Guided Course speed [m/s], NAN until latched from the forward speed on the first course setpoint DEFINE_PARAMETERS( - (ParamFloat) _param_ro_yaw_rate_limit, - (ParamFloat) _param_ro_speed_limit, + (ParamFloat) _param_ro_yaw_rate_lim, + (ParamFloat) _param_ro_speed_lim, (ParamFloat) _param_ra_wheel_base, (ParamFloat) _param_ra_max_str_ang, (ParamFloat) _param_nav_acc_rad, diff --git a/src/modules/rover_ackermann/AckermannDriveModes/AckermannManualMode/AckermannManualMode.cpp b/src/modules/rover_ackermann/AckermannDriveModes/AckermannManualMode/AckermannManualMode.cpp index 9eb741bf523..97c1f713e48 100644 --- a/src/modules/rover_ackermann/AckermannDriveModes/AckermannManualMode/AckermannManualMode.cpp +++ b/src/modules/rover_ackermann/AckermannDriveModes/AckermannManualMode/AckermannManualMode.cpp @@ -49,7 +49,7 @@ AckermannManualMode::AckermannManualMode(ModuleParams *parent) : ModuleParams(pa void AckermannManualMode::updateParams() { ModuleParams::updateParams(); - _max_yaw_rate = _param_ro_yaw_rate_limit.get() * M_DEG_TO_RAD_F; + _max_yaw_rate = _param_ro_yaw_rate_lim.get() * M_DEG_TO_RAD_F; } void AckermannManualMode::manual() @@ -184,7 +184,7 @@ void AckermannManualMode::position() _param_ro_stick_map.get()); const float speed_setpoint = math::interpolate(sticks.forward, - -1.f, 1.f, -_param_ro_speed_limit.get(), _param_ro_speed_limit.get()); + -1.f, 1.f, -_param_ro_speed_lim.get(), _param_ro_speed_lim.get()); if (fabsf(sticks.yaw) > FLT_EPSILON || fabsf(speed_setpoint) < FLT_EPSILON) { diff --git a/src/modules/rover_ackermann/AckermannDriveModes/AckermannManualMode/AckermannManualMode.hpp b/src/modules/rover_ackermann/AckermannDriveModes/AckermannManualMode/AckermannManualMode.hpp index 1858e67f18a..f48154eae94 100644 --- a/src/modules/rover_ackermann/AckermannDriveModes/AckermannManualMode/AckermannManualMode.hpp +++ b/src/modules/rover_ackermann/AckermannDriveModes/AckermannManualMode/AckermannManualMode.hpp @@ -129,13 +129,13 @@ private: float _max_yaw_rate{NAN}; DEFINE_PARAMETERS( - (ParamFloat) _param_ro_yaw_rate_limit, + (ParamFloat) _param_ro_yaw_rate_lim, (ParamFloat) _param_ro_yaw_p, (ParamFloat) _param_ro_yaw_stick_dz, (ParamFloat) _param_ro_yaw_expo, (ParamFloat) _param_ro_yaw_supexpo, (ParamFloat) _param_ro_park_thr_max, - (ParamFloat) _param_ro_speed_limit, + (ParamFloat) _param_ro_speed_lim, (ParamFloat) _param_pp_lookahd_max, (ParamInt) _param_ro_stick_map ) diff --git a/src/modules/rover_ackermann/AckermannPosControl/AckermannPosControl.cpp b/src/modules/rover_ackermann/AckermannPosControl/AckermannPosControl.cpp index 086551882e1..22401969489 100644 --- a/src/modules/rover_ackermann/AckermannPosControl/AckermannPosControl.cpp +++ b/src/modules/rover_ackermann/AckermannPosControl/AckermannPosControl.cpp @@ -49,7 +49,7 @@ AckermannPosControl::AckermannPosControl(ModuleParams *parent) : void AckermannPosControl::updateParams() { ModuleParams::updateParams(); - _max_yaw_rate = _param_ro_yaw_rate_limit.get() * M_DEG_TO_RAD_F; + _max_yaw_rate = _param_ro_yaw_rate_lim.get() * M_DEG_TO_RAD_F; _min_speed = _param_ra_wheel_base.get() * _max_yaw_rate / tanf(_param_ra_max_str_ang.get()); } @@ -74,9 +74,9 @@ void AckermannPosControl::updatePosControl() float speed_setpoint{_cruising_speed}; - if (!course_control && _param_ro_decel_limit.get() > FLT_EPSILON && _param_ro_jerk_limit.get() > FLT_EPSILON) { - speed_setpoint = math::min(math::trajectory::computeMaxSpeedFromDistance(_param_ro_jerk_limit.get(), - _param_ro_decel_limit.get(), distance_to_target, fabsf(_arrival_speed)), _cruising_speed); + if (!course_control && _param_ro_decel_lim.get() > FLT_EPSILON && _param_ro_jerk_lim.get() > FLT_EPSILON) { + speed_setpoint = math::min(math::trajectory::computeMaxSpeedFromDistance(_param_ro_jerk_lim.get(), + _param_ro_decel_lim.get(), distance_to_target, fabsf(_arrival_speed)), _cruising_speed); } float bearing_setpoint{NAN}; @@ -175,7 +175,7 @@ void AckermannPosControl::updateSubscriptions() _start_ned = _start_ned.isAllFinite() ? _start_ned : _curr_pos_ned; _arrival_speed = PX4_ISFINITE(surface_vehicle_position_setpoint.arrival_speed) ? surface_vehicle_position_setpoint.arrival_speed : 0.f; _cruising_speed = PX4_ISFINITE(surface_vehicle_position_setpoint.cruising_speed) ? surface_vehicle_position_setpoint.cruising_speed : - _param_ro_speed_limit.get(); + _param_ro_speed_lim.get(); _target_waypoint_ned = Vector2f(surface_vehicle_position_setpoint.target_ned[0], surface_vehicle_position_setpoint.target_ned[1]); _course = NAN; _stopped = false; @@ -187,7 +187,7 @@ void AckermannPosControl::updateSubscriptions() _start_ned = Vector2f(NAN, NAN); _arrival_speed = 0.f; _cruising_speed = PX4_ISFINITE(surface_vehicle_course_setpoint.speed) ? - surface_vehicle_course_setpoint.speed : _param_ro_speed_limit.get(); + surface_vehicle_course_setpoint.speed : _param_ro_speed_lim.get(); _target_waypoint_ned = Vector2f(NAN, NAN); _course = surface_vehicle_course_setpoint.course; _stopped = false; @@ -199,7 +199,7 @@ bool AckermannPosControl::runSanityChecks() { bool ret = true; - if (_param_ro_speed_limit.get() < FLT_EPSILON) { + if (_param_ro_speed_lim.get() < FLT_EPSILON) { ret = false; } diff --git a/src/modules/rover_ackermann/AckermannPosControl/AckermannPosControl.hpp b/src/modules/rover_ackermann/AckermannPosControl/AckermannPosControl.hpp index 44e8ff17360..a17c1c86062 100644 --- a/src/modules/rover_ackermann/AckermannPosControl/AckermannPosControl.hpp +++ b/src/modules/rover_ackermann/AckermannPosControl/AckermannPosControl.hpp @@ -85,7 +85,7 @@ public: /** * @brief Reset position controller. */ - void reset() {_start_ned = Vector2f{NAN, NAN}; _target_waypoint_ned = Vector2f{NAN, NAN}; _course = NAN; _arrival_speed = 0.f; _cruising_speed = _param_ro_speed_limit.get(); _stopped = false; _drift_angle_estimator.reset();}; + void reset() {_start_ned = Vector2f{NAN, NAN}; _target_waypoint_ned = Vector2f{NAN, NAN}; _course = NAN; _arrival_speed = 0.f; _cruising_speed = _param_ro_speed_lim.get(); _stopped = false; _drift_angle_estimator.reset();}; protected: /** @@ -134,13 +134,13 @@ private: DEFINE_PARAMETERS( (ParamFloat) _param_ro_max_thr_speed, (ParamFloat) _param_ro_speed_red, - (ParamFloat) _param_ro_decel_limit, - (ParamFloat) _param_ro_jerk_limit, - (ParamFloat) _param_ro_speed_limit, + (ParamFloat) _param_ro_decel_lim, + (ParamFloat) _param_ro_jerk_lim, + (ParamFloat) _param_ro_speed_lim, (ParamFloat) _param_pp_lookahd_gain, (ParamFloat) _param_pp_lookahd_max, (ParamFloat) _param_pp_lookahd_min, - (ParamFloat) _param_ro_yaw_rate_limit, + (ParamFloat) _param_ro_yaw_rate_lim, (ParamFloat) _param_ra_wheel_base, (ParamFloat) _param_ra_max_str_ang, (ParamFloat) _param_ro_speed_th diff --git a/src/modules/rover_ackermann/AckermannRateControl/AckermannRateControl.cpp b/src/modules/rover_ackermann/AckermannRateControl/AckermannRateControl.cpp index 1a602cba9c4..1de7c0186fa 100644 --- a/src/modules/rover_ackermann/AckermannRateControl/AckermannRateControl.cpp +++ b/src/modules/rover_ackermann/AckermannRateControl/AckermannRateControl.cpp @@ -47,7 +47,7 @@ AckermannRateControl::AckermannRateControl(ModuleParams *parent) : void AckermannRateControl::updateParams() { ModuleParams::updateParams(); - _max_yaw_rate = _param_ro_yaw_rate_limit.get() * M_DEG_TO_RAD_F; + _max_yaw_rate = _param_ro_yaw_rate_lim.get() * M_DEG_TO_RAD_F; // Set up PID controller _pid_yaw_rate.setGains(_param_ro_yaw_rate_p.get(), _param_ro_yaw_rate_i.get(), 0.f); @@ -55,7 +55,7 @@ void AckermannRateControl::updateParams() _pid_yaw_rate.setOutputLimit(1.f); // Set up slew rate - _adjusted_yaw_rate_setpoint.setSlewRate(_param_ro_yaw_accel_limit.get() * M_DEG_TO_RAD_F); + _adjusted_yaw_rate_setpoint.setSlewRate(_param_ro_yaw_accel_lim.get() * M_DEG_TO_RAD_F); } void AckermannRateControl::updateRateControl() @@ -75,7 +75,7 @@ void AckermannRateControl::updateRateControl() float yaw_rate_limit = math::min(max_possible_yaw_rate, _max_yaw_rate); float constrained_yaw_rate = math::constrain(_yaw_rate_setpoint, -yaw_rate_limit, yaw_rate_limit); - if (_param_ro_yaw_accel_limit.get() > FLT_EPSILON) { // Apply slew rate if configured + if (_param_ro_yaw_accel_lim.get() > FLT_EPSILON) { // Apply slew rate if configured if (fabsf(_adjusted_yaw_rate_setpoint.getState() - _vehicle_yaw_rate) > fabsf(constrained_yaw_rate - _vehicle_yaw_rate)) { _adjusted_yaw_rate_setpoint.setForcedValue(_vehicle_yaw_rate); @@ -173,10 +173,10 @@ bool AckermannRateControl::runSanityChecks() } - if (_param_ro_yaw_rate_limit.get() < FLT_EPSILON) { + if (_param_ro_yaw_rate_lim.get() < FLT_EPSILON) { ret = false; events::send(events::ID("ackermann_rate_control_conf_invalid_yaw_rate_lim"), events::Log::Error, - "Invalid configuration of necessary parameter RO_YAW_RATE_LIM", _param_ro_yaw_rate_limit.get()); + "Invalid configuration of necessary parameter RO_YAW_RATE_LIM", _param_ro_yaw_rate_lim.get()); } diff --git a/src/modules/rover_ackermann/AckermannRateControl/AckermannRateControl.hpp b/src/modules/rover_ackermann/AckermannRateControl/AckermannRateControl.hpp index 7036bbf0b30..6cf44a8bb86 100644 --- a/src/modules/rover_ackermann/AckermannRateControl/AckermannRateControl.hpp +++ b/src/modules/rover_ackermann/AckermannRateControl/AckermannRateControl.hpp @@ -122,11 +122,11 @@ private: (ParamFloat) _param_ro_max_thr_speed, (ParamFloat) _param_ra_wheel_base, (ParamFloat) _param_ra_max_str_ang, - (ParamFloat) _param_ro_yaw_rate_limit, + (ParamFloat) _param_ro_yaw_rate_lim, (ParamFloat) _param_ro_yaw_rate_th, (ParamFloat) _param_ro_yaw_rate_p, (ParamFloat) _param_ro_yaw_rate_i, - (ParamFloat) _param_ro_yaw_accel_limit, + (ParamFloat) _param_ro_yaw_accel_lim, (ParamFloat) _param_ro_speed_th, (ParamFloat) _param_ro_yaw_rate_corr ) diff --git a/src/modules/rover_ackermann/AckermannSpeedControl/AckermannSpeedControl.cpp b/src/modules/rover_ackermann/AckermannSpeedControl/AckermannSpeedControl.cpp index ee726ad6ae7..dd90651f4e1 100644 --- a/src/modules/rover_ackermann/AckermannSpeedControl/AckermannSpeedControl.cpp +++ b/src/modules/rover_ackermann/AckermannSpeedControl/AckermannSpeedControl.cpp @@ -54,8 +54,8 @@ void AckermannSpeedControl::updateParams() _pid_speed.setOutputLimit(1.f); // Set up slew rate - if (_param_ro_accel_limit.get() > FLT_EPSILON) { - _adjusted_speed_setpoint.setSlewRate(_param_ro_accel_limit.get()); + if (_param_ro_accel_lim.get() > FLT_EPSILON) { + _adjusted_speed_setpoint.setSlewRate(_param_ro_accel_lim.get()); } } @@ -70,12 +70,12 @@ void AckermannSpeedControl::updateSpeedControl() // Thrust setpoint if (PX4_ISFINITE(_speed_setpoint)) { - const float speed_setpoint = math::constrain(_speed_setpoint, -_param_ro_speed_limit.get(), - _param_ro_speed_limit.get()); + const float speed_setpoint = math::constrain(_speed_setpoint, -_param_ro_speed_lim.get(), + _param_ro_speed_lim.get()); surface_vehicle_thrust_setpoint_s surface_vehicle_thrust_setpoint{}; surface_vehicle_thrust_setpoint.timestamp = _timestamp; surface_vehicle_thrust_setpoint.x = RoverControl::speedControl(_adjusted_speed_setpoint, _pid_speed, - speed_setpoint, _vehicle_speed, _param_ro_accel_limit.get(), _param_ro_decel_limit.get(), + speed_setpoint, _vehicle_speed, _param_ro_accel_lim.get(), _param_ro_decel_lim.get(), _param_ro_max_thr_speed.get(), dt); surface_vehicle_thrust_setpoint.y = NAN; _surface_vehicle_thrust_setpoint_pub.publish(surface_vehicle_thrust_setpoint); @@ -125,10 +125,10 @@ bool AckermannSpeedControl::runSanityChecks() ret = false; } - if (_param_ro_speed_limit.get() < FLT_EPSILON) { + if (_param_ro_speed_lim.get() < FLT_EPSILON) { ret = false; events::send(events::ID("ackermann_speed_control_conf_invalid_speed_lim"), events::Log::Error, - "Invalid configuration of necessary parameter RO_SPEED_LIM", _param_ro_speed_limit.get()); + "Invalid configuration of necessary parameter RO_SPEED_LIM", _param_ro_speed_lim.get()); } diff --git a/src/modules/rover_ackermann/AckermannSpeedControl/AckermannSpeedControl.hpp b/src/modules/rover_ackermann/AckermannSpeedControl/AckermannSpeedControl.hpp index 02659e75280..b43ab95c830 100644 --- a/src/modules/rover_ackermann/AckermannSpeedControl/AckermannSpeedControl.hpp +++ b/src/modules/rover_ackermann/AckermannSpeedControl/AckermannSpeedControl.hpp @@ -123,10 +123,10 @@ private: (ParamFloat) _param_ro_max_thr_speed, (ParamFloat) _param_ro_speed_p, (ParamFloat) _param_ro_speed_i, - (ParamFloat) _param_ro_accel_limit, - (ParamFloat) _param_ro_decel_limit, - (ParamFloat) _param_ro_jerk_limit, - (ParamFloat) _param_ro_speed_limit, + (ParamFloat) _param_ro_accel_lim, + (ParamFloat) _param_ro_decel_lim, + (ParamFloat) _param_ro_jerk_lim, + (ParamFloat) _param_ro_speed_lim, (ParamFloat) _param_ro_speed_th ) }; diff --git a/src/modules/rover_differential/DifferentialActControl/DifferentialActControl.cpp b/src/modules/rover_differential/DifferentialActControl/DifferentialActControl.cpp index fbdbfd4968a..9f498b88ed3 100644 --- a/src/modules/rover_differential/DifferentialActControl/DifferentialActControl.cpp +++ b/src/modules/rover_differential/DifferentialActControl/DifferentialActControl.cpp @@ -48,8 +48,8 @@ void DifferentialActControl::updateParams() { ModuleParams::updateParams(); - if (_param_ro_accel_limit.get() > FLT_EPSILON && _param_ro_max_thr_speed.get() > FLT_EPSILON) { - _adjusted_throttle_setpoint.setSlewRate(_param_ro_accel_limit.get() / _param_ro_max_thr_speed.get()); + if (_param_ro_accel_lim.get() > FLT_EPSILON && _param_ro_max_thr_speed.get() > FLT_EPSILON) { + _adjusted_throttle_setpoint.setSlewRate(_param_ro_accel_lim.get() / _param_ro_max_thr_speed.get()); } } @@ -77,10 +77,10 @@ void DifferentialActControl::updateActControl() _actuator_motors_sub.copy(&actuator_motors_sub); const float current_throttle = (actuator_motors_sub.control[0] + actuator_motors_sub.control[1]) / 2.f; const float adjusted_throttle_setpoint = RoverControl::throttleControl(_adjusted_throttle_setpoint, - _throttle_setpoint, current_throttle, _param_ro_accel_limit.get(), - _param_ro_decel_limit.get(), _param_ro_max_thr_speed.get(), dt); + _throttle_setpoint, current_throttle, _param_ro_accel_lim.get(), + _param_ro_decel_lim.get(), _param_ro_max_thr_speed.get(), dt); actuator_motors_s actuator_motors{}; - actuator_motors.reversible_flags = _param_r_rev.get(); + actuator_motors.reversible_flags = _param_ca_r_rev.get(); computeInverseKinematics(adjusted_throttle_setpoint, _speed_diff_setpoint).copyTo(actuator_motors.control); actuator_motors.timestamp = _timestamp; _actuator_motors_pub.publish(actuator_motors); @@ -107,7 +107,7 @@ void DifferentialActControl::stopVehicle() { _timestamp = hrt_absolute_time(); actuator_motors_s actuator_motors{}; - actuator_motors.reversible_flags = _param_r_rev.get(); + actuator_motors.reversible_flags = _param_ca_r_rev.get(); actuator_motors.control[0] = 0.f; actuator_motors.control[1] = 0.f; actuator_motors.timestamp = _timestamp; diff --git a/src/modules/rover_differential/DifferentialActControl/DifferentialActControl.hpp b/src/modules/rover_differential/DifferentialActControl/DifferentialActControl.hpp index 280c1adafd2..11f45ac0e50 100644 --- a/src/modules/rover_differential/DifferentialActControl/DifferentialActControl.hpp +++ b/src/modules/rover_differential/DifferentialActControl/DifferentialActControl.hpp @@ -110,9 +110,9 @@ private: // Parameters DEFINE_PARAMETERS( - (ParamInt) _param_r_rev, - (ParamFloat) _param_ro_accel_limit, - (ParamFloat) _param_ro_decel_limit, + (ParamInt) _param_ca_r_rev, + (ParamFloat) _param_ro_accel_lim, + (ParamFloat) _param_ro_decel_lim, (ParamFloat) _param_ro_max_thr_speed ) }; diff --git a/src/modules/rover_differential/DifferentialAttControl/DifferentialAttControl.cpp b/src/modules/rover_differential/DifferentialAttControl/DifferentialAttControl.cpp index 185fb94345c..eb35bb8d820 100644 --- a/src/modules/rover_differential/DifferentialAttControl/DifferentialAttControl.cpp +++ b/src/modules/rover_differential/DifferentialAttControl/DifferentialAttControl.cpp @@ -48,8 +48,8 @@ void DifferentialAttControl::updateParams() { ModuleParams::updateParams(); - if (_param_ro_yaw_rate_limit.get() > FLT_EPSILON) { - _max_yaw_rate = _param_ro_yaw_rate_limit.get() * M_DEG_TO_RAD_F; + if (_param_ro_yaw_rate_lim.get() > FLT_EPSILON) { + _max_yaw_rate = _param_ro_yaw_rate_lim.get() * M_DEG_TO_RAD_F; } // Set up PID controller @@ -104,7 +104,7 @@ bool DifferentialAttControl::runSanityChecks() { bool ret = true; - if (_param_ro_yaw_rate_limit.get() < FLT_EPSILON) { + if (_param_ro_yaw_rate_lim.get() < FLT_EPSILON) { ret = false; } diff --git a/src/modules/rover_differential/DifferentialAttControl/DifferentialAttControl.hpp b/src/modules/rover_differential/DifferentialAttControl/DifferentialAttControl.hpp index a48483070f4..fc943a6b1c8 100644 --- a/src/modules/rover_differential/DifferentialAttControl/DifferentialAttControl.hpp +++ b/src/modules/rover_differential/DifferentialAttControl/DifferentialAttControl.hpp @@ -112,7 +112,7 @@ private: // Parameters DEFINE_PARAMETERS( - (ParamFloat) _param_ro_yaw_rate_limit, + (ParamFloat) _param_ro_yaw_rate_lim, (ParamFloat) _param_ro_yaw_p, (ParamFloat) _param_ro_yaw_stick_dz ) diff --git a/src/modules/rover_differential/DifferentialDriveModes/DifferentialAutoMode/DifferentialAutoMode.cpp b/src/modules/rover_differential/DifferentialDriveModes/DifferentialAutoMode/DifferentialAutoMode.cpp index 4ba088c37f5..4328b789403 100644 --- a/src/modules/rover_differential/DifferentialDriveModes/DifferentialAutoMode/DifferentialAutoMode.cpp +++ b/src/modules/rover_differential/DifferentialDriveModes/DifferentialAutoMode/DifferentialAutoMode.cpp @@ -77,7 +77,7 @@ void DifferentialAutoMode::autoControl() // Waypoint cruising speed float cruising_speed = position_setpoint_triplet.current.cruising_speed > 0.f ? math::constrain( - position_setpoint_triplet.current.cruising_speed, 0.f, _param_ro_speed_limit.get()) : _param_ro_speed_limit.get(); + position_setpoint_triplet.current.cruising_speed, 0.f, _param_ro_speed_lim.get()) : _param_ro_speed_lim.get(); surface_vehicle_position_setpoint_s surface_vehicle_position_setpoint{}; surface_vehicle_position_setpoint.timestamp = hrt_absolute_time(); @@ -86,7 +86,7 @@ void DifferentialAutoMode::autoControl() surface_vehicle_position_setpoint.start_ned[0] = prev_wp_ned(0); surface_vehicle_position_setpoint.start_ned[1] = prev_wp_ned(1); surface_vehicle_position_setpoint.arrival_speed = arrivalSpeed(cruising_speed, waypoint_transition_angle, - _param_ro_speed_limit.get(), _param_rd_trans_drv_trn.get(), _param_ro_speed_red.get(), curr_wp_type); + _param_ro_speed_lim.get(), _param_rd_trans_drv_trn.get(), _param_ro_speed_red.get(), curr_wp_type); surface_vehicle_position_setpoint.cruising_speed = cruising_speed; surface_vehicle_position_setpoint.yaw = NAN; _surface_vehicle_position_setpoint_pub.publish(surface_vehicle_position_setpoint); @@ -139,7 +139,7 @@ void DifferentialAutoMode::guidedCourse() surface_vehicle_course_setpoint.timestamp = hrt_absolute_time(); // The navigator publishes the course in [0, 2pi) surface_vehicle_course_setpoint.course = matrix::wrap_pi(current.course); - surface_vehicle_course_setpoint.speed = math::min(_course_speed, _param_ro_speed_limit.get()); + surface_vehicle_course_setpoint.speed = math::min(_course_speed, _param_ro_speed_lim.get()); surface_vehicle_course_setpoint.yaw = NAN; _surface_vehicle_course_setpoint_pub.publish(surface_vehicle_course_setpoint); } diff --git a/src/modules/rover_differential/DifferentialDriveModes/DifferentialAutoMode/DifferentialAutoMode.hpp b/src/modules/rover_differential/DifferentialDriveModes/DifferentialAutoMode/DifferentialAutoMode.hpp index 6ae6a37cd42..f531cfc2fd3 100644 --- a/src/modules/rover_differential/DifferentialDriveModes/DifferentialAutoMode/DifferentialAutoMode.hpp +++ b/src/modules/rover_differential/DifferentialDriveModes/DifferentialAutoMode/DifferentialAutoMode.hpp @@ -117,7 +117,7 @@ private: float _course_speed{NAN}; // Guided Course speed [m/s], NAN until latched from the forward speed on the first course setpoint DEFINE_PARAMETERS( - (ParamFloat) _param_ro_speed_limit, + (ParamFloat) _param_ro_speed_lim, (ParamFloat) _param_ro_speed_red, (ParamFloat) _param_rd_trans_drv_trn ) diff --git a/src/modules/rover_differential/DifferentialDriveModes/DifferentialManualMode/DifferentialManualMode.cpp b/src/modules/rover_differential/DifferentialDriveModes/DifferentialManualMode/DifferentialManualMode.cpp index fa40e940ebd..c2d962a5d17 100644 --- a/src/modules/rover_differential/DifferentialDriveModes/DifferentialManualMode/DifferentialManualMode.cpp +++ b/src/modules/rover_differential/DifferentialDriveModes/DifferentialManualMode/DifferentialManualMode.cpp @@ -49,7 +49,7 @@ DifferentialManualMode::DifferentialManualMode(ModuleParams *parent) : ModulePar void DifferentialManualMode::updateParams() { ModuleParams::updateParams(); - _max_yaw_rate = _param_ro_yaw_rate_limit.get() * M_DEG_TO_RAD_F; + _max_yaw_rate = _param_ro_yaw_rate_lim.get() * M_DEG_TO_RAD_F; } void DifferentialManualMode::manual() @@ -177,7 +177,7 @@ void DifferentialManualMode::position() _param_ro_stick_map.get()); const float speed_setpoint = math::interpolate(sticks.forward, - -1.f, 1.f, -_param_ro_speed_limit.get(), _param_ro_speed_limit.get()); + -1.f, 1.f, -_param_ro_speed_lim.get(), _param_ro_speed_lim.get()); if (fabsf(sticks.yaw) > FLT_EPSILON || fabsf(speed_setpoint) < FLT_EPSILON) { diff --git a/src/modules/rover_differential/DifferentialDriveModes/DifferentialManualMode/DifferentialManualMode.hpp b/src/modules/rover_differential/DifferentialDriveModes/DifferentialManualMode/DifferentialManualMode.hpp index f6f106b2fd6..0d60aa0be51 100644 --- a/src/modules/rover_differential/DifferentialDriveModes/DifferentialManualMode/DifferentialManualMode.hpp +++ b/src/modules/rover_differential/DifferentialDriveModes/DifferentialManualMode/DifferentialManualMode.hpp @@ -129,13 +129,13 @@ private: float _max_yaw_rate{NAN}; DEFINE_PARAMETERS( - (ParamFloat) _param_ro_yaw_rate_limit, + (ParamFloat) _param_ro_yaw_rate_lim, (ParamFloat) _param_ro_yaw_stick_dz, (ParamFloat) _param_ro_yaw_expo, (ParamFloat) _param_ro_yaw_supexpo, (ParamFloat) _param_rd_yaw_stk_gain, (ParamFloat) _param_ro_park_thr_max, - (ParamFloat) _param_ro_speed_limit, + (ParamFloat) _param_ro_speed_lim, (ParamFloat) _param_pp_lookahd_max, (ParamInt) _param_ro_stick_map ) diff --git a/src/modules/rover_differential/DifferentialPosControl/DifferentialPosControl.cpp b/src/modules/rover_differential/DifferentialPosControl/DifferentialPosControl.cpp index cdd364c5cca..d528d483d26 100644 --- a/src/modules/rover_differential/DifferentialPosControl/DifferentialPosControl.cpp +++ b/src/modules/rover_differential/DifferentialPosControl/DifferentialPosControl.cpp @@ -72,9 +72,9 @@ void DifferentialPosControl::updatePosControl() if (course_control || distance_to_target > _param_nav_acc_rad.get() || _arrival_speed > FLT_EPSILON) { float speed_setpoint{_cruising_speed}; - if (!course_control && _param_ro_decel_limit.get() > FLT_EPSILON && _param_ro_jerk_limit.get() > FLT_EPSILON) { - speed_setpoint = math::min(math::trajectory::computeMaxSpeedFromDistance(_param_ro_jerk_limit.get(), - _param_ro_decel_limit.get(), distance_to_target, fabsf(_arrival_speed)), _cruising_speed); + if (!course_control && _param_ro_decel_lim.get() > FLT_EPSILON && _param_ro_jerk_lim.get() > FLT_EPSILON) { + speed_setpoint = math::min(math::trajectory::computeMaxSpeedFromDistance(_param_ro_jerk_lim.get(), + _param_ro_decel_lim.get(), distance_to_target, fabsf(_arrival_speed)), _cruising_speed); } float yaw_setpoint{NAN}; @@ -182,7 +182,7 @@ void DifferentialPosControl::updateSubscriptions() _start_ned = _start_ned.isAllFinite() ? _start_ned : _curr_pos_ned; _arrival_speed = PX4_ISFINITE(surface_vehicle_position_setpoint.arrival_speed) ? surface_vehicle_position_setpoint.arrival_speed : 0.f; _cruising_speed = PX4_ISFINITE(surface_vehicle_position_setpoint.cruising_speed) ? surface_vehicle_position_setpoint.cruising_speed : - _param_ro_speed_limit.get(); + _param_ro_speed_lim.get(); _target_waypoint_ned = Vector2f(surface_vehicle_position_setpoint.target_ned[0], surface_vehicle_position_setpoint.target_ned[1]); _course = NAN; _stopped = false; @@ -194,7 +194,7 @@ void DifferentialPosControl::updateSubscriptions() _start_ned = Vector2f(NAN, NAN); _arrival_speed = 0.f; _cruising_speed = PX4_ISFINITE(surface_vehicle_course_setpoint.speed) ? - surface_vehicle_course_setpoint.speed : _param_ro_speed_limit.get(); + surface_vehicle_course_setpoint.speed : _param_ro_speed_lim.get(); _target_waypoint_ned = Vector2f(NAN, NAN); _course = surface_vehicle_course_setpoint.course; _stopped = false; @@ -205,7 +205,7 @@ bool DifferentialPosControl::runSanityChecks() { bool ret = true; - if (_param_ro_speed_limit.get() < FLT_EPSILON) { + if (_param_ro_speed_lim.get() < FLT_EPSILON) { ret = false; } diff --git a/src/modules/rover_differential/DifferentialPosControl/DifferentialPosControl.hpp b/src/modules/rover_differential/DifferentialPosControl/DifferentialPosControl.hpp index e2088ca3cc2..e25560cedc9 100644 --- a/src/modules/rover_differential/DifferentialPosControl/DifferentialPosControl.hpp +++ b/src/modules/rover_differential/DifferentialPosControl/DifferentialPosControl.hpp @@ -92,7 +92,7 @@ public: /** * @brief Reset position controller. */ - void reset() {_start_ned = Vector2f{NAN, NAN}; _target_waypoint_ned = Vector2f{NAN, NAN}; _course = NAN; _arrival_speed = 0.f; _cruising_speed = _param_ro_speed_limit.get(); _stopped = false; _drift_angle_estimator.reset();}; + void reset() {_start_ned = Vector2f{NAN, NAN}; _target_waypoint_ned = Vector2f{NAN, NAN}; _course = NAN; _arrival_speed = 0.f; _cruising_speed = _param_ro_speed_lim.get(); _stopped = false; _drift_angle_estimator.reset();}; protected: /** @@ -139,9 +139,9 @@ private: (ParamFloat) _param_rd_trans_trn_drv, (ParamFloat) _param_rd_trans_drv_trn, (ParamFloat) _param_ro_max_thr_speed, - (ParamFloat) _param_ro_decel_limit, - (ParamFloat) _param_ro_jerk_limit, - (ParamFloat) _param_ro_speed_limit, + (ParamFloat) _param_ro_decel_lim, + (ParamFloat) _param_ro_jerk_lim, + (ParamFloat) _param_ro_speed_lim, (ParamFloat) _param_pp_lookahd_gain, (ParamFloat) _param_pp_lookahd_max, (ParamFloat) _param_pp_lookahd_min, diff --git a/src/modules/rover_differential/DifferentialRateControl/DifferentialRateControl.cpp b/src/modules/rover_differential/DifferentialRateControl/DifferentialRateControl.cpp index 25bcc6193a3..858e222c683 100644 --- a/src/modules/rover_differential/DifferentialRateControl/DifferentialRateControl.cpp +++ b/src/modules/rover_differential/DifferentialRateControl/DifferentialRateControl.cpp @@ -54,7 +54,7 @@ void DifferentialRateControl::updateParams() _pid_yaw_rate.setOutputLimit(1.f); // Set up slew rate - _adjusted_yaw_rate_setpoint.setSlewRate(_param_ro_yaw_accel_limit.get() * M_DEG_TO_RAD_F); + _adjusted_yaw_rate_setpoint.setSlewRate(_param_ro_yaw_accel_lim.get() * M_DEG_TO_RAD_F); } void DifferentialRateControl::updateRateControl() @@ -81,8 +81,8 @@ void DifferentialRateControl::updateRateControl() _yaw_rate_setpoint : 0.f; const float speed_diff_normalized = RoverControl::rateControl(_adjusted_yaw_rate_setpoint, _pid_yaw_rate, yaw_rate_setpoint, _vehicle_yaw_rate, _param_ro_max_thr_speed.get(), _param_ro_yaw_rate_corr.get(), - _param_ro_yaw_accel_limit.get() * M_DEG_TO_RAD_F, - _param_ro_yaw_decel_limit.get() * M_DEG_TO_RAD_F, _param_rd_wheel_track.get(), dt); + _param_ro_yaw_accel_lim.get() * M_DEG_TO_RAD_F, + _param_ro_yaw_decel_lim.get() * M_DEG_TO_RAD_F, _param_rd_wheel_track.get(), dt); surface_vehicle_steering_setpoint_s surface_vehicle_steering_setpoint{}; surface_vehicle_steering_setpoint.timestamp = _timestamp; surface_vehicle_steering_setpoint.normalized_steering_setpoint = speed_diff_normalized; diff --git a/src/modules/rover_differential/DifferentialRateControl/DifferentialRateControl.hpp b/src/modules/rover_differential/DifferentialRateControl/DifferentialRateControl.hpp index 2066d8f9d7a..56e05e73ff6 100644 --- a/src/modules/rover_differential/DifferentialRateControl/DifferentialRateControl.hpp +++ b/src/modules/rover_differential/DifferentialRateControl/DifferentialRateControl.hpp @@ -113,8 +113,8 @@ private: (ParamFloat) _param_ro_yaw_rate_th, (ParamFloat) _param_ro_yaw_rate_p, (ParamFloat) _param_ro_yaw_rate_i, - (ParamFloat) _param_ro_yaw_accel_limit, - (ParamFloat) _param_ro_yaw_decel_limit, + (ParamFloat) _param_ro_yaw_accel_lim, + (ParamFloat) _param_ro_yaw_decel_lim, (ParamFloat) _param_ro_yaw_rate_corr, (ParamFloat) _param_ro_max_thr_speed ) diff --git a/src/modules/rover_differential/DifferentialSpeedControl/DifferentialSpeedControl.cpp b/src/modules/rover_differential/DifferentialSpeedControl/DifferentialSpeedControl.cpp index ad578c06dba..34834c99933 100644 --- a/src/modules/rover_differential/DifferentialSpeedControl/DifferentialSpeedControl.cpp +++ b/src/modules/rover_differential/DifferentialSpeedControl/DifferentialSpeedControl.cpp @@ -54,8 +54,8 @@ void DifferentialSpeedControl::updateParams() _pid_speed.setOutputLimit(1.f); // Set up slew rate - if (_param_ro_accel_limit.get() > FLT_EPSILON) { - _adjusted_speed_setpoint.setSlewRate(_param_ro_accel_limit.get()); + if (_param_ro_accel_lim.get() > FLT_EPSILON) { + _adjusted_speed_setpoint.setSlewRate(_param_ro_accel_lim.get()); } } @@ -74,7 +74,7 @@ void DifferentialSpeedControl::updateSpeedControl() surface_vehicle_thrust_setpoint_s surface_vehicle_thrust_setpoint{}; surface_vehicle_thrust_setpoint.timestamp = _timestamp; surface_vehicle_thrust_setpoint.x = RoverControl::speedControl(_adjusted_speed_setpoint, _pid_speed, - speed_setpoint, _vehicle_speed, _param_ro_accel_limit.get(), _param_ro_decel_limit.get(), + speed_setpoint, _vehicle_speed, _param_ro_accel_lim.get(), _param_ro_decel_lim.get(), _param_ro_max_thr_speed.get(), dt); surface_vehicle_thrust_setpoint.y = 0.f; _surface_vehicle_thrust_setpoint_pub.publish(surface_vehicle_thrust_setpoint); @@ -119,7 +119,7 @@ void DifferentialSpeedControl::updateSubscriptions() float DifferentialSpeedControl::calcSpeedSetpoint() { - float speed_setpoint = math::constrain(_speed_setpoint, -_param_ro_speed_limit.get(), _param_ro_speed_limit.get()); + float speed_setpoint = math::constrain(_speed_setpoint, -_param_ro_speed_lim.get(), _param_ro_speed_lim.get()); const float speed_setpoint_normalized = math::interpolate(speed_setpoint, -_param_ro_max_thr_speed.get(), _param_ro_max_thr_speed.get(), -1.f, 1.f); @@ -143,10 +143,10 @@ bool DifferentialSpeedControl::runSanityChecks() { bool ret = true; - if (_param_ro_speed_limit.get() < FLT_EPSILON) { + if (_param_ro_speed_lim.get() < FLT_EPSILON) { ret = false; events::send(events::ID("differential_speed_control_conf_invalid_speed_lim"), events::Log::Error, - "Invalid configuration of necessary parameter RO_SPEED_LIM", _param_ro_speed_limit.get()); + "Invalid configuration of necessary parameter RO_SPEED_LIM", _param_ro_speed_lim.get()); } if (_param_ro_max_thr_speed.get() < FLT_EPSILON && _param_ro_speed_p.get() < FLT_EPSILON) { diff --git a/src/modules/rover_differential/DifferentialSpeedControl/DifferentialSpeedControl.hpp b/src/modules/rover_differential/DifferentialSpeedControl/DifferentialSpeedControl.hpp index 80871f873fd..cb674d08acc 100644 --- a/src/modules/rover_differential/DifferentialSpeedControl/DifferentialSpeedControl.hpp +++ b/src/modules/rover_differential/DifferentialSpeedControl/DifferentialSpeedControl.hpp @@ -132,10 +132,10 @@ private: (ParamFloat) _param_ro_max_thr_speed, (ParamFloat) _param_ro_speed_p, (ParamFloat) _param_ro_speed_i, - (ParamFloat) _param_ro_accel_limit, - (ParamFloat) _param_ro_decel_limit, - (ParamFloat) _param_ro_jerk_limit, - (ParamFloat) _param_ro_speed_limit, + (ParamFloat) _param_ro_accel_lim, + (ParamFloat) _param_ro_decel_lim, + (ParamFloat) _param_ro_jerk_lim, + (ParamFloat) _param_ro_speed_lim, (ParamFloat) _param_ro_speed_th ) }; diff --git a/src/modules/rover_mecanum/MecanumActControl/MecanumActControl.cpp b/src/modules/rover_mecanum/MecanumActControl/MecanumActControl.cpp index 2d3defc0adf..b41dc570f4b 100644 --- a/src/modules/rover_mecanum/MecanumActControl/MecanumActControl.cpp +++ b/src/modules/rover_mecanum/MecanumActControl/MecanumActControl.cpp @@ -48,9 +48,9 @@ void MecanumActControl::updateParams() { ModuleParams::updateParams(); - if (_param_ro_accel_limit.get() > FLT_EPSILON && _param_ro_max_thr_speed.get() > FLT_EPSILON) { - _adjusted_throttle_x_setpoint.setSlewRate(_param_ro_accel_limit.get() / _param_ro_max_thr_speed.get()); - _adjusted_throttle_y_setpoint.setSlewRate(_param_ro_accel_limit.get() / _param_ro_max_thr_speed.get()); + if (_param_ro_accel_lim.get() > FLT_EPSILON && _param_ro_max_thr_speed.get() > FLT_EPSILON) { + _adjusted_throttle_x_setpoint.setSlewRate(_param_ro_accel_lim.get() / _param_ro_max_thr_speed.get()); + _adjusted_throttle_y_setpoint.setSlewRate(_param_ro_accel_lim.get() / _param_ro_max_thr_speed.get()); } } @@ -80,13 +80,13 @@ void MecanumActControl::updateActControl() const float current_throttle_x = (actuator_motors_sub.control[0] + actuator_motors_sub.control[1]) / 2.f; const float current_throttle_y = (actuator_motors_sub.control[2] - actuator_motors_sub.control[0]) / 2.f; const float adjusted_throttle_x_setpoint = RoverControl::throttleControl(_adjusted_throttle_x_setpoint, - _throttle_x_setpoint, current_throttle_x, _param_ro_accel_limit.get(), - _param_ro_decel_limit.get(), _param_ro_max_thr_speed.get(), dt); + _throttle_x_setpoint, current_throttle_x, _param_ro_accel_lim.get(), + _param_ro_decel_lim.get(), _param_ro_max_thr_speed.get(), dt); const float adjusted_throttle_y_setpoint = RoverControl::throttleControl(_adjusted_throttle_y_setpoint, - _throttle_y_setpoint, current_throttle_y, _param_ro_accel_limit.get(), - _param_ro_decel_limit.get(), _param_ro_max_thr_speed.get(), dt); + _throttle_y_setpoint, current_throttle_y, _param_ro_accel_lim.get(), + _param_ro_decel_lim.get(), _param_ro_max_thr_speed.get(), dt); actuator_motors_s actuator_motors{}; - actuator_motors.reversible_flags = _param_r_rev.get(); + actuator_motors.reversible_flags = _param_ca_r_rev.get(); computeInverseKinematics(adjusted_throttle_x_setpoint, adjusted_throttle_y_setpoint, _speed_diff_setpoint).copyTo(actuator_motors.control); actuator_motors.timestamp = _timestamp; @@ -124,7 +124,7 @@ void MecanumActControl::stopVehicle() { _timestamp = hrt_absolute_time(); actuator_motors_s actuator_motors{}; - actuator_motors.reversible_flags = _param_r_rev.get(); + actuator_motors.reversible_flags = _param_ca_r_rev.get(); actuator_motors.control[0] = 0.f; actuator_motors.control[1] = 0.f; actuator_motors.control[2] = 0.f; diff --git a/src/modules/rover_mecanum/MecanumActControl/MecanumActControl.hpp b/src/modules/rover_mecanum/MecanumActControl/MecanumActControl.hpp index ec804d5c000..d03347be555 100644 --- a/src/modules/rover_mecanum/MecanumActControl/MecanumActControl.hpp +++ b/src/modules/rover_mecanum/MecanumActControl/MecanumActControl.hpp @@ -112,9 +112,9 @@ private: // Parameters DEFINE_PARAMETERS( - (ParamInt) _param_r_rev, - (ParamFloat) _param_ro_accel_limit, - (ParamFloat) _param_ro_decel_limit, + (ParamInt) _param_ca_r_rev, + (ParamFloat) _param_ro_accel_lim, + (ParamFloat) _param_ro_decel_lim, (ParamFloat) _param_ro_max_thr_speed ) }; diff --git a/src/modules/rover_mecanum/MecanumAttControl/MecanumAttControl.cpp b/src/modules/rover_mecanum/MecanumAttControl/MecanumAttControl.cpp index 05ef1349c9b..95ab4ee96fc 100644 --- a/src/modules/rover_mecanum/MecanumAttControl/MecanumAttControl.cpp +++ b/src/modules/rover_mecanum/MecanumAttControl/MecanumAttControl.cpp @@ -48,8 +48,8 @@ void MecanumAttControl::updateParams() { ModuleParams::updateParams(); - if (_param_ro_yaw_rate_limit.get() > FLT_EPSILON) { - _max_yaw_rate = _param_ro_yaw_rate_limit.get() * M_DEG_TO_RAD_F; + if (_param_ro_yaw_rate_lim.get() > FLT_EPSILON) { + _max_yaw_rate = _param_ro_yaw_rate_lim.get() * M_DEG_TO_RAD_F; } // Set up PID controller @@ -109,7 +109,7 @@ bool MecanumAttControl::runSanityChecks() { bool ret = true; - if (_param_ro_yaw_rate_limit.get() < FLT_EPSILON) { + if (_param_ro_yaw_rate_lim.get() < FLT_EPSILON) { ret = false; } diff --git a/src/modules/rover_mecanum/MecanumAttControl/MecanumAttControl.hpp b/src/modules/rover_mecanum/MecanumAttControl/MecanumAttControl.hpp index 24ffb35b0c2..65651428708 100644 --- a/src/modules/rover_mecanum/MecanumAttControl/MecanumAttControl.hpp +++ b/src/modules/rover_mecanum/MecanumAttControl/MecanumAttControl.hpp @@ -119,7 +119,7 @@ private: // Parameters DEFINE_PARAMETERS( - (ParamFloat) _param_ro_yaw_rate_limit, + (ParamFloat) _param_ro_yaw_rate_lim, (ParamFloat) _param_ro_yaw_p, (ParamFloat) _param_ro_yaw_stick_dz ) diff --git a/src/modules/rover_mecanum/MecanumDriveModes/MecanumAutoMode/MecanumAutoMode.cpp b/src/modules/rover_mecanum/MecanumDriveModes/MecanumAutoMode/MecanumAutoMode.cpp index 563e5ff9818..b68c781893d 100644 --- a/src/modules/rover_mecanum/MecanumDriveModes/MecanumAutoMode/MecanumAutoMode.cpp +++ b/src/modules/rover_mecanum/MecanumDriveModes/MecanumAutoMode/MecanumAutoMode.cpp @@ -77,7 +77,7 @@ void MecanumAutoMode::autoControl() // Waypoint cruising speed float cruising_speed = position_setpoint_triplet.current.cruising_speed > 0.f ? math::constrain( - position_setpoint_triplet.current.cruising_speed, 0.f, _param_ro_speed_limit.get()) : _param_ro_speed_limit.get(); + position_setpoint_triplet.current.cruising_speed, 0.f, _param_ro_speed_lim.get()) : _param_ro_speed_lim.get(); surface_vehicle_position_setpoint_s surface_vehicle_position_setpoint{}; surface_vehicle_position_setpoint.timestamp = hrt_absolute_time(); @@ -86,7 +86,7 @@ void MecanumAutoMode::autoControl() surface_vehicle_position_setpoint.start_ned[0] = prev_wp_ned(0); surface_vehicle_position_setpoint.start_ned[1] = prev_wp_ned(1); surface_vehicle_position_setpoint.arrival_speed = arrivalSpeed(cruising_speed, waypoint_transition_angle, - _param_ro_speed_limit.get(), _param_ro_speed_red.get(), curr_wp_type); + _param_ro_speed_lim.get(), _param_ro_speed_red.get(), curr_wp_type); surface_vehicle_position_setpoint.cruising_speed = cruising_speed; surface_vehicle_position_setpoint.yaw = PX4_ISFINITE(position_setpoint_triplet.current.yaw) ? position_setpoint_triplet.current.yaw : NAN; @@ -140,7 +140,7 @@ void MecanumAutoMode::guidedCourse() surface_vehicle_course_setpoint.timestamp = hrt_absolute_time(); // The navigator publishes the course in [0, 2pi) surface_vehicle_course_setpoint.course = matrix::wrap_pi(current.course); - surface_vehicle_course_setpoint.speed = math::min(_course_speed, _param_ro_speed_limit.get()); + surface_vehicle_course_setpoint.speed = math::min(_course_speed, _param_ro_speed_lim.get()); surface_vehicle_course_setpoint.yaw = NAN; _surface_vehicle_course_setpoint_pub.publish(surface_vehicle_course_setpoint); } diff --git a/src/modules/rover_mecanum/MecanumDriveModes/MecanumAutoMode/MecanumAutoMode.hpp b/src/modules/rover_mecanum/MecanumDriveModes/MecanumAutoMode/MecanumAutoMode.hpp index 31327985735..dc075d6c142 100644 --- a/src/modules/rover_mecanum/MecanumDriveModes/MecanumAutoMode/MecanumAutoMode.hpp +++ b/src/modules/rover_mecanum/MecanumDriveModes/MecanumAutoMode/MecanumAutoMode.hpp @@ -116,7 +116,7 @@ private: float _course_speed{NAN}; // Guided Course speed [m/s], NAN until latched from the forward speed on the first course setpoint DEFINE_PARAMETERS( - (ParamFloat) _param_ro_speed_limit, + (ParamFloat) _param_ro_speed_lim, (ParamFloat) _param_ro_speed_red ) }; diff --git a/src/modules/rover_mecanum/MecanumDriveModes/MecanumManualMode/MecanumManualMode.cpp b/src/modules/rover_mecanum/MecanumDriveModes/MecanumManualMode/MecanumManualMode.cpp index e868327fbf5..fcb89a445c8 100644 --- a/src/modules/rover_mecanum/MecanumDriveModes/MecanumManualMode/MecanumManualMode.cpp +++ b/src/modules/rover_mecanum/MecanumDriveModes/MecanumManualMode/MecanumManualMode.cpp @@ -49,7 +49,7 @@ MecanumManualMode::MecanumManualMode(ModuleParams *parent) : ModuleParams(parent void MecanumManualMode::updateParams() { ModuleParams::updateParams(); - _max_yaw_rate = _param_ro_yaw_rate_limit.get() * M_DEG_TO_RAD_F; + _max_yaw_rate = _param_ro_yaw_rate_lim.get() * M_DEG_TO_RAD_F; } void MecanumManualMode::manual() @@ -180,9 +180,9 @@ void MecanumManualMode::position() Vector3f velocity_setpoint_body{}; velocity_setpoint_body(0) = math::interpolate(sticks.forward, - -1.f, 1.f, -_param_ro_speed_limit.get(), _param_ro_speed_limit.get()); + -1.f, 1.f, -_param_ro_speed_lim.get(), _param_ro_speed_lim.get()); velocity_setpoint_body(1) = math::interpolate(sticks.lateral, - -1.f, 1.f, -_param_ro_speed_limit.get(), _param_ro_speed_limit.get()); + -1.f, 1.f, -_param_ro_speed_lim.get(), _param_ro_speed_lim.get()); velocity_setpoint_body(2) = 0.f; if (fabsf(sticks.yaw) > FLT_EPSILON || velocity_setpoint_body.norm() < FLT_EPSILON) { diff --git a/src/modules/rover_mecanum/MecanumDriveModes/MecanumManualMode/MecanumManualMode.hpp b/src/modules/rover_mecanum/MecanumDriveModes/MecanumManualMode/MecanumManualMode.hpp index 49cc14a31da..04e8ee1eb1b 100644 --- a/src/modules/rover_mecanum/MecanumDriveModes/MecanumManualMode/MecanumManualMode.hpp +++ b/src/modules/rover_mecanum/MecanumDriveModes/MecanumManualMode/MecanumManualMode.hpp @@ -132,13 +132,13 @@ private: float _max_yaw_rate{NAN}; DEFINE_PARAMETERS( - (ParamFloat) _param_ro_yaw_rate_limit, + (ParamFloat) _param_ro_yaw_rate_lim, (ParamFloat) _param_ro_yaw_stick_dz, (ParamFloat) _param_ro_yaw_expo, (ParamFloat) _param_ro_yaw_supexpo, (ParamFloat) _param_rm_yaw_stk_gain, (ParamFloat) _param_ro_park_thr_max, - (ParamFloat) _param_ro_speed_limit, + (ParamFloat) _param_ro_speed_lim, (ParamFloat) _param_rm_course_ctl_th, (ParamFloat) _param_pp_lookahd_max, (ParamInt) _param_ro_stick_map diff --git a/src/modules/rover_mecanum/MecanumPosControl/MecanumPosControl.cpp b/src/modules/rover_mecanum/MecanumPosControl/MecanumPosControl.cpp index b8ff7cc9744..c7add4409f0 100644 --- a/src/modules/rover_mecanum/MecanumPosControl/MecanumPosControl.cpp +++ b/src/modules/rover_mecanum/MecanumPosControl/MecanumPosControl.cpp @@ -72,9 +72,9 @@ void MecanumPosControl::updatePosControl() float speed_setpoint{_cruising_speed}; - if (!course_control && _param_ro_decel_limit.get() > FLT_EPSILON && _param_ro_jerk_limit.get() > FLT_EPSILON) { - speed_setpoint = math::min(math::trajectory::computeMaxSpeedFromDistance(_param_ro_jerk_limit.get(), - _param_ro_decel_limit.get(), distance_to_target, fabsf(_arrival_speed)), _cruising_speed); + if (!course_control && _param_ro_decel_lim.get() > FLT_EPSILON && _param_ro_jerk_lim.get() > FLT_EPSILON) { + speed_setpoint = math::min(math::trajectory::computeMaxSpeedFromDistance(_param_ro_jerk_lim.get(), + _param_ro_decel_lim.get(), distance_to_target, fabsf(_arrival_speed)), _cruising_speed); } // The speed controller tracks the ground velocity in body frame, so a velocity along the course setpoint needs no drift angle correction @@ -146,7 +146,7 @@ void MecanumPosControl::updateSubscriptions() _start_ned = _start_ned.isAllFinite() ? _start_ned : _curr_pos_ned; _arrival_speed = PX4_ISFINITE(surface_vehicle_position_setpoint.arrival_speed) ? surface_vehicle_position_setpoint.arrival_speed : 0.f; _cruising_speed = PX4_ISFINITE(surface_vehicle_position_setpoint.cruising_speed) ? surface_vehicle_position_setpoint.cruising_speed : - _param_ro_speed_limit.get(); + _param_ro_speed_lim.get(); _target_waypoint_ned = Vector2f(surface_vehicle_position_setpoint.target_ned[0], surface_vehicle_position_setpoint.target_ned[1]); _course = NAN; _stopped = false; @@ -158,7 +158,7 @@ void MecanumPosControl::updateSubscriptions() _start_ned = Vector2f(NAN, NAN); _arrival_speed = 0.f; _cruising_speed = PX4_ISFINITE(surface_vehicle_course_setpoint.speed) ? - surface_vehicle_course_setpoint.speed : _param_ro_speed_limit.get(); + surface_vehicle_course_setpoint.speed : _param_ro_speed_lim.get(); _target_waypoint_ned = Vector2f(NAN, NAN); _course = surface_vehicle_course_setpoint.course; _stopped = false; @@ -169,11 +169,11 @@ bool MecanumPosControl::runSanityChecks() { bool ret = true; - if (_param_ro_yaw_rate_limit.get() < FLT_EPSILON) { + if (_param_ro_yaw_rate_lim.get() < FLT_EPSILON) { ret = false; } - if (_param_ro_speed_limit.get() < FLT_EPSILON) { + if (_param_ro_speed_lim.get() < FLT_EPSILON) { ret = false; } diff --git a/src/modules/rover_mecanum/MecanumPosControl/MecanumPosControl.hpp b/src/modules/rover_mecanum/MecanumPosControl/MecanumPosControl.hpp index c931a8f0f42..9aaeaac1027 100644 --- a/src/modules/rover_mecanum/MecanumPosControl/MecanumPosControl.hpp +++ b/src/modules/rover_mecanum/MecanumPosControl/MecanumPosControl.hpp @@ -84,7 +84,7 @@ public: /** * @brief Reset position controller. */ - void reset() {_start_ned = Vector2f{NAN, NAN}; _target_waypoint_ned = Vector2f{NAN, NAN}; _course = NAN; _arrival_speed = 0.f; _cruising_speed = _param_ro_speed_limit.get(); _stopped = false;}; + void reset() {_start_ned = Vector2f{NAN, NAN}; _target_waypoint_ned = Vector2f{NAN, NAN}; _course = NAN; _arrival_speed = 0.f; _cruising_speed = _param_ro_speed_lim.get(); _stopped = false;}; protected: @@ -132,15 +132,15 @@ private: (ParamFloat) _param_ro_speed_p, (ParamFloat) _param_ro_speed_i, (ParamFloat) _param_ro_yaw_stick_dz, - (ParamFloat) _param_ro_accel_limit, - (ParamFloat) _param_ro_decel_limit, - (ParamFloat) _param_ro_jerk_limit, - (ParamFloat) _param_ro_speed_limit, + (ParamFloat) _param_ro_accel_lim, + (ParamFloat) _param_ro_decel_lim, + (ParamFloat) _param_ro_jerk_lim, + (ParamFloat) _param_ro_speed_lim, (ParamFloat) _param_ro_speed_th, (ParamFloat) _param_pp_lookahd_gain, (ParamFloat) _param_pp_lookahd_max, (ParamFloat) _param_pp_lookahd_min, - (ParamFloat) _param_ro_yaw_rate_limit, + (ParamFloat) _param_ro_yaw_rate_lim, (ParamFloat) _param_ro_yaw_p, (ParamFloat) _param_nav_acc_rad ) diff --git a/src/modules/rover_mecanum/MecanumRateControl/MecanumRateControl.cpp b/src/modules/rover_mecanum/MecanumRateControl/MecanumRateControl.cpp index a9df78881c7..502a922253e 100644 --- a/src/modules/rover_mecanum/MecanumRateControl/MecanumRateControl.cpp +++ b/src/modules/rover_mecanum/MecanumRateControl/MecanumRateControl.cpp @@ -54,7 +54,7 @@ void MecanumRateControl::updateParams() _pid_yaw_rate.setOutputLimit(1.f); // Set up slew rate - _adjusted_yaw_rate_setpoint.setSlewRate(_param_ro_yaw_accel_limit.get() * M_DEG_TO_RAD_F); + _adjusted_yaw_rate_setpoint.setSlewRate(_param_ro_yaw_accel_lim.get() * M_DEG_TO_RAD_F); } void MecanumRateControl::updateRateControl() @@ -81,8 +81,8 @@ void MecanumRateControl::updateRateControl() _yaw_rate_setpoint : 0.f; const float speed_diff_normalized = RoverControl::rateControl(_adjusted_yaw_rate_setpoint, _pid_yaw_rate, yaw_rate_setpoint, _vehicle_yaw_rate, _param_ro_max_thr_speed.get(), _param_ro_yaw_rate_corr.get(), - _param_ro_yaw_accel_limit.get() * M_DEG_TO_RAD_F, - _param_ro_yaw_decel_limit.get() * M_DEG_TO_RAD_F, _param_rm_wheel_track.get(), dt); + _param_ro_yaw_accel_lim.get() * M_DEG_TO_RAD_F, + _param_ro_yaw_decel_lim.get() * M_DEG_TO_RAD_F, _param_rm_wheel_track.get(), dt); surface_vehicle_steering_setpoint_s surface_vehicle_steering_setpoint{}; surface_vehicle_steering_setpoint.timestamp = _timestamp; surface_vehicle_steering_setpoint.normalized_steering_setpoint = speed_diff_normalized; @@ -106,10 +106,10 @@ bool MecanumRateControl::runSanityChecks() { bool ret = true; - if (_param_ro_yaw_rate_limit.get() < FLT_EPSILON) { + if (_param_ro_yaw_rate_lim.get() < FLT_EPSILON) { ret = false; events::send(events::ID("mecanum_rate_control_conf_invalid_yaw_rate_lim"), events::Log::Error, - "Invalid configuration of necessary parameter RO_YAW_RATE_LIM", _param_ro_yaw_rate_limit.get()); + "Invalid configuration of necessary parameter RO_YAW_RATE_LIM", _param_ro_yaw_rate_lim.get()); } diff --git a/src/modules/rover_mecanum/MecanumRateControl/MecanumRateControl.hpp b/src/modules/rover_mecanum/MecanumRateControl/MecanumRateControl.hpp index 383e90e00fe..2643a0358d6 100644 --- a/src/modules/rover_mecanum/MecanumRateControl/MecanumRateControl.hpp +++ b/src/modules/rover_mecanum/MecanumRateControl/MecanumRateControl.hpp @@ -111,12 +111,12 @@ private: DEFINE_PARAMETERS( (ParamFloat) _param_rm_wheel_track, (ParamFloat) _param_ro_max_thr_speed, - (ParamFloat) _param_ro_yaw_rate_limit, + (ParamFloat) _param_ro_yaw_rate_lim, (ParamFloat) _param_ro_yaw_rate_th, (ParamFloat) _param_ro_yaw_rate_p, (ParamFloat) _param_ro_yaw_rate_i, - (ParamFloat) _param_ro_yaw_accel_limit, - (ParamFloat) _param_ro_yaw_decel_limit, + (ParamFloat) _param_ro_yaw_accel_lim, + (ParamFloat) _param_ro_yaw_decel_lim, (ParamFloat) _param_ro_yaw_rate_corr ) }; diff --git a/src/modules/rover_mecanum/MecanumSpeedControl/MecanumSpeedControl.cpp b/src/modules/rover_mecanum/MecanumSpeedControl/MecanumSpeedControl.cpp index af266958dc3..90c1ca6c3fc 100644 --- a/src/modules/rover_mecanum/MecanumSpeedControl/MecanumSpeedControl.cpp +++ b/src/modules/rover_mecanum/MecanumSpeedControl/MecanumSpeedControl.cpp @@ -57,9 +57,9 @@ void MecanumSpeedControl::updateParams() _pid_speed_y.setOutputLimit(1.f); // Set up slew rates - if (_param_ro_accel_limit.get() > FLT_EPSILON) { - _adjusted_speed_x_setpoint.setSlewRate(_param_ro_accel_limit.get()); - _adjusted_speed_y_setpoint.setSlewRate(_param_ro_accel_limit.get()); + if (_param_ro_accel_lim.get() > FLT_EPSILON) { + _adjusted_speed_x_setpoint.setSlewRate(_param_ro_accel_lim.get()); + _adjusted_speed_y_setpoint.setSlewRate(_param_ro_accel_lim.get()); } } @@ -79,10 +79,10 @@ void MecanumSpeedControl::updateSpeedControl() surface_vehicle_thrust_setpoint.timestamp = _timestamp; surface_vehicle_thrust_setpoint.x = RoverControl::speedControl(_adjusted_speed_x_setpoint, _pid_speed_x, - speed_setpoint(0), _vehicle_speed_body_x, _param_ro_accel_limit.get(), _param_ro_decel_limit.get(), + speed_setpoint(0), _vehicle_speed_body_x, _param_ro_accel_lim.get(), _param_ro_decel_lim.get(), _param_ro_max_thr_speed.get(), dt); surface_vehicle_thrust_setpoint.y = RoverControl::speedControl(_adjusted_speed_y_setpoint, _pid_speed_y, - speed_setpoint(1), _vehicle_speed_body_y, _param_ro_accel_limit.get(), _param_ro_decel_limit.get(), + speed_setpoint(1), _vehicle_speed_body_y, _param_ro_accel_lim.get(), _param_ro_decel_lim.get(), _param_ro_max_thr_speed.get(), dt); _surface_vehicle_thrust_setpoint_pub.publish(surface_vehicle_thrust_setpoint); @@ -168,10 +168,10 @@ bool MecanumSpeedControl::runSanityChecks() { bool ret = true; - if (_param_ro_speed_limit.get() < FLT_EPSILON) { + if (_param_ro_speed_lim.get() < FLT_EPSILON) { ret = false; events::send(events::ID("mecanum_vel_control_conf_invalid_speed_lim"), events::Log::Error, - "Invalid configuration of necessary parameter RO_SPEED_LIM", _param_ro_speed_limit.get()); + "Invalid configuration of necessary parameter RO_SPEED_LIM", _param_ro_speed_lim.get()); } diff --git a/src/modules/rover_mecanum/MecanumSpeedControl/MecanumSpeedControl.hpp b/src/modules/rover_mecanum/MecanumSpeedControl/MecanumSpeedControl.hpp index 4f9b5a1f8c3..af6259a9186 100644 --- a/src/modules/rover_mecanum/MecanumSpeedControl/MecanumSpeedControl.hpp +++ b/src/modules/rover_mecanum/MecanumSpeedControl/MecanumSpeedControl.hpp @@ -137,10 +137,10 @@ private: (ParamFloat) _param_ro_max_thr_speed, (ParamFloat) _param_ro_speed_p, (ParamFloat) _param_ro_speed_i, - (ParamFloat) _param_ro_accel_limit, - (ParamFloat) _param_ro_decel_limit, - (ParamFloat) _param_ro_jerk_limit, - (ParamFloat) _param_ro_speed_limit, + (ParamFloat) _param_ro_accel_lim, + (ParamFloat) _param_ro_decel_lim, + (ParamFloat) _param_ro_jerk_lim, + (ParamFloat) _param_ro_speed_lim, (ParamFloat) _param_ro_speed_th ) }; diff --git a/src/modules/sensors/sensor_params_flow.yaml b/src/modules/sensors/sensor_params_flow.yaml index e9ebbbf141a..a6074193064 100644 --- a/src/modules/sensors/sensor_params_flow.yaml +++ b/src/modules/sensors/sensor_params_flow.yaml @@ -1,10 +1,70 @@ +__max_num_flow_instances: &max_num_flow_instances 2 + module_name: sensors parameters: - group: Sensor Calibration definitions: - SENS_FLOW_MINHGT: + SENS_FLOW${i}_ID: description: - short: Minimum height above ground when reliant on optical flow + short: Optical flow sensor ${i} ID + long: 'Device ID of the flow sensor configured by the SENS_FLOW${i}_* + parameters. Set to 0 to automatically bind the first unbound sensor + reporting data.' + type: int32 + default: 0 + reboot_required: true + num_instances: *max_num_flow_instances + instance_start: 0 + SENS_FLOW${i}_DELAY: + description: + short: Optical flow sensor ${i} measurement delay relative to IMU + long: |- + Assumes measurement is timestamped at trailing edge of integration + period. Applied to timestamp_sample of the published data. The default + matches a DroneCAN flow node, whose frame reaches the flight controller + about 7 ms after its integration window closes. + type: float + default: 7.0 + min: 0 + max: 300 + unit: ms + reboot_required: true + decimal: 1 + num_instances: *max_num_flow_instances + instance_start: 0 + SENS_FLOW${i}_POS_X: + description: + short: X position of optical flow sensor ${i} focal point in body frame + long: Forward axis with origin relative to vehicle centre of gravity + type: float + default: 0.0 + unit: m + decimal: 3 + num_instances: *max_num_flow_instances + instance_start: 0 + SENS_FLOW${i}_POS_Y: + description: + short: Y position of optical flow sensor ${i} focal point in body frame + long: Right axis with origin relative to vehicle centre of gravity + type: float + default: 0.0 + unit: m + decimal: 3 + num_instances: *max_num_flow_instances + instance_start: 0 + SENS_FLOW${i}_POS_Z: + description: + short: Z position of optical flow sensor ${i} focal point in body frame + long: Down axis with origin relative to vehicle centre of gravity + type: float + default: 0.0 + unit: m + decimal: 3 + num_instances: *max_num_flow_instances + instance_start: 0 + SENS_FLOW${i}_HMIN: + description: + short: Minimum height above ground when reliant on optical flow ${i} long: |- This parameter defines the minimum distance from ground at which the optical flow sensor operates reliably. The sensor may be usable below this height, but accuracy will progressively reduce to loss of focus. @@ -15,9 +75,11 @@ parameters: max: 1.0 increment: 0.1 decimal: 2 - SENS_FLOW_MAXHGT: + num_instances: *max_num_flow_instances + instance_start: 0 + SENS_FLOW${i}_HMAX: description: - short: Maximum height above ground when reliant on optical flow + short: Maximum height above ground when reliant on optical flow ${i} long: |- This parameter defines the maximum distance from ground at which the optical flow sensor operates reliably. The height setpoint will be limited to be no greater than this value when the navigation system @@ -30,9 +92,11 @@ parameters: max: 100.0 increment: 0.1 decimal: 2 - SENS_FLOW_MAXR: + num_instances: *max_num_flow_instances + instance_start: 0 + SENS_FLOW${i}_MAXR: description: - short: Max angular flow rate measurable by sensor + short: Max angular flow rate measurable by sensor ${i} long: |- Magnitude of maximum angular flow rate reliably measurable by the optical flow sensor @@ -44,11 +108,13 @@ parameters: unit: rad/s min: 1.0 decimal: 2 + num_instances: *max_num_flow_instances + instance_start: 0 - group: Sensors definitions: - SENS_FLOW_ROT: + SENS_FLOW${i}_ROT: description: - short: Optical flow rotation + short: Optical flow ${i} rotation long: |- This parameter defines the yaw rotation of the optical flow relative to the vehicle body frame. Zero rotation is defined as X on flow board pointing towards front of vehicle. @@ -63,9 +129,11 @@ parameters: 6: "Yaw 270\xB0" 7: "Yaw 315\xB0" default: 0 - SENS_FLOW_RATE: + num_instances: *max_num_flow_instances + instance_start: 0 + SENS_FLOW${i}_RATE: description: - short: Optical flow max rate + short: Optical flow ${i} max rate long: |- Optical flow data maximum publication rate. This is an upper bound, actual optical flow data rate is still dependent on the sensor. @@ -75,11 +143,15 @@ parameters: max: 200 unit: Hz reboot_required: true - SENS_FLOW_SCALE: + num_instances: *max_num_flow_instances + instance_start: 0 + SENS_FLOW${i}_SCALE: description: - short: Optical flow scale factor + short: Optical flow ${i} scale factor type: float default: 1.0 min: 0.5 max: 1.5 decimal: 2 + num_instances: *max_num_flow_instances + instance_start: 0 diff --git a/src/modules/sensors/sensor_params_mag.yaml b/src/modules/sensors/sensor_params_mag.yaml index 85c0dbc6b55..c4196636d84 100644 --- a/src/modules/sensors/sensor_params_mag.yaml +++ b/src/modules/sensors/sensor_params_mag.yaml @@ -79,8 +79,7 @@ parameters: short: Magnetometer auto calibration long: Automatically initialize magnetometer calibration from bias estimate if available. The estimate only captures hard-iron offsets, so a full - calibration is still recommended. Mainly intended for remote nodes - (e.g. CAN GPS units) that cannot be calibrated from a ground station. + calibration is still recommended. category: System type: boolean default: 0 diff --git a/src/modules/sensors/sensors.cpp b/src/modules/sensors/sensors.cpp index 4d109412993..7292031b803 100644 --- a/src/modules/sensors/sensors.cpp +++ b/src/modules/sensors/sensors.cpp @@ -68,6 +68,10 @@ Sensors::Sensors(bool hil_enabled) : _vehicle_angular_velocity.Start(); #endif // CONFIG_SENSORS_VEHICLE_ANGULAR_VELOCITY +#if defined(CONFIG_SENSORS_VEHICLE_OPTICAL_FLOW) + _flow_slot_binder.init("SENS_FLOW%u_ID", VehicleOpticalFlow::MAX_FLOW_INSTANCES); +#endif // CONFIG_SENSORS_VEHICLE_OPTICAL_FLOW + param_find("SYS_FAC_CAL_MODE"); // Parameters controlling the on-board sensor thermal calibrator @@ -137,9 +141,11 @@ Sensors::~Sensors() #if defined(CONFIG_SENSORS_VEHICLE_OPTICAL_FLOW) - if (_vehicle_optical_flow) { - _vehicle_optical_flow->Stop(); - delete _vehicle_optical_flow; + for (auto &vehicle_optical_flow : _vehicle_optical_flow) { + if (vehicle_optical_flow) { + vehicle_optical_flow->Stop(); + delete vehicle_optical_flow; + } } #endif // CONFIG_SENSORS_VEHICLE_OPTICAL_FLOW @@ -433,14 +439,16 @@ void Sensors::InitializeVehicleMagnetometer() #if defined(CONFIG_SENSORS_VEHICLE_OPTICAL_FLOW) void Sensors::InitializeVehicleOpticalFlow() { - if (_vehicle_optical_flow == nullptr) { - uORB::Subscription sensor_optical_flow_sub{ORB_ID(sensor_optical_flow)}; + for (uint8_t i = 0; i < VehicleOpticalFlow::MAX_FLOW_INSTANCES; i++) { + if (_vehicle_optical_flow[i] == nullptr) { + uORB::Subscription sensor_optical_flow_sub{ORB_ID(sensor_optical_flow), i}; - if (sensor_optical_flow_sub.advertised()) { - _vehicle_optical_flow = new VehicleOpticalFlow(); + if (sensor_optical_flow_sub.advertised()) { + _vehicle_optical_flow[i] = new VehicleOpticalFlow(i, _flow_slot_binder, _vehicle_optical_flow_pubs); - if (_vehicle_optical_flow) { - _vehicle_optical_flow->Start(); + if (_vehicle_optical_flow[i]) { + _vehicle_optical_flow[i]->Start(); + } } } } @@ -669,9 +677,11 @@ int Sensors::print_status() #if defined(CONFIG_SENSORS_VEHICLE_OPTICAL_FLOW) - if (_vehicle_optical_flow) { - PX4_INFO_RAW("\n"); - _vehicle_optical_flow->PrintStatus(); + for (auto &vehicle_optical_flow : _vehicle_optical_flow) { + if (vehicle_optical_flow) { + PX4_INFO_RAW("\n"); + vehicle_optical_flow->PrintStatus(); + } } #endif // CONFIG_SENSORS_VEHICLE_OPTICAL_FLOW diff --git a/src/modules/sensors/sensors.hpp b/src/modules/sensors/sensors.hpp index a588bdee317..be7fafb385f 100644 --- a/src/modules/sensors/sensors.hpp +++ b/src/modules/sensors/sensors.hpp @@ -212,7 +212,9 @@ private: #endif // CONFIG_SENSORS_VEHICLE_GPS_POSITION #if defined(CONFIG_SENSORS_VEHICLE_OPTICAL_FLOW) - VehicleOpticalFlow *_vehicle_optical_flow {nullptr}; + VehicleOpticalFlow *_vehicle_optical_flow[VehicleOpticalFlow::MAX_FLOW_INSTANCES] {}; + SensorSlotBinder _flow_slot_binder{}; + VehicleOpticalFlow::Publications _vehicle_optical_flow_pubs{}; uint8_t _n_optical_flow{0}; #endif // CONFIG_SENSORS_VEHICLE_OPTICAL_FLOW diff --git a/src/modules/sensors/vehicle_air_data/VehicleAirData.cpp b/src/modules/sensors/vehicle_air_data/VehicleAirData.cpp index f92015a2c88..5714445e01f 100644 --- a/src/modules/sensors/vehicle_air_data/VehicleAirData.cpp +++ b/src/modules/sensors/vehicle_air_data/VehicleAirData.cpp @@ -262,6 +262,22 @@ void VehicleAirData::Run() } } + vehicle_status_s vehicle_status; + + if (_vehicle_status_sub.update(&vehicle_status)) { + _armed = (vehicle_status.arming_state == vehicle_status_s::ARMING_STATE_ARMED); + } + + vehicle_command_s vehicle_command; + + while (_vehicle_command_sub.update(&vehicle_command)) { + // an externally set altitude overrides the GNSS one + if (vehicle_command.command == vehicle_command_s::VEHICLE_CMD_EXTERNAL_POSITION_ESTIMATE + && PX4_ISFINITE(vehicle_command.param7)) { + _external_altitude_set = true; + } + } + estimator_status_flags_s latest_estimator_status_flags; bool baro_gnss_calibration_running = false; @@ -270,9 +286,14 @@ void VehicleAirData::Run() if (!_relative_calibration_done) { _relative_calibration_done = UpdateRelativeCalibrations(time_now_us); - } else if (!_baro_gnss_calibration_done && _param_sens_baro_autocal.get() && latest_estimator_status_flags.cs_gps_hgt) { + } else if (_param_sens_bar_autocal.get() && latest_estimator_status_flags.cs_gps_hgt + && (!_armed || !_baro_gnss_calibration_done) && !_external_altitude_set) { + // first calibration may complete armed, later drift is only tracked while disarmed baro_gnss_calibration_running = true; - _baro_gnss_calibration_done = BaroGNSSAltitudeOffset(); + + if (BaroGNSSAltitudeOffset()) { + _baro_gnss_calibration_done = true; + } } } @@ -522,6 +543,12 @@ bool VehicleAirData::BaroGNSSAltitudeOffset() { static constexpr float kDeltaOffsetTolerance = 4.f; static constexpr uint64_t kLpfWindow = 2_s; + // time constant of the baro-GNSS offset filter after the first calibration + static constexpr uint64_t kTrackingTimeConstant = 5_s; + // wait after a filter reset before evaluating the offset, 3 time constants = 95% settled + static constexpr uint64_t kTrackingSettleTime = 3 * kTrackingTimeConstant; + // recalibrate when the filtered baro-GNSS offset exceeds this + static constexpr float kTrackingThreshold = 0.5f; vehicle_gnss_s vehicle_gnss; @@ -532,9 +559,9 @@ bool VehicleAirData::BaroGNSSAltitudeOffset() const float pressure_sealevel = _param_sens_baro_qnh.get() * 100.0f; const float baro_pressure = _data_sum[_selected_sensor_sub_index] / _data_sum_count[_selected_sensor_sub_index]; - const float target_altitude = static_cast(vehicle_gnss.receiver.altitude_msl); + const float baro_altitude = getAltitudeFromPressure(baro_pressure, pressure_sealevel); - const float delta_alt = getAltitudeFromPressure(baro_pressure, pressure_sealevel) - target_altitude; + const float delta_alt = baro_altitude - static_cast(vehicle_gnss.receiver.altitude_msl); bool gnss_baro_offset_stable = false; if (vehicle_gnss.failed_strict_checks || _t_first_gnss_sample == 0) { @@ -546,14 +573,19 @@ bool VehicleAirData::BaroGNSSAltitudeOffset() if (_calibration_t_first == 0) { _calibration_t_first = vehicle_gnss.timestamp; - _delta_baro_gnss_lpf.setParameters(_calibration_t_first - _t_first_gnss_sample, kLpfWindow); + _delta_baro_gnss_lpf.setParameters(_calibration_t_first - _t_first_gnss_sample, + _baro_gnss_calibration_done ? kTrackingTimeConstant : kLpfWindow); _delta_baro_gnss_lpf.reset(delta_alt); } else { _delta_baro_gnss_lpf.update(delta_alt); } - if (vehicle_gnss.timestamp - _calibration_t_first > kLpfWindow && !PX4_ISFINITE(_baro_gnss_offset_t1)) { + if (_baro_gnss_calibration_done) { + gnss_baro_offset_stable = (vehicle_gnss.timestamp - _calibration_t_first > kTrackingSettleTime) + && (fabsf(_delta_baro_gnss_lpf.getState()) > kTrackingThreshold); + + } else if (vehicle_gnss.timestamp - _calibration_t_first > kLpfWindow && !PX4_ISFINITE(_baro_gnss_offset_t1)) { _baro_gnss_offset_t1 = _delta_baro_gnss_lpf.getState(); } else if (vehicle_gnss.timestamp - _calibration_t_first > 2 * kLpfWindow && PX4_ISFINITE(_baro_gnss_offset_t1)) { @@ -571,6 +603,11 @@ bool VehicleAirData::BaroGNSSAltitudeOffset() return false; } + // next check starts a new window + _t_first_gnss_sample = 0; + + const float target_altitude = baro_altitude - _delta_baro_gnss_lpf.getState(); + // Binary search float low = -10000.0f; float high = 10000.0f; @@ -594,12 +631,20 @@ bool VehicleAirData::BaroGNSSAltitudeOffset() } } - // add new offset to existing relative offsets + if (!PX4_ISFINITE(offset)) { + return false; + } + + // add new offset to existing relative offsets, also of a sensor without a sample since the last publication for (int instance = 0; instance < MAX_SENSOR_COUNT; ++instance) { - if (_calibration[instance].device_id() != 0 && _data_sum_count[instance] > 0) { + if (_calibration[instance].device_id() != 0) { _calibration[instance].set_offset(_calibration[instance].offset() + offset); _calibration[instance].ParametersSave(instance); param_notify_changes(); + + // apply to samples accumulated with the old offset + _data_sum[instance] -= offset * _data_sum_count[instance]; + _last_data[instance] -= offset; } } diff --git a/src/modules/sensors/vehicle_air_data/VehicleAirData.hpp b/src/modules/sensors/vehicle_air_data/VehicleAirData.hpp index 1928807e94a..d579f76fcdb 100644 --- a/src/modules/sensors/vehicle_air_data/VehicleAirData.hpp +++ b/src/modules/sensors/vehicle_air_data/VehicleAirData.hpp @@ -56,7 +56,9 @@ #include #include #include +#include #include +#include using namespace time_literals; @@ -116,6 +118,8 @@ private: }; uORB::Subscription _vehicle_gnss_sub{ORB_ID(vehicle_gnss)}; + uORB::Subscription _vehicle_command_sub{ORB_ID(vehicle_command)}; + uORB::Subscription _vehicle_status_sub{ORB_ID(vehicle_status)}; calibration::Barometer _calibration[MAX_SENSOR_COUNT]; @@ -143,6 +147,8 @@ private: int8_t _selected_sensor_sub_index{-1}; bool _last_status_baro_fault{false}; + bool _armed{false}; + bool _external_altitude_set{false}; bool _relative_calibration_done{false}; bool _baro_gnss_calibration_done{false}; @@ -154,7 +160,7 @@ private: DEFINE_PARAMETERS( (ParamFloat) _param_sens_baro_qnh, (ParamFloat) _param_sens_baro_rate, - (ParamBool) _param_sens_baro_autocal + (ParamBool) _param_sens_bar_autocal ) }; }; // namespace sensors diff --git a/src/modules/sensors/vehicle_air_data/params.yaml b/src/modules/sensors/vehicle_air_data/params.yaml index bfdf106ada4..6a95e685de0 100644 --- a/src/modules/sensors/vehicle_air_data/params.yaml +++ b/src/modules/sensors/vehicle_air_data/params.yaml @@ -24,7 +24,9 @@ parameters: SENS_BAR_AUTOCAL: description: short: Barometer auto calibration - long: Automatically calibrate barometer based on the GNSS height + long: |- + Automatically calibrate barometer based on the GNSS height. + Keeps recalibrating while landed and disarmed when the baro drifts away from the GNSS height. category: System type: boolean default: 1 diff --git a/src/modules/sensors/vehicle_air_data/test/VehicleAirDataTest.cpp b/src/modules/sensors/vehicle_air_data/test/VehicleAirDataTest.cpp index b1ab60ef6b0..54873007458 100644 --- a/src/modules/sensors/vehicle_air_data/test/VehicleAirDataTest.cpp +++ b/src/modules/sensors/vehicle_air_data/test/VehicleAirDataTest.cpp @@ -48,7 +48,9 @@ #include #include #include +#include #include +#include #include class VehicleAirDataTest : public ::testing::Test @@ -165,6 +167,26 @@ public: _vehicle_gnss_pub.publish(gnss); } + static void publishExternalPositionEstimate(float altitude) + { + vehicle_command_s command{}; + command.timestamp = hrt_absolute_time(); + command.command = vehicle_command_s::VEHICLE_CMD_EXTERNAL_POSITION_ESTIMATE; + command.param2 = 0.f; + command.param5 = 47.; + command.param6 = 8.; + command.param7 = altitude; + _vehicle_command_pub.publish(command); + } + + static void publishVehicleStatus(bool armed) + { + vehicle_status_s status{}; + status.timestamp = hrt_absolute_time(); + status.arming_state = armed ? vehicle_status_s::ARMING_STATE_ARMED : vehicle_status_s::ARMING_STATE_DISARMED; + _vehicle_status_pub.publish(status); + } + // a run of GNSS samples 100 ms apart, all with the same solution and estimator state struct GnssSegment { int samples; @@ -172,6 +194,9 @@ public: uint16_t failed_strict_checks; bool in_air = false; bool gnss_height_fused = true; + bool armed = false; + // sent with the first sample, NAN for none + float external_altitude = NAN; }; // brings the module up on the given altitude, then feeds it the given GNSS segments in order, and returns @@ -192,6 +217,7 @@ public: runFor(module, 1500_ms, [&]() { publishSample(0, noisy_pressure()); publishEstimatorStatusFlags(); + publishVehicleStatus(false); }); EXPECT_EQ(module.selectedIndex(), 0); @@ -204,6 +230,12 @@ public: gnss_timestamp += 100_ms; publishSample(0, noisy_pressure()); publishEstimatorStatusFlags(segment.in_air, segment.gnss_height_fused); + publishVehicleStatus(segment.armed); + + if ((i == 0) && PX4_ISFINITE(segment.external_altitude)) { + publishExternalPositionEstimate(segment.external_altitude); + } + publishGnss(gnss_timestamp, segment.altitude_msl, segment.failed_strict_checks); module.RunPublic(); px4_usleep(5_ms); @@ -237,6 +269,8 @@ public: static uORB::Publication _parameter_update_pub; static uORB::Publication _estimator_status_flags_pub; static uORB::Publication _vehicle_gnss_pub; + static uORB::Publication _vehicle_status_pub; + static uORB::Publication _vehicle_command_pub; static constexpr const char *kOffsetParams[kSensorCount] {"CAL_BARO0_OFF"}; @@ -249,6 +283,8 @@ uORB::PublicationMulti VehicleAirDataTest::_sensor_baro_pubs[kSen uORB::Publication VehicleAirDataTest::_parameter_update_pub{ORB_ID(parameter_update)}; uORB::Publication VehicleAirDataTest::_estimator_status_flags_pub{ORB_ID(estimator_status_flags)}; uORB::Publication VehicleAirDataTest::_vehicle_gnss_pub{ORB_ID(vehicle_gnss)}; +uORB::Publication VehicleAirDataTest::_vehicle_status_pub{ORB_ID(vehicle_status)}; +uORB::Publication VehicleAirDataTest::_vehicle_command_pub{ORB_ID(vehicle_command)}; constexpr const char *VehicleAirDataTest::kOffsetParams[]; TEST_F(VehicleAirDataTest, BarometerDisabledFromBootDoesNotDriveRun) @@ -352,3 +388,38 @@ TEST_F(VehicleAirDataTest, GnssBaroCalibrationCompletesAfterFlight) EXPECT_GT(offset, 150.f); EXPECT_LT(offset, 210.f); } + +TEST_F(VehicleAirDataTest, GnssBaroCalibrationCompletesWhileArmedOnGround) +{ + // arming before the first calibration does not hold it back + const float offset = runGnssCalibration({{60, 15., 0, false, true, true}}); + + EXPECT_GT(offset, 150.f); + EXPECT_LT(offset, 210.f); +} + +TEST_F(VehicleAirDataTest, GnssBaroCalibrationTracksBaroDriftUntilArmed) +{ + // a steady 1.5 m drift on the ground is recalibrated onto 16.5 m, drift while armed is ignored + const float offset = runGnssCalibration({ + {60, 15., 0}, + {300, 16.5, 0}, + {300, 25., 0, false, true, true}, + }); + + // roughly 12 Pa per metre + EXPECT_GT(offset, 194.f); + EXPECT_LT(offset, 204.f); +} + +TEST_F(VehicleAirDataTest, GnssBaroCalibrationStopsTrackingAfterExternalAltitude) +{ + // an externally set altitude stops the tracking, the calibration stays on 15 m + const float offset = runGnssCalibration({ + {60, 15., 0}, + {300, 25., 0, false, true, false, 30.f}, + }); + + EXPECT_GT(offset, 150.f); + EXPECT_LT(offset, 210.f); +} diff --git a/src/modules/sensors/vehicle_imu/VehicleIMU.cpp b/src/modules/sensors/vehicle_imu/VehicleIMU.cpp index 00063ddf7a3..6cd51eebe4b 100644 --- a/src/modules/sensors/vehicle_imu/VehicleIMU.cpp +++ b/src/modules/sensors/vehicle_imu/VehicleIMU.cpp @@ -124,7 +124,7 @@ bool VehicleIMU::ParametersUpdate(bool force) _accel_calibration.ParametersUpdate(); _gyro_calibration.ParametersUpdate(); - _notify_clipping = _param_sens_imu_notify_clipping.get(); + _notify_clipping = _param_sens_imu_clpnoti.get(); if (accel_calibration_count != _accel_calibration.calibration_count()) { // if calibration changed reset any existing learned calibration diff --git a/src/modules/sensors/vehicle_imu/VehicleIMU.hpp b/src/modules/sensors/vehicle_imu/VehicleIMU.hpp index 689d72f6142..cae683bc9b7 100644 --- a/src/modules/sensors/vehicle_imu/VehicleIMU.hpp +++ b/src/modules/sensors/vehicle_imu/VehicleIMU.hpp @@ -201,7 +201,7 @@ private: DEFINE_PARAMETERS( (ParamInt) _param_imu_integ_rate, (ParamBool) _param_sens_imu_autocal, - (ParamBool) _param_sens_imu_notify_clipping + (ParamBool) _param_sens_imu_clpnoti ) }; diff --git a/src/modules/sensors/vehicle_magnetometer/VehicleMagnetometer.cpp b/src/modules/sensors/vehicle_magnetometer/VehicleMagnetometer.cpp index 02b11180160..6c862cad561 100644 --- a/src/modules/sensors/vehicle_magnetometer/VehicleMagnetometer.cpp +++ b/src/modules/sensors/vehicle_magnetometer/VehicleMagnetometer.cpp @@ -112,7 +112,7 @@ bool VehicleMagnetometer::ParametersUpdate(bool force) } // Mag compensation type - MagCompensationType mag_comp_typ = static_cast(_param_mag_comp_typ.get()); + MagCompensationType mag_comp_typ = static_cast(_param_cal_mag_comp_typ.get()); if (mag_comp_typ != _mag_comp_type) { // check mag power compensation type (change battery current subscription instance if necessary) diff --git a/src/modules/sensors/vehicle_magnetometer/VehicleMagnetometer.hpp b/src/modules/sensors/vehicle_magnetometer/VehicleMagnetometer.hpp index 6642c474d69..4b2ed2441c4 100644 --- a/src/modules/sensors/vehicle_magnetometer/VehicleMagnetometer.hpp +++ b/src/modules/sensors/vehicle_magnetometer/VehicleMagnetometer.hpp @@ -183,7 +183,7 @@ private: bool _armed{false}; DEFINE_PARAMETERS( - (ParamInt) _param_mag_comp_typ, + (ParamInt) _param_cal_mag_comp_typ, (ParamBool) _param_sens_mag_mode, (ParamFloat) _param_sens_mag_rate, (ParamBool) _param_sens_mag_autocal, diff --git a/src/modules/sensors/vehicle_optical_flow/VehicleOpticalFlow.cpp b/src/modules/sensors/vehicle_optical_flow/VehicleOpticalFlow.cpp index f53d94a6e7d..fe02fbfd8fd 100644 --- a/src/modules/sensors/vehicle_optical_flow/VehicleOpticalFlow.cpp +++ b/src/modules/sensors/vehicle_optical_flow/VehicleOpticalFlow.cpp @@ -43,12 +43,13 @@ using namespace time_literals; static constexpr uint32_t SENSOR_TIMEOUT{300_ms}; -VehicleOpticalFlow::VehicleOpticalFlow() : - ModuleParams(nullptr), - ScheduledWorkItem(MODULE_NAME, px4::wq_configurations::nav_and_controllers) +VehicleOpticalFlow::VehicleOpticalFlow(uint8_t instance, SensorSlotBinder &slot_binder, Publications &pubs) : + ScheduledWorkItem(MODULE_NAME, px4::wq_configurations::nav_and_controllers), + _pubs(pubs), + _sensor_flow_sub(this, ORB_ID(sensor_optical_flow), instance), + _instance(instance), + _slot_binder(slot_binder) { - _vehicle_optical_flow_pub.advertise(); - _gyro_integrator.set_reset_samples(1); } @@ -89,12 +90,86 @@ void VehicleOpticalFlow::ParametersUpdate() parameter_update_s param_update; _params_sub.copy(¶m_update); - updateParams(); - - _flow_rotation = get_rot_matrix((enum Rotation)_param_sens_flow_rot.get()); + UpdateParameters(); } } +bool VehicleOpticalFlow::UpdateParamSlot(uint32_t device_id) +{ + const int8_t slot = _slot_binder.slotForInstanceWithFallback(_instance, device_id); + + if (slot < 0) { + if (!_no_slot_warned) { + PX4_WARN("optical flow %" PRIu8 " (device ID %" PRIu32 ") ignored, no free SENS_FLOW slot", _instance, device_id); + _no_slot_warned = true; + } + + return false; + } + + if (slot == _param_slot) { + return true; + } + + _param_slot = slot; + + char param_name[20] {}; + + snprintf(param_name, sizeof(param_name), "SENS_FLOW%d_ROT", slot); + _param_handles.rot = param_find(param_name); + + snprintf(param_name, sizeof(param_name), "SENS_FLOW%d_SCALE", slot); + _param_handles.scale = param_find(param_name); + + snprintf(param_name, sizeof(param_name), "SENS_FLOW%d_HMIN", slot); + _param_handles.hmin = param_find(param_name); + + snprintf(param_name, sizeof(param_name), "SENS_FLOW%d_HMAX", slot); + _param_handles.hmax = param_find(param_name); + + snprintf(param_name, sizeof(param_name), "SENS_FLOW%d_MAXR", slot); + _param_handles.maxr = param_find(param_name); + + snprintf(param_name, sizeof(param_name), "SENS_FLOW%d_RATE", slot); + _param_handles.rate = param_find(param_name); + + snprintf(param_name, sizeof(param_name), "SENS_FLOW%d_DELAY", slot); + _param_handles.delay = param_find(param_name); + + snprintf(param_name, sizeof(param_name), "SENS_FLOW%d_POS_X", slot); + _param_handles.pos_x = param_find(param_name); + + snprintf(param_name, sizeof(param_name), "SENS_FLOW%d_POS_Y", slot); + _param_handles.pos_y = param_find(param_name); + + snprintf(param_name, sizeof(param_name), "SENS_FLOW%d_POS_Z", slot); + _param_handles.pos_z = param_find(param_name); + + UpdateParameters(); + + return true; +} + +void VehicleOpticalFlow::UpdateParameters() +{ + if (_param_handles.rot == PARAM_INVALID) { + return; + } + + param_get(_param_handles.rot, &_params.rot); + param_get(_param_handles.scale, &_params.scale); + param_get(_param_handles.hmin, &_params.hmin); + param_get(_param_handles.hmax, &_params.hmax); + param_get(_param_handles.maxr, &_params.maxr); + param_get(_param_handles.rate, &_params.rate); + param_get(_param_handles.delay, &_params.delay); + param_get(_param_handles.pos_x, &_params.pos(0)); + param_get(_param_handles.pos_y, &_params.pos(1)); + param_get(_param_handles.pos_z, &_params.pos(2)); + + _flow_rotation = get_rot_matrix((enum Rotation)_params.rot); +} + void VehicleOpticalFlow::Run() { perf_begin(_cycle_perf); @@ -109,7 +184,8 @@ void VehicleOpticalFlow::Run() sensor_optical_flow_s sensor_optical_flow; - if (_sensor_flow_sub.update(&sensor_optical_flow)) { + if (_sensor_flow_sub.update(&sensor_optical_flow) + && UpdateParamSlot(sensor_optical_flow.device_id)) { // clear data accumulation if there's a gap in data const uint64_t integration_gap_threshold_us = sensor_optical_flow.integration_timespan_us * 2; @@ -211,10 +287,10 @@ void VehicleOpticalFlow::Run() bool publish = true; - if (_param_sens_flow_rate.get() > 0) { - const float interval_us = 1e6f / _param_sens_flow_rate.get(); + if (_params.rate > 0) { + const float interval_us = 1e6f / _params.rate; - // don't allow publishing faster than SENS_FLOW_RATE + // don't allow publishing faster than SENS_FLOW_RATE if (_integration_timespan_us < interval_us) { publish = false; } @@ -226,7 +302,17 @@ void VehicleOpticalFlow::Run() vehicle_optical_flow.timestamp_sample = sensor_optical_flow.timestamp_sample; vehicle_optical_flow.device_id = sensor_optical_flow.device_id; - _flow_integral *= _param_sens_flow_scale.get(); + // SENS_FLOW_DELAY + const hrt_abstime delay_us = static_cast(_params.delay * 1000.f); + + if (vehicle_optical_flow.timestamp_sample > delay_us) { + vehicle_optical_flow.timestamp_sample -= delay_us; + } + + // SENS_FLOW_POS_* + _params.pos.copyTo(vehicle_optical_flow.position_offset); + + _flow_integral *= _params.scale; _flow_integral.copyTo(vehicle_optical_flow.pixel_flow); _delta_angle.copyTo(vehicle_optical_flow.delta_angle); @@ -241,44 +327,44 @@ void VehicleOpticalFlow::Run() vehicle_optical_flow.distance_m = NAN; } - // SENS_FLOW_MAXR + // SENS_FLOW_MAXR if (PX4_ISFINITE(sensor_optical_flow.max_flow_rate) - && (sensor_optical_flow.max_flow_rate <= _param_sens_flow_maxr.get())) { + && (sensor_optical_flow.max_flow_rate <= _params.maxr)) { vehicle_optical_flow.max_flow_rate = sensor_optical_flow.max_flow_rate; } else { - vehicle_optical_flow.max_flow_rate = _param_sens_flow_maxr.get(); + vehicle_optical_flow.max_flow_rate = _params.maxr; } - // SENS_FLOW_MINHGT + // SENS_FLOW_HMIN if (PX4_ISFINITE(sensor_optical_flow.min_ground_distance) - && (sensor_optical_flow.min_ground_distance >= _param_sens_flow_minhgt.get())) { + && (sensor_optical_flow.min_ground_distance >= _params.hmin)) { vehicle_optical_flow.min_ground_distance = sensor_optical_flow.min_ground_distance; } else { - vehicle_optical_flow.min_ground_distance = _param_sens_flow_minhgt.get(); + vehicle_optical_flow.min_ground_distance = _params.hmin; } - // SENS_FLOW_MAXHGT + // SENS_FLOW_HMAX if (PX4_ISFINITE(sensor_optical_flow.max_ground_distance) - && (sensor_optical_flow.max_ground_distance <= _param_sens_flow_maxhgt.get())) { + && (sensor_optical_flow.max_ground_distance <= _params.hmax)) { vehicle_optical_flow.max_ground_distance = sensor_optical_flow.max_ground_distance; } else { - vehicle_optical_flow.max_ground_distance = _param_sens_flow_maxhgt.get(); + vehicle_optical_flow.max_ground_distance = _params.hmax; } - // rotate (SENS_FLOW_ROT) + // rotate (SENS_FLOW_ROT) float zeroval = 0.f; - rotate_3f((enum Rotation)_param_sens_flow_rot.get(), vehicle_optical_flow.pixel_flow[0], + rotate_3f((enum Rotation)_params.rot, vehicle_optical_flow.pixel_flow[0], vehicle_optical_flow.pixel_flow[1], zeroval); vehicle_optical_flow.timestamp = hrt_absolute_time(); - _vehicle_optical_flow_pub.publish(vehicle_optical_flow); + _pubs.flow.publish(_param_slot, vehicle_optical_flow); // vehicle_optical_flow_vel if distance is available (for logging) if (_distance_sum_count > 0 && PX4_ISFINITE(_distance_sum)) { @@ -336,7 +422,7 @@ void VehicleOpticalFlow::Run() flow_vel.timestamp = hrt_absolute_time(); - _vehicle_optical_flow_vel_pub.publish(flow_vel); + _pubs.flow_vel.publish(_param_slot, flow_vel); } ClearAccumulatedData(); @@ -486,7 +572,7 @@ void VehicleOpticalFlow::ClearAccumulatedData() void VehicleOpticalFlow::PrintStatus() { - + PX4_INFO_RAW("vehicle_optical_flow: %" PRIu8 ", param slot: %d\n", _instance, _param_slot); } }; // namespace sensors diff --git a/src/modules/sensors/vehicle_optical_flow/VehicleOpticalFlow.hpp b/src/modules/sensors/vehicle_optical_flow/VehicleOpticalFlow.hpp index dd3022c7096..2930d11badd 100644 --- a/src/modules/sensors/vehicle_optical_flow/VehicleOpticalFlow.hpp +++ b/src/modules/sensors/vehicle_optical_flow/VehicleOpticalFlow.hpp @@ -42,11 +42,13 @@ #include #include #include +#include +#include #include -#include #include #include #include +#include #include #include #include @@ -62,10 +64,18 @@ namespace sensors { -class VehicleOpticalFlow : public ModuleParams, public px4::ScheduledWorkItem +class VehicleOpticalFlow : public px4::ScheduledWorkItem { public: - VehicleOpticalFlow(); + static constexpr uint8_t MAX_FLOW_INSTANCES = 2; + + // indexed by SENS_FLOW slot, shared by all instances + struct Publications { + SlotPublications flow{}; + SlotPublications flow_vel{}; + }; + + VehicleOpticalFlow(uint8_t instance, SensorSlotBinder &slot_binder, Publications &pubs); ~VehicleOpticalFlow() override; bool Start(); @@ -88,8 +98,7 @@ private: static constexpr int MAX_SENSOR_COUNT = 3; - uORB::Publication _vehicle_optical_flow_pub{ORB_ID(vehicle_optical_flow)}; - uORB::Publication _vehicle_optical_flow_vel_pub{ORB_ID(vehicle_optical_flow_vel)}; + Publications &_pubs; uORB::Subscription _params_sub{ORB_ID(parameter_update)}; @@ -97,7 +106,7 @@ private: uORB::Subscription _vehicle_attitude_sub{ORB_ID(vehicle_attitude)}; - uORB::SubscriptionCallbackWorkItem _sensor_flow_sub{this, ORB_ID(sensor_optical_flow)}; + uORB::SubscriptionCallbackWorkItem _sensor_flow_sub; uORB::SubscriptionCallbackWorkItem _sensor_gyro_sub{this, ORB_ID(sensor_gyro)}; uORB::SubscriptionCallbackWorkItem _sensor_selection_sub{this, ORB_ID(sensor_selection)}; @@ -138,13 +147,39 @@ private: RingBuffer _gyro_buffer{}; RingBuffer _range_buffer{}; - DEFINE_PARAMETERS( - (ParamInt) _param_sens_flow_rot, - (ParamFloat) _param_sens_flow_minhgt, - (ParamFloat) _param_sens_flow_maxhgt, - (ParamFloat) _param_sens_flow_maxr, - (ParamFloat) _param_sens_flow_rate, - (ParamFloat) _param_sens_flow_scale - ) + const uint8_t _instance; + + // uORB instance -> SENS_FLOW parameter slot mapping (by device ID, SENS_FLOW_ID) + SensorSlotBinder &_slot_binder; + int8_t _param_slot{-1}; + bool _no_slot_warned{false}; + + // per-sensor parameters (SENS_FLOW_*), resolved by name + struct ParamHandles { + param_t rot{PARAM_INVALID}; + param_t scale{PARAM_INVALID}; + param_t hmin{PARAM_INVALID}; + param_t hmax{PARAM_INVALID}; + param_t maxr{PARAM_INVALID}; + param_t rate{PARAM_INVALID}; + param_t delay{PARAM_INVALID}; + param_t pos_x{PARAM_INVALID}; + param_t pos_y{PARAM_INVALID}; + param_t pos_z{PARAM_INVALID}; + } _param_handles; + + struct Params { + int32_t rot{0}; + float scale{1.f}; + float hmin{0.08f}; + float hmax{100.f}; + float maxr{8.f}; + float rate{70.f}; + float delay{7.f}; + matrix::Vector3f pos{}; + } _params; + + bool UpdateParamSlot(uint32_t device_id); + void UpdateParameters(); }; }; // namespace sensors diff --git a/src/modules/sensors/vehicle_optical_flow/test/VehicleOpticalFlowTest.cpp b/src/modules/sensors/vehicle_optical_flow/test/VehicleOpticalFlowTest.cpp index a97a6ba1ee9..2d969884c21 100644 --- a/src/modules/sensors/vehicle_optical_flow/test/VehicleOpticalFlowTest.cpp +++ b/src/modules/sensors/vehicle_optical_flow/test/VehicleOpticalFlowTest.cpp @@ -66,6 +66,8 @@ public: class VehicleOpticalFlowTestable : public sensors::VehicleOpticalFlow { public: + using sensors::VehicleOpticalFlow::VehicleOpticalFlow; + void UpdateDistanceSensorPublic() { VehicleOpticalFlow::UpdateDistanceSensor(); @@ -82,6 +84,9 @@ public: uORB::Manager::initialize(); } + + SensorSlotBinder _flow_slot_binder{}; + sensors::VehicleOpticalFlow::Publications _flow_pubs{}; void TearDown() override { uORB::Manager::terminate(); @@ -96,7 +101,7 @@ TEST_F(VehicleOpticalFlowTest, CameraFacingDown) orb_advertise(ORB_ID(distance_sensor), &message); // WHEN: update distance sensor - VehicleOpticalFlowTest::VehicleOpticalFlowTestable testable; + VehicleOpticalFlowTest::VehicleOpticalFlowTestable testable{0, _flow_slot_binder, _flow_pubs}; testable.UpdateDistanceSensorPublic(); // THEN: sensor selected @@ -110,7 +115,7 @@ TEST_F(VehicleOpticalFlowTest, CameraFacingForward) orb_advertise(ORB_ID(distance_sensor), &message); // WHEN: update distance sensor - VehicleOpticalFlowTest::VehicleOpticalFlowTestable testable; + VehicleOpticalFlowTest::VehicleOpticalFlowTestable testable{0, _flow_slot_binder, _flow_pubs}; testable.UpdateDistanceSensorPublic(); // THEN: sensor is not selected diff --git a/src/modules/simulation/battery_simulator/BatterySimulator.cpp b/src/modules/simulation/battery_simulator/BatterySimulator.cpp index 9763f277858..ed40a61c88e 100644 --- a/src/modules/simulation/battery_simulator/BatterySimulator.cpp +++ b/src/modules/simulation/battery_simulator/BatterySimulator.cpp @@ -179,7 +179,7 @@ float BatterySimulator::fullDischargeTime(int battery_index) const float BatterySimulator::minimumPercentage(int battery_index) const { // Only a negative override means: use the floor shared by all batteries. Zero is a valid floor. - return (_min_pct_override[battery_index] >= 0.f) ? _min_pct_override[battery_index] : _param_bat_min_pct.get(); + return (_min_pct_override[battery_index] >= 0.f) ? _min_pct_override[battery_index] : _param_sim_bat_min_pct.get(); } int BatterySimulator::task_spawn(int argc, char *argv[]) diff --git a/src/modules/simulation/battery_simulator/BatterySimulator.hpp b/src/modules/simulation/battery_simulator/BatterySimulator.hpp index fc432f4da1d..acb9ddf6fa6 100644 --- a/src/modules/simulation/battery_simulator/BatterySimulator.hpp +++ b/src/modules/simulation/battery_simulator/BatterySimulator.hpp @@ -103,6 +103,6 @@ private: DEFINE_PARAMETERS( (ParamFloat) _param_sim_bat_drain, ///< battery drain interval - (ParamFloat) _param_bat_min_pct //< minimum battery percentage + (ParamFloat) _param_sim_bat_min_pct //< minimum battery percentage ) }; diff --git a/src/modules/simulation/gz_bridge/GZBridge.cpp b/src/modules/simulation/gz_bridge/GZBridge.cpp index 97b85f184fd..f460b658910 100644 --- a/src/modules/simulation/gz_bridge/GZBridge.cpp +++ b/src/modules/simulation/gz_bridge/GZBridge.cpp @@ -85,55 +85,55 @@ int GZBridge::init() } // OPTIONAL: - if (_sim_gz_en_imu.get()) { + if (_param_sim_gz_en_imu.get()) { if (!subscribeImu(false)) { return PX4_ERROR; } } - if (_sim_gz_en_mag.get()) { + if (_param_sim_gz_en_mag.get()) { if (!subscribeMag(false)) { return PX4_ERROR; } } - if (_sim_gz_en_gps.get()) { + if (_param_sim_gz_en_gps.get()) { if (!subscribeNavsat(false)) { return PX4_ERROR; } } - if (_sim_gz_en_baro.get()) { + if (_param_sim_gz_en_baro.get()) { if (!subscribeAirPressure(false)) { return PX4_ERROR; } } - if (_sim_gz_en_lidar.get()) { + if (_param_sim_gz_en_lidar.get()) { if (!subscribeDistanceSensor(false)) { return PX4_ERROR; } } - if (_sim_gz_en_aspd.get()) { + if (_param_sim_gz_en_aspd.get()) { if (!subscribeAirspeed(false)) { return PX4_ERROR; } } - if (_sim_gz_en_flow.get()) { + if (_param_sim_gz_en_flow.get()) { if (!subscribeOpticalFlow(false)) { return PX4_ERROR; } } - if (_sim_gz_en_odom.get()) { + if (_param_sim_gz_en_odom.get()) { if (!subscribeOdometry(false)) { return PX4_ERROR; } } - if (_sim_gz_en_lidar.get()) { + if (_param_sim_gz_en_lidar.get()) { if (!subscribeLaserScan(false)) { return PX4_ERROR; } @@ -226,7 +226,7 @@ bool GZBridge::subscribePoseInfo(bool required) bool GZBridge::subscribeImu(bool required) { - uint8_t count = math::min(_MAX_IMU_SENSORS, static_cast(_sim_gz_en_imu.get())); + uint8_t count = math::min(_MAX_IMU_SENSORS, static_cast(_param_sim_gz_en_imu.get())); for (uint8_t i = 0; i < _MAX_IMU_SENSORS; i++) { std::string imu_topic; @@ -262,7 +262,7 @@ bool GZBridge::subscribeImu(bool required) bool GZBridge::subscribeMag(bool required) { - uint8_t count = math::min(_MAX_MAG_SENSORS, static_cast(_sim_gz_en_mag.get())); + uint8_t count = math::min(_MAX_MAG_SENSORS, static_cast(_param_sim_gz_en_mag.get())); for (uint8_t i = 0; i < _MAX_MAG_SENSORS; i++) { std::string mag_topic; @@ -389,7 +389,7 @@ bool GZBridge::subscribeAirspeed(bool required) bool GZBridge::subscribeAirPressure(bool required) { - uint8_t count = math::min(_MAX_BARO_SENSORS, static_cast(_sim_gz_en_baro.get())); + uint8_t count = math::min(_MAX_BARO_SENSORS, static_cast(_param_sim_gz_en_baro.get())); for (uint8_t i = 0; i < _MAX_BARO_SENSORS; i++) { std::string baro_topic; @@ -425,7 +425,7 @@ bool GZBridge::subscribeAirPressure(bool required) bool GZBridge::subscribeNavsat(bool required) { - uint8_t count = math::min(_MAX_GNSS_SENSORS, static_cast(_sim_gz_en_gps.get())); + uint8_t count = math::min(_MAX_GNSS_SENSORS, static_cast(_param_sim_gz_en_gps.get())); for (uint8_t i = 0; i < _MAX_GNSS_SENSORS; i++) { std::string gnss_topic; @@ -526,7 +526,7 @@ void GZBridge::opticalFlowCallback(const px4::msgs::OpticalFlow &msg) void GZBridge::magnetometerCallback(const gz::msgs::Magnetometer &msg, uint8_t instance_index) { // Bounds check and safety guard - uint8_t count = math::min(_MAX_MAG_SENSORS, static_cast(_sim_gz_en_mag.get())); + uint8_t count = math::min(_MAX_MAG_SENSORS, static_cast(_param_sim_gz_en_mag.get())); if (instance_index >= count) { return; @@ -568,7 +568,7 @@ void GZBridge::magnetometerCallback(const gz::msgs::Magnetometer &msg, uint8_t i void GZBridge::airPressureCallback(const gz::msgs::FluidPressure &msg, uint8_t instance_index) { // Bounds check and safety guard - uint8_t count = math::min(_MAX_BARO_SENSORS, static_cast(_sim_gz_en_baro.get())); + uint8_t count = math::min(_MAX_BARO_SENSORS, static_cast(_param_sim_gz_en_baro.get())); if (instance_index >= count) { return; @@ -581,6 +581,7 @@ void GZBridge::airPressureCallback(const gz::msgs::FluidPressure &msg, uint8_t i void GZBridge::airspeedCallback(const gz::msgs::AirSpeed &msg) { const uint64_t timestamp = hrt_absolute_time(); + _failure_config.update(); device::Device::DeviceId id{}; id.devid_s.bus_type = device::Device::DeviceBusType::DeviceBusType_SIMULATION; @@ -596,13 +597,16 @@ void GZBridge::airspeedCallback(const gz::msgs::AirSpeed &msg) _temperature = static_cast(msg.temperature()) + atmosphere::kAbsoluteNullCelsius; // K to C report.temperature = _temperature; report.pitot_temperature = NAN; - _differential_pressure_pub.publish(report); + + if (failure_injection::process_airspeed(_failure_config, 0, report, _airspeed_failure)) { + _differential_pressure_pub.publish(report); + } } void GZBridge::imuCallback(const gz::msgs::IMU &msg, uint8_t instance_index) { // Bounds check and safety guard - uint8_t count = math::min(_MAX_IMU_SENSORS, static_cast(_sim_gz_en_imu.get())); + uint8_t count = math::min(_MAX_IMU_SENSORS, static_cast(_param_sim_gz_en_imu.get())); if (instance_index >= count) { return; @@ -822,7 +826,7 @@ void GZBridge::addGpsNoise(double &latitude, double &longitude, double &altitude void GZBridge::navSatCallback(const gz::msgs::NavSat &msg, uint8_t instance_index) { - uint8_t count = math::min(_MAX_GNSS_SENSORS, static_cast(_sim_gz_en_gps.get())); + uint8_t count = math::min(_MAX_GNSS_SENSORS, static_cast(_param_sim_gz_en_gps.get())); if (instance_index >= count) { return; @@ -867,7 +871,7 @@ void GZBridge::navSatCallback(const gz::msgs::NavSat &msg, uint8_t instance_inde sensor_gnss_s sensor_gnss{}; - if (_sim_gps_used.get() >= 4) { + if (_param_sim_gps_used.get() >= 4) { // fix sensor_gnss.fix_type = 3; // 3D fix sensor_gnss.speed_accuracy = 0.4f; @@ -908,7 +912,7 @@ void GZBridge::navSatCallback(const gz::msgs::NavSat &msg, uint8_t instance_inde sensor_gnss.jamming_state = 0; sensor_gnss.spoofing_state = 0; sensor_gnss.vel_ned_valid = true; - sensor_gnss.satellites_used = _sim_gps_used.get(); + sensor_gnss.satellites_used = _param_sim_gps_used.get(); if (failure_injection::process_gnss(_failure_config, instance_index, sensor_gnss, _gnss_stuck[instance_index])) { _sensor_gnss_pub[instance_index].publish(sensor_gnss); diff --git a/src/modules/simulation/gz_bridge/GZBridge.hpp b/src/modules/simulation/gz_bridge/GZBridge.hpp index 7a1747a7555..d45f6061733 100644 --- a/src/modules/simulation/gz_bridge/GZBridge.hpp +++ b/src/modules/simulation/gz_bridge/GZBridge.hpp @@ -188,6 +188,7 @@ private: failure_injection::Config _failure_config; failure_injection::Stuck _gnss_stuck[_MAX_GNSS_SENSORS]; failure_injection::Stuck _visual_odometry_stuck{}; + failure_injection::AirspeedState _airspeed_failure; GZMixingInterfaceESC _mixing_interface_esc{_node}; GZMixingInterfaceServo _mixing_interface_servo{_node}; @@ -227,14 +228,14 @@ private: const float _vel_markov_time = 0.85f; // Velocity Markov process coefficient DEFINE_PARAMETERS( - (ParamInt) _sim_gps_used, - (ParamInt) _sim_gz_en_lidar, - (ParamInt) _sim_gz_en_flow, - (ParamInt) _sim_gz_en_aspd, - (ParamInt) _sim_gz_en_baro, - (ParamInt) _sim_gz_en_odom, - (ParamInt) _sim_gz_en_gps, - (ParamInt) _sim_gz_en_imu, - (ParamInt) _sim_gz_en_mag + (ParamInt) _param_sim_gps_used, + (ParamInt) _param_sim_gz_en_lidar, + (ParamInt) _param_sim_gz_en_flow, + (ParamInt) _param_sim_gz_en_aspd, + (ParamInt) _param_sim_gz_en_baro, + (ParamInt) _param_sim_gz_en_odom, + (ParamInt) _param_sim_gz_en_gps, + (ParamInt) _param_sim_gz_en_imu, + (ParamInt) _param_sim_gz_en_mag ) }; diff --git a/src/modules/simulation/gz_bridge/GZBridgeTest.cpp b/src/modules/simulation/gz_bridge/GZBridgeTest.cpp index dd583eafaa2..cf2168e87d9 100644 --- a/src/modules/simulation/gz_bridge/GZBridgeTest.cpp +++ b/src/modules/simulation/gz_bridge/GZBridgeTest.cpp @@ -37,6 +37,7 @@ #include #include +#include #include #include #include @@ -53,6 +54,11 @@ public: { bridge.odometryCallback(message); } + + static void airspeedCallback(GZBridge &bridge, const gz::msgs::AirSpeed &message) + { + bridge.airspeedCallback(message); + } }; namespace @@ -88,6 +94,14 @@ gz::msgs::OdometryWithCovariance odometry(double east, double north, double up) return message; } +gz::msgs::AirSpeed airSpeed(double diff_pressure) +{ + gz::msgs::AirSpeed message; + message.set_diff_pressure(diff_pressure); + message.set_temperature(288.15); + return message; +} + failure_injection_s sensorFailure(uint8_t unit, uint8_t failure_type) { failure_injection_s config{}; @@ -113,6 +127,11 @@ failure_injection_s vioFailure(uint8_t failure_type) return sensorFailure(failure_injection_s::FAILURE_UNIT_SENSOR_VIO, failure_type); } +failure_injection_s airspeedFailure(uint8_t failure_type) +{ + return sensorFailure(failure_injection_s::FAILURE_UNIT_SENSOR_AIRSPEED, failure_type); +} + } // namespace TEST(GZBridge, AppliesGpsFailureInjectionAtNavSatPublication) @@ -205,3 +224,43 @@ TEST(GZBridge, AppliesVioFailureInjectionAtOdometryPublication) EXPECT_FLOAT_EQ(recovered.position[1], 21.f); EXPECT_FLOAT_EQ(recovered.position[2], -23.f); } + +TEST(GZBridge, AppliesAirspeedFailureInjectionAtAirspeedPublication) +{ + GZBridge bridge{"default", "x500"}; + uORB::Publication failure_pub{ORB_ID(failure_injection)}; + uORB::Subscription differential_pressure_sub{ORB_ID(differential_pressure)}; + + GZBridgeTestPeer::airspeedCallback(bridge, airSpeed(100.0)); + + differential_pressure_s baseline{}; + ASSERT_TRUE(differential_pressure_sub.update(&baseline)); + EXPECT_FLOAT_EQ(baseline.differential_pressure_pa, 100.f); + + ASSERT_TRUE(failure_pub.publish(airspeedFailure(failure_injection_s::FAILURE_TYPE_STUCK))); + GZBridgeTestPeer::airspeedCallback(bridge, airSpeed(200.0)); + + differential_pressure_s stuck{}; + ASSERT_TRUE(differential_pressure_sub.update(&stuck)); + EXPECT_FLOAT_EQ(stuck.differential_pressure_pa, baseline.differential_pressure_pa); + + // Wrong starts the pitot blockage ramp, so the first sample is still unscaled + // (the ramp itself is covered by the process_airspeed() tests). + ASSERT_TRUE(failure_pub.publish(airspeedFailure(failure_injection_s::FAILURE_TYPE_WRONG))); + GZBridgeTestPeer::airspeedCallback(bridge, airSpeed(200.0)); + + differential_pressure_s wrong{}; + ASSERT_TRUE(differential_pressure_sub.update(&wrong)); + EXPECT_FLOAT_EQ(wrong.differential_pressure_pa, 200.f); + + ASSERT_TRUE(failure_pub.publish(airspeedFailure(failure_injection_s::FAILURE_TYPE_OFF))); + GZBridgeTestPeer::airspeedCallback(bridge, airSpeed(200.0)); + EXPECT_FALSE(differential_pressure_sub.updated()); + + ASSERT_TRUE(failure_pub.publish(airspeedFailure(failure_injection_s::FAILURE_TYPE_OK))); + GZBridgeTestPeer::airspeedCallback(bridge, airSpeed(200.0)); + + differential_pressure_s recovered{}; + ASSERT_TRUE(differential_pressure_sub.update(&recovered)); + EXPECT_FLOAT_EQ(recovered.differential_pressure_pa, 200.f); +} diff --git a/src/modules/simulation/gz_bridge/GZMixingInterfaceServo.cpp b/src/modules/simulation/gz_bridge/GZMixingInterfaceServo.cpp index b90ec9789eb..8c0b1233da3 100644 --- a/src/modules/simulation/gz_bridge/GZMixingInterfaceServo.cpp +++ b/src/modules/simulation/gz_bridge/GZMixingInterfaceServo.cpp @@ -42,21 +42,21 @@ GZMixingInterfaceServo::get_servo_angle_max(const size_t index) float angle; switch (index) { - case 0: {angle = _servo_max_angle_1.get(); break;} + case 0: {angle = _param_sim_gz_sv_maxa1.get(); break;} - case 1: {angle = _servo_max_angle_2.get(); break;} + case 1: {angle = _param_sim_gz_sv_maxa2.get(); break;} - case 2: {angle = _servo_max_angle_3.get(); break;} + case 2: {angle = _param_sim_gz_sv_maxa3.get(); break;} - case 3: {angle = _servo_max_angle_4.get(); break;} + case 3: {angle = _param_sim_gz_sv_maxa4.get(); break;} - case 4: {angle = _servo_max_angle_5.get(); break;} + case 4: {angle = _param_sim_gz_sv_maxa5.get(); break;} - case 5: {angle = _servo_max_angle_6.get(); break;} + case 5: {angle = _param_sim_gz_sv_maxa6.get(); break;} - case 6: {angle = _servo_max_angle_7.get(); break;} + case 6: {angle = _param_sim_gz_sv_maxa7.get(); break;} - case 7: {angle = _servo_max_angle_8.get(); break;} + case 7: {angle = _param_sim_gz_sv_maxa8.get(); break;} default: {angle = NAN; break;} } @@ -75,21 +75,21 @@ GZMixingInterfaceServo::get_servo_angle_min(const size_t index) float angle; switch (index) { - case 0: {angle = _servo_min_angle_1.get(); break;} + case 0: {angle = _param_sim_gz_sv_mina1.get(); break;} - case 1: {angle = _servo_min_angle_2.get(); break;} + case 1: {angle = _param_sim_gz_sv_mina2.get(); break;} - case 2: {angle = _servo_min_angle_3.get(); break;} + case 2: {angle = _param_sim_gz_sv_mina3.get(); break;} - case 3: {angle = _servo_min_angle_4.get(); break;} + case 3: {angle = _param_sim_gz_sv_mina4.get(); break;} - case 4: {angle = _servo_min_angle_5.get(); break;} + case 4: {angle = _param_sim_gz_sv_mina5.get(); break;} - case 5: {angle = _servo_min_angle_6.get(); break;} + case 5: {angle = _param_sim_gz_sv_mina6.get(); break;} - case 6: {angle = _servo_min_angle_7.get(); break;} + case 6: {angle = _param_sim_gz_sv_mina7.get(); break;} - case 7: {angle = _servo_min_angle_8.get(); break;} + case 7: {angle = _param_sim_gz_sv_mina8.get(); break;} default: {angle = NAN; break;} diff --git a/src/modules/simulation/gz_bridge/GZMixingInterfaceServo.hpp b/src/modules/simulation/gz_bridge/GZMixingInterfaceServo.hpp index 6182de8ceaf..daf8a444705 100644 --- a/src/modules/simulation/gz_bridge/GZMixingInterfaceServo.hpp +++ b/src/modules/simulation/gz_bridge/GZMixingInterfaceServo.hpp @@ -90,21 +90,21 @@ private: std::vector _angular_range_rad; DEFINE_PARAMETERS( - (ParamFloat) _servo_max_angle_1, - (ParamFloat) _servo_min_angle_1, - (ParamFloat) _servo_max_angle_2, - (ParamFloat) _servo_min_angle_2, - (ParamFloat) _servo_max_angle_3, - (ParamFloat) _servo_min_angle_3, - (ParamFloat) _servo_max_angle_4, - (ParamFloat) _servo_min_angle_4, - (ParamFloat) _servo_max_angle_5, - (ParamFloat) _servo_min_angle_5, - (ParamFloat) _servo_max_angle_6, - (ParamFloat) _servo_min_angle_6, - (ParamFloat) _servo_max_angle_7, - (ParamFloat) _servo_min_angle_7, - (ParamFloat) _servo_max_angle_8, - (ParamFloat) _servo_min_angle_8 + (ParamFloat) _param_sim_gz_sv_maxa1, + (ParamFloat) _param_sim_gz_sv_mina1, + (ParamFloat) _param_sim_gz_sv_maxa2, + (ParamFloat) _param_sim_gz_sv_mina2, + (ParamFloat) _param_sim_gz_sv_maxa3, + (ParamFloat) _param_sim_gz_sv_mina3, + (ParamFloat) _param_sim_gz_sv_maxa4, + (ParamFloat) _param_sim_gz_sv_mina4, + (ParamFloat) _param_sim_gz_sv_maxa5, + (ParamFloat) _param_sim_gz_sv_mina5, + (ParamFloat) _param_sim_gz_sv_maxa6, + (ParamFloat) _param_sim_gz_sv_mina6, + (ParamFloat) _param_sim_gz_sv_maxa7, + (ParamFloat) _param_sim_gz_sv_mina7, + (ParamFloat) _param_sim_gz_sv_maxa8, + (ParamFloat) _param_sim_gz_sv_mina8 ) }; diff --git a/src/modules/simulation/sensor_airspeed_sim/SensorAirspeedSim.cpp b/src/modules/simulation/sensor_airspeed_sim/SensorAirspeedSim.cpp index be9999f5ff2..65c3f6db349 100644 --- a/src/modules/simulation/sensor_airspeed_sim/SensorAirspeedSim.cpp +++ b/src/modules/simulation/sensor_airspeed_sim/SensorAirspeedSim.cpp @@ -80,61 +80,46 @@ void SensorAirspeedSim::Run() if (_vehicle_local_position_sub.updated() && _vehicle_global_position_sub.updated() && _vehicle_attitude_sub.updated()) { - updateFailureConfig(); + _failure_config.update(); - if (!_airspeed_disconnected) { + vehicle_local_position_s lpos{}; + _vehicle_local_position_sub.copy(&lpos); - vehicle_local_position_s lpos{}; - _vehicle_local_position_sub.copy(&lpos); + vehicle_global_position_s gpos{}; + _vehicle_global_position_sub.copy(&gpos); - vehicle_global_position_s gpos{}; - _vehicle_global_position_sub.copy(&gpos); + vehicle_attitude_s attitude{}; + _vehicle_attitude_sub.copy(&attitude); - vehicle_attitude_s attitude{}; - _vehicle_attitude_sub.copy(&attitude); + Vector3f local_velocity = Vector3f{lpos.vx, lpos.vy, lpos.vz}; + Vector3f body_velocity = Dcmf{Quatf{attitude.q}} .transpose() * local_velocity; - Vector3f local_velocity = Vector3f{lpos.vx, lpos.vy, lpos.vz}; - Vector3f body_velocity = Dcmf{Quatf{attitude.q}} .transpose() * local_velocity; + // device id + device::Device::DeviceId device_id; + device_id.devid_s.bus_type = device::Device::DeviceBusType::DeviceBusType_SIMULATION; + device_id.devid_s.bus = 0; + device_id.devid_s.address = 0; + device_id.devid_s.devtype = DRV_DIFF_PRESS_DEVTYPE_SIM; - // device id - device::Device::DeviceId device_id; - device_id.devid_s.bus_type = device::Device::DeviceBusType::DeviceBusType_SIMULATION; - device_id.devid_s.bus = 0; - device_id.devid_s.address = 0; - device_id.devid_s.devtype = DRV_DIFF_PRESS_DEVTYPE_SIM; + const float alt_amsl = gpos.alt; + const float temperature_local = TEMPERATURE_MSL - LAPSE_RATE * alt_amsl; + const float density_ratio = powf(TEMPERATURE_MSL / temperature_local, 4.256f); + const float air_density = AIR_DENSITY_MSL / density_ratio; - const float alt_amsl = gpos.alt; - const float temperature_local = TEMPERATURE_MSL - LAPSE_RATE * alt_amsl; - const float density_ratio = powf(TEMPERATURE_MSL / temperature_local, 4.256f); - const float air_density = AIR_DENSITY_MSL / density_ratio; + // calculate differential pressure + noise in hPa + const float diff_pressure_noise = (float)math::generate_wgn() * 0.01f; + float diff_pressure = sign(body_velocity(0)) * 0.005f * air_density * body_velocity(0) * body_velocity( + 0) + diff_pressure_noise; - if (!_airspeed_stuck) { - // calculate differential pressure + noise in hPa - const float diff_pressure_noise = (float)math::generate_wgn() * 0.01f; - float diff_pressure = sign(body_velocity(0)) * 0.005f * air_density * body_velocity(0) * body_velocity( - 0) + diff_pressure_noise; + differential_pressure_s differential_pressure{}; + // report.timestamp_sample = time; + differential_pressure.device_id = 1377548; // 1377548: DRV_DIFF_PRESS_DEVTYPE_SIM, BUS: 1, ADDR: 5, TYPE: SIMULATION + differential_pressure.differential_pressure_pa = diff_pressure * 100.0f; // hPa to Pa + differential_pressure.temperature = temperature_local + ABSOLUTE_ZERO_C; // K to C + differential_pressure.pitot_temperature = NAN; + differential_pressure.timestamp = hrt_absolute_time(); - // simulate pitot blockage: ramp down differential pressure over time - const float blockage_fraction = 0.7f; // max blockage (fully ramped) - const float airspeed_blockage_rampup_time = 30_s; - - float airspeed_blockage_scale = 1.f; - - if (_airspeed_blocked_timestamp > 0) { - airspeed_blockage_scale = math::constrain(1.f - (hrt_absolute_time() - _airspeed_blocked_timestamp) / - airspeed_blockage_rampup_time, 1.f - blockage_fraction, 1.f); - } - - _last_differential_pressure_pa = diff_pressure * 100.0f * airspeed_blockage_scale; // hPa to Pa - } - - differential_pressure_s differential_pressure{}; - // report.timestamp_sample = time; - differential_pressure.device_id = 1377548; // 1377548: DRV_DIFF_PRESS_DEVTYPE_SIM, BUS: 1, ADDR: 5, TYPE: SIMULATION - differential_pressure.differential_pressure_pa = _last_differential_pressure_pa; - differential_pressure.temperature = temperature_local + ABSOLUTE_ZERO_C; // K to C - differential_pressure.pitot_temperature = NAN; - differential_pressure.timestamp = hrt_absolute_time(); + if (failure_injection::process_airspeed(_failure_config, 0, differential_pressure, _airspeed_failure)) { _differential_pressure_pub.publish(differential_pressure); } } @@ -142,26 +127,6 @@ void SensorAirspeedSim::Run() perf_end(_loop_perf); } -void SensorAirspeedSim::updateFailureConfig() -{ - _failure_config.update(); - - const failure_injection::Mode mode = _failure_config.mode(failure_injection_s::FAILURE_UNIT_SENSOR_AIRSPEED, 1); - - _airspeed_disconnected = (mode == failure_injection::Mode::Off); - _airspeed_stuck = (mode == failure_injection::Mode::Stuck); - - if (mode == failure_injection::Mode::Wrong) { - // Simulate pitot blockage: start the ramp on the rising edge and keep it running. - if (_airspeed_blocked_timestamp == 0) { - _airspeed_blocked_timestamp = hrt_absolute_time(); - } - - } else { - _airspeed_blocked_timestamp = 0; - } -} - int SensorAirspeedSim::task_spawn(int argc, char *argv[]) { SensorAirspeedSim *instance = new SensorAirspeedSim(); diff --git a/src/modules/simulation/sensor_airspeed_sim/SensorAirspeedSim.hpp b/src/modules/simulation/sensor_airspeed_sim/SensorAirspeedSim.hpp index 448ba42c6e2..daa742c21bf 100644 --- a/src/modules/simulation/sensor_airspeed_sim/SensorAirspeedSim.hpp +++ b/src/modules/simulation/sensor_airspeed_sim/SensorAirspeedSim.hpp @@ -80,8 +80,6 @@ public: bool init(); - void updateFailureConfig(); - private: void Run() override; @@ -94,10 +92,7 @@ private: failure_injection::Config _failure_config; - bool _airspeed_disconnected{false}; - bool _airspeed_stuck{false}; - hrt_abstime _airspeed_blocked_timestamp{0}; - float _last_differential_pressure_pa{0.f}; + failure_injection::AirspeedState _airspeed_failure; perf_counter_t _loop_perf{perf_alloc(PC_ELAPSED, MODULE_NAME": cycle")}; }; diff --git a/src/modules/simulation/sensor_baro_sim/SensorBaroSim.cpp b/src/modules/simulation/sensor_baro_sim/SensorBaroSim.cpp index d3cbe21b07b..be54d4e6a31 100644 --- a/src/modules/simulation/sensor_baro_sim/SensorBaroSim.cpp +++ b/src/modules/simulation/sensor_baro_sim/SensorBaroSim.cpp @@ -126,10 +126,10 @@ void SensorBaroSim::Run() const float absolute_pressure_noisy = absolute_pressure + abs_pressure_noise + _baro_drift_pa; // Apply pressure offset - float pressure = absolute_pressure_noisy + _sim_baro_off_p.get(); + float pressure = absolute_pressure_noisy + _param_sim_baro_off_p.get(); // calculate temperature in Celsius - float temperature = temperature_local - 273.0f + _sim_baro_off_t.get(); + float temperature = temperature_local - 273.0f + _param_sim_baro_off_t.get(); // Store values for stuck mode _last_pressure = pressure; diff --git a/src/modules/simulation/sensor_baro_sim/SensorBaroSim.hpp b/src/modules/simulation/sensor_baro_sim/SensorBaroSim.hpp index a96da319972..a1a76e2dc6c 100644 --- a/src/modules/simulation/sensor_baro_sim/SensorBaroSim.hpp +++ b/src/modules/simulation/sensor_baro_sim/SensorBaroSim.hpp @@ -92,7 +92,7 @@ private: perf_counter_t _loop_perf{perf_alloc(PC_ELAPSED, MODULE_NAME": cycle")}; DEFINE_PARAMETERS( - (ParamFloat) _sim_baro_off_p, - (ParamFloat) _sim_baro_off_t + (ParamFloat) _param_sim_baro_off_p, + (ParamFloat) _param_sim_baro_off_t ) }; diff --git a/src/modules/simulation/sensor_gps_sim/SensorGpsSim.cpp b/src/modules/simulation/sensor_gps_sim/SensorGpsSim.cpp index eed096303cf..f1c508b1694 100644 --- a/src/modules/simulation/sensor_gps_sim/SensorGpsSim.cpp +++ b/src/modules/simulation/sensor_gps_sim/SensorGpsSim.cpp @@ -122,7 +122,7 @@ void SensorGpsSim::Run() sensor_gnss_s sensor_gnss{}; - if (_sim_gps_used.get() >= 4) { + if (_param_sim_gps_used.get() >= 4) { // fix: RTK fixed while corrections are flowing, 3D otherwise sensor_gnss.fix_type = rtk ? sensor_gnss_s::FIX_TYPE_RTK_FIXED : sensor_gnss_s::FIX_TYPE_3D; sensor_gnss.speed_accuracy = 0.4f; @@ -163,12 +163,12 @@ void SensorGpsSim::Run() sensor_gnss.jamming_state = 0; sensor_gnss.spoofing_state = 0; sensor_gnss.vel_ned_valid = true; - sensor_gnss.satellites_used = _sim_gps_used.get(); + sensor_gnss.satellites_used = _param_sim_gps_used.get(); publishWithFailures(0, sensor_gnss, _sensor_gnss_pub); - const float gnss1_offx = _param_gnss1_offx.get(); - const float gnss1_offy = _param_gnss1_offy.get(); + const float gnss1_offx = _param_sens_gnss1_offx.get(); + const float gnss1_offy = _param_sens_gnss1_offy.get(); if (fabsf(gnss1_offx) > 0.f || fabsf(gnss1_offy) > 0.f) { sensor_gnss_s gnss1 = sensor_gnss; diff --git a/src/modules/simulation/sensor_gps_sim/SensorGpsSim.hpp b/src/modules/simulation/sensor_gps_sim/SensorGpsSim.hpp index 84e29c5545d..c51e53f61af 100644 --- a/src/modules/simulation/sensor_gps_sim/SensorGpsSim.hpp +++ b/src/modules/simulation/sensor_gps_sim/SensorGpsSim.hpp @@ -119,8 +119,8 @@ private: static constexpr float _vel_markov_time{0.54f}; DEFINE_PARAMETERS( - (ParamInt) _sim_gps_used, - (ParamFloat) _param_gnss1_offx, - (ParamFloat) _param_gnss1_offy + (ParamInt) _param_sim_gps_used, + (ParamFloat) _param_sens_gnss1_offx, + (ParamFloat) _param_sens_gnss1_offy ) }; diff --git a/src/modules/simulation/sensor_mag_sim/SensorMagSim.cpp b/src/modules/simulation/sensor_mag_sim/SensorMagSim.cpp index c717d2ab42c..b4ec6d3b17a 100644 --- a/src/modules/simulation/sensor_mag_sim/SensorMagSim.cpp +++ b/src/modules/simulation/sensor_mag_sim/SensorMagSim.cpp @@ -119,9 +119,9 @@ void SensorMagSim::Run() Vector3f expected_field = Dcmf{Quatf{attitude.q}} .transpose() * _mag_earth_pred; expected_field += math::noiseGauss3f(0.02f, 0.02f, 0.03f); - expected_field += Vector3f(_sim_mag_offset_x.get(), - _sim_mag_offset_y.get(), - _sim_mag_offset_z.get()); + expected_field += Vector3f(_param_sim_mag_offset_x.get(), + _param_sim_mag_offset_y.get(), + _param_sim_mag_offset_z.get()); if (_mag_stuck && _last_field_valid) { // Replay the last field seen before the failure was injected diff --git a/src/modules/simulation/sensor_mag_sim/SensorMagSim.hpp b/src/modules/simulation/sensor_mag_sim/SensorMagSim.hpp index 17b4c24c69c..9e86d2bb830 100644 --- a/src/modules/simulation/sensor_mag_sim/SensorMagSim.hpp +++ b/src/modules/simulation/sensor_mag_sim/SensorMagSim.hpp @@ -93,8 +93,8 @@ private: perf_counter_t _loop_perf{perf_alloc(PC_ELAPSED, MODULE_NAME": cycle")}; DEFINE_PARAMETERS( - (ParamFloat) _sim_mag_offset_x, - (ParamFloat) _sim_mag_offset_y, - (ParamFloat) _sim_mag_offset_z + (ParamFloat) _param_sim_mag_offset_x, + (ParamFloat) _param_sim_mag_offset_y, + (ParamFloat) _param_sim_mag_offset_z ) }; diff --git a/src/modules/simulation/simulator_sih/CMakeLists.txt b/src/modules/simulation/simulator_sih/CMakeLists.txt index 1aa35a77194..6a0b14fb50f 100644 --- a/src/modules/simulation/simulator_sih/CMakeLists.txt +++ b/src/modules/simulation/simulator_sih/CMakeLists.txt @@ -87,6 +87,7 @@ if(PX4_PLATFORM MATCHES "posix") standard_vtol_flow hex rover_ackermann + rover_differential ) # find corresponding airframes diff --git a/src/modules/simulation/simulator_sih/sih.cpp b/src/modules/simulation/simulator_sih/sih.cpp index 50ac59d03ed..38a79b6bbfa 100644 --- a/src/modules/simulation/simulator_sih/sih.cpp +++ b/src/modules/simulation/simulator_sih/sih.cpp @@ -105,13 +105,13 @@ void Sih::run() _px4_gyro.set_temperature(T1_C); // the vehicle type is needed by parameters_updated() to place the vehicle on the terrain - _vehicle = static_cast(constrain(_sih_vtype.get(), + _vehicle = static_cast(constrain(_param_sih_vehicle_type.get(), static_cast(VehicleType::First), static_cast(VehicleType::Last))); parameters_updated(); - if (_sih_optical_flow_en.get()) { + if (_param_sih_of_en.get()) { // Advertise before the simulated clock starts running: the sensors module brings up its // optical flow pipeline when the topic first appears, and it only looks for it while // updating its parameters. Advertising here makes it visible for the startup scan even @@ -145,7 +145,7 @@ static uint64_t micros() void Sih::lockstep_loop() { - int rate = math::min(_imu_gyro_ratemax.get(), _imu_integration_rate.get()); + int rate = math::min(_param_imu_gyro_ratemax.get(), _param_imu_integ_rate.get()); // default to 400Hz (2500 us interval) if (rate <= 0) { @@ -235,7 +235,7 @@ static void timer_callback(void *sem) void Sih::realtime_loop() { - int rate = _imu_gyro_ratemax.get(); + int rate = _param_imu_gyro_ratemax.get(); // default to 250 Hz (4000 us interval) if (rate <= 0) { @@ -333,7 +333,7 @@ void Sih::sensor_step() } // distance sensor published at 50 Hz - if (_sih_distance_snsr_en.get() && now - _dist_snsr_time >= 20_ms) { + if (_param_sih_distsnsr_en.get() && now - _dist_snsr_time >= 20_ms) { _dist_snsr_time = now; send_dist_snsr(now); } @@ -342,7 +342,7 @@ void Sih::sensor_step() // once the control pipeline is alive. Publishing while the system is still starting up // races with the sensors module bringing up its optical flow pipeline and deadlocks the // simulation, as this thread is the one advancing the lockstep clock. - if (_sih_optical_flow_en.get()) { + if (_param_sih_of_en.get()) { if (_last_actuator_output_time > 0) { accumulate_optical_flow(dt); @@ -370,54 +370,54 @@ void Sih::sensor_step() void Sih::parameters_updated() { - _T_MAX = _sih_t_max.get(); - _Q_MAX = _sih_q_max.get(); - _L_ROLL = _sih_l_roll.get(); - _L_PITCH = _sih_l_pitch.get(); - _KDV = _sih_kdv.get(); - _KDW = _sih_kdw.get(); - _F_T_MAX = _sih_f_thrust_max.get(); - _F_Q_MAX = _sih_f_torque_max.get(); + _T_MAX = _param_sih_t_max.get(); + _Q_MAX = _param_sih_q_max.get(); + _L_ROLL = _param_sih_l_roll.get(); + _L_PITCH = _param_sih_l_pitch.get(); + _KDV = _param_sih_kdv.get(); + _KDW = _param_sih_kdw.get(); + _F_T_MAX = _param_sih_f_t_max.get(); + _F_Q_MAX = _param_sih_f_q_max.get(); // update the thruster models for (size_t i = 0; i < NUM_DYN_THRUSTER; i++) { - if (_sih_f_ct0.get() > 0.0f && _sih_f_cp0.get() > 0.0f) { - _thruster[i] = Thruster(_sih_forward_diameter_inch.get(), _sih_forward_rpm_max.get(), - _sih_f_ct0.get(), _sih_f_ct1.get(), _sih_f_ct2.get(), - _sih_f_cp0.get(), _sih_f_cp1.get(), _sih_f_cp2.get()); + if (_param_sih_f_ct0.get() > 0.0f && _param_sih_f_cp0.get() > 0.0f) { + _thruster[i] = Thruster(_param_sih_f_dia_inch.get(), _param_sih_f_rpm_max.get(), + _param_sih_f_ct0.get(), _param_sih_f_ct1.get(), _param_sih_f_ct2.get(), + _param_sih_f_cp0.get(), _param_sih_f_cp1.get(), _param_sih_f_cp2.get()); } else { _thruster[i] = Thruster(_F_T_MAX, _F_Q_MAX); } } - if (_sih_f_ct0.get() > 0.0f && _sih_f_cp0.get() > 0.0f) { + if (_param_sih_f_ct0.get() > 0.0f && _param_sih_f_cp0.get() > 0.0f) { _F_T_MAX = _thruster[0].get_T_max(); _F_Q_MAX = _thruster[0].get_Q_max(); - if (fabsf(_F_T_MAX - _sih_f_thrust_max.get()) > 1.0e-5f) { - _sih_f_thrust_max.set(_F_T_MAX); - _sih_f_thrust_max.commit(); + if (fabsf(_F_T_MAX - _param_sih_f_t_max.get()) > 1.0e-5f) { + _param_sih_f_t_max.set(_F_T_MAX); + _param_sih_f_t_max.commit(); PX4_INFO("SIH_F_CT0 > 0, using propeller dynamic model, overriding SIH_F_T_MAX"); } - if (fabsf(_F_Q_MAX - _sih_f_torque_max.get()) > 1.0e-5f) { - _sih_f_torque_max.set(_F_Q_MAX); - _sih_f_torque_max.commit(); + if (fabsf(_F_Q_MAX - _param_sih_f_q_max.get()) > 1.0e-5f) { + _param_sih_f_q_max.set(_F_Q_MAX); + _param_sih_f_q_max.commit(); PX4_INFO("SIH_F_CP0 > 0, using propeller dynamic model, overriding SIH_F_Q_MAX"); } } if (!_lpos_ref.isInitialized() - || (fabsf(static_cast(_lpos_ref.getProjectionReferenceLat()) - _sih_lat0.get()) > FLT_EPSILON) - || (fabsf(static_cast(_lpos_ref.getProjectionReferenceLon()) - _sih_lon0.get()) > FLT_EPSILON) - || (fabsf(_terrain.defaultAltitude() - _sih_h0.get()) > FLT_EPSILON)) { - const double lat0 = static_cast(_sih_lat0.get()); - const double lon0 = static_cast(_sih_lon0.get()); + || (fabsf(static_cast(_lpos_ref.getProjectionReferenceLat()) - _param_sih_loc_lat0.get()) > FLT_EPSILON) + || (fabsf(static_cast(_lpos_ref.getProjectionReferenceLon()) - _param_sih_loc_lon0.get()) > FLT_EPSILON) + || (fabsf(_terrain.defaultAltitude() - _param_sih_loc_h0.get()) > FLT_EPSILON)) { + const double lat0 = static_cast(_param_sih_loc_lat0.get()); + const double lon0 = static_cast(_param_sih_loc_lon0.get()); _lpos_ref.initReference(lat0, lon0); // start on the ground: flat at SIH_LOC_H0, or on the terrain model - _terrain.setDefaultAltitude(_sih_h0.get()); + _terrain.setDefaultAltitude(_param_sih_loc_h0.get()); _lpos_ref_alt = _terrain.vehicleGroundAltitude(lat0, lon0); _ground_alt = _lpos_ref_alt; @@ -430,33 +430,33 @@ void Sih::parameters_updated() const Dcmf R_E2N = _lla.computeRotEcefToNed(); _R_N2E = R_E2N.transpose(); _v_E = _R_N2E * _v_N; - _q = Quatf(Eulerf(0.f, 0.f, _sih_yaw0.get())); + _q = Quatf(Eulerf(0.f, 0.f, _param_sih_loc_yaw0.get())); _q_E = Quatf(_R_N2E) * _q; _q_E.normalize(); } - _MASS = _sih_mass.get(); + _MASS = _param_sih_mass.get(); - _I = diag(Vector3f(_sih_ixx.get(), _sih_iyy.get(), _sih_izz.get())); - _I(0, 1) = _I(1, 0) = _sih_ixy.get(); - _I(0, 2) = _I(2, 0) = _sih_ixz.get(); - _I(1, 2) = _I(2, 1) = _sih_iyz.get(); + _I = diag(Vector3f(_param_sih_ixx.get(), _param_sih_iyy.get(), _param_sih_izz.get())); + _I(0, 1) = _I(1, 0) = _param_sih_ixy.get(); + _I(0, 2) = _I(2, 0) = _param_sih_ixz.get(); + _I(1, 2) = _I(2, 1) = _param_sih_iyz.get(); // guards against too small determinants _Im1 = 100.0f * inv(static_cast(100.0f * _I)); - _distance_snsr_min = _sih_distance_snsr_min.get(); - _distance_snsr_max = _sih_distance_snsr_max.get(); - _distance_snsr_override = _sih_distance_snsr_override.get(); - _distance_snsr_noise = _sih_distance_snsr_noise.get(); + _distance_snsr_min = _param_sih_distsnsr_min.get(); + _distance_snsr_max = _param_sih_distsnsr_max.get(); + _distance_snsr_override = _param_sih_distsnsr_ovr.get(); + _distance_snsr_noise = _param_sih_distsnsr_noi.get(); _px4_rangefinder.set_min_distance(_distance_snsr_min); _px4_rangefinder.set_max_distance(_distance_snsr_max); - _optical_flow_interval_us = static_cast(roundf(1e6f / math::max(_sih_optical_flow_rate.get(), 1.f))); + _optical_flow_interval_us = static_cast(roundf(1e6f / math::max(_param_sih_of_rate.get(), 1.f))); - _T_TAU = _sih_thrust_tau.get(); + _T_TAU = _param_sih_t_tau.get(); - _v_wind_N = Vector3f(_sih_wind_n.get(), _sih_wind_e.get(), 0.f); + _v_wind_N = Vector3f(_param_sih_wind_n.get(), _param_sih_wind_e.get(), 0.f); } void Sih::read_motors(const float dt) @@ -502,6 +502,8 @@ uint8_t Sih::num_motors() const case VehicleType::RoverAckermann: return 1; + case VehicleType::RoverDifferential: return 2; // right wheel at 0, left wheel at 1 + default: return 0; } } @@ -534,7 +536,7 @@ void Sih::publish_esc_status() float max_rpm = 10000.f; if (_vehicle == VehicleType::FixedWing || _vehicle == VehicleType::TailsitterVTOL || _vehicle == VehicleType::StandardVTOL) { - max_rpm = _sih_forward_rpm_max.get(); + max_rpm = _param_sih_f_rpm_max.get(); } for (int i = 0; i < NUM_ACTUATORS_MAX && motor_idx < num_motors(); i++) { @@ -633,6 +635,9 @@ void Sih::generate_force_and_torques(const float dt) } else if (_vehicle == VehicleType::RoverAckermann) { generate_rover_ackermann_dynamics(_u[1], _u[0], dt); + + } else if (_vehicle == VehicleType::RoverDifferential) { + generate_rover_differential_dynamics(_u[0], _u[1]); } } @@ -713,10 +718,10 @@ void Sih::generate_rover_ackermann_dynamics(const float throttle_cmd, const floa // Link: https://srianumakonda.medium.com/everything-you-need-to-know-about-self-driving-in-30-minutes-b38d68bd3427 const float a_y = C * delta / _MASS - fabsf(v_B(0)) * _w_B(2) - 2 * C * v_B(1) / (_MASS * fabsf(v_B(0))); // [m/s^2] Lateral acceleration - const float psi_dot_dot = WHEEL_BASE * C * delta / _sih_izz.get() - - C * WHEEL_BASE * WHEEL_BASE * _w_B(2) / (_sih_izz.get() * fabsf(v_B(0))); // [rad/s^2] Yaw acceleration + const float psi_dot_dot = WHEEL_BASE * C * delta / _param_sih_izz.get() + - C * WHEEL_BASE * WHEEL_BASE * _w_B(2) / (_param_sih_izz.get() * fabsf(v_B(0))); // [rad/s^2] Yaw acceleration F_y = _MASS * a_y; // Lateral force [N] - M_z = _sih_izz.get() * psi_dot_dot; // [Nm] Yaw moment + M_z = _param_sih_izz.get() * psi_dot_dot; // [Nm] Yaw moment } _T_B = Vector3f(F_x, F_y, 0.f); @@ -751,6 +756,40 @@ void Sih::generate_rover_ackermann_dynamics(const float throttle_cmd, const floa } +void Sih::generate_rover_differential_dynamics(const float right_cmd, const float left_cmd) +{ + // Unicycle model: each wheel is driven towards the ground speed its motor command asks for, with the force limited + // by the traction of the wheel, and the wheels do not let the rover slip sideways. + static constexpr float WHEEL_TRACK = 0.6f; // [m] Distance between the left and right wheels, matches RD_WHEEL_TRACK + static constexpr float MAX_WHEEL_SPEED = 2.f; // [m/s] Wheel ground speed at full motor command, matches RO_MAX_THR_SPEED + static constexpr float WHEEL_SPEED_TAU = 0.2f; // [s] Time constant of the wheel speed response + static constexpr float LATERAL_TAU = 0.05f; // [s] Time constant of the lateral slip decay + static constexpr float MU = 0.8f; // [-] Friction coefficient between the wheels and the ground + + const Vector3f v_B = _q.rotateVectorInverse(_v_N); // Nav -> Body + const float yaw_rate = _w_B(2); // [rad/s] positive when turning right + + // Ground speed of each wheel [m/s], turning right slows down the right wheel + const float v_right = v_B(0) - yaw_rate * WHEEL_TRACK / 2.f; + const float v_left = v_B(0) + yaw_rate * WHEEL_TRACK / 2.f; + + // Longitudinal force [N]: force per wheel + const float wheel_gain = _MASS / (2.f * WHEEL_SPEED_TAU); // [N/(m/s)] per wheel, the forward speed responds with WHEEL_SPEED_TAU + const float max_wheel_force = MU * _MASS * CONSTANTS_ONE_G / 2.f; // [N] the weight is shared by both sides + const float F_right = constrain(wheel_gain * (MAX_WHEEL_SPEED * right_cmd - v_right), -max_wheel_force, max_wheel_force); + const float F_left = constrain(wheel_gain * (MAX_WHEEL_SPEED * left_cmd - v_left), -max_wheel_force, max_wheel_force); + + // Lateral force [N]: provides the centripetal force of the turn and removes any sideways velocity + const float max_lateral_force = MU * _MASS * CONSTANTS_ONE_G; + const float F_y = constrain(_MASS * (yaw_rate * v_B(0) - v_B(1) / LATERAL_TAU), -max_lateral_force, max_lateral_force); + + _T_B = Vector3f(F_right + F_left, F_y, 0.f); // Forces [N] + _Mt_B = Vector3f(0.f, 0.f, (F_left - F_right) * WHEEL_TRACK / 2.f); // Moments [Nm] + + _Fa_E = Vector3f(); // [N] Second order drag and friction: rolling resistance is part of the wheel speed response, no aerodynamic drag at rover speeds + _Ma_B = -_KDW * _w_B; // [Nm] First order angular damper +} + void Sih::equations_of_motion(const float dt) { const Vector3f gravity_acceleration_E = Vector3f(_R_N2E.col(2)) * LatLonAlt::Wgs84::gravity( @@ -780,7 +819,8 @@ void Sih::equations_of_motion(const float dt) _grounded = true; } else if (_vehicle == VehicleType::FixedWing - || _vehicle == VehicleType::RoverAckermann) { + || _vehicle == VehicleType::RoverAckermann + || _vehicle == VehicleType::RoverDifferential) { Vector3f down_u = _R_N2E.col(2); ground_force_E = -down_u * sum_of_forces_E * down_u; @@ -1096,9 +1136,9 @@ void Sih::accumulate_optical_flow(const float dt) // value is produced by a right handed rotation of the sensor about the body axis, which // gives the translation over the ground the opposite sign (see the flow observation model // in the EKF). - const float distance = ground_distance(_sih_optical_flow_h_max.get()); + const float distance = ground_distance(_param_sih_of_h_max.get()); - if (!PX4_ISFINITE(distance) || distance > _sih_optical_flow_h_max.get()) { + if (!PX4_ISFINITE(distance) || distance > _param_sih_of_h_max.get()) { // too high above the ground, or not looking at it: no image to track _optical_flow_tracking = false; _optical_flow_dt += dt; @@ -1142,7 +1182,7 @@ void Sih::send_optical_flow(const hrt_abstime &time_now_us) if (tracking) { // white noise on the flow rate estimate, integrated over the interval - pixel_flow += Vector2f(generate_wgn(), generate_wgn()) * (_sih_optical_flow_noise.get() * integration_time); + pixel_flow += Vector2f(generate_wgn(), generate_wgn()) * (_param_sih_of_noise.get() * integration_time); flow.quality = UINT8_MAX; } else { @@ -1162,7 +1202,7 @@ void Sih::send_optical_flow(const hrt_abstime &time_now_us) flow.max_flow_rate = FLOW_MAX_RATE; flow.min_ground_distance = 0.f; - flow.max_ground_distance = _sih_optical_flow_h_max.get(); + flow.max_ground_distance = _param_sih_of_h_max.get(); flow.mode = sensor_optical_flow_s::MODE_LOWLIGHT; flow.error_count = 0; @@ -1180,7 +1220,7 @@ void Sih::send_ranging_beacon(const hrt_abstime &time_now_us) for (uint8_t i = 0; i < NUM_RANGING_BEACONS; i++) { _lpos_ref.reproject(RANGING_BEACON_OFFSETS[i].north_m, RANGING_BEACON_OFFSETS[i].east_m, _ranging_beacons[i].lat_deg, _ranging_beacons[i].lon_deg); - _ranging_beacons[i].alt_m = _sih_h0.get() + RANGING_BEACON_OFFSETS[i].alt_offset_m; + _ranging_beacons[i].alt_m = _param_sih_loc_h0.get() + RANGING_BEACON_OFFSETS[i].alt_offset_m; } } @@ -1192,7 +1232,7 @@ void Sih::send_ranging_beacon(const hrt_abstime &time_now_us) const matrix::Vector3d delta_ecef = beacon_ecef - _p_E; const double true_range_m = delta_ecef.norm(); - const float noise_std = _sih_ranging_beacon_noise.get(); + const float noise_std = _param_sih_rngbc_noise.get(); const float noise_m = (noise_std > 0.f) ? math::generate_wgn() * noise_std : 0.f; const double measured_range_m = math::max(0.0, true_range_m + static_cast(noise_m)); @@ -1329,6 +1369,9 @@ int Sih::print_status() } else if (_vehicle == VehicleType::RoverAckermann) { PX4_INFO("Rover Ackermann"); + + } else if (_vehicle == VehicleType::RoverDifferential) { + PX4_INFO("Rover Differential"); } _terrain.printStatus(); diff --git a/src/modules/simulation/simulator_sih/sih.hpp b/src/modules/simulation/simulator_sih/sih.hpp index 60b1606c804..50dcb4d0567 100644 --- a/src/modules/simulation/simulator_sih/sih.hpp +++ b/src/modules/simulation/simulator_sih/sih.hpp @@ -232,6 +232,7 @@ private: void generate_fw_aerodynamics(const float roll_cmd, const float pitch_cmd, const float yaw_cmd, const float thrust_for_prowash); void generate_ts_aerodynamics(); void generate_rover_ackermann_dynamics(const float throttle_cmd, const float steering_cmd, const float dt); + void generate_rover_differential_dynamics(const float right_cmd, const float left_cmd); void sensor_step(); void ecefToNed(); @@ -333,7 +334,7 @@ private: float _Q[NUM_DYN_THRUSTER] {}; // thruster torque (Nm) Thruster _thruster[NUM_DYN_THRUSTER] {}; // thruster objects - enum class VehicleType {Quadcopter, FixedWing, TailsitterVTOL, StandardVTOL, Hexacopter, RoverAckermann, First = Quadcopter, Last = RoverAckermann}; // numbering dependent on parameter SIH_VEHICLE_TYPE + enum class VehicleType {Quadcopter, FixedWing, TailsitterVTOL, StandardVTOL, Hexacopter, RoverAckermann, RoverDifferential, First = Quadcopter, Last = RoverDifferential}; // numbering dependent on parameter SIH_VEHICLE_TYPE VehicleType _vehicle = VehicleType::Quadcopter; // aerodynamic segments for the fixedwing @@ -383,50 +384,50 @@ private: // parameters defined in sih_params.c DEFINE_PARAMETERS( - (ParamInt) _imu_gyro_ratemax, - (ParamInt) _imu_integration_rate, - (ParamFloat) _sih_mass, - (ParamFloat) _sih_ixx, - (ParamFloat) _sih_iyy, - (ParamFloat) _sih_izz, - (ParamFloat) _sih_ixy, - (ParamFloat) _sih_ixz, - (ParamFloat) _sih_iyz, - (ParamFloat) _sih_t_max, - (ParamFloat) _sih_q_max, - (ParamFloat) _sih_l_roll, - (ParamFloat) _sih_l_pitch, - (ParamFloat) _sih_kdv, - (ParamFloat) _sih_kdw, - (ParamFloat) _sih_lat0, - (ParamFloat) _sih_lon0, - (ParamFloat) _sih_h0, - (ParamFloat) _sih_yaw0, - (ParamInt) _sih_distance_snsr_en, - (ParamFloat) _sih_distance_snsr_min, - (ParamFloat) _sih_distance_snsr_max, - (ParamFloat) _sih_distance_snsr_override, - (ParamFloat) _sih_distance_snsr_noise, - (ParamInt) _sih_optical_flow_en, - (ParamFloat) _sih_optical_flow_rate, - (ParamFloat) _sih_optical_flow_noise, - (ParamFloat) _sih_optical_flow_h_max, - (ParamFloat) _sih_thrust_tau, + (ParamInt) _param_imu_gyro_ratemax, + (ParamInt) _param_imu_integ_rate, + (ParamFloat) _param_sih_mass, + (ParamFloat) _param_sih_ixx, + (ParamFloat) _param_sih_iyy, + (ParamFloat) _param_sih_izz, + (ParamFloat) _param_sih_ixy, + (ParamFloat) _param_sih_ixz, + (ParamFloat) _param_sih_iyz, + (ParamFloat) _param_sih_t_max, + (ParamFloat) _param_sih_q_max, + (ParamFloat) _param_sih_l_roll, + (ParamFloat) _param_sih_l_pitch, + (ParamFloat) _param_sih_kdv, + (ParamFloat) _param_sih_kdw, + (ParamFloat) _param_sih_loc_lat0, + (ParamFloat) _param_sih_loc_lon0, + (ParamFloat) _param_sih_loc_h0, + (ParamFloat) _param_sih_loc_yaw0, + (ParamInt) _param_sih_distsnsr_en, + (ParamFloat) _param_sih_distsnsr_min, + (ParamFloat) _param_sih_distsnsr_max, + (ParamFloat) _param_sih_distsnsr_ovr, + (ParamFloat) _param_sih_distsnsr_noi, + (ParamInt) _param_sih_of_en, + (ParamFloat) _param_sih_of_rate, + (ParamFloat) _param_sih_of_noise, + (ParamFloat) _param_sih_of_h_max, + (ParamFloat) _param_sih_t_tau, // forward propeller - (ParamFloat) _sih_f_thrust_max, - (ParamFloat) _sih_f_torque_max, - (ParamFloat) _sih_f_ct0, - (ParamFloat) _sih_f_ct1, - (ParamFloat) _sih_f_ct2, - (ParamFloat) _sih_f_cp0, - (ParamFloat) _sih_f_cp1, - (ParamFloat) _sih_f_cp2, - (ParamFloat) _sih_forward_diameter_inch, - (ParamFloat) _sih_forward_rpm_max, - (ParamInt) _bat1_source, - (ParamInt) _sih_vtype, - (ParamFloat) _sih_wind_n, - (ParamFloat) _sih_wind_e, - (ParamFloat) _sih_ranging_beacon_noise + (ParamFloat) _param_sih_f_t_max, + (ParamFloat) _param_sih_f_q_max, + (ParamFloat) _param_sih_f_ct0, + (ParamFloat) _param_sih_f_ct1, + (ParamFloat) _param_sih_f_ct2, + (ParamFloat) _param_sih_f_cp0, + (ParamFloat) _param_sih_f_cp1, + (ParamFloat) _param_sih_f_cp2, + (ParamFloat) _param_sih_f_dia_inch, + (ParamFloat) _param_sih_f_rpm_max, + (ParamInt) _param_bat1_source, + (ParamInt) _param_sih_vehicle_type, + (ParamFloat) _param_sih_wind_n, + (ParamFloat) _param_sih_wind_e, + (ParamFloat) _param_sih_rngbc_noise ) }; diff --git a/src/modules/simulation/simulator_sih/sih_params.yaml b/src/modules/simulation/simulator_sih/sih_params.yaml index e52f98ddaa1..0ff22be6a05 100644 --- a/src/modules/simulation/simulator_sih/sih_params.yaml +++ b/src/modules/simulation/simulator_sih/sih_params.yaml @@ -344,6 +344,7 @@ parameters: 3: Standard VTOL 4: Hexacopter 5: Rover Ackermann + 6: Rover Differential default: 0 reboot_required: true SIH_WIND_N: diff --git a/src/modules/spacecraft/SpacecraftPositionControl/SpacecraftPositionControl.cpp b/src/modules/spacecraft/SpacecraftPositionControl/SpacecraftPositionControl.cpp index eccf2bb945c..dc519a69994 100644 --- a/src/modules/spacecraft/SpacecraftPositionControl/SpacecraftPositionControl.cpp +++ b/src/modules/spacecraft/SpacecraftPositionControl/SpacecraftPositionControl.cpp @@ -58,30 +58,30 @@ void SpacecraftPositionControl::updateParams() int num_changed = 0; - if (_param_sys_vehicle_resp.get() >= 0.f) { + if (_param_spc_vehicle_resp.get() >= 0.f) { // make it less sensitive at the lower end - float responsiveness = _param_sys_vehicle_resp.get() * _param_sys_vehicle_resp.get(); + float responsiveness = _param_spc_vehicle_resp.get() * _param_spc_vehicle_resp.get(); - num_changed += _param_mpc_acc.commit_no_notification(math::lerp(1.f, 15.f, responsiveness)); - num_changed += _param_mpc_acc_max.commit_no_notification(math::lerp(2.f, 15.f, responsiveness)); - num_changed += _param_mpc_man_y_max.commit_no_notification(math::lerp(80.f, 450.f, responsiveness)); + num_changed += _param_spc_acc.commit_no_notification(math::lerp(1.f, 15.f, responsiveness)); + num_changed += _param_spc_acc_max.commit_no_notification(math::lerp(2.f, 15.f, responsiveness)); + num_changed += _param_spc_man_y_max.commit_no_notification(math::lerp(80.f, 450.f, responsiveness)); if (responsiveness > 0.6f) { - num_changed += _param_mpc_man_y_tau.commit_no_notification(0.f); + num_changed += _param_spc_man_y_tau.commit_no_notification(0.f); } else { - num_changed += _param_mpc_man_y_tau.commit_no_notification(math::lerp(0.5f, 0.f, responsiveness / 0.6f)); + num_changed += _param_spc_man_y_tau.commit_no_notification(math::lerp(0.5f, 0.f, responsiveness / 0.6f)); } - num_changed += _param_mpc_jerk_max.commit_no_notification(math::lerp(2.f, 50.f, responsiveness)); - num_changed += _param_mpc_jerk_auto.commit_no_notification(math::lerp(1.f, 25.f, responsiveness)); + num_changed += _param_spc_jerk_max.commit_no_notification(math::lerp(2.f, 50.f, responsiveness)); + num_changed += _param_spc_jerk_auto.commit_no_notification(math::lerp(1.f, 25.f, responsiveness)); } - if (_param_mpc_vel_all.get() >= 0.f) { - float all_vel = _param_mpc_vel_all.get(); - num_changed += _param_mpc_vel_manual.commit_no_notification(all_vel); - num_changed += _param_mpc_vel_cruise.commit_no_notification(all_vel); - num_changed += _param_mpc_vel_max.commit_no_notification(all_vel); + if (_param_spc_vel_all.get() >= 0.f) { + float all_vel = _param_spc_vel_all.get(); + num_changed += _param_spc_vel_manual.commit_no_notification(all_vel); + num_changed += _param_spc_vel_cruise.commit_no_notification(all_vel); + num_changed += _param_spc_vel_max.commit_no_notification(all_vel); } if (num_changed > 0) { @@ -90,39 +90,39 @@ void SpacecraftPositionControl::updateParams() // Set PI and PID gains, as well as anti-windup limits _control.setPositionGains( - Vector3f(_param_mpc_pos_p.get(), _param_mpc_pos_p.get(), _param_mpc_pos_p.get()), - Vector3f(_param_mpc_pos_i.get(), _param_mpc_pos_i.get(), _param_mpc_pos_i.get())); - _control.setPositionIntegralLimits(_param_mpc_pos_i_lim.get()); + Vector3f(_param_spc_pos_p.get(), _param_spc_pos_p.get(), _param_spc_pos_p.get()), + Vector3f(_param_spc_pos_i.get(), _param_spc_pos_i.get(), _param_spc_pos_i.get())); + _control.setPositionIntegralLimits(_param_spc_pos_i_lim.get()); _control.setVelocityGains( - Vector3f(_param_mpc_vel_p_acc.get(), _param_mpc_vel_p_acc.get(), _param_mpc_vel_p_acc.get()), - Vector3f(_param_mpc_vel_i_acc.get(), _param_mpc_vel_i_acc.get(), _param_mpc_vel_i_acc.get()), - Vector3f(_param_mpc_vel_d_acc.get(), _param_mpc_vel_d_acc.get(), _param_mpc_vel_d_acc.get())); - _control.setVelocityIntegralLimits(_param_mpc_vel_i_lim.get()); + Vector3f(_param_spc_vel_p.get(), _param_spc_vel_p.get(), _param_spc_vel_p.get()), + Vector3f(_param_spc_vel_i.get(), _param_spc_vel_i.get(), _param_spc_vel_i.get()), + Vector3f(_param_spc_vel_d.get(), _param_spc_vel_d.get(), _param_spc_vel_d.get())); + _control.setVelocityIntegralLimits(_param_spc_vel_i_lim.get()); // Check that the design parameters are inside the absolute maximum constraints - if (_param_mpc_vel_cruise.get() > _param_mpc_vel_max.get()) { - _param_mpc_vel_cruise.set(_param_mpc_vel_max.get()); - _param_mpc_vel_cruise.commit(); + if (_param_spc_vel_cruise.get() > _param_spc_vel_max.get()) { + _param_spc_vel_cruise.set(_param_spc_vel_max.get()); + _param_spc_vel_cruise.commit(); mavlink_log_critical(&_mavlink_log_pub, "Cruise speed has been constrained by max speed\t"); /* EVENT * @description SPC_VEL_CRUISE is set to {1:.0}. */ events::send(events::ID("sc_pos_ctrl_cruise_set"), events::Log::Warning, - "Cruise speed has been constrained by maximum speed", _param_mpc_vel_max.get()); + "Cruise speed has been constrained by maximum speed", _param_spc_vel_max.get()); } - if (_param_mpc_vel_manual.get() > _param_mpc_vel_max.get()) { - _param_mpc_vel_manual.set(_param_mpc_vel_max.get()); - _param_mpc_vel_manual.commit(); + if (_param_spc_vel_manual.get() > _param_spc_vel_max.get()) { + _param_spc_vel_manual.set(_param_spc_vel_max.get()); + _param_spc_vel_manual.commit(); mavlink_log_critical(&_mavlink_log_pub, "Manual speed has been constrained by max speed\t"); /* EVENT * @description SPC_VEL_MANUAL is set to {1:.0}. */ events::send(events::ID("sc_pos_ctrl_man_vel_set"), events::Log::Warning, - "Manual speed has been constrained by maximum speed", _param_mpc_vel_max.get()); + "Manual speed has been constrained by maximum speed", _param_spc_vel_max.get()); } - yaw_rate = math::radians(_param_mpc_man_y_max.get()); + yaw_rate = math::radians(_param_spc_man_y_max.get()); } } @@ -256,9 +256,9 @@ void SpacecraftPositionControl::updatePositionControl() if (_vehicle_control_mode.flag_control_position_enabled && (_setpoint.timestamp >= _time_position_control_enabled)) { - _control.setThrustLimit(_param_mpc_thr_max.get()); + _control.setThrustLimit(_param_spc_thr_max.get()); - _control.setVelocityLimits(_param_mpc_vel_max.get()); + _control.setVelocityLimits(_param_spc_vel_max.get()); _control.setInputSetpoint(_setpoint); @@ -267,7 +267,7 @@ void SpacecraftPositionControl::updatePositionControl() // Run position control if (!_control.update(dt)) { _control.setInputSetpoint(generateFailsafeSetpoint(vehicle_local_position.timestamp_sample, states, true)); - _control.setVelocityLimits(_param_mpc_vel_max.get()); + _control.setVelocityLimits(_param_spc_vel_max.get()); _control.update(dt); } diff --git a/src/modules/spacecraft/SpacecraftPositionControl/SpacecraftPositionControl.hpp b/src/modules/spacecraft/SpacecraftPositionControl/SpacecraftPositionControl.hpp index b7f188042a8..b0e34393705 100644 --- a/src/modules/spacecraft/SpacecraftPositionControl/SpacecraftPositionControl.hpp +++ b/src/modules/spacecraft/SpacecraftPositionControl/SpacecraftPositionControl.hpp @@ -105,25 +105,25 @@ private: DEFINE_PARAMETERS( // Position Control - (ParamFloat) _param_mpc_pos_p, - (ParamFloat) _param_mpc_pos_i, - (ParamFloat) _param_mpc_pos_i_lim, - (ParamFloat) _param_mpc_vel_p_acc, - (ParamFloat) _param_mpc_vel_i_acc, - (ParamFloat) _param_mpc_vel_i_lim, - (ParamFloat) _param_mpc_vel_d_acc, - (ParamFloat) _param_mpc_vel_all, - (ParamFloat) _param_mpc_vel_max, - (ParamFloat) _param_mpc_vel_cruise, - (ParamFloat) _param_mpc_vel_manual, - (ParamFloat) _param_sys_vehicle_resp, - (ParamFloat) _param_mpc_acc, - (ParamFloat) _param_mpc_acc_max, - (ParamFloat) _param_mpc_man_y_max, - (ParamFloat) _param_mpc_man_y_tau, - (ParamFloat) _param_mpc_jerk_auto, - (ParamFloat) _param_mpc_jerk_max, - (ParamFloat) _param_mpc_thr_max + (ParamFloat) _param_spc_pos_p, + (ParamFloat) _param_spc_pos_i, + (ParamFloat) _param_spc_pos_i_lim, + (ParamFloat) _param_spc_vel_p, + (ParamFloat) _param_spc_vel_i, + (ParamFloat) _param_spc_vel_i_lim, + (ParamFloat) _param_spc_vel_d, + (ParamFloat) _param_spc_vel_all, + (ParamFloat) _param_spc_vel_max, + (ParamFloat) _param_spc_vel_cruise, + (ParamFloat) _param_spc_vel_manual, + (ParamFloat) _param_spc_vehicle_resp, + (ParamFloat) _param_spc_acc, + (ParamFloat) _param_spc_acc_max, + (ParamFloat) _param_spc_man_y_max, + (ParamFloat) _param_spc_man_y_tau, + (ParamFloat) _param_spc_jerk_auto, + (ParamFloat) _param_spc_jerk_max, + (ParamFloat) _param_spc_thr_max ); matrix::Vector3f target_pos_sp; diff --git a/src/modules/spacecraft/SpacecraftRateControl/SpacecraftRateControl.cpp b/src/modules/spacecraft/SpacecraftRateControl/SpacecraftRateControl.cpp index 25cbbec295a..504d08c1087 100644 --- a/src/modules/spacecraft/SpacecraftRateControl/SpacecraftRateControl.cpp +++ b/src/modules/spacecraft/SpacecraftRateControl/SpacecraftRateControl.cpp @@ -71,8 +71,8 @@ void SpacecraftRateControl::updateParams() // manual rate control acro mode rate limits _acro_rate_max = Vector3f(radians(_param_sc_acro_r_max.get()), radians(_param_sc_acro_p_max.get()), radians(_param_sc_acro_y_max.get())); - _manual_force_max = _param_sc_manual_f_max.get(); - _manual_torque_max = _param_sc_manual_t_max.get(); + _manual_force_max = _param_sc_man_f_max.get(); + _manual_torque_max = _param_sc_man_t_max.get(); } void SpacecraftRateControl::updateRateControl() diff --git a/src/modules/spacecraft/SpacecraftRateControl/SpacecraftRateControl.hpp b/src/modules/spacecraft/SpacecraftRateControl/SpacecraftRateControl.hpp index cfb7a620cda..1974ab3c9d1 100644 --- a/src/modules/spacecraft/SpacecraftRateControl/SpacecraftRateControl.hpp +++ b/src/modules/spacecraft/SpacecraftRateControl/SpacecraftRateControl.hpp @@ -152,8 +152,8 @@ private: (ParamFloat) _param_sc_acro_supexpo, /**< superexpo stick curve shape (roll & pitch) */ (ParamFloat) _param_sc_acro_supexpoy, /**< superexpo stick curve shape (yaw) */ - (ParamFloat) _param_sc_manual_f_max, - (ParamFloat) _param_sc_manual_t_max, + (ParamFloat) _param_sc_man_f_max, + (ParamFloat) _param_sc_man_t_max, (ParamBool) _param_sc_bat_scale_en ) diff --git a/src/modules/uuv_att_control/uuv_att_control.cpp b/src/modules/uuv_att_control/uuv_att_control.cpp index bd17b2df487..81cc6b20b55 100644 --- a/src/modules/uuv_att_control/uuv_att_control.cpp +++ b/src/modules/uuv_att_control/uuv_att_control.cpp @@ -99,7 +99,7 @@ void UUVAttitudeControl::constrain_actuator_commands(float roll_u, float pitch_u float thrust_x, float thrust_y, float thrust_z) { if (PX4_ISFINITE(roll_u)) { - roll_u = math::constrain(roll_u, -_param_torque_sat.get(), _param_torque_sat.get()); + roll_u = math::constrain(roll_u, -_param_uuv_torque_sat.get(), _param_uuv_torque_sat.get()); _vehicle_torque_setpoint.xyz[0] = roll_u; } else { @@ -107,7 +107,7 @@ void UUVAttitudeControl::constrain_actuator_commands(float roll_u, float pitch_u } if (PX4_ISFINITE(pitch_u)) { - pitch_u = math::constrain(pitch_u, -_param_torque_sat.get(), _param_torque_sat.get()); + pitch_u = math::constrain(pitch_u, -_param_uuv_torque_sat.get(), _param_uuv_torque_sat.get()); _vehicle_torque_setpoint.xyz[1] = pitch_u; } else { @@ -115,7 +115,7 @@ void UUVAttitudeControl::constrain_actuator_commands(float roll_u, float pitch_u } if (PX4_ISFINITE(yaw_u)) { - yaw_u = math::constrain(yaw_u, -_param_torque_sat.get(), _param_torque_sat.get()); + yaw_u = math::constrain(yaw_u, -_param_uuv_torque_sat.get(), _param_uuv_torque_sat.get()); _vehicle_torque_setpoint.xyz[2] = yaw_u; } else { @@ -123,7 +123,7 @@ void UUVAttitudeControl::constrain_actuator_commands(float roll_u, float pitch_u } if (PX4_ISFINITE(thrust_x)) { - thrust_x = math::constrain(thrust_x, -_param_thrust_sat.get(), _param_thrust_sat.get()); + thrust_x = math::constrain(thrust_x, -_param_uuv_thrust_sat.get(), _param_uuv_thrust_sat.get()); _vehicle_thrust_setpoint.xyz[0] = thrust_x; } else { @@ -131,7 +131,7 @@ void UUVAttitudeControl::constrain_actuator_commands(float roll_u, float pitch_u } if (PX4_ISFINITE(thrust_y)) { - thrust_y = math::constrain(thrust_y, -_param_thrust_sat.get(), _param_thrust_sat.get()); + thrust_y = math::constrain(thrust_y, -_param_uuv_thrust_sat.get(), _param_uuv_thrust_sat.get()); _vehicle_thrust_setpoint.xyz[1] = thrust_y; } else { @@ -139,7 +139,7 @@ void UUVAttitudeControl::constrain_actuator_commands(float roll_u, float pitch_u } if (PX4_ISFINITE(thrust_z)) { - thrust_z = math::constrain(thrust_z, -_param_thrust_sat.get(), _param_thrust_sat.get()); + thrust_z = math::constrain(thrust_z, -_param_uuv_thrust_sat.get(), _param_uuv_thrust_sat.get()); _vehicle_thrust_setpoint.xyz[2] = thrust_z; } else { @@ -194,9 +194,9 @@ void UUVAttitudeControl::control_attitude_geo(const vehicle_attitude_s &attitude /**< P-Control */ if (attitude_control_enabled) { - torques(0) = - e_R_vec(0) * _param_roll_p.get(); /**< Roll */ - torques(1) = - e_R_vec(1) * _param_pitch_p.get(); /**< Pitch */ - torques(2) = - e_R_vec(2) * _param_yaw_p.get(); /**< Yaw */ + torques(0) = - e_R_vec(0) * _param_uuv_roll_p.get(); /**< Roll */ + torques(1) = - e_R_vec(1) * _param_uuv_pitch_p.get(); /**< Pitch */ + torques(2) = - e_R_vec(2) * _param_uuv_yaw_p.get(); /**< Yaw */ // take thrust from attitude message float thrust_x = attitude_setpoint.thrust_body[0]; @@ -204,9 +204,9 @@ void UUVAttitudeControl::control_attitude_geo(const vehicle_attitude_s &attitude float thrust_z = attitude_setpoint.thrust_body[2]; /**< PD-Control */ - torques(0) -= omega(0) * _param_roll_d.get(); /**< Roll */ - torques(1) -= omega(1) * _param_pitch_d.get(); /**< Pitch */ - torques(2) -= omega(2) * _param_yaw_d.get(); /**< Yaw */ + torques(0) -= omega(0) * _param_uuv_roll_d.get(); /**< Roll */ + torques(1) -= omega(1) * _param_uuv_pitch_d.get(); /**< Pitch */ + torques(2) -= omega(2) * _param_uuv_yaw_d.get(); /**< Yaw */ float roll_u = torques(0); float pitch_u = torques(1); @@ -222,9 +222,9 @@ void UUVAttitudeControl::control_attitude_geo(const vehicle_attitude_s &attitude float thrust_z = _rates_setpoint.thrust_body[2]; /**< PD-Control */ - torques(0) -= omega(0) * _param_roll_d.get(); /**< Roll */ - torques(1) -= omega(1) * _param_pitch_d.get(); /**< Pitch */ - torques(2) -= omega(2) * _param_yaw_d.get(); /**< Yaw */ + torques(0) -= omega(0) * _param_uuv_roll_d.get(); /**< Roll */ + torques(1) -= omega(1) * _param_uuv_pitch_d.get(); /**< Pitch */ + torques(2) -= omega(2) * _param_uuv_yaw_d.get(); /**< Yaw */ float roll_u = torques(0); float pitch_u = torques(1); @@ -248,12 +248,12 @@ void UUVAttitudeControl::generate_attitude_setpoint(float dt) float roll_setpoint = 0.0f; float pitch_setpoint = 0.0f; - float yaw_setpoint = yaw + _manual_control_setpoint.yaw * dt * _param_sgm_yaw.get(); + float yaw_setpoint = yaw + _manual_control_setpoint.yaw * dt * _param_uuv_sgm_yaw.get(); if (!js_heave_sway_mode) { // Integrate roll/pitch from sticks - roll_setpoint = roll + _manual_control_setpoint.roll * dt * _param_sgm_roll.get(); - pitch_setpoint = pitch + -_manual_control_setpoint.pitch * dt * _param_sgm_pitch.get(); + roll_setpoint = roll + _manual_control_setpoint.roll * dt * _param_uuv_sgm_roll.get(); + pitch_setpoint = pitch + -_manual_control_setpoint.pitch * dt * _param_uuv_sgm_pitch.get(); } // Generate target quaternion @@ -266,7 +266,7 @@ void UUVAttitudeControl::generate_attitude_setpoint(float dt) q_sp.copyTo(_attitude_setpoint.q_d); // Thrust mapping - const float throttle_manual_attitude_gain = _param_sgm_thrtl.get(); + const float throttle_manual_attitude_gain = _param_uuv_sgm_thrtl.get(); if (js_heave_sway_mode) { // XYZ thrust @@ -287,13 +287,13 @@ void UUVAttitudeControl::generate_attitude_setpoint(float dt) void UUVAttitudeControl::generate_rates_setpoint(float dt) { const bool js_heave_sway_mode = joystick_heave_sway_mode(); - const float throttle_manual_rate_gain = _param_rgm_thrtl.get(); + const float throttle_manual_rate_gain = _param_uuv_rgm_thrtl.get(); if (js_heave_sway_mode) { // Hold pitch/roll level. Only yaw is a rate command. XYZ thrust _rates_setpoint.roll = 0.0f; _rates_setpoint.pitch = 0.0f; - _rates_setpoint.yaw = _manual_control_setpoint.yaw * dt * _param_rgm_yaw.get(); + _rates_setpoint.yaw = _manual_control_setpoint.yaw * dt * _param_uuv_rgm_yaw.get(); _rates_setpoint.thrust_body[0] = _manual_control_setpoint.pitch * throttle_manual_rate_gain; // heave +z down _rates_setpoint.thrust_body[1] = _manual_control_setpoint.roll * throttle_manual_rate_gain; // sway +y @@ -301,9 +301,9 @@ void UUVAttitudeControl::generate_rates_setpoint(float dt) } else { // Roll/pitch/yaw are rate commands; thrust only surge - _rates_setpoint.roll = _manual_control_setpoint.roll * dt * _param_rgm_roll.get(); - _rates_setpoint.pitch = -_manual_control_setpoint.pitch * dt * _param_rgm_pitch.get(); - _rates_setpoint.yaw = _manual_control_setpoint.yaw * dt * _param_rgm_yaw.get(); + _rates_setpoint.roll = _manual_control_setpoint.roll * dt * _param_uuv_rgm_roll.get(); + _rates_setpoint.pitch = -_manual_control_setpoint.pitch * dt * _param_uuv_rgm_pitch.get(); + _rates_setpoint.yaw = _manual_control_setpoint.yaw * dt * _param_uuv_rgm_yaw.get(); _rates_setpoint.thrust_body[0] = _manual_control_setpoint.throttle * throttle_manual_rate_gain; _rates_setpoint.thrust_body[1] = 0.f; @@ -317,7 +317,7 @@ void UUVAttitudeControl::check_setpoint_validity(vehicle_attitude_s &v_att) { const float _setpoint_age = (hrt_absolute_time() - _attitude_setpoint.timestamp) * 1e-6f; - if (_setpoint_age < 0.0f || _setpoint_age > _param_setpoint_max_age.get()) { + if (_setpoint_age < 0.0f || _setpoint_age > _param_uuv_sp_max_age.get()) { reset_attitude_setpoint(v_att); } } @@ -398,11 +398,11 @@ void UUVAttitudeControl::Run() if (js_heave_sway_mode) { // Keep roll/pitch level, yaw torque, full XYZ thrust - const float throttle_manual_gain = _param_mgm_thrtl.get(); + const float throttle_manual_gain = _param_uuv_mgm_thrtl.get(); const float roll_u = 0.0f; const float pitch_u = 0.0f; - const float yaw_u = _manual_control_setpoint.yaw * _param_mgm_yaw.get(); + const float yaw_u = _manual_control_setpoint.yaw * _param_uuv_mgm_yaw.get(); const float thrust_x = _manual_control_setpoint.pitch * throttle_manual_gain; // heave const float thrust_y = _manual_control_setpoint.roll * throttle_manual_gain; // sway @@ -412,10 +412,10 @@ void UUVAttitudeControl::Run() } else { // Pitch/roll/yaw torques from sticks, thrust only surge - constrain_actuator_commands(_manual_control_setpoint.roll * _param_mgm_roll.get(), - -_manual_control_setpoint.pitch * _param_mgm_pitch.get(), - _manual_control_setpoint.yaw * _param_mgm_yaw.get(), - _manual_control_setpoint.throttle * _param_mgm_thrtl.get(), + constrain_actuator_commands(_manual_control_setpoint.roll * _param_uuv_mgm_roll.get(), + -_manual_control_setpoint.pitch * _param_uuv_mgm_pitch.get(), + _manual_control_setpoint.yaw * _param_uuv_mgm_yaw.get(), + _manual_control_setpoint.throttle * _param_uuv_mgm_thrtl.get(), 0.f, 0.f); } diff --git a/src/modules/uuv_att_control/uuv_att_control.hpp b/src/modules/uuv_att_control/uuv_att_control.hpp index a3d87b8c5a5..f291185d797 100644 --- a/src/modules/uuv_att_control/uuv_att_control.hpp +++ b/src/modules/uuv_att_control/uuv_att_control.hpp @@ -130,29 +130,29 @@ private: hrt_abstime _last_run{0}; DEFINE_PARAMETERS( - (ParamFloat) _param_roll_p, - (ParamFloat) _param_roll_d, - (ParamFloat) _param_pitch_p, - (ParamFloat) _param_pitch_d, - (ParamFloat) _param_yaw_p, - (ParamFloat) _param_yaw_d, + (ParamFloat) _param_uuv_roll_p, + (ParamFloat) _param_uuv_roll_d, + (ParamFloat) _param_uuv_pitch_p, + (ParamFloat) _param_uuv_pitch_d, + (ParamFloat) _param_uuv_yaw_p, + (ParamFloat) _param_uuv_yaw_d, // gains for the different modes - (ParamFloat) _param_sgm_roll, - (ParamFloat) _param_sgm_pitch, - (ParamFloat) _param_sgm_yaw, - (ParamFloat) _param_sgm_thrtl, - (ParamFloat) _param_rgm_roll, - (ParamFloat) _param_rgm_pitch, - (ParamFloat) _param_rgm_yaw, - (ParamFloat) _param_rgm_thrtl, - (ParamFloat) _param_mgm_roll, - (ParamFloat) _param_mgm_pitch, - (ParamFloat) _param_mgm_yaw, - (ParamFloat) _param_mgm_thrtl, - (ParamFloat) _param_torque_sat, - (ParamFloat) _param_thrust_sat, - (ParamFloat) _param_setpoint_max_age, - (ParamInt) _param_stick_mode + (ParamFloat) _param_uuv_sgm_roll, + (ParamFloat) _param_uuv_sgm_pitch, + (ParamFloat) _param_uuv_sgm_yaw, + (ParamFloat) _param_uuv_sgm_thrtl, + (ParamFloat) _param_uuv_rgm_roll, + (ParamFloat) _param_uuv_rgm_pitch, + (ParamFloat) _param_uuv_rgm_yaw, + (ParamFloat) _param_uuv_rgm_thrtl, + (ParamFloat) _param_uuv_mgm_roll, + (ParamFloat) _param_uuv_mgm_pitch, + (ParamFloat) _param_uuv_mgm_yaw, + (ParamFloat) _param_uuv_mgm_thrtl, + (ParamFloat) _param_uuv_torque_sat, + (ParamFloat) _param_uuv_thrust_sat, + (ParamFloat) _param_uuv_sp_max_age, + (ParamInt) _param_uuv_stick_mode ) @@ -175,5 +175,5 @@ private: void reset_attitude_setpoint(vehicle_attitude_s &v_att); void check_setpoint_validity(vehicle_attitude_s &v_att); - inline bool joystick_heave_sway_mode() const { return _param_stick_mode.get() == 0; } + inline bool joystick_heave_sway_mode() const { return _param_uuv_stick_mode.get() == 0; } }; diff --git a/src/modules/uuv_pos_control/uuv_pos_control.cpp b/src/modules/uuv_pos_control/uuv_pos_control.cpp index d394ec54f09..668717e0dac 100644 --- a/src/modules/uuv_pos_control/uuv_pos_control.cpp +++ b/src/modules/uuv_pos_control/uuv_pos_control.cpp @@ -102,10 +102,10 @@ void UUVPOSControl::pose_controller_6dof(const Vector3f &pos_des, vehicle_attitu Quatf q_att(vehicle_attitude.q); // Assumes target 0 velocity - Vector3f p_control_output = Vector3f(_param_pose_gain_x.get() * (pos_des(0) - vlocal_pos.x) - _param_pose_gain_d_x.get() + Vector3f p_control_output = Vector3f(_param_uuv_gain_x_p.get() * (pos_des(0) - vlocal_pos.x) - _param_uuv_gain_x_d.get() * vlocal_pos.vx, - _param_pose_gain_y.get() * (pos_des(1) - vlocal_pos.y) - _param_pose_gain_d_y.get() * vlocal_pos.vy, - _param_pose_gain_z.get() * (pos_des(2) - vlocal_pos.z) - _param_pose_gain_d_z.get() * vlocal_pos.vz); + _param_uuv_gain_y_p.get() * (pos_des(1) - vlocal_pos.y) - _param_uuv_gain_y_d.get() * vlocal_pos.vy, + _param_uuv_gain_z_p.get() * (pos_des(2) - vlocal_pos.z) - _param_uuv_gain_z_d.get() * vlocal_pos.vz); if (altitude_mode) { // In altitude mode, we only control the z-axis @@ -129,7 +129,7 @@ void UUVPOSControl::check_setpoint_validity(vehicle_local_position_s &vlocal_pos { const float _setpoint_age = (hrt_absolute_time() - _trajectory_setpoint.timestamp) * 1e-6f; - if (_setpoint_age < 0.0f || _setpoint_age > _param_setpoint_max_age.get()) { + if (_setpoint_age < 0.0f || _setpoint_age > _param_uuv_sp_max_age.get()) { reset_trajectory_setpoint(vlocal_pos); } @@ -164,7 +164,7 @@ void UUVPOSControl::generate_trajectory_setpoint(vehicle_local_position_s &vloca float roll_setpoint = roll; float pitch_setpoint = pitch; - if (_param_stab_mode.get()) { + if (_param_uuv_stab_mode.get()) { roll_setpoint = 0.0; pitch_setpoint = 0.0; @@ -172,19 +172,19 @@ void UUVPOSControl::generate_trajectory_setpoint(vehicle_local_position_s &vloca // Update target roll and pitch setpoint with D-pad switch (_manual_control_setpoint.buttons) { case 2048: - pitch_setpoint -= dt * _param_sgm_pitch.get(); + pitch_setpoint -= dt * _param_uuv_sgm_pitch.get(); break; case 4096: - pitch_setpoint += dt * _param_sgm_pitch.get(); + pitch_setpoint += dt * _param_uuv_sgm_pitch.get(); break; case 8192: - roll_setpoint -= dt * _param_sgm_roll.get(); + roll_setpoint -= dt * _param_uuv_sgm_roll.get(); break; case 16384: - roll_setpoint += dt * _param_sgm_roll.get(); + roll_setpoint += dt * _param_uuv_sgm_roll.get(); break; default: @@ -192,31 +192,31 @@ void UUVPOSControl::generate_trajectory_setpoint(vehicle_local_position_s &vloca } } - float yaw_setpoint = yaw + _manual_control_setpoint.yaw * dt * _param_sgm_yaw.get(); + float yaw_setpoint = yaw + _manual_control_setpoint.yaw * dt * _param_uuv_sgm_yaw.get(); // Update position setpoints based on manual control inputs float vx_sp = 0.0; - if (_manual_control_setpoint.pitch > _param_pos_stick_db.get() - || _manual_control_setpoint.pitch < -_param_pos_stick_db.get()) { + if (_manual_control_setpoint.pitch > _param_uuv_pos_stick_db.get() + || _manual_control_setpoint.pitch < -_param_uuv_pos_stick_db.get()) { // If pitch is not zero, we use it to set the roll setpoint - vx_sp = _manual_control_setpoint.pitch * _param_pgm_vel.get(); + vx_sp = _manual_control_setpoint.pitch * _param_uuv_pgm_vel.get(); } float vy_sp = 0.0; - if (_manual_control_setpoint.roll > _param_pos_stick_db.get() - || _manual_control_setpoint.roll < -_param_pos_stick_db.get()) { + if (_manual_control_setpoint.roll > _param_uuv_pos_stick_db.get() + || _manual_control_setpoint.roll < -_param_uuv_pos_stick_db.get()) { // If roll is not zero, we use it to set the pitch setpoint - vy_sp = _manual_control_setpoint.roll * _param_pgm_vel.get(); + vy_sp = _manual_control_setpoint.roll * _param_uuv_pgm_vel.get(); } float vz_sp = 0.0; - if (_manual_control_setpoint.throttle > _param_pos_stick_db.get() - || _manual_control_setpoint.throttle < -_param_pos_stick_db.get()) { + if (_manual_control_setpoint.throttle > _param_uuv_pos_stick_db.get() + || _manual_control_setpoint.throttle < -_param_uuv_pos_stick_db.get()) { // If throttle is not zero, we use it to set the vertical velocity - vz_sp = -_manual_control_setpoint.throttle * _param_pgm_vel.get(); + vz_sp = -_manual_control_setpoint.throttle * _param_uuv_pgm_vel.get(); } // rotate velocity setpoint in body frame to global frame @@ -235,7 +235,7 @@ void UUVPOSControl::generate_trajectory_setpoint(vehicle_local_position_s &vloca _trajectory_setpoint.timestamp = hrt_absolute_time(); - if (!_param_pos_mode.get()) { + if (!_param_uuv_pos_mode.get()) { _trajectory_setpoint.position[0] = _trajectory_setpoint.position[0] + vx_sp * dt; // X in world frame _trajectory_setpoint.position[1] = _trajectory_setpoint.position[1] + vy_sp * dt; // Y in world frame _trajectory_setpoint.position[2] = _trajectory_setpoint.position[2] + vz_sp * dt; // Z in world frame @@ -327,7 +327,7 @@ void UUVPOSControl::Run() float roll_setpoint = 0.0f; float pitch_setpoint = 0.0f; - float yaw_setpoint = yaw + _manual_control_setpoint.roll * dt * _param_sgm_yaw.get(); + float yaw_setpoint = yaw + _manual_control_setpoint.roll * dt * _param_uuv_sgm_yaw.get(); // Generate target quaternion Eulerf euler_sp(roll_setpoint, pitch_setpoint, yaw_setpoint); @@ -339,18 +339,18 @@ void UUVPOSControl::Run() q_sp.copyTo(_attitude_setpoint.q_d); - float maximumDistanceAllowed = _param_hgt_max_diff.get(); + float maximumDistanceAllowed = _param_uuv_hgt_max_diff.get(); //change the desired hgt - if (_manual_control_setpoint.buttons & (1 << _param_hgt_b_up.get())) { //up - if (abs(hgtData[0] - 0.001f * _param_hgt_strength.get() - vlocal_pos.z) < maximumDistanceAllowed) { - hgtData[0] = hgtData[0] - 0.001f * _param_hgt_strength.get(); + if (_manual_control_setpoint.buttons & (1 << _param_uuv_hgt_b_up.get())) { //up + if (abs(hgtData[0] - 0.001f * _param_uuv_hgt_str.get() - vlocal_pos.z) < maximumDistanceAllowed) { + hgtData[0] = hgtData[0] - 0.001f * _param_uuv_hgt_str.get(); } } - if (_manual_control_setpoint.buttons & (1 << _param_hgt_b_down.get())) { //down - if (abs(hgtData[0] + 0.001f * _param_hgt_strength.get() - vlocal_pos.z) < maximumDistanceAllowed) { - hgtData[0] = hgtData[0] + 0.001f * _param_hgt_strength.get(); + if (_manual_control_setpoint.buttons & (1 << _param_uuv_hgt_b_down.get())) { //down + if (abs(hgtData[0] + 0.001f * _param_uuv_hgt_str.get() - vlocal_pos.z) < maximumDistanceAllowed) { + hgtData[0] = hgtData[0] + 0.001f * _param_uuv_hgt_str.get(); } } @@ -358,15 +358,15 @@ void UUVPOSControl::Run() float errorInZ = hgtData[0] - vlocal_pos.z; //make sure the integrational part is not to high - if (std::abs(hgtData[1] + 0.005f * errorInZ * _param_hgt_i_speed.get()) < 1.0f) { - hgtData[1] = hgtData[1] + 0.005f * errorInZ * _param_hgt_i_speed.get(); + if (std::abs(hgtData[1] + 0.005f * errorInZ * _param_uuv_hgt_i_spd.get()) < 1.0f) { + hgtData[1] = hgtData[1] + 0.005f * errorInZ * _param_uuv_hgt_i_spd.get(); } matrix::Vector3f thrustxyz; - thrustxyz(2) = _param_hgt_p.get() * errorInZ - _param_hgt_d.get() * vlocal_pos.vz + _param_hgt_i.get() * + thrustxyz(2) = _param_uuv_hgt_p.get() * errorInZ - _param_uuv_hgt_d.get() * vlocal_pos.vz + _param_uuv_hgt_i.get() * hgtData[1];//PID values - const float throttle_manual_attitude_gain = _param_sgm_thrtl.get(); + const float throttle_manual_attitude_gain = _param_uuv_sgm_thrtl.get(); thrustxyz(0) = _manual_control_setpoint.throttle * throttle_manual_attitude_gain; // surge +x thrustxyz(1) = _manual_control_setpoint.yaw * throttle_manual_attitude_gain; // sway +y diff --git a/src/modules/uuv_pos_control/uuv_pos_control.hpp b/src/modules/uuv_pos_control/uuv_pos_control.hpp index fd7e5605f2d..156fb6104f1 100644 --- a/src/modules/uuv_pos_control/uuv_pos_control.hpp +++ b/src/modules/uuv_pos_control/uuv_pos_control.hpp @@ -123,30 +123,30 @@ private: float hgtData[2];//des_hgt,integrated hgt error bool altitudeStateFlag; DEFINE_PARAMETERS( - (ParamFloat) _param_pose_gain_x, - (ParamFloat) _param_pose_gain_y, - (ParamFloat) _param_pose_gain_z, - (ParamFloat) _param_pose_gain_d_x, - (ParamFloat) _param_pose_gain_d_y, - (ParamFloat) _param_pose_gain_d_z, - (ParamInt) _param_stab_mode, - (ParamFloat) _param_pos_stick_db, - (ParamFloat) _param_pgm_vel, - (ParamFloat) _param_sgm_roll, - (ParamFloat) _param_sgm_pitch, - (ParamFloat) _param_sgm_yaw, - (ParamFloat) _param_setpoint_max_age, - (ParamInt) _param_pos_mode, + (ParamFloat) _param_uuv_gain_x_p, + (ParamFloat) _param_uuv_gain_y_p, + (ParamFloat) _param_uuv_gain_z_p, + (ParamFloat) _param_uuv_gain_x_d, + (ParamFloat) _param_uuv_gain_y_d, + (ParamFloat) _param_uuv_gain_z_d, + (ParamInt) _param_uuv_stab_mode, + (ParamFloat) _param_uuv_pos_stick_db, + (ParamFloat) _param_uuv_pgm_vel, + (ParamFloat) _param_uuv_sgm_roll, + (ParamFloat) _param_uuv_sgm_pitch, + (ParamFloat) _param_uuv_sgm_yaw, + (ParamFloat) _param_uuv_sp_max_age, + (ParamInt) _param_uuv_pos_mode, - (ParamFloat) _param_sgm_thrtl, - (ParamFloat) _param_hgt_p, - (ParamFloat) _param_hgt_d, - (ParamFloat) _param_hgt_i, - (ParamFloat) _param_hgt_i_speed, - (ParamFloat) _param_hgt_strength, - (ParamInt) _param_hgt_b_up, - (ParamInt) _param_hgt_b_down, - (ParamFloat) _param_hgt_max_diff + (ParamFloat) _param_uuv_sgm_thrtl, + (ParamFloat) _param_uuv_hgt_p, + (ParamFloat) _param_uuv_hgt_d, + (ParamFloat) _param_uuv_hgt_i, + (ParamFloat) _param_uuv_hgt_i_spd, + (ParamFloat) _param_uuv_hgt_str, + (ParamInt) _param_uuv_hgt_b_up, + (ParamInt) _param_uuv_hgt_b_down, + (ParamFloat) _param_uuv_hgt_max_diff ) void Run() override; diff --git a/src/modules/uxrce_dds_client/dds_topics.yaml b/src/modules/uxrce_dds_client/dds_topics.yaml index 3370235f206..99a5342340d 100644 --- a/src/modules/uxrce_dds_client/dds_topics.yaml +++ b/src/modules/uxrce_dds_client/dds_topics.yaml @@ -165,9 +165,6 @@ subscriptions: - topic: /fmu/in/obstacle_distance type: px4_msgs::msg::ObstacleDistance - - topic: /fmu/in/sensor_optical_flow - type: px4_msgs::msg::SensorOpticalFlow - - topic: /fmu/in/goto_setpoint type: px4_msgs::msg::GotoSetpoint @@ -257,3 +254,8 @@ subscriptions_multi: type: px4_msgs::msg::RtcmData route_field: device_id max_instances: 4 + + - topic: /fmu/in/sensor_optical_flow + type: px4_msgs::msg::SensorOpticalFlow + route_field: device_id + max_instances: 2 diff --git a/src/modules/uxrce_dds_client/uxrce_dds_client.cpp b/src/modules/uxrce_dds_client/uxrce_dds_client.cpp index 60164a8ff2b..dc776a3347c 100644 --- a/src/modules/uxrce_dds_client/uxrce_dds_client.cpp +++ b/src/modules/uxrce_dds_client/uxrce_dds_client.cpp @@ -237,7 +237,7 @@ bool UxrceddsClient::setupSession(uxrSession *session) // Session // The key identifier of the Client. All Clients connected to an Agent must have a different key. - const uint32_t key = (uint32_t)_param_uxrce_key.get(); + const uint32_t key = (uint32_t)_param_uxrce_dds_key.get(); if (key == 0) { PX4_ERR("session key must be different from zero"); diff --git a/src/modules/uxrce_dds_client/uxrce_dds_client.h b/src/modules/uxrce_dds_client/uxrce_dds_client.h index 3b85350a7a5..24ff98298aa 100644 --- a/src/modules/uxrce_dds_client/uxrce_dds_client.h +++ b/src/modules/uxrce_dds_client/uxrce_dds_client.h @@ -253,7 +253,7 @@ private: DEFINE_PARAMETERS( (ParamInt) _param_uxrce_dds_dom_id, - (ParamInt) _param_uxrce_key, + (ParamInt) _param_uxrce_dds_key, (ParamInt) _param_uxrce_dds_ptcfg, (ParamInt) _param_uxrce_dds_syncc, (ParamInt) _param_uxrce_dds_synct, diff --git a/src/modules/vision_target_estimator/Orientation/VTEOrientation.cpp b/src/modules/vision_target_estimator/Orientation/VTEOrientation.cpp index d90cd21f032..73b2d593bd1 100644 --- a/src/modules/vision_target_estimator/Orientation/VTEOrientation.cpp +++ b/src/modules/vision_target_estimator/Orientation/VTEOrientation.cpp @@ -229,7 +229,7 @@ bool VTEOrientation::processObsVision(VisionObs &vision_obs) return false; } - const float min_ev_angle_var = sq(fmaxf(_param_vte_ev_angle_noise.get(), kMinObservationNoise)); + const float min_ev_angle_var = sq(fmaxf(_param_vte_eva_noise.get(), kMinObservationNoise)); const float yaw_unc = fmaxf(fiducial_marker_yaw.yaw_var_ned, min_ev_angle_var); vision_obs.timestamp = fiducial_marker_yaw.timestamp_sample; diff --git a/src/modules/vision_target_estimator/Orientation/VTEOrientation.h b/src/modules/vision_target_estimator/Orientation/VTEOrientation.h index d0702ffabbc..d8c37807d54 100644 --- a/src/modules/vision_target_estimator/Orientation/VTEOrientation.h +++ b/src/modules/vision_target_estimator/Orientation/VTEOrientation.h @@ -172,7 +172,7 @@ private: DEFINE_PARAMETERS( (ParamFloat) _param_vte_yaw_unc_in, (ParamFloat) _param_vte_yaw_acc_unc, - (ParamFloat) _param_vte_ev_angle_noise, + (ParamFloat) _param_vte_eva_noise, (ParamFloat) _param_vte_yaw_nis_thre ) }; diff --git a/src/modules/vision_target_estimator/Position/VTEPosition.cpp b/src/modules/vision_target_estimator/Position/VTEPosition.cpp index 56d79118237..281b6475bd7 100644 --- a/src/modules/vision_target_estimator/Position/VTEPosition.cpp +++ b/src/modules/vision_target_estimator/Position/VTEPosition.cpp @@ -168,7 +168,7 @@ bool VTEPosition::initEstimator(const AxisEstimatorStates &state_init, const Vec // Get initial variance from params const float state_pos_var = fmaxf(_param_vte_pos_unc_in.get(), kMinVariance); const float state_vel_var = fmaxf(_param_vte_vel_unc_in.get(), kMinVariance); - const float state_bias_var = fmaxf(_param_vte_bias_unc_in.get(), kMinVariance); + const float state_bias_var = fmaxf(_param_vte_bia_unc_in.get(), kMinVariance); EstimatorState state_var_init{}; state_var_init(vtest::State::vel_uav) = state_vel_var; @@ -810,7 +810,7 @@ void VTEPosition::activateBiasEstimate(const Vector3f &position, const Vector3f const TargetObs &vision_obs, bool position_from_vision) { const float pos_var = fmaxf(_param_vte_pos_unc_in.get(), kMinVariance); - const float bias_var = fmaxf(_param_vte_bias_unc_in.get(), kMinVariance); + const float bias_var = fmaxf(_param_vte_bia_unc_in.get(), kMinVariance); const hrt_abstime reset_time = math::min(vision_obs.timestamp, _last_predict); const float latency = (_last_predict - reset_time) * kMicrosecondsToSeconds; @@ -971,7 +971,7 @@ bool VTEPosition::processObsVision(TargetObs &obs) quat_att.normalize(); const Vector3f vision_rel(report.rel_pos); const Vector3f vision_ned = quat_att.rotateVector(vision_rel); - const float min_ev_pos_var = sq(fmaxf(_param_vte_ev_pos_noise.get(), kMinObservationNoise)); + const float min_ev_pos_var = sq(fmaxf(_param_vte_evp_noise.get(), kMinObservationNoise)); // Rotate covariance matrix to vc-NED const SquareMatrix cov_mat = diag(Vector3f( @@ -1428,22 +1428,22 @@ void VTEPosition::updateParams() float VTEPosition::getMinGpsVelVar() const { - return sq(fmaxf(_param_vte_gps_vel_noise.get(), kMinObservationNoise)); + return sq(fmaxf(_param_vte_gps_v_noise.get(), kMinObservationNoise)); } float VTEPosition::getMinGpsPosVar() const { - return sq(fmaxf(_param_vte_gps_pos_noise.get(), kMinObservationNoise)); + return sq(fmaxf(_param_vte_gps_p_noise.get(), kMinObservationNoise)); } float VTEPosition::getBiasAveragingThreshold() const { - return fmaxf(_param_vte_bias_avg_thr.get(), 0.f); + return fmaxf(_param_vte_bia_avg_thr.get(), 0.f); } hrt_abstime VTEPosition::getBiasAveragingTimeoutUs() const { - const float seconds = fmaxf(_param_vte_bias_avg_tout.get(), 0.f); + const float seconds = fmaxf(_param_vte_bia_avg_tout.get(), 0.f); const float microseconds = fminf(seconds * 1e6f, static_cast(UINT32_MAX)); return static_cast(microseconds); } diff --git a/src/modules/vision_target_estimator/Position/VTEPosition.h b/src/modules/vision_target_estimator/Position/VTEPosition.h index 05cbd44d3bb..bebd03c06e1 100644 --- a/src/modules/vision_target_estimator/Position/VTEPosition.h +++ b/src/modules/vision_target_estimator/Position/VTEPosition.h @@ -458,15 +458,15 @@ private: (ParamFloat) _param_vte_acc_d_unc, (ParamFloat) _param_vte_acc_t_unc, (ParamFloat) _param_vte_bias_unc, - (ParamFloat) _param_vte_bias_avg_thr, - (ParamFloat) _param_vte_bias_avg_tout, + (ParamFloat) _param_vte_bia_avg_thr, + (ParamFloat) _param_vte_bia_avg_tout, (ParamFloat) _param_vte_pos_unc_in, (ParamFloat) _param_vte_vel_unc_in, - (ParamFloat) _param_vte_bias_unc_in, + (ParamFloat) _param_vte_bia_unc_in, (ParamFloat) _param_vte_acc_unc_in, - (ParamFloat) _param_vte_gps_vel_noise, - (ParamFloat) _param_vte_gps_pos_noise, - (ParamFloat) _param_vte_ev_pos_noise, + (ParamFloat) _param_vte_gps_v_noise, + (ParamFloat) _param_vte_gps_p_noise, + (ParamFloat) _param_vte_evp_noise, (ParamFloat) _param_vte_pos_nis_thre ) }; diff --git a/src/modules/vision_target_estimator/VisionTargetEst.cpp b/src/modules/vision_target_estimator/VisionTargetEst.cpp index 0767a882607..d392396f9d2 100644 --- a/src/modules/vision_target_estimator/VisionTargetEst.cpp +++ b/src/modules/vision_target_estimator/VisionTargetEst.cpp @@ -230,11 +230,11 @@ void VisionTargetEst::updateParams() _vte_position.setTargetValidTimeout(target_valid_timeout_us); _vte_orientation.setTargetValidTimeout(target_valid_timeout_us); - const hrt_abstime meas_recent_timeout_us = static_cast(_param_vte_mrec_tout.get() * 1_s); + const hrt_abstime meas_recent_timeout_us = static_cast(_param_vte_m_rec_tout.get() * 1_s); _vte_position.setMeasRecentTimeout(meas_recent_timeout_us); _vte_orientation.setMeasRecentTimeout(meas_recent_timeout_us); - const hrt_abstime meas_updated_timeout_us = static_cast(_param_vte_mupd_tout.get() * 1_s); + const hrt_abstime meas_updated_timeout_us = static_cast(_param_vte_m_upd_tout.get() * 1_s); _vte_position.setMeasUpdatedTimeout(meas_updated_timeout_us); if (_vte_position_enabled && _position_estimator_running diff --git a/src/modules/vision_target_estimator/VisionTargetEst.h b/src/modules/vision_target_estimator/VisionTargetEst.h index 2fb1dabb6de..40cf67e672d 100644 --- a/src/modules/vision_target_estimator/VisionTargetEst.h +++ b/src/modules/vision_target_estimator/VisionTargetEst.h @@ -238,8 +238,8 @@ private: (ParamInt) _param_vte_task_mask, (ParamFloat) _param_vte_btout, (ParamFloat) _param_vte_tgt_tout, - (ParamFloat) _param_vte_mrec_tout, - (ParamFloat) _param_vte_mupd_tout, + (ParamFloat) _param_vte_m_rec_tout, + (ParamFloat) _param_vte_m_upd_tout, (ParamInt) _param_vte_aid_mask ) }; diff --git a/src/modules/vtol_att_control/CMakeLists.txt b/src/modules/vtol_att_control/CMakeLists.txt index 64ffbdaa1e9..decd708ba5f 100644 --- a/src/modules/vtol_att_control/CMakeLists.txt +++ b/src/modules/vtol_att_control/CMakeLists.txt @@ -43,6 +43,8 @@ px4_add_module( standard_params.yaml tiltrotor_params.yaml vtol_att_control_params.yaml + DEPENDS + hysteresis ) px4_add_functional_gtest(SRC test_vtol_quadchute.cpp LINKLIBS modules__vtol_att_control) diff --git a/src/modules/vtol_att_control/standard.cpp b/src/modules/vtol_att_control/standard.cpp index c10bfcd23a0..dbe20e2339e 100644 --- a/src/modules/vtol_att_control/standard.cpp +++ b/src/modules/vtol_att_control/standard.cpp @@ -60,6 +60,11 @@ Standard::parameters_update() // make sure that pusher ramp in backtransition is smaller than back transition (max) duration _param_vt_b_trans_ramp.set(math::min(_param_vt_b_trans_ramp.get(), _param_vt_b_trans_dur.get())); + + // disabling the detection in flight overrides a detected pusher failure, e.g. a false positive in strong wind + if (!isPusherFailureDetectionEnabled()) { + _pusher_failed = false; + } } void Standard::update_vtol_state() @@ -69,6 +74,11 @@ void Standard::update_vtol_state() * For the back transition the pusher motor is immediately stopped and rotors reactivated. */ + // without pusher a front transition would fail too, so this quad-chute stays until reboot + if (_pusher_failed) { + _attc->quadchute(QuadchuteReason::PusherFailure); + } + float mc_weight = _mc_roll_weight; if (_attc->is_quadchute_active()) { @@ -176,6 +186,9 @@ void Standard::update_transition_state() VtolType::update_transition_state(); + // the pusher failure detection restarts in multicopter mode + _pusher_failure_hysteresis.set_state_and_update(false, now); + // we get attitude setpoint from a multirotor flighttask if climbrate is controlled. // in any other case the fixed wing attitude controller publishes attitude setpoint from manual stick input. if (_v_control_mode->flag_control_climb_rate_enabled) { @@ -284,6 +297,28 @@ void Standard::update_mc_state() VtolType::update_mc_state(); _pusher_throttle = VtolType::pusher_assist(); + + _pusher_failed = _pusher_failed || isPusherFailureDetected(); +} + +bool Standard::isPusherFailureDetected() +{ + bool pusher_ineffective = false; + + if (isPusherFailureDetectionEnabled() && _pusher_throttle > _param_vt_ef_throt.get() && _local_pos->v_xy_valid) { + const Quatf q(_v_att->q); + const float forward_vel = q.rotateVectorInverse(Vector3f(_local_pos->vx, _local_pos->vy, _local_pos->vz))(0); + const float forward_vel_sp = q.rotateVectorInverse(Vector3f(_local_pos_sp->vx, _local_pos_sp->vy, + _local_pos_sp->vz))(0); + + // NAN velocities fail the comparison and never detect + pusher_ineffective = forward_vel_sp - forward_vel > _param_vt_ef_vel_err.get(); + } + + _pusher_failure_hysteresis.set_hysteresis_time_from(false, (hrt_abstime)(1_s * math::max(_param_vt_ef_time.get(), 0.f))); + _pusher_failure_hysteresis.set_state_and_update(pusher_ineffective, hrt_absolute_time()); + + return _pusher_failure_hysteresis.get_state(); } void Standard::update_fw_state() diff --git a/src/modules/vtol_att_control/standard.h b/src/modules/vtol_att_control/standard.h index 9239be3a0e9..1b27816703b 100644 --- a/src/modules/vtol_att_control/standard.h +++ b/src/modules/vtol_att_control/standard.h @@ -47,6 +47,8 @@ #define STANDARD_H #include "vtol_type.h" +#include + class Standard : public VtolType { @@ -80,12 +82,23 @@ private: hrt_abstime _last_time_pusher_transition_update{0}; float _front_transition_pitch{NAN}; + systemlib::Hysteresis _pusher_failure_hysteresis{false}; + bool _pusher_failed{false}; ///< latched until reboot or until the detection is disabled + void parameters_update() override; + bool isPusherFailureDetectionEnabled() const { return _param_vt_ef_time.get() > FLT_EPSILON; } + + /** Pusher assist above VT_EF_THROT, but the forward velocity stays below its setpoint */ + bool isPusherFailureDetected(); + DEFINE_PARAMETERS_CUSTOM_PARENT(VtolType, (ParamFloat) _param_vt_psher_slew, (ParamFloat) _param_vt_b_trans_ramp, - (ParamFloat) _param_fw_psp_off + (ParamFloat) _param_fw_psp_off, + (ParamFloat) _param_vt_ef_time, + (ParamFloat) _param_vt_ef_throt, + (ParamFloat) _param_vt_ef_vel_err ) }; #endif diff --git a/src/modules/vtol_att_control/standard_params.yaml b/src/modules/vtol_att_control/standard_params.yaml index ae9e32f44db..256147f75b5 100644 --- a/src/modules/vtol_att_control/standard_params.yaml +++ b/src/modules/vtol_att_control/standard_params.yaml @@ -60,3 +60,41 @@ parameters: min: 0 increment: 0.01 decimal: 2 + VT_EF_TIME: + description: + short: Pusher failure detection time + long: A pusher failure is detected in multicopter mode when, for this time, the + pusher assist throttle is above VT_EF_THROT, but the forward velocity stays more + than VT_EF_VEL_ERR below its setpoint. It is handled as a quad-chute that blocks + front transitions until reboot or until disabled. Only used by standard VTOLs when + VT_FWD_THRUST_EN is enabled. Set to 0 to disable. + type: float + default: 5.0 + unit: s + min: 0.0 + max: 20.0 + increment: 0.1 + decimal: 1 + VT_EF_THROT: + description: + short: Pusher failure detection throttle threshold + long: Has to be below the highest pusher assist throttle, which VT_FWD_THRUST_SC, + VT_PITCH_MIN and MPC_TILTMAX_AIR set. + type: float + default: 0.4 + min: 0.0 + max: 0.9 + increment: 0.01 + decimal: 2 + VT_EF_VEL_ERR: + description: + short: Pusher failure detection forward velocity error + long: Forward velocity setpoint minus forward velocity above which pusher assist + above VT_EF_THROT is considered ineffective, see VT_EF_TIME. + type: float + default: 3.5 + unit: m/s + min: 0.5 + max: 10.0 + increment: 0.1 + decimal: 1 diff --git a/src/modules/vtol_att_control/test_vtol_quadchute.cpp b/src/modules/vtol_att_control/test_vtol_quadchute.cpp index bcdf1bb5ebf..dc748474e5a 100644 --- a/src/modules/vtol_att_control/test_vtol_quadchute.cpp +++ b/src/modules/vtol_att_control/test_vtol_quadchute.cpp @@ -41,11 +41,14 @@ #include #include +#include +#include #include "standard.h" #include "vtol_att_control_main.h" using namespace matrix; +using namespace time_literals; TEST(VtolQuadchuteTest, CommandedQuadchuteIsNoFixedWingFailure) { @@ -89,11 +92,11 @@ protected: } // Hover with a nose-down pitch setpoint, which pusher assist replaces with pusher thrust - void setHover(VtolAttitudeControl &attc) + void setHover(VtolAttitudeControl &attc, float pitch_degrees = -30.f) { attc.get_control_mode()->flag_control_climb_rate_enabled = true; Quatf().copyTo(attc.get_att()->q); - Quatf(Eulerf(0.f, math::radians(-30.f), 0.f)).copyTo(attc.get_mc_virtual_att_sp()->q_d); + Quatf(Eulerf(0.f, math::radians(pitch_degrees), 0.f)).copyTo(attc.get_mc_virtual_att_sp()->q_d); } // Pusher command of one Run() cycle, update_mc_state() only runs on a new attitude setpoint @@ -137,3 +140,142 @@ TEST_F(VtolQuadchutePusherTest, DetectedQuadchuteStopsPusherAssist) EXPECT_FALSE(PX4_ISFINITE(runCycle(attc, standard, false))); EXPECT_FALSE(PX4_ISFINITE(runCycle(attc, standard, true))); } + +// Pusher failures detected in multicopter mode block front transitions until VT_EF_TIME is set to 0 or reboot. +class VtolPusherFailureTest : public VtolQuadchutePusherTest +{ +protected: + void SetUp() override + { + VtolQuadchutePusherTest::SetUp(); + + const float ef_time = 0.1f; + param_set(param_find("VT_EF_TIME"), &ef_time); + } + + void TearDown() override + { + param_reset(param_find("VT_EF_TIME")); + VtolQuadchutePusherTest::TearDown(); + } + + // Level hover, by default with a pitch setpoint of -45 deg, which pusher assist replaces with thrust above + // VT_EF_THROT + void setHover(VtolAttitudeControl &attc, float forward_velocity, float forward_velocity_setpoint = 5.f, + float pitch_degrees = -45.f) + { + VtolQuadchutePusherTest::setHover(attc, pitch_degrees); + attc.get_local_pos()->v_xy_valid = true; + attc.get_local_pos()->vx = forward_velocity; + attc.get_local_pos_sp()->vx = forward_velocity_setpoint; + } + + void commandFrontTransition(VtolAttitudeControl &attc) + { + vehicle_command_s command{}; + command.timestamp = hrt_absolute_time(); + command.command = vehicle_command_s::VEHICLE_CMD_DO_VTOL_TRANSITION; + command.param1 = vtol_vehicle_status_s::VEHICLE_VTOL_STATE_FW; + uORB::Publication command_pub{ORB_ID(vehicle_command)}; + ASSERT_TRUE(command_pub.publish(command)); + attc.vehicle_cmd_poll(); + } + + // Fly multicopter mode until the quad-chute or the timeout, returns the flight time + hrt_abstime fly(VtolAttitudeControl &attc, Standard &standard, hrt_abstime timeout) + { + const hrt_abstime start = hrt_absolute_time(); + + while (!attc.is_fixed_wing_system_failure() && hrt_elapsed_time(&start) < timeout) { + runCycle(attc, standard, true); + px4_usleep(10_ms); + } + + return hrt_elapsed_time(&start); + } +}; + +TEST_F(VtolPusherFailureTest, NoForwardMotionIsPusherFailure) +{ + VtolAttitudeControl attc; + Standard standard(&attc); + setHover(attc, 0.f); + + const hrt_abstime flight_time = fly(attc, standard, 2_s); + EXPECT_TRUE(attc.is_fixed_wing_system_failure()); + EXPECT_GE(flight_time, 100_ms); // not before VT_EF_TIME + + // a front transition command clears the reason, the next update detects the latched pusher failure again + commandFrontTransition(attc); + ASSERT_TRUE(attc.is_fixed_wing_requested()); + ASSERT_FALSE(attc.is_quadchute_active()); + EXPECT_FALSE(PX4_ISFINITE(runCycle(attc, standard, false))); + EXPECT_TRUE(attc.is_fixed_wing_system_failure()); + EXPECT_EQ(standard.get_mode(), mode::ROTARY_WING); +} + +TEST_F(VtolPusherFailureTest, DisablingDetectionAllowsFrontTransitions) +{ + VtolAttitudeControl attc; + Standard standard(&attc); + setHover(attc, 0.f); + + fly(attc, standard, 2_s); + ASSERT_TRUE(attc.is_fixed_wing_system_failure()); + + // VT_EF_TIME set to 0 in flight, then a front transition command clears the quad-chute for good + const float ef_time = 0.f; + param_set(param_find("VT_EF_TIME"), &ef_time); + static_cast(standard).parameters_update(); + commandFrontTransition(attc); + ASSERT_TRUE(attc.is_fixed_wing_requested()); + ASSERT_FALSE(attc.is_quadchute_active()); + standard.update_vtol_state(); + EXPECT_FALSE(attc.is_fixed_wing_system_failure()); + EXPECT_EQ(standard.get_mode(), mode::TRANSITION_TO_FW); +} + +TEST_F(VtolPusherFailureTest, PusherFailureReplacesCommandedQuadchute) +{ + VtolAttitudeControl attc; + Standard standard(&attc); + setHover(attc, 0.f); + attc.quadchute(QuadchuteReason::ExternalCommand); + ASSERT_FALSE(attc.is_fixed_wing_system_failure()); + EXPECT_GT(runCycle(attc, standard, true), 0.1f); + + fly(attc, standard, 2_s); + EXPECT_TRUE(attc.is_fixed_wing_system_failure()); + EXPECT_FALSE(PX4_ISFINITE(runCycle(attc, standard, false))); + EXPECT_FALSE(PX4_ISFINITE(runCycle(attc, standard, true))); +} + +TEST_F(VtolPusherFailureTest, ForwardVelocityCloseToSetpointIsNoPusherFailure) +{ + VtolAttitudeControl attc; + Standard standard(&attc); + setHover(attc, 2.f); // 3 m/s below the setpoint, VT_EF_VEL_ERR is 3.5 m/s + + fly(attc, standard, 300_ms); + EXPECT_FALSE(attc.is_fixed_wing_system_failure()); +} + +TEST_F(VtolPusherFailureTest, MovingBackwardWhenHoldingPositionIsPusherFailure) +{ + VtolAttitudeControl attc; + Standard standard(&attc); + setHover(attc, -4.f, 0.f); + + fly(attc, standard, 2_s); + EXPECT_TRUE(attc.is_fixed_wing_system_failure()); +} + +TEST_F(VtolPusherFailureTest, PusherAssistBelowThresholdIsNoPusherFailure) +{ + VtolAttitudeControl attc; + Standard standard(&attc); + setHover(attc, 0.f, 5.f, -30.f); // pusher assist 0.35, VT_EF_THROT is 0.4 + + fly(attc, standard, 300_ms); + EXPECT_FALSE(attc.is_fixed_wing_system_failure()); +} diff --git a/src/modules/vtol_att_control/vtol_att_control_main.cpp b/src/modules/vtol_att_control/vtol_att_control_main.cpp index b521268029e..ad32a8a04e3 100644 --- a/src/modules/vtol_att_control/vtol_att_control_main.cpp +++ b/src/modules/vtol_att_control/vtol_att_control_main.cpp @@ -232,6 +232,11 @@ VtolAttitudeControl::quadchute(QuadchuteReason reason) "Quad-chute triggered due to maximum roll angle exceeded"); break; + case QuadchuteReason::PusherFailure: + events::send(events::ID("vtol_att_ctrl_quadchute_pusher"), events::Log::Critical, + "Quad-chute triggered due to pusher failure"); + break; + case QuadchuteReason::None: // should never get in here return; diff --git a/src/modules/vtol_att_control/vtol_att_control_main.h b/src/modules/vtol_att_control/vtol_att_control_main.h index fe9c81f9de5..a33da4c61a2 100644 --- a/src/modules/vtol_att_control/vtol_att_control_main.h +++ b/src/modules/vtol_att_control/vtol_att_control_main.h @@ -154,6 +154,8 @@ public: float get_calibrated_airspeed() { return _calibrated_airspeed; } private: + friend class VtolPusherFailureTest; // exercises front transition commands after a pusher failure + void Run() override; uORB::SubscriptionCallbackWorkItem _vehicle_torque_setpoint_virtual_fw_sub{this, ORB_ID(vehicle_torque_setpoint_virtual_fw)}; uORB::SubscriptionCallbackWorkItem _vehicle_torque_setpoint_virtual_mc_sub{this, ORB_ID(vehicle_torque_setpoint_virtual_mc)}; diff --git a/src/modules/vtol_att_control/vtol_type.cpp b/src/modules/vtol_att_control/vtol_type.cpp index 47563afb937..9c59ec50e69 100644 --- a/src/modules/vtol_att_control/vtol_type.cpp +++ b/src/modules/vtol_att_control/vtol_type.cpp @@ -223,8 +223,8 @@ bool VtolType::isQuadchuteEnabled() } - const bool above_quadchute_altitude_limit = _param_quadchute_max_height.get() > 0 - && dist_to_ground > (float)_param_quadchute_max_height.get(); + const bool above_quadchute_altitude_limit = _param_vt_fw_qc_hmax.get() > 0 + && dist_to_ground > (float)_param_vt_fw_qc_hmax.get(); return _v_control_mode->flag_armed && !_land_detected->landed && !above_quadchute_altitude_limit; diff --git a/src/modules/vtol_att_control/vtol_type.h b/src/modules/vtol_att_control/vtol_type.h index f42383ab044..c2bfe4902d9 100644 --- a/src/modules/vtol_att_control/vtol_type.h +++ b/src/modules/vtol_att_control/vtol_type.h @@ -92,6 +92,7 @@ enum class QuadchuteReason { TransitionAltitudeLoss, MaximumPitchExceeded, MaximumRollExceeded, + PusherFailure, }; class VtolAttitudeControl; @@ -335,7 +336,7 @@ protected: (ParamInt) _param_vt_fw_qc_p, (ParamInt) _param_vt_fw_qc_r, (ParamFloat) _param_vt_qc_t_alt_loss, - (ParamInt) _param_quadchute_max_height, + (ParamInt) _param_vt_fw_qc_hmax, (ParamFloat) _param_vt_f_tr_ol_tm, (ParamFloat) _param_vt_trans_min_tm, diff --git a/src/modules/zenoh/zenoh.cpp b/src/modules/zenoh/zenoh.cpp index 6c3fedde76b..2274368fc21 100644 --- a/src/modules/zenoh/zenoh.cpp +++ b/src/modules/zenoh/zenoh.cpp @@ -130,7 +130,7 @@ int ZENOH::generate_rmw_zenoh_topic_keyexpr(const char *topic, const uint8_t *ri "%02x%02x%02x%02x%02x%02x%02x%02x" "%02x%02x%02x%02x%02x%02x%02x%02x" "%02x%02x%02x%02x%02x%02x%02x%02x", - _zenoh_domain_id.get(), topic, type, + _param_zenoh_domain_id.get(), topic, type, rihs_hash[0], rihs_hash[1], rihs_hash[2], rihs_hash[3], rihs_hash[4], rihs_hash[5], rihs_hash[6], rihs_hash[7], rihs_hash[8], rihs_hash[9], rihs_hash[10], rihs_hash[11], @@ -143,7 +143,7 @@ int ZENOH::generate_rmw_zenoh_topic_keyexpr(const char *topic, const uint8_t *ri #else return snprintf(keyexpr, KEYEXPR_SIZE, "%" PRId32 "%s/" KEYEXPR_MSG_NAME "%s_/TypeHashNotSupported", - _zenoh_domain_id.get(), topic, type); + _param_zenoh_domain_id.get(), topic, type); #endif } @@ -180,7 +180,7 @@ int ZENOH::generate_rmw_zenoh_topic_liveliness_keyexpr(const z_id_t *id, const c "%02x%02x%02x%02x%02x%02x%02x%02x" "%02x%02x%02x%02x%02x%02x%02x%02x" "/::,7:,:,:,,", - _zenoh_domain_id.get(), + _param_zenoh_domain_id.get(), id->id[0], id->id[1], id->id[2], id->id[3], id->id[4], id->id[5], id->id[6], id->id[7], id->id[8], id->id[9], id->id[10], id->id[11], id->id[12], id->id[13], id->id[14], id->id[15], @@ -206,7 +206,7 @@ int ZENOH::generate_rmw_zenoh_topic_liveliness_keyexpr(const z_id_t *id, const c "0/11/%s/%%/%%/px4_%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x/%s/" KEYEXPR_MSG_NAME "%s_/TypeHashNotSupported" "/::,7:,:,:,,", - _zenoh_domain_id.get(), + _param_zenoh_domain_id.get(), id->id[0], id->id[1], id->id[2], id->id[3], id->id[4], id->id[5], id->id[6], id->id[7], id->id[8], id->id[9], id->id[10], id->id[11], id->id[12], id->id[13], id->id[14], id->id[15], @@ -447,11 +447,11 @@ int ZENOH::setupTopics(px4_pollfd_struct_t *pfds) int instance; z_publisher_options_t global_opts; z_publisher_options_default(&global_opts); - global_opts.congestion_control = (z_congestion_control_t)_zenoh_pub_cc.get(); - global_opts.is_express = (bool)_zenoh_pub_expr.get(); - global_opts.priority = (z_priority_t)_zenoh_pub_prio.get(); + global_opts.congestion_control = (z_congestion_control_t)_param_zenoh_pub_cc.get(); + global_opts.is_express = (bool)_param_zenoh_pub_expr.get(); + global_opts.priority = (z_priority_t)_param_zenoh_pub_prio.get(); #ifdef Z_FEATURE_UNSTABLE_API - global_opts.reliability = (z_reliability_t)_zenoh_pub_rel.get(); + global_opts.reliability = (z_reliability_t)_param_zenoh_pub_rel.get(); #endif for (i = 0; i < _pub_count; i++) { diff --git a/src/modules/zenoh/zenoh.h b/src/modules/zenoh/zenoh.h index fdb38aa9d76..89488f717e6 100644 --- a/src/modules/zenoh/zenoh.h +++ b/src/modules/zenoh/zenoh.h @@ -89,11 +89,11 @@ public: private: DEFINE_PARAMETERS( - (ParamInt) _zenoh_domain_id, - (ParamInt) _zenoh_pub_cc, - (ParamInt) _zenoh_pub_rel, - (ParamInt) _zenoh_pub_expr, - (ParamInt) _zenoh_pub_prio + (ParamInt) _param_zenoh_domain_id, + (ParamInt) _param_zenoh_pub_cc, + (ParamInt) _param_zenoh_pub_rel, + (ParamInt) _param_zenoh_pub_expr, + (ParamInt) _param_zenoh_pub_prio ) int generate_rmw_zenoh_node_liveliness_keyexpr(const z_id_t *id, char *keyexpr); diff --git a/validation/module_schema.yaml b/validation/module_schema.yaml index 87c3ad4ae16..c656fc48ebc 100644 --- a/validation/module_schema.yaml +++ b/validation/module_schema.yaml @@ -72,9 +72,23 @@ serial_config: # For multiple instances, '${i}' can be used to refer to # an instance, for example in the parameter name or script # command. + # Either an integer, or a Kconfig int symbol (without the + # CONFIG_ prefix) that sets the count per board, plus the + # count used when the symbol is not set. + # A list default shorter than the count repeats its last entry. # Default: 1 - type: integer - min: 1 + anyof: &num_instances + - type: integer + min: 1 + - type: dict + schema: + kconfig: + type: string + required: true + default: + type: integer + min: 1 + required: true supports_networking: # set to true if the module supports networking (UDP) type: boolean @@ -207,9 +221,9 @@ parameters: # For multiple instances, '${i}' can be used to # refer to an instance, for example in the parameter # name or description. + # Same format as serial_config num_instances. # Default: 1 - type: integer - min: 1 + anyof: *num_instances instance_start: # The value of the first instance for multiple # instances, used in '${i}'. If 0, ${i} expands to