Viessmann Component

I’m currently merging this branch with the latest state of vicare in home assistant core. There was a bigger refactoring on the sensors which slowed things down again.
And even if the config flow branch works for most of you I assume thay the process of contributing to Home Assistant will take some time. Usually the reviews are quite thorough and there’s always something to improve :wink:

I’m sorry that I can’t find enough time to speed this up. If anyone has more time and wants to contribute please let me know.

@oischinger dude, take it easy, your efforts on this are way out there…much appreciated. The current config-flow branch is fine… HA will adopt it sooner or later.

Thanks again for maintaining my most used integration!!

Don’t worry, I’m waiting patiently. Highly appreciate your great work on it so far! I can contribute with testing, if needed, as the coding is way beyond my skills already.

Thanks guys, any feedback is really appreciated. If you see issues on the config flow branch that need to be resolved don’t hesitate to create github issues on https://github.com/oischinger/ha_vicare

With such a big change we should be sure that it works fine for different setups before we contribute it upstream to Home Assistant core

1 Like

Hi, the Integration is great.
Is it possible zu integrate the solar sensors from vicare api?

Hi Tommmil,

I don’t understand why it works now, i did exactly the same thing.

But thanks a lot, now it works

Yes. But first we need to wait for the config_flow to be official. Home-Assistant is not allowing changes to integrations anymore, which don’t support config_flow

1 Like

I’ve just installed the config flow version of the integration and it worked seamlessly! Many thanks for your great work on it! After restart it has imported settings from configuration.yaml (I forgot to delete it before restarting). I have also tried to remove the integration, it has nicely detected it in a minute or two but when trying to set it up with the config flow “Unknown error occurred”. And in the logs I can see:

2021-10-07 09:15:35 ERROR (MainThread) [aiohttp.server] Error handling request
Traceback (most recent call last):
  File "/usr/local/share/homeassistant/lib/python3.8/site-packages/aiohttp/web_protocol.py", line 422, in _handle_request
    resp = await self._request_handler(request)
  File "/usr/local/share/homeassistant/lib/python3.8/site-packages/aiohttp/web_app.py", line 499, in _handle
    resp = await handler(request)
  File "/usr/local/share/homeassistant/lib/python3.8/site-packages/aiohttp/web_middlewares.py", line 119, in impl
    return await handler(request)
  File "/usr/local/share/homeassistant/lib/python3.8/site-packages/homeassistant/components/http/security_filter.py", line 60, in security_filter_middleware
    return await handler(request)
  File "/usr/local/share/homeassistant/lib/python3.8/site-packages/homeassistant/components/http/forwarded.py", line 98, in forwarded_middleware
    return await handler(request)
  File "/usr/local/share/homeassistant/lib/python3.8/site-packages/homeassistant/components/http/request_context.py", line 24, in request_context_middleware
    return await handler(request)
  File "/usr/local/share/homeassistant/lib/python3.8/site-packages/homeassistant/components/http/ban.py", line 78, in ban_middleware
    return await handler(request)
  File "/usr/local/share/homeassistant/lib/python3.8/site-packages/homeassistant/components/http/auth.py", line 144, in auth_middleware
    return await handler(request)
  File "/usr/local/share/homeassistant/lib/python3.8/site-packages/homeassistant/components/http/view.py", line 136, in handle
    result = await result
  File "/usr/local/share/homeassistant/lib/python3.8/site-packages/homeassistant/components/config/config_entries.py", line 157, in post
    return await super().post(request, flow_id)
  File "/usr/local/share/homeassistant/lib/python3.8/site-packages/homeassistant/components/http/data_validator.py", line 62, in wrapper
    result = await method(view, request, *args, **kwargs)
  File "/usr/local/share/homeassistant/lib/python3.8/site-packages/homeassistant/helpers/data_entry_flow.py", line 111, in post
    result = await self._flow_mgr.async_configure(flow_id, data)
  File "/usr/local/share/homeassistant/lib/python3.8/site-packages/homeassistant/data_entry_flow.py", line 198, in async_configure
    result = await self._async_handle_step(flow, cur_step["step_id"], user_input)
  File "/usr/local/share/homeassistant/lib/python3.8/site-packages/homeassistant/data_entry_flow.py", line 256, in _async_handle_step
    result: FlowResult = await getattr(flow, method)(user_input)
  File "/home/homeassistant/homeassistant/custom_components/vicare/config_flow.py", line 59, in async_step_user
    await self.hass.async_add_executor_job(vicare_login, user_input)
  File "/usr/local/lib/python3.8/concurrent/futures/thread.py", line 57, in run
    result = self.fn(*self.args, **self.kwargs)
TypeError: vicare_login() missing 1 required positional argument: 'conf'

I have PyVicare version 2.10.0 installed - this was the requirement in the manifest. Should I try with a different version/branch?

Hi,

Is there any way to make the HA also show electricity and gas consumption?
The ViCare smartphone application displays this data.

Very soon

3 Likes

There’s a PR which supports the energy consumption dashboard for Gas Boilers.
It should now also differentiate between cubic metres and kWh. Before that change some users data was actually in cubic metres but Home Assistant showed it as kWh.
I couldn’t really test it yet since the API delivers kWh for me. So anyone who is interested to test please head to:

1 Like

I would like to test for you, but I’m on config-flow branch…would this potentially break things ?

1 Like

I need to split my PR into multiple smaller ones to contribute it back to Home Assistant. Since this will take more time I decided to merge config-flow branch to master on the custom component repository.

So the energy_support branch is based on the config flow changes. You should be fine switching to it

1 Like


Is there anything specific you need checking out ?

Looks good. Can you confirm that the unit (m³) and the values match what you see on the Vicare app?

Thanks for the feedback!

image

image

Pretty similar I’d say.

1 Like

Hello, I have a problem with entities visibility.
I’ve added oischinger custom component but the integration detects only five entities:

My gas heater is Vitodens 100, I choose gas heating type, but I don’t have entities about gas and energy consumption and many more.
When I’ve been trying to use official HA integration these entities were marked as unavaible.

In the log there are entries about feature not supported, but I have this data in ViCare app:

