Arduino Adventures :: Day 5

Published February 27, 2010
Advertisement
As I stated last time, I had decided to try out Charlieplexing as a way of individually addressing 64 LEDs with only 14 I/O pins (9 is all I need for this actually). So I ordered some resistors and some very specific LEDs. Before I get into the build, let me give a high level overview of what Charlieplexing is and how it works, so that you can understand the conclusions I came to later.

Charlieplexing was invented in 1995 by Charlie Allen as a way of driving many LEDs with few I/O pins and nothing but resistors to implement it. It relies on two facts about LEDs:
  1. That they are diodes, thus electricity will only flow through them in one direction
  2. That they have a specific "operating voltage", below which they will not light up even if current is flowing through them

( Instructables has a really great in-depth explanation here. )

Simply put, you hook LEDs up in combinations such that electricity will either not flow through certain LEDs due to the fact they are diodes in the wrong direction, or that electricity will flow through ones you don't want to light up, but not enough current to actually light them:
LED Operating Curve

When all is said and done, only one LED will light up at a time. Thus, individual addressing:
3 Pin Charlieplexing

Now the more astute reader may have noticed I just glossed over something. Yes I can turn individual LEDs on by themselves, but as is dictated by the circuit, I can not turn on all the LEDs at once, in fact not even a third of them, and in practice, you can actually only turn one LED on at a time using this method, which sounds pretty limiting. But there is a way around it: Persistence of Vision.

I'm sure you've seen it used some where before but not known it. The idea is if you can turn a light on and off fast enough, the human eye won't be able to perceive that it was ever actually off, and thus it will look like it is always on. So to make this useful, you "schedule" all the lights that you want to be on, and then the software scans through and turns each one on and off in succession, when it gets to the end, it starts over. You have to be able to scan through the lights enough times per second to fake out the human eye:
Persistence of Vision

So with all that, I set forth to implement a prototype on my breadboard, and have a video of it
">here (it look a long time to make, not because it's long, but because I suck with the video editing software, so give it a watch :D ).
" target="_blank">Arduino Day 5 Video

Now this whole research and prototype cycle allowed me to draw some important conclusions. And they aren't favorable for Charlieplexing :P

There are some small issues that make this method problematic for my application.
  1. The circuit layout does not lend itself to have the LEDs in a grid. It could be designed around, but would be a real pain. This isn't a big one, but it's certainly a consideration.

  2. As the circuit expands with more pins, and you want to have more LEDs on at once, I found the LEDs got dimmer. This could be for one of two reasons (or both). It could be the fact that the circuit itself is larger and has more resistance built into it over all (and the current is being split many different ways), and the more LEDs are scheduled to be on, the longer each LED will be off for during a given "scan". Now you can counteract this, by using lower ohm resistors to increase the overall current in the circuit, but then you run into the issue of the "compliment drive" LEDs lighting up dimly when they shouldn't.

And that last issue is a problem I ran into even in my small circuit.

So where does this leave me!

Well it leaves me out in the cold as far as Charlieplexing is concerned.

But I got to thinking... my original idea of using demultiplexers could still work, so that's where I am at, I have a few ideas I'm going to explore on paper, and I'll post when I have something concrete.
0 likes 0 comments

Comments

Nobody has left a comment. You can be the first!
You must log in to join the conversation.
Don't have a GameDev.net account? Sign up!
Advertisement
Advertisement