ssy
June 2, 2018, 12:22pm
21
Check your z-wave configuration and adjust USB-path if not working. That was the issue with my hassio installation.
#my config.yaml
zwave:
usb_path: /dev/ttyACM0
#so adjust the command as follows (for turning off):
> 'echo -e -n "\x01\x08\x00\xF2\x51\x01\x00\x05\x01\x51" > /dev/ttyACM0'
3 Likes
bythelake
(Kevin Forth)
December 1, 2018, 11:24pm
22
That was awesome, thanks. I’ve added that switch to my hassio config and it worked perfectly.
Hi all.
I find a way to make it work in hassbian:
- platform: command_line
switches:
aeotec_zstick_disco_light:
friendly_name: 'Aeotec Z-Stick Disco Light'
command_on: '/usr/bin/echo -e -n "\x01\x08\x00\xF2\x51\x01\x01\x05\x01\x50" > /dev/serial/by-id/usb-0658_0200-if00'
command_off: '/usr/bin/echo -e -n "\x01\x08\x00\xF2\x51\x01\x00\x05\x01\x51" > /dev/serial/by-id/usb-0658_0200-if00'
The key is to use the full path of echo.
Still useless, so indispensable.
1 Like
ghstudio
(douglas weiss)
August 11, 2019, 4:46pm
24
streetchat…tried and nothing happens
hi.
maybe you can add some attributes to /usr/bin/echo to give it the right to be run by homeassistant user ?
Sorry, i lost my actual installation on hassbian and can not check at the moment. I am trying to get back configuration from a backup and mount a new fresh installation in hass.io and i am looking how to do this.
kind regards
Try this:
> - platform: command_line
> switches:
> aeotec_zstick_disco_light:
> friendly_name: 'Aeotec USB Z-Wave Light'
> command_on: 'echo -e -n "\x01\x08\x00\xF2\x51\x01\x01\x05\x01\x50" > /dev/ttyACM0'
> command_off: 'echo -e -n "\x01\x08\x00\xF2\x51\x01\x00\x05\x01\x51" > /dev/ttyACM0'
ewelin34
(Eric)
December 9, 2019, 6:31pm
27
awesome solution, thanks sharing!
Does anyone know if there is a command to specify a static color for the LED?
Fantastic!!! many thanks!!
rpbatchelor
(Ryan Batchelor)
January 25, 2021, 5:16am
30
Excellent solution from NotoriousBDG - worked a treat
works perfectly thank you
Even three years after posting, it’s still useful. Thank you.
1 Like
peerkn
(Peerkn)
June 8, 2023, 2:43pm
33
Hello,
in home assistant V. 2023.6.0 there is a breaking change with the command_line. What is the way to implement it correct in config.yaml?
Thanks and best regards
Peer
peerkn
(Peerkn)
June 8, 2023, 4:21pm
34
I solved the problem.
Remove the switch from your config.yaml.
Add the following to your config.yaml:
command_line: !include command_line.yaml
Make a folder command_line.yaml in the home assistant config folder.
Add the following in the command_line.yaml:
switch:
name: "Aeotec Z-Stick Disco Light"
command_on: 'echo -e -n "\x01\x08\x00\xF2\x51\x01\x01\x05\x01\x50" > /dev/ttyACM0'
command_off: 'echo -e -n "\x01\x08\x00\xF2\x51\x01\x00\x05\x01\x51" > /dev/ttyACM0'
At least change the “Aeotec Z-Stick Disco Light” entity to the current on your dashboard.
I found the hint to my solution here:
https://community.home-assistant.io/t/2023-6-network-storage-favorite-light-colors-new-integrations-dashboard/579381/122
and in the following posts.
Best regards
Peer
3 Likes
@peerkn thanks for the updated version.
In case anyone else ends up needing this. It also works directly in the config.yaml as:
command_line:
- switch:
name: "Aeotec Z-Stick Disco Light"
command_on: 'echo -e -n "\x01\x08\x00\xF2\x51\x01\x01\x05\x01\x50" > /dev/serial/by-id/usb-0658_0200-if00'
command_off: 'echo -e -n "\x01\x08\x00\xF2\x51\x01\x00\x05\x01\x51" > /dev/serial/by-id/usb-0658_0200-if00'