View Full Version : New WS2811 LED controller firmware for Teensy 3.0

07-27-2013, 08:44 PM

I wanted to announce a new open source firmware project that uses the Teensy 3.0 to control WS2811/WS2812 LED strips. This one builds on OctoWS2811, adding an interpolation and dithering engine that lets it do much smoother colors and fades than you'd get otherwise. Some quick stats:

512 LED pixels per Teensy board
395 FPS hardware refresh rate
Temporal dithering algorithm, for 48-bit color
Color correction and gamma in firmware
Efficient USB protocol
Smooth interpolation between keyframes
Open Pixel Control server for Linux & Mac, including Raspberry Pi

The project is called Fadecandy, and it's on GitHub:

Hope some of you find this useful. The temporal dithering algorithm is something I've been excited to use, since it finally opens up the door for subtle effects that look good over a wide range of brightnesses. It's hard to convey the difference in video or photos, but if you have a Teensy that's already set up for OctoWS2811, I'd encourage you to give this project a try.


07-28-2013, 06:07 AM
This looks really great. I just ordered a reel of WS2812Bs, I will definitely try this out.

Thanks for the work.

07-29-2013, 11:03 PM
This looks awesome, thanks! The server in particular may save us a ton of time on our current project, as we were about to roll our own similar server code on the Beaglebone (using the Philips Color Kinetics Ethernet protocol.)

The only problem is that we are already committed to 1000 pixels per Teensy / ~128 pixel strands. Are there any simple tradeoffs we could make to modify your library to use more LEDs? Only getting half the frame rate would be okay.

07-29-2013, 11:07 PM
PS. The project in question is a 17' climbable steel sculpture for Burning Man: http://penrosetriangle.com

08-05-2013, 11:19 PM
Running an 128-pixel-per-strip experiment with modified firmware that doubles every pixel and turns off double buffering to fit in the Teensy's memory. So far it looks pretty good!

08-06-2013, 10:53 AM
A nice project! And it seems to be well documented. I want to create something with that, using some external sensors. But the strips seems to be too expensive.

5m/300 leds for 100$:

Is there something cheaper on the market?

08-06-2013, 03:01 PM
I found Ray Wu's store on AliExpress at the DIY Christmas light forum via a web search for the WS2812, several comments there say it's the least expensive and I haven't found anything cheaper. Here's a 4M strip for $60 ($45 + $15 shipping):


which works out to $0.25/pixel, cheaper than the $0.32/pixel from the eBay strip (albeit 1M shorter).

The absolute cheapest option I know of is to buy the component LEDs unassembled -on reels of 1000 they're $0.14 ea:


in larger quantities they're even less expensive, but you'd have to make your own PCB to mount them and solder them yourself.

08-12-2013, 04:36 PM
Thank you for the links potatotron! They help me for my project! And 0.14$ for a RGB led + 2811 chip is a dream price (hoping the quality and durability is ok)!

I found this post from Paul:

It is not only a crazy idea... it is really crazy what he did with this teensy using the DMAs!
I am able to communicate with other devices and change the colors of the strips without feeling any delay!

08-13-2013, 10:03 PM
In the description, "For large installations, it's usually easier to run the USB signals long distances and place the Teensy boards close to your LEDs." What is considered long distance? I'm thinking about using it in a location that could be 10 meters from a weatherproof area to house the T3.


08-13-2013, 10:09 PM
5 meters is "long" for USB.

There are plenty of long USB extension cables on the market in the 10 meter range, some with little amplifiers to supposedly boost the signal. They technically violate the USB spec (so you won't see the official USB logo on them), but they usually work.

08-14-2013, 06:47 AM
I have extensive experience using out of spec cables. For USB 12Mbit, 10m usually works. For 480Mbit, things are usually ok with 5m, but iffy with longer cables.

My experience with those extension cords that have a single USB port used as repeater and unpowered USB hubs is quite bad (most of them not working reliably). Chaining USB hubs is allowed by the spec.

08-14-2013, 09:17 AM
Thanks, guys, I missed that the connection was USB.