Add files via upload
This commit is contained in:
parent
92214985f9
commit
3f584454c2
|
@ -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)
|
||||||
|
|
|
@ -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)
|
|
||||||
|
|
Loading…
Reference in a new issue