Connect WS2812 LED Ring to an ATTiny85

Using an ATTiny85 with a WS2812 LED Ring

WS2812 NeoPixel Ring Connected to ATTiny85

The NeoPixel WS2812 LED Ring and Arduino ATTiny85 are the perfect combinations for the creation of elegant LED lighting solutions.

Arduinos are wonderful and easy to work with and available in various sizes, depending on your computing requirements. The ATTiny85 based controller features six input/output connections with a clock running at 16MHz. Memory onboard includes 8k of Flash memory with 512 bytes of RAM.

The capabilities of the ATTiny85 allow for interfacing possibilities with many types of sensors, controlling different types of loads, and even the options of driving addressable LEDs like WS2811, WS2812 NeoPixel display.

An alternative to mounting for the ATTiny85, could be to use our Proto Arduino prototype board which is compatible with both the ATTiny85 and the Arduino NANO processors.

ATTiny85 to LED Ring Connection

WS2812 NeoPixel Ring Connected to ATTiny85

The interface between the ATTiny85 and the display boards requires only three connections. Power, Ground, and Signal are all that is necessary.

  • The Power and Ground solder pads on each ring are connected to each other to provide power to each of the rings.
    • Run a single wire from each Vcc pad on each ring and attach it back to the ATTiny85
    • Follow the same process for the GND connection on each ring.
  • The Signal lead should also include a series resistor to protect the processor from stray voltages coming back on the signal pin. We recommend a 470-ohm, one-quarter watt resistor for the series protection resistor. The connection process for the signal lead is:
    • From the P1 pin on the ATTiny85, connect to one side of the 470-ohm resistor
    • The other lead of the 470-ohm connects to the DI (Data In) solder pad of the first ring
      • To attach to the next ring, a connection is established from the DO (Data Out) pin and connected to the DI pin on the next ring
    • The DO to DI jumper is applied to each ring (from the 24-LED board to the 16-LED board, from the 16-LED board to the 12-LED board, from the 12-LED board to the 8-LED board and finally from the 8-LED board to the 1-LED board).
WS2812 NeoPixel Ring Connected to ATTiny85 - Close-Up Showing Series Resistor

ATtiny85 Software Sketch for NeoPIXEL Ring Set

When you have completed connecting your ATtiny85 to the NeoPIXEL ring set, you require software for your ATTiny85. The software sketch is programmed into your ATtiny85 using the Arduino software.

The software sketch is a demonstration displaying some of the possibilities and effects possible. The code can be modified to select only the variations you need or you can expand upon the sample provided.

Code Download: (updated 2021-09-21)

Why A Series Protection Resistor?

We have recommended a resistor on the DI lead from the ATtiny85 to the first LED ring. There were several people inquiring why it was there. This is a good question as all the prototype systems we built did not include the series resistor.

The best explanation we have for the resistor is if you supply power separately to the LED Rings and another supply to the ATtiny85. This would be very common if you have larger strings of LEDs, which would require more current to operate. With the series resistor, this would limit the possibilities of current flow between the two separate power supplies. If you are only going to use a single power input to the circuit, the 470-ohm resistor would be optional and not required to operate.

WS2811 or WS2812 – What Is The Difference

There are times where you will see reference made to the WS2811 and other times to the WS2812. A WS2812 is a complete single LED package that includes the LED elements and also the constant-current driver and decoding electronics. The WS2811 is the driver chip which integrated into to the WS2812 LED module.