Hello all,
I have several IKEA Tradfri Color bulbs connected to a HUE bridge and i am not able to change color form openhab.
Nothing new here, for it has already been discussed in this (IKEA Tradfri Color Changing bulb on Hue Bridge no control of colors).
In this post, there is reference of a script that has a static value applied to it when executed form the rules.
How can i change the rules file, so when i chose one of my light bulbs it is passed directly to the script (value $1)?
Also, the same applies to the HSB (value $2). How can i obtain the value form colorpicker?
My files (copy paste from the original post):
.rules
rule “RGB Farbe Wohnzimmer Schrank”
when
Item colorpicker_wohnzimmer_schrank changed
then
executeCommandLine("/etc/openhab2/scripts/hue_tradfri_color.sh 10 Stehlampe_Wohnzimmer_Schrank_Brightness " + colorpicker_wohnzimmer_schrank.state)
end
Current .mappings file:
Selection item=colorpicker_wohnzimmer_schrank label=“Farbe:” icon=“colorpicker” visibility=[Stehlampe_Wohnzimmer_Schrank_Switch==ON] mappings=[
0=" Warmes Licht “,
1=” Tageslicht “,
2=” Nachtlicht “,
3=” Sonnenuntergang “,
4=” Gelb “,
5=” Helles Gelb “,
6=” Helles Grün “,
7=” Orange “,
8=” Helles Orange “,
9=” Rot “,
10=” Pink “,
11=” Helles Lila “,
12=” Blau "
]
I want to replace the above section with:
Colorpicker item=colorpicker_wohnzimmer_schrank label=“Farbe:” icon=“colorpicker”
So, i need to get the value of the lamp, and the output of colorpicker and pass it to the script:
How can it be done? Is it possible? I dont have the budget to buy an bridge Tradfri just for this lamps.
Again thanks for a very nice program and all your input!