Integrate Ikea Bulb with color via zigbee2mqtt

Hello together,

I have integrated the Ikea Blub Light via zigbee2mqtt and it works.
I can control almost everythink but not the color and that is the issue.

I need your help to convert the color to the Ikea special Color with x,y.

I hope some one can help me.

KR

Kevin

Don’t know what bulb you have, but on the zigbee2mqtt site in the description of an ikea color bulb I found following:

Alternatively it is possible to set the XY color via RGB:

  • {"color": {"r": R, "g": G, "b": B}} e.g. {"color":{"r":46,"g":102,"b":150}}
  • {"color": {"rgb": "R,G,B"}} e.g. {"color":{"rgb":"46,102,150"}}

Are you talking color (in R, G, B) or color temperature?

Below my example for color temp of one of my IKEA bulbs:

Screenshots:



I do not have an R, G, B IKEA light to test others as they do not exist in our market.
But I would assume, as @Vradatta showed, you can command them via the RGB channel.

I would like to integrate this LED1924G9.

I have also found this description, but how do I implement it?

I would like to control the blub via a color controller.

Thank you for your answer.

Yes i would like to controll the RGB-Channel.

I have same bulb. It’s also possible to control color using HSB.
{"brightness":254,"color":{"hue":42,"saturation":80,"x":0.512264,"y":0.438988},... is sample input of your device. hue_value, saturation_value, brightness_value/2.54 are your HSB values.
You may set coloritem state hue_value, saturation_value, brightness_value, as {“brightness”:brightness_value,“color”:{“hue_value”:42,“saturation”:saturation_value}}.
Please note, that color and brightness are operated separately. At first brightness is changed, secondly color is changed. Device reports both states. Therefore you should debounce input by 200 msec.
For parsing note Zigbee2mqtt revisited: No more ugly transformations