Pages: 1 ... 3 4 [5] 6 7 ... 9   Go Down
Author Topic: Problem when expanding on the ShifOut tutorial for LEDs  (Read 6578 times)
0 Members and 1 Guest are viewing this topic.
0
Offline Offline
Sr. Member
****
Karma: 0
Posts: 340
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

What, specifically should I test???

I'd love to wire it 'correctly' but 'correctly' doesn't work for me. Here are the configurations I tested today in addition to the ones tested earlier:
"Working configuration" is defined as the normal circuit except 5v from arduino is removed, only one cap placed on the +- rails near first chip instead of several spread out, LED w. resistor going from Vcc of chip one to ground.
1) starting from the "Working configuration", unplug cap and LED, plug in 5v from arduino = unresponsive.
2) same as scenarios 1 but chip 1 is separated from the others = unresponsive
3) starting from the "Working configuration", unplug LED = unresponsive
4) starting from the "Working configuration", unplug cap = responds but is so noisy it is unusable.
5) starting from the "Working configuration", add more caps along the +- rail, one by one = gets noisier and noisier.

I'm trying my best to give you as much info as possible to make it as easy as possible to solve this. The only thing wrong with the "Working configuration" is a little bit of noise. By noise, I mean that one-five LEDs will turn on when it's not supposed to, intermittently.

What, specifically should I test???
« Last Edit: May 07, 2012, 01:59:21 pm by David82 » Logged

Offline Offline
Sr. Member
****
Karma: 0
Posts: 339
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

The blinking u say when it shouldnt, u mean each time another ne blinks, others close blink as well?!? U using three wires to send the data?? Is it latched ?!? as far as i can gather it isnt is it ?!?
PS- It is, ignore it.

All it seems is you probably have either a mistake there( normally its soldering, cold solders, bulky ones that are creating enough cross voltage kinda thing or something, then.
As u see Nick proved it works, and determined what were the causes of the initial noise, etc.
So only you can localize the fault.
Dont worry as that happens to all of us from time to time.
And everytime tends to be our faulg, as usual...Something we passed without noticing
« Last Edit: May 07, 2012, 02:20:49 pm by iyahdub » Logged

10 LET Loop=Infinite
20 GO TO 10

0
Offline Offline
Sr. Member
****
Karma: 0
Posts: 340
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

That doesn't help iyahdub. I need to know what tests to perform to resolve the noise.
Logged

Offline Offline
Sr. Member
****
Karma: 0
Posts: 339
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I thought i was helping you actually- You affirmed yourself that it is a mess( and we got there, cause its not normal disconnect the positive and work better ?!?!?).
So i thought that going rechecking everything would be a good point to start ( Continuity, cross solders, etc).
 But if you know better...
Logged

10 LET Loop=Infinite
20 GO TO 10

Global Moderator
Offline Offline
Brattain Member
*****
Karma: 452
Posts: 18694
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

1) starting from the "Working configuration", unplug cap and LED, plug in 5v from arduino = unresponsive.

But why? You are saying if you power up the chips they stop working. Why? Is the ground common? Are you, perhaps, drawing too much power from the Arduino board? How much does each LED draw? (can you measure it?).

Say they are drawing 20 mA each. And you have 88 of them. Well that is 1.76 amps. Can your board supply that much? I doubt it. Are you running the board from the USB?

You have to get away from the mindset that it is "working" without power. It is limping along.
Logged

0
Offline Offline
Sr. Member
****
Karma: 0
Posts: 340
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

No problem. I will define working. Working is defined as being able to send 'S' and have them all light up (I have to send that command twice because the last chip doesn't light up until it is sent a second time). Working is also defined as being able to send <nn>s commands in rapid succession and have the appropriate LEDs light up.
Quote
But why?
I don't know why adding the 5v lead makes them unresponsive.
Quote
You are saying if you power up the chips they stop working
Apparently,they are already powered up from pins 10/11/15 but when I add the 5v line, they are unresponsive.
Quote
Is the ground common?
yea. The ground lead is connected from arduino to breadboard.
Quote
Are you, perhaps, drawing too much power from the Arduino board?
I doubt it. It works 98% correctly running off of usb power. I can light them all up just fine and when I'm actually using it for it's intended purpose only about 8-15 LEDs are being lit up. I just get a little bit of noise and one pesky LED that keeps randomly turning on and off when other commands are sent.

I think the fact that that LED has to be hooked up for it to work should be a big clue. What it implies, I don't know. The fact that it has to have one cap, but gets worse if you add more should also be a clue to something.

What software should I use to draw out the schematic and create the breadboard layout? The schematic might help explain it better and it's something I'll need to do to be able to have them manufactured.


Logged

Offline Offline
Sr. Member
****
Karma: 0
Posts: 339
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Well here are the rules for +5vdc usage for output pin current ratings, total processor chip rating, and total board current ratings.

Output pins:     Recommended continuous current, 20ma. Absolute maximum above which will damage pin/chip 40ma (use 20ma recommendation)

Total chip Vcc current (all output pins total and chip overhead): 200ma., i.e. 10 output pin driving 10 leds @ 20 ma is max for whole chip.

Total +5vdc current available for on-board and external use:

If USB powered: 500ma max limited by on-board thermofuse and USB standards.

If powered via on-board +5vdc voltage regulator driven by external power socket (Input Voltage (recommended) 7-12V ) :
not specified, but don't plan on using more then 500ma max.

leds on average are built to draw somewhere around 20mA ( doesnt mean they will draw that, mind)

Can you do your numbers ?

You could do with some NPN transistors  !!
« Last Edit: May 07, 2012, 05:36:00 pm by iyahdub » Logged

10 LET Loop=Infinite
20 GO TO 10

0
Offline Offline
Sr. Member
****
Karma: 0
Posts: 340
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

It would seem that, given the fact the all the LEDS can light up at once and it still functions correctly, that amperage isn't a problem at all. If it was, wouldn't I have issues when telling them all to light up? We have two problems: 1) Why does it have to be wired this way to work? 2) How do we get rid of the little bit of noise that is left? (adding caps makes it worse for some reason).

3) What software should I use to draw out the schematic and create the breadboard layout? The schematic might help explain it better and it's something I'll need to do to be able to have them manufactured.
Logged

Offline Offline
Sr. Member
****
Karma: 0
Posts: 339
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Oh it doesnt ? My guess is that it is what is causing the troubles tpo start with.Someone who done several cubes said that even with several pins( not with registerss, which means that more current is injected) said that a safe number would be around 60.And that was already using 4 npn transistors.Youre using none ?!?
Anyway- Kicad is a free schematic program. what about some photos ?
Logged

10 LET Loop=Infinite
20 GO TO 10

0
Offline Offline
Sr. Member
****
Karma: 0
Posts: 340
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

No one has mentioned using npn transistors before. Which ones do I get and where exactly to I put them? What problem are they supposed to solve? Keep in mind, I'm not using a matrix.
Logged

Global Moderator
Offline Offline
Brattain Member
*****
Karma: 452
Posts: 18694
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

If my eyes don't deceive me you have 220R resistors in series with the LEDs. Assuming they have a 2V forward voltage and you are putting 5V into them then they will draw 13.6 mA each (3/220). That is within the capabilities of the output pins on the shift register, although if all 8 are on at once it may exceed the Vcc current listed for the entire chip (I'm not certain about that). 8 LEDs x 13.6 mA x 5V would be 544 mW which is just over what the chip specs say (500 mW).

So you should be able to manage without the transistors, just, IMHO. However you need to power the shift registers (how many times?) and I suspect NOT from the Arduino, which won't be able to supply 11 x 8 x 13.6 == 1.197 amps.

So, find a separate power supply (eg. a 2 amp wall-wart) and use that to supply +5V to the Vcc of the shift registers.
Logged

Offline Offline
Sr. Member
****
Karma: 0
Posts: 339
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Nick just done the numbers for us...
The transistors help to increase it a bit, but needs to be used with caution.
But you want too many leds.Have a look at special led projects out there, designed to power the leds properly, or just buy one( wont be that expensive anyway).
I, for one, thought that you just wanted to understand the dynamics and code of it all ! Never thought you wanted to keep adding endless numbers of leds lol lol lol What are your plans anyway???! Light the local street party or owt  ?!? lol
Logged

10 LET Loop=Infinite
20 GO TO 10

0
Offline Offline
Sr. Member
****
Karma: 0
Posts: 340
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

So, find a separate power supply (eg. a 2 amp wall-wart) and use that to supply +5V to the Vcc of the shift registers.
I can do that. I should have one with high enough amperage around here somewhere. I'm not sure why I need it though. When used for what's it's designed for, all 88 LEd's are never on all at once.. Maybe 15 at the most. With that critical point being said, how is getting a higher amp power supply going to solve the "it has to be wired in a strange way" problem and the small noise problem?? Do you see what I'm saying? It doesn't follow that it would be an amperage problem since only ~15 are ever on at once at the most. It's never 8 from the same chip either. If the premise for needing more amperage is the fact that 88 LEDs draws 1.2amps, then that is invalidated by the fact that there are really ever only ~15 of them on at one time making the real amp draw around 200ma at the most.

I still don't know why I ave to have it wired the way I have it in order for it to work correctly. I don't understand why the correct wiring doesn't work.
« Last Edit: May 08, 2012, 12:18:58 am by David82 » Logged

Global Moderator
Offline Offline
Brattain Member
*****
Karma: 452
Posts: 18694
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

OK, wire it up in the way that "doesn't work" ... namely with the 5V from the Arduino. Take a clear photo. Post it. Read Mike's comment again:

This is called paricitic powering and is a good way to destroy chips. Unless you connect all the chips to the 5V line you don't stand a hope in hell of getting anything working. Chips are made to take power from their 5V input and ground.
As you try and scale up you get two problems, first you get noise on the supply lines that distributing decoupling capacitors can help with. Second the signals that go to all the chips, like the clock signal, are not strong enough to power all the chips.

Now if you aren't prepared to work hard at solving this "parasitic powering" problem then I'm sorry, it isn't going to work and I'm not going to spend another 5 pages answering "but it almost works" questions.
Logged

0
Offline Offline
Sr. Member
****
Karma: 0
Posts: 340
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset


Logged

Pages: 1 ... 3 4 [5] 6 7 ... 9   Go Up
Jump to: