[SOLVED] OH3: zwave binding Z-Wave Serial Controller Aeotec Z-Stick Gen5 remains offline

My Aeotec Z-Wave serial controller does not work in OH3. On the same server, I installed OH2 and tested with the same settings and there it works.
Below you find all the relevant information I gathered so far.
If you need additional output, please advice.

Platform information:

Hardware: Intel® Pentium® Silver J5005 CPU @ 2.8GHz
OS: CentOS Linux release 8.2.2004 (Core)
# dmesg | grep tty
[   10.134643] cdc_acm 1-2:1.0: ttyACM0: USB ACM device
# lsusb
Bus 001 Device 004: ID 0658:0200 Sigma Designs, Inc. Aeotec Z-Stick Gen5 (ZW090) - UZB
# ll /dev | grep tty
crw-rw-rw-. 1 root dialout 166,     0 Nov 13  2020 ttyACM0
lrwxrwxrwx. 1 root root             7 Nov 13 10:28 ttyUSB-ZStick -> ttyACM0

/etc/udev/rules.d/99-usb-serial.rules

SUBSYSTEM=="tty", ATTRS{idVendor}=="0658", ATTRS{idProduct}=="0200", SYMLINK+="ttyUSB-ZStick", GROUP="dialout", MODE="0666"

Test1:
Java Runtime Environment: OpenJDK 64-Bit Server VM (build 25.272-b10, mixed mode)
OH: openHAB version: openHAB 2.5.10 Release Build

/etc/default/openhab2

EXTRA_JAVA_OPTS="-Dgnu.io.rxtx.SerialPorts=/dev/ttyUSB-ZStick"

Steps:

Test2:
Java Runtime Environment: openjdk version “11.0.9” 2020-10-20 LTS
OH: openHAB version: openHAB 3.0.0.M2

/etc/default/openhab (OH3)

EXTRA_JAVA_OPTS="-Dgnu.io.rxtx.SerialPorts=/dev/ttyUSB-ZStick"
  • fresh install OpenHAB 3.0.0.M2
  • added zwave binding
  • added Z-Wave Serial Controller (default settings)
    -> Port Configuration (dropdwon Serial Port NOT available)
    -> added /dev/ttyUSB-ZStick manually (tested the same with )
    Bridge appears offline in GUI

Debug log:

2020-11-13 10:58:11.148 [DEBUG] [g.zwave.internal.ZWaveConfigProvider] - No thing found in getConfigDescription thing:zwave:serial_zstick:53d1f7a07d
2020-11-13 10:58:11.180 [DEBUG] [wave.discovery.ZWaveDiscoveryService] - Creating ZWave discovery service for zwave:serial_zstick:53d1f7a07d with scan time of 60
2020-11-13 10:58:11.181 [DEBUG] [wave.discovery.ZWaveDiscoveryService] - ZWave discovery: Active zwave:serial_zstick:53d1f7a07d
2020-11-13 10:58:11.182 [INFO ] [zwave.handler.ZWaveControllerHandler] - Attempting to add listener when controller is null
2020-11-13 10:58:11.214 [DEBUG] [ing.zwave.handler.ZWaveSerialHandler] - Initializing ZWave serial controller.
2020-11-13 10:58:11.216 [DEBUG] [zwave.handler.ZWaveControllerHandler] - Initializing ZWave Controller zwave:serial_zstick:53d1f7a07d.
2020-11-13 10:58:11.217 [DEBUG] [zwave.handler.ZWaveControllerHandler] - No network key set by user - using random value.

Might be unrelated but worth a try.
As you read in the prerequisites, we recommend using Azul Zulu , there are some issues with OpenJDK.

@hmerk
Thanks for the hint. Could you please tell me where the prerequisites are listed ?

Here

1 Like

I saw that, but there are only issues with arm architecture linked. My platform is x86_64 driven.
My issue can be caused by the different JDK’s, sure. But as I know, OpenJDK11 is fully supported and recommended for OH3.

Ups, I’m wrong:
OpenJDK may also be used, but it has some known limitations with openHAB and is not recommended
SoI’ll test Azul Zulu and report back

I installed Azul OpenJDK

# java -version
openjdk version "11.0.9.1" 2020-11-04 LTS
OpenJDK Runtime Environment Zulu11.43+55-CA (build 11.0.9.1+1-LTS)
OpenJDK 64-Bit Server VM Zulu11.43+55-CA (build 11.0.9.1+1-LTS, mixed mode)

But I still get the same issue:

2020-11-13 15:27:18.278 [DEBUG] [wave.discovery.ZWaveDiscoveryService] - Creating ZWave discovery service for zwave:serial_zstick:ca9eb3d9f8 with scan time of 60
2020-11-13 15:27:18.279 [DEBUG] [wave.discovery.ZWaveDiscoveryService] - ZWave discovery: Active zwave:serial_zstick:ca9eb3d9f8
2020-11-13 15:27:18.279 [INFO ] [zwave.handler.ZWaveControllerHandler] - Attempting to add listener when controller is null
2020-11-13 15:27:18.289 [DEBUG] [ing.zwave.handler.ZWaveSerialHandler] - Initializing ZWave serial controller.
2020-11-13 15:27:18.290 [DEBUG] [zwave.handler.ZWaveControllerHandler] - Initializing ZWave Controller zwave:serial_zstick:ca9eb3d9f8.

