This is a node.js thing to control the radio-controlled lights in your home (klikaanklikuit or action or some others).
- A raspberry-pi or something else with a 434MHz transmitter
- An executable that can be called like
./light A 1 on(ie
- A email@example.com server
Set up a seaport server and make sure it has a static IP or DNS name pointing to it.
Compile the tool for your brand:
g++ -o kaku kaku.cpp -I/usr/local/include -L/usr/local/lib -lwiringPi
setuidbit on it if it needs to run as root
config.jsonand modify the host/port to point to your seaport server, and modify the controller to point to your executable
config.json pointing to your seaport server. You can place this in the same directory as the lightsd installation, or as
~/.config/lights.conf.json Run the
lights-cli.js) executable to interface with the server.
You can copy the
sun_sched.example.js file to
sun_sched.js, the code will be run daily to set times that lights turn on and off. (please keep in mind that the descriptions need to be reasonably unique (everything with the same description is erased when these times are set)).