I think its working in the same way as the script @Danielhiversen posted here:
I have adopted that script but never got it working as well as yours. I assumed it was a limitation of the HA script processing, but now I suspect that the brightness is changed in too small increments.
Thanks for posting automation and scripts yam. I need to get it working properly now ![]()