duh! xt == xy
This commit is contained in:
parent
3cb79978ce
commit
79874a804b
|
@ -47,7 +47,7 @@ no_cert_check = ssl.create_default_context()
|
||||||
no_cert_check.check_hostname=False
|
no_cert_check.check_hostname=False
|
||||||
no_cert_check.verify_mode=ssl.CERT_NONE
|
no_cert_check.verify_mode=ssl.CERT_NONE
|
||||||
|
|
||||||
scenes = {'br': {}, 'ct': {}, 'xt': {}}
|
scenes = {'br': {}, 'ct': {}, 'xy': {}}
|
||||||
scenes['br']['bright'] = b'{"on": true, "bri": 254, "alert": "none"}'
|
scenes['br']['bright'] = b'{"on": true, "bri": 254, "alert": "none"}'
|
||||||
scenes['br']['relax'] = b'{"on": true, "bri": 144, "alert": "none"}'
|
scenes['br']['relax'] = b'{"on": true, "bri": 144, "alert": "none"}'
|
||||||
scenes['br']['dimmed'] = b'{"on": true, "bri": 77, "alert": "none"}'
|
scenes['br']['dimmed'] = b'{"on": true, "bri": 77, "alert": "none"}'
|
||||||
|
@ -56,10 +56,10 @@ scenes['ct']['bright'] = b'{"on": true, "bri": 254, "ct": 367, "alert": "none",
|
||||||
scenes['ct']['relax'] = b'{"on": true, "bri": 144, "ct": 447, "alert": "none", "colormode": "ct"}'
|
scenes['ct']['relax'] = b'{"on": true, "bri": 144, "ct": 447, "alert": "none", "colormode": "ct"}'
|
||||||
scenes['ct']['dimmed'] = b'{"on": true, "bri": 77, "ct": 367, "alert": "none", "colormode": "ct"}'
|
scenes['ct']['dimmed'] = b'{"on": true, "bri": 77, "ct": 367, "alert": "none", "colormode": "ct"}'
|
||||||
scenes['ct']['nightlight'] = b'{"on": true, "bri": 1, "ct": 447, "alert": "none", "colormode": "ct"}'
|
scenes['ct']['nightlight'] = b'{"on": true, "bri": 1, "ct": 447, "alert": "none", "colormode": "ct"}'
|
||||||
scenes['xt']['bright'] = b'{"on": true, "bri": 254, "hue": 8402, "sat": 140, "effect": "none", "xy": [0.4578, 0.41], "ct": 367, "alert": "none", "colormode": "xy"}'
|
scenes['xy']['bright'] = b'{"on": true, "bri": 254, "hue": 8402, "sat": 140, "effect": "none", "xy": [0.4578, 0.41], "ct": 367, "alert": "none", "colormode": "xy"}'
|
||||||
scenes['xt']['relax'] = b'{"on": true, "bri": 144, "hue": 8402, "sat": 140, "effect": "none", "xy": [0.5019, 0.4152], "ct": 447, "alert": "none", "colormode": "xy"}'
|
scenes['xy']['relax'] = b'{"on": true, "bri": 144, "hue": 8402, "sat": 140, "effect": "none", "xy": [0.5019, 0.4152], "ct": 447, "alert": "none", "colormode": "xy"}'
|
||||||
scenes['xt']['dimmed'] = b'{"on": true, "bri": 77, "hue": 8402, "sat": 140, "effect": "none", "xy": [0.4578, 0.41], "ct": 367, "alert": "none", "colormode": "xy"}'
|
scenes['xy']['dimmed'] = b'{"on": true, "bri": 77, "hue": 8402, "sat": 140, "effect": "none", "xy": [0.4578, 0.41], "ct": 367, "alert": "none", "colormode": "xy"}'
|
||||||
scenes['xt']['nightlight'] = b'{"on": true, "bri": 1, "hue": 8402, "sat": 140, "effect": "none", "xy": [0.561, 0.4042], "ct": 367, "alert": "none", "colormode": "xy"}'
|
scenes['xy']['nightlight'] = b'{"on": true, "bri": 1, "hue": 8402, "sat": 140, "effect": "none", "xy": [0.561, 0.4042], "ct": 367, "alert": "none", "colormode": "xy"}'
|
||||||
|
|
||||||
def get_state(type, id):
|
def get_state(type, id):
|
||||||
url = f"https://{bridge}/api/{token}/{type}/{id}"
|
url = f"https://{bridge}/api/{token}/{type}/{id}"
|
||||||
|
|
|
@ -8,4 +8,4 @@ PATH=$PATH:/usr/local/bin
|
||||||
# sensor 50 to check
|
# sensor 50 to check
|
||||||
# light 24 to control
|
# light 24 to control
|
||||||
# scene dimmed
|
# scene dimmed
|
||||||
/home/mischa/hue/daylight-trigger.py 10.0.0.174 $(cat /home/mischa/hue-token) -s 50 -l 24 -a dimmed -v
|
/home/mischa/hue/daylight-trigger.py 10.0.0.174 $(cat /home/mischa/hue-token) -s 50 -l 24 -a dimmed -v -d
|
||||||
|
|
Loading…
Reference in New Issue