Should I open a bugreport in

1 Like

For me Aeotec Z-Wave USB normaly work On Ubuntu 20.4, zulu java 11.0.9 and openhab 3.0.0M2 …

openjdk version “11.0.9” 2020-10-20 LTS
OpenJDK Runtime Environment Zulu11.43+21-CA (build 11.0.9+11-LTS)
OpenJDK 64-Bit Server VM Zulu11.43+21-CA (build 11.0.9+11-LTS, mixed mode)

strange, I enabled

log:set DEBUG org.openhab.core.io.transport.serial 

additional output

2020-11-13 16:35:16.575 [DEBUG] [ort.serial.internal.RxTxPortProvider] - No SerialPortIdentifier found for: /dev/ttyUSB-ZStick

I enabled now a workaround using ser2net service

dnf install ser2net

vi /etc/ser2net.conf
deleted the whole content and added only this line

3001:telnet:0:/dev/ttyACM0:115200 8DATABITS NONE 1STOPBIT remctl
systemctl enable ser2net
systemctl start ser2net

Port configuration:

rfc2217://127.0.0.1:3001
1 Like

@chris
Do you have some hints what i can do (e.g. add some debug to other classes) to find the root cause of my issue with the OH3 zwave binding?

Sorry - not really. The issue seems to be with the serial port configuration as far as I can see. I also don’t use RFC2217 so can’t help you there.

@chris the ser2net config is working (as a workaround).
Could you please have a look in the 1st post. There is the main issue described. The binding is working in OH2 but not in OH3 on the same server.

To be honest I’ve no idea what problem you’re reporting - you just say -:

There’s no real information on what doesn’t work - you’ve provided a bunch of information showing he USB config etc which is not in any way linked to the binding. If you provide a debug log from the binding, I will take a look, but it’s hard to know what your issue really is at the moment - it seemed to me that it was a serial port issue with all the discussion around this.

@chris

in the 1st post Test 2

added Z-Wave Serial Controller (default settings)
→ Port Configuration (dropdwon Serial Port NOT available)
→ added /dev/ttyUSB-ZStick manually (tested the same with )
Bridge appears offline in GUI

Debug log:

2020-11-13 10:58:11.148 [DEBUG] [g.zwave.internal.ZWaveConfigProvider] - No thing found in getConfigDescription thing:zwave:serial_zstick:53d1f7a07d
2020-11-13 10:58:11.180 [DEBUG] [wave.discovery.ZWaveDiscoveryService] - Creating ZWave discovery service for zwave:serial_zstick:53d1f7a07d with scan time of 60
2020-11-13 10:58:11.181 [DEBUG] [wave.discovery.ZWaveDiscoveryService] - ZWave discovery: Active zwave:serial_zstick:53d1f7a07d
2020-11-13 10:58:11.182 [INFO ] [zwave.handler.ZWaveControllerHandler] - Attempting to add listener when controller is null
2020-11-13 10:58:11.214 [DEBUG] [ing.zwave.handler.ZWaveSerialHandler] - Initializing ZWave serial controller.
2020-11-13 10:58:11.216 [DEBUG] [zwave.handler.ZWaveControllerHandler] - Initializing ZWave Controller zwave:serial_zstick:53d1f7a07d.
2020-11-13 10:58:11.217 [DEBUG] [zwave.handler.ZWaveControllerHandler] - No network key set by user - using random value.

and in this post additional debug log:

is this not enough information?

I saw this, but unfortunately 6 lines of logging does not make a debug log :wink: . It’s impossible to know what is going on - there is very little information, and I see no errors.

The 6 line log is absolutely not enough - no. The extra one line doesn’t really help a lot and I had seen this already, but reinforces my original comment that the problem is a serial port issue since the binding reports that there is an error finding the serial port.

there is no more debug log from the zwave binding at all.
issue: zwave bridge does not comes online
it works on the same server with OH2 and openjdk8

sorry. but i thought i provided as much information as possible. and if there are no more logs then i can not povide more.

Ok, that’s fine - thanks. This leads me back to my original response then.

ok, in pictures

The bridge does not come online in OH3, but on the same server with OH2 is works.

And I asked:
“Do you have some hints what i can do (e.g. add some debug to other classes) to find the root cause of my issue”

Why does it work in OH2 and no longer in OH3 on the same HW and OS ?
What can I do (debugging) to get more information ?

Sure - I know what OFFLINE means - both as text and as an image :wink:

Understood - it’s OFFLINE - I got that already :wink:

I’m sorry - but I don’t know. All I can say is what I’ve already said a couple of times. Based on the information I can see, the issue seems to be that the binding cannot open the serial port. Serial port access isn’t really part of the binding - it’s handled by a serial abstraction layer. Secondly, as I’ve said, I don’t use RFC2217, and I know people have problems with this.

I’m sorry - I really don’t know how else to help you. You seem to keep repeating the same question - probably you think I’m being difficult, or hiding information, but that’s not the case. From the binding perspective, it just tries to open the serial port - if this fails, there’s not a lot more that it can do, and I don’t have any other information that can really help.

Ok, then it must be a Bug in OH3 serial port handling.
I can live with that as I have a workaround.

So I then mark this topic a solved.