Update piplayer4.py
This commit is contained in:
+4
-9
@@ -20,13 +20,10 @@ SOUND_SCAN_FAIL = "mnt/INTERNAL/sounds/fail-05.mp3"
|
|||||||
QR_SCANNER_TIMEOUT = 4
|
QR_SCANNER_TIMEOUT = 4
|
||||||
|
|
||||||
# photo sensor on PIN 17
|
# photo sensor on PIN 17
|
||||||
PIN_SENSOR = 4 ## TODO TEST
|
PIN_SENSOR = 5
|
||||||
|
|
||||||
# IR LED on PIN 22
|
# LED on PIN 22
|
||||||
PIN_IR_LED = 22
|
PIN_LED = 22
|
||||||
|
|
||||||
# LED on PIN 27
|
|
||||||
PIN_LED = 27
|
|
||||||
|
|
||||||
# Buttons on PINs 9, 10 and 11
|
# Buttons on PINs 9, 10 and 11
|
||||||
PIN_PREV = 9
|
PIN_PREV = 9
|
||||||
@@ -35,9 +32,7 @@ PIN_NEXT = 11
|
|||||||
|
|
||||||
|
|
||||||
GPIO.setmode(GPIO.BCM)
|
GPIO.setmode(GPIO.BCM)
|
||||||
GPIO.setup(PIN_SENSOR, GPIO.IN, pull_up_down=GPIO.PUD_UP) # TEST
|
GPIO.setup(PIN_SENSOR, GPIO.IN, pull_up_down=GPIO.PUD_UP)
|
||||||
GPIO.setup(PIN_IR_LED, GPIO.OUT)
|
|
||||||
GPIO.output(PIN_IR_LED, GPIO.LOW)
|
|
||||||
GPIO.setup(PIN_LED, GPIO.OUT)
|
GPIO.setup(PIN_LED, GPIO.OUT)
|
||||||
GPIO.output(PIN_LED, GPIO.LOW)
|
GPIO.output(PIN_LED, GPIO.LOW)
|
||||||
GPIO.setup(PIN_PREV, GPIO.IN, pull_up_down=GPIO.PUD_UP)
|
GPIO.setup(PIN_PREV, GPIO.IN, pull_up_down=GPIO.PUD_UP)
|
||||||
|
|||||||
Reference in New Issue
Block a user