Skip to main content
Visitor II
April 28, 2021
Solved

Calibration of LIS2DW12

  • April 28, 2021
  • 3 replies
  • 1262 views

Hello,

I can not find any information on calibration of the acetometer in the LIS2DW12.

Is it something we can do ourselves, is it done automatically etc.

Would like a reference or explanation.

Thank you

    This topic has been closed for replies.
    Best answer by Eleon BORLINI

    Hi @Msaga.1​ ,

    the accelerometer is calibrated at production level, and the calibration values are stored in the reserved registers, and it is better to not modify them.

    However, it could happen that after the soldering process or handling actions, the accelerometer might be slightly out of calibration, and in this case you can:

    • measure the offset on the 3 axis in a steady position, and write the obtained values in the X_OFS_USR (3Ch), Y_OFS_USR (3Dh) and Z_OFS_USR (3Eh) registers (datasheet, p.55);
    • and / or use a calibration library, for example from the X-CUBE-MEMS1 package, such as the MotionAC library: it provides real-time accelerometer calibration through offset and scale factor coefficients used to correct accelerometer data. .

    If my reply answered your question, please click on Select as Best at the bottom of this post. This will help other users with the same issue to find the answer faster.

    -Eleon

    3 replies

    ST Employee
    April 28, 2021

    Hi @Msaga.1​ ,

    the accelerometer is calibrated at production level, and the calibration values are stored in the reserved registers, and it is better to not modify them.

    However, it could happen that after the soldering process or handling actions, the accelerometer might be slightly out of calibration, and in this case you can:

    • measure the offset on the 3 axis in a steady position, and write the obtained values in the X_OFS_USR (3Ch), Y_OFS_USR (3Dh) and Z_OFS_USR (3Eh) registers (datasheet, p.55);
    • and / or use a calibration library, for example from the X-CUBE-MEMS1 package, such as the MotionAC library: it provides real-time accelerometer calibration through offset and scale factor coefficients used to correct accelerometer data. .

    If my reply answered your question, please click on Select as Best at the bottom of this post. This will help other users with the same issue to find the answer faster.

    -Eleon

    Msaga.1Author
    Visitor II
    April 28, 2021

    Hi Eleon,

    Thank you for your answer. Regarding your suggestion to measure the offset on the 3 axis in a steady position, and write the obtained values in the X_OFS_USR (3Ch), Y_OFS_USR (3Dh) and Z_OFS_USR (3Eh) registers. I saw that the values on the axis at rest are not 0, but there is a slight deviation. What can I do so the values will be 0(except at Z of course that should be close to g value)

    Thank you

    ST Employee
    April 28, 2021

    Hi @Msaga.1​ ,

    you can characterized accurately these value and then put them in the register (volatile memory): when you'll run the acquisition, you'll get the already compensated values in the output registers.

    You can do the same for the Z axis, but you have to subtract the 1g nominal value.

    -Eleon

    Msaga.1Author
    Visitor II
    April 29, 2021

    Thank you very much