Matek h743 slim v4 dual IMU vibration investigations

TL;DR: On boards with two IMUs running at different sample rates, VIBE levels are not comparable between them. Setting both to 1kHz (INS_GYRO_RATE=0) equalises the readings and, on my setup, cut reported vibrations by more than half.

I’m still in the process of figuring out the vibrations issues on my 10inch quadcopter, in the meantime I found some potentially interesting results in regards to vibration levels on Matek H743 slim v4 IMUs.

I’ve noticed, like a few other people already (

) that vibration levels differ significantly between the two IMUs.

Here we can see for example. that vibration levels drop from 40-50 to 15-20 by looking at the second IMU instead of the first one.

On my board, both IMUs are ICM42688, so this was strange so I investigated further.

On the filter review tool we can see a similar effect on the gyro data.

We can also observe the second IMU sampling at 1kHz while the first IMU samples at 2kHz, which I assume causes a decline in gryo noise above 250Hz (though I’m somewhat confused by that given that I’d only expect frequencies above half the sampling frequency to be “modified” due to lower sampling rate.

It’s also interesting to observe the “stabilization” of the noise graph on the second IMU in the, for example, 150-275 Hz band, where orange curve is much smoother, I have no explanation for that.

I’ve also modified (not very trustworthy modification, mostly provided by LLM, so keep that in mind) filter review tool to provide frequency plots of acceleration data from ACC logs.

The peak noise frequencies appear to match between the accelerometer and gyro(ok, not that interesting, but might save work for others).

For the next test I then modified INS_GYRO_RATE and set it from 1 to 0 to force both IMUs to the same rate.

The VIBE graph now shows great overlap!

Gyro 1 noise data also looks smooth, but also not quite like the gyro 2 looked like in the earlier flight

I’m unable to plot gyro 2 with this modification for some reason.

So I guess there’s a bunch of data here, I still have some questions that I’d appreciate some input on:

  • It’s “common knowledge” that vibes above 30 are generally an issue, but it seems from these measurements that vibe levels are highly dependent on the sampling frequency. Should the threshold scale with the sampling frequency?
  • Should I lower sampling rate to 1kHz if I care much more about EKF quality/reliability than responsiveness and my vibration levels are borderline, given that this reduces vibe levels in logs?
  • Why does gyro noise get lower at lower sample rate even at low frequencies?
  • Why is gyro noise graph smoother at lower sampling rate?

Here’s the log with 2kHz/1kHz rate https://drive.google.com/file/d/13_zVxGtrVd5tWsdxOUNGjHTzwG06tJfC/view?usp=sharing

And the log with the 1kHz/1kHz rate

Try writing log without Fast IMU / Fast harmonic notch logging, eg LOG_BITMASK, 180221
Lowering sampling rate actually works like rude LPF

Reverted INS_GYRO_RATE to 1 and changed LOG_BITMASK to 180221.

1 Like

In this log you had EKF lane switch in flight, with that the gyro log is not very useful.
Also set INS_RAW_LOG_OPT,10 to log both gyros.
Why do you have your compass disabled? That might help EKF keeping the line.
Try recalibrating your compass with GPS and battery installed and do COMPASS_USE,1, looks like it have wrong orientation set now.

1 Like

I don’t have any good place to put a compass(where it wouldn’t get disturbed by the current), and it seems to work fine without it, so I just don’t bother enabling it. Will get logs with new logging parameters as soon as I can.

Updated loggin parameters. Seems like the primary’ gyro noise data has more frequency stability now.

EKF changes at/after landing, this hopefully isn’t an issue.

You see classical -3db (twice) noise reduction by halving the frequency band, that’s why EKF prefer line with less noise and switch to 2nd IMU. I don’t see any problem to use it - no strong signal is visible past 500hz, so it cannot alias down. I believe it also affect accelerometer reading that translates to less registered noise, but it’s preferable to eliminate source of vibrations by improving FC mount and making the frame more stiff.
You can see increased vibe levels on descent - it’s propwash partially because of low PIDs and higher filering amount. You can try to retune the PIDs and lower your filtering amount by increasing LPF (let’s say to 80hz) and adjusting RPM notch (15hz/15db looks adequate), “update at loop” rate also can give 1-2ms, this will lower the filtering delay and decrease propwash.

1 Like