core icon indicating copy to clipboard operation
core copied to clipboard

Home Assistant / API doesn't get data from Viessmann hybrid system

Open Mnovu opened this issue 2 years ago • 16 comments

The problem

Hello,

I have connected Home Assistant and my Viessmann hybrid system (Vitocal (heating pump) and Vitodens (gas)) via Viessmann API.

In HomeAssistant, however, only Vitodens is recognized, even if I enter "hybrid" or "heatpump". But I need both devices or if only one works, I would need the heat pump.

Overall goal: I as house owner want to use my pv energy to heat up the water in the puffer/water tank.

What am I doing wrong? Or does the API not pass the data?
Thanks for feedback 🙂

P.S. I created a ticket at the Viessmann dev portal too (german only) https://www.viessmann-community.com/t5/Feedback-API/Home-Assistant-API-erkennt-Hybrid-System-bzw-Waermepumpe-nicht/m-p/376282#M241

What version of Home Assistant Core has the issue?

core-2023.10.5

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

home-assistant_vicare_2023-10-29T14-27-24.169Z.log

Example YAML snippet

No response

Anything in the logs that might be useful for us?

No response

Additional information

No response

Mnovu avatar Oct 29 '23 14:10 Mnovu

The integration currently supports only one device (the first one).

https://github.com/home-assistant/core/blob/b323295aa15ff6ac81e46b213a2f22440f0460de/homeassistant/components/vicare/init.py#L85-L87

I have prepared a PR to enable all devices that are reachable by the used PyViCare library. I run this myself with two * Vitodens* via two VitoConnects.

I would be really interested if this also works for your!

CFenner avatar Oct 29 '23 19:10 CFenner

hey @CFenner thanks for that! Could have looked into the code as well, just didn't think about it :(

Since I am pretty fresh to the show (just started yesterday with HA): How can I test this? Is there an option to enable PRs on the running integration (e.g. enable test versions?). Or any other way?

Mnovu avatar Oct 30 '23 07:10 Mnovu

So you can simply download PR code and copy the folder vicare from homeassistant/components to config/custom_components/ on your instance.

@joostlek you mentions some script to try out PRs, can you share that?

CFenner avatar Oct 30 '23 08:10 CFenner

cd /config
curl -o- -L https://gist.githubusercontent.com/bdraco/43f8043cb04b9838383fd71353e99b18/raw/core_integration_pr | bash /dev/stdin -d vicare -p 96044

After -d comes the domain and after -p comes the pull request id

joostlek avatar Oct 30 '23 08:10 joostlek

@CFenner ok, thanks. Will try that and share feedback. This week is quite busy.

Mnovu avatar Oct 30 '23 09:10 Mnovu

Moved testing results over to https://github.com/home-assistant/core/pull/96044#issuecomment-1785759049

Mnovu avatar Oct 30 '23 17:10 Mnovu

In the api description heat pumps are listed under the paid api plan. Are you aware of this?

CFenner avatar Oct 30 '23 19:10 CFenner

No, see picture. But it’s hidden :D IMG_0310

Mnovu avatar Oct 30 '23 20:10 Mnovu

@CFenner - thanks a lot for your contribution, i just implemented it in my HA setup as i will extend my current heating system (gaz boiler) with a heatpump in 2 weeks. I also recommend to decrease the nb of api calls by implementing 2 automation (1 at night with 30min delay, and one for daytime with 2 or 3 min interval). i can share the script i use ;-). dont forget to disable the poll feature in the vicare integration

niouniou49 avatar Dec 26 '23 08:12 niouniou49

@CFenner when HA will have new releases update, will your changes stay or do i need to manually implement them again?

niouniou49 avatar Dec 26 '23 08:12 niouniou49

If you copied the PR content to your custom components folder, it will stay.

CFenner avatar Dec 26 '23 10:12 CFenner

you mean the vicare folder should be in custom components folder?

niouniou49 avatar Dec 26 '23 12:12 niouniou49

Yes, simply use this script. It will do the rest for you.

https://github.com/home-assistant/core/issues/103009#issuecomment-1784679898

CFenner avatar Dec 26 '23 12:12 CFenner

i just run your command 'cd /config curl -o- -L https://gist.githubusercontent.com/bdraco/43f8043cb04b9838383fd71353e99b18/raw/core_integration_pr | bash /dev/stdin -d vicare -p 96044 without changing anything

niouniou49 avatar Dec 26 '23 12:12 niouniou49

ok so all good, i guess ;-)

niouniou49 avatar Dec 26 '23 12:12 niouniou49

everything is working for me too. I have a lot of viessman device (heat pump, gas heater, inverter and photovoltaic and water solar heater). With 2024.1 update and this PRoject now i can use the supported devices

@CFenner if you need some report/log ask me

l2jalbe avatar Jan 28 '24 08:01 l2jalbe

Hello,

I am an absolute beginner. I would also like to read out several devices. What do I need to download and how can I insert it step by step, and of course where? Maybe someone has the desire and time to explain this to me?

Thank you!

TimHeu avatar Feb 13 '24 16:02 TimHeu