ZHA - Aqara Opple - Wireless Scene Switch 2 Button

this blueprint based on the 4 Button blueprint. Thanks to Jarne_Roussard for the initial work :slight_smile:

Open your Home Assistant instance and show the blueprint import dialog with a specific blueprint pre-filled.

blueprint:
  name: ZHA - Aqara Opple - Wireless Scene Switch 2 Button
  description: Control anything using Aqara Opple two button remote
  domain: automation
  input:
    remote:
      name: Remote
      description: Opple remote to use
      selector:
        device:
          integration: zha
          manufacturer: LUMI
          model: lumi.remote.b286opcn01
    # ---- Left button ---
    button_left_single_press:
      name: Left button - Single press
      description: Action to run on a single press of the Left button
      default: []
      selector:
        action: {}
    button_left_double_press:
      name: Left button - Double press
      description: Action to run on a double press of the Left button
      default: []
      selector:
        action: {}
    button_left_triple_press:
      name: Left button - Triple press
      description: Action to run on a triple press of the Left button
      default: []
      selector:
        action: {}
    button_left_hold_release:
      name: Left button - Hold release
      description: Action to run when Left button was held in and released
      default: []
      selector:
        action: {}
    button_left_hold_in:
      name: Left button - Hold in
      description: Action to run when Left button is held in
      default: []
      selector:
        action: {}
    # -- Right button ---
    button_right_single_press:
      name: Right button - Single press
      description: Action to run on a single press of the right button
      default: []
      selector:
        action: {}
    button_right_double_press:
      name: Right button - Double press
      description: Action to run on a double press of the right button
      default: []
      selector:
        action: {}
    button_right_triple_press:
      name: Right button - Triple press
      description: Action to run on a triple press of the right button
      default: []
      selector:
        action: {}
    button_right_hold_release:
      name: Right button - Hold release
      description: Action to run whenRight button was held in and released
      default: []
      selector:
        action: {}
    button_right_hold_in:
      name: Right button - Hold in
      description: Action to run whenRight button is held in
      default: []
      selector:
        action: {}
  source_url: https://community.home-assistant.io/t/zha-aqara-opple-wireless-scene-switch-2-button/375107
mode: restart
max_exceeded: silent
trigger:
- platform: event
  event_type: zha_event
  event_data:
    device_id: !input 'remote'
action:
- variables:
    event: '{{ trigger.event.data.command }}'
- choose:
  - conditions:
    - '{{ event == "1_single" }}'
    sequence: !input 'button_left_single_press'
  - conditions:
    - '{{ event == "1_double" }}'
    sequence: !input 'button_left_double_press'
  - conditions:
    - '{{ event == "1_triple" }}'
    sequence: !input 'button_left_triple_press'
  - conditions:
    - '{{ event == "1_release" }}'
    sequence: !input 'button_left_hold_release'
  - conditions:
    - '{{ event == "1_long press" }}'
    sequence: !input 'button_left_hold_in'
  - conditions:
    - '{{ event == "2_single" }}'
    sequence: !input 'button_right_single_press'
  - conditions:
    - '{{ event == "2_double" }}'
    sequence: !input 'button_right_double_press'
  - conditions:
    - '{{ event == "2_triple" }}'
    sequence: !input 'button_right_triple_press'
  - conditions:
    - '{{ event == "2_release" }}'
    sequence: !input 'button_right_hold_release'
  - conditions:
    - '{{ event == "2_long press" }}'
    sequence: !input 'button_right_hold_in'

Hello!
Many thanks for this Blueprint!

A note: my Opple model (b286opcn01) has no “_long press” event, but “_hold” event.

Regards,

Hi!

I try to control an IKEA Tradfri RGB bulb with this switch.
Single press works for on and off action, however I want to set hold action for brighness increase/decrease, but it doesn’t work with hold. When I set the brighness adjustment to double click action, the brightness inceremens with 10% every time. It is pretty inconvenient, would be nice a smooth transition with the hold. Do you have maybe an idea what could be the culprit?