Viessmann Vitotrol2MQTT (Vitotrol/Vitodata100)

Hi all,

for those who want to integrate a Vitotrol (Vitodata100) controlled Viessmann system with Home Assistant, this might be something.

I’ve created a MQTT bridge between vitotrol and a MQTT broker. This way it can easily be integrated in Home Assistant using MQTT sensors and switches or MQTT climate.

For example:

switch:
  - platform: mqtt 
    name: "Vitovalor - Energy Saving Mode"  
    state_topic: "vitotrol2mqtt/Vitovalor 300-P/EnergySavingMode" 
    command_topic: "vitotrol2mqtt/Vitovalor 300-P/EnergySavingMode/set" 
    payload_on: "1" 
    payload_off: "0"
sensor:
  - platform: mqtt
    state_topic: "vitotrol2mqtt/Vitovalor 300-P/IndoorTemp"
    name: "Vitovalor - Indoor Temperature"
    unit_of_measurement: "°C" 
climate:
  - platform: mqtt
    name: Living
    current_temperature_topic: vitotrol2mqtt/Vitovalor 300-P/IndoorTemp
    temperature_state_topic: vitotrol2mqtt/Vitovalor 300-P/HeatNormalTemp
    temperature_command_topic: vitotrol2mqtt/Vitovalor 300-P/HeatNormalTemp/set
    temperature_command_template: "{{ value | int}}"
    precision: 1.0
    modes:
      - heat
      - 'off'
    mode_state_topic: vitotrol2mqtt/Vitovalor 300-P/OperatingModeRequested
    mode_state_template: >-
      {% set values = { '1':'off', '2':'heat'} %}
      {{ values[value.lower()] if value.lower() in values.keys() else 'off' }}
    mode_command_topic: vitotrol2mqtt/Vitovalor 300-P/OperatingModeRequested/set    mode_command_template: >-
      {% set values = { 'off':1, 'heat':2} %}
      {{ values[value.lower()] if value.lower() in values.keys() else 1 }}
    temperature_unit: C

Lots of credits go to maxatome, the creator of the library and the vitotrol2influxdb tool, which the vitotrol2mqtt tool is based on!

Have fun with it if you want, all feedback is welcome!

Note: The Vitotrol API is not fast, so there is some delay on the switch toggle action and the actual state change.

regards
Ben

Hi !
How to install vitotrol2mqtt on Hassio ?

Hi

Please explain
How to install vitotrol2mqtt to Home Assistant?

I am also interested in this. Just reconnected my vitocom 100 back online to integrate it with home assistant. Thanks for sharing the library!

Can you add screenshot how this integration looks like?

I’ve created a MQTT bridge between vitotrol and a MQTT broker. This way it can easily be integrated in Home Assistant using MQTT sensors and switches or MQTT climate.

It seems I am not the only one who is usually using already ported integrations (this one requires building with go and adding to home assistant somehow). It might be useful to add some steps for newbies like us.

Hi all,

apologies for keeping you guys in the dark. I didn’t make it very clear indeed.

Short story:
The thing is that this is not a Home Assistant plugin or addon or anything of the sort. It’s a little program that talks to the vitodata api and translates that data into MQTT messages.
Afterwards, Home Assistant can use MQTT to create sensors, switches, … from this information.

The steps:
First things first, you will need a MQTT broker (e.g. mosquitto), and it has to be connected to Home Assistant (MQTT component).

Second thing is to run the application itself. This is done with Docker and docker-compose. If you don’t have Docker yet, this is the time :slight_smile:

In the repository, there is a docker-compose file and a Dockerfile. These are the files needed to get everything working. Check out the repo, and run:

docker-compose up -d

This will build and deploy the software.

Make sure that vitotrol2mqtt.yml reflects your specific situation. Also in this file, you can specify all the vitodata field you want to read and/or write. For the full list, please consult the original library.

When you have all this setup, there should now be information flowing from vitotrol into MQTT and visa versa.

Last step is creating a (set of) Home Assistant sensor(s), switch(es) or even a climate integration, like I mentioned in the first post.

So:

  1. install MQTT broker (if applicable)
  2. checkout and docker-compose up -d
  3. mqtt configuration in Home Assistant

I hope this clears some things up?

Be aware that apparently every Viessmann device acts a little bit differently, so trial and error might be necessary.

Anyway, the result is satisfying :slight_smile:


good luck!

I am trying to get this running… I want to run the docker container on Synology. Copied dockerfile and docker-compose file to NAS. Edited vitotrol2mqtt.yml with my information.
Then as root executed “docker-compose up -d”

Step 1/5 goes fine, Step 2 creates error. No clue what I am doing wrong here…

Step 2/5 : RUN CGO_ENABLED=0 GOOS=linux go get -u -a -tags netgo -ldflags '-w -extldflags "-static"' github.com/benvanmierloo/vitotrol2mqtt
 ---> Running in f7022ba83612
# cd .; git clone -- https://github.com/benvanmierloo/vitotrol2mqtt /go/src/github.com/benvanmierloo/vitotrol2mqtt
Cloning into '/go/src/github.com/benvanmierloo/vitotrol2mqtt'...
fatal: unable to access 'https://github.com/benvanmierloo/vitotrol2mqtt/': Could not resolve host: github.com
package github.com/benvanmierloo/vitotrol2mqtt: exit status 128
The command '/bin/sh -c CGO_ENABLED=0 GOOS=linux go get -u -a -tags netgo -ldflags '-w -extldflags "-static"' github.com/benvanmierloo/vitotrol2mqtt' returned a non-zero code: 1
ERROR: Service 'vitotrol' failed to build

What am I doing wrong here?

Thanks!

Resolved the issue. Synology firewall was blocking access to subnet that container will run in. 172.16.0.0/16
Added rule to allow traffic.

Hello benvanmierloo, thank's for you vitotrol2mqtt tool which installed very well as a docker within my synology environment running Mosquitto and HA , but i'm stuck since a couple of days and i cannot find the solution, perhaps you will have an idea which can help and unlock the situation, i feel i made some thingwrong somewhere or i missed a basic concept :wink:  (the only changes i made was to update HomeAssistant YAML syntax for MQTT to comply with new syntax)

test were done on the topic "vitotrol2mqtt/Solaire LAN Senlisse/konf_sparbetrieb_rw" which is 0 or 1 (this is to activate the Eco mode)....

**1/ Vitotrol Cloud  > vitotrol2mqtt > Mosquitto > MQTT-HomeAsiistant**, this data flow works very well .
so, i was able to  integrate sensor: ,binary sensor: ,switch: and climate: within my HA environment, all of them return correct values from the vitotrol cloud.
**BUT**
2/ **[u]no way[/u]** to succeed writing data toward the vitotrol cloud following the flow ; 
MQTT-HomeAssistant>Mosquiitto>vitotrol2mqtt>vitotrol Cloud
Monitoring the traffic with MQTT-explorer, i see that HomeAssitant "publish" is sent to the mosquito broker but it seems the "vitotro2mqtt listner" does not proceed it and do not send the write statement toward vitotrol cloud...
3/i try also to publish from MQTT-explorer directly or from HomeAssistant MQTT Dashboard : same symptom
4/ I try also from Home assistant Switch interface, in that case it appears in MQTT-Explorer a "set=1" line for the foreseen topic 
5/ associated documentation : 
5.1/ [u]Extract from configuration.yaml[/u]

mqtt:
  switch:
    - name: "Vitovalor - konf_sparbetrieb_rw"  
      state_topic: "vitotrol2mqtt/Solaire LAN Senlisse/konf_sparbetrieb_rw" 
      command_topic: "vitotrol2mqtt/Solaire LAN Senlisse/konf_sparbetrieb_rw/set" 
      payload_on: "1" 
      payload_off: "0"
      retain: true
      unique_id: "Vitotrol Switch Mode Economie"
    
    - name: "Vitovalor - konf_partybetrieb_rw"  
      state_topic: "vitotrol2mqtt/Solaire LAN Senlisse/konf_partybetrieb_rw" 
      command_topic: "vitotrol2mqtt/Solaire LAN Senlisse/konf_partybetrieb_rw/set" 
      payload_on: "1" 
      payload_off: "0"
      retain: true
      unique_id: "Vitotrol Switch Mode Reception"

  binary_sensor:
    - name: "binarycircpumpstate"
      state_topic: "vitotrol2mqtt/Solaire LAN Senlisse/CirculationPumpState"
      payload_on: "1" 
      payload_off: "0"
      unique_id: "binarycircpumpstate"

