fix(lampion): update
This commit is contained in:
parent
9f06b15675
commit
fee4cfd7d1
1 changed files with 2 additions and 1 deletions
|
@ -4,6 +4,7 @@ import os
|
||||||
import asyncio
|
import asyncio
|
||||||
import websockets
|
import websockets
|
||||||
import json
|
import json
|
||||||
|
from multiprocessing import Process, Value
|
||||||
import requests
|
import requests
|
||||||
|
|
||||||
status = Value('i', 2)
|
status = Value('i', 2)
|
||||||
|
@ -13,7 +14,7 @@ status = Value('i', 2)
|
||||||
# L'interface est ACTIVE LOW
|
# L'interface est ACTIVE LOW
|
||||||
def changecolor(color):
|
def changecolor(color):
|
||||||
if color=="ROSE":
|
if color=="ROSE":
|
||||||
requests.post("http://192.168.51.249/0", data=b'1')
|
requests.post("http://192.168.51.249/0", data=b'0')
|
||||||
requests.post("http://192.168.51.249/1", data=b'0')
|
requests.post("http://192.168.51.249/1", data=b'0')
|
||||||
elif color=="BLANC":
|
elif color=="BLANC":
|
||||||
requests.post("http://192.168.51.249/0", data=b'0')
|
requests.post("http://192.168.51.249/0", data=b'0')
|
||||||
|
|
Loading…
Add table
Reference in a new issue