Chromaticity exposes a Hue compatible REST API that has a modular backend design, allowing a user to control Zigbee*, Color Kinetics, MiLight/LimitlessLED*, and OPC (Open Pixel Control) devices through a unified API.
*: Temporarily disabled
Much of the current work has gone toward making Chromaticity a workable local API for a rooted Wink home automation hub. It is currently capable of reading the Wink's database of Zigbee devices and controlling Philips Hue and GE Link bulbs.
There is effect and group support, but no alert or scene support. Groups are not backed by Zigbee groups currently so updates might be slow for larger groups. Renaming of lights is not yet supported. Currently no changes are persisted between runs.
Experimental RGBW light support is in place for OPC lights, one can define the color temperature of the white source in the fixture.
Light discovery (after startup) is only implemented for Color Kinetics lights currently.
Authentication is wide open, any api_key will work. The API should be discoverable by off the shelf Hue apps. Speaking of which, most iOS and Android apps should work out of the box at this point.
A swagger ui is served up at http://<your_ip>/apidocs
.
Install opkg on your rooted hub:
curl -s http://wink.7pr.xyz/bootstrap.sh | bash
Then:
opkg install chromaticity
/etc/init.d/S57chromaticity restart
go get github.com/evq/chromaticity
go install github.com/evq/chromaticity
chromaticity
Chromaticity will read stored (json serialized) light information from
~/.chromaticity/data.json
. This is primarily useful for hardcoding
OPC light information.
go-opc: An open pixel control client library
go-restful: A framework for creating RESTful web services with autogenerated swagger API docs
go-colorful: A color space transformation library
logrus: A structured logger that is API compatible with the standard library