mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-23 00:05:33 +03:00
Added dterm filter type to MSP_FILTER_CONFIG and MSP_SET_FILTER_CONFIG
This commit is contained in:
parent
0b9dd11cb5
commit
25b10f50f6
1 changed files with 4 additions and 0 deletions
|
@ -1345,6 +1345,7 @@ static bool mspFcProcessOutCommand(uint8_t cmdMSP, sbuf_t *dst, mspPostProcessFn
|
|||
sbufWriteU16(dst, currentPidProfile->dterm_notch_cutoff);
|
||||
sbufWriteU16(dst, gyroConfig()->gyro_soft_notch_hz_2);
|
||||
sbufWriteU16(dst, gyroConfig()->gyro_soft_notch_cutoff_2);
|
||||
sbufWriteU8(dst, currentPidProfile->dterm_filter_type);
|
||||
break;
|
||||
|
||||
case MSP_PID_ADVANCED:
|
||||
|
@ -1745,6 +1746,9 @@ static mspResult_e mspFcProcessInCommand(uint8_t cmdMSP, sbuf_t *src)
|
|||
gyroConfigMutable()->gyro_soft_notch_hz_2 = sbufReadU16(src);
|
||||
gyroConfigMutable()->gyro_soft_notch_cutoff_2 = sbufReadU16(src);
|
||||
}
|
||||
if (dataSize > 17) {
|
||||
currentPidProfile->dterm_filter_type = sbufReadU8(src);
|
||||
}
|
||||
// reinitialize the gyro filters with the new values
|
||||
validateAndFixGyroConfig();
|
||||
gyroInitFilters();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue