Adafruit_CircuitPython_Circ.../examples/circuitplayground_slide_switch.py
2019-06-07 14:45:09 -04:00

8 lines
275 B
Python

"""This example prints the status of the slide switch. Try moving the switch back and forth to see
what's printed to the serial console!"""
import time
from adafruit_circuitplayground.express import cpx
while True:
print("Slide switch:", cpx.switch)
time.sleep(0.1)