Lutron Caseta - wall dimming switch

I have been running Lutron switches for a long time without any issues…$$$$ but I believe worth it.

I have a automation/script that uses the pico remote and I can see which button on the switch is push/held …
I have recently added a light level control to the office which is not using the pico remote only the wall dimming switch and do not see where I can get the button pushed information. The office light control: How do you modify the value of a sensor attribute - #9 by eralbright

I’m looking for: (this uses the pico to control two lights. The upper/lower is on/off for one switch and the on/off is on/off for the other and the stop is toggle both)

alias: Art Light off
description: ""
trigger:
  - platform: device
    device_id: 2f92ace13caf2a43b0c12ea2d7231d0e
    domain: lutron_caseta
    type: press
    subtype: lower
condition: []
action:
  - type: turn_off
    device_id: 789099c4b7d01e9f2678f889450cd87f
    entity_id: 216e86d0b5c1b38d221b68e52af63b5a
    domain: light
mode: single

but from the wall switch.
Does it exist - is there a way to get this information?

Not currently, or likely:
Feature Request: Add support for all button events · Issue #86 · gurumitts/pylutron-caseta (github.com)

This custom integration will do what you want, and also supports double tap and long press for the buttons

IIRC, the -pro integration doesn’t expose button presses on switches/dimmers, only picos, but it’s been awhile since I played with it.

I think the best that could be done is to detect brightnes state changes and set the related lights to match the “master” light’s brightness.

This would not be as smooth as the OP wants. In practice, the direct connected light would dim as expected, but the second light would be delayed.

So I ended up doing a work around with the switch brightness value. When I enter the automation I get the reading and compare it to the last time the automation ran leaving value. If it is not the same (within reason, I have found that it is usually about 1 off of the last value - don’t understand why) then the switch was adjusted, either by Alexa request or by switch adjustment.

It is all working as expected - now it is clean it up and speed it up.
Speeding it up - I will most likely try parallel execution. Has anyone looked to see if that is actually faster than the series run.


The executed path shown has it doing a lot of tests to see what needs to be done. The reason I’m thinking parallel is it physically would be shorter so therefore less time. But does it take more time due to increased processor needs. But using such a small amount of processor … about to find out, or break it completely.

All yes, agreed. I skimmed and saw the Pico mentioned in the first comment, and missed the normal switch. Yes, definitely does not detect button presses for non pico. but I do still love that integration for the double tap and long press on the Picos. :slight_smile:

I already had template code for pico long/double/triple presses. It’s ugly and takes a little manual setup for each pico, but works well. Doubt I would go that route today if I were starting over.