0

empowering creative people

Addressable RGB LED Controllers

neopixel-closeup

Addressable RGB LED strips are one maker favourite that can really spruce up any project or even be the star attraction of one. These strips allow you to select the colour, brightness and state of any LED in a long strip and can make for some truly spectacular lighting effects. If you've ever been looking to pick up a LED strip, you'll have noticed that you're met with 3 options as far as the controller of the strip goes; the WS2812B, the SK61812, and the APA102C. We're going to do a bit of a comparison of these 3 types of RGB LED controller and discuss why you would pick one type over any other. As with any comparison, let start with what's similar before we delve into what is different between all the different types of LED strips.

All LED strips come in lengths of usually 1m or 5m. They also all come in different densities, that is the number of LEDs that are crammed into a 1-meter roll. The standard LED densities for strips is 30 LEDs/meter, 60 LEDs/meter and 144 LEDs/meter. On their own, LED strips don't do anything at all, you need to control them using the GPIO pins on a microcontroller, like the ATmega328 on the Arduino Uno, and some code (multiple libraries are available for the different types of LED strips). This is done so that you can address and control the colour and brightness of each LED individually. When it comes to RGB LED strips, you will have likely heard of NeoPixel and maybe even DotStar LED Strips, both are fantastic RGB LED strips from Adafruit that run on the controllers we're about to discuss. If you want to see or learn about them and how they work, go ahead and check out their respective tutorials below:

The long story short with NeoPixels and DotStar LEDs is that each of them uses a different LED controller, making them suitable for different applications, and they are both incredibly easy to use. As always, our friends over at Adafruit have put together some fantastic libraries and content discussing the high-level differences between their two types of LED strips, you can view all that good stuff here.

However, we're more interested the in the differences between the LED controllers. In the case of the NeoPixel it is the WS2812B (datasheet) or SK6812 (datasheet) controller chip and in the case of the DotStar Strip, it is the APA102C (datasheet) chip. We want to know how each of these work, the limitations of each one and finally, which one is suited for which applications and why. We've compiled most of the information in this table but there is a more detailed discussion of the differences below.

table-comparison-ws2812b-sk6812-apa201c

The WS2812 (or WS2812B)

The WS2812 Integrated Light Source is a programmable constant current controller hidden beneath a 5050 sized RGB LED package. It doesn't use a standard communication protocol for LED control though, instead, it handles control by precisely timed software I/O toggles, otherwise known as bit-banging. Originally, the WS2812 was the kingpin of the LED strip market, but it has since been upgraded to the WS2812B - which uses a one-wire interface alongside power and ground to allow you to chain LEDs together for (theoretically infinitely long) LED strips. We'll just refer to it as the WS2812 in this write-up.

Essentially (and very simply), the WS2812 takes in 24 bits of data (the colour information for green, red and blue LEDs) and then (after receiving a reset) passes the rest of the data string out to the next WS2812 in the strip. Indirectly, this means all of the data for your LEDs needs to be buffered in memory and then sent out to your strip as a long data stream. Each LED you to have in the strip requires 3 bytes of memory, meaning you can pretty quickly chew up the SRAM on an Arduino Uno or similar MCU with a ~500 LED strip.

While there is no theoretical limit to how many LEDs you can have in a strip of WS2812's, there are certain complications that arise when you start getting to massively long strips. For the 1 LED to be at full brightness, you can expect 60mA @ 5V power requirement, which scales pretty terribly for most power supplies (500 LEDs is approaching a 30A supply!). Each LED requires 30 microseconds for data to be received and an additional 50 microseconds for the data to "latch". Although, the actual transmission delay between LEDs is 0.5 microseconds (which is quite low, even when scaled).

All in all, the WS2812b is a robust and popular LED controller purely because it works so simply, especially when using Adafruit's NeoPixel Library or one of the communities made ones like FastLED. Although, the lower refresh rate means that it isn't great for POV style applications. However, if you need something for that the APA102C based DotStar LED strips are the way to go (we'll get into that below). But for a stationary colour, basic fading effects or any other basic animations, the WS2812 works quite well.

The SK6812

The SK6812 appeared in the LED strip market in 2016, as an almost direct clone of the WS6812. Interestingly, this means that most of the above description for the WS2812B applies entirely to the SK6812. There we some minor improvements between the two chips, however, the timing 'improvements' aren't enough to make the chips incompatible with each other, meaning you can daisy chain an SK6812 to a WS2812b without any real issues.

The most major differences between the two chips are the refresh rate increase up (to 1.2kHz from 400Hz on the WS2812b), which is still not quite fast enough for POV applications. The other being the inclusion of a White LED in the RGB package, meaning it's actually an RGBW LED.

All in all, though, all the information on the WS is directly applicable with the SK6812.

The APA102C

The APA102C is an all-around improvement to the WS2812b. All of the timing considerations to bit-bang out your LED data-stream are solved by using a standard SPI interface to control the strip. Of course, this means that you are using 4 total cables for your strip not including power (as opposed to the 1 required with the two options above).

The best part about using SPI is that it opens the door to being able to use your LED strip completely independent to timing considerations that hindered the WS2812b; timing was so specific and important bit banging data streams that it doesn't play well with a SBC running an OS. Another fantastic upgrade is that the PWM frequency of the APA102C is 19.2kHz (that's almost 20 times the speed of the SK6812 which was 3 times the WS2812b). This refresh rate breaks through to one that is valid and works well for POV applications, which is great for makers everywhere. The only real issue with an APA102C strip is that the price of the strip is quite a bit higher than it's simpler alternatives, but completely worth the jump up if you need POV capability.

Addressable RGB LED strips are one maker favourite that can really spruce up any project or even be the star attraction of ...

Have a question? Ask the Author of this guide today!