[u]5.2/ From MQTT-explorer Dashboard or from HA-MQTT interface[/u]

[u]5.3/ from HA Lovelace switch widjet interface[/u], i can see this "set=1" extra line in MQTT-Explorer

**konf_sparbetrieb_rw = 0**
**   set = 1**

if needed i can send to you a copy but i am limited to one media in that post

6/  conclusion : any idea i can work on ? my brain becoming dry :wink: 

for info  : if i use vitotrol-go command line  to SET data to the vitotrol cloud, it works

Hey Eric-IOT,

I see you use vitotrol2mqtt/Solaire LAN Senlisse/konf_sparbetrieb_rw and vitotrol2mqtt/Solaire LAN Senlisse/konf_partybetrieb_rw directly, which are the raw values and can only be read. Try using EnergySavingMode and PartyMode respectively instead. Those can be also be set.
Check attributes.go for the list of ReadOnly and ReadWrite attributes. If you have extra attributes which need to be ReadWrite, they should be added to the library.

So it will become:

mqtt:
  switch:
    - name: "Vitovalor - EnergySavingMode"  
      state_topic: "vitotrol2mqtt/Solaire LAN Senlisse/EnergySavingMode" 
      command_topic: "vitotrol2mqtt/Solaire LAN Senlisse/EnergySavingMode/set" 
      payload_on: "1" 
      payload_off: "0"
      retain: true
      unique_id: "Vitotrol Switch Mode Economie"

    - name: "Vitovalor - PartyMode"  
      state_topic: "vitotrol2mqtt/Solaire LAN Senlisse/PartyMode" 
      command_topic: "vitotrol2mqtt/Solaire LAN Senlisse/PartyMode/set" 
      payload_on: "1" 
      payload_off: "0"
      retain: true
      unique_id: "Vitotrol Switch Mode Reception"

Hi, benvanmierloo!
Thanks for your useful topic.

I try to integrate my Vitocom 200, but faced a number of problems.
Finally, I can run vitotrol2mqtt but as a result have no mqtt events. I’ve got errors executing docker-compose up

[+] Running 2/2
 ⠿ Network vitotrol2mqtt_default       Created                                                                                         0.4s
 ⠿ Container vitotrol2mqtt-vitotrol-1  Created                                                                                         0.8s
Attaching to vitotrol2mqtt-vitotrol-1
vitotrol2mqtt-vitotrol-1  | MQTT Connected
vitotrol2mqtt-vitotrol-1  | Vitotrol login...
vitotrol2mqtt-vitotrol-1  | Vitotrol GetDevices...
vitotrol2mqtt-vitotrol-1  | 1 device(s) found
vitotrol2mqtt-vitotrol-1  | Refreshing fields...
vitotrol2mqtt-vitotrol-1  | panic: runtime error: invalid memory address or nil pointer dereference
vitotrol2mqtt-vitotrol-1  | [signal SIGSEGV: segmentation violation code=0x1 addr=0x0 pc=0x28f9e8]
vitotrol2mqtt-vitotrol-1  |
vitotrol2mqtt-vitotrol-1  | goroutine 1 [running]:
vitotrol2mqtt-vitotrol-1  | main.getAttrValue(0x4000187e18, 0x4000201506, 0x33a1d0, 0x10)
vitotrol2mqtt-vitotrol-1  |     /go/src/github.com/benvanmierloo/vitotrol2mqtt/main.go:103 +0x98
vitotrol2mqtt-vitotrol-1  | main.refreshDevice(0x4000187e18, 0x4000118090, 0x12, 0x12, 0x1b)
vitotrol2mqtt-vitotrol-1  |     /go/src/github.com/benvanmierloo/vitotrol2mqtt/main.go:134 +0x260
vitotrol2mqtt-vitotrol-1  | main.refreshDevices()
vitotrol2mqtt-vitotrol-1  |     /go/src/github.com/benvanmierloo/vitotrol2mqtt/main.go:157 +0x1e8
vitotrol2mqtt-vitotrol-1  | main.mainLoop()
vitotrol2mqtt-vitotrol-1  |     /go/src/github.com/benvanmierloo/vitotrol2mqtt/main.go:245 +0x24
vitotrol2mqtt-vitotrol-1  | main.main()
vitotrol2mqtt-vitotrol-1  |     /go/src/github.com/benvanmierloo/vitotrol2mqtt/main.go:272 +0x194
vitotrol2mqtt-vitotrol-1 exited with code 0

Any ideas what’s wrong?

Hey!

hmmm, stange stuff here :slight_smile:

could you first try with the latest version? Some changes have been made which might help (doubt it thought…). Are you running Linux containers?

docker-compose build --no-cache && docker-compose up

It seems like its going wrong in the original library somehow.

With the new docker image you can directly call the vitotrol library to get all the attributes. Could you try that and see if that does work?

docker-compose exec vitotrol /vitotrol --login <username> --password <password> rget all

Let me know the results!

Hi!
I’ve tried to implement the new version, but have the same result.

root@raspberrypi:/home/dskudrin/vitotrol2mqtt# docker-compose build --no-cache
[+] Building 68.8s (16/16) FINISHED
 => [internal] load build definition from Dockerfile                                                                                                                                                          0.1s
 => => transferring dockerfile: 671B                                                                                                                                                                          0.0s
 => [internal] load .dockerignore                                                                                                                                                                             0.1s
 => => transferring context: 2B                                                                                                                                                                               0.0s
 => [internal] load metadata for docker.io/library/golang:1.21.1                                                                                                                                              1.9s
 => [internal] load metadata for docker.io/library/alpine:3.18.3                                                                                                                                              1.9s
 => CACHED [builder 1/3] FROM docker.io/library/golang:1.21.1@sha256:d2aad22fc6f1017aa568d980b15d0067a721c770be47b9dc62b11c33487fba64                                                                         0.0s
 => [internal] load build context                                                                                                                                                                             0.0s
 => => transferring context: 39B                                                                                                                                                                              0.0s
 => CACHED [stage-1 1/7] FROM docker.io/library/alpine:3.18.3@sha256:7144f7bab3d4c2648d7e59409f15ec52a18006a128c733fcff20d3a4a54ba44a                                                                         0.0s
 => [stage-1 2/7] RUN apk --no-cache add bash                                                                                                                                                                 5.8s
 => [builder 2/3] RUN CGO_ENABLED=0 GOOS=linux go install github.com/benvanmierloo/vitotrol2mqtt@latest                                                                                                      56.3s
 => [builder 3/3] RUN CGO_ENABLED=0 GOOS=linux go install github.com/maxatome/go-vitotrol/cmd/vitotrol@master                                                                                                 6.3s
 => [stage-1 3/7] COPY --from=builder /go/bin/vitotrol2mqtt /vitotrol2mqtt                                                                                                                                    0.6s
 => [stage-1 4/7] COPY --from=builder /go/bin/vitotrol /vitotrol                                                                                                                                              0.9s
 => [stage-1 5/7] RUN mkdir /config                                                                                                                                                                           0.7s
 => [stage-1 6/7] COPY ./vitotrol2mqtt.yml /config/vitotrol2mqtt.yml                                                                                                                                          0.3s
 => [stage-1 7/7] COPY ./vitotrol2mqtt.yml /vitotrol2mqtt.yml                                                                                                                                                 0.2s
 => exporting to image                                                                                                                                                                                        0.5s
 => => exporting layers                                                                                                                                                                                       0.5s
 => => writing image sha256:f3c3088e58c92f62bc101521ed30505f76e7022a775a32144fc14935605f806c                                                                                                                  0.0s
 => => naming to docker.io/library/vitotrol2mqtt-vitotrol                                                                                                                                                     0.0s
root@raspberrypi:/home/dskudrin/vitotrol2mqtt# docker-compose up
[+] Running 1/1
 ⠿ Container vitotrol2mqtt-vitotrol-1  Recreated                                                                                                                                                              0.7s
