Controlling Cololight from the Command Line
Find Out MoreCololight Pro is a wifi-aware lighting system that is controlled by an application on your Android or iOS device. It's similar in concept to a Nanoleaf. "Colo" is my .NET Core solution that can be run from the Command Line on Windows, MacOS and Linux. Being Command Line based means you can integrate it into most scripting solutions on any of those platforms.
Currently, only source code is provided so you'll need to download it locally and build from there. Instructions for doing this are located within the GitHub Repo.
Once built, the following commands are possible:
Usage: [options]
Options:
-?|-h|--help Show help information
-a|--address <IPADDRESS> The IP address of the Cololight device you want to instruct
-o|--on[:<BOOL>] True to turn the light on, false to turn it off
-c|--colour[:<COLOUR>] Sets the base colour to one of the System.Drawing.Color types
Allowed values are: ActiveBorder, ActiveCaption, ActiveCaptionText, AppWorkspace, Control,
ControlDark, ControlDarkDark, ControlLight, ControlLightLight, ControlText, Desktop,
GrayText, Highlight, HighlightText, HotTrack, InactiveBorder, InactiveCaption,
InactiveCaptionText, Info, InfoText, Menu, MenuText, ScrollBar, Window, WindowFrame,
WindowText, Transparent, AliceBlue, AntiqueWhite, Aqua, Aquamarine, Azure, Beige, Bisque,
Black, BlanchedAlmond, Blue, BlueViolet, Brown, BurlyWood, CadetBlue, Chartreuse, Chocolate,
Coral, CornflowerBlue, Cornsilk, Crimson, Cyan, DarkBlue, DarkCyan, DarkGoldenrod, DarkGray,
DarkGreen, DarkKhaki, DarkMagenta, DarkOliveGreen, DarkOrange, DarkOrchid, DarkRed,
DarkSalmon, DarkSeaGreen, DarkSlateBlue, DarkSlateGray, DarkTurquoise, DarkViolet, DeepPink,
DeepSkyBlue, DimGray, DodgerBlue, Firebrick, FloralWhite, ForestGreen, Fuchsia, Gainsboro,
GhostWhite, Gold, Goldenrod, Gray, Green, GreenYellow, Honeydew, HotPink, IndianRed, Indigo,
Ivory, Khaki, Lavender, LavenderBlush, LawnGreen, LemonChiffon, LightBlue, LightCoral,
LightCyan, LightGoldenrodYellow, LightGray, LightGreen, LightPink, LightSalmon,
LightSeaGreen, LightSkyBlue, LightSlateGray, LightSteelBlue, LightYellow, Lime, LimeGreen,
Linen, Magenta, Maroon, MediumAquamarine, MediumBlue, MediumOrchid, MediumPurple,
MediumSeaGreen, MediumSlateBlue, MediumSpringGreen, MediumTurquoise, MediumVioletRed,
MidnightBlue, MintCream, MistyRose, Moccasin, NavajoWhite, Navy, OldLace, Olive, OliveDrab,
Orange, OrangeRed, Orchid, PaleGoldenrod, PaleGreen, PaleTurquoise, PaleVioletRed,
PapayaWhip, PeachPuff, Peru, Pink, Plum, PowderBlue, Purple, Red, RosyBrown, RoyalBlue,
SaddleBrown, Salmon, SandyBrown, SeaGreen, SeaShell, Sienna, Silver, SkyBlue, SlateBlue,
SlateGray, Snow, SpringGreen, SteelBlue, Tan, Teal, Thistle, Tomato, Turquoise, Violet,
Wheat, White, WhiteSmoke, Yellow, YellowGreen, ButtonFace, ButtonHighlight, ButtonShadow,
GradientActiveCaption, GradientInactiveCaption, MenuBar, MenuHighlight
-rgb|--rgb[:<RRGGBB>] Sets the base colour a custom HTML defined colour
-e|--effect[:<EFFECT>] Sets the animated Effect of the lights
Allowed values are: Club80s, CherryBlossom, CocktailParade, Instagrammer, Pensieve,
Savasana, Sunrise, TheCircus, Unicorns, Christmas, RainbowFlow, MusicMode
-b|--brightness[:<N>] Sets the brightness as a percentage between 0 and 100
The same help can be accessed by running colo --help
at the command line/shell.
You need to always send the IP Address of your Cololight Pro device on your network. I'd suggest giving it a static IP if you are scripting changes to the light. Multiple commands can be issued at the same time. So for example, the following turns on the light, sets the brightness to half-way and the colour to magenta:
colo --address 192.168.0.100 --on:true --brightness:50 --colour:Magenta
... and in concise mode:
colo -a 192.168.0.100 -o:true -b:50 -c:Magenta
Background information for this project came from Matthias Kleine whom had already gathered the command strings needed to control the light.
Proudly designed in New Zealand. Copyright Heard Technologies 2018-2024