krahabb / meross_lan

Home Assistant integration for Meross devices
MIT License
416 stars 45 forks source link

Different icons (compared to Meross-HomeAssistant) for TRVs #48

Closed almico closed 3 years ago

almico commented 3 years ago

Version of the custom_component

2.1.0

Describe the bug

image The image above shows what I see about the very same Meross TRV. On the left is the TRV reported by Meross-HomeAssistant integration and on the right is the TRV reported by Meross-LAN. Let me know if I can help, or if there nothing to do 😄

krahabb commented 3 years ago

Yeah.. There are so many things to say about HA climate and about Meross TRV too ;)

They both present 'peculiarities' which in the end are hard to match. I mean:

the HA climate is very very generic (too much maybe?) so you have heat modes like HEAT - COOL - FAN - DRY and then you'll have 'presets' which are more or less the same but maybe could carry some very specific settings for the underlying device (eco-mode is the best candidate here or 'party mode' for traditional heaters).

Then the MTS100 has its own 'ontology'. If you see it in the Meross App you'll have 'Heat - Cool - Away' mode or even 'Auto' which stands for 'schedule'. Of course, 'Cool' mode in Meross is not really 'Cool' it is just a different set-point for the temperature (maybe) lower than 'Heat' (or 'Comfort' I don't remember). Forgive me about the 'confusion' in terms but I don't have the MTS available anymore in the App and I remember the App UI reported different names than the protocol message labels so it is a total mess (Like in the App you have 'Night' mode while in the protocol api you have 'economy' as the label which will report the Night mode temperature preset)

So, in the end, the meross device has these (5) modes: custom: target temperature is what you set Heat/Comfort: target temperature is the 'Comfort temperature' preset (which you can easily edit anyway) Cool/Sleep: same as Heat except the preset might be different Economy/Away: same as Heat except the preset might be really low to just prevent the house from freezing Auto/Schedule: target temperature can be programmed to vary along the day or the week whatever you prefer The first being totally manual The second third fourth are just 'shortcuts' to predefined targets but still it is manual The fifth varies the target over a time schedule

Then you'll have the valve switched off which I represented as 6th 'operational mode' for the device.

Now to the point: The left (Meross-HA) is wrong when it shows you the 'Cool' icon (between 'Heat' and 'Off') since that's an HVAC mode in HA terms and it should mean: 'Hey I'm cooling this down!'. Now the Meross App UI is to blame when it reports the term 'Cool' (or not?) since it's not really cooling. It's just a valve: it either heats or stand-by. Ok ok it works anyway: you set HVAC mode to 'Cool' in HA and the Meross valve sets its target temperature to a 'cool' preset but it's wrong in design terms (in my opinion) So Meross-LAN doesn't give you the option to set any HVAC mode different from AUTO-HEAT-OFF where these HA HVAC modes are 'mapped' to Meross Valve 'modes' this way: AUTO -> Meross schedule/auto HEAT -> Meross 'Custom' (Manual preset) OFF -> Valve switched off HA then gives you the option to not set an HVAC mode but to set a 'preset mode'. If you use this way you'll find all the 5 Meross modes + Off. Of course, when you set any of these preset modes I'll try to 'back-map' to HA HVAC modes and this is the mapping: Custom -> HEAT Heat/Comfort -> HEAT Cool/Sleep -> HEAT Away/Economy -> HEAT Auto/Schedule -> AUTO Off -> Off

Also to note: in App you can set the 3 different targets for Heat/Cool/Away which will be recalled when you use meross_lan to call a preset. This is in my opinion intuitive and correct. So to use HA exactly as the App. Bear in mind anyway that if you set the valve in any of these presets, when you change the target temperature in HA meross_lan will modify the current target temperature but also the preset so, if you're in Heat/Comfort mode and change the temperature in HA, the valve will stay in Heat/Comfort and the temperature preset (check it in App after changing form HA) for Heat/Comfort will change. This is different from the app behaviour: when you set the mode and then change the temperature in the main UI, the valve will switch to 'custom'

As for why the left reports 'Off - CUSTOM' in the central pane while meross_lan reports 'Off - off' this is subtle: When you switch off the valve it is definitely 'off' but still retains its own 'mode' so when you switch it on again yo'll be where you left (this is expecially true when you manage the hardware buttons) so the left panel is sligthly more correct then the right one. In meross_lan I've decided to hide this state since there's no switch on/off in HA terms: you just change 'HVAC' mode or 'preset' mode to something. Of course, it could be reasonable, when you eventually set HVAC mode back from 'Off' to 'HEAT' to return to the 'preset' it was before while it actually turns always to 'custom' mode.

But in the end, inside HA, all of these 'modes' and 'schedules' are just confusing since you would likely just use the 'custom' mode and use HA automations to schedule or set any target temperature based on whatever you like.

Like I said, and while explaining this I've contributed it a lot: it's a total mess!

almico commented 3 years ago

About

It's just a valve: it either heats or stand-by

I have the previous version of this thing. I was forced to purchase it, because the home builder wasn't the... smartest (interesting analogy with the name of the thermostat 😆), and used redundant (read: "useless additional") devices. I didn't want to risk anything, thus I bought that good-looking, expensive, difficult to integrate, working-ugly controller. But the key point is that I struggled to figure out what was going to happen to the signals on the cabling when I switched from "heating" to "cooling". Now... 150 euros later... I finally understood that the only difference is that a ">" becomes a "<" in the code where the thermostat decides whether it has to open or close the valve 😆. It is somewhere else that, in my house, another valve lets hot or cold water flow through the pipes 😄