Hue lights looping

Hi, Iā€™d like to create a party mode where the hue lights I have cycle through colours. This can be done on the hue app but Iā€™m unsure how via hubitat. Has anyone done this and is able to share the code? Thanks

What do you do via the Hue app? I wrote a custom Hue Bridge integration that can activate Hue Labs virtual activatiors, and you can also start or stop the "color loop" effect on bulbs or groups.

You could definitely recreate similar things all on the Hubitat side, but if you offload whatever you can to just Hue, I think you're likely to get a better experience. So, if it's one of those two, I might try starting there, but that's just my recommendation. :slight_smile:

2 Likes

That sounds exactly what i'm after! Do you have the code published on here anywhere?

The CoCoHue thread:

FWIW, CoCoHue plus the colorLoop formula found in Hue Labs works great. This is another case of letting Hue do what Hue does best.

3 Likes

Brilliant, thanks

Note that Hue bulbs themselves support the "color loop" effect. This can be done with setEffect(1) on a bulb or group device (it's also the only effect they support, so the number doesn't matter too much right now, but this was how I squeezed in this functionality using standard Hubitat capabilities). I'm not sure if this is different from what Hue Labs does, but as of version 3.0 (not released yet but available as a sort of preview/beta in that thread), you can import virtual activators from there if needed too, so that should also work!

1 Like

Help!! How do I stop setEffect(1)!!???

1 Like

Do a setEffect(0). You can see the "key" for this on the lightEffects attribute under "Current States," and 0 matches to "None." Or do setNextEffect() or setPreviousEffect()--Hue only has one, so going back or forward would take you to none either way. :smiley:

Phew!! Thanks :smiley: