Yaw inconsistent error on GPSless plane with compass

Hello,

I have a small plane that does run matek h743 with 2 IMU and just compass, have no GNSS receiver installed.
I’m getting the “PreArm: AHRS: EKF3 Yaw inconsistent XX deg. Wait or reboot” error if on startup the nose does not points strictly north.
This error does not appear on copter because it have DCM disabled but on plane DCM still works as fallback and looks like it do not account compass data on startup. I found some explanations from @rmackay9 and understood that 2 EKF lines should be compared if possible, but here it want to compare with DCM.
Is that a bug? What is workaround except disabling this prearm check?

Thanks.

Hi @mike_tk,

Txs for the report. Could you provide an onboard log?

I’m not the plane expert but I guess it’s clear that either two EKF cores disagree on yaw or that EKF disagrees with DCM. I’m pretty in normal cases DCM initialises its yaw using the compass so I don’t think that should be the issue.

Yes, sure.
no_gps_yaw_inconsistent.bin (864 KB)
I was not able to reproduce it in SITL with SIM_OPOS_HDG parameter, but in hardware I had only CAN compass connected and

ARSPD_TYPE,0
CAN_P1_DRIVER,1
COMPASS_AUTODEC,0
EK3_SRC1_POSXY,0
EK3_SRC1_VELXY,0
EK3_SRC1_VELZ,0
EK3_SRC2_YAW,1
GPS1_TYPE,0

Plane requires a position source of some kind to operate correctly.

I can setup EKF origin / set home point via GCS or AHRS_ORIGIN_x, also can install airspeed sensor, but that does not help.
So you say plane without GPS that flying manual is not possible?
No way to use EKF, only DCM?
Is correct way in this setup not to use EKF and just AHRS_EKF_TYPE, 0
Why it works on copter but not on plane?

Thanks.

There is no way to safely use plane without a position source of some kind.

Copter has some extra handling for it which we don’t have in plane. I hope that it will be one of the capabilities that we will add for the 4.8 release.

Do github issue exists for this? I’d be more than happy to assist, but my knowledge of ardupilot internals is not enough to propose a PR.

I just started using Arducopter 4.7.1 with MG-902 (both for the first time) and started to face the similar issue. We have repeatedly calibrated (indoor and outdoor) the external compass, and we still see this PreArm error message. Is it too near to the carbon fiber plate, but we do not think so?

Do I have to set GPS_DELAY_MS = 200, same as M10G-5883, but MicoAir didn’t mention it?

PreArm: AHRS: EKF3 Yaw inconsistent 31 deg. Wait o

FCU = MicoAir743v2-AIO-45A
Logfile.


Hi @Jai.GAY,

It looks like the vehicle is a Copter and has a GPS so it doesn’t appear to be the same issue as is discussed higher in this thread. I think in the issue is likely just that the internal and external compass disagree which likely means one of them is getting interference from the wires around it.

Putting the compass on a mast is probably a good idea and if its the internal compass that is incorrect then disabling is probably the best that can be done.

txs!

There is only one compass (external). MicoAir743v2-AIO-45A does not have a built-in internal compass.

The MicoAir743v2-AIO doesn’t have a built-in compass sensor, but you can attach an external compass using I2C on the SDA and SCL connector.

We just did a migration from MicoAir743v2-AIO-45A + M10G-5883 + Arducopter 4.6.3 + frame A to MicoAir743v2-AIO-45A + MG-902 + Arducopter 4.7.1 + frame B.

Surprisingly, the compass MG-902 calibration was fast both indoors and outdoors.

I solved it by configuring this line.