Magnetometer has me scratching my head...

I have been trying to figure out why my loiter mode is circling and just plain bad compared to earlier versions of the software (I am running 2.0.49). I have been looking at the magnetometer and am seeing the following behavior (I live in Columbus, OH so have been setting the declination to -6.77).

When the quad points North the APM shows the direction as North.

When pointing South.. APM shows South.

    BUT...

When pointing East, the APM is reporting -15deg less than it should be. It should show about 90 deg and is showing 75deg.

 

When pointing West, APM is showing +15deg more than it should be. It should show 270 and is showing 285deg.

 

The following output is shown from the "compass" output in CLI:

 

Compass

-------------------------------------------------------------

enabled

Mag Dec: -6.7700

Mag offsets: -77.8462, -15.9017, 89.9628

 

Can someone offer some insight as to why I am getting these weird readings and if this is normal?

 

Thanks...

You need to be a member of diydrones to add comments!

Join diydrones

Email me when people reply –

Replies

  • I agree those compass readings seems troublesome. But it does not explain why the loiter mode worked better in previous FW versions.

    I too am struggling with tuning the loiter out of circling tendencies, but since I am fresh on Arducopter I cannot compare to previous FW versions.

    I will follow this thread with interest.

  • Yep I found the same. Even the xbee wires need to be as far away from compass and oil pan as possible. Otherwise I found that many sensor readings become unstable. This probably seems obvious to many with more experience than myself but when I saw it for my own eyes it really hit home.

  • Developer

     

    This is certainly because you have magnetic influences on the frame. Can be caused by near wires, ferromagnetic parts.

     

    Near wires can cause dynamic changes, according to the current flowing in them. Lock your frame on the ground and try to push throttle and roll/pitch/yaw sticks. You shouldn't see compass deviation inside Mission Planner. If you see deviations, then your wiring must be redesigned or the compass moved far from power wiring.

     

  • Developer

    I wonder if it could be the enviroment where you're testing it.  For example if there were something pulling the compass "needle" north you'd see the behaviour you've described.

This reply was deleted.

Activity

DIY Robocars via Twitter
Jan 28
DIY Robocars via Twitter
RT @Heavy02011: ⁦@diyrobocars⁩ : A Home-brew computer club* for Connected Autonomous Driving. talk at #piandmore ⁦@PiAndMore⁩ on Jan 23rd h…
Jan 23
DIY Robocars via Twitter
RT @a1k0n: New blog post! Deep dive into my ceiling light based localization algorithm which runs in 1ms on a Raspberry Pi 3: https://t.co/…
Jan 23
DIY Robocars via Twitter
Great new guide to using @donkey_car https://custom-build-robots.com/donkey-car-e-book-en
Jan 23
DIY Robocars via Twitter
RT @chr1sa: The next @DIYRobocars virtual AI race is tomorrow morn at 9:00am PT. You can watch live on Twitch https://www.meetup.com/DIYRobocars/events/275268196/
Jan 22
DIY Robocars via Twitter
New version of Intel OpenBot! This resolves many of the issues with the first version, including a much smoother tr… https://twitter.com/i/web/status/1352395636369313798
Jan 21
DIY Drones via Twitter
Using ArduRover with an RTK GPS https://ift.tt/2N9I3RO
Jan 18
DIY Drones via Twitter
Jan 18
DIY Robocars via Twitter
Jan 18
DIY Robocars via Twitter
Jan 15
DIY Robocars via Twitter
Jan 15
DIY Drones via Twitter
Jan 14
DIY Robocars via Twitter
RT @Heavy02011: @diyrobocars : A Home-brew computer club* for Connected Autonomous Driving on Jan 23rd, 2021 https://www.meetup.com/Connected-Autonomous-Driving/events/275728684/ #Meetu…
Jan 14
DIY Robocars via Twitter
Jan 14
DIY Robocars via Twitter
RT @Heavy02011: ⁦@diyrobocars⁩ Autonomous Driving Assembly at #rC3. join us at https://rc3.world/rc3/assembly/diyrobocars-f1tenth/ ⁦@f1tenth⁩ ⁦@DAVGtech⁩ ⁦@DWalmroth⁩…
Jan 11
DIY Robocars via Twitter
RT @chr1sa: New car designs coming for our next @DIYRobocars @donkey_car virtual race on the 23rd. Choose any one you want at race time Le…
Jan 11
More…