1
0
Fork 0
mirror of https://github.com/iNavFlight/inav.git synced 2025-07-26 09:45:33 +03:00

Add control_smoothness configuration variable

This commit is contained in:
Harry Kalogirou 2020-04-09 11:58:09 +03:00
parent 4b31b81a76
commit 1bc8938657
4 changed files with 7 additions and 0 deletions

View file

@ -108,6 +108,7 @@ static const OSD_Entry cmsx_menuFixedWingEntries[] =
OSD_SETTING_ENTRY("MAX DIVE ANGLE", SETTING_NAV_FW_DIVE_ANGLE),
OSD_SETTING_ENTRY("PITCH TO THR RATIO", SETTING_NAV_FW_PITCH2THR),
OSD_SETTING_ENTRY("LOITER RADIUS", SETTING_NAV_FW_LOITER_RADIUS),
OSD_SETTING_ENTRY("CONTROL SMOOTHNESS", SETTING_NAV_FW_CONTROL_SMOOTHNESS),
OSD_BACK_AND_END_ENTRY,
};

View file

@ -1596,6 +1596,10 @@ groups:
field: fw.cruise_speed
min: 0
max: 65535
- name: nav_fw_control_smoothness
field: fw.control_smoothness
min: 0
max: 9
- name: nav_fw_land_dive_angle
field: fw.land_dive_angle

View file

@ -143,6 +143,7 @@ PG_RESET_TEMPLATE(navConfig_t, navConfig,
.max_dive_angle = 15, // degrees
.cruise_throttle = 1400,
.cruise_speed = 0, // cm/s
.control_smoothness = 0,
.max_throttle = 1700,
.min_throttle = 1200,
.pitch_to_throttle = 10, // pwm units per degree of pitch (10pwm units ~ 1% throttle)

View file

@ -198,6 +198,7 @@ typedef struct navConfig_s {
uint8_t max_dive_angle; // Fixed wing max banking angle (deg)
uint16_t cruise_throttle; // Cruise throttle
uint16_t cruise_speed; // Speed at cruise throttle (cm/s), used for time/distance left before RTH
uint8_t control_smoothness; // The amount of smoothing to apply to controls for navigation
uint16_t min_throttle; // Minimum allowed throttle in auto mode
uint16_t max_throttle; // Maximum allowed throttle in auto mode
uint8_t pitch_to_throttle; // Pitch angle (in deg) to throttle gain (in 1/1000's of throttle) (*10)