georgezhao2010 / midea_ac_lan

Auto-configure and then control your Midea M-Smart devices (Air conditioner, Fan, Water heater, Washer, etc) via local area network.
MIT License
1.42k stars 233 forks source link

Heat Pump Water Heater RSJRAC01 bugs #404

Open Punisher01 opened 11 months ago

Punisher01 commented 11 months ago

HA core version

2023.12.1

Intergration version

0.3.22

Device type and model

Heat Pump Water Heater RSJRAC01 (0) from Midea

Used App

Comfort Home

The description of problem

The device appears on and off constantly and it shows incorrect temperatures: For example 12 degrees instead of 55 Celsius

The logs

home-assistant_midea_ac_lan_2023-12-10T20-00-32.535Z.log

tomvo commented 7 months ago

Same problem here, did you find a solution? Any pointers from the dev team on where to look and try to fix this?

tomvo commented 7 months ago

I managed to fix this bug without any knowledge of the internal workings of this plugin but maybe the developers can fix it easily from here. It seems that the additional subtraction and division that is going on here is not necessary: https://github.com/georgezhao2010/midea_ac_lan/blob/master/custom_components/midea_ac_lan/midea/devices/cd/message.py#L69

By setting the values likes so the properties actually seem to be correct:

self.target_temperature = body[3]
self.current_temperature = body[4]
self.max_temperature = body[10]
self.min_temperature = body[11]
image