Getting goControl WA00Z-1 to controlZooz Zen52 double relay

X86_64 OMV 6 OS running Openhab Docker latest set up per instructions on OH website/github
i5-4590 with 16gb ram - docker container running on host network - /dev/ttyusb items for nortek combo stick passed thru to container which is also set as privileged.
GitHub - hotrodwinston/homeserverstack: a short list of my configs for setting up a home media/file server for more info on my setup
My setup was recreated from scratch a few months (and again a few days ago due to an issue with my server) ago and I set everything up in the model as opposed to the old method of linking “items” to “things” but I understand the item/thing setup since I have been running OH since 2018 . I have worked to not have any items configured thru an item text file so I can control and edit everything in the UI. All links to outside services (google assistant etc.) are handled thru the model metadata tags.

I installed a Zen52 double relay and it works great but I want to add a remote to turn on each of the relays independently. I do have a couple of goControl WA00Z-1 remotes but unsure how to make one turn on relay 1 and the other turn on relay 2. I tried setting a rule to watch for the scene number to change but it didn’t work (this method hasn’t worked for any rules since I moved off of the raspberry pi middle of last year)
Settings for the remote are per https://github.com/openhab/org.openhab.binding.zwave/blob/main/doc/linear/wa00z1_0_0.md and are set as follows:
Param 1 : 0
Param 2 : 1
Param 4 : 0

I suggest changing your title, as this seems to be more about the GoControl remote than the Zen52. I thought this would be a “how do I get this Z-Wave device working” post. :wink:

I’m not sure why the Raspberry Pi would make a difference to a rule. The scripting method remains the same regardless of platform. What doesn’t work?

Here’s a DSL rule I use for the six scene commands that can be triggered by a GoControl remote. Remote_Blinds is a number item.

rule "Control blinds with Z-Wave remote"
when
    Item Remote_Blinds received update
then
    switch (Remote_Blinds.state)
    {
        case 1.0 : //single click
        {
            //do stuff
        }
        case 1.2 : //press and hold
        {
            //do stuff
        }
        case 1.1 : //release after hold
        // {
            //do stuff
        // }
        case 2.0 : //single click
        {
            //do stuff
        }
        case 2.2 : //press and hold
        {
            //do stuff
        }
        case 2.1 : //release after hold
        // {
            //do stuff
        // }
    }
end

That’s what I figured too but I had a rule that said if switch 2 changed to scene 1 then turn lamp on and a second rule that said if switch 2 changed to scene 2 then turn the lamp off. It worked fine on my Raspberry Pi, but then I set up my server and the rule won’t work. I will admit I set up my server from scratch rather than importing a backup because I had a bunch of bugs from trying things in OH since 2018 (I tend to tinker) and just wanted a fresh start (I even played with home assistant on both the pi and the server for a bit but didn’t like it so came back to OH)

I really just don’t understand what is not working on the rules and I can’t just associate the GC remote with the Zooz relay as it turns on both relays and that’s not the behavior I want.

I’m just guessing/checking :wink: Are your items linked to endpoint 1 and endpoint 2 channels. Typically EP 0 will turn both on

Association in the thing settings will only allow me to associate them with a node not an endpoint.

I’m getting a little confused between your two posts, so let’s make sure we’re on the same page. As I understand it, you want to use one GoControl remote to toggle one of the relays in your ZEN52. Sticking with Rules DSL:

rule "Control Relay 1 of ZEN52 with GoControl remote"
when
    Item GoControl_Remote_1 received update
then
    switch (GoControl_Remote_1.state)
    {
        case 1.0 : //single click
        {
            relay1.sendCommand(ON)
        }
        case 2.0 : //single click
        {
            relay1.sendCommand(OFF)
        }
    }
end

If this rule triggers both relays in the ZEN52, then something is wrong with your items.

  1. You’ve linked your item to a channel that controls both relays (which I think is what @apella12 is suggesting)
  2. Your item is accidentally linked to both relay channels
  3. There’s a configuration issue with the thing that’s causing one relay to follow the other one.

If your item appears to be fine, then I suggest creating a brand new one with a completely different name, and testing with that. If the problem persists, then it’s a configuration issue in the thing.

As @rpwong notes this need to be done in a rule with separate items linked to different channels. The Association group trigger will go to EP 0 and trigger both switches ON.

1 Like

So I need to create items not just points in the model?
Then use the rule you posted with the item names from my setup?

I really don’t understand the DSL syntax. I have always used the basic rule editor but I can give this a try.

I don’t use the model, so I can’t comment on it.

In the future, I’d encourage you to post more detail from your system/configuration to help us understand what’s actually in place. I don’t know what your old rule looked like when it worked, or what it looked like when you recreated it in the new system.

Don’t worry about DSL if you use UI rules. I just copied and pasted from my rules, but it’s easy to do in a UI rule. A case statement is just an if statement that handles multiple scenarios at once:

  • If GoControl_Remote_1 changes to 1.0, turn on relay1
  • If GoControl_Remote_1 changes to 2.0, turn off relay1
1 Like

Sorry for the long silence - my server had issues and then I had issues and now I’m setting everything back up and got back to this problem.

I tried making rules in the UI but they won’t work properly. My goal is to have one of the WA00Z control Relay 1 and the other control Relay 2. To that end I tried to make a rule to have remote number 2 turn off Relay 1 if the bottom button is pressed (also made a separate rule for the opposite) and when I press it nothing happens.

configuration: {}
triggers:
  - id: "1"
    configuration:
      itemName: WA00Z1_Remote_2_Scene_Number
      state: "2"
      previousState: ""
    type: core.ItemStateChangeTrigger
conditions: []
actions:
  - inputs: {}
    id: "2"
    configuration:
      itemName: Living_Room_Ceiling_Switch_1
      command: OFF
    type: core.ItemCommandAction

How can I re-write this to have it do what I need? - note that I didn’t write this code I used the UI and then copied the code. also my settings for the remote are per https://github.com/openhab/org.openhab.binding.zwave/blob/main/doc/linear/wa00z1_0_0.md and are set as follows:
Param 1 : 0
Param 2 : 1
Param 4 : 0
If changes need to be made to the settings of the remote please let me know. I am not just after a quick fix but want to understand how the setup works so I can apply the principles to future problems if needed. Will edit op with more info about setup and feel free to ask questions.

It might be easier to use the association group, if you are just looking for on off. Do the relays show as separate when try to add to the association groups?

1 Like

I see a few issues. First:

Is this the actual state that’s reported by your WA00Z-1? I’m fairly sure it isn’t. If you look in your log, I expect it will say something like:

Item 'WA00Z1_Remote_2_Scene_Number' changed from 1.0 to 2.0

2 does not equal 2.0. You need an exact match to trigger the rule.

Second:

I believe that this will only trigger the rule if the previous state was null, but that’s probably not the case. If you previously used the WA00Z-1, its state is whatever button event you last used.

You don’t know what the previous state was…and you don’t actually care. So you can just remove this bit.

That being said, the previous state does come into play with the third issue:

In this particular case, you can’t rely on item changes, because the state might not actually change:

  1. You use the remote to turn off the light (state = 2.0)
  2. You use the wall switch to turn on the light
  3. You use the remote to turn of the light again (state = 2.0)

In this scenario, the remote doesn’t change state the second time you used it, because it was already 2.0. So, you need to trigger your rule on state updates to ensure you get every single button press.

Whenever you have equipment that’s not binary (ON/OFF), state updates may be more valuable than changes. You need to look at the actual behaviour of the device to determine how best to use it in rules.

This should give you a rule that looks like this:

configuration: {}
triggers:
  - id: "1"
    configuration:
      itemName: WA00Z1_Remote_2_Scene_Number
      state: "2.0"
    type: core.ItemStateUpdateTrigger
conditions: []
actions:
  - id: "2"
    configuration:
      itemName: Living_Room_Ceiling_Switch_1
      command: OFF
    type: core.ItemCommandAction
1 Like

@apella12 unfortunately the association group only shows node 14 which is all on or all off not independent relay control.

That is what I was missing. I kept using state change, which automatically added the previous state condition in the designer. The rule you wrote worked fine and for the turn-on rule, I swapped in the correct values and got that working.
Thank you so much.