Zwave add new device to OH 2.4 stable

Tags: #<Tag:0x00007f4332268e10> #<Tag:0x00007f4332268be0> #<Tag:0x00007f4332268b18>

Hi,
I read through a number of posts, and I understood that

  1. probably a zwave snapshot build would not work reliable on an OH 2.4 stable release.
  2. There is no way to update the zwave database, except for installing the latest zwave binding.

So, if I want to stay on a stable OH release (2.4 atm), but also want to use the “devolo wall switch” I added to the zwave database there seems to be no migratrion path for this, is this correct?

  • Wouldn’t it be possible to build a zwave 2.4 binding with the latest database content?
  • Can I do it locally if there is no way to do it in your build processing?

In case there is no possibility, when will the current zwave database be part of a stable release (2.5?) and when is it planned for public release?

Thanks
Markus

you can do this and there is a thread on how to do it somewhere, if I can find it I will post it

that would be great

No.
The database is part of the zwave binding and you can run the latest binding on 2.4. There is a script that can help you do this. The developer of the binding actually recommends people run a newer binding.
Here is the script that also includes how to update it manually.

1 Like

I think it would. At least it’s worth trying.

PS: and why don’t you move to latest milestone or at least 2.5M1.

I am afraid of un-stable behavior or bugs, especially on zwave and modbus bindings that I use a lot. Is the 2.5 M1 reliable?

Generally speaking yes, but the only way to find out is to use it.

ok, I did a backup of my current instllation and I might try today…
one more question: Can I find out (in the repo ?) if my device which I added like two days ago is already contained in the latest snapshot build of the zwave binding?
Where can I find the zwave development branch in the code repository?

Ok, zwave has a separate repo. I found my new device xml file there in
src/main/resources/ESH-INF/thing/devolo/mt2759_0_0.xml

Just a word of warning - depending on the device, you should not expect to just add an XML to the binding, and for the device to work. It might, but it will depend on what features it requires in the binding - the code and the database are typically kept together for this reason.

If it’s a simple/standard featured device, then this should work to use it in 2.4 though.

Hi Chris,
thanks for the hint.
I am still considering if I

  • upgrade to OH2.5M1 and the use the latest zwave binding
  • stay on OH 2.4 and try to install the latest zwave binding
  • use the 2.4 zwave binding and add the xml file

It is just a wall switch of devolo, very similar to the scene switch which already exists and works… so I would guess the existing code should be able to handle this xml file.

Yes - it should be fine in this case.

ok, so would you agree that the the fastest and less risky way for my “productive” system might be to rebuild the zwave 2.4 binding locally and add this 1 xml file?
I bought the devolo device but cannot test it, but I plan to buy more of them if they work fine with OH2.

Actually, the latest testing, just released, is 2.5M3. I have been running 2.5M2 since it came out with no major issues. The main issue I have heard of ( & still in 2.5M3) is some addons conflicting with the RESt API docs.
@chris, the developer for the zwave & zigbee bindings strongly recommends using a 2.5 binding.

Possibly - somewhere there is a description from @5iver of how to edit a JAR to add an XML file. I looked for it earlier but couldn’t find it (I should bookmark it!). Maybe Scott can point this out as I would suggest that this is the easiest and safest way.

Compiling your own binding should also work, and if you have an IDE that works for 2.4, then fine, but there are a lot of issues getting the IDE working now and a LOT has changed since 2.4 was released.

This is true - and 2.5 does improve the handling of associations to try and add more automation into their configuration, but if you have a working 2.4 that you’re happy with, then it’s probably safer to just add the XML.

I’m not 100% sure that you can run the 2.5 binding with 2.4 - I think there were some changes that might make it incompatible, but it was a long time ago, so I’m just not sure.

I think I found it: Modify a zwave binding jar to add/change a zwave device while waiting for a build

1 Like

Here you go…

2 Likes

any hint from where to download the org.openhab.binding.zwave-2.4.0.jar?

Thank you all!
I finally managed it!

In case anyone else is interested in how to do this I summarize my steps below:

  1. Deinstalled zwave binding via PaperUI
  2. Download the zwave-binding jar of OH 2.4 from JFrog:
    https://openhab.jfrog.io/openhab/webapp/#/artifacts/browse/tree/General/bintray-openhab/org/openhab/binding/org.openhab.binding.zwave/2.4.0/org.openhab.binding.zwave-2.4.0.jar
  3. Download the xml file from the zwave database (in my case I added a new device)
    Either from Chris’ ZWave database directly
    https://github.com/openhab/org.openhab.binding.zwave/blob/master/src/main/resources/ESH-INF/thing/devolo/mt2759_0_0.xml
    or from the gitlab latest build
    src/main/resources/ESH-INF/thing/devolo/mt2759_0_0.xml
    https://github.com/openhab/org.openhab.binding.zwave/blob/master/src/main/resources/ESH-INF/thing/devolo/mt2759_0_0.xml
  4. Copy org.openhab.binding.zwave-2.4.0.jar to a working directory and create the sub-structure (as described here Modify a zwave binding jar to add/change a zwave device while waiting for a build)
 |_ [working directory where jar was downloaded to]
     |_ ESH-INF
         |_ thing
             |_ [vendor]
  1. Updated the jar file with the new xml
    jar -uf org.openhab.binding.zwave-2.4.0.jar ./ESH-INF/thing/devolo/mt2759_0_0.xml
  2. Copied the jar file to the addons directory
    sudo cp org.openhab.binding.zwave-2.4.0.jar /usr/share/openhab2/addons/
  3. Waited for (re-)start of binding

Everything works fine now…
Thanks to all!

1 Like