Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to fix "unavailable" status? #42

Closed
mthlvt opened this issue Jan 29, 2020 · 4 comments
Closed

How to fix "unavailable" status? #42

mthlvt opened this issue Jan 29, 2020 · 4 comments
Assignees
Labels
bug Something isn't working waiting validation Waiting for user's test/validation

Comments

@mthlvt
Copy link

mthlvt commented Jan 29, 2020

Hi Alberto,

When a device is unavailable (smart switch/bulb), what is the best way to restore them to a normal status?

I tried to turn the device on/off, restart HA without success. I can make the meross devices work in HA when removing the integration, and redoing the setup again, but that's not a practical solution.

On meross native app, all bulbs/devices are connected and responsive.

Tested on switches:

mss310 1.0.0
by Meross
Firmware: 1.1.18

and bulbs:

msl120 2.0.0
by Meross
Firmware: 2.1.18

Note that when I restart HA, I get the following logs:
2020-01-29 20:08:43 WARNING (MainThread) [homeassistant.components.light] Setup of light platform meross_cloud is taking over 10 seconds. 2020-01-29 20:08:43 ERROR (MainThread) [homeassistant.core] Error doing job: Task exception was never retrieved Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 355, in _async_add_entity capabilities=entity.capability_attributes, File "/usr/src/homeassistant/homeassistant/components/light/__init__.py", line 391, in capability_attributes supported_features = self.supported_features File "/config/custom_components/meross_cloud/light.py", line 123, in supported_features if self._device.supports_luminance(): File "/usr/local/lib/python3.7/site-packages/meross_iot/cloud/devices/light_bulbs.py", line 278, in supports_luminance return self.supports_mode(MODE_LUMINANCE) File "/usr/local/lib/python3.7/site-packages/meross_iot/cloud/devices/light_bulbs.py", line 259, in supports_mode return (self.get_abilities().get(LIGHT).get('capacity') & mode) == mode File "/usr/local/lib/python3.7/site-packages/meross_iot/cloud/device.py", line 134, in get_abilities self._abilities = self.execute_command("GET", ABILITY, {})['ability'] File "/usr/local/lib/python3.7/site-packages/meross_iot/cloud/device.py", line 126, in execute_command return self.__cloud_client.execute_cmd(self.uuid, command, namespace, payload, callback=callback, timeout=timeout) File "/usr/local/lib/python3.7/site-packages/meross_iot/cloud/client.py", line 302, in execute_cmd raise CommandTimeoutException("A timeout occurred while waiting for the ACK: %d" % timeout) meross_iot.cloud.exceptions.CommandTimeoutException.CommandTimeoutException: A timeout occurred while waiting for the ACK: 10

Any ideas or tips where to start looking in the code are welcome.
Thanks!

@albertogeniola
Copy link
Owner

Hi,
The issue you mention is related to #46.

@albertogeniola albertogeniola added the bug Something isn't working label Feb 9, 2020
@albertogeniola
Copy link
Owner

Hi, latest version of the component should fix it. Would you please update the component and report back if that's working?

@albertogeniola albertogeniola added the waiting validation Waiting for user's test/validation label Feb 16, 2020
@mthlvt
Copy link
Author

mthlvt commented Feb 17, 2020

Hi Alberto,

It seems to work, could reboot HA faster since the integration loads without long delay, and devices are detected available as expected.

Thanks!

@albertogeniola
Copy link
Owner

Glad to hear that,

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working waiting validation Waiting for user's test/validation
Projects
None yet
Development

No branches or pull requests

2 participants