Hey there! If you’ve got Tradfri bulbs with color support (or a bunch of them), you might’ve run into some glitches when trying to animate brightness and color (or color temperature) simultaneously. Well, these bulbs can’t do both at the same time. If you’ve ever tried switching between different scenes with Tradfri, you may know the pain.
This little script is designed to help with that by splitting brightness and color adjustment into separate actions, restoring the ability to use transitions.
How to use this:
Install the blueprint,
Instead of calling light.turn_on, call script.tradfri_wrapper (just replace the script’s name if you want to change it),
Wrap all service call parameters inside a data payload like this:
If your call involves both brightness and color/temperature adjustment, it’ll be split into two calls, doubling the total transition time but preserving the transition itself.
I have another question: how do i turnoff the Ikea bulbs without having them staying on with a Minimum britghtness value? Is this also possible with the wrapper Script? Tried it with „brightness: 0“ but also then the bulb shows the unwanted effect.
This is an awesome blueprint that has totally saved Tradfri lights for me. Much appreciated!
One additional hint: at first the script didn’t seem to work all the time for me. Whenever I was changing the colour of mutiple lights at once, some of the calls failed. Turns out that’s because by default scripts use ‘mode: single’, which means you can only change one lightbulb’s colour at a time. So I explicitly set ‘mode: parallel’ in the script and since then it’s been working perfectly.
My problem is that in a room, not all lights are turned on in every scene. When I then use “Turn Off,” the lights that were already off are always turned back on at minimal brightness, but Home Assistant still shows them as “Off.”
I actually have the same problem. There is a night light in the hall way with three GU10 Tadfri lights. most of the times, they turn off completly. But every now and then one, two or all three lights stay on with minimum brightness and sometimes turn from an at least very warm white to a very cold blue. If look into Home Assistant it says, that all lights are turned off. So I have to set them to on and then to off. That always works. But with an automation, it works sometimes.
Have you ever found a solution? I am really hard thinking of getting three Philipps HUE lights. But that would be around a 100 €
i am Not working with the „.turn_off“ anymore. Instead of that i am activating a new scene in which all lights are turned on with Zero brightness.
Probably this could also be a Solution for you.
This is great and I can get it to work as a service call for individual lights. Is it possible to use this to call different scenes or would it need to be significantly modified? Thanks!