Leviton Scene Controller - Working Automation

I was finally able to get the Leviton Scene Controllers to work, although still not 100% ideal.
I have a RZCS4-1L scene controller, but this should be the same configuration for the VRCS4-1L (as the RZCS is the older, 9600 bps version). I am unsure how well this would work for the Zone Controllers, as they have two discrete buttons for each scene.

As OZW does not have an XML for this device, you will need to set the association of groups 1,2,3,4 with your controller (typically node 1). Group 1 should already be associated with your controller by default. This ensures that the scene controller will send back the scene activated message to your controller.

Note that you can also do a few other things with the Leviton scene controller – if you set an additional group association to the node for dimmer switch, the dim buttons on the bottom will control that dimmer; independent of OZW (when the relevant scene button is enabled – group 1 for button 1, and so on and so forth).

After that, add the following to your automations.yaml file (replace my devices with your devices). I had to add code to disable and renable the automation (as a debounce timer) as the scene controller sends at least 4 duplicate SceneEvent commands whenever a scene button is pressed.

# Leviton Scene Controller Integration

- alias: Leviton Scene Button 1
  trigger:
    platform: event
    event_type: zwave.scene_activated
    event_data:
      entity_id: zwave.master_bedroom_scene_controller
      scene_id: 1
  action:
    - service: homeassistant.turn_off                    # Disable automation due to multiple scene activated message
      entity_id: automation.leviton_scene_button_1
    - service: switch.toggle
      entity_id: switch.master_bedroom_ceiling_fan
    - delay: '00:00:02'                                  # Wait 2 Seconds
    - service: homeassistant.turn_on                     # Re-enable automation
      entity_id: automation.leviton_scene_button_1

- alias: Leviton Scene Button 2
  trigger:
    platform: event
    event_type: zwave.scene_activated
    event_data:
      entity_id: zwave.master_bedroom_scene_controller
      scene_id: 2
  action:
    - service: homeassistant.turn_off                     # Disable automation due to multiple scene activated messages
      entity_id: automation.leviton_scene_button_2
    - service: switch.toggle
      entity_id: switch.master_bedroom_left_bedside_light
    - delay: '00:00:02'                                   # Wait 2 seconds
    - service: homeassistant.turn_on                      # Re-enable automation
      entity_id: automation.leviton_scene_button_2

- alias: Leviton Scene Button 3
  trigger:
    platform: event
    event_type: zwave.scene_activated
    event_data:
      entity_id: zwave.master_bedroom_scene_controller
      scene_id: 3
  action:
    - service: homeassistant.turn_off                    # Disable automation due to multiple scene activated messages
      entity_id: automation.leviton_scene_button_3
    - service: switch.toggle
      entity_id: switch.master_bedroom_right_bedside_light
    - delay: '00:00:02'                                  # Wait 2 seconds
    - service: homeassistant.turn_on                     # Re-enable automation
      entity_id: automation.leviton_scene_button_3

- alias: Leviton Scene Button 4
  trigger:
    platform: event
    event_type: zwave.scene_activated
    event_data:
      entity_id: zwave.master_bedroom_scene_controller
      scene_id: 4
  action:
    - service: homeassistant.turn_off                    # Disable automation due to multiple scene activated messages
      entity_id: automation.leviton_scene_button_4
    - service: switch.toggle
      entity_id: switch.master_bedroom_snail_light
    - delay: '00:00:02'                                  # Wait 2 seconds
    - service: homeassistant.turn_on                     # Re-enable automation
      entity_id: automation.leviton_scene_button_4

The only issue is that when toggling the same device on/off, you need an extra key press in between. If switching between devices, you don’t need the extra key press (as the controller “disables” one scene and enables another scene). This is because we are only trapping the scene activation event, and when the scene is “deactivated” on the Leviton controller, it sends a NodeEvent message back. However, it doesn’t not look like there is any difference in the NodeEvent message for any of the 4 scenes.

