Compass variance with 3DR Pixhawk

Hello

I have an issue with frequently occuring compass variance. Arducopter 4.1.3
Reviewing the log, it can be seen that there are big spikes especially with MAG[0] in x-axis and z-axis. MAG[1] does not show any spikes

  1. Is MAG[0] the internal or external compass? I am a bit confused about which MAG[xx] or MAGx.is the internal compass.
  2. What is the reason for the spikes (up to -4gauss)

Bin-file:

Thanks for your kind support

BR

Harald

I think from your settings that the first compass is external and is in use. This is correct.
It’s not badly affected by battery current and I see you’ve done the compass/motor calibration.

Those glitches in Mag X are almost like a connector issue. The glitches are there in Y and Z axis too but not as bad.
Also GPS HDOP is getting too high for most of that flight. The GPS readings also have “glitches” but not at the same times as the compass readings. Maybe the whole unit is bad.
Check all your connectors, and measure that a good solid 5 volts DC is getting to your GPS unit.

Hello Shawn

Thanks very much for your help. Especially the hint that the FC also looses satellites frequently - which I have not noticed - was very helpful and made the focus clear to the GPS unit or cable.
I changed the cable and made 5 flights altogether today and no problems/spikes anymore from Compass as well as stable hdop / numbers of satellites.

BR

Harald

Thanks. Problem solved