Project in progress

Christmas Wreath © GPL3+

The 1/4-60 NeoPixel set up into a Christmas wreath for the holiday season.

  • 505 views
  • 0 comments
  • 1 respect

Components and supplies

Necessary tools and machines

09507 01
Soldering iron (generic)
Adafruit Wire, .22 guage

Apps and online services

About this project

Wanted to do something different this year for displaying Christmas lights. Since there are lots of options for this with small board computers. So this is the first of the 3 Christmas projects I'm working on for a window in the house.

I did the following to make this work.

Using the Arduino Nano, I did not install any of the headers that came with the board, but I guess you could, then you could use Breadboard wires to connect the board to the Neopixel. I used PIN 6 on the Nano for my data.

Solder the 4, 1/4 60 Neopixel boards together. I used a small amount of stripped wired to connect each 1/4 to the next. On the last 1/4, which will make the complete circle, You have to solder a lead wire from the 5V on the Nano to the 5V on the Neopixels and to the same for the Gnd(Ground). From the Nano to the Neopixel. Now solder the wire from PIN 6 to the "DIN" only, do not bridge the to the "DOUT" side of the circle.

Upload the sketch from the Arduino IDE.

Schematics

Wreath
File for the wreath in Fritzing
christmaswreath_6KwIIVgzsK.fzz
Wreath In Fritzing
Image of the wreath in Fritzing
Wreath b1nnairqwn

Code

WreathArduino
This is a Christmas wreath which colours in both red and green with a splash of blue!
// NeoPixel Ring simple sketch (c) 2013 Shae Erisson
// released under the GPLv3 license to match the rest of the AdaFruit NeoPixel library
// revamped to have it look much like a Christmas wreath by Scott Milliken (2017)

#include <Adafruit_NeoPixel.h>
#ifdef __AVR__
  #include <avr/power.h>
#endif

// Which pin on the Arduino is connected to the NeoPixels?
// On a Trinket or Gemma we suggest changing this to 1
#define PIN            6

// How many NeoPixels are attached to the Arduino?
#define NUMPIXELS      60

// When we setup the NeoPixel library, we tell it how many pixels, and which pin to use to send signals.
// Note that for older NeoPixel strips you might need to change the third parameter--see the strandtest
// example for more information on possible values.
Adafruit_NeoPixel pixels = Adafruit_NeoPixel(NUMPIXELS, PIN);

int myPixels[] = {5, 10, 15, 20, 25, 30, 35, 40, 45, 50, 55, 60};
int delayval1 = 100; // delay for a 1/10th of a second
int delayval2 = 5000; // delay for 5 seconds

void setup() {

  pixels.begin();
  pixels.show(); // This initializes the NeoPixel library.
}

void loop() {
  
  // For a set of NeoPixels the first NeoPixel is 0, second is 1, all the way up to the count of pixels minus one.

  for(int i = 0; i < NUMPIXELS; i++){

    // pixels.Color takes RGB values, from 0,0,0 up to 255,255,255
    pixels.setPixelColor(i, pixels.Color(255,0,0)); // Moderately bright green color.
    pixels.show(); // This sends the updated pixel color to the hardware.
    delay(delayval1); // Delay for a period of time (in milliseconds).
  }
    for(int i = NUMPIXELS-1; i >= 0; i--){

    // pixels.Color takes RGB values, from 0,0,0 up to 255,255,255
    pixels.setPixelColor(i, pixels.Color(0,150,0)); // Moderately bright green color.
    pixels.show(); // This sends the updated pixel color to the hardware.
    delay(delayval1);
  }
     // Making every 5th LED Red to form Holly on the wreath, rest of the wreath stays green.
     for (int i = 0; i < pixels.numPixels(); i += 5){
      
      pixels.setPixelColor(i, 255, 0, 0);  
      pixels.show();  
  }      
      delay(delayval2);//pause for 5 seconds
      
// make the holly berry turn blue and back to red repeat twice then back to the start. 
  for(uint16_t pos = 0; pos < 12; pos++) {
    pixels.setPixelColor(myPixels[pos], 0, 0, 255);
    pixels.show();
    delay(delayval1);  
  }

    for(uint16_t pos = 0; pos < 12; pos++) {
    pixels.setPixelColor(myPixels[pos], 255, 0, 0);
    pixels.show();
    delay(delayval1);  
  }

    for(uint16_t pos = 0; pos < 12; pos++) {
    pixels.setPixelColor(myPixels[pos], 0, 0, 255);
    pixels.show();
    delay(delayval1);  
  }

    for(uint16_t pos = 0; pos < 12; pos++) {
    pixels.setPixelColor(myPixels[pos], 255, 0, 0);
    pixels.show();
    delay(delayval1);  
  }
  delay(delayval2);
}

Comments

Similar projects you might like

Magic Lamp

by Nekhil ravi

  • 744 views
  • 2 comments
  • 8 respects

Arduino MKR GSM 1400 and DTMF

by Arduino_Genuino

  • 3,242 views
  • 0 comments
  • 9 respects

Love You Pillow

Project tutorial by Arduino

  • 1,638 views
  • 0 comments
  • 4 respects

Infrared Replicator

Project tutorial by Gustavo Gonnet

  • 3,487 views
  • 6 comments
  • 24 respects

Rural Hack Kit

by Officine Innesto

  • 3,578 views
  • 0 comments
  • 5 respects

A Model Lighthouse Using an Adafruit NeoPixel Ring

Project tutorial by Jeremy Lindsay

  • 265 views
  • 0 comments
  • 4 respects
Add projectSign up / Login