Does the new Z-Wave JS support this? I have a Zwave Scene Switch in which I used to use this to monitor for events. I can’t seem to find the new one, if it exists at all.
I’m trying to find the same thing. Can’t make it work on new Z-Wave JS
A kind soul on Reddit had me try zwave_js_event and that worked. Some of the results are a bit different, but nothing you can’t translate over.
I have replace my ozw.scene_activated by zwave_js_event but my dimmer doesn’t work. It looks like it’s getting something but not the same as ozw.scene_activated. do I need to add something else?
I have a NodOn Soft Remote switch that I was using in an automation with ozw.scene_activated in the OZW OpenZwave beta. I’ve been trying out the Z-Wave JS integration today, and I’m not seeing zwave_js_event in the list of services provided by Z-Wave JS.
Is there something else I should be using, or do I simply wait until Z-Wave JS has matured some more? Thanks.
Here is how I’m using it in automations until it gets better native support in the new Z-Wave JS. Your situation might be different than mine, but you might be able to use it in an automation or script. You may already know/do this and I’m not helping at all.
- Go to Configuration, Developer Tools, Events and Listen to events. Use zwave_js_event here.
- Toggle your switch and watch the output. If you have more than 1 button, go ahead a trip that too.
- The output will list what is being sent. Find a couple of unique items and make note.
- For a Trigger in an Automation use Trigger Type: Event, Event: zwave_js_event
- For Event Data put in those unique items you noted, usually without the quotes. Here’s mine from a two button scene controller when button 1 is pressed:
label: Scene 001
node_id: 49
value: KeyPressed
Button 2 would be the same but it would be Scene 002 above.
Your device might show this differently, but the idea to watch for unique items is the same. You don’t need everything it shows you, but node_id - which device and a couple of values will make sure it doesn’t trigger on something else.
Thanks very much for your help. It solved the issue for me. I’ve now got the buttons working!
Thank you all for posting this. I’ve been patiently waiting for scene support and finally was able to set the last thing I’ve been waiting on. Thanks!
Does this also work for the fibaro roller shutter 2?
Like I typed here:
Hi there.
I’m wondering if you can steer me in the right direction. I’ve just migrated to Z-Wave JS and everything went pretty smoothly - except for the Aeon Minimote that I’ve got. It took me forever to get it paired and then just as long to figure out where to look for commands from it. I finally figured out that I should listen to “zwave_js_value_notification” to see events from it. The output looks like this:
{
"event_type": "zwave_js_value_notification",
"data": {
"domain": "zwave_js",
"node_id": 33,
"home_id": XXXXXXXXX,
"endpoint": 0,
"device_id": "XXXXXXXXXX",
"command_class": 43,
"command_class_name": "Scene Activation",
"label": "Scene ID",
"property": "sceneId",
"property_name": "sceneId",
"property_key": null,
"property_key_name": null,
"value": 1,
"value_raw": 1
},
"origin": "LOCAL",
"time_fired": "2021-04-15T01:20:31.418444+00:00",
"context": {
"id": "b2624946e33dc145c95d82c1654ca81e",
"parent_id": null,
"user_id": null
}
}
I’ve determined that the “value” and “value_raw” correspond to the button pressed. But now I have no idea how to translate that to my automation from the previous integration, which looks like this:
alias: Minimote Button Pressed or Held
trigger:
- platform: event
event_type: zwave.scene_activated
event_data:
entity_id: zwave.minimote1
action:
- service: homeassistant.toggle
data_template:
entity_id: |-
{% set map = {1: 'switch.bed_light',
2: '',
3: 'switch.dome_light',
4: '',
5: 'light.bedroom',
6: '',
7: 'fan.bedroom',
9: ''} %}
{{ map[trigger.event.data.scene_id|int] }}
mode: single
I think I have to change the event_type to “ zwave_js_value_notification” but then I’m kinda stuck. I copy and pasted this original automation from somewhere else when I first set up Home Assistant a few months ago.
Sorry for the long-winded post, but I figured it was best to give as much information as possible. Any help provided will be greatly appreciated!
Disregard the above message. I was able to tweak it and get it going. For future reference for anyone looking for the same solution, here’s the autiomation code that worked for me:
alias: Minimote Button Pressed or Held (New)
trigger:
- platform: event
event_type: zwave_js_value_notification
event_data:
node_id: 33 ##Node number of your Minimote goes here.
action:
- service: homeassistant.toggle
data_template:
entity_id: |-
{% set map = {1: 'switch.bed_light', ##Put the entity IDs of the device you wish to control with each button.
2: '',
3: 'switch.dome_light',
4: '',
5: 'light.bedroom',
6: '',
7: 'fan.bedroom',
9: ''} %}
{{ map[trigger.event.data.value_raw] }} ##Value_raw corresponds to the button press that triggered the event.
mode: single
Odd numbers are button presses, even are press and hold. Hope this helps someone!
Also manage to get this to work. Thanks for the early work on this. Here’s my simple automation that turns on a light when the second button of a Fibaro Dimmer 2 is held and generates scene 22
alias: Carport Light on Motion
description: ''
trigger:
- platform: event
event_type: zwave_js_value_notification
event_data:
node_id: 7
value_raw: 22
condition: []
action:
- type: turn_on
device_id: 9d22d4829d36c59c132f84b5f452d3b4
entity_id: light.fibaro_dimmer_2
domain: light
mode: single
Thank you, thank you, thank you for this thread! I had spent an hour looking in the documentation and messing around, but I couldn’t find anything about this, so my bunch of Namron 4 channel wall switches/dimmers were useless. Now I have the regular press down.
Now I only need to fix the long presses. On my automations from the OZW implementation it was a separate scene for long presses, but if I understand this correctly I will need to use value raw. I’ll probably manage.
is this solution still working? Can’t get mine to trigger.
Even with all the great info here and in the docs it took me a while to get it working. So for future reference:
My situation: HA with Zwave JS integration + Zwavejs2mqtt in docker. Aeotec Z-stick gen5. Fibaro Dimmer 2 FGD212, Fibaro Switch 2 FGS223.
- Learned that the devices don’t send Zwave events in normal, default, use. Just state_changed. This is unclear in the docs.
- Needed Re-Configuring the devices to send SceneID. (Config was reset?).
- Dimmer: Enable parameter 28 in Zwavejs2mqtt. https://manuals.fibaro.com/dimmer-2/#:~:text=Scene%20activation%20functionality
- Switch 2: Can only enable or disable sending SceneID 1 for S1 of SceneID 2 for S2 with parameters 28 and 29, https://manuals.fibaro.com/switch-2/#:~:text=Activating%20scenes but you can look at the “value” value in the event data and see what was done to the button.
So after getting the device re-configured I could see the events when listening to zwave_js_value_notification events. And use the data to create automations.
Hope this helps anyone in the future.