-
-
Notifications
You must be signed in to change notification settings - Fork 595
Open
Description
The EU version of the gateway is supported in the current versión of the library and can be intergated in HA.
Some tests had been made to evaluate subdevices resolution with no success:
(venv)$ python /tmp/test_miio_gateway/gateway_devices.py
Traceback (most recent call last):
File "/tmp/test_miio_gateway/gateway_devices.py", line 5, in <module>
gateway.discover_devices()
File "/opt/DevelopmentSpace/hassio/home-assistant/venv/lib/python3.7/site-packages/miio/gateway.py", line 168, in discover_devices
devices_raw = self.get_prop("device_list")
File "/opt/DevelopmentSpace/hassio/home-assistant/venv/lib/python3.7/site-packages/miio/gateway.py", line 207, in get_prop
return self.send("get_device_prop", ["lumi.0", property])
File "/opt/DevelopmentSpace/hassio/home-assistant/venv/lib/python3.7/site-packages/miio/device.py", line 147, in send
command, parameters, retry_count, extra_parameters=extra_parameters
File "/opt/DevelopmentSpace/hassio/home-assistant/venv/lib/python3.7/site-packages/miio/miioprotocol.py", line 203, in send
self._handle_error(payload["error"])
File "/opt/DevelopmentSpace/hassio/home-assistant/venv/lib/python3.7/site-packages/miio/miioprotocol.py", line 263, in _handle_error
raise DeviceError(error)
miio.exceptions.DeviceError: {'code': -5005, 'message': 'params error'}
where gateway_devices.py:
from miio import Gateway
gateway = Gateway("192.168.1.IP", "tokentokentoken")
gateway.discover_devices()
devices = gateway.devices
for dev in devices:
dev.update()
print(dev)@starkillerOG sugest (home-assistant/core#22078) a new approach with the get_device_list command.
chickenbeef, jacopocarlini, airampg, serge1peshcoff, marioskamperis and 2 more
Metadata
Metadata
Assignees
Labels
No labels