Pages: 1 [2]   Go Down
Author Topic: Aiuto per calcolare resistenze per LedCube  (Read 1536 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Newbie
*
Karma: 0
Posts: 26
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

"resistance for the ground" is the resistance connected to each plane of the cube, connected to the transistor...

Is ok 1K?
Logged

-Phoed-

United Kingdom
Offline Offline
Tesla Member
***
Karma: 223
Posts: 6593
Hofstadter's Law: It always takes longer than you expect, even when you take into account Hofstadter's Law.
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

If you mean the resistor connected between the base of the transistor and the Arduino pin, then 1K (giving base current around 4mA) is rather high given that you are switching 240mA. I would use 220 ohms (base current around 18mA).
« Last Edit: January 14, 2013, 06:46:42 pm by dc42 » Logged

Formal verification of safety-critical software, software development, and electronic design and prototyping. See http://www.eschertech.com. Please do not ask for unpaid help via PM, use the forum.

Offline Offline
Newbie
*
Karma: 0
Posts: 26
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

yes, is "the resistor connected between the base of the transistor and the Arduino pin". Sorry for my inaccuracy...

I will entrust to your experience dc42,
but could you please explain the calculations you have done to understand it?

thank you very much
Logged

-Phoed-

United Kingdom
Offline Offline
Tesla Member
***
Karma: 223
Posts: 6593
Hofstadter's Law: It always takes longer than you expect, even when you take into account Hofstadter's Law.
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

To switch a transistor full on, you need to supply it with enough base current. You could calculate the base current by dividing the collector current by the hfe, however hfe is typically measured at Vce = 10V, whereas we want Vce (the collector-to-emitter voltage) to be well under 1V when we turn the transistor on. So you need more base current than the value implied by the hfe. A guide is to look at the conditions under which Vce(sat) was measured, given on the datasheet. For the 2N2222A, Vce(sat) is measured with Ib = 0.1 * Ic. So to will achieve the manufacturer's Vce(sat) figure, we need to supply a base current of 0.1 times the collector current, which is 24mA in this case. In practice, we can usually tolerate a slightly higher voltage drop than the Vce(sat) figure given in the datasheet, so a slightly lower base current will do.
Logged

Formal verification of safety-critical software, software development, and electronic design and prototyping. See http://www.eschertech.com. Please do not ask for unpaid help via PM, use the forum.

Offline Offline
Newbie
*
Karma: 0
Posts: 26
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Thanks for your great availability dc42!

I will use the transistor you suggested (BC337 or ZTX851) for the next "cube", because I was lucky enough to find six 2N2222A from my grandfather...

now at last I understand a little 'more about the transistor, but... I hope it's last question... how to connect?
Arduino_Pin  --> base of the transistor --> 220 Ohm resistor --> plane of the cube with 12 Leds
Vss --> emitter of the transistor
Vdd--> Collector of the transistor?

........or something is missing?????
I apologize but these things I've never seen

thanks again
Logged

-Phoed-

United Kingdom
Offline Offline
Tesla Member
***
Karma: 223
Posts: 6593
Hofstadter's Law: It always takes longer than you expect, even when you take into account Hofstadter's Law.
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Emitter to ground.
Base to 220 ohm resistor; other side of resistor to Arduino plane output pin.
Collector to cathodes of the 9 LEDs in the plane. The series resistors for the LEDs will be between the 9 anode lines and the corresponding Arduino outputs.
Logged

Formal verification of safety-critical software, software development, and electronic design and prototyping. See http://www.eschertech.com. Please do not ask for unpaid help via PM, use the forum.

Offline Offline
Newbie
*
Karma: 0
Posts: 26
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

perfect,
(each floor will have 12 LEDs in my project)

thanks, thanks, thanks very much
Logged

-Phoed-

Pages: 1 [2]   Go Up
Jump to: