Dim lights on long press button - please finally fix it

Please add support for changing the brightness of led bulbs and led strips in case of a long press of the wireless button from the IKEA series.
Currently, it is not possible to set the functional automation for the option to decrease or increase the brightness. In my opinion, this is a fundamental lack of the missing basic function that I expected from the assistant.
There are many forums and websites where this problem is often addressed and unfortunately unsuccessfully. It can be seen that this is a problem that bothers a large number of users of this device.

What is this? Precise statement of problem please?

1 Like

If the integration API does not support a button release event this is not possible. It is a limitation of the available API.

If it does generate a button release event then you can easily automate dimming up/down on a long press event until a button release event.

IKEA remotes has some funky stuff going on.
They send commands that shouldn’t be sent and is hard to use for more complex automations.
However… The new symfonisk media remote is very easy to use.
I was truly surprised how well everything works.

Although it doesn’t send a hold command, it sends the same command several times so if you just make your automation in parallell then it works very nicely.

By far the worst IKEA remote is the four button light remote. It was hard to use before and now since the new update (from IKEA) it’s even worse.

I am using the following two IKEA devices, via Zigbee2MQTT and an automation, to adjust brightness:

Is the “wireless button” you mentioned either one of those two devices?

Are you using Zigbee2MQTT or ZHA?

1 Like

Hello. Yes, I use the Ikea E1743 button (On/Off square). I use Zigbee in ZHA mode.

Unless something has changed since a few years ago then ZHA can’t do long press on that device.
If you use Node red then you can create a way to detect it.

Here are two Blueprints designed to support the E1743 with ZHA:

Hi, thank you very much for the tips and help. Ikea controller. Not very well, but it works. But I have found that it is even more difficult for me to find a working option to dim the light using any button other than the ikea one.
Does anyone have a working code or script to dim the light using any ZigBee button please?

I am surprised that such a basic thing as dimming the light is not implemented at all in Home Assistant using at least a basic set. It’s surprising that the Home Assistant can’t dim the light with a long press by default without much trouble. Disappointment.

You don’t think this is something IKEA is responsible for do you?
They built a remote that sends two commands when you long press.
Both the one we want and then the ON command.

Sure just configure your actions to not listen to the ON command at all and it will work fine

I don’t even have an automation to dim my IKEA bulb with the E1743. I just use Zigbee binding to bind the 2 together.

Here is an automation to dim my study light with the E1743 using zigbee2mqtt.

My switches unfortunately don’t support binding, so I decided to roll my own simple automation. I have found that the “HA Awesome Blueprints” project didn’t work well for my lights and was a confusing project. I found this worked nicely. It also doesn’t need an input helper.

alias: E1743 controller for study light
description: Connect a Tradfri E1743 to a light (via z2m)
trigger:
  - platform: mqtt
    topic: zigbee2mqtt/0x84ba20fffec1fa68/action
    # the incoming payloads from an E1743 should be one of: 
    #   on, off, brightness_move_up, brightness_move_down or brightness_stop.

action:

   # optionally notify your device while debugging, note 
   # this is not enabled by default
  - action: notify.yourdevice
    metadata: {}
    data:
      message: >-
        {{ trigger.payload }}: brightness {{
        state_attr('light.study_light','brightness') }}
    enabled: false

  - choose:

      # handle on/off
      - conditions:
          - condition: template
            value_template: "{{ trigger.payload == 'on' or trigger.payload == 'off' }}"
        sequence:
          - action: light.turn_{{trigger.payload}}
            target:
              entity_id: light.study_light

      # handle up/down
      - conditions:
          - condition: template
            value_template: >-
              {{ trigger.payload == 'brightness_move_up' or trigger.payload ==
              'brightness_move_down' }}

        sequence:

          # just in case we miss the 'brightness_stop' command end after 20 loops
          - repeat:
              count: 20 

              # brightness +10% or -10%, then wait 500ms
              sequence:
                - action: light.turn_on
                  data:
                    brightness_step_pct: "{{ 10 if trigger.payload=='brightness_move_up' else -10 }}"
                  target:
                    entity_id: light.study_light
                - delay:
                    seconds: 0
                    milliseconds: 500

# this is important because any new incoming mqtt 
# command from this device interrupts the loops above
mode: restart