Z-Wave Items and Channel/Item Linking Confusion in OH2

Hi, Y’all,

I can’t seem to find a way to provide the equivalent of Z-Wave scene/key functionality in OH2. E.g., the HomeSeer WS100+ allows multiple taps on the switch paddle to cause different scene activation. In OH1/ZW1.9, the item would be specified like this:

Switch  GarageLights        "Garage Lights"				{ zwave="15:command=SWITCH_BINARY,refresh_interval=60" }
Number  GarageLights_1TU	"Garage Lights_Scene 1TU"   { zwave="15:command=CENTRAL_SCENE,scene=1,key=0" }
Number  GarageLights_2TU	"Garage Lights_Scene 2TU"   { zwave="15:command=CENTRAL_SCENE,scene=1,key=3" }
Number  GarageLights_3TU	"Garage Lights_Scene 3TU"   { zwave="15:command=CENTRAL_SCENE,scene=1,key=4" }
Number  GarageLights_1TD	"Garage Lights_Scene 1TD"   { zwave="15:command=CENTRAL_SCENE,scene=2,key=0" }
Number  GarageLights_2TD	"Garage Lights_Scene 2TD"   { zwave="15:command=CENTRAL_SCENE,scene=2,key=3" }
Number  GarageLights_3TD	"Garage Lights_Scene 3TD"   { zwave="15:command=CENTRAL_SCENE,scene=2,key=4" }

(NB: An item receives an update when its corresponding multi-tap takes place. Rules can then take advantage of these updates to do clever things.)

Unfortunately, after the Thing is found in OH2, the only relevant channels that show up are two channels called Scene Number with no further descriptions or options:

Which of these is the correct channel? Is there any difference between the two?

I’ve done my best Googling and have come up dry, so any help you can provide will likely be useful for many others to come.

(I do love the fact that I have OH1 on one SD card and OH2 on the other, so swapping cards WOW THOSE THINGS ARE TINY is all that’s required to revert to my old installation. Highly recommend this path to anybody considering going from OH1 to OH2 as long as your eyesight and manual dexterity are both in good shape.)


[Edited based on the details found in this post. Whereas I assumed, before and incorrectly, that there would be one channel created per scene and key combination, it seems that the channel passes the scene and key back as a single decimal value in the form scene.key.]

Look at my post you linked to at the bottom of your’s.
You will want to set a single Number Item to your “Scene Number” Channel.

Scene Number channels are reported back as a complete digit.decmial value depending on the number of presses and if up or down.

Here is what you need:


Number vDimmer_Scene "Driveway Soffit Lights_Scene" { channel="zwave:device:159a54632e2:node2:scene_number" }


rule "Homeseer WD-100+ Single/Double/Tripple Tap Scene Control"
    Item vDimmer_Scene received update
	switch(vDimmer_Scene.state) {
		case 1.0 : {							/* Single Tap ON */
			logInfo("RULE.DIMMER", "Single Tap: ON")
		case 1.3 : {							/* Double Tap ON */
			logInfo("RULE.DIMMER", "Double Tap: ON")
		case 1.4 : { 							/* Tripple Tap ON */
			logInfo("RULE.DIMMER", "Tripple Tap: ON")
		case 2.0 : {							/* Single Tap OFF */
			logInfo("RULE.DIMMER", "Single Tap: OFF")
		case 2.3 : {							/* Double Tap OFF */
			logInfo("RULE.DIMMER", "Double Tap: OFF")
		case 2.4 : { 							/* Tripple Tap OFF */
		   logInfo("RULE.DIMMER", "Tripple Tap: OFF")

Then just put your logic within each case #.# depending what you want to do when a specific scene is pressed. To the right is a comment what each value is for (# of taps and if on or off)

Thanks, Chris, but how did you handle the multiple “Scene Number” channels? I have two of 'em as shown in the picture. Did you have two, or just one?

Whoops, missed the Item definition in what you wrote. But that seems very OH1. Is there a more OH2-centric way of accomplishing the same thing while dealing with the duplicate Scene Numbers (if they’re more widespread than in my installation, that is)?

I just have one… what does PaperUI show you?

@billeccles - I think I saw this randomly a few times myself when I was first setting this up. Most instances, it was a matter of reloading HABmin and the second one would go away. If that doesn’t happen, then maybe there is a secondary scene component. What I’ve often found (particularly things like Thermostats and the Astro binding) - is that you can just click to add an item to the channel in HABmin, and the new item screen will give you more information in the Name field about WHAT exactly it is. Often times I’d have something like Cooling Setpoint Cooling Setpoint, but one is really heating. The name would populate with the THING ID which outlines cooling_setpoint_heating cooling_setpoint_cooling.

Astro is huge culprit of this. All channels are the same 4 names, but each individual channel has a different THING ID under the covers that you have to see to understand the channel.

But as @Python mentioned, I only had one. HABmin was causing the issue though with missing information at times, duplicates, lack of item connections at times, etc. If something looks odd, I usually reload when using HABmin.

Wanted to report back here as I think I’ve found the answer to your question. I stumbled upon this as I was researching an issue I had with one of my switches. I didn’t notice this nuance before, but I would make a bet it’s the reason why and the difference for why I’ve found more than one Scene Number channels in HABmin, and in PaperUI for that matter. This is just my speculation, but I believe it’s because the Switch actually has another function that I wasn’t aware of. You can apparently do 1/2/3 taps, but you can also do press and hold action. Seems they left the code mostly the same in terms of what the values are (1.2->1.1 for prerss+hold up, 2.2->2.1 for press+hold down). These codes are the same as the dimmer when using the paddle to change the dim levels.

I highlighted below the comparison between the WD and WS devices in the database, and there is one extra component in there. I may be pulling this out of my ass, but I’ve confirmed it is only the WS devices (switches) that have this 2 Scene Number issue. But the valuable thing I have validated, is it doesn’t matter which one you map to apparently. It seems as though they both are actually sharing/showing the same detail. Using the API view, I can see the UID of the channel, is exactly the same on both Scene Number items. So I’d chock this up to a weird bug in how it’s showing in OH, and not be concerned about using one over the other.

When I figured this out, I just had to share since I know it was asked. Took a bit of searching to find the thread, but glad I did. Hope this helps educate and inform the value (I believe) of the two channels appearing. Additionally, it helped me identify the use of the until now, missing 1.1/1.2/2.1/2.2 values for scenes. Now I can achieve something else I was looking to do by letting the switch change over to these seemingly unused values if not using this special function. I’d also imagine this means you could build out a sort of virtual dimmer button in HABpanel and others if you map the command to send scene 1.2/2.2 upon press, and 1.1/2.1 upon release. Just spitballing here though.