deconz-rest-plugin icon indicating copy to clipboard operation
deconz-rest-plugin copied to clipboard

Update error messages to be more precise

Open bluemoehre opened this issue 1 year ago • 3 comments

Hue has added more effects than Colorloop. Now we also have Candle & Fireplace. So we have to be more generic with this message.

bluemoehre avatar Oct 08 '23 16:10 bluemoehre

Also we need to adapt the corresponding variable & function names.

bluemoehre avatar Oct 08 '23 16:10 bluemoehre

This is not going to work. The isColorLoopActive() checks only for colorloop. The special effects work very differently on Zigbee level, and are manufacturer-specific (Hue implements them differently from Mueller and from the LIDL Xmas light strip). In hindsight, I half regret exposing both using state.effect. Also note that colormode is hs for colorloop, but effect for the special effects.

I think setting the color(temperature) while a special effect is active actually terminates the effect, where this is simply ignored while colorloop is active (hence the check).

ebaauw avatar Oct 08 '23 17:10 ebaauw

If I activate the Candle or Fireplace effect and after PUT something with sat or bri I get the response error "colorloop is active". The effect is not terminated. To terminate the effect I need to add effect: 'none'.

Also note that colormode is hs for colorloop, but effect for the special effects.

Wow, you are right - this will add even more irritation.

In my opinion the whole effect thing is kinda bad made (by Philips). Why not having an effect which starts with "defaults" but allow to overwrite things like color of candle. Well, that's another story ;)

EDIT: okay, actually candle allows to overwrite bri but not in the same request which enables the effect. =/

bluemoehre avatar Oct 09 '23 00:10 bluemoehre