anthropo

  • ***
  • 110
Please help with gps mag orientation
« on: January 28, 2019, 07:10:38 pm »
Hello,
it's a day i'm trying to set my external compass orientation. I want the 3 bars stay at zero in the mag settings. it is never the case.
when i set 0,0,0 all is ok till i return the quad. Then z goes to 43.

I tried the 64 combinaisons (brute force) as i can't solve the problem by looking at the gps.

Can you help me ? here is a picture of the bottom of the gps. The mag is written 5883 then it is the HMC58836L

I'm serious, I'm sick of it.

Thank you

anthropo

  • ***
  • 110
Re: Please help with gps mag orientation
« Reply #1 on: January 28, 2019, 08:16:35 pm »
i just opened a dji gps i had. The mag is in the same position. So why do i get this gap on z axis returning the quad ?

Re: Please help with gps mag orientation
« Reply #2 on: January 29, 2019, 04:41:01 am »
GPS has an arrow on it.  That arrow must point forward.  You probably already did that.  Also, if you are using I2C aux mag (separate cable, usually 2 wire that goes to FlexiPort) then you must set Aux Mag Orientation (in Attitude->Magnetometer) to either 0,180,0 or 180,0,180 (they are the same rotation).  This will get it close.  It is OK if it is a few units off.  Rotating fast will make it show farther off than it is.  Rotate slowly and stop to check at a few rotations.

If you are using an OP GPSv9 or a DJI GPS, leave the Aux Mag Orientation at 0,0,0

This article has everything about setup, test, debug of aux mag.
https://librepilot.atlassian.net/wiki/spaces/LPDOC/pages/18382863/Aux+Mag+Setup+and+Calibration

Also be aware that the Flight Controller must be oriented correctly too.  The arrow must point forward, or if not, Attitude -> Settings -> RotateVirtual.. must be set correctly.  First get it flying without the GPS/mag to prove that the FC orientation, etc. is configured correctly.
« Last Edit: January 29, 2019, 05:29:38 am by TheOtherCliff »