Openhab add Velbus Bridge issue

Hi All

I need your help and support regarding my openhab/velbus installation:

-I’ve done a fresh install on an new server with the same openhab version 3.2.0 as my old server

-I’ve backed up the config from the old server (my Nas)

  • Both my NAS and the new server running Version 3.2.0 (Build) on Debian distro.

-After restoring that backup —> blank page + service disconnecting in loop every few minutes, so I gave up…

I decided then to configure everything from scratch on the new server:

-Installed the velbus addon: OK

-I’m stuck at the bridge detection: it is a Velbus USB Serial Bridge, “VMB1USB” over the usb port “port”: “/dev/ttyACM0”

If I remeber properly , few years ago , this one just appeared in the list then I just configured it according the Usb port etc…

-I’ve added a VMB1USB.things file with the line below, in /etc/openhab/things and rebooted but still can’t detect it:

Bridge velbus:bridge:1 [ port="/dev/ttyACM0, reconnectionInterval=“15” ]

  • I compared in the /etc/openhab/things of the Nas: no .things file in there

The difference now VS few years ago is I have the Signum: this one appears automatically in the things

Did the signum took the preference over the VMB1USB? I don’t think so…both should be seen normally, no?

Also after a Scan, I cannot detect the other devices thru the Signum : tried both 80 and 8080 ports which are green and 27015 : red
Just to remind you that the Signum is the Velbus Server solution based on a Raspberry motherboard, it has both Network and Serial Bridge function.

I can only add manually but VMB1USB is not present as it is a Bridge.

Do you think that it could be because of a Velbus addon update that removed the VMB1USB?

-Already uninstalled/ re-installed the Velbus binding…

-Already replaced the USB cable from the server to the USB serial interface

Maybe it is something obvious but I can’t see it!!!

I’m starting to be out of idea.

My next step would be to remove the signum from the network like that it will not interfere with the others bridges…
I will also open the things json file in the jsondb folder and paste in it the VMB1USB config lines copied from the backed up config and give a try…

Best Regards

Youness

Okay, I’ve not tried to link openHAB with the USB port on Signum, I’ll give it a try.

Ports 80 & 8080 of Signum are for Web access to the Signum UI.

Port 27015 is the Velbus port, however it is a secure port with TLS & SSL, which openHAB Velbus binding doesn’t support right now.

My advice would be to add the official Velbus Snap package to your openHAB machine and connect using a Network bridge on 127.0.0.1, after you have set up Velbus-tcp correctly. (Obviously removing the Serial bridge)

You can try this script to install Velbus-tcp

https://www.mdar.co.uk/dl/velbus/velbus-tcp.sh

You can then connect openHAB Velbus Network bridge with

127.0.0.1
Port 6000

(No security)

It also exposes port 27015 with a TLS password.

Hi Stuart,

Thank you for your quick resply, appreciate.
I’ll give a try.
But still I would like to know why teh Usb-Serial VMB1USB is not seen or detected to allow me to configure it over the /dev/ttyACM0?
When attached to the new server on the sub port and if I invoque the command:
ls -l /dev/serial/by-id/usb-Velleman_Projects_VMB1USB_Velbus_USB_interface-if00
it returns:
→ …/…/ttyACM0

Regards

Youness

I’ll confess that I haven’t used the Serial bridge for many years, I tend to use VelServ or Velbus-tcp as a gateway, so that I can connect multiple times to the same USB.

What are you entering for the /dev/ttyACM0 in the serial bridge?

Hi Stuart,

What I think is that the serial device detected in the things is also the Signum, as this one has several hardware function according to its specs, if I’m not wrong.
The VMB1USB, should normally appear has USB Serial Bridge, like it is on my NAS Openhab instance.
This has been confirmed after the 1st openhab and velbus binding install, at the add Things step, WITHOUT the VMB1USB being plugged in the usb port and not powered by +12V.
I had that:

For me this picture is showing the 2 hardware functions of the Signum (Network+Serial).
If I would like to add a thing on my previous openhab instance on my Nas, I have the exact same double device bridge, but with the VMB1USB already installed and online, as the unique bridge for my installation.

Below, is how the VMB1USB appears and is configured on my NAS:

That’s why I suppose that “Velbus USB Serial Bridge” is different from "Velbus Serial Bridge "

But again why the VMB1USB (Velbus USB Serial Bridge) doesn’t show up on the new server freshly installed?
Did they removed it from the Velbus addon?

Regards

Youness

Just for clarity, Velbus Bridges like most system bridges aren’t detected they have to be manually installed.

The fact that the Serial bridge defaults to ttyACM0 is purely what the developer set it to as a starting point.

Likewise with the Network Bridge, you would have to configure it to suit your system.

As far as I’m aware, they are exactly the same thing.

USB presents as a Serial port to the computer, so no difference.

So we come full circle back to the original issue.

I’ll plug my Signum USB port into a Linux machine and see what happens and what Linux calls the USB device.

Hi Stuart,

My issue is I can’t add the VMB1USB serial bridge.

  • Either because I don’t know/remember how to do it on openhab 3.2.0, because on my last working config, if I remember correctly it was 2.5 then updated later to 3.2.0
    I would appreciate if you tell me how to do it.

  • Or I’m doing it the right way but for some reason, I get stuck when I want to edit the config of the serial bridge, the screen stays grey and flashing without being populated…see below how I proceed:

then

to finally get that:

That screen stays forever if you let it …
More than that, it is kind of freezing the openhab service:

  • I have no 8080 port and web UI page not available
  • to recover from that, I have to invoke
    systemctl restart openhab.service
    or stop/start it and wait few minutes to get access again.

here is the status of the service when get that freeze, It looks like the karaf process is down!:

for info, I’m using

openjdk version “11.0.5” 2019-10-15 LTS
OpenJDK Runtime Environment Zulu11.35+36-CA (build 11.0.5+10-LTS)
OpenJDK Client VM Zulu11.35+36-CA (build 11.0.5+10-LTS, mixed mode)

I can try to install the last revision 11.0.14.1+1 Zulu: 11.54.25

Regards

Youness

Have you tried creating a text based Things file for the bridge?

Something as simple as ----

Bridge velbus:bridge: VelbusSerial [ port="/dev/ttyACM0" ]

As I’ve wrote it in my 1st post , I tried to add a .things file in /etc/openhab/things/ :

I’ve also tried with your text line: Bridge velbus:bridge: VelbusSerial [ port="/dev/ttyACM0" ]
unfortunatly it still the same situation: freezing when trying to configure the detected serial bridge + not showing the USB Serial one (VMB1USB) on that server.

On the other hand, on my “old” server ( NAS ), now it sees all 3 bridges ( Network, Serial and USB-Serial ) and as I’ve installed the Velbus.sh script, but I’m still not able to control all my things and my home installation thru the Signum (Network and Serial), even if everything is online and green.

  • For the Network: populated the local signum IP adress + the Velbus link port 27015 (6000 doesn’t work, it remain offline)
    Also tried with 127.0.0.1 and 6000/27015 without sucess.
  • For the Serial : just populated the USB port on which it’s plugged in , for me it was the /dev/ttyACM0

After what I went on all the offline things and changed the parent bridge as so, to turn the Online:

Regards

Youness

Hi

I’m a little lost as to how to help you as there are a few details about what you are trying to achieve that confuse me.

  • There are only two types of bridges, The network bridge and the serial bridge.
    Where are you getting a USB Bridge from?

  • Why are you trying to control the same Velbus network from more than One bridge?

My advice would be to connect to your network using a Network bridge, then multiple instances of openHAB and Velbuslink can connect.

As to why openHAB is hanging when you add a serial Bridge, that is a complete mystery to me.
It’s not something I have seen before or able to re-create.

FYI

This is what I see when connecting a VMBRSUSB and a VMBSIG via USB cables to a machine.

I really want to help, I just can’t work out how to.

If it helps, this is how I have the Velbus snap package configured, so that I can access the Velbus network from anything, from anywhere on my LAN

root@SamsungN150-01:~# snap get velbus-tcp -d


{
        "logging": {
                "output": "stream",
                "type": "info"
        },
        "ntp": {
                "enabled": true,
                "synctime": ""
        },
        "serial": {
                "autodiscover": true,
                "port": "/dev/serial/by-id/usb-Velleman_Projects_VMB1USB_Velbus_USB_interface-if00"
        },
        "tcp": {
                "auth": "true,false",
                "authkey": "MyKey-example,",
                "cert": "/var/snap/velbus-tcp/common/certificate.pem",
                "host": "0.0.0.0,127.0.0.1",
                "pk": "/var/snap/velbus-tcp/common/privkey.pem",
                "port": "27015,6000",
                "relay": "true,true",
                "ssl": "true,false"
        }
}

It should be a simple matter to swap the serial device to the Signum with a command like –

snap set velbus-tcp serial.port=/dev/serial/by-id/usb-Velbus_VMBSIG_Velbus_USB_interface-if00

You can easily use that command to swap between USB or RS232 connections, if you have multiple isolated Velbus networks.

I see an issue here, but more about understanding what you are doing.

I can’t confirm (at this time) that the openHAB Velbus binding works with the Signum device via TCP.

Your Signum exists on your LAN with a unique IP address.

If the Signum’s instance of Velbus-tcp (or the python equivalent) works with openHAB, you would need to use port 27015

This assumes that the Signum isn’t expecting a TLS Authorisation key, which openHAB can’t provide at present.

Port 6000 was an arbitrary number I dreamt up years ago, when we were working exclusively with Velserv for TCP connections. (VelServ can be set with any port number.)

So if you were running VelServ on the same machine as openHAB, you would use the localhost / loopback IP address of 127.0.0.1 and port 6000

Now that I have swapped over to the Velbus official Snap package, I configure an unsecured Loopback port at 6000 and a secure LAN port at 27015 with a TLS password for Velbuslink or Control4 (as an example)
(As you can see in my previous message)

I think I may have spotted another misunderstanding.

Bridges are very rarely automatically detected.

What you have shown here is the ability to manually add a bridge of your choosing.

As stated in the binding documents.

You must decide how you want openHAB to connect to your Velbus network.

Ensuring all requirements are met.

Looking closely at this screen shot.

This is a Velbus Serial bridge, that You / Someone elected to name “Velbus USB Serial Bridge”

Which explains the later confusion.

Hi Stuart,

I’m back with some fresh news:

  • I’ve installed openhab server on linux laptop ( Ubuntu) and plugged the VMB1USB.
    installed the Velbus binding

  • Invoked:
    ls -l /dev/serial/by-id/
    which returned: ttyACM0

  • In “Things” clicked on + to manually add the serial/usb:
    the page opened successfully VS flashing white and grey on the other server that I couldn’t add the VMB1USB. see below how that flashing page it looks:

  • populated the “serial port” with ttyACM0 and saved
  • scanned my local installation : which has detected all my modules successfully

So based on that I’m assuming that it is kinda hardware limitation on the other server, that prevent it to open the “serial bridge” page under things…
that server is the sheevaplug that I was using as server with the HomeCenter installed on it.
The hardware specs are:

  • Processor Marvell Kirkwood. Architecture ARM v5. 1,2 GHz.
  • Memory 512 Mo DDR2 and 512 Mo of Flash Memory ( Nand).

As you may know better then I: This “plug computer” was shipped with [Ubuntu 9.04], which was the last or the only available version for the ARM 32sf architecture.
I think that Stijnen who has developped the HomeCenter for Velbus, did it on ubuntu 9 VS me over Debian 8,9,10 and 11. (tried them all)
Do you think that It could be a ubuntu 9.04 VS Debian X issue? I don’t think but who knows?
Or something else in the install? Any clue/advise or idea is welcome.

Unfortuatly I was unable to find ubuntu 9.04 for arm32 (uImage/uInitrd for UBoot) , even after many hours of research…
So if some knows where to dowlnload it or have it, please share just to give a 2nd life to that Sheevaplug Computer.

Best Regards

Youness

1 Like

That’s excellent news.

Proves that everything in the Velbus realm works well.

Arrrrr I see

That explains a lot.

If you try a Debian OS, can you run VelServ or Snap Velbus-tcp as a gateway to the USB device, using the /dev/serial/by-id/velleman-xxxxx path.

VelServ

Velbus-tcp

Then use the Velbus Network Bridge in openHAB?

(From another machine, before you install openHAB on the Sheevaplug)

And try connecting Velbuslink over the LAN to the Sheevaplug.

Or…

I see a bright future for it, in a glass cabinet with a couple of spot lights on it, maybe with a plaque under it, explaining how our ancestors used this cutting edge device.

Or you could use it as a paperweight?