Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Vitocal200S support / XML file configurable #47

Open
RoP09 opened this issue Oct 24, 2023 · 14 comments
Open

Vitocal200S support / XML file configurable #47

RoP09 opened this issue Oct 24, 2023 · 14 comments

Comments

@RoP09
Copy link

RoP09 commented Oct 24, 2023

Hello,

I have a Vitocal 200S which uses a different command set (see https://github.com/openv/openv/wiki/Adressen#adressen-um-werte-abzufragen-oder-zu-setzen), which I already used successfully for years in FHEM / VCONTROL.

Would it be possible to make the vito.xml editable so we can add custom commands to allow other devices?

Thanks!

@RoP09
Copy link
Author

RoP09 commented Oct 24, 2023

I downloaded a copy of the addon and created a local addon from it, but no matter what I try it completly ignores any changes from the rootfs/etc/vito.xml. I simply changed the payload of an existing command to one that the 200S understands, but it still sends the old payload.

Could it be that the vito.xml is taken from the original vcontrold (installed from the docker file) instead of the provided one?

@elasc
Copy link

elasc commented Oct 29, 2023

as far as I understood, you can not modify a file of a installed add-on, as it's running in a container. The only possible configuration is within the config page of the add-on administration in ha.
Having this said, I do have exactly the same issue. Also Vitocal 200-S and also migrating from FHEM. :-)

@elasc
Copy link

elasc commented Oct 29, 2023

@Alexandre-io would you add the parameters for Vitocal 200-S in your code?

@Alexandre-io
Copy link
Owner

Hi @elasc, could you send me the vito.xml for the 200-S? I will try to find the best way to integrate it into the module.

@RoP09
Copy link
Author

RoP09 commented Oct 30, 2023

as far as I understood, you can not modify a file of a installed add-on, as it's running in a container. The only possible configuration is within the config page of the add-on administration in ha. Having this said, I do have exactly the same issue. Also Vitocal 200-S and also migrating from FHEM. :-)

Yes, that is why I installed it as a custom (local) addon and modified the files before installation, but still it seems it is not using the values I set there (maybe the wrong place?)

@Alexandre-io
Copy link
Owner

Hello @here! I just added the ability to customize the vito.xml file. You just need to create the vcontrold directory in the HA configuration files and add the vito.xml file.

cf. https://github.com/Alexandre-io/homeassistant-vcontrol/blob/main/vcontrold/DOCS.md#custom-vitoxml-configuration-file

@mifritscher
Copy link

Does this mean that I the check for the possible device IDs isn't enforced any longer?

Btw, for me the integration of the configuration for the Vitocal200S (device ID 204D) would be very useful as well :-)

@elasc
Copy link

elasc commented Oct 30, 2023

very nice @Alexandre-io and great support. I've added the modified vito.xml file as custom file as you've implemented this today. Attached please find my file for 204D (Vitocal 200-S).

Commands are getTempA getTempVListM1 getTempVLsollM1 getTempRL17A getTempSpu getUmschaltventil

A bit hacky; I've also added this device in command getTempVListM2 for reading Vorlaufsolltemperatur Anlage as I could not find an implemented command for this reading.
vito.xml.zip

@mifritscher
Copy link

Seems to work, thanks :-)

Hint for others: the vito.xml needs to be saved in /config/vcontrold (/config being the root of the "file editor").

My list of commands:

  • getTempA:FLOAT
  • getTempVListM1:FLOAT
  • getTempVListM2:FLOAT
  • getTempVLsollM1:FLOAT
  • getTempRL17A:FLOAT
  • getTempSpu:FLOAT
  • getUmschaltventil:FLOAT

My yaml:

mqtt:
  binary_sensor:
    - name: Status Umschaltventil
      unique_id: vcontroldgetUmschaltventil
      state_topic: openv/getUmschaltventil
      device_class: running
      value_template: "{% if(value|int == '0') %}OFF{% else %}ON{% endif %}"
      device:
        identifiers: vcontrold
        manufacturer: Viessmann
  sensor:
    - name: Aussentemperatur
      unique_id: vcontroldgetTempA
      device_class: temperature
      state_topic: openv/getTempA
      unit_of_measurement: °C
      value_template: "{{ value | round(2) }}"
      device:
        identifiers: vcontrold
        manufacturer: Viessmann
    - name: Vorlauftemperatur M1
      unique_id: vcontroldgetTempVListM1
      state_topic: openv/getTempVListM1
      device:
        identifiers: vcontrold
        manufacturer: Viessmann
      unit_of_measurement: °C
      value_template: "{{ value | round(2) }}"
    - name: Vorlauftemperatur M2
      unique_id: vcontroldgetTempVListM2
      state_topic: openv/getTempVListM2
      device:
        identifiers: vcontrold
        manufacturer: Viessmann
      unit_of_measurement: °C
      value_template: "{{ value | round(2) }}"
    - name: Vorlaufsolltemperatur M1
      unique_id: vcontroldgetTempVLsollM1
      state_topic: openv/getTempVLsollM1
      device:
        identifiers: vcontrold
        manufacturer: Viessmann
      unit_of_measurement: °C
      value_template: "{{ value | round(2) }}"
    - name: Ruecklauftemperatur 17A
      unique_id: vcontroldgetTempRL17A
      state_topic: openv/getTempRL17A
      device:
        identifiers: vcontrold
        manufacturer: Viessmann
      unit_of_measurement: °C
      value_template: "{{ value | round(2) }}"
    - name: Speichertemperatur unten
      unique_id: vcontroldgetTempSpu
      state_topic: openv/getTempSpu
      device:
        identifiers: vcontrold
        manufacturer: Viessmann
      unit_of_measurement: °C
      value_template: "{{ value | round(2) }}"

