deCONZ - Aqara Opple Wireless Scene Switch - 6 Button

Blueprint to support the Aqara Opple Wireless Scene Switch - 6 Button. Combine actions for all buttons in a single automation.

All buttons support the following actions:

  • Single press
  • Double press
  • Tripple press
  • Hold in
  • Hold release

Blueprint to import:

blueprint:
  name: deCONZ - Aqara Opple - Wireless Scene Switch 6 Button
  description: 'Control anything using Aqara Opple six button remote'
  domain: automation
  input:
    remote:
      name: Remote
      description: Opple remote to use
      selector:
        device:
          integration: deconz
          manufacturer: LUMI
          model: lumi.remote.b686opcn01
    
    # ---------------------------- BUTTON TOP LEFT ----------------------------
    button_top_left_single_press:
      name: Top left button - Single press
      description: Action to run on a single press of the top left button
      default: []
      selector:
        action: {}

    button_top_left_double_press:
      name: Top left button - Double press
      description: Action to run on a double press of the top left button
      default: []
      selector:
        action: {}

    button_top_left_triple_press:
      name: Top left button - Triple press
      description: Action to run on a triple press of the top left button
      default: []
      selector:
        action: {}

    button_top_left_hold_release:
      name: Top left button - Hold release
      description: Action to run when top left button was held in and released
      default: []
      selector:
        action: {}

    button_top_left_hold_in:
      name: Top left button - Hold in
      description: Action to run when top left button is held in
      default: []
      selector:
        action: {}

    # ---------------------------- BUTTON TOP RIGHT ----------------------------
    button_top_right_single_press:
      name: Top right button - Single press
      description: Action to run on a single press of the top right button
      default: []
      selector:
        action: {}

    button_top_right_double_press:
      name: Top right button - Double press
      description: Action to run on a double press of the top right button
      default: []
      selector:
        action: {}

    button_top_right_triple_press:
      name: Top right button - Triple press
      description: Action to run on a triple press of the top right button
      default: []
      selector:
        action: {}

    button_top_right_hold_release:
      name: Top right button - Hold release
      description: Action to run when top right button was held in and released
      default: []
      selector:
        action: {}

    button_top_right_hold_in:
      name: Top right button - Hold in
      description: Action to run when top right button is held in
      default: []
      selector:
        action: {}

    # ---------------------------- BUTTON MIDDLE LEFT ----------------------------
    button_middle_left_single_press:
      name: Middle left button - Single press
      description: Action to run on a single press of the middle left button
      default: []
      selector:
        action: {}

    button_middle_left_double_press:
      name: Middle left button - Double press
      description: Action to run on a double press of the middle left button
      default: []
      selector:
        action: {}

    button_middle_left_triple_press:
      name: Middle left button - Triple press
      description: Action to run on a triple press of the middle left button
      default: []
      selector:
        action: {}

    button_middle_left_hold_release:
      name: Middle left button - Hold release
      description: Action to run when middle left button was held in and released
      default: []
      selector:
        action: {}

    button_middle_left_hold_in:
      name: Middle left button - Hold in
      description: Action to run when middle left button is held in
      default: []
      selector:
        action: {}

    # ---------------------------- BUTTON MIDDLE RIGHT ----------------------------
    button_middle_right_single_press:
      name: Middle right button Single press
      description: Action to run on a single press of the middle right button
      default: []
      selector:
        action: {}

    button_middle_right_double_press:
      name: Middle right button Double press
      description: Action to run on a double press of the middle right button
      default: []
      selector:
        action: {}

    button_middle_right_triple_press:
      name: Middle right button triple press
      description: Action to run on a triple press of the middle right button
      default: []
      selector:
        action: {}

    button_middle_right_hold_release:
      name: Middle right button Hold release
      description: Action to run when middle right button was held in and released
      default: []
      selector:
        action: {}

    button_middle_right_hold_in:
      name: Middle right button Hold in
      description: Action to run when middle right button is held in
      default: []
      selector:
        action: {}

    # ---------------------------- BUTTON BOTTOM LEFT ----------------------------
    button_bottom_left_single_press:
      name: Bottom left button - Single press
      description: Action to run on a single press of the bottom left button
      default: []
      selector:
        action: {}

    button_bottom_left_double_press:
      name: Bottom left button - Double press
      description: Action to run on a double press of the bottom left button
      default: []
      selector:
        action: {}

    button_bottom_left_triple_press:
      name: Bottom left button - Triple press
      description: Action to run on a triple press of the bottom left button
      default: []
      selector:
        action: {}

    button_bottom_left_hold_release:
      name: Bottom left button - Hold release
      description: Action to run when bottom left button was held in and released
      default: []
      selector:
        action: {}

    button_bottom_left_hold_in:
      name: Bottom left button - Hold in
      description: Action to run when bottom left button is held in
      default: []
      selector:
        action: {}

    # ---------------------------- BUTTON BOTTOM RIGHT ----------------------------
    button_bottom_right_single_press:
      name: Bottom right button - Single press
      description: Action to run on a single press of the bottom right button
      default: []
      selector:
        action: {}

    button_bottom_right_double_press:
      name: Bottom right button - Double press
      description: Action to run on a double press of the bottom right button
      default: []
      selector:
        action: {}

    button_bottom_right_triple_press:
      name: Bottom right button - Triple press
      description: Action to run on a triple press of the bottom right button
      default: []
      selector:
        action: {}

    button_bottom_right_hold_release:
      name: Bottom right button - Hold release
      description: Action to run when bottom right button was held in and released
      default: []
      selector:
        action: {}

    button_bottom_right_hold_in:
      name: Bottom right button - Hold in
      description: Action to run when bottom right button is held in
      default: []
      selector:
        action: {}

mode: restart
max_exceeded: silent
trigger:
- platform: event
  event_type: deconz_event
  event_data:
    device_id: !input 'remote'
action:
- variables:
    event: '{{ trigger.event.data.event }}'
- choose:

  # ---------------------------- BUTTON TOP LEFT ----------------------------
  - conditions:
    - '{{ event == 1002 }}'
    sequence: !input 'button_top_left_single_press'
  - conditions:
    - '{{ event == 1004 }}'
    sequence: !input 'button_top_left_double_press'
  - conditions:
    - '{{ event == 1005 }}'
    sequence: !input 'button_top_left_triple_press'
  - conditions:
    - '{{ event == 1003 }}'
    sequence: !input 'button_top_left_hold_release'
  - conditions:
    - '{{ event == 1001 }}'
    sequence: !input 'button_top_left_hold_in'

  # ---------------------------- BUTTON TOP RIGHT ----------------------------
  - conditions:
    - '{{ event == 2002 }}'
    sequence: !input 'button_top_right_single_press'
  - conditions:
    - '{{ event == 2004 }}'
    sequence: !input 'button_top_right_double_press'
  - conditions:
    - '{{ event == 2005 }}'
    sequence: !input 'button_top_right_triple_press'
  - conditions:
    - '{{ event == 2003 }}'
    sequence: !input 'button_top_right_hold_release'
  - conditions:
    - '{{ event == 2001 }}'
    sequence: !input 'button_top_right_hold_in'

  # ---------------------------- BUTTON MIDDLE LEFT ----------------------------
  - conditions:
    - '{{ event == 3002 }}'
    sequence: !input 'button_middle_left_single_press'
  - conditions:
    - '{{ event == 3004 }}'
    sequence: !input 'button_middle_left_double_press'
  - conditions:
    - '{{ event == 3005 }}'
    sequence: !input 'button_middle_left_triple_press'
  - conditions:
    - '{{ event == 3003 }}'
    sequence: !input 'button_middle_left_hold_release'
  - conditions:
    - '{{ event == 3001 }}'
    sequence: !input 'button_middle_left_hold_in'

  # ---------------------------- BUTTON MIDDLE RIGHT ----------------------------
  - conditions:
    - '{{ event == 4002 }}'
    sequence: !input 'button_middle_right_single_press'
  - conditions:
    - '{{ event == 4004 }}'
    sequence: !input 'button_middle_right_double_press'
  - conditions:
    - '{{ event == 4005 }}'
    sequence: !input 'button_middle_right_triple_press'
  - conditions:
    - '{{ event == 4003 }}'
    sequence: !input 'button_middle_right_hold_release'
  - conditions:
    - '{{ event == 4001 }}'
    sequence: !input 'button_middle_right_hold_in'

  # ---------------------------- BUTTON BOTTOM LEFT ----------------------------
  - conditions:
    - '{{ event == 5002 }}'
    sequence: !input 'button_bottom_left_single_press'
  - conditions:
    - '{{ event == 5004 }}'
    sequence: !input 'button_bottom_left_double_press'
  - conditions:
    - '{{ event == 5005 }}'
    sequence: !input 'button_bottom_left_triple_press'
  - conditions:
    - '{{ event == 5003 }}'
    sequence: !input 'button_bottom_left_hold_release'
  - conditions:
    - '{{ event == 5001 }}'
    sequence: !input 'button_bottom_left_hold_in'

  # ---------------------------- BUTTON BOTTOM RIGHT ----------------------------
  - conditions:
    - '{{ event == 6002 }}'
    sequence: !input 'button_bottom_right_single_press'
  - conditions:
    - '{{ event == 6004 }}'
    sequence: !input 'button_bottom_right_double_press'
  - conditions:
    - '{{ event == 6005 }}'
    sequence: !input 'button_bottom_right_triple_press'
  - conditions:
    - '{{ event == 6003 }}'
    sequence: !input 'button_bottom_right_hold_release'
  - conditions:
    - '{{ event == 6001 }}'
    sequence: !input 'button_bottom_right_hold_in'

