EKF-primary 1,2 error in AUTO mode

Hi everyone,
I’m using cube orange, MN5008 340KV antigravity motors, 60A esc and 1806 propellers.
HEXA FRAME
even I did autotune according to ardupilot documentation, it’s flying properly in posh hold, loiter mode but when I sent for AUTO mode 500m it went correctly after that suddenly EKF primary 1,2 like that errors are started, drone started to spin continuously
Then I manage by stabilize RTL other modes and safely landed the drone
please someone help on this
Thank You

Remove the access requirement to the file.

Ohhh sorry @dkemxr

Now it’s done, please check

quickly I see two things:

The compass calibration is not good. You should do a Magfit calibration on the compass. It would be best if you had proper battery current values because I suspect there’s interference from that.

The RTL was because of a fence breach.

@Allister thank you sir,

That I’ll do,
Is there any problem in PID values or autotune things.

Yea, sure there is.
Long before you attempted Autotune you should have realized you have major output oscillation and an apparent Yaw bias. So, change these 1st and then do a simple hover for a minute or so and review the outputs as shown:
PSC_ACCZ_I,0.6
PSC_ACCZ_P,0.3

The notch filter will require review/revision also.

1 Like

@dkemxr sure sir
Thank you
I’ll try it and I’ll update

After this did I need to do tuning again before going to auto mode flying…?

You may have to fix a mechanical Yaw bias but let’s see what the Rcout’s look like after making the parameter change. Re-enable these to check the notch filter settings:
INS_LOG_BAT_MASK,1
INS_LOG_BAT_OPT,4
And set this:
INS_ACCEL_FILTER,10

@dkemxr sure sir,
I’ll come with a update tomorrow

@dkemxr Hi sir,
done with flying, with the changes you have told

As expected you have a mechanical Yaw bias. Note the difference in the CW and CCW motors (plot the RCout’s for yourself). The props are not level, it could be from motor mount or arm twist but it needs to be corrected.
The output oscillation is improved but still present. I don’t think you got a good Auto Tune so I would reset the Rate PID’s to default and start over.
Also the notch filter is not configured optimally. Make these changes:

Notch

@dkemxr thank you so much sir,

Tommorow I’ll completely once again check the mechanical issues
And I’ll move on to tuning process from starting again

@dkemxr
Hi sir,
from complete scratch I have done everything, up to this notch filters and also, I did a flight for checking extreme input checks, there was no errors occurred,
planning to push for AUTO TUNE tomorrow please review the log once sir.
1st LOG - Basic Alt hold Flying
2nd LOG - Extreme input check Flying

Thank you.