hass_nibe icon indicating copy to clipboard operation
hass_nibe copied to clipboard

Getting the intergration to show operation modes.

Open frank8the9tank opened this issue 2 years ago • 14 comments

I own a VMM500 and a F2120 with the option for cooling installed. The heating pump basicly works in 3 modes/productions: heating, cooling and hotwater production. I have the integration installed in home assistation and working stable. But i dont see any entity that shown what mode the system is running in. On the VVM500 display the operation mode is shown trough status/icons.

Is there a way to add this to the integration? That it shows in an entitie what mode the system is in?

frank8the9tank avatar Dec 23 '21 07:12 frank8the9tank

The room temperature cöimate entity will show as heating when it's heating and cooling when it's cooling. The water heater entity will be heating when hot water production is active.

elupus avatar Dec 23 '21 13:12 elupus

Hi Elupus

I have created a template sensor based on your advice, sadly i'm doing something wrongs (it always shows as idle)

My template:

        friendly_name: "Nibe heatpump running operation"
        value_template: >-
          {% if is_state('sensor.water_heater.nibe_108376_40014_47387', 'heat_pump' ) %}
            "Hot Water"
          {% elif is_state('sensor.climate.nibe_108376_s1_room', 'heating' ) %}
            "Heating"
          {% elif is_state('sensor.climate.nibe_108376_s1_room', 'cooling' ) %}
            "Cooling"
          {% else %}
            "Idle"
          {% endif %}

It never changes from idle Under development tools it shows the entities as: afbeelding afbeelding heat pump state: afbeelding

i think at least "Hot Water" should be shown as the entity state is: heat_pump for sensor water_heater.nibe_108376_40014_47387

What am i doing wrong?

frank8the9tank avatar Jan 26 '22 07:01 frank8the9tank

heatpump state when the hotwater production is done: afbeelding

frank8the9tank avatar Jan 26 '22 08:01 frank8the9tank

In your first elif you have ’heating’ as value but the state in first screenshot shows ’heat’…

imist avatar Jan 26 '22 09:01 imist

That always shows a heat, (thats the mode its is in (in summer cool) I think the status atribute is the thing that actual represent the heating beeing "ON and OFF"

frank8the9tank avatar Jan 26 '22 09:01 frank8the9tank

I think you should change first elif to: {% elif is_state('sensor.climate.nibe_108376_s1_room', 'heat' ) %} otherwise it will never evaluate to true. Also, the second elif should probably be changed to ‘cool’ in the same way.

imist avatar Jan 26 '22 09:01 imist

Thats not it for what i can see, in the winter its always in heating mode. within this mode it switches the "heating" on and off, while the mode always shows a heat. same for cooling in the summer The actual heat pump switches ON and OFF (at differenct capacities/loads) for heating, cooling, and hot water production, i want to see that in an entity.

frank8the9tank avatar Jan 26 '22 09:01 frank8the9tank

This template worked for me and shows "Heating" when it's not warming water:

{% if is_state('water_heater.nibe_hot_water', 'heat_pump' ) %}
   "Hot Water"
{% elif is_state('climate.nibe_19650_s1_room', 'heat' ) %}
  "Heating"
{% elif is_state('climate.nibe_19650_s1_room', 'cool' ) %}
  "Cooling"
{% else %}
  "Idle"
{% endif %}

Apart from changing the state values from heating/cooling to heat/cool you also need to remove "sensor." that you have prefixed the entities with. These are not regular home assistant sensors, they are from Climate and Water Heater integrations:

https://www.home-assistant.io/integrations/water_heater/ https://www.home-assistant.io/integrations/climate/

Hope this helps to get your template sensor working.

imist avatar Jan 26 '22 10:01 imist

Removing the sensor. part from the water_heater did the trick for the first rule. I can see the value change when i put the code above in the delopment tools -> template. (result is idle or hot water) So that is good. Other strange thing i see is that the entity does not get updated, (so i dont see the same in the front end, it never changes from idle)

For the climate part, this does not work, its the status atribute that changes. Shown above as status: DONE.

So the second and third rule have to look a the atribure for that.

frank8the9tank avatar Jan 26 '22 10:01 frank8the9tank

Yes, unless you change the state values from heating/cooling to heat/cool you'll never get "Heating" or "Cooling", only "Hot Water" or "Idle".

As you say, the template can of course be improved by also looking at various attributes...

imist avatar Jan 26 '22 11:01 imist

Its actual the hvac_action attribute that changes when the heatpump is on or off, It changes from: idle to heating (and idle to cooling in the cool mode) So my if statement rule needs to look for the attribute of the entity.

frank8the9tank avatar Jan 26 '22 12:01 frank8the9tank

Ah, I see now when my Nibe F750 went from waming water to heating! Perhaps some like this then?

{% if is_state('water_heater.nibe_hot_water', 'heat_pump' ) %}
  "Hot Water"
{% elif is_state_attr('climate.nibe_19650_s1_room', 'hvac_action', 'heating' ) %}
  "Heating"
{% elif is_state_attr('climate.nibe_19650_s1_room', 'hvac_action', 'cooling' ) %}
  "Cooling"
{% else %}
  "Idle"
{% endif %}

imist avatar Jan 26 '22 14:01 imist

I have made this:

      nibe_heatpump_operation:
        friendly_name: "Nibe heatpump running operation"
        value_template: >-
          {% if is_state('water_heater.nibe_108376_40014_47387', 'heat_pump' ) %}
            Hot Water
          {% elif is_state_attr('climate.nibe_108376_s1_room','hvac_action', 'heating') %}
            Heating
          {% elif is_state_attr('climate.nibe_108376_s1_room','hvac_action', 'cooling') %}
            Cooling
          {% else %}
            Idle
          {% endif %}

This is working under the template page in development tools. Strange thing that the entity does not get updated in the front panel. (so under development is shows all the states correctly, but in the lovelace gui only idle) why?

frank8the9tank avatar Jan 26 '22 14:01 frank8the9tank

Found it, the configuration file was not saved, above code is working.

frank8the9tank avatar Jan 26 '22 14:01 frank8the9tank