Bom dia pessoal, estou a tentar automatizar as minhas downlights da xiaomi philips zhirui, mas nao estou a conseguir não sei muito bem porquê. será que alguém me consegue ajudar?
A minha automação
- alias: Ligar 18h00 20h00
initial_state: true
trigger:
platform: state
entity_id: binary_sensor.motion_sensor_158d00029be9c3
from: 'off'
to: 'on'
condition:
- condition: time
after: '18:00:00'
before: '20:00:00'
- condition: numeric_state
entity_id: sensor.illumination_158d00029be9c3
below: 15
action:
- service: light.turn_on
entity_id: light.downlight_cozinha_entrada
data:
Brightness: 100
Scene : 1
- service: light.turn_on
data:
entity_id: binary_sensor.motion_sensor_158d00029be9c3
configuration.yaml está assim
light:
- platform: yeelight
devices:
xxx.xxx.x.xxx:
name: yeelight_rgb_7811dc6b09nm
- platform: xiaomi_miio
name: Downlight Cozinha Entrada
host: xxx.xxx.x.xxx
token: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
model: philips.light.bulb
- platform: xiaomi_miio
name: Downlight Cozinha Janela
host: xxx.xxx.x.xxx
token: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
model: philips.light.bulb
e o erro que o home assistant reporta:
2018-11-04 09:06:26 WARNING (MainThread) [homeassistant.config] Package portao contains invalid customize
2018-11-04 09:06:26 WARNING (MainThread) [homeassistant.config] Package cozinha contains invalid customize
2018-11-04 09:06:51 ERROR (SyncWorker_3) [homeassistant.components.light.yeelight] Failed to connect to bulb xxx.xxx.x.xxx, yeelight_rgb_7811dc6b09nm: A socket error occurred when sending the command.
2018-11-04 09:07:00 ERROR (MainThread) [homeassistant.core] Timer got out of sync. Resetting
2018-11-04 09:07:10 ERROR (MainThread) [homeassistant.helpers.entity] Update for media_player.radio fails
Traceback (most recent call last):
File "/usr/local/lib/python3.6/site-packages/jsonrpc_async/jsonrpc.py", line 29, in send_message
response = yield from self._request(data=message.serialize())
File "/usr/local/lib/python3.6/site-packages/aiohttp/client.py", line 391, in _request
await resp.start(conn)
File "/usr/local/lib/python3.6/site-packages/aiohttp/client_reqrep.py", line 770, in start
self._continue = None
File "/usr/local/lib/python3.6/site-packages/aiohttp/helpers.py", line 673, in __exit__
raise asyncio.TimeoutError from None
concurrent.futures._base.TimeoutError
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/local/lib/python3.6/site-packages/homeassistant/helpers/entity.py", line 221, in async_update_ha_state
await self.async_device_update()
File "/usr/local/lib/python3.6/site-packages/homeassistant/helpers/entity.py", line 347, in async_device_update
await self.async_update()
File "/usr/local/lib/python3.6/site-packages/homeassistant/components/media_player/kodi.py", line 479, in async_update
'albumartist', 'showtitle', 'album', 'season', 'episode']
File "/usr/local/lib/python3.6/site-packages/jsonrpc_async/jsonrpc.py", line 31, in send_message
raise TransportError('Transport Error', message, exc)
jsonrpc_base.jsonrpc.TransportError: ("Error calling method 'Player.GetItem': Transport Error", TimeoutError())
Obrigado pela vossa ajuda.