Hey,
I’ve integrated Velbus support with Home Assistant as of version 0.50
See this link for announcement / more information.
Happy to get your thoughts/improvements.
Hey,
I’ve integrated Velbus support with Home Assistant as of version 0.50
See this link for announcement / more information.
Happy to get your thoughts/improvements.
That’s great news.
I’ll give it a try when I get 5 minutes… Or more
Just one question.
Does it have to connect directly to the TTY port? Or can I point it to a TCP/IP stream?
Like VelServ or JVelbusD?
(So that we don’t have to disconnect the USB to connect VelbusLink)
It connects directly to TTY (based on python-velbus). I experimented earlier with TCP/IP stream but have not tested code anymore in recent years since I don’t use it myself.
Okay, a second USB interface isn’t the end of the world
I did try to get it up and running today.
It detected my Google Chromecast devices and worked really well.
When I tried to connect to a Velbus test rig, I got some strange issues.
I tried to setup a light and a switch.
I couldn’t get the config right for a switch and the light appeared on the UI, but when I switched it on, 2 seconds later it showed as off again.
(I must confess that I didn’t look to see if the light came on at all)
Is there some more detailed instructions anywhere?
Or is there a way I can see some debugging?
Cheers,
Stuart
Great!
Thanks for trying.
The lights and switches need to be configured manually (see documentation online) and I currently don’t support dimming (I use SwitchRelayOff and On Messages for both). When it shows as off again, it means that the command did not go through since state only changes if a Velbus status message is received.
Happy to take a look if you post your config.
The log component of home assistant can be set to DEBUG which will give you more info.
Hi
Thanks for the offer to help.
I’ve tried to follow the instructions, but the best I can get is notes in the output saying that “unrecognised messages received”.
Which is okay, because I see the same messages in OpenRemote.
It just means that a packet has come in which isn’t recognised, but it has been received.
So, I’m happy to say that by removing the apostrophes from the tty address, I’ve got a live connection to my Velbus model.
velbus:
port: '/dev/ttyACM0'
Didn’t work on my Ubuntu machine, but this does :
velbus:
port: /dev/ttyACM0
So the next issue is getting anything to work in the UI.
If I add this text, I get a single slide switch in the UI.
But if I try to operate it,
It slides to ON.
Waits a few seconds, then slides to off again.
(I can’t get the switch to work in any way)
#Velbus components
#switch:
# - platform: velbus
# devices:
# - name: Switch
# type: single
# module: 0x74
# channel: 5
light:
- platform: velbus
devices:
- name: light
module: 0xba
channel: 4
There is a bit of red text that I see in the screen output in Ubuntu, which is shown in this screen grab.
Something about dependencies not being met.
(Screenshot in the zip)
The attached zip file contains the VLP file that is the current configuration of my model / development unit, please feel free to use any of the data in it to configure something to get a working example.
Many thanks,
Stuart
P.S.
There’s no rush
Hello Thomas and MDAR,
whatever I try to get the VMB1USB interface to work with Home Assistant on a Raspberry Pi 3 it does not work.
I have tried to change the entry of the configuration.yaml file several times, see below:
velbus:
** port: ‘/dev/ttyUSB00’**
to
velbus:
** port: /dev/ttyUSB00**
but also to
velbus:
** port: ‘/dev/ttyACM0’**
and also this one
velbus:
** port: /dev/ttyACM0**
It does NOT work
Here is my latest output of /config/home-assistant.log
2017-10-16 20:45:51 ERROR (SyncWorker_4) [velbus] Could not open serial port, no messages are read or written to the bus
2017-10-16 20:45:51 ERROR (MainThread) [homeassistant.setup] Error during setup of component velbus
Traceback (most recent call last):
** File “/usr/lib/python3.6/site-packages/serial/serialposix.py”, line 244, in open**
** self.fd = os.open(self.portstr, os.O_RDWR | os.O_NOCTTY | os.O_NONBLOCK)**
FileNotFoundError: [Errno 2] No such file or directory: '/dev/ttyUSB00’
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
** File “/usr/lib/python3.6/site-packages/velbus/connections/init.py”, line 60, in init**
** rtscts=self.RTSCTS)**
** File “/usr/lib/python3.6/site-packages/serial/serialutil.py”, line 182, in init**
** self.open()**
** File “/usr/lib/python3.6/site-packages/serial/serialposix.py”, line 247, in open**
** raise SerialException(msg.errno, “could not open port {}: {}”.format(self._port, msg))**
serial.serialutil.SerialException: [Errno 2] could not open port /dev/ttyUSB00: [Errno 2] No such file or directory: '/dev/ttyUSB00’
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
** File “/usr/lib/python3.6/site-packages/homeassistant/setup.py”, line 194, in _async_setup_component**
** component.setup, hass, processed_config)**
** File “/usr/lib/python3.6/asyncio/futures.py”, line 331, in iter**
** yield self # This tells Task to wait for completion.**
** File “/usr/lib/python3.6/asyncio/tasks.py”, line 244, in _wakeup**
** future.result()**
** File “/usr/lib/python3.6/asyncio/futures.py”, line 244, in result**
** raise self._exception**
** File “/usr/lib/python3.6/concurrent/futures/thread.py”, line 55, in run**
** result = self.fn(self.args, self.kwargs)
** File “/usr/lib/python3.6/site-packages/homeassistant/components/velbus.py”, line 33, in setup*
** connection = velbus.VelbusUSBConnection(port)**
** File “/usr/lib/python3.6/site-packages/velbus/connections/init.py”, line 64, in init**
** raise VelbusException(“Could not open serial port”)**
velbus.connections.VelbusException: 'Could not open serial port’
2017-10-16 20:45:55 WARNING (MainThread) [homeassistant.setup] Setup of sensor is taking over 10 seconds.
2017-10-16 20:45:57 WARNING (MainThread) [homeassistant.setup] Setup of tts is taking over 10 seconds.
2017-10-16 20:46:21 WARNING (SyncWorker_13) [netdisco.ssdp] Error fetching description at http://192.168.1.65:40000/device_description
Can you please help me to get this to work?
Thnak you,
GiGi
seems you’re pointing to a non-existing device; check the name of your device : to see your devices enter following in a shell:
ls /dev/tty*
or check with
sudo dmesg
the last lines for the name just after you connected the usb device.
Dimming would be great. Are you going to develop more on velbus integration in Home Assistant?
I’m going to write documentation for python-velbus library so it becomes easier to understand how to integrate support for other modules.
I don’t have dimmers myself so can’t write support for them.
in the last couple of weeks thomas and i optimized the velbus integration for HomeAssistant.
The system now does autodiscovery of all the (known) modules, currently it supports the relay modules, the vmb*pbn, vm6in, vmb7in (input only) and the glasspanels (input + temperature only)
I’m currently working on adding more modules:
Try openhabian on Rpi and google home.
So far it’s the best i have tested.
Does absolutely everything!
Fantastic! Thanks for this, this will mean true integration.
I am struggling since the update of HA to 0.76 and newer:
How do you add Velbus?
The syntax for adding the component which works in .69 doesn’t seem to work anymore, I’m not sure what I’m overlooking. The release notes state that the component should still be added, but that modules will be discovered automatically. When not changing the configuration.yaml while upgrading, I suddenly get the error that the component could not be successfully added.
What could be the reason for this? Any clues on how to solve? In the meantime I’ve downgraded to 0.69 until further notice.
TIA
Ward
HA standing for home assistant?
i am talking about openhab…
Hi Ciceron,
I would like to stick with Home Assistant, however I have no clue how to use the great work by cereal in the newer versions of it.
Best regards
it is easy, give it a try, you wont regret. follow youtube tutorial and ask…
in the latest version you just have to add this to you HA config (homeassistant)
velbus:
port: ‘127.0.0.1:3788’switch:
- platform: velbus
binary_sensor:
- platform: velbus
sensor:
- platform: velbus
port can be a ip:port format or a linux device.
When thats there and you start HA all devices will be auto-discoverd
Dear cereal,
Thank you so much for your answer!
However…
When adding this:
velbus:
port: ‘/dev/ttyACM0’
switch:
I get this error message:
When checking out the available hardware, the ACM one disappears if I disconnect the velbus USB to serial module.
I’m really stuck
When researching, I found this article, containing a path to the velbus component:
I can’t seem to find any of the 3 locations mentioned in that debug message.
Could the velbus folder be missing in v0.77?
Once it is solved I would be happy to update and submit the documentation page
HI Cereal, this didn’t work. Can you help me out?
I’m sure we’re not far off, and then I would have all that lovely functionality.