Charlie-plexing

This forum is for posts that might be considered off-topic but that may be useful or interesting to members. Examples include posts about electronics or programming in general, other microcontrollers or interesting devices, useful websites, etc.
Post Reply
Don_Kirby
Posts: 341
Joined: 15 October 2006, 3:48 AM
Location: Long Island, New York

Charlie-plexing

Post by Don_Kirby »

Many of my projects involve some sort of LED display; RBG, bi-color, numeric, etc... The current project needed several go/no-go indicators, and bi-color LEDs seemed the most appropriate. As I was running short on I/O pins, I began looking for another solution that didn't require additional hardware. What I found was the Charlieplex method, which I had never heard of before. n I/O pins can control n(n-1) LEDs, so for my 8 LED array, the pin count is 4, but I could control 12 LEDs with those same for pins if needed.

Now, to be fair, there are some serious drawbacks to the method. First, you can't light more than 1 LED at a time, although cycling through them quickly can overcome that limitation fairly easily. The second (and perhaps more serious) limitation pertains to the failure mode of the array. The failure of a single LED (open or short) can result in the unintended lighting of other LEDs in the array, making diagnosing the failed component difficult at best.

I probably wouldn't use it on a commercial device, but for homebrewing, Charlieplexing might do the trick when you're running out of I/O pins to drive LEDs.

-DK
dlh
Posts: 395
Joined: 15 December 2006, 12:12 PM
Location: ~Cincinnati

Post by dlh »

There are a few app notes from Microchip that list numerous unconventional methods to stretch the capabilities of the hardware. While some are specific to Microchip's PICs, many are equally applicable to AVRs. Search using Microchip Tips Tricks. I think this is the biggest one... http://ww1.microchip.com/downloads/en/D ... 01146B.pdf
Don_Kirby
Posts: 341
Joined: 15 October 2006, 3:48 AM
Location: Long Island, New York

Post by Don_Kirby »

Fantastic information. Thanks for passing that along.

-Don
Post Reply