0
Offline
Newbie
Karma: 0
Posts: 20
Prototype Limited Edition owner! lol
|
 |
« on: September 25, 2010, 07:23:47 am » |
Hi, im using 5 digital pins and one 4067 16channel multiplexer to multiplex 16 x 5 LED's. To multiplexer pulls the LED's to ground. (Its for my 16steps sequencer) The problem im having is that, some led's glow faint when they should be off... I have the feeling im missing some diodes? but dont know where? here is the schematic, Ow before the LEDS are 220 ohm resistors ofcourse. 
|
|
|
|
« Last Edit: September 25, 2010, 07:24:31 am by Intosia »
|
Logged
|
|
|
|
|
Stockholm
Offline
Newbie
Karma: 0
Posts: 34
Arduino rocks
|
 |
« Reply #1 on: September 25, 2010, 07:37:34 am » |
I had similar problems with a 4051 multiplexer. The answer I got that it was not good with driving LEDs, read this discussion: http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1281382049
|
|
|
|
|
Logged
|
|
|
|
|
Manchester (England England)
Online
Brattain Member
Karma: 271
Posts: 25419
Solder is electric glue
|
 |
« Reply #2 on: September 25, 2010, 07:37:38 am » |
Sorry but that is just not the way to multiplex LEDs or the way to use that multiplexer. You seem to be feeding 5V into the vase of your transistors with no current limiting resistors at all. That circuit is just pants.
|
|
|
|
|
Logged
|
|
|
|
|
0
Offline
Newbie
Karma: 0
Posts: 20
Prototype Limited Edition owner! lol
|
 |
« Reply #3 on: September 25, 2010, 07:59:00 am » |
Ok so it need a 1K resistor on the Base? I dont see the problem with the idea? I got it from this: http://nzlamb.files.wordpress.com/2010/04/led-multiplex-schematic.pngI replaces the 7seg with led's and hooked the transistors to the 4067. But like i said i know something is wrong with it, so any suggestions?
|
|
|
|
|
Logged
|
|
|
|
|
Manchester (England England)
Online
Brattain Member
Karma: 271
Posts: 25419
Solder is electric glue
|
 |
« Reply #4 on: September 25, 2010, 08:03:07 am » |
I dont see the problem with the idea? Only that what you have is nothing like that schematic you posted, and this is not the way to use an analogue multiplexer.
|
|
|
|
|
Logged
|
|
|
|
|
0
Offline
Newbie
Karma: 0
Posts: 20
Prototype Limited Edition owner! lol
|
 |
« Reply #5 on: September 25, 2010, 08:12:49 am » |
Ok... Any suggestion how i multiplexer 16x5 leds? And i dont want so daisychain shiftregisters, thats way to slow (updating 80 leds every time).
|
|
|
|
« Last Edit: September 25, 2010, 08:13:02 am by Intosia »
|
Logged
|
|
|
|
|
Manchester (England England)
Online
Brattain Member
Karma: 271
Posts: 25419
Solder is electric glue
|
 |
« Reply #6 on: September 25, 2010, 08:28:23 am » |
|
|
|
|
|
Logged
|
|
|
|
|
0
Offline
Edison Member
Karma: 0
Posts: 1103
Arduino rocks
|
 |
« Reply #7 on: September 25, 2010, 09:04:35 am » |
i dont want so daisychain shiftregisters, thats way to slow (updating 80 leds every time). In fact it is very fast.... With standard shiftOut() it will take 1 ms (still fast) With digitalWriteFast() it should be < 50us.
|
|
|
|
|
Logged
|
|
|
|
|
Austin, TX
Online
Faraday Member
Karma: 41
Posts: 5165
CMiYC
|
 |
« Reply #8 on: September 25, 2010, 09:07:40 am » |
And i dont want so daisychain shiftregisters, thats way to slow (updating 80 leds every time). Your eyes are are much, much slower.
|
|
|
|
|
Logged
|
|
|
|
|
0
Offline
Newbie
Karma: 0
Posts: 20
Prototype Limited Edition owner! lol
|
 |
« Reply #9 on: September 25, 2010, 09:12:09 am » |
Hm, well maybe speed isnt the real issue, but its just that i have to wire up all the 80 leds seperatly... If i multiplex them per 5 (per step on the sequencer), i have 5 wires and then i can connect them all to them on the frontpannel.
|
|
|
|
|
Logged
|
|
|
|
|
0
Offline
Edison Member
Karma: 0
Posts: 1103
Arduino rocks
|
 |
« Reply #10 on: September 25, 2010, 09:14:36 am » |
To stop Mike's cat-and-mouse play.
You should use a DIGITAL multiplexer (and of course also base resistors). The analog multiplexer outputs (well, "throughputs") will become high impedance when de-selected.
You can mend this by base pull-downs (100k or such)
OTOH the internal resistance of the analog channels (100 ohms) results to a current limitation (45mA) that MIGHT be acceptable to your transistors.
|
|
|
|
« Last Edit: September 25, 2010, 09:17:32 am by mpeuser »
|
Logged
|
|
|
|
|
0
Offline
Newbie
Karma: 0
Posts: 20
Prototype Limited Edition owner! lol
|
 |
« Reply #11 on: September 25, 2010, 09:21:23 am » |
Ok digital multiplexer makes more sence indeed, its just that i have the analog laying around  So would need to make a pulldown construction like this? The switch would be the multiplexer then? 
|
|
|
|
« Last Edit: September 25, 2010, 09:22:20 am by Intosia »
|
Logged
|
|
|
|
|
0
Offline
Edison Member
Karma: 0
Posts: 1103
Arduino rocks
|
 |
« Reply #12 on: September 25, 2010, 09:28:49 am » |
Yes, that should work. One typically would connect R3 directly to the base to stress its intention, but that makes no difference at all.
Edit: ----- .. and it would suffice to have just ONE base resistor (1k or such) at the 5V INPUT of the multiplexer rather than 8 at the outputs. But you need 8 base pull-downs, of course!
|
|
|
|
« Last Edit: September 25, 2010, 09:32:22 am by mpeuser »
|
Logged
|
|
|
|
|
0
Offline
Newbie
Karma: 0
Posts: 20
Prototype Limited Edition owner! lol
|
 |
« Reply #13 on: September 25, 2010, 09:34:10 am » |
Ok thanks all! Ill try some stuff on my breadboard 
|
|
|
|
|
Logged
|
|
|
|
|
0
Offline
Newbie
Karma: 0
Posts: 20
Prototype Limited Edition owner! lol
|
 |
« Reply #14 on: September 25, 2010, 11:11:53 am » |
Nice, works perfectly! 
|
|
|
|
|
Logged
|
|
|
|
|
|