FXOS8700CQ different readings, same board

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

FXOS8700CQ different readings, same board

1,180 Views
jorge_ar
Contributor I

Hello! 

I've designed a board using a FXOS8700CQ. I have 10 boards working. When I read the x,y,z uT values, they differ from each other a lot. The conditions are the same for all boards (tested one by one in the same spot with same orientation. 

If I write the offset registers (MOFF_X_LSB_REG, MOFF_X_MSB_REG, etc etc) the readings of all boards are near zero.

What is the source of this drifts between boards? Is there anything more to calibrate?

thanks!!

Labels (1)
0 Kudos
5 Replies

783 Views
jorge_ar
Contributor I

Thanks you! 

One more question, Shoud I write these registers every time I init the sensor or they are stored inside the FXOS forever?

0 Kudos

783 Views
TomasVaverka
NXP TechSupport
NXP TechSupport

Hello Jorge,

They need to be written each time you init the FXOS8700CQ. 

Best regards,

Tomas

0 Kudos

783 Views
TomasVaverka
NXP TechSupport
NXP TechSupport

Hello Jorge,

Without calibration it is common to see different output values, the offset of the magnetometer is variable from unit to unit as it is pointless to accurately trim the offset when the main target markets of FXOS8700CQ are smartphones, tablets and other mobile devices, each with a different hard-iron interfering field. That is also why we implemented the auto-calibration function which is usually sufficient for applications where hard-iron interference is the primary source of error and soft-iron distortion is minimal or non-existent. Have you also implemented it according to the AN4459?

 

I would also recommend taking a closer look at our other applications notes such as AN4247 andAN4246/AN4248 if a more complex calibration is required.

Best regards,

Tomas

0 Kudos

783 Views
jorge_ar
Contributor I

Hello! I've implemented the following function. I do lot of readings while moving the board in every direction. While doing that, the program stores the max and min values for each axis. Then, I write the MOFF_X_LSB_REG and  MOFF_X_MSB_REG (for each axis). I think that it's similar to AN4459 but implemented in code. 

Is that enough for calibrating hard iron interferences?

Can you share the code of the AN4246?

My application requieres that the Z axis to be really sensitive in order to detect cars and other vehicles.

Thanks, 

0 Kudos

783 Views
TomasVaverka
NXP TechSupport
NXP TechSupport

Hello Jorge,

Yes, it should be enough, I have also used this simple calibration method in my example code here.

As far as I know, the code of AN4246 is part of NXP Sensor Fusion Library for Kinetis MCUs:

https://www.nxp.com/docs/en/data-sheet/NSFK_DS.pdf 

NXP® Sensor Fusion Library for Kinetis® MCUs 

Best regards,

Tomas

0 Kudos