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

Set values are cut off too early #48

Open
dk1305hb opened this issue Nov 3, 2023 · 3 comments
Open

Set values are cut off too early #48

dk1305hb opened this issue Nov 3, 2023 · 3 comments

Comments

@dk1305hb
Copy link

dk1305hb commented Nov 3, 2023

Hi,

I have noticed that some set commands are not successful if the values have got whitespaces.

Example from Unit "BetriebsArt", enum value
<enum bytes="04" text="H+WW FS"/>

The set command is cut off after "H+WW"

I think the reason is in vcontrold/rootfs/etc/services.d/vclient_sub/run
Line 19

echo "setBetriebsArt H+WW FS" | cut -d' ' -f2
=H+WW

Maybe solved by
echo "setBetriebsArt H+WW FS" | cut -d' ' -f2-
=H+WW FS

Regards
Daniel

@Huskerdu24
Copy link

I see a similar issue here:
The payload for the heating shedule doesn’t work at all. I.e. this:

select: 
    - name: "HZ01 Timer HZ Mo Sel"
      unique_id: "vcontroldgetTimerMoHeizen"
      state_topic: "openv/getTimerMoHeizen"
      device:
        identifiers: vcontrold
        manufacturer: Viessmann
      command_topic: "openv/setTimerMoHeizen"
      options:
        - "Zeit 1"
        - "Zeit 2"
      command_template: |-
        {% if value == 'Zeit 1' %}
        06:30 08:30 18:30 22:00
        {% elif value == 'Zeit 2' %}
        07:30 10:30 19:30 23:30
        {% endif %}

Option "Zeit 1" sends only the first “on”-time in the string = “06:30”. It doesn’t send the whole String "06:30 08:30 18:30 22:00" including the other values.
Hopefully there will be a solution for that at some point as well.

@ppuetsch
Copy link

ppuetsch commented Dec 4, 2023

I think the root cause is that in
https://github.com/Alexandre-io/homeassistant-vcontrol/blob/main/vcontrold/rootfs/etc/services.d/vclient_sub/run
the mosquito_sub messages are split by space.
A workaround is maybe to format the output of mosquito_sub using the -F option (see https://mosquitto.org/man/mosquitto_sub-1.html).

@Huskerdu24
Copy link

Thank you.
I am not a programmer. Can I somehow solve the problem myself?

jodli added a commit to jodli/homeassistant-vcontrol that referenced this issue Dec 19, 2024
Resolves Set values are cut off too early Alexandre-io#48.
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

3 participants