Logic Machine Forum
Rgb turn colors with script. - Printable Version

+- Logic Machine Forum (https://forum.logicmachine.net)
+-- Forum: LogicMachine eco-system (https://forum.logicmachine.net/forumdisplay.php?fid=1)
+--- Forum: Scripting (https://forum.logicmachine.net/forumdisplay.php?fid=8)
+--- Thread: Rgb turn colors with script. (/showthread.php?tid=2340)



Rgb turn colors with script. - Tokatubs - 13.11.2019

I am controlling an dmx controller from Elka via knx. 

Added to Mosaic for turning colors. Working like a charm. 
Now i want to create something that turns the colors during the day. 
Scheduler would work, but i guess thats a little bit 1980. 
Anyone have a good way to change the colors randomly..  Smile


RE: Rgb turn colors with script. - Daniel - 13.11.2019

something like this would do
Code:
math.randomseed(os.time())
value = math.random(0,16777215)
grp.update('RGB', value)



RE: Rgb turn colors with script. - Tokatubs - 13.11.2019

Of course i did not get this going on my first try.
Added to a script, but nothing happened to the GA.
Where do i put in the transsision time between the random value calculates.


RE: Rgb turn colors with script. - Daniel - 14.11.2019

This script just generate a random RBB value each time it runs, nothing more. It use the 3byte RGB object.