Pages: [1] 2   Go Down
Author Topic: Super Bright Red Led - BC547B Transistor, but which Resistors?  (Read 2941 times)
0 Members and 1 Guest are viewing this topic.
Brazil
Offline Offline
God Member
*****
Karma: 3
Posts: 616
Wusik Dot Com
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Guys, hope someone could help me with the math, as I can't figure this out just yet.  smiley-red

I plan on using a BC547B NPN transistor to switch On/Off a Super Bright Red Led. But I need to know the resistor for the LED and the resistor for the Transistor. I plan on using a Shift Register (74HC595) to drive 16 Leds from the Arduino.

So, the 74HC595, each output pin goes to one BC547B Transistor base via a Resistor, and so on ... I can draw this if required, but you could also check this page out instead.

http://www.sqlskills.com/blogs/paulselec/post/Arduino-figuring-out-transistors-and-associated-resistors.aspx

I see he did reply about such question, but the transistor and led I'm using may be a bit different from what I see...

Thanks for any help.

Best Regards, WilliamK
Logged


Global Moderator
Boston area, metrowest
Offline Offline
Brattain Member
*****
Karma: 545
Posts: 27352
Author of "Arduino for Teens". Available for Design & Build services. Now with Unlimited Eagle board sizes!
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Making some assumptions:
5V supply
LED has Vf of 2V
10mA LED current flow desired

BC547B: Vce Saturation (Max) @ Ib, Ic:  300mV @ 5mA, 100mA
 
Transistor has Vce of 0.3V
Transistor has Vbe of 0.7V
8mA Transistor base current as 74HC595 is only spec'ed for 8mA at 5V output

Then 5V-LED-resistor-collector-emitter-gnd:
(5V - 2V - 0.3V)/0.01 = 270 ohm resistor

74HC595-resistor-base-gnd:
(5V -0.7)/.008 = 538 ohm. Try 560.
Logged

Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

Brazil
Offline Offline
God Member
*****
Karma: 3
Posts: 616
Wusik Dot Com
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Thanks bud, and yes, its 5V, sorry I forgot to mention. ;-)

I also wonder if I could use 2 of those LEDs in series with the 5V supply?
Logged


Global Moderator
Boston area, metrowest
Offline Offline
Brattain Member
*****
Karma: 545
Posts: 27352
Author of "Arduino for Teens". Available for Design & Build services. Now with Unlimited Eagle board sizes!
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Yes, if their Vf is low enough.
Logged

Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

Global Moderator
Boston area, metrowest
Offline Offline
Brattain Member
*****
Karma: 545
Posts: 27352
Author of "Arduino for Teens". Available for Design & Build services. Now with Unlimited Eagle board sizes!
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Adjust resistor then:
(5V-Vf-Vf-Vce)/current = resistor
Logged

Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

Brazil
Offline Offline
God Member
*****
Karma: 3
Posts: 616
Wusik Dot Com
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Perfect! I'm learning, thanks!  smiley-cool

One thing, how can I know the details of a LED? I bought in bulk, all I know is that they are super bright red leds. (I think they are 5mm, I could measure)

They look just like this one:

http://www.ebay.com/itm/100-Pcs-5mm-Red-Superbright-diffused-LED-Light-lamp-2-Pins-5000-6000-Mcd-/180967282597?pt=LH_DefaultDomain_0&hash=item2a227d97a5
Logged


Brazil
Offline Offline
God Member
*****
Karma: 3
Posts: 616
Wusik Dot Com
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Oops, actually they were called "5mm Red Ultra Bright" (I copied this from the purchase I made)

So they are like this:

http://www.ebay.com/itm/100pcs-OF-RED-5mm-ROUND-HEAD-ULTRA-BRIGHT-8000-mcd-/271047071506?pt=LH_DefaultDomain_0&hash=item3f1baa1712

FORWARD VOLTAGE: 2.3 VOLT
FORWARD CURRENT: 20 MA
Logged


Global Moderator
Boston area, metrowest
Offline Offline
Brattain Member
*****
Karma: 545
Posts: 27352
Author of "Arduino for Teens". Available for Design & Build services. Now with Unlimited Eagle board sizes!
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Connect one from 5V to Gnd with 270 ohm resistor, measure the voltage across - now you know Vf.
Most LEDs are spec'ed for 20mA continuous.
High brightness LEDs, like 5000mCD kind, are blindingly bright.
270 should yield around 10mA. Measure the voltage across the resistor & confirm: V/R = I.
Or put multimeter in mA mode and wire in series from resistor to gnd.
Logged

Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

Brazil
Offline Offline
God Member
*****
Karma: 3
Posts: 616
Wusik Dot Com
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

One thing I'm wondering is to just do a matrix of leds instead of using the shift c595 ic. Any ideas on that?

For 16 leds using the C595, I would need two x C595, a resistor + transistor + resistor for each led.

Now, for a 4 x 4 Led Matrix (total of 16 leds) connecting directly to each pin on the arduino, I would have 4 pins for the row and 4 pins for the column. Now, wouldn't I use less ICs? I know that I will need to use a timer to handle the leds, just like SparkFun did on the 4x4 Button SPI product.

Anyway, just brainstorming out loud ... ;-)
Logged


Global Moderator
Boston area, metrowest
Offline Offline
Brattain Member
*****
Karma: 545
Posts: 27352
Author of "Arduino for Teens". Available for Design & Build services. Now with Unlimited Eagle board sizes!
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Sure, 4x4: 4 pins with resistors to drive anodes, ULN2003 to sink cathodes.
Do it all from a shift register if you want. Use TPIC6B595 and 4 pullup resistors.
0 on Anodes - don't pull low, allow resistor to soure current,
1 on Cathode column to turn on.

Write blink without delay type code, every 5mS output next set of anodes and next cathode.
Rest of the time, do whatever you're gonna be doing.
Logged

Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

Brazil
Offline Offline
God Member
*****
Karma: 3
Posts: 616
Wusik Dot Com
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Oh, thanxs!

I got some ULN2803A here, would those work too?
Logged


Brazil
Offline Offline
God Member
*****
Karma: 3
Posts: 616
Wusik Dot Com
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

But I guess using a 4x4 matrix will present less light brightness compared to the other solution, right?
Logged


Global Moderator
Boston area, metrowest
Offline Offline
Brattain Member
*****
Karma: 545
Posts: 27352
Author of "Arduino for Teens". Available for Design & Build services. Now with Unlimited Eagle board sizes!
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

ULN2803 will work great (8 drivers vs 7).
If you were running the original at 20mA, and now you are multiplexing so each column sees 1/4 of that, then maybe yes.
If you were running original at 5mA because your wife was complaining it was too bright and shielding her eyes every time you powered up, then perhaps you could inrease the current some in multiplex mode to get back to the same perceived blindingly bright level.
Logged

Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

Brazil
Offline Offline
God Member
*****
Karma: 3
Posts: 616
Wusik Dot Com
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

I need it to be as bright as possible, since a plexy will go on top of the LEDs. ;-)
Logged


Global Moderator
Boston area, metrowest
Offline Offline
Brattain Member
*****
Karma: 545
Posts: 27352
Author of "Arduino for Teens". Available for Design & Build services. Now with Unlimited Eagle board sizes!
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

In that case, run the 16 LEDs from 2 TPIC6B595 and crank up the current to eye blistering level smiley-cool
Logged

Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

Pages: [1] 2   Go Up
Jump to: