Project #1: LED slow rise.

crutschow

Joined Mar 14, 2008
34,285
If you use NPN you need a voltage rail with higher voltage.
PNP needs a negative voltage.
Voltages are all relative. For example you can use a PNP with a positive rail if the emitter is connected to that positive voltage and it's collector load goes to ground (the high side switch you mentioned).
 

crutschow

Joined Mar 14, 2008
34,285
It is even more weird since the LED is in parrallel with the transistor. One voltage source should connect to the common ground (the inverse triangle in simulation softwares such as LTSpice).
No, the LED is in series with the collector of the transistor.

The voltage source is not required to go to ground. But Spice simulators do require at least one point of the circuit be grounded, which the op's circuit has.
 

takao21203

Joined Apr 28, 2012
3,702
No, the LED is in series with the collector of the transistor.

The voltage source is not required to go to ground. But Spice simulators do require at least one point of the circuit be grounded, which the op's circuit has.
sure. but the ccirccuit does not actually work according to OP.
 

Thread Starter

AcousticBruce

Joined Nov 17, 2008
58
the ground was accidental. It should have been on neg side of voltage source. oops



I was reading about beta or hFE and I am a bit confused....
Rich (BB code):
"...For example, a transistor may be required to drive a relay of 30ma  with a base current of 0.15mA and voltages as low as 1 volts –  definitely nothing less than 200 would work here as the hFE....

 Let’s say if the Ic is 35mA and Ib is 0.15mA, then the required minimum hFE level would be:
 β = 35/0.15 = 233."
What does this mean "required minimum hFE level would be..." ?


What is "required"? The beta level? I do not understand. I thought the beta level was a calculation of the base and common amps.
 

Papabravo

Joined Feb 24, 2006
21,159
Think of the Beta as a range of values instead of a single number. When you design a circuit you want it to work regardless of which individual transistor you pick from a lot of identically marked transistors.

For Example: If I give you a lot of 100 transistors and say the mean β is 350 with a variance of 900, what would you conclude if I also say that β is a normally distributed random variable?
 

Papabravo

Joined Feb 24, 2006
21,159
The average β is 350 and the values of β over the lot of 100 different transistors follow a normal distribution. The square root of the variance (900) is 30 which is the standard deviation of this particular normal distribution. This means that 99 out of 100 transistors will fall within 3 standard deviations of the mean. The deviations can be positive or negative.

So:

350 + 3(30) = 440 and
350 - 3(30) = 260

Therefore the highly probable range of β is [260,...,440]

That last transistor could be <260 or >440, we really don't know. That was the answer to my question. So when you do your design you start with a worst case assumption that your transistor β is say 200. This is more than 4 standard deviation below the mean, meaning it is very unlikely, but not impossible that your design will fail in practive because of insufficient gain.

Now you look at the current required by your load, you assume that the transistor β is 200 and you compute the required base current to produce that amount of collector current. Any transistor with a higher β will supply the current required by the load because the base current you chose will be more than sufficient.

Hope that helps.
 

crutschow

Joined Mar 14, 2008
34,285
But note that Beta value is a small signal value typically given at several volts of collector-emitter voltage. If you want to fully turn on the transistor as a switch, such as driving a relay coil, with only a few tenths of a volt collector-emitter voltage then you need to use a much smaller value for β. Typically a value of 10 is used when the transistor is used as a switch although 20 may be used for high gain type transistors at a collector current well below their maximum.
 

Thread Starter

AcousticBruce

Joined Nov 17, 2008
58
At the beginning of this thread there was a lot of talk about grounding problems and other areas that may have been confusing. I did slap that circuit together real quick and I also was missing a key piece of knowledge: beta or Hfe.

Well for the past week I have been reading and studying and I think I am on to understanding the DC effects of a transistor.


My approach was to correctly (roughly) calculate proper resisters while keeping the Hfe in mind. I chose a 2n2222 because the Hfe in this range was roughly 100. I wanted 100mA in the CE and with 100 beta I would want roughly 1mA in the B. So I did the math: 12V / 0.100A = 120 Ohms. Then I did the math for the B: 5V / 0.001A = 4.3k. I slapped a circuit together and it seemed to work great. Here is a screen shot. This is set up to start at 0 and in 500mS it will climb to 5 volts all on the base side. I was hoping for the CE to rise to 100mA.






Can you tell me if I am thinking of this correctly?
 

crutschow

Joined Mar 14, 2008
34,285
The Beta of a real transistor has a wide range of values from unit-to-unit (typically a factor of about 3 times for the 2N2222) so your delay will also vary depending upon the particular transistor you have. That's why you want to design a circuit largely independent of this Beta variation using negative feedback (typically from an emitter resistor such as the circuit I posted in #6).
 

Thread Starter

AcousticBruce

Joined Nov 17, 2008
58
I think its time to check out your circuit. I wanted to understand a few things first. It still seems really complex. I hope you can walk me through it. Now, I see a darlington pair (i believe that is what it is called), why did you chose an NPN as well as a PNP in that pair? Also what is "startup uic"?
 

#12

Joined Nov 30, 2010
18,224
It's called something strange like a Sziklai pair. You get the advantage of gain squared and the voltage at R1 tracks the voltage at B (not inverted).
 

Thread Starter

AcousticBruce

Joined Nov 17, 2008
58
Okay, I can understand that as part of the learning process. Then there are two main problems with your circuit that you want to solve:

1) The input resistor value to the transistor is too high to give the required base current for your desired output current, as #12 noted. (look up the minimum beta (Hfe) gain for the transistor you want to use, such as a 2N2222, in its data sheet.) Thus you either need to drastically reduce the value of R1 (and correspondingly increase the value of C1) or add more gain to the circuit.

2) A common-emitter amplifer has a relatively abrupt turn-on at a base-emitter voltage (Vbe) of about 0.7V (one diode drop). Thus at power-on your circuit will show a significant delay with no LED current until 0.7V is reached and then rapidly turn ON. You won't get the slow ramped turn on of the LED you want from time zero.

So you need to solve those problems. I gave you my solution. So give it a shot yourself. There is no single solution, of course, but some solutions are better than others. The interesting part of design is trying to find which one is best. You may come up with one better than mine. ;)

I like your solution. It is awesome. I will break this circuit down and learn exactly how to calculate this. For now I am wondering if you can give me a few homework problems :)

For instance I want to use common emitter npn transistor circuit with a certain load and am looking for a few problems to solve. Would you be interested in giving me these. Just make up a few and I can solve them and get back to you. What do you think?
 

#12

Joined Nov 30, 2010
18,224
Here are 2 other ways to do it. If you don't know what an op-amp is, the first drawing means nothing to you. The second drawing will get you enough current and the output will rise continuously after the capacitor gets to about 1.2 volts.
 

Attachments

Thread Starter

AcousticBruce

Joined Nov 17, 2008
58
Here are 2 other ways to do it. If you don't know what an op-amp is, the first drawing means nothing to you. The second drawing will get you enough current and the output will rise continuously after the capacitor gets to about 1.2 volts.

I do know what an op-amp is, just do not know how to use it yet. So that being said, the second drawing is pretty simple looking.

So I looked at it and here is my analysis:

That is in-fact a darlington pair. The base resister limits the current, pretty simple here. The cap does something very interesting to me. I believe it would leak the current to ground and progressively quench ground until no more dc can pass through. At this point the base current would be at max and stay. The cap design is new to me, I am sure I have seen this type of use, but I seem to get it now.

Well I think I am right. Am I? Ill make a circuit like this later in ltspice.
 

crutschow

Joined Mar 14, 2008
34,285
I think its time to check out your circuit. ........................... Now, I see a darlington pair (i believe that is what it is called), why did you chose an NPN as well as a PNP in that pair? Also what is "startup uic"?
It's not a Darlington pair (which are two transistors of the same polarity) but, as #12 noted, it is a Sziklai_pair (sometimes called a compementary darlington). I used it because it requires only about 0.7V to turn on instead of the ≈1.4V the Darlington requires.

The "startup.uic" means Spice does not calculate the initial DC operating conditions before doing the Transient simulation. Without that, the simulation would start with the capacitor already fully charged.
 

Thread Starter

AcousticBruce

Joined Nov 17, 2008
58
It's not a Darlington pair (which are two transistors of the same polarity) but, as #12 noted, it is a Sziklai_pair (sometimes called a compementary darlington). I used it because it requires only about 0.7V to turn on instead of the ≈1.4V the Darlington requires.

The "startup.uic" means Spice does not calculate the initial DC operating conditions before doing the Transient simulation. Without that, the simulation would start with the capacitor already fully charged.
Crutschow, the darlington pair I was refering is to #12's simple circuit a couple posts up.

my version of LTSpice does not include the .uic extension... it only puts "startup"

So the Sziklai may be more efficient. I will study darlington first, then get into the Sziklai.
 
Top