init stuff

This commit is contained in:
Giulio De Pasquale 2017-08-18 14:33:11 +02:00
parent 9db92276be
commit c01556ac9f

View File

@ -1,8 +1,13 @@
import RPi.GPIO as GPIO
CHANNEL = 19
GPIO.setmode(GPIO.BOARD)
GPIO.setup(CHANNEL, GPIO.IN)
if GPIO.input(CHANNEL):
print('Input was HIGH')
else:
print('Input was LOW')
print('Input was LOW')
GPIO.cleanup()