I think that some more commands should be adaptable for the Vitocal 200S, but this is a thing for the next days ;-)

@alexalex89
Copy link

alexalex89 commented Nov 5, 2023

Alexandre-io Maybe another idea to extend this issue. How about overwriting the vcontrold.xml or at least parts of it? My vito.xml (found on the internet) uses some custom protocmds, which are not available from vcontrold.
Example:
<command name="setaddr25"> <send>SEND 00 02 $addr $hexlen FA 00;RECV 2 SR</send> </command>

Thanks in advance :-)

@wtrumler
Copy link

wtrumler commented Nov 19, 2023

I also have a Vitocal 222-S and a Vitotronic 200 Type WO1C (Device ID = 204D)

(Remark: I quite new to homeassistant ;))

In order to use the vito.xml for my device (204D) I followed the steps described above.

  1. ssh into homeassistant
  2. created a folder add-on_configs/vcontrold
  3. copy my file vito.xml into the just created folder

To check if it is working I removed all existing commands and added the command getAussentemperatur which is the first command listed in my vito.xmlfile.

I tried to change the Device ID in the configuration to 204D, which fails vcontrol to start.
So I changed the Device ID back to 2094, which is one of the IDs defined in controls.xml´ This solves the restart issue, but now it doesn't recognize my command getAussentemperatur`.

In the protokol I get:

[77] Sun Nov 19 17:46:23 2023 : Command: getAussentemperatur
[77] Sun Nov 19 17:46:23 2023 : Command: quit
SRV ERR: command unknown

So I thought I change the Device ID in my vito.xml file to 2094 match the ID in the configuration.
But I still get the same error about the unknown command.

What am I missing here?

This is the top most part of my vito.xml (still with the original Device ID):

<vito> 
	<devices>
		<device ID="204D" name="V200-S" protocol="P300"/> 
	</devices>
	
	<commands>
	<!-- TEMPERATUREN -->

		<command name="getAussentemperatur" protocmd="getaddr"> 
			<addr>0101</addr>
			<len>2</len>
			<unit>UT</unit>
			<description>Ermittle Aussentemperatur in Grad C (-40..70)</description>
		</command>

@WarmeBrille
Copy link

Seems to work, thanks :-)

Hint for others: the vito.xml needs to be saved in /config/vcontrold (/config being the root of the "file editor").

My list of commands:

  • getTempA:FLOAT
  • getTempVListM1:FLOAT
  • getTempVListM2:FLOAT
  • getTempVLsollM1:FLOAT
  • getTempRL17A:FLOAT
  • getTempSpu:FLOAT
  • getUmschaltventil:FLOAT

My yaml:

mqtt:
  binary_sensor:
    - name: Status Umschaltventil
      unique_id: vcontroldgetUmschaltventil
      state_topic: openv/getUmschaltventil
      device_class: running
      value_template: "{% if(value|int == '0') %}OFF{% else %}ON{% endif %}"
      device:
        identifiers: vcontrold
        manufacturer: Viessmann
  sensor:
    - name: Aussentemperatur
      unique_id: vcontroldgetTempA
      device_class: temperature
      state_topic: openv/getTempA
      unit_of_measurement: °C
      value_template: "{{ value | round(2) }}"
      device:
        identifiers: vcontrold
        manufacturer: Viessmann
    - name: Vorlauftemperatur M1
      unique_id: vcontroldgetTempVListM1
      state_topic: openv/getTempVListM1
      device:
        identifiers: vcontrold
        manufacturer: Viessmann
      unit_of_measurement: °C
      value_template: "{{ value | round(2) }}"
    - name: Vorlauftemperatur M2
      unique_id: vcontroldgetTempVListM2
      state_topic: openv/getTempVListM2
      device:
        identifiers: vcontrold
        manufacturer: Viessmann
      unit_of_measurement: °C
      value_template: "{{ value | round(2) }}"
    - name: Vorlaufsolltemperatur M1
      unique_id: vcontroldgetTempVLsollM1
      state_topic: openv/getTempVLsollM1
      device:
        identifiers: vcontrold
        manufacturer: Viessmann
      unit_of_measurement: °C
      value_template: "{{ value | round(2) }}"
    - name: Ruecklauftemperatur 17A
      unique_id: vcontroldgetTempRL17A
      state_topic: openv/getTempRL17A
      device:
        identifiers: vcontrold
        manufacturer: Viessmann
      unit_of_measurement: °C
      value_template: "{{ value | round(2) }}"
    - name: Speichertemperatur unten
      unique_id: vcontroldgetTempSpu
      state_topic: openv/getTempSpu
      device:
        identifiers: vcontrold
        manufacturer: Viessmann
      unit_of_measurement: °C
      value_template: "{{ value | round(2) }}"

I think that some more commands should be adaptable for the Vitocal 200S, but this is a thing for the next days ;-)

No matter what I try, I don't see any changes in the add-on.

Since you are using file explorer too, what do you mean with /config is the root of the explorer?
For some reason any path I can access starts with /files.

I placed it here
/files/config/addons_config/vcontrold/vito.xml
And here
/files/config/vcontrold/vito.xml

The vito.xml has a wrong device id so it definitely throw a error in the log when the add-on starts but there's nothing.

Somebody please help.

@dk1305hb
Copy link

I do not use the external vito.xml, but did you try this?
Screenshot 2023-11-22 um 15 52 44
And then use the file upload function for your vito.xml

@WarmeBrille
Copy link

I do not use the external vito.xml, but did you try this? Screenshot 2023-11-22 um 15 52 44 And then use the file upload function for your vito.xml

Worked!
Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

8 participants