ardupilot/libraries/AP_InertialSensor
Andrew Tridgell 6a5889726c AP_InertialSensor: fixed Q calculation for notch filters
when doing the init() we must use the reference frequency, not the
current frequency. Using the current frequency leaves us with an
incorrect value for Q. If the current frequency is below the reference
frequency (which shouldn't happen in 4.5, but has been seen in 4.3)
then the Q can be much too low and massive phase lag can happen.

The vulnerability in 4.5.x is that the current frequency could be well
above the reference frequency. For example, the user may be doing a
motor test at 30s after boot, which is when we stop the
sensors_converging() test, and thus is the last time we call
init(). In that case we can end up with a Q which is much larger than
the one that should come from INS_HNTCH_FREQ and INS_HNTCH_BW, and
thus end up with a filter that produces a lot less attenuation than is
desired, potentially leading to instability due to high noise.

There are other scenarios that can cause this - for example a motor
test of a fwd motor at 30s after boot, or a spurious FFT peak due to
someone knocking the aircraft, or the vibration of a IC engine.
2024-12-03 16:39:48 +09:00
..
examples AP_InertialSensor: correct INS_generic example 2022-08-13 20:53:29 +10:00
AP_InertialSensor_ADIS1647x.cpp AP_InertialSensor: added support for more ADIS IMUs 2021-12-29 18:25:18 +11:00
AP_InertialSensor_ADIS1647x.h AP_InertialSensor: added support for more ADIS IMUs 2021-12-29 18:25:18 +11:00
AP_InertialSensor_Backend.cpp AP_InertialSensor: allow compilation with HAL_LOGGING_ENABLED false 2024-01-17 18:25:55 +11:00
AP_InertialSensor_Backend.h AP_InertialSensor: allow compilation with HAL_LOGGING_ENABLED false 2024-01-17 18:25:55 +11:00
AP_InertialSensor_BMI055.cpp AP_InertialSensor: Console output can be disabled 2022-05-17 09:53:06 +10:00
AP_InertialSensor_BMI055.h
AP_InertialSensor_BMI088.cpp AP_InertialSensor: fixed the error value for BMI088 2023-10-08 10:52:27 +11:00
AP_InertialSensor_BMI088.h AP_InertialSensor: use 234Hz accel LPF and 532Hz gyro LPF on BMI088 to more closely match Invensense 2022-12-28 18:18:26 +11:00
AP_InertialSensor_BMI160.cpp AP_InertialSensor: Console output can be disabled 2022-05-17 09:53:06 +10:00
AP_InertialSensor_BMI160.h AP_InertialSensor: BMI160: Allow configuring the rotation 2021-08-13 12:32:28 +10:00
AP_InertialSensor_BMI270.cpp AP_InertialSensor: Remove line breaks from PANIC strings 2022-09-15 13:21:09 +10:00
AP_InertialSensor_BMI270.h AP_InertialSensor: synchronize BMI70 on fifo reads 2022-09-06 09:31:21 +10:00
AP_InertialSensor_config.h AP_InertialSensor: create define specifically for the developer feature for killing IMUs 2023-06-07 18:23:01 +10:00
AP_InertialSensor_ExternalAHRS.cpp AP_InertialSensor: External: report name in output banner 2023-01-03 10:32:20 +11:00
AP_InertialSensor_ExternalAHRS.h AP_InertialSensor: External: report name in output banner 2023-01-03 10:32:20 +11:00
AP_InertialSensor_Invensense_registers.h AP_InertialSensor: properly reset MPU6000 signal path at startup 2022-06-08 17:44:17 +10:00
AP_InertialSensor_Invensense.cpp AP_InertialSensor: pre-fetch instances for use in filter setup 2023-10-25 19:23:11 +11:00
AP_InertialSensor_Invensense.h AP_InertialSensor: add fast reset for ICM20602 instead of full reset on bad temp sample 2022-11-01 10:53:09 +11:00
AP_InertialSensor_Invensensev2_registers.h
AP_InertialSensor_Invensensev2.cpp AP_InertialSensor: pre-fetch instances for use in filter setup 2023-10-25 19:23:11 +11:00
AP_InertialSensor_Invensensev2.h
AP_InertialSensor_Invensensev3.cpp AP_InertialSensor: fixed ICM42670 2024-06-15 09:06:36 +09:00
AP_InertialSensor_Invensensev3.h AP_InertialSensor: add high-resolution reads for ICM45686 2023-10-25 19:23:11 +11:00
AP_InertialSensor_L3G4200D.cpp
AP_InertialSensor_L3G4200D.h
AP_InertialSensor_Logging.cpp AP_InertialSensor: allow compilation with HAL_LOGGING_ENABLED false 2024-01-17 18:25:55 +11:00
AP_InertialSensor_LSM9DS0.cpp AP_InertialSensor: Console output can be disabled 2022-05-17 09:53:06 +10:00
AP_InertialSensor_LSM9DS0.h
AP_InertialSensor_LSM9DS1.cpp AP_InertialSensor: Console output can be disabled 2022-05-17 09:53:06 +10:00
AP_InertialSensor_LSM9DS1.h
AP_InertialSensor_NONE.cpp AP_InertialSensor: fixed build of NONE backend 2024-01-07 20:51:55 +11:00
AP_InertialSensor_NONE.h AP_InertialSensor: use motor_mask from SITL for which outputs are motors 2022-10-16 20:38:19 +11:00
AP_InertialSensor_Params.cpp AP_InertialSensor: add support for extra Aux IMUs 2023-03-21 10:04:16 +11:00
AP_InertialSensor_Params.h AP_InertialSensor: add support for extra Aux IMUs 2023-03-21 10:04:16 +11:00
AP_InertialSensor_RST.cpp AP_InertialSensor: Console output can be disabled 2022-05-17 09:53:06 +10:00
AP_InertialSensor_RST.h
AP_InertialSensor_SCHA63T.cpp AP_InertialSensor: SCHA63T comment fix 2023-05-10 17:24:02 +10:00
AP_InertialSensor_SCHA63T.h AP_InertialSensor: SCHA63T loses unused ret bool 2023-05-10 17:24:02 +10:00
AP_InertialSensor_SITL.cpp AP_InertialSensor: Specify the number of arrays by sizeof 2024-01-04 10:24:44 +11:00
AP_InertialSensor_SITL.h AP_InertialSensor: add support for reading and writing INS data from a file in SITL 2022-12-28 18:14:56 +11:00
AP_InertialSensor_tempcal.cpp AP_InertialSensor: Fix persistent storing of IMU Z Scale 2024-08-21 20:39:44 +09:00
AP_InertialSensor_tempcal.h AP_InertialSensor: add support for extra Aux IMUs 2023-03-21 10:04:16 +11:00
AP_InertialSensor.cpp AP_InertialSensor: fixed Q calculation for notch filters 2024-12-03 16:39:48 +09:00
AP_InertialSensor.h AP_InertialSensor: added support for writing raw IMU data to a UART 2023-11-30 07:05:02 +11:00
AuxiliaryBus.cpp
AuxiliaryBus.h
BatchSampler.cpp AP_InertialSensor: fix hardfault in BatchSampler 2023-04-05 18:22:03 +10:00
LogStructure.h AP_InertialSensor: vibe units m/s/s 2021-11-18 13:23:06 +09:00