Imagine using this a focal point at a dimly lit party. While people generally place light-up items out of doors, this tree is also suitable for indoor use. With eight different settings, this tree can blink, stay static or anything in between! The function control box attached to the tree will allow you to choose your special effects. The LED lights are multi-coloured, and each shade shines brilliantly. The stand is made of metal, with a rope light swirling around it to create the tree effect. This tree, which stands a staggering 1.8m tall, is one such sight to behold. Transformer Australian approval number: GMA-505997-EA.Product complies with Australian safety & performance requirements.Outdoor use requires IP20 transformer to be used indoors only.Mains power operated with low voltage transformer:.Dimension 60cm x 60cm x 1.8m with 3m lead.Features memory hold alternate spiral row flashing sequences with various speeds & static.Includes tree topping 5 point Christmas star.3D light display includes red, green, blue & orange LED bulbs in clear rope tube.Alternating four colour LEDs 3D spiral Christmas tree rope light motif. * (R, G, and B are each calculated separately. * colors, it increases or decreases the value of that color by 1. * reaches the step size appropriate for one of the PinMode(bluPin, OUTPUT) if (DEBUG) /* The next function is calculateVal. PinMode(redPin, OUTPUT) // sets the pins as output Int prevB = bluVal // Set up the LED outputs Int j = 0 // Loop counter for repeat// Initialize color variables Int repeat = 0 // How many times should we loop before stopping? (0 for no stop) Int loopCount = 60 // How often should DEBUG report? Int DEBUG = 0 // DEBUG counter if set to 1, will write values back via serial Int hold = 0 // Optional hold when a color is complete, before the next crossFade Int bluVal = black int wait = 3 // 10ms internal crossFade delay increase for slower fades Int bluPin = 11 // Blue LED, connected to digital pin 11// Color arrays Int redPin = 10 // Red LED, connected to digital pin 9 Int grnPin = 9 // Green LED, connected to digital pin 10 * are a little fussy - the inner workings are explained * The internals of the program aren't complicated, but they Set the DEBUG flag to 1 if you want debugging output to be * program for 'hold' milliseconds when a color is complete, There is an optional 'hold' variable, which pasues the * and make the last color black if you want it to fade out at the end.) * then stop on the last color in the sequence. * if it is set to a number, it will loop that number of times, If 'repeat' is set to 0, the program will loop indefinitely. * practice, the other functions the code is performing slow this * a 'wait' of 10 ms should make a crossFade of ~10 seconds. * sets the approximate duration of a single crossfade. The internal loop runs for 1020 interations the 'wait' variable * you can set the initial color to be any other color The initial color is set to black (so the first color fades in), but * In addition, there are 5 optional settings you can adjust: * Those colors will appear in that order, fading out of * In the main part of the program, you need to list the order * Some common colors are provided below, or make your own * Red is the red LED at full, blue and green off * controlling the red, green and blue LEDs * A color is just an array of three percentages, 0-100, Describe the colors you want to be displayed * To create fades, you need to do two things: ** Code for cross-fading 3 LEDs, red, green and blue (RGB) I ended up using a slow crossfade demo as the base for the tree. Feel free to use a cheapie inline preprogrammed controller like I did on my umbrella instead. I had plenty of these boards left over from other lamp projects. Just had to switch the target programmer and program the chip directly. I could have used an arduino uno and did to make the initial tests using an RGB shield but ended up using a custom single board with a bare Atmega328 chip. This also means a controller will be needed. This means I can have a programmed effect but all leds change color simultaneously. I decided to use non-addressable RGB leds.
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |