[OBSOLETE] IKEA Tradfri RGB Bulbs (ZigBee with "CIE xy" color scheme)

Hi all.

Straight to the point: here you will find a Device Handler for the new IKEA Tradfri RGB Bulbs. :slight_smile:

https://github.com/puzzle-star/SmartThings-IKEA-Tradfri-RGB

And now the details:

  • Standard ZLL / ZigBee RGB Bulb DHs do not work with IKEA Tradfri RGB Bulbs
  • After some ZigBee analyzing, I found out these bulbs are not using the “Hue/Saturation” Color cluster commands, but the “Color XY” commands
  • I have not been able to make the bulbs show Cyan, and Green is quite yellowish. All the rest is fine. Looks to be a limitation in the bulb gamut, as the same happens with the remote without ST: anyway I will be happy to fix it if it is an error in my color conversion (currently using “sRGB” colorspace to “CIE xy” conversion matrixes, plus gamma correction)

Just new to ST & Groovy (did not know the language existed three days ago…, but fortunately I am quite advanced in other programming languages, including Java), so If somebody finds something terribly wrong in the code, please let me know.

I built the DH trying to make sure that as many events, and as soon as possible, are sent, so that these bulbs can be used with most of the existing apps.

The DH has been updated now (v1.1) to send also the standard events and accept the setHue, setSaturation, and setColor({hue:sat}) commands, but extensive testing has not been done on these last ones.

Enjoy! :slight_smile:

Update:

After using it a bit, I discovered that I barely used the R/G/B sliders, and that when I did, it was just to do minor adjustements on the color: this updated version of the DH replaces these sliders with a Hue / Saturation wheel. I know this is sort of redundant with the color picker, but RBG change was not intuitive anyway, specially if tied to the full saturation color as it was before.

11 Likes

Just a quick thank you! Trying this DH out now, and it’s working great. As you say, Green is a bit iffy and I also noticed that pure Red isn’t very saturated. Many colors seems a bit muted, but I guess that is in the bulb rather than in the DH. :slight_smile:

Still waiting for IKEA to get these here in Sweden(!)

If you’re any bit unsure about the color space conversions, Charles Poynton is an incredible source of information.
Check these links out:


http://user.engineering.uiowa.edu/~aip/Misc/ColorFAQ.html

1 Like

I bought mine today at IKEA Barkarby. :slight_smile:

cool! anybody know if the yankees have these in the stores yet?

Thanks @emilakered !

Just out of curiosity, did you get better colors when pairing the bulb directly to the remote ? I think it was not my case, but just to make sure this was not only my perception.

If paring directly with the remote has the same color limitations, then it would be clear for me this is not related to the DH, but to the fact that the “primaries” of the bulb are not quite primary indeed…

Thanks @Mario_Fuchs for the docs. Quite instructive :slight_smile:

It looks like my assumptions on the conversions I did are mostly right (unless I really misunderstood something), and that the resulting colors are more a limitation of the bulbs capacity. But if somebody comes with some quirk to improve it, I will be happy to check.

PS: curious enough that IKEA did not launch these in Sweden before doing so in Spain…

Great information! Was just looking for a DH for this the other day when doing testing. These bulbs are indeed appearing here in U.S. stores (I’m in Phoenix) and I just posted a review after picking one up earlier in the week: https://youtu.be/Z7I4veBjyHE IKEA also updated bulb firmware in August to support connecting directly with the Philips Hue Bridge.

I think the main color that is not that great on the bulbs is green, and blue isn’t as intense or saturated as on Hue/LIFX, but otherwise the color reproduction is fairly good for its price point. Here’s my video on linking the bulbs to Hue if interested - https://youtu.be/lU9za1qlego (I’ve updated that video description with a link back here for those wanting to link it to ST)

Actually, I never tried it with the remote. Maybe I’ll give it a go this weekend!

After more testing, my conclusion is that the colors are really muted. Pure red feels like… white light through a red filter, not really red if you know what I mean. But, for the price it’s pretty decent. :slight_smile:

I discovered something odd today. I can change the colors via the SmartThings app and the DH, no problem. However, SmartApps like Smart Lighting and my ActionTiles control panel can’t change the color.

The bulb is reported as RGB, and the correct controls are there. They just don’t do anything. I can change on/off and level as usual, so the connection to the bulb obviously works.

Hi @emilakered,

I think this is because the Apps are using the (standard) setColor({hue:sat}}, setHue & setSaturation set of functions. These are in the TO DO list of the driver :slight_smile:, as I need to convert from Hue/Sat to RGB before (the IKEA bulbs are not using Hue/Sat Zigbee commands, but CIE color XY commands)

Will try to make these work this weekend

Ah, I understand the problem! Thank you for your work with this, really great. :slight_smile:

Hi @emilakered,

I updated the DH and now it should accept the setHue / setSaturation / setColor({hue:sat}) commands. I could only do some basic testing, as I am not using any app with which I could test these, If it does not work correctly, please let me know and will try to identify any issues.

I did a quick test with ActionTiles, and it seems to be working fine! I’ll try it out more tomorrow, my daughter is asleep in the “RGB room” and I don’t think she likes a midnight disco… :slight_smile:

I went to IKEA Kungens Kurva, the first IKEA store in the world and one would have thought they would have it. I asked, and turns out IKEA Barkaby were a little too hot on the trigger. Official launch in October.

Will have to find another excuse to go there again… :wink:

Can the remote be added to SmartThings to control anything else? I’m new to the community so unsure what may or may not work. I don’t need a remote unless it can be used for other things so I’d be more likely to buy a comparably priced but higher quality bulb without a remote, but if the remote can be used for other stuff then it becomes a nice bonus to a cheap bulb!

1 Like

I have found googling around some attempts to make it work, and even there is a discussion on the topic here “IKEA Tradfri Button – help needed”, with no success so far, so I decided to investigate a bit myselft and it looks like the remote is using Zigbee group and maybe scene commands to control the lights directly. If it is like that, there is no way to make the remote send anything to the ST hub.

So the brief answer is that it looks like it won’t work. Will be happy if somebody comes with a solution.

Do you have to do something special to get horizontal sliders in the SLIDER_CONTROL? Every DeviceHandler I try only shows a very small vertical slider.

Screenshot_20171207-220059

It is totally under UI implementation control. Some weeks ago the ST mobile app was updated and this was changed.

So, basically, what you see now is the same as everybody else sees. Just the snapshot you see from the first post is from before that update.

Personally, I preferred it as it was before: now you have to get into the control and then change it, while before you could do it directly from the tile. But ST guys decided to change it for some reason.

Thanks,

one more ? if you don,t mind. Where did you find the documentation for this? zigbee.levelRefresh() and the other methods in your refresh method ? I do not see it in the smartthings documentation anywhere. Only the options found under these 2 pages which mention nothing of the ones you are using in refresh.

http://docs.smartthings.com/en/latest/device-type-developers-guide/zigbee-primer.html
http://docs.smartthings.com/en/latest/ref-docs/zigbee-ref.html