I am looking for some assistance on barometer fluctuations I am experiencing.
Vehicle and parameter setup:
2.5" copter on a MicoAir H743V2 AIO. This board has the SPL06 barometer and I have covered it with open cell foam. MTF-01. No GPS onboard. I have EK3_SRC1_POSZ set to barometer and also have EK3_RNG_USE_HGT set to 95 and EK3_RNG_USE_SPD to 0.5. I have this set so that when the vehicle is generally still and close to the ground, it will use the rangefinder, otherwise it will use the barometer.
Test flight and observations:
Indoor flight. I took off in stabilize and switched to ALTH. I did some generally quick pitch and roll maneuvers in order to observe the result, which was quick altitude changes. This graph is messy for a reason, I wanted to show one of the two RC inputs I was giving it (pitch and roll). At about 50 seconds, the desired and Alt and DAlt shoot up, evidenced by the rangefinder’s increasing altitude reading. At about 58 seconds I reduce throttle to lower the vehicle and get a decent height while still in ALTH. Then with some more pitch and roll, the vehicle loses altitude.
I have also experienced altitude fluctuations during indoor flights in ALT_HOLD mode with no GPS, but I haven’t had the time to investigate the issue in detail.
All I can say is that in the past, we flew extensively with EK2 (ArduCopter 4.0.5), and it always worked fine. Since updating to newer versions using EK3, we’ve been seeing this behavior — even in a perfect hover, there are sometimes slow oscillations of about ±0.5 m. I agree that the problem lies in the estimation rather than on the control side.
I watched one of Andy Piper’s videos where he was adjusting params for a Pavo20 barometer. I incorporated some of those changes and I did two more test flights: one outdoors (pretty windy) and one indoors.
Before the changes, abrupt altitude fluctuations typically happened when I went full pitch and then changed direction hard.
After the changes, the altitude fluctuates were not as abrupt. Of course being outside, those fluctuations were less noticeable than when indoors. But, overall, I feel like it’s in a better spot.