Altitude control only with baro in indoors

I cannot hold a specific altitude in altitude control.
if start to switch to altitude mode and throttle stick in conter,
the drone drifting away from specific altitude and wouldn’t back to the original altitude.
the result of the ekf2 is most stable between lpe,inav and ekf2 in my test.
but still cannot fly at a stable altitude.
I already see a product of the quadcopter can do it.
what are keypoints for altitude control only with baro in indoors?
need to have a accurate barometer? or need adjust position estimator and controller params?
attached one of my tests:

I’m not sure how well you are going to do without a dedicated range sensor, such as the ultrasound sensor used in the PX4FLOW board. My feeling is that the barometer will be insensitive to meaningful changes in altitude indoors (such as in the range of 0m-2m).

In terms of the controller, I would probably start debugging by tuning your altitude hover throttle in the position controller parameters (it is also accessible from the tuning menu in QGroundControl). That parameter determines the thrust applied when the throttle stick is in the center dead-band position.

Best of luck to you :slight_smile:

Do you have a video of the test? so i can see how drift it is…

Hello All,
I have the same problem about hovering only with baro. Some good results can be found at
F450 Naze32 Altitude hold (Baro mode)
Naze 32 Barometer Altitude hold demo flight
And I want to achieve similar performance.
I am using LPE estimator with ms5611 and IMU module on a 250 frame.
Based on the static test of ms5611, I set LPE_BAR_Z to 1.
The result is shown below.

So is this estimation good enough to do the hovering with barometer?