Add files via upload

This commit is contained in:
tpollina 2019-12-13 22:02:00 -08:00 committed by GitHub
parent 92214985f9
commit 3f584454c2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 9 deletions

View file

@ -18,9 +18,9 @@ state = str(sys.argv[1])
def light(state): def light(state):
if state == "on": if state == "true":
GPIO.output(21,GPIO.HIGH) GPIO.output(21,GPIO.HIGH)
if state == "off": if state == "false":
GPIO.output(21,GPIO.LOW) GPIO.output(21,GPIO.LOW)
light(state) light(state)

View file

@ -3,8 +3,6 @@
from adafruit_motor import stepper from adafruit_motor import stepper
from adafruit_motorkit import MotorKit from adafruit_motorkit import MotorKit
from time import sleep
import RPi.GPIO as GPIO
kit = MotorKit() kit = MotorKit()
@ -15,8 +13,3 @@ pump_stepper = kit.stepper2
stage.release() stage.release()
pump_stepper.release() pump_stepper.release()
#turn off LED after killing
GPIO.setmode(GPIO.BCM)
GPIO.setwarnings(False)
GPIO.setup(21,GPIO.OUT)
GPIO.output(21,GPIO.LOW)