EKF(Position vertical) BARO issue Only on Load condition

@xfacta
CUAV V5+ mounted on 40kg Agriculture Spraying Quad system.
as per the tuning instruction i have configured everything before flight and tested Hover flight .
on continuing this configured PRE and POST Filter testing .

POST Fliter:

when flying at NO load condition I am not facing any EKF issue related to BARO .

but when i fly with 10litre Sprayer continuously getting EKF variance Especially on BARO . during this EKF switch over drone altitude increase and decrease drastically.
then i decided to open up the spray(water).while keep weight decreasing by spray the water its worked normally. Out of 10litre 8 liter was remaining available in the tank then it started flying normally and there is no EKF issue after that .


here is the log https://drive.google.com/file/d/1Rth73Pw7_3N8u7Pvdi3m6nSJhXC1-7iG/view?usp=sharing

here is the FC mounting without tank.


this image is after Tank fixed

what will happen if I choose GPS as altitude source instead of BARO.

It looks like your barometer gets really noisy at that payload. The only thing I could come up with would be that when the motors work hard enough and pushes enough air, you get turbulence around the flight controller which causes the barometer to get inaccurate fluctuating readings.

Your GPS altitude looks fine though so you could try to change the primary alt source to GPS attitude and try again. Keep in mind that your altitude accuracy than would be dependent on your gps signal quality. So waiting for some extra satellites would be needed.

Your systems seems to only be using one GPS, it you go on and use GPS as the altitude source, you might want to look into using dual GPS modules.

I would start there, test with GPS altitude. If that solves your issue it’s only barometer related and probably aerodynamical. You could than try to shield the flight controller compartment from quick air pressure changes or stick with using GPS altitude.

I use it on one of my aircrafts, with a single here 2. On that craft, it’s due to aerodynamical effects occurring in windier conditions. It holds the altitude stably but can drift a bit over time up and down. Keep in mind, the here 2 is great but a bit old now, with dual here 3 or some other new gps unit you would get better results.

I appreciate your reply on this thank you so much @Axel1

But i don’t think because you can see the picture that cover entire autopilot cabin with water tank,even there is much clearance between propeller to autopilot so i don’t think its might the reason.

Any how i try to cover the autopilot cabin with carbon fibre plate.

Yes i wonder about this, atleast for checking EKF issue i must change alt source as GPS and check if still problem exist.
Yes i am using only one GPS CUAV Neo V2 pro and worrying about how it will work?

How much drift in vertical height did you got when using alt source as a GPS?

Aerodynamics can be tricky, especially pressure changes. You could try to put foam around the flight controler to see if it makes any difference, not as a final solution but for testing.

The CUAV Neo v2 pro should work for GPS altitude no problem. I got around 1 meter in either direction, up/down. Your GPS altitude in the log looked good so you don’t think you will experience much drift. If you get good results from the GPS altitude, maybe investing in a second gps and using GPS as primary for altitude could be an option. As this is a sprayer drone you will most likely fly over large open surfaces most of the time I would assume.

But some foam around the flight controller could improve the barometer fluctuations.

Ok let me check both the solution one by one and report you … thank you @Axel1

No problem! Do the test and than we can take a look at the results

Just going out on a limb…
The noisy baro could also be related to Vcc (5 volts DC to the Flight Controller).
I know correlation is not always causation…
But when the Vcc gets a bit lower and a bit noisier, the Baro also gets noisier.
Maybe try adding an electolytic cap to the 5 volts supply??

The foam around the FC is a good idea too, so it’s like an igloo and not touching the FC.

Thats an interesting observation, missed that one. As the voltage rises at the end. Also when the copter lands, and the current draw and motor out signal drops down, the vcc voltage goes up. It could very much be an issue regarding the power to the flight controler. What power supply is used to power the FC?

On other tuning matters…

ANG P’s are very low
RAT P and I are quite high
That’s all Ok if it works properly. Maybe reassess them after sorting out the Baro and testing these changes below.

I would change HNOTCH like this:
INS_HNTCH_REF,0.25
INS_HNTCH_FREQ,28
INS_HNTCH_BW,14

Also Loiter shows some unnecessary movements, soften it by halving these params to:
PSC_POSXY_P,0.5
PSC_VELXY_D,0.25
PSC_VELXY_I,0.5
PSC_VELXY_P,1.0

Is battery voltage augmented with a generator? You might still want to set the related battery params in case the generator stops or loses regulation.
BATT_ARM_VOLT,44.30
BATT_CRT_VOLT,42.00
BATT_LOW_VOLT,43.20
BATT_FS_CRT_ACT,1
BATT_FS_LOW_ACT,2
MOT_BAT_VOLT_MAX,51.0 ← increased a little over standard based on your log
MOT_BAT_VOLT_MIN,39.60
You might want to increase the BATT_ voltages slightly to trigger early warning and actions.

Thank you for your reply @xfacta

I had given power supply to Skydroid T12 receiver from flight controller telemetry port that might draw more power when on load ?
Can i add another back up Power to the Power port 2 of the CUAV v5+.

I used default CUAV power module which come along with CUAV V5+ package…
That specifications is 5.3V at 5A continuous current.

And i kept angle P low since its agri drone and while stopping its should not have more correction,if more correction even that causes more oscillation during stop.

This suggestion have you told after seeing the harmonic pre filter graph?

Yes it is.

The attitude control you have there is quite good.
If possible tune with the lightest take off weight, for best performance (high PIDs or whatever is suitable).
Then, reduce the ATC_ACCEL MAX params to suit your maximum take off weight as per:

new ATC_ACCEL_P_MAX = ATC_ACCEL_P_MAX x (min_TOW / max_TOW)
new ATC_ACCEL_R_MAX = ATC_ACCEL_R_MAX x (min_TOW / max_TOW)
new ATC_ACCEL_Y_MAX = ATC_ACCEL_Y_MAX x (min_TOW / max_TOW)

My current ATC_ACCEL_P_MAX = 30000
So i calculate new ATC _ACCEL_P_MAX from this or
from default 110000.

You would start with the ATC_ACCEL MAX based on your prop size, and complete all tuning for the “ideal” configuration of no payload. If you are able to run Autotune it might go even higher.
Then perform the calc based on mimimum and maximum takeoff weights.

You could try a mauch power module, although we haven’t confirmed thar it’s an actual problem with the power module, so it’s a long shot. Go ahead with some tuning, as @xfacta posted about. For the baro issue, try the gps altitude as alt source first

I have tried covered Fc controller with carbon fibre plate as like below


But this not at all worked and there is no way to get air into flight controller area but why baro keep affteted.

Then i changed EK3_SRC1_POSZ = 3 ( Gps )

There is no ekf error at all and using gps altitude it was flown nicely even there is no bumb ( height increase or decrease).
Had two flights and both of them worked well at full load condition ( 10L).

Than maybe GPS altitude it better for this setup. The aerodynamical effects can be rapid pressure changes outside of the main fuselage which in turn affects the pressure inside.

But if GPS height works fine, you could go on and use that, maybe you want to invest in a second gps, for better accuracy but also for redundancy

hi @xfacta
as per your suggestion i have halve the position controller parameter and harmonic filter setting.
as i said to @Axel1 baro still have problem after covered the flight controller with carbon fiber plate (reference photo attached above)
here is the log file for 3 flight Agri drone EKF (Baro) variance - Google Drive
each flight named respect test conditions. please check and provided if any improvement

Yes im going to use second gps also in future .if i add second gps except configure of gps paramter should i change any other parameter like which gps is mainly used for altitude estimation source?