mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-25 09:16:07 +03:00
Revise PID/Rate profile names to use get/set and eliminate extra PG's
Removes the custom CLI commands to update or display the PID and Rate profile names. Moves the storage into the pidProfile and controlRateProfile PG's. Names can now be set with: set profile_name = NAME set rate_profile_name = NAME Also added profile name display to the profile and rate CMS menus.
This commit is contained in:
parent
67d1f720ff
commit
f5bc673ada
11 changed files with 57 additions and 116 deletions
|
@ -36,12 +36,13 @@ typedef enum {
|
|||
THROTTLE_LIMIT_TYPE_COUNT // must be the last entry
|
||||
} throttleLimitType_e;
|
||||
|
||||
|
||||
typedef enum {
|
||||
TPA_MODE_PD,
|
||||
TPA_MODE_D
|
||||
} tpaMode_e;
|
||||
|
||||
#define MAX_RATE_PROFILE_NAME_LENGTH 8u
|
||||
|
||||
typedef struct controlRateConfig_s {
|
||||
uint8_t thrMid8;
|
||||
uint8_t thrExpo8;
|
||||
|
@ -55,6 +56,7 @@ typedef struct controlRateConfig_s {
|
|||
uint8_t throttle_limit_percent; // Sets the maximum pilot commanded throttle limit
|
||||
uint16_t rate_limit[3]; // Sets the maximum rate for the axes
|
||||
uint8_t tpaMode; // Controls which PID terms TPA effects
|
||||
char profileName[MAX_RATE_PROFILE_NAME_LENGTH + 1]; // Descriptive name for rate profile
|
||||
} controlRateConfig_t;
|
||||
|
||||
PG_DECLARE_ARRAY(controlRateConfig_t, CONTROL_RATE_PROFILE_COUNT, controlRateProfiles);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue