It seems like this script would be the perfect solution.
I could test this, but have no clue about Python.
Except
Viessmann2MQTT.py A script to be run on e.g. a Raspberry Pi with Optolink. It polls a list of events (look at the source code - they need to be adopted to your heating unit!) and sends them via MQTT.
I found no further explanation.
That means I would need a manual first (installation and first steps for home-assistant) .
I already had Vitosoft and Viessdata v2.06 running over Optolink without any problems.
My system is a Vitodens 300-W B3HB-26 and uses the 300 protocol according to Viessdata or voIdent v1.5.
Nevertheless if you want to send/write and having making use of existing configurations/developments using vcontrold as a gateway and MQTT would be nice.
Example for reading and publishing measurements:
short update form my side - the custom addon works perfectly for getting and setting values in Viessmann devices: GitHub - Alexandre-io/homeassistant-vcontrol: Vcontrold Home Assistant add-on repository
Good this is that it is based on openv/vcontrol so there is still some work/developments going on and you can contribute some settings from your device to that project.
There are some configuration examples for HA in the issues part - works pretty nice out of the box:
but how can you use it if Home Assistant is running on a server (Proxmox) and vcontrold is installed on a Raspberry, which is connected to the heater in the boiler room and is only accessible via WLAN. I can currently only access it via ssh and then query the values there.
The addon only works if the adapter is connected directly via USB to the computer on which Home Assistant is running. Or am I wrong here?
This will be the case for most USERS.
In HA, a device with sensors and switches can be created directly via MQTT.
How hard is it to create a Python script that runs directly on the Raspberry on which vcontrold is installed and there every few seconds sends all data to the HA MQTT server, and certain values (operating mode, set temperature, etc.) queried and then set again by vcontrold.
Of course, you could also go via NodeRed, but the way listed above would be perfect, but unfortunately my Python knowledge is not sufficient here.
good question. That is one thing I had in mind for a PR As a temporary workaround you could use some socat or ser2net-based approach, but basically you only need to change 2 config settings for vclient and add some config to the container.
Currently the add-on is running vcontrold and vclient in the same container so you need to have the optolink cable connected to the HA instance. It will pass though the ttyUSB and ttyACM devices to the container.
I’d like to add a “connect to remote” flag with a setting for Optolink/vcontrold host/port so you can deactivate the local vcontrold and connect to a remote server. I already created a branch in my form (GitHub - Schm1tz1/homeassistant-vcontrol at remote-vcontrold) and will have a look later tonight.
For the second part: Polling vcontrold can be done with vclient. The add-on does the same internally. You could just take the configs/template and use it for that purpose on your RPi but better to add that feature to the add-on. I did that for the last 5 years using vclient as a cron job but honestly from an operational perspective it’s better to use the add-on. You get alerten on errors and the watchog will restart if it fails. I think this is a feature that can be integrated in a few days.
I will now test everything a few days and then here for my heater Viessmann V200KW1 ID=2094 protocol:KW the Vito.xml and vcontrold.xml are available here, as well as the configruation for all sensors, etc…
I have made a few adjustments to the config.yaml, here is a list with all the points that are queried for my heater. Whether the set works I must still test.
very nice, happy to see that it works for you !
Concerning the set-commands some seem to be not correct for my device but that is probably related to openv and/or the vito.xml (e.g. set for party mode not working with my device but working for Björn who did the example you are referring to). One way to get some more commands would be by installing the Viessmann tool and extracting the xml files as described here so one can add them to vito.xml.
I will have a look at the Viessmann tool. With the set commands I do not get along also yet.
What I would actually wish (wish):
It takes a long time until all values are queried. It would be great if the query of the commands were divided into, for example, three areas, of which you can set the interval for the query for each. In the respective area you then put the commands that should be queried with the interval for this area.
A device is created via MQTT that then contains all sensors and switches. Here I still have to read up on how this works manually. Currently, the sensors are only in the entities.
I saw a video on Twitch at the beginning of last year, where a programmer started to program what runs directly on the Raspberry on the Vcontrold. That has all the get Commandos then sent directly to the MQTT server of HA and there was created a device with all the sensors, switches, etc… (the same way I would like to see the MQTT device created with the commands contained in the Vito.xml).
I have written to the programmer, but unfortunately I have received as an answer only that he makes it only for himself.
@NightWatcher - very nice!
Having the same issues with the zero values which are returned when actual NULL values were returned from vcontrold. I remember I had that issue some years ago when writing my openHAB scripts for that job - by that time I checked for numeric values: openHAB Scripts to get vcontrold values and push via REST API · GitHub
That would be something worth integrating and testing - but as far as I remember that doesn’t work with the templates in vclient
Hey! Thanks for your great work! I have now also set up the addon Vcontrol in Home Assistant! I adjusted a few values in the configuration, but unfortunately he doesn’t set the burner value/circulation pump to off at all, they’re just always on! it also reacts very slowly, sometimes it takes 10 minutes for a value to be changed. sometimes you have to change the value more often before it is accepted. my controller is a V 200 KW4 (from 2005) (I took the id 2094) <— VitoOpen Identifikation. do you have an idea what that could be? Thanks in advance!
thx for your PR to use a remote host. I also have Raspberry Pi Zero for my vcontrold service. When I try your PR, I am able to set the remote settings (host, port). But in the logs it looks like it will be using the main image without your PR. How can I use the add-on with your PR? Thx
Hi,
that the image pull policy. You need to force him to re-create the image as I cannot override the existing image in the registry but would like to keep the configuration in a consistent state for the original author.
That’s what you need to do: