Weird behaviour in Loiter mode

Hi Team,

Today, while Flying in Loiter mode, The Quadcopter has deviated from the locked position significantly and there was also yaw drift upto 180 degrees, I had to take control manually from the loiter mode.
This never happened before.

Can anybody tell me what has happened.

Attaching the log file link

https://drive.google.com/drive/folders/1F3Aw2hB4Eda3qzjOLapnmw0wInY_CzY0

Your compass is toast, and only one compass is configured for use. Disable the HMC compass (or replace) and use the IST.

Hi Andras,

If the compass is toast, then i should be seeing yaw drifts right from the start right ?, but after taking control, I again engaged loiter mode again, but this time, the craft did hold position for some time before landing.

And also after take off, the craft did hold position for plenty of time.

What is going on here, and also how compass effects the gps lock of the craft

Without compass, there is no gps position hold, with bad compass there is bad position hold. You HMC compass output looks like this :


And the second IST (good) compass output looks like this :

If i were to enable IST compass and redo the compass calibration again, then will the problem resolve.

I still don’t know how my compass got damaged, I thought Hardware failures were rare.

FYI just before few flights, I accidentally slammed the quad against a wall, the compass should have damaged at that time. But the damage didn’t show for few flights.

What do you think.

I don’t know why. The only clear thing is that the HMC compass is not OK, and it must be replaced or disabled.

I will replace the compass and will do a test flight. And check if the problem is resolved, Thank you for your analysis.

Hi Andras,

I have replaced the compass and did a test flight, The flight went great, There are no significant deviations from the gps lock and there are no large yaw drifts,

Can u check this from the logs and let me know and also how is my thrust to weight ratio, is it good
And also can you let me know if u observe any unknown problems.

Thank you