2021-10-16 19:45:52 DEBUG (MainThread) [custom_components.vicare.sensor] Found device ViCare Outside Temperature
2021-10-16 19:45:52 INFO (MainThread) [custom_components.vicare.sensor] Feature not supported ViCare Outside Temperature
2021-10-16 19:45:52 DEBUG (MainThread) [custom_components.vicare.sensor] Found device ViCare Return Temperature
2021-10-16 19:45:52 INFO (MainThread) [custom_components.vicare.sensor] Feature not supported ViCare Return Temperature
2021-10-16 19:45:52 DEBUG (MainThread) [custom_components.vicare.sensor] Found device ViCare Boiler Temperature
2021-10-16 19:45:52 INFO (MainThread) [custom_components.vicare.sensor] Feature not supported ViCare Boiler Temperature
2021-10-16 19:45:52 DEBUG (MainThread) [custom_components.vicare.sensor] Found device ViCare Hot water gas consumption today
2021-10-16 19:45:52 INFO (MainThread) [custom_components.vicare.sensor] Feature not supported ViCare Hot water gas consumption today
2021-10-16 19:45:52 DEBUG (MainThread) [custom_components.vicare.sensor] Found device ViCare Hot water gas consumption this week
2021-10-16 19:45:52 INFO (MainThread) [custom_components.vicare.sensor] Feature not supported ViCare Hot water gas consumption this week
2021-10-16 19:45:52 DEBUG (MainThread) [custom_components.vicare.sensor] Found device ViCare Hot water gas consumption this month
2021-10-16 19:45:52 INFO (MainThread) [custom_components.vicare.sensor] Feature not supported ViCare Hot water gas consumption this month
2021-10-16 19:45:52 DEBUG (MainThread) [custom_components.vicare.sensor] Found device ViCare Hot water gas consumption this year
2021-10-16 19:45:52 INFO (MainThread) [custom_components.vicare.sensor] Feature not supported ViCare Hot water gas consumption this year
2021-10-16 19:45:52 DEBUG (MainThread) [custom_components.vicare.sensor] Found device ViCare Heating gas consumption today
2021-10-16 19:45:52 INFO (MainThread) [custom_components.vicare.sensor] Feature not supported ViCare Heating gas consumption today
2021-10-16 19:45:52 DEBUG (MainThread) [custom_components.vicare.sensor] Found device ViCare Heating gas consumption this week
2021-10-16 19:45:52 INFO (MainThread) [custom_components.vicare.sensor] Feature not supported ViCare Heating gas consumption this week
2021-10-16 19:45:52 DEBUG (MainThread) [custom_components.vicare.sensor] Found device ViCare Heating gas consumption this month
2021-10-16 19:45:52 INFO (MainThread) [custom_components.vicare.sensor] Feature not supported ViCare Heating gas consumption this month
2021-10-16 19:45:52 DEBUG (MainThread) [custom_components.vicare.sensor] Found device ViCare Heating gas consumption this year
2021-10-16 19:45:52 INFO (MainThread) [custom_components.vicare.sensor] Feature not supported ViCare Heating gas consumption this year
2021-10-16 19:45:52 DEBUG (MainThread) [custom_components.vicare.sensor] Found device ViCare Power production current
2021-10-16 19:45:52 DEBUG (MainThread) [custom_components.vicare.sensor] Attribute Error ViCare Power production current
2021-10-16 19:45:52 DEBUG (MainThread) [custom_components.vicare.sensor] Found device ViCare Power production today
2021-10-16 19:45:52 DEBUG (MainThread) [custom_components.vicare.sensor] Attribute Error ViCare Power production today
2021-10-16 19:45:52 DEBUG (MainThread) [custom_components.vicare.sensor] Found device ViCare Power production this week
2021-10-16 19:45:52 DEBUG (MainThread) [custom_components.vicare.sensor] Attribute Error ViCare Power production this week
2021-10-16 19:45:52 DEBUG (MainThread) [custom_components.vicare.sensor] Found device ViCare Power production this month
2021-10-16 19:45:52 DEBUG (MainThread) [custom_components.vicare.sensor] Attribute Error ViCare Power production this month
2021-10-16 19:45:52 DEBUG (MainThread) [custom_components.vicare.sensor] Found device ViCare Power production this year
2021-10-16 19:45:52 DEBUG (MainThread) [custom_components.vicare.sensor] Attribute Error ViCare Power production this year
2021-10-16 19:45:52 DEBUG (MainThread) [custom_components.vicare.sensor] Found device ViCare Supply Temperature
2021-10-16 19:45:52 DEBUG (MainThread) [custom_components.vicare.sensor] Found entity ViCare Supply Temperature
2021-10-16 19:45:52 DEBUG (MainThread) [custom_components.vicare.sensor] Found device ViCare Burner Starts
2021-10-16 19:45:52 INFO (MainThread) [custom_components.vicare.sensor] Feature not supported ViCare Burner Starts
2021-10-16 19:45:52 DEBUG (MainThread) [custom_components.vicare.sensor] Found device ViCare Burner Hours
2021-10-16 19:45:52 INFO (MainThread) [custom_components.vicare.sensor] Feature not supported ViCare Burner Hours
2021-10-16 19:45:52 DEBUG (MainThread) [custom_components.vicare.sensor] Found device ViCare Burner Modulation
2021-10-16 19:45:52 DEBUG (MainThread) [custom_components.vicare.sensor] Found entity ViCare Burner Modulation```

Hey @elenril
it looks like the data is just not provided by Viessmann. Unfortunately not all data you can see in the app is also available via their new API.
I suggest to dump the data for your device as described here:

It will also help future development to provide that data to the project: https://github.com/somm15/PyViCare/tree/master/tests/response

I have the same problem. I still had the official version of vicare. Today I updated HA to a new version and the binary burner sensor disappeared. So I tried to use the github version and suddenly almost everything disappeared and only 5 sensors remained. After deleting the custom_components again, the sensors came on but a total of 3 is missing. It seems that Viessmann is throwing sticks under his feet :frowning: