Why do I get very different magnetometer results from 3 FXOS8700 devices located side-by-side?

cancel
Showing results for 
Search instead for 
Did you mean: 

Why do I get very different magnetometer results from 3 FXOS8700 devices located side-by-side?

529 Views
rev
Contributor III

I've got 3 FDRM-FXS-9AXIS boards mounted side-by-side, each with a unique I2C address.  I'd expect the magnetometer readings to be fairly close, but the raw results are very different.

Unit 1: X=355, Y=404, Z=370

Unit 2: X=510, Y=26, Z= 490

Unit 3: X=620, Y=-195, Z=150

They are taped in close proximity to each other on piece of abs plastic and held >12" away from any iron or substantial magnetic fields.  Changing the relative positions has no significant effect on the differences.

Is this expected?

Labels (2)
0 Kudos
1 Reply

114 Views
TomasVaverka
NXP TechSupport
NXP TechSupport

Hello Jonathan,

Yes, it is common to see such differences, the offset is variable from unit to unit as it is pointless to accurately trim the offset when the target market is smartphones, tablets, each with a different hard-iron interfering field. In normal actual practice, the FXOS8700CQ is used with a background compensation algorithm to achieve the best performance. Please refer to our AN4246 and eCompass software for more information.

The easiest method to calibrate the offset is rotating the FXOS8700CQ in a figure of eight twisting motions for a few seconds, record the minimum and maximum magnetometer readings, compute the corresponding offset values by using the min/max averaging and then either substract these offset values from the current magnetometer measurements or write them in the user offset registers 0x3F – 0x44 as shown in my simple example code.


I hope it helps.


Regards,

Tomas


PS: If my answer helps to solve your question, please mark it as "Correct" or “Helpful”. Thank you.

0 Kudos