mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-17 05:15:25 +03:00
More Filter Config Options
refactor Bump EEPROM Version
This commit is contained in:
parent
6d51ab6e53
commit
e490564815
4 changed files with 46 additions and 22 deletions
|
@ -348,12 +348,14 @@ static const char * const lookupTableSerialRX[] = {
|
|||
};
|
||||
|
||||
static const char * const lookupTableGyroFilter[] = {
|
||||
"LOW", "MEDIUM", "HIGH"
|
||||
"OFF", "LOW", "MEDIUM", "HIGH"
|
||||
};
|
||||
|
||||
static const char * const lookupTableGyroSampling[] = {
|
||||
"8KHZ",
|
||||
"1KHZ"
|
||||
static const char * const lookupTableGyroLpf[] = {
|
||||
"OFF",
|
||||
"188HZ",
|
||||
"98HZ",
|
||||
"42HZ"
|
||||
};
|
||||
|
||||
typedef struct lookupTableEntry_s {
|
||||
|
@ -377,7 +379,7 @@ typedef enum {
|
|||
TABLE_PID_CONTROLLER,
|
||||
TABLE_SERIAL_RX,
|
||||
TABLE_GYRO_FILTER,
|
||||
TABLE_GYRO_SAMPLING,
|
||||
TABLE_GYRO_LPF,
|
||||
} lookupTableIndex_e;
|
||||
|
||||
static const lookupTableEntry_t lookupTables[] = {
|
||||
|
@ -394,7 +396,7 @@ static const lookupTableEntry_t lookupTables[] = {
|
|||
{ lookupTablePidController, sizeof(lookupTablePidController) / sizeof(char *) },
|
||||
{ lookupTableSerialRX, sizeof(lookupTableSerialRX) / sizeof(char *) },
|
||||
{ lookupTableGyroFilter, sizeof(lookupTableGyroFilter) / sizeof(char *) },
|
||||
{ lookupTableGyroSampling, sizeof(lookupTableGyroSampling) / sizeof(char *) }
|
||||
{ lookupTableGyroLpf, sizeof(lookupTableGyroLpf) / sizeof(char *) }
|
||||
};
|
||||
|
||||
#define VALUE_TYPE_OFFSET 0
|
||||
|
@ -545,7 +547,7 @@ const clivalue_t valueTable[] = {
|
|||
|
||||
{ "max_angle_inclination", VAR_UINT16 | MASTER_VALUE, &masterConfig.max_angle_inclination, .config.minmax = { 100, 900 } },
|
||||
|
||||
{ "gyro_sampling", VAR_UINT8 | MASTER_VALUE | MODE_LOOKUP, &masterConfig.gyro_lpf, .config.lookup = { TABLE_GYRO_SAMPLING } },
|
||||
{ "gyro_lpf", VAR_UINT8 | MASTER_VALUE | MODE_LOOKUP, &masterConfig.gyro_lpf, .config.lookup = { TABLE_GYRO_LPF } },
|
||||
{ "moron_threshold", VAR_UINT8 | MASTER_VALUE, &masterConfig.gyroConfig.gyroMovementCalibrationThreshold, .config.minmax = { 0, 128 } },
|
||||
{ "imu_dcm_kp", VAR_UINT16 | MASTER_VALUE, &masterConfig.dcm_kp, .config.minmax = { 0, 50000 } },
|
||||
{ "imu_dcm_ki", VAR_UINT16 | MASTER_VALUE, &masterConfig.dcm_ki, .config.minmax = { 0, 50000 } },
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue