Skip to main content
Visitor II
March 26, 2020
Question

LIS2DH12 position of 6D.

  • March 26, 2020
  • 1 reply
  • 1503 views

I use LIS2DH12 to determine the position of 6D. My task is to get interruption when the accelerometer is positioned with the + X axis at an angle of 50 degrees or more. Autumn X is also disabled. In this case, the acceleration along the X axis = 1g. I give below the register settings:

CTRL_REG3 (22h) = 0x40

INT1_CFG (30h) = 0b11000010

INT1_THS (32h) = 0x2F

INT1_DURATION (33h) = 0x02

CTRL_REG1 (20h) = 0b00101111

These are all the settings that I enter in the accelerometer. I don’t touch any registers anymore. What am I missing, help.

    This topic has been closed for replies.

    1 reply

    ST Employee
    March 26, 2020

    Hi @AGari​ , did you check the INT1_SRC (31h) register in order to see if the interrupt has been raised at least via software even if not via HW (the INT pin)? Regards

    AGariAuthor
    Visitor II
    March 26, 2020

    Hello! The 6d interrupt works for me, but only when the acceleration along the X axis is close to 1g, and I need it to work at the level of 0.77g, this is when the angle along the X axis is about 50 degrees. The problem is this.

    ST Employee
    March 27, 2020

    So you would like to raise the interrupt along the X axis when the acceleration value along this axis is > 0.77g and not just around 1g, right? I suggest you to try to lower the INT1_THS (32h) value, maybe there is a little non-linearity on the threshold steps. Regards