gregtomasch / USFSMAX_MMC_Module

Test sketches and information to use the improved USFSMAX Module with MMC5983 magnetometer
9 stars 2 forks source link

Is the orientation output using magnetic north or true north? #5

Open teknoman117 opened 1 day ago

teknoman117 commented 1 day ago

I will fully admit, I don't have a great way of testing the accuracy of the resulting heading at the moment. Still working on integrating the USFSMAX (MMC) into my robot where I can check against an RTK GPS.

I updated the magnetic field strength and declination constants for my location in the config. After calibrating the 3D DHI corrector (a few different times), I noticed that the resulting heading seems to mostly correspond with the magnetic heading reported by my phone (I understand that phone compasses are also in general not great).

If I change the declination in the host tool after calibration and restart the USFSMAX, I notice that the reported heading doesn't seem to be affected.

Does the resulting quaternion use magnetic north or "true" north (as defined by declination)? Or does this value only matter during calibration?

kriswiner commented 19 hours ago

Perhaps Greg can add something but:

"Does the resulting quaternion use magnetic north or "true" north (as defined by declination)?"

Should be true North such that when the USFSMAX is pointing to true North the yaw should read 0 and the quaternion should read 0, 0, 0, 1.

Changes to the configuration file should take effect after restart. I suggest that you remove all power, wait ten seconds, and then try again.

On Thu, Sep 19, 2024 at 10:44 PM Nathan Lewis @.***> wrote:

I will fully admit, I don't have a great way of testing the accuracy of the resulting heading at the moment. Still working on integrating the USFSMAX (MMC) into my robot where I can check against an RTK GPS.

I updated the magnetic field strength and declination constants for my location in the config. After calibrating the 3D DHI corrector (a few different times), I noticed that the resulting heading seems to mostly correspond with the magnetic heading reported by my phone (I understand that phone compasses are also in general not great).

If I change the declination in the host tool after calibration and restart the USFSMAX, I notice that the reported heading doesn't seem to be affected.

Does the resulting quaternion use magnetic north or "true" north (as defined by declination)? Or does this value only matter during calibration?

— Reply to this email directly, view it on GitHub https://github.com/gregtomasch/USFSMAX_MMC_Module/issues/5, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABTDLKX7JVHY3ZREFI4BNGLZXOY4JAVCNFSM6AAAAABORJTQB6VHI2DSMVQWIX3LMV43ASLTON2WKOZSGUZTOOJSGQ2TKNQ . You are receiving this because you are subscribed to this thread.Message ID: @.***>