2017-08-03 14:04:11.020 Detail,
2017-08-03 14:04:11.020 Info, Node039, UPDATE_STATE_NODE_INFO_RECEIVED from node 39
2017-08-03 14:04:11.021 Detail, Node039, AdvanceQueries queryPending=0 queryRetries=0 queryStage=Dynamic live=1
2017-08-03 14:04:11.021 Detail, Node039, QueryStage_Dynamic
2017-08-03 14:04:11.022 Detail, Node039, QueryStage_Configuration
2017-08-03 14:04:11.022 Detail, Node039, QueryStage_Complete
2017-08-03 14:04:11.023 Warning, CheckCompletedNodeQueries m_allNodesQueried=0 m_awakeNodesQueried=1
2017-08-03 14:04:11.024 Warning, CheckCompletedNodeQueries all=0, deadFound=0 sleepingOnly=1
2017-08-03 14:04:11.024 Detail, Node039, Notification: NodeQueriesComplete
2017-08-03 14:04:11.070 Detail, Node039,   Received: 0x01, 0x09, 0x00, 0x04, 0x08, 0x27, 0x03, 0x20, 0x01, 0x00, 0xff
2017-08-03 14:04:11.071 Detail,
2017-08-03 14:04:11.071 Info, Node039, Received Basic set from node 39: level=0.  Sending event notification.
2017-08-03 14:04:11.072 Detail, Node039, Notification: NodeEvent
2017-08-03 14:04:11.115 Detail, Node039,   Received: 0x01, 0x09, 0x00, 0x04, 0x08, 0x27, 0x03, 0x20, 0x01, 0x00, 0xff
2017-08-03 14:04:11.121 Detail,
2017-08-03 14:04:11.123 Info, Node039, Received Basic set from node 39: level=0.  Sending event notification.
2017-08-03 14:04:11.123 Detail, Node039, Notification: NodeEvent
2017-08-03 14:04:11.182 Detail, Node039,   Received: 0x01, 0x09, 0x00, 0x04, 0x08, 0x27, 0x03, 0x20, 0x01, 0x00, 0xff
2017-08-03 14:04:11.185 Detail,
2017-08-03 14:04:11.186 Info, Node039, Received Basic set from node 39: level=0.  Sending event notification.
2017-08-03 14:04:11.187 Detail, Node039, Notification: NodeEvent
2017-08-03 14:04:11.265 Detail, Node039,   Received: 0x01, 0x09, 0x00, 0x04, 0x00, 0x27, 0x03, 0x20, 0x01, 0x00, 0xf7
2017-08-03 14:04:11.266 Detail,
2017-08-03 14:04:11.267 Info, Node039, Received Basic set from node 39: level=0.  Sending event notification.
2017-08-03 14:04:11.267 Detail, Node039, Notification: NodeEvent

Thanks for sharing, I’m trying to make this work but I’m running into an issue. When factory defaulted, my Leviton controllers only send scene 1 from button 1. Buttons 2-3-4 don’t send scenes. I -think- that’s programmable, but over my head as to how… How did you get yours to send scenes for the other 3 buttons?

I have the Leviton VRCS4-M0Z included and on scenes seem to be responding

2018-05-31 10:03:41.058 Detail, Node022, Received: 0x01, 0x0c, 0x00, 0x04, 0x00, 0x16, 0x06, 0x91, 0x00, 0x1d, 0x0c, 0x01, 0x00, 0x66
2018-05-31 10:03:41.058 Detail,
2018-05-31 10:03:41.058 Info, Node022, ApplicationCommandHandler - Unhandled Command Class 0x91
2018-05-31 10:03:41.764 Detail, Node022, Received: 0x01, 0x0a, 0x00, 0x04, 0x00, 0x16, 0x04, 0x2b, 0x01, 0x09, 0xff, 0x3f
2018-05-31 10:03:41.765 Detail,
2018-05-31 10:03:41.765 Info, Node022, Received Scene Activation set from node 22: scene id=9 via configuration. Sending event notification.
2018-05-31 10:03:41.765 Detail, Node022, Notification: SceneEvent
2018-05-31 10:04:01.275 Detail, Node022, Received: 0x01, 0x0c, 0x00, 0x04, 0x00, 0x16, 0x06, 0x91, 0x00, 0x1d, 0x0c, 0x05, 0x00, 0x62
2018-05-31 10:04:01.275 Detail,
2018-05-31 10:04:01.275 Info, Node022, ApplicationCommandHandler - Unhandled Command Class 0x91
2018-05-31 10:04:02.065 Detail, Node022, Received: 0x01, 0x09, 0x00, 0x04, 0x00, 0x16, 0x03, 0x20, 0x01, 0x00, 0xc6

I can’t seem to get the off scenes to come through. On scenes in automation work great with the following code
- alias: Kitchen VRCS4-M0Z Scene B1 On
trigger:
platform: event
event_type: zwave.scene_activated
event_data:
entity_id: zwave.kitchen_4_button
scene_id: 9
action:
- service: homeassistant.turn_off # Disable automation due to multiple scene activated message
entity_id: automation.kitchen_vrcs4m0z_scene_button_1
- service: light.toggle
entity_id: light.kitchen_recessed
- service: light.toggle
entity_id: light.kitchen_island_pendants
- service: light.toggle
entity_id: light.kitchen_island_recessed
- service: light.toggle
entity_id: light.kitchen_under_cabinet
- delay: ‘00:00:02’ # Wait 2 Seconds
- service: homeassistant.turn_on # Re-enable automation
entity_id: automation.kitchen_vrcs4m0z_scene_button_1

Any insight on how to get the off scenes to show in OZW_log?

I’ve never been able to get the off scenes to show up. It may be an association thing as well, but I have not really looked. I set my actions as toggle rather than on/off, so the off scenes don’t really matter, but it requires multiple button presses sometimes as per my first pot.

@dlasher In order to get the other scenes to send, you need to manually set the associations for the other scenes as per my first post.

Yea i already associated Group 1 - 4 but that is all i see in the associate list. Did i miss something

I was replying to both replies – I did not see the other post from March until you replied. You have your associations setup properly.

Any way to fire an event on the off push instead of just pushing the button a million times lol