treban / pimatic-tradfri

This plugin provides a tradfri interface for pimatic.
https://pimatic.org/plugins/pimatic-tradfri/
GNU General Public License v2.0
11 stars 3 forks source link

Unable to create action "set color temp" in rule #24

Closed cklam2 closed 6 years ago

cklam2 commented 6 years ago

Pimatic version :

0.9.42

Plugin version :

0.1.17

Problem / Feature :

Unable to create action set color temp in rule

Expected :

Expected color temp action to work like the set color rgb action.

Notes

If I create a rule and enter "set color rgb" then pimatic will show the list of tradfri devices and after selecting a device it will show option to so I will end up in this action: set color rgb Living Room to #ff0000and I can save this.

However if I do the same for action set color temp it won't pop up Tradfri devices. Instead it pops up the. If I manually enter the entire action, ie set color temp Living Room to 80 and save the rule then pimatic will show an error message: Could not find an provider that provides the next action of "set color temp Living Room (RGB) to 80".

treban commented 6 years ago

i will check this

FranzieR commented 6 years ago

When you type "set color rgb" it will show "the" but when you type "set color temp" it will show the tradfri_ devices!!

treban commented 6 years ago

i think the problem is that the "set color temp" action is only possible for device type: "TradfriDimmerTemp" and the "set color rgb" action is only possible for device type: "TradfriRGB"

I will modify the "set color temp" action so that both actions are offered for RGB bulbs.

@cklam2 you should have a rgb bulb ? @FranzieR and you should have a temperature bulb ?

cklam2 commented 6 years ago

@treban, thanks for the support. I indeed have a TradfriRGB bulb. In the UI I can control its color, dim level and hue (=blue-yellow).

FranzieR commented 6 years ago

@treban Thank you! Sorry, what is a temperature bulb? Only shades of white?

FranzieR commented 6 years ago

After Reading again I understnd what you mean 😀. Yes I have a temp, no RGB, bulb 😀 I was searching in a rule a way to dim the light at startup to 50% but only found a way to change the temp. (...and turn on Lamp Bank links and set color temp Lamp bank links to 61....) How to change the dimming to 50%?

treban commented 6 years ago

Just: dim Lamp Bank links to 50%

cklam2 commented 6 years ago

Oh great, I didn't know that either, this action wasn't listed in the readme.md. Will try that tonight.

treban commented 6 years ago

Your welcome. The dim action is a default pimatic action for all light devices and not implement from this plugin. But I will make a hint in the readme.

FranzieR commented 6 years ago

Thanks #treban!

cklam2 commented 6 years ago

I changed line 1019 to 'TradfriDimmerTemp', 'TradfriRGB' in tradfri.coffee. After that, 'set color temp' works fine for TradfriRGB. Also the dim action works like a charm.

treban commented 6 years ago

Thank you for the hint. I will release a new version soon.

cklam2 commented 6 years ago

Created pull request with changes that we discussed, see #25.

cklam2 commented 6 years ago

Thanks for merging, closing now