$15 external compass for APM 2.5

As a followup to a conversation in this thread: 

I have successfully used this $15 sparkfun HMC5883L breakout board: https://www.sparkfun.com/products/10530

as an external compass on my APM 2.5.  

Used the instructions here: http://copter.ardupilot.com/wiki/common-external-magnetometer-for-improved-performance/

The process is even simpler than those instructions, since the sparkfun board is already wired for 3.3V.  Just connect four wires and cut a jumper on he APM to disable the onboard compass.

I wasn't able to source the correct cable from sparkfun, but got one that was 1mm OC instead of the 1.25 OC that the APM uses on the i2c port.  A little very minor pin bending and hot glue to hold it in seemed to do the trick.

The HMC583L is the same sensor that's on the APM and on the 3DR external compass/GPS module.

E-mail me when people leave their comments –

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

Join diydrones


  • Thank you very much for your help ... at the end of the two compass that was in my power ... none worked ... a friend, who also has a board arduflyer, commissioned this compass in hk (http://www.hobbyking .com/hobbyking/store/__25095__Multiwii_Compass_Module_HMC5883L.html) was enough to change the cable, plug and everything worked perfectly ...!
    I leave you a big hug.

  • Josh thank you very much ... I'll try ...!

  • Marcelo,

    On the APM 2.5 just re-solder the bridge you cut and that will re-enable your internal compass.

  • This is the compass I'm testing ....(http://www.goodluckbuy.com/hmc5883l-triple-axis-compass-magnetomete...) I have also this ... (http://articulo.mercadolibre.com.ar/MLA-475935044-modulo-compas-mag...) but this does not yield any data ... the other at least seem that measured magfield, we do not throw any data in relation to the cardinal points ... if I move the compass, I see no change in the mission planer. Failure of both the compass test
    I've tried everything .. and I could not get them to work ... in case ... is there any easy way to retrieve the internal compass ...????
    thank you very much

  • Marcelo, do you have a 3.3v arduino?  Try testing the compass off of the APM to verify that it works.

  • Thank you very much Jani, if I understand that these values ​​are high, so the need to install external compass, to keep him away from all sources of interference. Now someone else has had problems installing the external compass or just me ... at the end of mission planer when I check, I get the following error message "compass initialization failed" ... this happens to me even with the connected external compass .... that's why I ask for your help ...

  • Developer

    Marcelo 72% is a bit too much. You should try to keep it way below 60%. Good values starts under 30% and really good is under 20%.

  • Hello friends, I wanted to make an inquiry ...
    I've been trying to install an external compass in my apm 2.5, following your instructions, but I have not managed to make it work.
    The compass in question is a HMC5883L Board Track cut, I connected to the I2C port, if I run the test terminal compass in mission planner ... should give me some reading ... or even with external compass connected, indicate initialization error ...? ? If instead you should give me some sort of reading, as I have a serious problem ...! since cutting board track and now I can not run the external compass.
    Finally, external compass this change was due to under compassmot ... I have a 72% magnetic interference ... and I have a good chance of raising the board ...
    I leave you a hug from Argentina

  • 5th connection DRDY...not used

    I can't remember what online page I ordered from...I'll try to find it in my history.


  • Earl, I can't find it on their "store" page. Also, what is the 5th connection for?

This reply was deleted.