0

Neopixel ornament
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

Neopixel ornament

by michaelmeissner on Fri Dec 20, 2013 10:57 am

I was planning on sending a Christmas ornament to my relatives this year that had a neopixel ring that would vary the colors, using a raw ATtiny85 to drive the ring, and a USB charging cable to deliver 5v. I was going to put a family portrait inside of the ring, and a hanger to hang it on the Christmas tree.

Unfortunately, my soldering skills are not yet up to the challenge of connecting the parts and also real life has thrown me some curve balls, so I will not make the mailing deadline to send it out this year.

I sort of wish I had just planned to use a Gemma, instead of going the DIY way, since with the Gemma, you just need to connect 3 wires and a USB cable, and you are done. However, at the time I made the choice, I was still struggling to get the timing right for uploading the Gemma, and I wanted to save a little money.

I've decided to put out the code in case it helps somebody else. What this code does is alternate between two patterns.

The first pattern goes between all red and all green, fading the colors to do the transition.

The second pattern starts with a solid color, and then starts a simple chase pattern, where another color fills in a pixel, and then goes around for a few iterations, setting the next pixel, and resetting the first pixel to the background color. At the last iteration, it fills in the color.

I'm going to have to attach it as a file, since one word in the standard GNU copyleft header (F.I.T.N.E.S.S.) is a banned word on this forum.
Attachments
Christmas-2013.zip
Source code for Michael Meissner's 2013 neopixel ornament
(15.84 KiB) Downloaded 53 times

michaelmeissner
 
Posts: 1585
Joined: Wed Aug 29, 2012 12:40 am

Re: Neopixel ornament

by adafruit_support_mike on Sun Dec 22, 2013 12:25 am

MichaelMeissner wrote:I'm going to have to attach it as a file, since one word in the standard GNU copyleft header (F.I.T.N.E.S.S.) is a banned word on this forum.

The link spammers just get more creative as the days go by..

Thanks for posting the code! ;-)
When you void a product warranty, you give up your right to sue the manufacturer if something goes wrong and accept full responsibility for whatever happens next. And then you truly own the product.

adafruit_support_mike
 
Posts: 64984
Joined: Thu Feb 11, 2010 2:51 pm

Please be positive and constructive with your questions and comments.