Tested and working. Let me know if there are any issues for you :slight_smile:

8 Likes

That’s a lot of buttons. What are you using them for?

It would be nice to add as on ControlerX hold_brightness_toggle which will allow with only one button dim_up and dim_down…

But I don’t know if it’s possible here…

1 Like

Nice blueprint.

Slight typo in Tripple should be Triple :slight_smile:

Control some lights, activate the alarm, turn everything off in the house, open the garage, and some spare ones :wink:

Good catch! Damn… Don’t think I’m allowed to update it as it would break existing blueprints. Or should I go for it anyway?

You can update, existing users will have to remove and re import it anyway. The import mechanism just reads it in once

Thanks for the clarification! Updated :wink:

Well personally I wouldn’t be able to memorize 30 (6 buttons * 5 actions) different things, even if you only used 1/3 of them. Nice to see how many blueprints are being made, though!

1 Like

Wait, there’s some confusion here. I don’t have 30 actions for this device (only 6 so far)! With this blueprint I’m just mapping out all possible actions you could use.

That way, it’s really easy for people to make an automation for one of these devices and only use the buttons/actions they need. No need to lookup the event data they sent, or anything like that.

1 Like

do you also experience a 1-2 seconds delay when using these switches? i.e. you click, then only after a second or two action is actually executed.

i am guessing its switch firmware waiting to see if you would want to click one or two times more in a same period of time to understand if its a double/triple click and not just a single click.

or is it only my device?

No delay here, instant feedback. Using conbee2 on rpi.

Thanks @Savjee. Realy nice and easy to use. Now it would be nice to use a blueprint with dimming (long press)

Can you please add lumi.remote.b486opcn01 and lumi.remote.b286opcn01 also? :slight_smile:
As far as I know the events should be the same from top to bottom.

1 Like

I have this switch.

This is great as I don’t like touching yaml and only did UI automations it left me with like 6 automations for each which was a bit messy, a good solutoin would of just been a folder in the automation section but this works too, nice stuff

I personally looking to sell my 6 button for the two button.

I also don’t need so many options and often get confused in the dark what button is which.

2 x (6 possible) is enough for me.

and 4 button at a push lol

If anyone has a 3d printer, I recently designed a switch cover for the Opple switch and thought I’d share it here.

I have a aqara Opplw wireless Scene switch 6 button. Is this blueprint also working with ZHA intergration?

It does not work for me. If I listen to events of deconz it shows me that the buttons are pressed, but there is no way to get it working in the blueprint. Lights, shutters… no reaction :frowning:

It’s only tested with Deconz. I don’t use ZHA, so can’t test.

@Sven12345 Did you try this out? I just ordered one and hoping it does.

Product is on the way to my house but look at this link i think it’s work with zha.

AWESOME! Thank you! Can’t wait to have this.