2015-05-13 00:16:45 -03:00
# include "Rover.h"
2024-02-21 02:40:36 -04:00
# include <AP_Gripper/AP_Gripper.h>
2012-04-30 04:17:14 -03:00
/*
2020-03-26 20:14:17 -03:00
Rover parameter definitions
2012-04-30 04:17:14 -03:00
*/
2015-10-25 14:03:46 -03:00
const AP_Param : : Info Rover : : var_info [ ] = {
2016-04-17 01:11:01 -03:00
// @Param: FORMAT_VERSION
// @DisplayName: Eeprom format version number
// @Description: This value is incremented when changes are made to the eeprom format
// @User: Advanced
2016-12-20 09:30:04 -04:00
GSCALAR ( format_version , " FORMAT_VERSION " , 1 ) ,
2013-05-20 23:21:38 -03:00
// @Param: LOG_BITMASK
// @DisplayName: Log bitmask
2022-08-08 12:45:14 -03:00
// @Description: Bitmap of what log types to enable in on-board logger. This value is made up of the sum of each of the log types you want to be saved. On boards supporting microSD cards or other large block-storage devices it is usually best just to enable all basic log types by setting this to 65535.
2022-09-07 03:49:51 -03:00
// @Bitmask: 0:Fast Attitude,1:Medium Attitude,2:GPS,3:System Performance,4:Throttle,5:Navigation Tuning,7:IMU,8:Mission Commands,9:Battery Monitor,10:Rangefinder,11:Compass,12:Camera,13:Steering,14:RC Input-Output,19:Raw IMU,20:Video Stabilization,21:Optical Flow
2013-05-20 23:21:38 -03:00
// @User: Advanced
2016-12-20 09:30:04 -04:00
GSCALAR ( log_bitmask , " LOG_BITMASK " , DEFAULT_LOG_BITMASK ) ,
2016-04-17 01:11:01 -03:00
2013-06-03 04:55:22 -03:00
// @Param: RST_SWITCH_CH
// @DisplayName: Reset Switch Channel
2016-12-20 09:30:04 -04:00
// @Description: RC channel to use to reset to last flight mode after geofence takeover.
2013-06-03 04:55:22 -03:00
// @User: Advanced
2016-12-20 09:30:04 -04:00
GSCALAR ( reset_switch_chan , " RST_SWITCH_CH " , 0 ) ,
2013-02-08 06:17:54 -04:00
2013-05-02 18:59:15 -03:00
// @Param: INITIAL_MODE
// @DisplayName: Initial driving mode
2015-08-17 18:25:58 -03:00
// @Description: This selects the mode to start in on boot. This is useful for when you want to start in AUTO mode on boot without a receiver. Usually used in combination with when AUTO_TRIGGER_PIN or AUTO_KICKSTART.
2023-04-20 08:53:05 -03:00
// @CopyValuesFrom: MODE1
2013-05-02 18:59:15 -03:00
// @User: Advanced
2023-09-21 12:47:41 -03:00
GSCALAR ( initial_mode , " INITIAL_MODE " , ( int8_t ) Mode : : Number : : MANUAL ) ,
2013-05-02 18:59:15 -03:00
2020-02-13 05:12:32 -04:00
// @Param: SYSID_THISMAV
2015-05-10 21:21:28 -03:00
// @DisplayName: MAVLink system ID of this vehicle
// @Description: Allows setting an individual MAVLink system id for this vehicle to distinguish it from others on the same network
2014-01-13 21:10:47 -04:00
// @Range: 1 255
2013-02-08 06:17:54 -04:00
// @User: Advanced
2016-12-20 09:30:04 -04:00
GSCALAR ( sysid_this_mav , " SYSID_THISMAV " , MAV_SYSTEM_ID ) ,
2013-02-08 06:17:54 -04:00
// @Param: SYSID_MYGCS
// @DisplayName: MAVLink ground station ID
2016-04-17 01:11:01 -03:00
// @Description: The identifier of the ground station in the MAVLink protocol. Don't change this unless you also modify the ground station to match.
2014-01-13 21:10:47 -04:00
// @Range: 1 255
2023-11-25 23:10:14 -04:00
// @Increment: 1
2013-02-08 06:17:54 -04:00
// @User: Advanced
2016-12-20 09:30:04 -04:00
GSCALAR ( sysid_my_gcs , " SYSID_MYGCS " , 255 ) ,
2012-11-27 20:42:51 -04:00
// @Param: TELEM_DELAY
2016-12-20 09:30:04 -04:00
// @DisplayName: Telemetry startup delay
2012-11-27 20:42:51 -04:00
// @Description: The amount of time (in seconds) to delay radio telemetry to prevent an Xbee bricking on power up
// @User: Standard
2017-05-02 10:34:42 -03:00
// @Units: s
2016-08-29 03:28:47 -03:00
// @Range: 0 30
2012-11-27 20:42:51 -04:00
// @Increment: 1
2012-08-29 20:36:18 -03:00
GSCALAR ( telem_delay , " TELEM_DELAY " , 0 ) ,
2012-11-27 20:42:51 -04:00
2015-06-18 04:37:59 -03:00
// @Param: GCS_PID_MASK
// @DisplayName: GCS PID tuning mask
// @Description: bitmask of PIDs to send MAVLink PID_TUNING messages for
// @User: Advanced
2021-11-26 00:02:20 -04:00
// @Bitmask: 0:Steering,1:Throttle,2:Pitch,3:Left Wheel,4:Right Wheel,5:Sailboat Heel,6:Velocity North,7:Velocity East
2015-06-18 04:37:59 -03:00
GSCALAR ( gcs_pid_mask , " GCS_PID_MASK " , 0 ) ,
2013-10-20 19:09:57 -03:00
2016-12-20 09:30:04 -04:00
// @Param: AUTO_TRIGGER_PIN
// @DisplayName: Auto mode trigger pin
// @Description: pin number to use to enable the throttle in auto mode. If set to -1 then don't use a trigger, otherwise this is a pin number which if held low in auto mode will enable the motor to run. If the switch is released while in AUTO then the motor will stop again. This can be used in combination with INITIAL_MODE to give a 'press button to start' rover with no receiver.
2021-07-14 22:52:11 -03:00
// @Values: -1:Disabled,0:APM TriggerPin0,1:APM TriggerPin1,2:APM TriggerPin2,3:APM TriggerPin3,4:APM TriggerPin4,5:APM TriggerPin5,6:APM TriggerPin6,7:APM TriggerPin7,8:APM TriggerPin8,50:AUX1,51:AUX2,52:AUX3,53:AUX4,54:AUX5,55:AUX6
2019-05-17 10:39:25 -03:00
// @User: Standard
2016-12-20 09:30:04 -04:00
GSCALAR ( auto_trigger_pin , " AUTO_TRIGGER_PIN " , - 1 ) ,
// @Param: AUTO_KICKSTART
// @DisplayName: Auto mode trigger kickstart acceleration
// @Description: X acceleration in meters/second/second to use to trigger the motor start in auto mode. If set to zero then auto throttle starts immediately when the mode switch happens, otherwise the rover waits for the X acceleration to go above this value before it will start the motor
// @Units: m/s/s
// @Range: 0 20
// @Increment: 0.1
2019-05-17 10:39:25 -03:00
// @User: Standard
2016-12-20 09:30:04 -04:00
GSCALAR ( auto_kickstart , " AUTO_KICKSTART " , 0.0f ) ,
2013-03-21 19:38:25 -03:00
2013-02-08 06:17:54 -04:00
// @Param: CRUISE_SPEED
2013-02-21 17:38:13 -04:00
// @DisplayName: Target cruise speed in auto modes
2013-02-08 06:17:54 -04:00
// @Description: The target speed in auto missions.
// @Units: m/s
// @Range: 0 100
2013-02-07 18:21:22 -04:00
// @Increment: 0.1
// @User: Standard
2018-03-09 00:19:21 -04:00
GSCALAR ( speed_cruise , " CRUISE_SPEED " , CRUISE_SPEED ) ,
2013-02-08 06:17:54 -04:00
2014-02-16 19:08:59 -04:00
2013-02-08 06:17:54 -04:00
// @Param: CRUISE_THROTTLE
// @DisplayName: Base throttle percentage in auto
2013-02-21 17:38:13 -04:00
// @Description: The base throttle percentage to use in auto mode. The CRUISE_SPEED parameter controls the target speed, but the rover starts with the CRUISE_THROTTLE setting as the initial estimate for how much throttle is needed to achieve that speed. It then adjusts the throttle based on how fast the rover is actually going.
2017-05-02 10:34:42 -03:00
// @Units: %
2013-02-08 06:17:54 -04:00
// @Range: 0 100
// @Increment: 1
// @User: Standard
2016-12-20 09:30:04 -04:00
GSCALAR ( throttle_cruise , " CRUISE_THROTTLE " , 50 ) ,
2013-02-08 06:17:54 -04:00
2017-11-27 09:11:45 -04:00
// @Param: PILOT_STEER_TYPE
// @DisplayName: Pilot input steering type
2021-10-19 23:20:14 -03:00
// @Description: Pilot RC input interpretation
2017-11-27 09:11:45 -04:00
// @Values: 0:Default,1:Two Paddles Input,2:Direction reversed when backing up,3:Direction unchanged when backing up
2013-03-14 21:04:33 -03:00
// @User: Standard
2017-11-27 09:11:45 -04:00
GSCALAR ( pilot_steer_type , " PILOT_STEER_TYPE " , 0 ) ,
2013-03-14 21:04:33 -03:00
2013-02-08 06:17:54 -04:00
// @Param: FS_ACTION
// @DisplayName: Failsafe Action
// @Description: What to do on a failsafe event
2024-05-05 20:21:37 -03:00
// @Values: 0:Nothing,1:RTL,2:Hold,3:SmartRTL or RTL,4:SmartRTL or Hold,5:Terminate
2013-02-08 06:17:54 -04:00
// @User: Standard
2023-09-21 11:22:37 -03:00
GSCALAR ( fs_action , " FS_ACTION " , ( int8_t ) FailsafeAction : : Hold ) ,
2013-02-08 06:17:54 -04:00
// @Param: FS_TIMEOUT
// @DisplayName: Failsafe timeout
2018-10-31 02:29:10 -03:00
// @Description: The time in seconds that a failsafe condition must persist before the failsafe action is triggered
2017-05-02 10:34:42 -03:00
// @Units: s
2018-10-31 02:29:10 -03:00
// @Range: 1 100
// @Increment: 0.5
2013-02-08 06:17:54 -04:00
// @User: Standard
2018-10-31 02:29:10 -03:00
GSCALAR ( fs_timeout , " FS_TIMEOUT " , 1.5 ) ,
2013-02-08 06:17:54 -04:00
// @Param: FS_THR_ENABLE
2012-11-27 20:42:51 -04:00
// @DisplayName: Throttle Failsafe Enable
2013-03-29 08:46:58 -03:00
// @Description: The throttle failsafe allows you to configure a software failsafe activated by a setting on the throttle input channel to a low value. This can be used to detect the RC transmitter going out of range. Failsafe will be triggered when the throttle channel goes below the FS_THR_VALUE for FS_TIMEOUT seconds.
2018-11-13 04:40:40 -04:00
// @Values: 0:Disabled,1:Enabled,2:Enabled Continue with Mission in Auto
2012-11-27 20:42:51 -04:00
// @User: Standard
2018-11-13 04:40:40 -04:00
GSCALAR ( fs_throttle_enabled , " FS_THR_ENABLE " , FS_THR_ENABLED ) ,
2012-11-27 20:42:51 -04:00
2013-02-08 06:17:54 -04:00
// @Param: FS_THR_VALUE
2012-11-27 20:42:51 -04:00
// @DisplayName: Throttle Failsafe Value
2016-04-17 01:11:01 -03:00
// @Description: The PWM level on the throttle channel below which throttle failsafe triggers.
2017-05-24 09:28:52 -03:00
// @Range: 910 1100
2013-06-18 03:57:11 -03:00
// @Increment: 1
2012-11-27 20:42:51 -04:00
// @User: Standard
2016-12-20 09:30:04 -04:00
GSCALAR ( fs_throttle_value , " FS_THR_VALUE " , 910 ) ,
2012-11-27 20:42:51 -04:00
2013-02-07 18:21:22 -04:00
// @Param: FS_GCS_ENABLE
2012-11-27 20:42:51 -04:00
// @DisplayName: GCS failsafe enable
2013-03-29 08:46:58 -03:00
// @Description: Enable ground control station telemetry failsafe. When enabled the Rover will execute the FS_ACTION when it fails to receive MAVLink heartbeat packets for FS_TIMEOUT seconds.
2018-11-13 04:40:40 -04:00
// @Values: 0:Disabled,1:Enabled,2:Enabled Continue with Mission in Auto
2012-11-27 20:42:51 -04:00
// @User: Standard
2018-11-13 04:40:40 -04:00
GSCALAR ( fs_gcs_enabled , " FS_GCS_ENABLE " , FS_GCS_DISABLED ) ,
2013-02-08 06:17:54 -04:00
2016-11-21 12:08:24 -04:00
// @Param: FS_CRASH_CHECK
// @DisplayName: Crash check action
// @Description: What to do on a crash event. When enabled the rover will go to hold if a crash is detected.
2017-12-23 00:52:21 -04:00
// @Values: 0:Disabled,1:Hold,2:HoldAndDisarm
2016-11-21 12:08:24 -04:00
// @User: Standard
2017-03-15 00:01:49 -03:00
GSCALAR ( fs_crash_check , " FS_CRASH_CHECK " , FS_CRASH_DISABLE ) ,
2016-11-21 12:08:24 -04:00
2018-11-01 04:04:58 -03:00
// @Param: FS_EKF_ACTION
// @DisplayName: EKF Failsafe Action
// @Description: Controls the action that will be taken when an EKF failsafe is invoked
2020-10-26 08:04:58 -03:00
// @Values: 0:Disabled,1:Hold,2:ReportOnly
2018-11-01 04:04:58 -03:00
// @User: Advanced
2020-11-02 14:38:14 -04:00
GSCALAR ( fs_ekf_action , " FS_EKF_ACTION " , FS_EKF_HOLD ) ,
2018-11-01 04:04:58 -03:00
// @Param: FS_EKF_THRESH
// @DisplayName: EKF failsafe variance threshold
// @Description: Allows setting the maximum acceptable compass and velocity variance
// @Values: 0.6:Strict, 0.8:Default, 1.0:Relaxed
// @User: Advanced
GSCALAR ( fs_ekf_thresh , " FS_EKF_THRESH " , 0.8f ) ,
2013-02-07 18:21:22 -04:00
// @Param: MODE_CH
// @DisplayName: Mode channel
2013-02-08 06:17:54 -04:00
// @Description: RC Channel to use for driving mode control
2012-11-27 20:42:51 -04:00
// @User: Advanced
2016-12-20 09:30:04 -04:00
GSCALAR ( mode_channel , " MODE_CH " , MODE_CHANNEL ) ,
2012-11-27 20:42:51 -04:00
2013-02-07 18:21:22 -04:00
// @Param: MODE1
// @DisplayName: Mode1
2023-04-20 08:53:05 -03:00
// @Values: 0:Manual,1:Acro,3:Steering,4:Hold,5:Loiter,6:Follow,7:Simple,8:Dock,9:Circle,10:Auto,11:RTL,12:SmartRTL,15:Guided
2012-11-27 20:42:51 -04:00
// @User: Standard
2013-02-08 06:17:54 -04:00
// @Description: Driving mode for switch position 1 (910 to 1230 and above 2049)
2023-09-21 12:47:41 -03:00
GSCALAR ( mode1 , " MODE1 " , ( int8_t ) Mode : : Number : : MANUAL ) ,
2012-11-27 20:42:51 -04:00
2013-02-07 18:21:22 -04:00
// @Param: MODE2
// @DisplayName: Mode2
2013-02-08 06:17:54 -04:00
// @Description: Driving mode for switch position 2 (1231 to 1360)
2021-12-14 00:55:46 -04:00
// @CopyValuesFrom: MODE1
2012-11-27 20:42:51 -04:00
// @User: Standard
2023-09-21 12:47:41 -03:00
GSCALAR ( mode2 , " MODE2 " , ( int8_t ) Mode : : Number : : MANUAL ) ,
2012-11-27 20:42:51 -04:00
2013-02-07 18:21:22 -04:00
// @Param: MODE3
2022-12-29 22:10:57 -04:00
// @CopyFieldsFrom: MODE1
2013-02-07 18:21:22 -04:00
// @DisplayName: Mode3
2013-02-08 06:17:54 -04:00
// @Description: Driving mode for switch position 3 (1361 to 1490)
2023-09-21 12:47:41 -03:00
GSCALAR ( mode3 , " MODE3 " , ( int8_t ) Mode : : Number : : MANUAL ) ,
2012-11-27 20:42:51 -04:00
2013-02-07 18:21:22 -04:00
// @Param: MODE4
2022-12-29 22:10:57 -04:00
// @CopyFieldsFrom: MODE1
2013-02-07 18:21:22 -04:00
// @DisplayName: Mode4
2013-02-08 06:17:54 -04:00
// @Description: Driving mode for switch position 4 (1491 to 1620)
2023-09-21 12:47:41 -03:00
GSCALAR ( mode4 , " MODE4 " , ( int8_t ) Mode : : Number : : MANUAL ) ,
2012-11-27 20:42:51 -04:00
2013-02-07 18:21:22 -04:00
// @Param: MODE5
2022-12-29 22:10:57 -04:00
// @CopyFieldsFrom: MODE1
2013-02-07 18:21:22 -04:00
// @DisplayName: Mode5
2013-02-08 06:17:54 -04:00
// @Description: Driving mode for switch position 5 (1621 to 1749)
2023-09-21 12:47:41 -03:00
GSCALAR ( mode5 , " MODE5 " , ( int8_t ) Mode : : Number : : MANUAL ) ,
2012-11-27 20:42:51 -04:00
2013-02-07 18:21:22 -04:00
// @Param: MODE6
2022-12-29 22:10:57 -04:00
// @CopyFieldsFrom: MODE1
2013-02-07 18:21:22 -04:00
// @DisplayName: Mode6
2013-02-08 06:17:54 -04:00
// @Description: Driving mode for switch position 6 (1750 to 2049)
2023-09-21 12:47:41 -03:00
GSCALAR ( mode6 , " MODE6 " , ( int8_t ) Mode : : Number : : MANUAL ) ,
2012-08-06 22:24:20 -03:00
2016-12-20 09:30:04 -04:00
// variables not in the g class which contain EEPROM saved variables
2013-06-03 04:55:22 -03:00
2021-12-04 00:22:56 -04:00
// @Group: COMPASS_
2016-03-15 11:16:23 -03:00
// @Path: ../libraries/AP_Compass/AP_Compass.cpp
2021-12-04 00:22:56 -04:00
GOBJECT ( compass , " COMPASS_ " , Compass ) ,
2013-06-03 04:55:22 -03:00
2013-06-03 21:37:05 -03:00
// @Group: SCHED_
// @Path: ../libraries/AP_Scheduler/AP_Scheduler.cpp
GOBJECT ( scheduler , " SCHED_ " , AP_Scheduler ) ,
2020-12-03 04:13:33 -04:00
// @Group: BARO
2014-02-23 18:25:50 -04:00
// @Path: ../libraries/AP_Baro/AP_Baro.cpp
2020-12-03 04:13:33 -04:00
GOBJECT ( barometer , " BARO " , AP_Baro ) ,
2014-02-23 18:25:50 -04:00
2023-06-06 05:05:07 -03:00
# if AP_RELAY_ENABLED
2023-10-03 21:18:04 -03:00
// @Group: RELAY
2013-06-24 23:48:58 -03:00
// @Path: ../libraries/AP_Relay/AP_Relay.cpp
2023-10-03 21:18:04 -03:00
GOBJECT ( relay , " RELAY " , AP_Relay ) ,
2023-06-06 05:05:07 -03:00
# endif
2013-06-24 23:48:58 -03:00
2013-06-03 06:33:59 -03:00
// @Group: RCMAP_
// @Path: ../libraries/AP_RCMapper/AP_RCMapper.cpp
GOBJECT ( rcmap , " RCMAP_ " , RCMapper ) ,
2013-09-11 20:51:36 -03:00
// @Group: SR0_
2015-05-20 22:42:59 -03:00
// @Path: GCS_Mavlink.cpp
2019-06-19 08:26:19 -03:00
GOBJECTN ( _gcs . chan_parameters [ 0 ] , gcs0 , " SR0_ " , GCS_MAVLINK_Parameters ) ,
2013-09-11 20:51:36 -03:00
2020-12-22 15:44:22 -04:00
# if MAVLINK_COMM_NUM_BUFFERS >= 2
2013-11-23 06:57:26 -04:00
// @Group: SR1_
2015-05-20 22:42:59 -03:00
// @Path: GCS_Mavlink.cpp
2019-06-19 08:26:19 -03:00
GOBJECTN ( _gcs . chan_parameters [ 1 ] , gcs1 , " SR1_ " , GCS_MAVLINK_Parameters ) ,
2020-12-22 15:44:22 -04:00
# endif
2013-11-23 06:57:26 -04:00
2020-12-22 15:44:22 -04:00
# if MAVLINK_COMM_NUM_BUFFERS >= 3
2013-11-23 06:57:26 -04:00
// @Group: SR2_
2015-05-20 22:42:59 -03:00
// @Path: GCS_Mavlink.cpp
2019-06-19 08:26:19 -03:00
GOBJECTN ( _gcs . chan_parameters [ 2 ] , gcs2 , " SR2_ " , GCS_MAVLINK_Parameters ) ,
2020-12-22 15:44:22 -04:00
# endif
2012-11-07 03:28:20 -04:00
2020-12-22 15:44:22 -04:00
# if MAVLINK_COMM_NUM_BUFFERS >= 4
2015-05-15 01:24:59 -03:00
// @Group: SR3_
2015-05-20 22:42:59 -03:00
// @Path: GCS_Mavlink.cpp
2019-06-19 08:26:19 -03:00
GOBJECTN ( _gcs . chan_parameters [ 3 ] , gcs3 , " SR3_ " , GCS_MAVLINK_Parameters ) ,
2020-12-22 15:44:22 -04:00
# endif
# if MAVLINK_COMM_NUM_BUFFERS >= 5
// @Group: SR4_
// @Path: GCS_Mavlink.cpp
GOBJECTN ( _gcs . chan_parameters [ 4 ] , gcs4 , " SR4_ " , GCS_MAVLINK_Parameters ) ,
# endif
# if MAVLINK_COMM_NUM_BUFFERS >= 6
// @Group: SR5_
// @Path: GCS_Mavlink.cpp
GOBJECTN ( _gcs . chan_parameters [ 5 ] , gcs5 , " SR5_ " , GCS_MAVLINK_Parameters ) ,
# endif
# if MAVLINK_COMM_NUM_BUFFERS >= 7
// @Group: SR6_
// @Path: GCS_Mavlink.cpp
GOBJECTN ( _gcs . chan_parameters [ 6 ] , gcs6 , " SR6_ " , GCS_MAVLINK_Parameters ) ,
# endif
2015-05-15 01:24:59 -03:00
2024-02-28 00:57:47 -04:00
// AP_SerialManager was here
2015-01-28 00:56:36 -04:00
2023-11-07 18:23:42 -04:00
# if AP_RANGEFINDER_ENABLED
2014-07-16 16:18:10 -03:00
// @Group: RNGFND
2019-11-10 22:47:52 -04:00
// @Path: ../libraries/AP_RangeFinder/AP_RangeFinder.cpp
2017-07-13 08:36:44 -03:00
GOBJECT ( rangefinder , " RNGFND " , RangeFinder ) ,
2023-11-07 18:23:42 -04:00
# endif
2013-02-28 21:00:48 -04:00
2023-03-08 06:40:11 -04:00
// @Group: INS
2012-11-07 03:28:20 -04:00
// @Path: ../libraries/AP_InertialSensor/AP_InertialSensor.cpp
2023-03-08 06:40:11 -04:00
GOBJECT ( ins , " INS " , AP_InertialSensor ) ,
2012-08-06 22:24:20 -03:00
2021-10-29 21:37:06 -03:00
# if AP_SIM_ENABLED
2012-11-27 08:20:25 -04:00
// @Group: SIM_
// @Path: ../libraries/SITL/SITL.cpp
2021-07-30 07:10:10 -03:00
GOBJECT ( sitl , " SIM_ " , SITL : : SIM ) ,
2012-11-27 08:20:25 -04:00
# endif
2012-11-17 02:45:20 -04:00
// @Group: AHRS_
// @Path: ../libraries/AP_AHRS/AP_AHRS.cpp
GOBJECT ( ahrs , " AHRS_ " , AP_AHRS ) ,
2022-06-02 05:28:26 -03:00
# if AP_CAMERA_ENABLED
2023-02-14 00:04:37 -04:00
// @Group: CAM
2013-07-14 20:57:00 -03:00
// @Path: ../libraries/AP_Camera/AP_Camera.cpp
2023-02-14 00:04:37 -04:00
GOBJECT ( camera , " CAM " , AP_Camera ) ,
2013-07-14 20:57:00 -03:00
# endif
2023-03-22 05:45:41 -03:00
# if AC_PRECLAND_ENABLED
2022-05-30 06:26:55 -03:00
// @Group: PLND_
// @Path: ../libraries/AC_PrecLand/AC_PrecLand.cpp
GOBJECT ( precland , " PLND_ " , AC_PrecLand ) ,
# endif
2020-07-24 14:23:45 -03:00
# if HAL_MOUNT_ENABLED
2015-04-28 21:08:06 -03:00
// @Group: MNT
2013-07-14 20:57:00 -03:00
// @Path: ../libraries/AP_Mount/AP_Mount.cpp
2015-01-12 08:12:31 -04:00
GOBJECT ( camera_mount , " MNT " , AP_Mount ) ,
2013-07-14 20:57:00 -03:00
# endif
2015-10-30 02:56:41 -03:00
// @Group: ARMING_
// @Path: ../libraries/AP_Arming/AP_Arming.cpp
GOBJECT ( arming , " ARMING_ " , AP_Arming ) ,
2015-08-25 23:15:16 -03:00
// @Group: BATT
2013-10-02 03:07:28 -03:00
// @Path: ../libraries/AP_BattMonitor/AP_BattMonitor.cpp
2014-12-09 09:14:22 -04:00
GOBJECT ( battery , " BATT " , AP_BattMonitor ) ,
2013-10-02 03:07:28 -03:00
2014-01-19 21:57:59 -04:00
// @Group: BRD_
// @Path: ../libraries/AP_BoardConfig/AP_BoardConfig.cpp
GOBJECT ( BoardConfig , " BRD_ " , AP_BoardConfig ) ,
2020-05-31 08:50:19 -03:00
# if HAL_MAX_CAN_PROTOCOL_DRIVERS
2017-05-06 06:11:40 -03:00
// @Group: CAN_
2020-05-31 08:50:19 -03:00
// @Path: ../libraries/AP_CANManager/AP_CANManager.cpp
GOBJECT ( can_mgr , " CAN_ " , AP_CANManager ) ,
2017-05-06 06:11:40 -03:00
# endif
2014-03-31 16:18:27 -03:00
// GPS driver
2020-12-30 11:02:10 -04:00
// @Group: GPS
2014-03-31 16:18:27 -03:00
// @Path: ../libraries/AP_GPS/AP_GPS.cpp
2020-12-30 11:02:10 -04:00
GOBJECT ( gps , " GPS " , AP_GPS ) ,
2014-03-31 16:18:27 -03:00
2020-01-15 08:05:49 -04:00
# if HAL_NAVEKF2_AVAILABLE
2017-08-10 01:14:33 -03:00
// @Group: EK2_
// @Path: ../libraries/AP_NavEKF2/AP_NavEKF2.cpp
2019-12-10 06:45:39 -04:00
GOBJECTN ( ahrs . EKF2 , NavEKF2 , " EK2_ " , NavEKF2 ) ,
2020-01-15 08:05:49 -04:00
# endif
2017-08-10 01:14:33 -03:00
2020-01-15 08:05:49 -04:00
# if HAL_NAVEKF3_AVAILABLE
2017-08-10 01:14:33 -03:00
// @Group: EK3_
// @Path: ../libraries/AP_NavEKF3/AP_NavEKF3.cpp
2019-12-10 06:45:39 -04:00
GOBJECTN ( ahrs . EKF3 , NavEKF3 , " EK3_ " , NavEKF3 ) ,
2017-08-10 01:14:33 -03:00
# endif
2014-02-21 00:51:34 -04:00
2022-07-15 08:53:42 -03:00
# if AP_RPM_ENABLED
2018-12-30 16:43:39 -04:00
// @Group: RPM
// @Path: ../libraries/AP_RPM/AP_RPM.cpp
GOBJECT ( rpm_sensor , " RPM " , AP_RPM ) ,
2022-07-15 08:53:42 -03:00
# endif
2018-12-30 16:43:39 -04:00
2014-03-10 05:42:44 -03:00
// @Group: MIS_
// @Path: ../libraries/AP_Mission/AP_Mission.cpp
2018-12-11 20:10:20 -04:00
GOBJECTN ( mode_auto . mission , mission , " MIS_ " , AP_Mission ) ,
2016-12-20 09:30:04 -04:00
2024-07-23 07:51:07 -03:00
# if AP_RSSI_ENABLED
2015-08-28 03:00:12 -03:00
// @Group: RSSI_
// @Path: ../libraries/AP_RSSI/AP_RSSI.cpp
2016-12-20 09:30:04 -04:00
GOBJECT ( rssi , " RSSI_ " , AP_RSSI ) ,
2024-07-23 07:51:07 -03:00
# endif
2014-03-10 05:42:44 -03:00
2015-12-03 16:48:16 -04:00
// @Group: NTF_
// @Path: ../libraries/AP_Notify/AP_Notify.cpp
GOBJECT ( notify , " NTF_ " , AP_Notify ) ,
2021-08-12 00:38:23 -03:00
# if HAL_BUTTON_ENABLED
2016-07-21 22:24:35 -03:00
// @Group: BTN_
// @Path: ../libraries/AP_Button/AP_Button.cpp
GOBJECT ( button , " BTN_ " , AP_Button ) ,
2021-08-12 00:38:23 -03:00
# endif
2016-10-25 22:37:08 -03:00
// @Group:
// @Path: Parameters.cpp
GOBJECT ( g2 , " " , ParametersG2 ) ,
2020-10-28 16:39:43 -03:00
# if OSD_ENABLED || OSD_PARAM_ENABLED
2018-08-27 16:55:29 -03:00
// @Group: OSD
// @Path: ../libraries/AP_OSD/AP_OSD.cpp
GOBJECT ( osd , " OSD " , AP_OSD ) ,
# endif
2022-09-07 03:49:51 -03:00
# if AP_OPTICALFLOW_ENABLED
// @Group: FLOW
// @Path: ../libraries/AP_OpticalFlow/AP_OpticalFlow.cpp
GOBJECT ( optflow , " FLOW " , AP_OpticalFlow ) ,
# endif
2019-12-01 13:02:18 -04:00
// @Group:
// @Path: ../libraries/AP_Vehicle/AP_Vehicle.cpp
2023-01-03 21:39:14 -04:00
PARAM_VEHICLE_INFO ,
2019-12-01 13:02:18 -04:00
2016-12-20 09:30:04 -04:00
AP_VAREND
2012-04-30 04:17:14 -03:00
} ;
2016-10-25 22:37:08 -03:00
/*
2 nd group of parameters
*/
const AP_Param : : GroupInfo ParametersG2 : : var_info [ ] = {
2024-01-30 00:15:48 -04:00
// 1 was AP_Stats
2017-02-28 02:07:59 -04:00
// @Param: SYSID_ENFORCE
2016-11-21 11:06:25 -04:00
// @DisplayName: GCS sysid enforcement
// @Description: This controls whether packets from other than the expected GCS system ID will be accepted
// @Values: 0:NotEnforced,1:Enforced
// @User: Advanced
AP_GROUPINFO ( " SYSID_ENFORCE " , 2 , ParametersG2 , sysid_enforce , 0 ) ,
2017-01-06 06:31:10 -04:00
// @Group: SERVO
2017-02-05 22:15:51 -04:00
// @Path: ../libraries/SRV_Channel/SRV_Channels.cpp
2017-01-06 06:31:10 -04:00
AP_SUBGROUPINFO ( servo_channels , " SERVO " , 3 , ParametersG2 , SRV_Channels ) ,
// @Group: RC
2018-08-03 23:28:09 -03:00
// @Path: ../libraries/RC_Channel/RC_Channels_VarInfo.h
2018-05-07 23:35:08 -03:00
AP_SUBGROUPINFO ( rc_channels , " RC " , 4 , ParametersG2 , RC_Channels_Rover ) ,
2017-01-30 10:21:55 -04:00
2024-08-04 21:54:28 -03:00
# if AP_ROVER_ADVANCED_FAILSAFE_ENABLED
2017-01-30 10:21:55 -04:00
// @Group: AFS_
// @Path: ../libraries/AP_AdvancedFailsafe/AP_AdvancedFailsafe.cpp
AP_SUBGROUPINFO ( afs , " AFS_ " , 5 , ParametersG2 , AP_AdvancedFailsafe ) ,
# endif
2023-04-09 05:54:09 -03:00
# if AP_BEACON_ENABLED
2017-04-03 17:46:12 -03:00
// @Group: BCN
// @Path: ../libraries/AP_Beacon/AP_Beacon.cpp
AP_SUBGROUPINFO ( beacon , " BCN " , 6 , ParametersG2 , AP_Beacon ) ,
2023-04-09 05:54:09 -03:00
# endif
2017-04-03 17:46:12 -03:00
2020-04-06 01:13:35 -03:00
// 7 was used by AP_VisualOdometry
2017-06-01 04:39:49 -03:00
2017-07-06 00:06:20 -03:00
// @Group: MOT_
2021-07-18 11:04:27 -03:00
// @Path: ../libraries/AR_Motors/AP_MotorsUGV.cpp
2017-07-06 00:06:20 -03:00
AP_SUBGROUPINFO ( motors , " MOT_ " , 8 , ParametersG2 , AP_MotorsUGV ) ,
2017-07-27 09:56:56 -03:00
// @Group: WENC
2017-07-11 23:02:51 -03:00
// @Path: ../libraries/AP_WheelEncoder/AP_WheelEncoder.cpp
2017-07-27 09:56:56 -03:00
AP_SUBGROUPINFO ( wheel_encoder , " WENC " , 9 , ParametersG2 , AP_WheelEncoder ) ,
2017-07-11 23:02:51 -03:00
2017-08-08 02:37:21 -03:00
// @Group: ATC
// @Path: ../libraries/APM_Control/AR_AttitudeControl.cpp
AP_SUBGROUPINFO ( attitude_control , " ATC " , 10 , ParametersG2 , AR_AttitudeControl ) ,
2017-08-10 05:29:21 -03:00
// @Param: TURN_RADIUS
// @DisplayName: Turn radius of vehicle
// @Description: Turn radius of vehicle in meters while at low speeds. Lower values produce tighter turns in steering mode
// @Units: m
// @Range: 0 10
// @Increment: 0.1
// @User: Standard
AP_GROUPINFO ( " TURN_RADIUS " , 11 , ParametersG2 , turn_radius , 0.9 ) ,
2017-11-28 02:59:13 -04:00
// @Param: ACRO_TURN_RATE
// @DisplayName: Acro mode turn rate maximum
// @Description: Acro mode turn rate maximum
// @Units: deg/s
// @Range: 0 360
// @Increment: 1
// @User: Standard
AP_GROUPINFO ( " ACRO_TURN_RATE " , 12 , ParametersG2 , acro_turn_rate , 180.0f ) ,
2017-11-29 21:58:11 -04:00
// @Group: SRTL_
// @Path: ../libraries/AP_SmartRTL/AP_SmartRTL.cpp
AP_SUBGROUPINFO ( smart_rtl , " SRTL_ " , 13 , ParametersG2 , AP_SmartRTL ) ,
2019-04-29 03:31:45 -03:00
// 14 was WP_SPEED and should not be re-used
2017-12-05 21:41:28 -04:00
// @Param: RTL_SPEED
// @DisplayName: Return-to-Launch speed default
// @Description: Return-to-Launch speed default. If zero use WP_SPEED or CRUISE_SPEED.
// @Units: m/s
// @Range: 0 100
// @Increment: 0.1
// @User: Standard
AP_GROUPINFO ( " RTL_SPEED " , 15 , ParametersG2 , rtl_speed , 0.0f ) ,
2017-12-06 22:37:42 -04:00
// @Param: FRAME_CLASS
// @DisplayName: Frame Class
// @Description: Frame Class
2018-06-05 05:56:46 -03:00
// @Values: 0:Undefined,1:Rover,2:Boat,3:BalanceBot
2017-12-06 22:37:42 -04:00
// @User: Standard
AP_GROUPINFO ( " FRAME_CLASS " , 16 , ParametersG2 , frame_class , 1 ) ,
2021-03-25 05:47:29 -03:00
# if HAL_PROXIMITY_ENABLED
2017-08-16 07:57:42 -03:00
// @Group: PRX
// @Path: ../libraries/AP_Proximity/AP_Proximity.cpp
AP_SUBGROUPINFO ( proximity , " PRX " , 18 , ParametersG2 , AP_Proximity ) ,
2021-03-25 05:47:29 -03:00
# endif
2017-08-16 07:57:42 -03:00
2024-03-09 03:49:48 -04:00
# if AP_AVOIDANCE_ENABLED
2017-12-12 02:12:16 -04:00
// @Group: AVOID_
// @Path: ../libraries/AC_Avoidance/AC_Avoid.cpp
AP_SUBGROUPINFO ( avoid , " AVOID_ " , 19 , ParametersG2 , AC_Avoid ) ,
2024-03-09 03:49:48 -04:00
# endif
2017-12-12 02:12:16 -04:00
2019-04-29 03:31:45 -03:00
// 20 was PIVOT_TURN_RATE and should not be re-used
2018-05-18 05:38:06 -03:00
2018-06-20 08:11:58 -03:00
// @Param: BAL_PITCH_MAX
// @DisplayName: BalanceBot Maximum Pitch
// @Description: Pitch angle in degrees at 100% throttle
// @Units: deg
2022-11-07 07:02:32 -04:00
// @Range: 0 15
2018-06-20 08:11:58 -03:00
// @Increment: 0.1
// @User: Standard
2022-11-07 07:02:32 -04:00
AP_GROUPINFO ( " BAL_PITCH_MAX " , 21 , ParametersG2 , bal_pitch_max , 10 ) ,
2018-06-20 08:11:58 -03:00
2018-06-27 10:53:30 -03:00
// @Param: CRASH_ANGLE
// @DisplayName: Crash Angle
// @Description: Pitch/Roll angle limit in degrees for crash check. Zero disables check
2018-06-21 09:50:28 -03:00
// @Units: deg
// @Range: 0 60
2018-06-27 10:53:30 -03:00
// @Increment: 1
2018-06-21 09:50:28 -03:00
// @User: Standard
2018-06-27 10:53:30 -03:00
AP_GROUPINFO ( " CRASH_ANGLE " , 22 , ParametersG2 , crash_angle , 0 ) ,
2018-06-21 09:50:28 -03:00
2023-08-11 09:28:32 -03:00
# if AP_FOLLOW_ENABLED
2018-05-24 01:47:07 -03:00
// @Group: FOLL
// @Path: ../libraries/AP_Follow/AP_Follow.cpp
AP_SUBGROUPINFO ( follow , " FOLL " , 23 , ParametersG2 , AP_Follow ) ,
2023-08-11 09:28:32 -03:00
# endif
2018-06-21 09:50:28 -03:00
2018-05-31 06:26:07 -03:00
// @Param: FRAME_TYPE
// @DisplayName: Frame Type
// @Description: Frame Type
2024-07-15 17:07:53 -03:00
// @Values: 0:Undefined,1:Omni3,2:OmniX,3:OmniPlus,4:Omni3Mecanum
2018-05-31 06:26:07 -03:00
// @User: Standard
// @RebootRequired: True
AP_GROUPINFO ( " FRAME_TYPE " , 24 , ParametersG2 , frame_type , 0 ) ,
2018-08-07 01:22:51 -03:00
// @Param: LOIT_TYPE
// @DisplayName: Loiter type
2019-02-05 20:03:35 -04:00
// @Description: Loiter behaviour when moving to the target point
2019-10-28 10:37:13 -03:00
// @Values: 0:Forward or reverse to target point,1:Always face bow towards target point,2:Always face stern towards target point
2018-08-07 01:22:51 -03:00
// @User: Standard
AP_GROUPINFO ( " LOIT_TYPE " , 25 , ParametersG2 , loit_type , 0 ) ,
2020-01-17 20:36:11 -04:00
# if HAL_SPRAYER_ENABLED
2020-02-13 05:11:43 -04:00
// @Group: SPRAY_
2018-06-08 06:22:55 -03:00
// @Path: ../libraries/AC_Sprayer/AC_Sprayer.cpp
AP_SUBGROUPINFO ( sprayer , " SPRAY_ " , 26 , ParametersG2 , AC_Sprayer ) ,
2020-01-17 20:36:11 -04:00
# endif
2018-06-08 06:22:55 -03:00
2018-08-08 00:48:30 -03:00
// @Group: WRC
// @Path: ../libraries/AP_WheelEncoder/AP_WheelRateControl.cpp
AP_SUBGROUPINFO ( wheel_rate_control , " WRC " , 27 , ParametersG2 , AP_WheelRateControl ) ,
2023-08-18 02:38:03 -03:00
# if HAL_RALLY_ENABLED
2018-08-29 21:54:12 -03:00
// @Group: RALLY_
// @Path: AP_Rally.cpp,../libraries/AP_Rally/AP_Rally.cpp
AP_SUBGROUPINFO ( rally , " RALLY_ " , 28 , ParametersG2 , AP_Rally_Rover ) ,
# endif
2018-07-02 04:21:37 -03:00
// @Param: SIMPLE_TYPE
// @DisplayName: Simple_Type
// @Description: Simple mode types
// @Values: 0:InitialHeading,1:CardinalDirections
// @User: Standard
// @RebootRequired: True
AP_GROUPINFO ( " SIMPLE_TYPE " , 29 , ParametersG2 , simple_type , 0 ) ,
2018-09-25 10:09:21 -03:00
// @Param: LOIT_RADIUS
// @DisplayName: Loiter radius
// @Description: Vehicle will drift when within this distance of the target position
// @Units: m
// @Range: 0 20
// @Increment: 1
// @User: Standard
AP_GROUPINFO ( " LOIT_RADIUS " , 30 , ParametersG2 , loit_radius , 2 ) ,
2018-09-25 10:09:47 -03:00
// @Group: WNDVN_
// @Path: ../libraries/AP_WindVane/AP_WindVane.cpp
AP_SUBGROUPINFO ( windvane , " WNDVN_ " , 31 , ParametersG2 , AP_WindVane ) ,
2019-05-07 15:20:43 -03:00
// 32 to 36 were old sailboat params
2018-09-14 04:09:07 -03:00
2022-01-09 21:37:11 -04:00
// 37 was airspeed
2018-09-14 04:09:07 -03:00
2018-11-08 12:14:45 -04:00
// @Param: MIS_DONE_BEHAVE
// @DisplayName: Mission done behave
2019-10-08 01:21:18 -03:00
// @Description: Behaviour after mission completes
2023-03-02 00:37:36 -04:00
// @Values: 0:Hold in Auto Mode,1:Loiter in Auto Mode,2:Acro Mode,3:Manual Mode
2018-11-08 12:14:45 -04:00
// @User: Standard
AP_GROUPINFO ( " MIS_DONE_BEHAVE " , 38 , ParametersG2 , mis_done_behave , 0 ) ,
2024-02-21 02:40:36 -04:00
// 39 was AP_Gripper
2019-02-07 19:45:23 -04:00
2018-12-13 03:49:08 -04:00
// @Param: BAL_PITCH_TRIM
// @DisplayName: Balance Bot pitch trim angle
// @Description: Balance Bot pitch trim for balancing. This offsets the tilt of the center of mass.
// @Units: deg
// @Range: -2 2
// @Increment: 0.1
// @User: Standard
AP_GROUPINFO ( " BAL_PITCH_TRIM " , 40 , ParametersG2 , bal_pitch_trim , 0 ) ,
2024-01-29 23:53:43 -04:00
// 41 was Scripting
2019-03-01 02:40:40 -04:00
2019-04-20 20:10:51 -03:00
// @Param: STICK_MIXING
// @DisplayName: Stick Mixing
// @Description: When enabled, this adds steering user stick input in auto modes, allowing the user to have some degree of control without changing modes.
// @Values: 0:Disabled,1:Enabled
// @User: Advanced
AP_GROUPINFO ( " STICK_MIXING " , 42 , ParametersG2 , stick_mixing , 0 ) ,
2019-04-29 03:31:45 -03:00
// @Group: WP_
// @Path: ../libraries/AR_WPNav/AR_WPNav.cpp
2021-11-22 00:38:20 -04:00
AP_SUBGROUPINFO ( wp_nav , " WP_ " , 43 , ParametersG2 , AR_WPNav_OA ) ,
2019-04-29 03:31:45 -03:00
2019-05-07 15:20:43 -03:00
// @Group: SAIL_
// @Path: sailboat.cpp
AP_SUBGROUPINFO ( sailboat , " SAIL_ " , 44 , ParametersG2 , Sailboat ) ,
2024-03-08 22:35:26 -04:00
# if AP_OAPATHPLANNER_ENABLED
2019-05-10 02:59:52 -03:00
// @Group: OA_
// @Path: ../libraries/AC_Avoidance/AP_OAPathPlanner.cpp
AP_SUBGROUPINFO ( oa , " OA_ " , 45 , ParametersG2 , AP_OAPathPlanner ) ,
2024-03-08 22:35:26 -04:00
# endif
2019-05-10 02:59:52 -03:00
2019-09-18 16:23:28 -03:00
// @Param: SPEED_MAX
// @DisplayName: Speed maximum
// @Description: Maximum speed vehicle can obtain at full throttle. If 0, it will be estimated based on CRUISE_SPEED and CRUISE_THROTTLE.
// @Units: m/s
// @Range: 0 30
// @Increment: 0.1
// @User: Advanced
AP_GROUPINFO ( " SPEED_MAX " , 46 , ParametersG2 , speed_max , 0.0f ) ,
// @Param: LOIT_SPEED_GAIN
// @DisplayName: Loiter speed gain
// @Description: Determines how agressively LOITER tries to correct for drift from loiter point. Higher is faster but default should be acceptable.
// @Range: 0 5
// @Increment: 0.01
// @User: Advanced
AP_GROUPINFO ( " LOIT_SPEED_GAIN " , 47 , ParametersG2 , loiter_speed_gain , 0.5f ) ,
2019-09-29 23:32:07 -03:00
// @Param: FS_OPTIONS
2021-11-19 23:05:23 -04:00
// @DisplayName: Failsafe Options
// @Description: Bitmask to enable failsafe options
2019-09-29 23:32:07 -03:00
// @Bitmask: 0:Failsafe enabled in Hold mode
// @User: Advanced
AP_GROUPINFO ( " FS_OPTIONS " , 48 , ParametersG2 , fs_options , 0 ) ,
2021-07-01 03:15:10 -03:00
# if HAL_TORQEEDO_ENABLED
2024-03-12 00:57:01 -03:00
// @Group: TRQ
2021-07-01 03:15:10 -03:00
// @Path: ../libraries/AP_Torqeedo/AP_Torqeedo.cpp
2024-03-12 00:57:01 -03:00
AP_SUBGROUPINFO ( torqeedo , " TRQ " , 49 , ParametersG2 , AP_Torqeedo ) ,
2021-07-01 03:15:10 -03:00
# endif
2021-11-18 23:38:12 -04:00
// @Group: PSC
// @Path: ../libraries/APM_Control/AR_PosControl.cpp
AP_SUBGROUPINFO ( pos_control , " PSC " , 51 , ParametersG2 , AR_PosControl ) ,
2021-11-19 23:05:23 -04:00
// @Param: GUID_OPTIONS
// @DisplayName: Guided mode options
// @Description: Options that can be applied to change guided mode behaviour
// @Bitmask: 6:SCurves used for navigation
// @User: Advanced
AP_GROUPINFO ( " GUID_OPTIONS " , 52 , ParametersG2 , guided_options , 0 ) ,
2022-07-05 15:21:10 -03:00
// @Param: MANUAL_OPTIONS
// @DisplayName: Manual mode options
// @Description: Manual mode specific options
// @Bitmask: 0:Enable steering speed scaling
// @User: Advanced
AP_GROUPINFO ( " MANUAL_OPTIONS " , 53 , ParametersG2 , manual_options , 0 ) ,
2024-08-04 21:54:28 -03:00
# if MODE_DOCK_ENABLED
2022-07-10 01:02:55 -03:00
// @Group: DOCK
// @Path: mode_dock.cpp
AP_SUBGROUPPTR ( mode_dock_ptr , " DOCK " , 54 , ParametersG2 , ModeDock ) ,
# endif
2022-11-09 22:08:18 -04:00
// @Param: MANUAL_STR_EXPO
// @DisplayName: Manual Steering Expo
// @Description: Manual steering expo to allow faster steering when stick at edges
// @Values: 0:Disabled,0.1:Very Low,0.2:Low,0.3:Medium,0.4:High,0.5:Very High
// @Range: -0.5 0.95
// @User: Advanced
AP_GROUPINFO ( " MANUAL_STR_EXPO " , 55 , ParametersG2 , manual_steering_expo , 0 ) ,
2023-01-29 18:49:35 -04:00
// @Param: FS_GCS_TIMEOUT
// @DisplayName: GCS failsafe timeout
// @Description: Timeout before triggering the GCS failsafe
// @Units: s
// @Range: 2 120
// @Increment: 1
// @User: Standard
AP_GROUPINFO ( " FS_GCS_TIMEOUT " , 56 , ParametersG2 , fs_gcs_timeout , 5 ) ,
2023-04-20 08:53:05 -03:00
// @Group: CIRC
// @Path: mode_circle.cpp
AP_SUBGROUPINFO ( mode_circle , " CIRC " , 57 , ParametersG2 , ModeCircle ) ,
2016-10-25 22:37:08 -03:00
AP_GROUPEND
} ;
2018-08-12 02:00:48 -03:00
// These auxiliary channel param descriptions are here so that users of beta Mission Planner (which uses the master branch as its source of descriptions)
// can get them. These lines can be removed once Rover-3.6-beta testing begins or we improve the source of descriptions for GCSs.
//
// @Param: CH7_OPTION
// @DisplayName: Channel 7 option
// @Description: What to do use channel 7 for
// @Values: 0:Nothing,1:SaveWaypoint,2:LearnCruiseSpeed,3:ArmDisarm,4:Manual,5:Acro,6:Steering,7:Hold,8:Auto,9:RTL,10:SmartRTL,11:Guided,12:Loiter
// @User: Standard
// @Param: AUX_CH
// @DisplayName: Auxiliary switch channel
// @Description: RC Channel to use for auxiliary functions including saving waypoints
// @User: Advanced
2016-10-25 22:37:08 -03:00
2019-04-29 03:31:45 -03:00
// @Param: PIVOT_TURN_ANGLE
// @DisplayName: Pivot turn angle
2020-04-09 11:10:41 -03:00
// @Description: Navigation angle threshold in degrees to switch to pivot steering. This allows you to setup a skid steering rover to turn on the spot in auto mode when the angle it needs to turn it greater than this angle. An angle of zero means to disable pivot turning. Note that you will probably also want to set a low value for WP_RADIUS to get neat turns.
2019-04-29 03:31:45 -03:00
// @Units: deg
// @Range: 0 360
// @Increment: 1
// @User: Standard
// @Param: PIVOT_TURN_RATE
// @DisplayName: Pivot turn rate
// @Description: Desired pivot turn rate in deg/s.
// @Units: deg/s
// @Range: 0 360
// @Increment: 1
// @User: Standard
2017-01-06 06:31:10 -04:00
ParametersG2 : : ParametersG2 ( void )
2017-07-19 01:33:11 -03:00
:
2024-08-04 21:54:28 -03:00
# if AP_ROVER_ADVANCED_FAILSAFE_ENABLED
2021-07-30 09:25:41 -03:00
afs ( ) ,
2017-01-30 10:21:55 -04:00
# endif
2023-04-09 05:54:09 -03:00
# if AP_BEACON_ENABLED
2022-05-31 23:12:32 -03:00
beacon ( ) ,
2023-04-09 05:54:09 -03:00
# endif
2018-08-08 00:48:30 -03:00
wheel_rate_control ( wheel_encoder ) ,
2024-09-21 21:37:45 -03:00
motors ( wheel_rate_control ) ,
2021-07-20 08:15:07 -03:00
attitude_control ( ) ,
2018-04-02 08:17:47 -03:00
smart_rtl ( ) ,
2021-03-25 05:47:29 -03:00
# if HAL_PROXIMITY_ENABLED
2019-09-27 05:23:48 -03:00
proximity ( ) ,
2021-03-25 05:47:29 -03:00
# endif
2024-09-21 21:37:45 -03:00
# if MODE_DOCK_ENABLED
mode_dock_ptr ( & rover . mode_dock ) ,
# endif
2024-03-09 03:49:48 -04:00
# if AP_AVOIDANCE_ENABLED
2019-05-22 03:04:12 -03:00
avoid ( ) ,
2024-03-09 03:49:48 -04:00
# endif
2023-08-11 09:28:32 -03:00
# if AP_FOLLOW_ENABLED
2018-08-29 21:54:12 -03:00
follow ( ) ,
2023-08-11 09:28:32 -03:00
# endif
2018-09-14 04:09:07 -03:00
windvane ( ) ,
2021-11-18 23:38:12 -04:00
wp_nav ( attitude_control , pos_control ) ,
2024-09-21 21:37:45 -03:00
sailboat ( ) ,
pos_control ( attitude_control )
2017-01-06 06:31:10 -04:00
{
AP_Param : : setup_object_defaults ( this , var_info ) ;
}
2016-10-25 22:37:08 -03:00
2013-10-02 03:07:28 -03:00
/*
This is a conversion table from old parameter values to new
parameter names . The startup code looks for saved values of the old
parameters and will copy them across to the new parameters if the
new parameter does not yet have a saved value . It then saves the new
value .
Note that this works even if the old parameter has been removed . It
relies on the old k_param index not being removed
The second column below is the index in the var_info [ ] table for the
old object . This should be zero for top level parameters .
*/
2015-10-25 14:03:46 -03:00
const AP_Param : : ConversionInfo conversion_table [ ] = {
2013-10-02 03:07:28 -03:00
{ Parameters : : k_param_battery_monitoring , 0 , AP_PARAM_INT8 , " BATT_MONITOR " } ,
{ Parameters : : k_param_battery_volt_pin , 0 , AP_PARAM_INT8 , " BATT_VOLT_PIN " } ,
{ Parameters : : k_param_battery_curr_pin , 0 , AP_PARAM_INT8 , " BATT_CURR_PIN " } ,
{ Parameters : : k_param_volt_div_ratio , 0 , AP_PARAM_FLOAT , " BATT_VOLT_MULT " } ,
{ Parameters : : k_param_curr_amp_per_volt , 0 , AP_PARAM_FLOAT , " BATT_AMP_PERVOLT " } ,
{ Parameters : : k_param_pack_capacity , 0 , AP_PARAM_INT32 , " BATT_CAPACITY " } ,
2015-01-28 00:56:36 -04:00
{ Parameters : : k_param_serial0_baud , 0 , AP_PARAM_INT16 , " SERIAL0_BAUD " } ,
{ Parameters : : k_param_serial1_baud , 0 , AP_PARAM_INT16 , " SERIAL1_BAUD " } ,
{ Parameters : : k_param_serial2_baud , 0 , AP_PARAM_INT16 , " SERIAL2_BAUD " } ,
2017-08-15 22:32:56 -03:00
{ Parameters : : k_param_throttle_min_old , 0 , AP_PARAM_INT8 , " MOT_THR_MIN " } ,
{ Parameters : : k_param_throttle_max_old , 0 , AP_PARAM_INT8 , " MOT_THR_MAX " } ,
2019-03-25 05:34:26 -03:00
{ Parameters : : k_param_compass_enabled_deprecated , 0 , AP_PARAM_INT8 , " COMPASS_ENABLE " } ,
2019-05-09 08:22:51 -03:00
{ Parameters : : k_param_waypoint_radius_old , 0 , AP_PARAM_FLOAT , " WP_RADIUS " } ,
2021-12-13 23:44:21 -04:00
{ Parameters : : k_param_g2 , 299 , AP_PARAM_INT16 , " WP_PIVOT_ANGLE " } ,
{ Parameters : : k_param_g2 , 363 , AP_PARAM_INT16 , " WP_PIVOT_RATE " } ,
{ Parameters : : k_param_g2 , 491 , AP_PARAM_FLOAT , " WP_PIVOT_DELAY " } ,
2019-05-08 09:56:14 -03:00
{ Parameters : : k_param_g2 , 32 , AP_PARAM_FLOAT , " SAIL_ANGLE_MIN " } ,
{ Parameters : : k_param_g2 , 33 , AP_PARAM_FLOAT , " SAIL_ANGLE_MAX " } ,
{ Parameters : : k_param_g2 , 34 , AP_PARAM_FLOAT , " SAIL_ANGLE_IDEAL " } ,
{ Parameters : : k_param_g2 , 35 , AP_PARAM_FLOAT , " SAIL_HEEL_MAX " } ,
{ Parameters : : k_param_g2 , 36 , AP_PARAM_FLOAT , " SAIL_NO_GO_ANGLE " } ,
2019-04-10 22:57:56 -03:00
{ Parameters : : k_param_arming , 2 , AP_PARAM_INT16 , " ARMING_CHECK " } ,
2021-05-02 13:37:13 -03:00
{ Parameters : : k_param_turn_max_g_old , 0 , AP_PARAM_FLOAT , " ATC_TURN_MAX_G " } ,
2022-08-22 14:22:54 -03:00
{ Parameters : : k_param_g2 , 82 , AP_PARAM_INT8 , " PRX1_TYPE " } ,
{ Parameters : : k_param_g2 , 146 , AP_PARAM_INT8 , " PRX1_ORIENT " } ,
{ Parameters : : k_param_g2 , 210 , AP_PARAM_INT16 , " PRX1_YAW_CORR " } ,
{ Parameters : : k_param_g2 , 274 , AP_PARAM_INT16 , " PRX1_IGN_ANG1 " } ,
{ Parameters : : k_param_g2 , 338 , AP_PARAM_INT8 , " PRX1_IGN_WID1 " } ,
{ Parameters : : k_param_g2 , 402 , AP_PARAM_INT16 , " PRX1_IGN_ANG2 " } ,
{ Parameters : : k_param_g2 , 466 , AP_PARAM_INT8 , " PRX1_IGN_WID2 " } ,
{ Parameters : : k_param_g2 , 530 , AP_PARAM_INT16 , " PRX1_IGN_ANG3 " } ,
{ Parameters : : k_param_g2 , 594 , AP_PARAM_INT8 , " PRX1_IGN_WID3 " } ,
{ Parameters : : k_param_g2 , 658 , AP_PARAM_INT16 , " PRX1_IGN_ANG4 " } ,
{ Parameters : : k_param_g2 , 722 , AP_PARAM_INT8 , " PRX1_IGN_WID4 " } ,
{ Parameters : : k_param_g2 , 1234 , AP_PARAM_FLOAT , " PRX1_MIN " } ,
{ Parameters : : k_param_g2 , 1298 , AP_PARAM_FLOAT , " PRX1_MAX " } ,
2024-03-12 00:57:01 -03:00
{ Parameters : : k_param_g2 , 113 , AP_PARAM_INT8 , " TRQ1_TYPE " } ,
{ Parameters : : k_param_g2 , 177 , AP_PARAM_INT8 , " TRQ1_ONOFF_PIN " } ,
{ Parameters : : k_param_g2 , 241 , AP_PARAM_INT8 , " TRQ1_DE_PIN " } ,
{ Parameters : : k_param_g2 , 305 , AP_PARAM_INT16 , " TRQ1_OPTIONS " } ,
{ Parameters : : k_param_g2 , 369 , AP_PARAM_INT8 , " TRQ1_POWER " } ,
{ Parameters : : k_param_g2 , 433 , AP_PARAM_FLOAT , " TRQ1_SLEW_TIME " } ,
{ Parameters : : k_param_g2 , 497 , AP_PARAM_FLOAT , " TRQ1_DIR_DELAY " } ,
2013-10-02 03:07:28 -03:00
} ;
2012-04-30 04:17:14 -03:00
2022-08-22 14:22:54 -03:00
2015-05-12 02:03:23 -03:00
void Rover : : load_parameters ( void )
2012-04-30 04:17:14 -03:00
{
2024-02-10 00:38:51 -04:00
AP_Vehicle : : load_parameters ( g . format_version , Parameters : : k_format_version ) ;
2012-04-30 04:17:14 -03:00
2017-08-16 00:04:10 -03:00
AP_Param : : convert_old_parameters ( & conversion_table [ 0 ] , ARRAY_SIZE ( conversion_table ) ) ;
2016-12-20 09:30:04 -04:00
2017-02-07 19:47:46 -04:00
AP_Param : : set_frame_type_flags ( AP_PARAM_FRAME_ROVER ) ;
2017-01-31 05:46:32 -04:00
2017-01-08 21:43:57 -04:00
SRV_Channels : : set_default_function ( CH_1 , SRV_Channel : : k_steering ) ;
SRV_Channels : : set_default_function ( CH_3 , SRV_Channel : : k_throttle ) ;
2017-01-31 05:46:32 -04:00
2018-06-27 10:53:30 -03:00
if ( is_balancebot ( ) ) {
g2 . crash_angle . set_default ( 30 ) ;
}
2020-01-13 00:46:05 -04:00
SRV_Channels : : upgrade_parameters ( ) ;
2018-05-08 09:19:03 -03:00
2019-01-23 00:48:35 -04:00
// convert CH7_OPTION to RC7_OPTION for Rover-3.4 to 3.5 upgrade
const AP_Param : : ConversionInfo ch7_option_info = { Parameters : : k_param_ch7_option , 0 , AP_PARAM_INT8 , " RC7_OPTION " } ;
AP_Int8 ch7_opt_old ;
if ( AP_Param : : find_old_parameter ( & ch7_option_info , & ch7_opt_old ) ) {
const uint8_t ch7_opt_map [ ] = { 0 , 7 , 50 , 41 , 51 , 52 , 53 , 54 , 16 , 4 , 42 , 55 , 56 } ;
const uint8_t ch7_opt_old_val = ( uint8_t ) ch7_opt_old . get ( ) ;
if ( ch7_opt_old_val < ARRAY_SIZE ( ch7_opt_map ) ) {
AP_Param : : set_default_by_name ( ch7_option_info . new_name , ch7_opt_map [ ch7_opt_old_val ] ) ;
}
}
2019-04-29 03:31:45 -03:00
// set AR_WPNav's WP_SPEED to be old WP_SPEED (if set) or CRUISE_SPEED (if set)
const AP_Param : : ConversionInfo wp_speed_old_info = { Parameters : : k_param_g2 , 14 , AP_PARAM_FLOAT , " WP_SPEED " } ;
const AP_Param : : ConversionInfo cruise_speed_info = { Parameters : : k_param_speed_cruise , 0 , AP_PARAM_FLOAT , " WP_SPEED " } ;
AP_Float wp_speed_old ;
if ( AP_Param : : find_old_parameter ( & wp_speed_old_info , & wp_speed_old ) ) {
// old WP_SPEED parameter value was set so copy to new WP_SPEED
AP_Param : : convert_old_parameter ( & wp_speed_old_info , 1.0f ) ;
} else {
// copy CRUISE_SPEED to new WP_SPEED
AP_Param : : convert_old_parameter ( & cruise_speed_info , 1.0f ) ;
}
2019-07-15 08:54:44 -03:00
// attitude control FF and FILT parameter changes for Rover-3.6
const AP_Param : : ConversionInfo ff_and_filt_conversion_info [ ] = {
{ Parameters : : k_param_g2 , 24650 , AP_PARAM_FLOAT , " ATC_STR_RAT_FLTE " } ,
{ Parameters : : k_param_g2 , 28746 , AP_PARAM_FLOAT , " ATC_STR_RAT_FF " } ,
{ Parameters : : k_param_g2 , 24714 , AP_PARAM_FLOAT , " ATC_SPEED_FLTE " } ,
{ Parameters : : k_param_g2 , 28810 , AP_PARAM_FLOAT , " ATC_SPEED_FF " } ,
{ Parameters : : k_param_g2 , 25226 , AP_PARAM_FLOAT , " ATC_BAL_FLTE " } ,
{ Parameters : : k_param_g2 , 29322 , AP_PARAM_FLOAT , " ATC_BAL_FF " } ,
{ Parameters : : k_param_g2 , 25354 , AP_PARAM_FLOAT , " ATC_SAIL_FLTE " } ,
{ Parameters : : k_param_g2 , 29450 , AP_PARAM_FLOAT , " ATC_SAIL_FF " } ,
} ;
2022-11-20 10:03:23 -04:00
AP_Param : : convert_old_parameters ( & ff_and_filt_conversion_info [ 0 ] , ARRAY_SIZE ( ff_and_filt_conversion_info ) ) ;
2019-07-15 08:54:44 -03:00
2018-05-08 09:19:03 -03:00
// configure safety switch to allow stopping the motors while armed
2018-08-01 20:46:59 -03:00
# if HAL_HAVE_SAFETY_SWITCH
2018-05-08 09:19:03 -03:00
AP_Param : : set_default_by_name ( " BRD_SAFETYOPTION " , AP_BoardConfig : : BOARD_SAFETY_OPTION_BUTTON_ACTIVE_SAFETY_OFF |
AP_BoardConfig : : BOARD_SAFETY_OPTION_BUTTON_ACTIVE_SAFETY_ON |
AP_BoardConfig : : BOARD_SAFETY_OPTION_BUTTON_ACTIVE_ARMED ) ;
# endif
2022-01-09 21:37:11 -04:00
2022-07-19 08:33:13 -03:00
# if AP_AIRSPEED_ENABLED | AP_AIS_ENABLED | AP_FENCE_ENABLED
2022-01-09 21:37:11 -04:00
// Find G2's Top Level Key
AP_Param : : ConversionInfo info ;
if ( ! AP_Param : : find_top_level_key_by_pointer ( & g2 , info . old_key ) ) {
return ;
}
2021-08-14 17:41:33 -03:00
# endif
2022-01-09 21:37:11 -04:00
2024-02-21 08:02:36 -04:00
static const AP_Param : : G2ObjectConversion g2_conversions [ ] {
2021-08-14 17:41:33 -03:00
# if AP_AIRSPEED_ENABLED
2024-02-21 08:02:36 -04:00
// PARAMETER_CONVERSION - Added: JAN-2022
2024-02-21 17:32:00 -04:00
{ & airspeed , airspeed . var_info , 37 } ,
2022-01-09 21:37:11 -04:00
# endif
2021-08-14 17:41:33 -03:00
# if AP_AIS_ENABLED
2024-02-21 08:02:36 -04:00
// PARAMETER_CONVERSION - Added: MAR-2022
2024-02-21 17:32:00 -04:00
{ & ais , ais . var_info , 50 } ,
2021-08-14 17:41:33 -03:00
# endif
2022-07-19 08:33:13 -03:00
# if AP_FENCE_ENABLED
2024-02-21 08:02:36 -04:00
// PARAMETER_CONVERSION - Added: Mar-2022
2024-02-21 17:32:00 -04:00
{ & fence , fence . var_info , 17 } ,
2022-03-04 12:41:00 -04:00
# endif
2024-01-25 23:24:25 -04:00
# if AP_STATS_ENABLED
2024-01-29 23:53:43 -04:00
// PARAMETER_CONVERSION - Added: Jan-2024 for Rover-4.6
2024-02-21 17:32:00 -04:00
{ & stats , stats . var_info , 1 } ,
2024-02-21 08:02:36 -04:00
# endif
2024-01-29 23:53:43 -04:00
# if AP_SCRIPTING_ENABLED
2024-02-21 08:02:36 -04:00
// PARAMETER_CONVERSION - Added: Jan-2024 for Rover-4.6
2024-02-21 17:32:00 -04:00
{ & scripting , scripting . var_info , 41 } ,
2024-01-29 23:53:43 -04:00
# endif
2024-02-21 02:40:36 -04:00
# if AP_GRIPPER_ENABLED
2024-02-21 08:02:36 -04:00
// PARAMETER_CONVERSION - Added: Feb-2024 for Copter-4.6
2024-02-21 17:32:00 -04:00
{ & gripper , gripper . var_info , 39 } ,
2024-02-21 02:40:36 -04:00
# endif
2024-02-21 08:02:36 -04:00
} ;
AP_Param : : convert_g2_objects ( & g2 , g2_conversions , ARRAY_SIZE ( g2_conversions ) ) ;
2024-02-21 02:40:36 -04:00
2024-02-07 16:42:28 -04:00
// PARAMETER_CONVERSION - Added: Feb-2024 for Rover-4.6
# if HAL_LOGGING_ENABLED
2024-02-21 17:32:00 -04:00
AP_Param : : convert_class ( g . k_param_logger , & logger , logger . var_info , 0 , true ) ;
2024-02-07 16:42:28 -04:00
# endif
2024-02-28 00:57:47 -04:00
static const AP_Param : : TopLevelObjectConversion toplevel_conversions [ ] {
# if AP_SERIALMANAGER_ENABLED
// PARAMETER_CONVERSION - Added: Feb-2024 for Rover-4.6
{ & serial_manager , serial_manager . var_info , Parameters : : k_param_serial_manager_old } ,
# endif
} ;
AP_Param : : convert_toplevel_objects ( toplevel_conversions , ARRAY_SIZE ( toplevel_conversions ) ) ;
2012-04-30 04:17:14 -03:00
}