Tuesday, January 05, 2016

Arduino powered X-Mas tree

In 2014 we got two cats and decided not to have a classic christmas tree. I also started playing with Arduino and other gadgets, so this made me think to have an Arduino powered tree in 2015. In November my daughter and I started to build the tree.
The tree
The tree has 14 RGB LEDs (basically WS2812 ones) from Sparkfun (or EXP-Tech).
Pinout of the LEDs is as follows:
LED Pinout
LED-Pinout (click to enlarge)
With that, the tree wiring got relatively easy by bending the LED pins in the four different directions and then connecting all 5 Volt pins with the red wire, GND with the black and chaining data in and out either by directly soldering the pins or via the yellow wire:
Backside of the tree
Detail view:
Wiring detail
The overall schematic then looks like this (I am using an Arduino at the moment, but will use a TrinketPro in the future):
Weihnachtsbaum Schaltplan
Schematic (click to enlarge)
I've added a photo resistor and a white diode to provide some lighting of the tree front, as at night, the RGB LEDs are so light, that the tree itself can't be seen. The resistor value also serves to dim the RGB LEDs at night.
The software driving the LEDs is basically the Strandtest one that Adafruit delivers as example for their Neopixel Library. I've modified the code a bit to also show other patterns.
In the future we will add a stand for the tree that will also house the electronics and will also host some additional surprise that I will talk about in a future post :)

[ UPDATE 2016-12-11 ]

I've added a stand and the dedicated TrinketPRO: