more led's

I am a bit new at the arduino and i was wondering how i could use 46 led's from my arduino. (less or more led's doesn't really matter)

I have read some other topic's but i didn't understend it very well.

could some one explain it very clear how it work's.

(sorry for my bad Englisch)

Say you have N arduino pins that you can use as digital outputs. (N is up to 19 on a duemilanove, since you can reuse the analog inputs as digital outputs if you really want to. A more realistic number is probably 11 pins, using only digital 2-13 (leaving 0/1 free so as not to interfere with upload and communications)

Assuming that you want "individual control" of each LED, and keeping in mind that at some point you also have to worry about exceeding the maximum current and/or power that the arduino can provide...

Connecting LEDs directly allows N LEDs to be used.

Using "multiplexing", you can have up to (N/2)2 LEDs. (actually, up to X*Y LEDs, where X+Y=N; 30 LEDs for 11 pins) Multiplexing is a technique where you connect the LEDs in rows and columns, with a pin for each row and column, and then light one row or column at a time, going through all of them too fast for the eye to detect flickering.

Using "charlieplexing", you can have up to (N*(N-1)) LEDs. (110 leds on 11 pins.) Charlieplexing is like multiplexing, but utilizes the "off" state possible with most microcontrollers so that the same pins can be connected to both a row and a column.

"LED multiplexing" and "charlieplexing" are both fine web search phrases that will turn up lots of information, explanations, tutorials, and even complete projects.

Using various forms of external hardware expansion, you can control essentially any number of LEDs, limited mainly by the communications speed with that external hardware, and the size and complexity of the program and data you need to control it. Peggy 2 is an example of essentially arduino-like hardware controlling 625 LEDs. (at some point, the external hardware exceeds the cost and complexity of the arduino itself, of course.)

Note that multi-color LEDs actually contain multiple LED chips internally, so that an RGB LED (for example) actually "counts" as three separate LEDs...

Thank you very much.

I still have a few questions about that Peggy board.

  • can you program it with your arduino?

  • can you extend the led's to something else so you can make for example a led table?

There are a number of available shields that will let you do that. Maybe the best for low power LEDs is one using the M5451 constant current chips. There is the CCShield/Lightuino: effluvia of a scattered mind: Lightuino V2.0 -- An Arduino compatible optimized for driving LEDs

Mowcius

Tanks: Mowcius
That lightuino seems realy good.

Would the rainbowduino work?

Umm it is a similar idea but the rainbowduino:

24 constant current channels of 120mA each

CCShield/lightuino:
70 constant current channels (not sure of the current for each one)

Mowcius

yeah oke the lightuino is better indeed but do you now how much he ask's for it

Well when I bought a CCShield prototype board (without all the flashy stuff on it) it was $35 or something like that so it might be edging on $45-50 or something. Take that with a pinch of salt though as I really don't know how much he will be charging.

Mowcius

Oke thank you very much.

I will think about buying it.
I am going to use it for a led coffee table

Hi mowcius! How's it going? Thanks for mentioning my Lightuino!

caz2406: I generally tell people that the difference between the Rainboduino and the Lightuino is that the Rainboduino is optimized for LED matrices (i.e. those 8x8 grids of 64 LEDs that you find in signs) while the Lightuino is optimized for placing individual LEDs where you want them. Since the Lightuino drives 70 constant-current outputs, you don't even need to put resistors in series with your LEDs. You literally just hook each LED up to a common power (i.e. +) and to the Lightuino "outputs" (actually the lightuino "sinks" conventional current for you hardware geeks). And it comes with a settable voltage regulator so its easy to send the exact voltage you need to your LEDs.

I haven't checked the Rainboduino site for a while but last time I did, these were the other differences:

  1. The Rainboduino runs a 168 I think, the Lightuino has a 328. So you get a lot more program space and RAM in the Lightuino.
  2. Lightuino is 100% Arduino shield compatible (and it even lets you change which pins control the LEDs, in case your shield has fixed pins). The Rainboduino is not Arduino shield compatible (but you can plug a LED matrix directly into it so that's a real bonus for those doing matrices)
  3. I have a open-source site with code that makes it easy to drive the board.
  4. The Lightuino uses a FTDI cable, which is commonly used in many Arduino clones and generally available. The Rainboduino has some strange connector system to program it that I didn't really understand when watching the video.
  5. Lightuino drives 70 LEDs at 15mA (watt averaged). The Rainboduino can drive fewer but higher mA LEDs.

Anyway last thing to note is that the Lightuino drives those 70 LEDs constant (unless you want them dim). Charlieplexing, matrixes, etc all blink the LEDs. This is how they manage to control more LEDs then wires. So a 15mA LED driven 100% of the time is equivalent to an 120mA LED driven 1/8 of the time (i.e. an 8 row matrix)

Good guess on the price Mowcius!

Send me an email at g dot andrew dot stone at gmail dot com if you are interested, or a message here.

Below is a method of making a controller box for controlling many strings of christmas lights via a parallel port. The same thing can be done from a controller with I/O capability. I've done similar setups using 74HC259 latching chips.

http://computerchristmas.com/christmas/link-how_to/HowToId-4/How_To_Build_A_Parallel_Port_Controller_Box"

Hi mowcius! How's it going? Thanks for mentioning my Lightuino!

No problem. If you are asking about the CCShield then it is still working... I have not really used it apart from a bit of a play around testing it. I tried it with an LED matrix ages ago and got it working but the refresh rate was a bit slow (because of how I did the code). I am just waiting for the perfect project to use it with!

I just had a look at your site a few days before this topic came up and the lightuino looked good so I thought I would mention it!

Mowcius

Mowcius