Make Home Assistant automation respond faster to blue 2-1

I have a blue 2-1 switch that is controlling both a zigbee group of smart lights and a shelly1 that is controlling power to a dumb light. The shelly1 isn’t zigbee, so I’m using an automation to turn on and off the shelly1 when the buttons are pressed. The automation is being triggered by the press up and press down events.

However, I’ve noticed that the automation is very slow, and it’s not because of the shelly (which responds quickly when Home Assistant itself just toggles the shelly on and off). It’s delayed by quite a bit compared to the zigbee lights (feels like a second or more, but hard to measure), and far longer than the shelly response delay.

However, I’ve noticed in my logbook that the blue switch sends multiple “On” events followed by a single “Press - Up” event. I’m guessing that the Press - Up event is delayed in some way compared to On (although I’m not sure why there are multiple On events every time).

Should I change to looking for the on event somehow? Is there something else I can do to get the automation to trigger faster after the blue 2-1 switch is pressed?

Example:

Switch - LR Wall 2 Press - Up event was fired
10:53:01 AM - 20 seconds ago

Switch - LR Wall 2 On event was fired
10:53:01 AM - 20 seconds ago

Switch - LR Wall 2 On event was fired
10:53:01 AM - 20 seconds ago

Switch - LR Wall 2 On event was fired
10:53:01 AM - Now

Based on your example, all the events have the same time stamp and show no delay. It also shows the up event fired at the same time as 2 of the on events (20 seconds ago).

One thing that does help speed things up is to adjust your button delay.

If you use multi-taps on the switch, you’ll struggle getting it reliable if the delay is lower than 300ms. If you don’t, set that to 0 and you shave off 0.5s.

I have tried removing the button delay entirely and it doesnt fix the problem, my home assistant automation seems to only fire approximately 1 second later, although it’s variable. I don’t think it’s the latency of sending the command to the shelly, as this functions close to instantly when triggered from home assistant. Maybe this is just the limitation of receiving the zigbee command and responding to it?