Attaching to vitotrol2mqtt-vitotrol-1
vitotrol2mqtt-vitotrol-1  | MQTT Subscribe:  vitotrol2mqtt/#
vitotrol2mqtt-vitotrol-1  | MQTT Connected.
vitotrol2mqtt-vitotrol-1  | Vitotrol login...
vitotrol2mqtt-vitotrol-1  | Vitotrol GetDevices...
vitotrol2mqtt-vitotrol-1  | 1 device(s) found
vitotrol2mqtt-vitotrol-1  | Refreshing fields...
vitotrol2mqtt-vitotrol-1  | panic: runtime error: invalid memory address or nil pointer dereference
vitotrol2mqtt-vitotrol-1  | [signal SIGSEGV: segmentation violation code=0x1 addr=0x0 pc=0x28037c]
vitotrol2mqtt-vitotrol-1  |
vitotrol2mqtt-vitotrol-1  | goroutine 1 [running]:
vitotrol2mqtt-vitotrol-1  | main.getAttrValue(0x2c4240?, 0x258)
vitotrol2mqtt-vitotrol-1  |     /go/pkg/mod/github.com/benvanmierloo/[email protected]/main.go:102 +0x3c
vitotrol2mqtt-vitotrol-1  | main.refreshDevice(0x400012de48, {0x4000070120?, 0x12, 0x12})
vitotrol2mqtt-vitotrol-1  |     /go/pkg/mod/github.com/benvanmierloo/[email protected]/main.go:131 +0x1c0
vitotrol2mqtt-vitotrol-1  | main.refreshDevices()
vitotrol2mqtt-vitotrol-1  |     /go/pkg/mod/github.com/benvanmierloo/[email protected]/main.go:154 +0x120
vitotrol2mqtt-vitotrol-1  | main.mainLoop()
vitotrol2mqtt-vitotrol-1  |     /go/pkg/mod/github.com/benvanmierloo/[email protected]/main.go:254 +0x20
vitotrol2mqtt-vitotrol-1  | main.main()
vitotrol2mqtt-vitotrol-1  |     /go/pkg/mod/github.com/benvanmierloo/[email protected]/main.go:281 +0x17c
vitotrol2mqtt-vitotrol-1  | MQTT Connected.
vitotrol2mqtt-vitotrol-1  | MQTT Subscribe:  vitotrol2mqtt/#
vitotrol2mqtt-vitotrol-1  | Vitotrol login...
vitotrol2mqtt-vitotrol-1  | Vitotrol GetDevices...
vitotrol2mqtt-vitotrol-1  | 1 device(s) found
vitotrol2mqtt-vitotrol-1  | Refreshing fields...

Running on HA Supervised in Docker@RPI4

Ohh, and the result of
docker-compose exec vitotrol /vitotrol --login --password rget all

