Hi @Community member ,
even if the LIS2HH12 doesn't directly implement the tap detection, you can consider the DT0101 design tip, that suggest you how to implement this feature on accelerometer even in the absence of the direct digital feature, for example the LIS2DH12.
For single-tap recognition there are two parameters to set up – threshold and shock time window.
- Threshold defines the intensity of the shock needed to generate a single-tap interrupt. The amplitude of the shock is proportional to the force that the user applies in either a positive or negative direction.
- Shock time window sets the maximum allowed duration of a shock. During this window the acceleration has to fall below the pre-selected threshold. Figure 2. depicts functionality of the shock window parameter.
In the LIS2HH12 case, you can tune ACT_THS (1Eh) and ACT_DUR (1Fh) to define the shape of the single tap event, as shown in the picture below:
If my reply helped you in answering 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