OctaLight
Description
OctaLight is a room light with WiFi. Basically it is an led strip wired in an octagon shape with a cross in the middle of it. It is powered by an ESP8266 chip and has multiple lighting modes and light effects already implemented in the C++ Arduino code. A simple HTTP server is implemented, so the light can react to GET requests. It can also be controlled via the in-built web control panel.
You can find the code on my Github repository "octalight".
Required libraries:
GET request endpoints
Route | Description | Arguments | Response | |
* | page=[true | false] | Whether to respond with the control panel. | success or error message | |
/ | Show the control panel. | control panel | ||
/get | Get the average light color. | color in RRGGBBWW | ||
/on | Set the light color to a warm white. | |||
/off | Set the light color to black (off). | |||
/color | Set the light color. | color=[RRGGBBWW] (required) | The color. | |
transition=[int] | The transition time in ms. | |||
mode=[all | inner | outer] | Where to set color. | |||
/alternate | Alternating circles animation of different colors on the outer pixels. | colors=[RRGGBBWWRRGGBBWWRR...] (required) | The colors. | |
duration=[int] | Duration for one color in ms. | |||
inner=[RRGGBBWW] | The color on the inner pixels. | |||
cycles=[int] | Cycle count. "-1" for infinity. | |||
/ripple | Ripple animation from in to out of different colors. | colors=[RRGGBBWWRRGGBBWWRR...] (required) | The colors. | |
duration=[int] | Duration for one color in ms. | |||
cycles=[int] | Cycle count. "-1" for infinity. | |||
/spectrum | Waving through the RGB spectrum. | duration=[int] | Duration for one cycle in ms. | |
cycles=[int] | Cycle count. "-1" for infinity. | |||
/randomness | Random colors on all pixels. | frequency=[int] | Number of new random pixels per second. | |
/starlight | A sky full of stars. | color=[RRGGBBWW] | Pixel color. | |
frequency=[int] | Number of pixel switches per minute. | |||
max=[int] | Maximum number of pixels on at the same time. | |||
/stroboscope | Fast-flashing stroboscopic light. | colors=[RRGGBBWWRRGGBBWWRR...] (required) | The colors. | |
frequency=[int] | Number of flashes per second. | |||
blacks=[int] | Number of black phases between flashes. | |||
mode=[random | random_spectrum | order] |
The ordering mode of the colors. |
Structure
Pixel zero is situated at the controller and the outer pixels (red) range counterclockwise back to it. From there the inner pixels (green) form a bow. Not all the strips can be connected directly: There has to be a cable connection to connect the two inner strands (black-green).
Parts list
Specifications according to reference project: 144 pixels, octagon diagonal ~1m
Prices are approximations.
- Wooden bars as base (5m length, 1-2cm wide) [5€]
- Per-LED-controllable LED strip with 4 colors (5m, 30 LEDs/m, temperature per your liking) [17€]
- Power adapter for the strip (5V 8A) [8€]
- Wire adapter [<1€]
- NodeMCU ESP8266 development board [3€]
- Wires, tape, glue, tools
- Total project cost ~40€, construction time 3-8 hours based on your experience