I have a Tradfri Switch (Square one with 1/0 buttons) and a Tradfri bulb. I currently have it configured that short presses turn the bulb ON and OFF, and long presses increase/decrease the brightness. This all works, but I don’t like how each long press just increases/decreases the brightness one step. I need to make continual long presses in order to significantly change the brightness.
I’d like to configure the automation instead such that when I long press the light continually increases or decreases in brightness until either I release the button or the max.min is reached. I don’t know how to go about doing this. I’ve read a little bit about script automations, but I’m not sure what the approach would be. If I were to code this I would start an interval timer on long press that increased/decreased the brightness by X % every Y ms. Releasing the button or reaching the limit stops the interval timer. Simple stuff in concept, but I don’t know how to do it in yaml.
Any good guides on how to make script automations like this?
Found your post here when searching about the same issue. Looks like you found a blueprint that solves the issue of these long presses without smooth dimming. I tried several, but keep having this issue. The bleuprints that I used are included below. Can you tell me which blueprint does the job well for you? Maybe it’s a configuration fault on my side and the following are working well for you.
@jclarke0000@Nick4 Thanks for the response and confirming that it’s the correct flow. I experimented a little more and figured something out.
The problem existed when I was using a group entity for the lights. (trying to dim 8 pieces of gu10 bulbs in that group - by dimming the group-entity)
I tried it with dimming individual bulbs. With one Tradfri GU10 bulbs it’s working fine!
With a few bulbs it’s still working fine, until I added about 5 of them, then the same problem began.
So unfortunately no solution yet… but maybe this additional information gives someone an idea about what’s the issue? I cannot image that nobody else is having the case to dim about 8 bulbs at the same time with this automation. Thanks!
Btw; maybe good to summarize clear problem; Not dimming completely by holding the button for long time. Need to release several times, and still then it’s not dimming at all on some “ranges of the dimming scale”.
Hi, I have the same requirement for smooth dimming behavior, but I’m using Z2M - Is there any blueprint for this?
I found a blueprint for standard behavior, which I can set up also manually, but I’m looking for continous set brightness up/down when holding the buttons…
I found a solution that works well for me – but it‘s not using HA automations.
Instead I installed the AppDaemon add-on and then the ControllerX „app“.
Everything is explained very good here: ControllerX
Then, via the File Editor add on I edited the /config/appdaemon/apps/apps.yaml file and added this for my E1743 IKEA Trådfri button: