core
core copied to clipboard
Add cooling consumption and cooling temperatures
The problem
Hello, as it's finally summer, I am using my heat pump for cooling, but there is not value for the energy consumption for cooling. Can we add this?
Currently, there is:
- Overall consumption
- Heating consumption
- hot water consumption
Cooling consumption is measured and included in "Overall consumption", but not in heating. That leads me to the assumption that there should be an attribute for "Cooling Consumption" in the API.
What version of Home Assistant Core has the issue?
2024.6.3
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
Viessmann 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
Hey there @cfenner, 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!
Code owner commands
Code owners of vicare can trigger bot actions by commenting:
@home-assistant closeCloses the issue.@home-assistant rename Awesome new titleRenames the issue.@home-assistant reopenReopen the issue.@home-assistant unassign vicareRemoves the current integration label and assignees on the issue, add the integration domain after the command.@home-assistant add-label needs-more-informationAdd a label (needs-more-information, problem in dependency, problem in custom component) to the issue.@home-assistant remove-label needs-more-informationRemove a label (needs-more-information, problem in dependency, problem in custom component) on the issue.
(message by CodeOwnersMention)
vicare documentation vicare source (message by IssueLinks)
You can check if the data point is in the api response in the diagnostic information yourself. I would assume that heating actually means climate and there is no dedicated cool. At least I did not noticed such in the past in heat pump api dumps.
What is the ViCare app telling your about this?
I would assume that heating actually means climate and there is no dedicated cool. I would not assume that as the energy used for cooling is not included but shows up in "Overall consumption"
App supports that assumption
API has:
https://api.viessmann.com/iot/v1/features/installations/#######/gateways/################/devices/0/features/heating.circuits.0.operating.modes.active where it states that the active mode is cooling (is not reflected in the "heat pump thermostat"
https://api.viessmann.com/iot/v1/features/installations/#######/gateways/################/devices/0/features/heating.circuits.0.operating.programs.comfortCooling/commands/setTemperature is an example where the temperatures for cooling are set (this is the same as in heating mode, but for cooling)
https://api.viessmann.com/iot/v1/features/installations/#######/gateways/################/devices/0/features/heating.power.consumption.cooling
is the consumption
Can we include these things? For reference I attached the Diag Info while cooling activated.
Great that there is an API endpoint. Unfortunately, this is not exposed in the library: https://github.com/somm15/PyViCare/blob/master/PyViCare/PyViCareHeatPump.py
And usually changes to the library are not merged in a reasonable about of time 😭.
Can we do something about it? I mean it looks to me there are several attributes that should be revamped and connected with the thermostat or somehow be included in the integration. See the other issue I mage for the programs/modes settings
This endpoints would be great. Thanks for starting!
Can we do something about it?
I tried to make some noise: https://github.com/somm15/PyViCare/pull/362#issuecomment-2192616183 https://discord.com/channels/864891057345921024/864891691538055178/1249731903989481572
But no response till now...
Can we do something? It says some checks are failing....
@x4N70pHyLL @SpaceRichard please have a look at https://github.com/home-assistant/core/pull/127267 and https://github.com/home-assistant/core/pull/127274 and test. This exposes number entities to set the target temp for cooling programs and makes cooling consumption available.
@x4N70pHyLL @SpaceRichard would you have time to have a look?
Sure, I would need some hints how to do so... I assume to put the to files the you changed in my HA directory and restart? Or do I have to change to the dev branch first?
@x4N70pHyLL yes, there is a script that does that really easy!
https://gist.github.com/bdraco/43f8043cb04b9838383fd71353e99b18
Just run that in your HA terminal
curl -o- -L https://gist.githubusercontent.com/bdraco/43f8043cb04b9838383fd71353e99b18/raw/core_integration_pr | bash /dev/stdin -d vicare -p 127274
Would like to test, but get the error when I try the command:
OS Version: Home Assistant OS 13.2
Home Assistant Core: 2024.10.2
Home Assistant URL: http://homeassistant.local:8123
Observer URL: http://homeassistant.local:4357
➜ ~ curl -o- -L https://gist.githubusercontent.com/bdraco/43f8043cb04b9838383fd71353e99b18/raw/core_integration_pr | bash /dev/stdin -d vicare -p 127274
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 2593 100 2593 0 0 9183 0 --:--:-- --:--:-- --:--:-- 9227
INFO: Current dir is /root
ERROR: Not a Home Assistant folder!
INFO: Cleaning up
Change to config directory
are you in the HA terminal add-on terminal?
Yes, I'm in the Add-On Terminal
Change to
configdirectory
Sorry for the long response time.
So I did the change and now see the following:
- Integration switched to English (was German)
- Entities for heating target temperatures are weirdly named: Wärmepumpe [%key:component::vicare::entity::number::comfort_temperature::name%]
- Besides that, I do not see any new / changed entities in the integration - hysteresis for DHW came already with 2024-10 I think.
@CFenner Please advise.
Another question: How to roll back correctly? I am running in container, but to run the terminal command was not an issue via the container management. I do see vicare integration as custom component now.
Are you testing https://github.com/home-assistant/core/pull/127274 now?
Integration switched to English (was German)
It's using the code as is without translations. German text will be available once in the release.
To use the bundled version of vicare, simple delete the custom_component/vicare folder.
Are you testing #127274 now?
Yes
Are you testing #127274 now?
Yes
Then you should see 3 new sensors Cooling energy consumption ....
Edit: oh, the dependency is not up to date..
I updated the branch, it should now be correct. Please run the script again.
Looks good so far:
-
I do have the 3 entities
-
2 of them (monthly and yearly) are by standard deactivated. After activating them, they seem to be plausible
I would propose to either deactivate the consumption for heating and DWH as well by default or activate all 3 cooling consumptions by default as well to be consistent.
-
I still have the weird naming for target heating temperatures, should I just ignore this?
Not sure what I do wrong, but I still miss this Entities (have 30 before and now)
👍
I still have the weird naming for target heating temperatures, should I just ignore this?
Yes
@SpaceRichard I just updated the PR code, did you execute the script again?
@SpaceRichard I just updated the PR code, did you execute the script again?
Yes, and restarted HA and refresh it
Can you share your diagnostic file?
https://github.com/home-assistant/core/pull/127267 also seemed plausible, temperatures are shown and match to what is shown in the ViCare iOS App. Well done :-) I did revert the changes by deleting the custom component, anything else I have to do for cleanup? There are some tmp/backup files created during installation
Ok, then let's get this reviewed for the Nov release!
I did revert the changes by deleting the custom component, anything else I have to do for cleanup?
No, that's all that I know of.