parent
1a185ad8e6
commit
b90fab0a42
1
main.py
1
main.py
|
@ -25,6 +25,7 @@ def error_print(message: str):
|
||||||
|
|
||||||
#relay
|
#relay
|
||||||
def relay_controller(pin: int, state: str):
|
def relay_controller(pin: int, state: str):
|
||||||
|
print(state)
|
||||||
if state == True:
|
if state == True:
|
||||||
relay = gpiozero.OutputDevice(pin, active_high=True, initial_value=False)
|
relay = gpiozero.OutputDevice(pin, active_high=True, initial_value=False)
|
||||||
relay.on()
|
relay.on()
|
||||||
|
|
Loading…
Reference in New Issue