BurnerHoursRun: uninitialized (Burner hours run)
InternalPumpStatus: uninitialized (Internal pump status)
OperatingModeRequested: continuous reduced@2023-09-13 13:39:46 (Operating mode r                                                                                                                                   equested)
HeatWaterOutTemp: 23.3@2023-09-13 13:39:46 (Heating water outlet temperature)
BurnerState: uninitialized (Burner status)
OutdoorTemp: 20.2@2023-09-13 13:39:46 (Outdoor temperature)
HeatNormalTemp: 20@2023-09-13 13:39:46 (Setpoint of the normal room temperature)
HeatReducedTemp: 12@2023-09-13 13:39:46 (Setpoint of the reduced room temperatur                                                                                                                                   e)
BurnerHoursRunReset: uninitialized (Reset the burner hours run)
BurnerStarts: uninitialized (Burner starts)
PartyMode: disabled@2023-09-13 13:39:46 (Party mode status)
CirculationPumpState: uninitialized (Statut pompe circulation)
DateTime: 2023-09-13 14:27:47@2023-09-13 13:39:46 (Current date and time)
CurrentError: 0F:00:00:00:00:00:00:00:00:00@2023-09-13 13:39:46 (Current error)
HolidaysEnd: 1970-01-01 00:00:00@2023-09-13 13:39:46 (Holidays end date)
FrostProtectionStatus: disabled@2023-09-13 13:39:46 (Frost protection status)
IndoorTemp: 23.5@2023-09-13 13:39:46 (Indoor temperature)
SmokeTemp: 20@2023-09-13 13:39:46 (Smoke temperature)
OperatingModeCurrent: reduced@2023-09-13 13:39:46 (Operating mode)
BoilerTemp: 23.3@2023-09-13 13:39:46 (Boiler temperature)
HotWaterOutTemp: uninitialized (Hot water outlet temperature)
PartyModeTemp: 22@2023-09-13 13:39:46 (Party mode temperature)
HotWaterSetpointTemp: 50@2023-09-13 13:39:46 (Setpoint of the domestic hot water                                                                                                                                    temperature)
HeatingPumpStatus: off@2023-09-13 13:39:46 (Heating pump status)
HolidaysStatus: disabled@2023-09-13 13:39:46 (Holidays program status)
HolidaysStart: 1970-01-01 00:00:00@2023-09-13 13:39:46 (Holidays begin date)
3WayValveStatus: uninitialized (3-way valve status)
HotWaterTemp: uninitialized (Hot water temperature)
EnergySavingMode: disabled@2023-09-13 13:39:46 (Energy saving mode status)
anzahl_brennerstunden_r-0x0063: 12754.4@2023-09-13 13:39:46 (anzahl_brennerstund                                                                                                                                   en_r)
anzahl_brennerstunden_2_r-0x0066: 0@2023-09-13 13:39:46 (anzahl_brennerstunden_2                                                                                                                                   _r)
anzahl_brennerstart_r-0x006c: 104387@2023-09-13 13:39:46 (anzahl_brennerstart_r)
info_brenner_modulation_r-0x1045: 0@2023-09-13 13:39:46 (info_brenner_modulation                                                                                                                                   _r)
konf_neigung_rw-0x0b35: 1.3@2023-09-13 13:39:46 (konf_neigung_rw)
konf_niveau_rw-0x0b3b: -5@2023-09-13 13:39:46 (konf_niveau_rw)
konf_partysolltemp_rw-0x0050: 20@2023-09-13 13:39:46 (konf_partysolltemp_rw)
konf_raumsolltemp_rw-0x0053: 21@2023-09-13 13:39:46 (konf_raumsolltemp_rw)
konf_raumsolltemp_reduziert_rw-0x0056: 12@2023-09-13 13:39:46 (konf_raumsolltemp                                                                                                                                   _reduziert_rw)
konf_ferien_start_rw-0x0133: 1970-01-01 00:00:00@2023-09-13 13:39:46 (konf_ferie                                                                                                                                   n_start_rw)
konf_ferien_ende_rw-0x0136: 1970-01-01 00:00:00@2023-09-13 13:39:46 (konf_ferien                                                                                                                                   _ende_rw)
konf_neigung_rw-0x0b37: 0.5@2023-09-13 13:39:46 (konf_neigung_rw)
konf_niveau_rw-0x0b3d: -3@2023-09-13 13:39:46 (konf_niveau_rw)
temp_vts_r-0x17a5: 24@2023-09-13 13:39:46 (temp_vts_r)
konf_ww_solltemp_2_rw-0x03b5: 0@2023-09-13 13:39:46 (konf_ww_solltemp_2_rw)
temp_ww_r-0x1502: 26.9@2023-09-13 13:39:46 (temp_ww_r)
zustand_brenner_r-0x00f4: Aus@2023-09-13 13:39:46 (zustand_brenner_r)
konf_heizungsschema_r-0x0321: 6 A1 + M2 + WW@2023-09-13 13:39:46 (konf_heizungss                                                                                                                                   chema_r)
zustand_wartung_rw-0x0361: aktiv@2023-09-13 13:39:46 (zustand_wartung_rw)
konf_fehlermanager_rw-0x03de: 1 Fehlermanager@2023-09-13 13:39:46 (konf_fehlerma                                                                                                                                   nager_rw)
konf_solarregler_r-0x1c67: 0 ohne@2023-09-13 13:39:46 (konf_solarregler_r)
externe_umschaltung_ba_r-0x010e: Aus@2023-09-13 13:39:46 (externe_umschaltung_ba                                                                                                                                   _r)
info_kennung_hk1_r-0x1f33: Direkter Kreis@2023-09-13 13:39:46 (info_kennung_hk1_                                                                                                                                   r)
konf_betriebsart_rw-0x005e: Dauernd Reduziert@2023-09-13 13:39:46 (konf_betriebs                                                                                                                                   art_rw)
externe_umschaltung_ba_r-0x010f: Aus@2023-09-13 13:39:46 (externe_umschaltung_ba                                                                                                                                   _r)
aktuelle_betriebsart_r-0x02c5: Reduzierter Betrieb@2023-09-13 13:39:46 (aktuelle                                                                                                                                   _betriebsart_r)
zustand_ferienprogramm_r-0x02cb: inaktiv@2023-09-13 13:39:46 (zustand_ferienprog                                                                                                                                   ramm_r)
zustand_frostgefahr_r-0x02ce: inaktiv@2023-09-13 13:39:46 (zustand_frostgefahr_r                                                                                                                                   )
zustand_heizkreispumpe_r-0x02da: Aus@2023-09-13 13:39:46 (zustand_heizkreispumpe                                                                                                                                   _r)
konf_sparbetrieb_rw-0x1ead: Aus@2023-09-13 13:39:46 (konf_sparbetrieb_rw)
konf_partybetrieb_rw-0x1eb0: Aus@2023-09-13 13:39:46 (konf_partybetrieb_rw)
zustand_speicherladepumpe_r-0x00fb: Aus@2023-09-13 13:39:46 (zustand_speicherlad                                                                                                                                   epumpe_r)
zustand_zirkulationspumpe_r-0x00fc: Aus@2023-09-13 13:39:46 (zustand_zirkulation                                                                                                                                   spumpe_r)
info_ww_charging_active_r-0x1c0c: 0: Ladung inaktiv@2023-09-13 13:39:46 (info_ww                                                                                                                                   _charging_active_r) 

