Closed tmds closed 1 year ago
Hi tom, It is possible that it is not yet implemented. My installation doesn't have the energy sensors, so I didn't have anything to test with.
I verified my installation includes the changes from https://github.com/openmotics/home-assistant/pull/13, so I think the sensors should show up.
It does not support it using the cloud setup but feel free to implement it :)
I tried switching to local
mode. The integration tab shows Retrying setup: 127
.
The log file has a stacktrace:
2022-10-14 13:13:25.430 ERROR (MainThread) [custom_components.openmotics.coordinator] Unexpected error fetching Localgw_192.168.1.106 data: 127
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 205, in _async_refresh
self.data = await self._async_update_data()
File "/config/custom_components/openmotics/coordinator.py", line 53, in _async_update_data
my_outputs = await self._omclient.outputs.get_all()
File "/config/deps/lib/python3.10/site-packages/pyhaopenmotics/openmoticsgw/outputs.py", line 71, in get_all
outputs = [Output.from_dict(device) for device in data]
File "/config/deps/lib/python3.10/site-packages/pyhaopenmotics/openmoticsgw/outputs.py", line 71, in <listcomp>
outputs = [Output.from_dict(device) for device in data]
File "/config/deps/lib/python3.10/site-packages/pyhaopenmotics/openmoticsgw/models/output.py", line 86, in from_dict
output_type = OPENMOTICS_OUTPUT_TYPE_TO_NAME[data.get("type", 0)]
KeyError: 127
I've added 127: "UNKNOWN",
to OPENMOTICS_OUTPUT_TYPE_TO_NAME
and it's up and running now! Including energy sensors!
With the change to local
mode, all temperature sensors and humidity sensors are reporting 0
.
Maybe pyhaopenmotics
doesn't support those in local
mode?
I don't have a use-case for those sensors, so I don't mind them not working for now. When I do, I'll take a closer look.
I've just installed home assistant with the openmotics integration. This went really smooth. Nice job!
The energy sensors are not showing up.
When I use the
cloud.openmotics.com
site, I see this:get_power_modules
returns:get_realtime_power
returns:@kneirinck @woutercoppens do you have an idea why this isn't working, or some advice on how to debug this?