Skip to main content
Visitor II
December 24, 2024
Question

Single and Double tapping on LSM6DSL accelerometer

  • December 24, 2024
  • 1 reply
  • 575 views

Hello,

 I am trying to detect Single & Double tapping on LSM6DSL accelerometer.

I am configuring the relevant registers as follows:

CTRL1_XL=0x60
TAP_CFG=0x8E
TAP_THS_6D= 0x8
INT_DUR2=0x45
WUP_THS=0x80
MD1_CFG=0x48

Every time I tap the accelerometer, and interrupt is generated and the I read the TAP_SRC register to identify the type of the type.

The  X_TAP, Y_TAP and Z_TAP  bits are updated properly.

But I NEVER get the SINGLE_TAP and DOUBLE_TAP bits set - They are always ZERO.

Can someone please help me what am doing wrong?

Thanks

    This topic has been closed for replies.

    1 reply

    Technical Moderator
    January 3, 2025

    Hi @DZado.2 ,

    Can you try to follow the two examples on Github and let me know if you solve the problem?

    Unfortunately, we don't have specific examples for LSM6DSL but you can you those for LSM6DSM because the tap detection registers do not change between the two products.