GPIO more code

This commit is contained in:
9and3r
2014-08-08 11:44:41 +02:00
parent e336fc4b9d
commit 17414dddf3

View File

@@ -7,6 +7,8 @@ logger = logging.getLogger(__name__)
class GPIOManager():
def __init__(self):
GPIO.setmode(GPIO.BCM)
GPIO.setup(23, GPIO.IN, pull_up_down = GPIO.PUD_DOWN)
GPIO.add_event_detect(23, GPIO.RISING, callback=self.printFunction, bouncetime=300)