Merge pull request #72 from kattni/circuitpython-quick-start

Cap touch example
This commit is contained in:
Kattni 2018-03-09 18:18:50 -05:00 committed by GitHub
commit 8d314142db
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -0,0 +1,10 @@
import time
import board
import touchio
touch_A0 = touchio.TouchIn(board.A0) # Will not work on Circuit Playground Express!
while True:
if touch_A0.value:
print("Touched A0!")
time.sleep(0.05)