Black Lives Matter - Action and Equality. ... Adafruit is open and shipping.
0

lis3dh_tap.py on PyBadge
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

lis3dh_tap.py on PyBadge

by twrackers on Mon Jun 08, 2020 12:29 am

Has anyone succeeded in making the LIS3DH tap example work on the PyBadge? The SimpleTest says the accelerometers are working properly, but I cannot get even single taps, let alone double taps, work.

twrackers
 
Posts: 86
Joined: Fri Jan 18, 2013 7:42 pm

Re: lis3dh_tap.py on PyBadge

by siddacious on Tue Jun 16, 2020 7:28 pm

I have; if you have not already, I would suggest looking at the documentation for the set_tap method that is used to adjust the parameters for the tap detection
:
https://circuitpython.readthedocs.io/pr ... DH.set_tap

Additionally the Arduino documentation has some discussion of how the different parameters work:

https://learn.adafruit.com/adafruit-lis ... 1729254-29

Tap detection is to be honest a bit fussy and usually requires a fair amount of trial and error to find settings that work somewhat well, and even then it's usually pretty particular to the scenario being tested.

siddacious
 
Posts: 271
Joined: Fri Apr 21, 2017 3:09 pm

Re: lis3dh_tap.py on PyBadge

by twrackers on Tue Jun 16, 2020 8:21 pm

Too finicky for my blood, I finally rolled my own single-tap version using just the Z-axis accelerometer and a state machine. Still needs some tuning but it works okay for now.

twrackers
 
Posts: 86
Joined: Fri Jan 18, 2013 7:42 pm

Please be positive and constructive with your questions and comments.