set a dimmer/light rgb color in python?

Discuss Python scripts here.
dliccardo
Posts: 56
Joined: Mon Jun 09, 2014 9:38 pm

set a dimmer/light rgb color in python?

Post by dliccardo »

Is it possible to set rgb color in python?

To set brightness, for example:

indigo.dimmer.setBrightness(359549372, value = 100) #family room lights

But I see no property for color if this is an rgb bulb.... (like something equivalent to the Set RGBW Levels device action available in action group)
User avatar
DaveL17
Posts: 6881
Joined: Tue Aug 20, 2013 11:02 am
Location: Chicago, IL, USA
Contact:

Re: set a dimmer/light rgb color in python?

Post by DaveL17 »

I believe what you're looking for is

Code: Select all

indigo.dimmer.setColorLevels( (DimmerDeviceCmds)arg1, (object)device [, (object)redLevel=None [, (object)greenLevel=None [, (object)blueLevel=None [, (object)whiteLevel=None [, (object)whiteLevel2=None [, (object)whiteTemperature=None [, (int)delay=0 [, (bool)suppressLogging=False [, (bool)updateStatesOnly=False]]]]]]]]]) -> None :
    Changes the red, green, blue, white levels of a color
    dimmable device with optional delay (delay) in seconds.
viewtopic.php?t=17039
I came here to drink milk and kick ass....and I've just finished my milk.

[My Plugins] - [My Forums]
dliccardo
Posts: 56
Joined: Mon Jun 09, 2014 9:38 pm

Re: set a dimmer/light rgb color in python?

Post by dliccardo »

yes, great, thx!
Post Reply

Return to “Python Scripting”