Seems like running container can load data from Viessmann cloud but can’t publish mqtt messages.

UPD:
Vitotrol2mqtt requires only attribures of concrete device. I removed from vitotrol2mqtt.yml all attributes with uninitialized status and the container starts working.
Thanx!

1 Like

Hi!
I’ve got another problem. Vitotrol2mqtt works fine about 24hrs but after that there are no new mqtt messages. I see that the device is not connected. I tried to stop/start or rebuild vitotrol2mqtt - the same result. But it starts working after connection via Vitotrol app or logging in to vitodata100 online service. Again for 24hrs. I can set autorefresh of vitodata100 page on my server to prevent this error, but maybe there are another solutions?

Attaching to vitotrol2mqtt-vitotrol-1
vitotrol2mqtt-vitotrol-1  | MQTT Subscribe:  vitotrol2mqtt/#
vitotrol2mqtt-vitotrol-1  | MQTT Connected.
vitotrol2mqtt-vitotrol-1  | Vitotrol login...
vitotrol2mqtt-vitotrol-1  | Vitotrol GetDevices...
vitotrol2mqtt-vitotrol-1  | 1 device(s) found
vitotrol2mqtt-vitotrol-1  | Refreshing fields...
vitotrol2mqtt-vitotrol-1  | Device is not connected `VT 200'

Yeah, I also have this sometimes… Opening the app or logging in to the website fixes it. For me it happens only once every few months. Vitotrol2mqtt cant fix this unfortunately…

I recently also got a message from Viessmann:

we have noticed that an unusually large number of calls to the Viessmann Vitotrol interface were made via your user.
We would like to point out that the interface is not intended for a large number of queries and would ask you to refrain from automated queries.

We thank you for your understanding.

Looks like this is not going to keep working for long… bummer

1 Like

I don’t know the reason why device became disconnected but right now in my case vitotrol2mqtt is still working for 4 days. In HA I created automation to hourly change any unnecessary parameter. For example, party temperature which I never use.
Maybe there is a sence to create additional mqtt topic “Device is connected” in vitotrol2mqtt? After that we can enable or disable elements in HA to easily understanding that the problem of connection is active?

hello, i am trying to get it work… but i am facing this issue, could you please help me or guide me what i do wrong…

C:\Users\Roman\Desktop\viessmann>vitotrol2mqtt.exe -config vitotrol2mqtt.yml
Refresh interval: 60s
Restart delay: 30s
MQTT Connected.
MQTT Subscribe: vitotrol2mqtt/#
Vitotrol login…
Vitotrol GetDevices…
1 device(s) found
Refreshing fields…
panic: runtime error: invalid memory address or nil pointer dereference
[signal 0xc0000005 code=0x0 addr=0x0 pc=0x99a976]

goroutine 1 [running]:
main.getAttrValue(0xc000075e10?, 0x14fe)
C:/Users/Roman/Desktop/viessmann/main.go:108 +0x36
main.refreshDevice(0xc000075e10, {0xc00000ab30, 0x4, 0x4})
C:/Users/Roman/Desktop/viessmann/main.go:138 +0x239
main.refreshDevices()
C:/Users/Roman/Desktop/viessmann/main.go:161 +0x176
main.mainLoop()
C:/Users/Roman/Desktop/viessmann/main.go:261 +0x14
main.main()
C:/Users/Roman/Desktop/viessmann/main.go:290 +0x1f4