home-assistant / core

:house_with_garden: Open source home automation that puts local control and privacy first.
https://www.home-assistant.io
Apache License 2.0
72.35k stars 30.28k forks source link

ViCare missing sensor #77799

Closed Kasper027 closed 1 year ago

Kasper027 commented 2 years ago

The problem

I miss some data points in the ViCare integration.

  1. System flow temperature if I read it correctly, it should be the "heating.boiler.sensors.temperature.commonSupply" data point.

  2. Buffer temperature it is named "heating.buffer.sensors.temperature.main" in the documentation or "heating.buffer.sensors.temperature.top".

Both temperature values are displayed in the ViCare app. Is it possible to get them here as well?

I have the Vitoconnect Opto 2 with a heat pump.

Many greetings Kasper027

What version of Home Assistant Core has the issue?

Home Assistant 2022.8.7

What was the last working version of Home Assistant Core?

No response

What type of installation are you running?

Home Assistant OS

Integration causing the issue

ViCare

Link to integration documentation on our website

https://www.home-assistant.io/integrations/vicare

Diagnostics information

No response

Example YAML snippet

No response

Anything in the logs that might be useful for us?

No response

Additional information

No response

probot-home-assistant[bot] commented 2 years ago

Hey there @oischinger, mind taking a look at this issue as it has been labeled with an integration (vicare) you are listed as a code owner for? Thanks! (message by CodeOwnersMention)


vicare documentation vicare source (message by IssueLinks)

oischinger commented 2 years ago

heating.boiler.sensors.temperature.commonSupply is already available as "Boiler Supply Temperature" But it seems like PyVicare offers it only for Gas Boiler types. Can you please create an issue at https://github.com/somm15/PyViCare to also provide it for heatpumps if applicable?

heating.buffer.sensors.temperature.top is definately missing. I'll add it

lukx commented 2 years ago

As a hint: I am using the following three template sensors to have my Buffer and my DHW as sensor entities. Also I am finding the Spread interesting, which I read as an information "how many energy gets absorbed by the house", in laymans terms.

template:
  - sensor:
    - name: Vicare Warmwasser
      unit_of_measurement: "°C"
      state: "{{ state_attr('water_heater.vicare_water', 'current_temperature') }}"
    - name: Vicare Pufferspeicher
      unit_of_measurement: "°C"
      state: "{{ state_attr('climate.vicare_heating', 'current_temperature') }}"
    - name: Vicare Spreizung
      unit_of_measurement: "%"
      state: "{{ ((1 - (states('sensor.vicare_return_temperature')|float)/ (states('sensor.vicare_supply_temperature')|float)) * 100) | round(0) }}"
oischinger commented 2 years ago

too bad that my device doesn't offer the return temperature. that would indeed be interesting data

oischinger commented 2 years ago

I created a PR for the missing sensors.

Kasper027 commented 1 year ago

Hey at all, i have update my System. Now i see some more datapoints. But i dont see the buffer Sensor. When i look in the diagnose-file there is the corrected buffer temp image

How can I also display this as an entity? I just don't know how

Best regards Kasper027

oischinger commented 1 year ago

The PR hasn't been accepted/merged yet. I expect it to be in the next HA release

Kasper027 commented 1 year ago

hey @oischinger, thank you for the info. then I will wait. A slightly different topic, I read something i-wo that the target flow temperature was calculated. But I don't know how or where. Do you have any idea how it could work?

oischinger commented 1 year ago

I only have a gas heater but there it is calculated. I created this template sensor:

  - platform: template
    sensors:
      vicare_heatcurve_target_temperature:
        friendly_name: "Vorlauftemperatur nach Heizkurve"
        unit_of_measurement: "°C"
        device_class: temperature
        value_template: "{{ state_attr('climate.vicare_heating', 'temperature') + state_attr('climate.vicare_heating', 'heating_curve_shift') - state_attr('climate.vicare_heating', 'heating_curve_slope') * (state_attr('climate.vicare_heating', 'outside_temperature') - state_attr('climate.vicare_heating', 'temperature')) * (1.4347 + 0.021 * (state_attr('climate.vicare_heating', 'outside_temperature') - state_attr('climate.vicare_heating', 'temperature')) + 247.9 * 0.000001 * (state_attr('climate.vicare_heating', 'outside_temperature') - state_attr('climate.vicare_heating', 'temperature')) * (state_attr('climate.vicare_heating', 'outside_temperature') - state_attr('climate.vicare_heating', 'temperature'))) }}"

I think I got the math from some forum which in turn referenced some official VIessman manuals

Kasper027 commented 1 year ago

Hey @oischinger, i checked some data points. I found out via "Download diagnostic information" that the missing data point is either "heating.buffer.sensors.temperature.main" or "heating.buffer.sensors.temperature.top". The data in the background is the same. So the data points themselves are there, they are just not output as an entity. If I'm not a good programmer, can I set this somewhere?

oischinger commented 1 year ago

Hi @Kasper027
I have created a PR on the custom component repo: https://github.com/oischinger/ha_vicare/pull/115

Would you mind checking it out and give me feedback? Then I can contribute it to HA

Thanks.

Kasper027 commented 1 year ago

Hey @oischinger looking at the sensor.py I think it should be correct. We should test it like this. Can I test this in advance without updating the system directly? Is there a file where I can use the part?

oischinger commented 1 year ago

Hi @Kasper027 you can just checkout the branch "newsensors" from https://github.com/oischinger/ha_vicare and copy custom_components/vicare to /config/custom_components/vicare to replace the original component with the custom one

Kasper027 commented 1 year ago

Hey @oischinger i can not find this folder. i used the direct integration. in the /config/custom_components folder is only my "auto_backup", "hacs", "nodered" and "ta_cmi". But no vicare. where else can i watch it?

Kasper027 commented 1 year ago

Hey @oischinger and @frenck, I have a question, i cant find the new sensor. It's all already implemented? Sorry for my question. Best regards Julian

frenck commented 1 year ago

@Kasper027 It is staged for the February release. If you like to test them out now, you can join the beta test (see our documentation on how to join the beta).

../Frenck