Altitude variation even when using rtk_fixed

Hi all,
I have a a quad that uses RTK from my own base station. In Mission Planner the quad GPS status shows RTK_Fixed but the drone drifts about 2 meters vertically when in position hold mode. In the Quick view screen in Mission Planner I have Altitude(m) and ahrs2_alt shown. With the quad sitting on the ground the ahrs2_alt value is rock solid (within 0.5m) but the Altitude(m) changes up and down by 1.5m within a minute. I have tried to disable the barometer etc but I still can not get the altitude to be as solid as ahrs2_alt. What do I need to do to force the ahrs2_alt value to be use as the main altitude feedback?

Hello, i assume that your autopilot is not covered, is this right?

Im not sure where you are going. It is not covered, but I have put some open cell foam over the barometer to reduce wind effects. Either way, I would like to give more weight to the GPS altitude over the barometer altitude because the GPS always gets the best estimate.

If you are facing a behaviour like this, then you might consider covering the FC or setting up the baro compensation. Fixing this baro estimation issue should be considered in my opinion.

I find it interesting that when the quad is sitting stationary on the ground, the Altitude(m) rises and falls by a 1 meter or so each minute, and the Vertical Speed(m/s) correlates exactly with the Alititude(m) value. ( ie velocity is positive while altitude goes up and velocity is negative while altitude goes down) I am not sure if the vertical velocity value is used to calculate Altitude or Altitude change is used to calculate vertical velocity but they are perfectly matched. While these values are changing up and down the GPS ahrs2_alt is steady within < 0.2m of a constant altitude. There is something very wrong if the EKF can not get it right when there is no wind and no acceleration. The barometric pressure is very steady at 950.8. I do not see what is causing the variation. If I lift the quad up by half a meter, the Altitude(m) value changes exactly the right amount. So the dynamic calculations are very good but the steady state offset has some problems. It looks like some altitude biasing integrator or logic is overshooting and oscillating about the correct altitude. It overshoots about 3m some times.

You need to configure the EKF to use GPS for altitude.

I understand your point. If this happens regardless of the vehicle’s velocity, then my point is not relevant. Could you please send a log containing this issue?

Hi randyV,
I am using a SpeedyBee mini F405 FC. It does not have a SD card for logging. Is there a way of logging via Mission Planner? Which variables would you like to have logged.
I can send my param file. How can I share it with you?
Thankyou for looking at this issue.

Actually, what you are seeing while testing is logged on your GCS computer via Mission Planner as a .tlog file. However, analyzing a .tlog is more limited compared to a normal .bin log file.

If you manage to find a valid .tlog, you can share it, and I or someone else might be able to help.

It should still block log to flash memory. Mission Planner shows no logs?
As per the Hwdef file:

Dataflash setup
SPIDEV dataflash SPI3 DEVID1 FLASH1_CS MODE3 104MHZ 104MHZ

define HAL_LOGGING_DATAFLASH_ENABLED 1

1 Like