test water pump

This commit is contained in:
joshuashoemaker 2021-01-26 20:37:06 -06:00
parent 15d1386288
commit 287797fa5f

View File

@ -0,0 +1,14 @@
import RPi.GPIO as GPIO
from time import sleep
motor_channel = (37, 35)
GPIO.setwarnings(True)
GPIO.setmode(GPIO.BOARD)
GPIO.setup(motor_channel, GPIO.OUT)
GPIO.output(motor_channel, (GPIO.HIGH, GPIO.LOW))
print('Should be on')
sleep(1)
GPIO.output(motor_channel, (GPIO.LOW, GPIO.LOW))