Open yuliwilliam opened 5 months ago
I thought I filtered those out. Maybe it was a different sensor. Should be an easy fix.
this seems to happen every time the thermostat restarted.
in your sensor.py file, try modifying async_update like this and let me know if that works:
async def async_update(self):
"""Get the latest state of the sensor."""
await self.data._async_update_data()
sensors = self.data.daikinskyport.get_sensors(self._index)
for sensor in sensors:
if sensor["type"] == self._type and self._sensor_name == sensor["name"]:
if not sensor["value"] == 65535 and not sensor["value"] == 655350:
self._state = sensor["value"]
Thanks! I was away for a bit, let me find some time to test it out.
looks like you guys already have a handle on it but figured I mentioned I'm seeing the issue as well.
Try the fix I posted and let me know if it works. I don't have the sensors since my unit doesn't track power.
async def async_update(self): """Get the latest state of the sensor.""" await self.data._async_update_data() sensors = self.data.daikinskyport.get_sensors(self._index) for sensor in sensors: if sensor["type"] == self._type and self._sensor_name == sensor["name"]: if not sensor["value"] == 65535 and not sensor["value"] == 655350: self._state = sensor["value"]
I've experienced some additional "infinite" values for certain sensors. I've been running with this commit in my fork for quite a while:
# Manage values that indidcate a comms failure to the hardware.
# Correct these values to something that doesn't skew the
# graphs so badly.
if (sensor["type"] in ("actual_status", "demand",
"frequency_percent")
and sensor["value"] == 127.5):
self._state = None
elif (sensor["type"] in ("power", "rpm")
and sensor["value"] == 65535):
self._state = None
elif sensor["type"] == "temperature" and sensor["value"] == 255:
self._state = None
else:
self._state = sensor["value"]
Is this still an issue?
Is this still an issue?
Would you consider the code I shared so that overflows in other sensors are caught as well?
The indoor and outdoor power sensors occasionally report the values
65535
and655350
, which correspond to2^16
. These incorrect values are consistently received simultaneously from both sensors while my unit is operating. I suspect this issue is due to an overflow in the API.