Skip to main content
Visitor II
December 16, 2020
Solved

LIS3DH Single and Double click interrupt at the same time

  • December 16, 2020
  • 2 replies
  • 1078 views

Single click interrupt works fine, Double click interrupt works fine. When trying to enable both at the same time only the double clicks work.

I have searched, and there are 3 old topics with this exact question, all are closed with no answer. Could you just provide an answer instead of just closing this one too? Is it a silicon bug? Or some error in the datasheet or appnote AN3308?

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

    Hi @Community member​ ,

    I'm afraid they enter in conflict and the double click interrupt prevails. So, if you just tap one single time on the sensor while both interrupt are enabled, you are not able to see the single click interrupt. This is declared in the AN3308 application note, p.34 (last row):

    0693W000006G9TsQAK.pngIt could be however possible to implement the single click in a different way, acting on the INT1_SRC (31h), INT1_THS (32h) and INT1_DURATION (33h), by "constructing by hand" the single click event detector. The double click has to be routed in this case on the INT2 pad.

    Please let me know it can help you.

    -Eleon

    2 replies

    ST Employee
    December 17, 2020

    Hi @Community member​ ,

    I'm afraid they enter in conflict and the double click interrupt prevails. So, if you just tap one single time on the sensor while both interrupt are enabled, you are not able to see the single click interrupt. This is declared in the AN3308 application note, p.34 (last row):

    0693W000006G9TsQAK.pngIt could be however possible to implement the single click in a different way, acting on the INT1_SRC (31h), INT1_THS (32h) and INT1_DURATION (33h), by "constructing by hand" the single click event detector. The double click has to be routed in this case on the INT2 pad.

    Please let me know it can help you.

    -Eleon

    ELevh.2Author
    Visitor II
    December 18, 2020

    Thank you for that clarification. I didnt notice the implicatinos of that truth table, I was hoping it was supposed to work as displayed in "Figure 16: Single and double-click recognition" on page 32.

    For this proof of concept application it worked out ok anyway, using double on one axis and single on the other two works good enough. Another fix could be to set it to only single and use software double clicks instead, that would add the benefit of tripple or more aswell, but at the cost of added cpu load..