# Why does this NPN transistor operate differently if it comes before the switched element?

I'm simulating turning an LED on with a transistor switch in LTSpice. To my bewilderment, the current through the LED in Circuit 1 is ~51 mA and the current through the same in Circuit 2 is only ~6 mA. The circuits are identical except for the placement of the transistor. In Circuit 1, the transistor's emitter is connected to ground and in Circuit 2, the transistor's emitter is connected to the load. What am I missing here?

• In the second circuit (emitter follower), the voltage across R1 + D1 is Q1's Vb minus one diode drop. In the first circuit, it is V1 minus Q1's Vce. Dec 30, 2021 at 0:18
• C suffix is an invalid part number (missing Colour, but all appear to be GaAs old technology) "SUPER BRIGHT 0402" = 35 mcd is NOT SUPER. 1000 mcd would be SUPER ( Due to size and luminent density, it would be super glare) Dec 30, 2021 at 1:14
• What do you need to learn? I have 2 solutions that do not need 5V. Questions? Dec 30, 2021 at 3:08
• Did you have any questions from my answer? Dec 30, 2021 at 21:37

Let me simplify the schematics a bit. I'm going to replace your $$\3.3\:\text{V}\$$ voltage source and the two resistors surrounding the BJT base with a single Thevenin equivalent voltage source and series resistance. And I'm drawing both your schematics together here:

simulate this circuit – Schematic created using CircuitLab

On the left side, it is possible for the collector voltage to be very near the emitter voltage if the base current is sufficient (and it is.) So almost all of the $$\5\:\text{V}\$$ can be applied to the series pair, $$\D_1\$$ and $$\R_2\$$ (given sufficient base current, which you do have.)

On the right side, the collector is locked at $$\5\:\text{V}\$$ and the base must be below $$\3\:\text{V}\$$ because of a small, unknown voltage drop across $$\R_1\$$. Further, the emitter has to be another diode drop below that, so nearing $$\2.3\:\text{V}\$$. This means that the collector-to-emitter voltage drop in this case must be around $$\2.7\:\text{V}\$$. So that much is being "thrown away" by $$\Q_1\$$, leaving only $$\2.3\:\text{V}\$$ left over to be applied to the series pair, $$\D_1\$$ and $$\R_2\$$. That's a lot smaller voltage, especially considering the fact that the LED will use up most of that, leaving only a small voltage drop across $$\R_2\$$ and therefore a much smaller LED current.

So the two cases are quite different. I get it that you just think of the NPN BJT here as a switch. And if so, that there should be no difference -- that you should be able to put the "load" on either side with the same effect. But that's just not the case.

In each circuit, the NPN has sufficient base drive available.

In circuit 1, with sufficient base drive, the transistor saturates and VCE is negligible (< 0. 2 V). Therefore the LED current is defined by its series R1 and V1. With ~ 2.2 VF needed for the LED, the current is (5-2.2)/54 = 51 mA.

In circuit 2, the NPN is not saturated. The base is driven to about 3.3 V by V2, and so the emitter is about 0.7 V below this -- e.g. 3.3-0.7 = 2.6 V. If the LED requires 2.2 V, this leaves only 0.4 V across the 54 Ω, for a current of 0.4/54 = 7 mA.

Note that this current is still consumed from V1, but the magnitude is not significantly affected by the value of V1 (as long as it is more than about 2.8 V).

• In Circuit 2, what happens to the 5V voltage? We have +5V at the collector, 3.3V at the base and 2.6 V at the emitter. Does that mean there is an (invisible) resistance of dV/I=1.7V/6mA=2400 Ohms at the NP junction inside the transistor? Dec 30, 2021 at 14:28
• Yes -- but it is a variable resistance ! This is exactly how a transistor works: If the emitter current is defined (i.e. controlled), and VCE > 0.2 V, the collector current will be beta/(1+beta) times the collector current. Dec 30, 2021 at 16:42

In Circuit 1 the NPN is wired as a common-emitter inverting driver. The voltage being applied to the LED and dropping resistor is about:

• 5V - Vce(sat) = 5V - 0.2V = 4.8V

This gives the best possible drive, and could even be used with a 3.3V supply for both the LED and driving source because Vce(sat) is small.

In Circuit 2, the NPN is wired as an emitter-follower non-inverting driver. The voltage being applied to the LED and dropping resistor is about:

• 3.3V - Vbe(sat) = 3.3V - 0.7V = 2.6V

The biggest difference is that the follower action limits the positive swing to 3.3V - Vbe(sat). This results in a much lower voltage being delivered to the LED + load resistor, and even worse, not enough voltage to reliably forward bias the LED in all cases (Vf is 2.0V nominal, 2.4V max.)

If you use 5V for the base drive in Circuit 2, things improve some:

• 5V - Vbe(sat) = 5V - 0.7V = 4.3V

But it's still not ideal, as Vce is 0.7V vs. 0.2V for the common-emitter configuration in Circuit 1.

If your goal is to have a consistent LED current, you'll need to compensate for the variation in the LED forward voltage. One way is to make a driver that has some negative feedback that senses current. That is, you need a constant current source.

Here's a simple current source that uses a fixed bias input to set a constant voltage across the 33 ohm emitter sense resistor. (simulate it here):

The high-gain emitter-follower pair tracks the output current through a 33 ohm sense resistor, which provides negative feedback. Variations in load resistance (and more importantly, LED forward voltage drop) are cancelled out by the voltage-follower action.

It's not super accurate, but it does a reasonable job of compensating LED Vf.

• That's not a particularly good Circuit. The darlington and 10k's mean that the base is 3.3/2, and if the darlington VBE is 1.3 V, it will only allow 0.35 V across the 6.8 Ω. The problem is that any small change in the 3.3 V level or temperature (which changes VBE) will dramatically change the current. You can remove the 10K to GND, also don't really need a darlington. Dec 30, 2021 at 21:11
• Yes, a better circuit would use an op-amp or a TL431 to add some gain for the feedback. That said, this is a classic emitter-degeneration approach. Dec 30, 2021 at 21:19

Common Emitter (CE) is a saturated switch with resistance depending on chip size and Ic/Ib ratio controlled by Rc if Ic/Ib<20 (Rated at 10)

Common Collector (CC) is a non-saturating current pump (Ic=hFE*Ib) with a Vbe, diode drop controlled by Rb.

When the Vbc becomes forward biased in the CE switch) hFE drops towards the rated ratio of 10 but typically you can use 10% of the linear hFE.

A picture is worth a thousand words.

Your 10k Rbase (R3) shunt is redundant but does reduce input current by 10%. It is not necessary to add this as it serves little or no purpose. The floating base will not turn on the LED.

Locate on my simulation that "Your Design" agrees with your test results and my Design on the right shows how to choose a better operating point <=20mA with 2 simple changes.

1. For CE on top: Choose 3.3V instead of 5 as Rc limits LED current with a small switch Vce<0.1 and expected Vf of LED of 2.0V in this part only. (GaAs) leaving 1.2V/68=Ic

2. for CC aka emitter follower below it: Change 5V to 3.3 on collector, Remove Base resistor (0) as it makes load dependent on hFE (wide tolerance) rather than Vbe so Ve is well defined 3.3-0.7=2.6V=Ve then the Re emitter resistor limits the current 2.6V-2.0V= 600 mV/20 mA= 30 Ohms, I used nearest value of 27 Ohms.

Observe how to make a simple linear approximation with my equivalent circuits on the left for YOUR LEDs and CC,CE circuits. Note that all these colours have the same voltage which is the old technology of 2V Gallium Arsenide and not the newer AlInGaAs or AlInGaP types that are Ultrabright. But being a very tiny dot it will be clearly visible but 35 mcd does not shed much light. >20,000 mcd 30 deg. sheds a LOT of light and is visible very far away and is blinding but that's what modern 5mm 3.1V white LED's can do now. I've got loads of 200pc/bag of these types.

The simple answer is that the NPN transistor's behavior depends on the voltage from base to emitter. In your two circuits, the base to emitter voltage is very different. This is the main reason why the same transistor exhibits two different behaviors in the two different circuits.

If you wire circuit 2 like this it should work the same as circuit 1, as far as current through the diode goes.

• That is true , but does not explain how to control Vbe or make it work. Dec 30, 2021 at 1:49
• @TonyStewartEE75 it is hard to predict what kind of answer will benefit a poster the most. Other people (including you) provided more complicated (and complete) answers already so I chose to focus on one very key, simple point. Hopefully the OP or some subsequent person searching on the internet will benefit from my answer. Dec 30, 2021 at 2:03
• It is very nonlinear truth when beginners need to learn the level 0 linear models. Nonlinear models come next.Year. Dec 30, 2021 at 2:12
• @TonyStewartEE75 the point of my circuit is to address the fundamental question asked by the OP: why is the load current different in circuit 1 vs circuit 2. So I modified circuit 2 in such a way that the load current should be the same as circuit 1. The purpose of this is to enlighten the OP about the difference between the two circuits. It is not my purpose to show the OP how to design a saturated switch properly because the OP is probably not ready for that. Dec 30, 2021 at 18:56
• Thats OK, I wanted to illuminate a more linear approach where the LED current is controlled by a single R value knowing Vbe and Vf are constant even using a more efficient supply of 3.3 for both. Dec 30, 2021 at 21:36

I want to further develop the philosophy inside some of the answers here making a few comparisons between the two circuits.

In fact, both circuits are voltage followers but they follow different voltages - the first circuit "follows" the supply voltage V1 and the second circuit follows the input voltage V2. And because the supply voltage is higher than the input voltage, the current through the LED in the latter case is lower.

If we continue with such simple comparisons, we can say that the transistor in the first circuit acts as a closed switch with zero resistance. No voltage is lost on it, so all the supply voltage is applied to the LED network. In the second circuit, the transistor acts as a variable resistor ("rheostat") on which, roughly speaking, the difference between the supply and input voltage is lost.

Both circuits are used here as switching (digital) circuits but, in fact, both they are analog circuits made act as digital circuits. For this purpose, the first is "overdriven" while the second follows the input voltage by the help of negative feedback.

Let us now see how, in principle (when the transistor is not "overdriven"), moving the load (LED circuit) from the collector (first circuit) to the emitter (second circuit) drastically changes the transistor behavior:

• When the LED network is in the collector, the transistor keeps up a constant current through the LED (acts as a current "source"). For this purpose, it changes its collector-emitter "resistance" so that to keep the total resistance constant. This is its genuine behavior.

• When the LED network is in the emitter, the transistor's behavior is changed by the mechanism of the negative feedback and now it keeps up a constant voltage (acts as a voltage source). For this purpose, it changes its collector-emitter "resistance" so that to keep a constant ratio between its "resistance" and the total resistance. This is its modified behavior.

So, by means of the negative feedback phenomenon, a current source (common-emitter stage) is converted to a voltage source (common- collector stage).

True, these are a few unusual considerations that resemble rather 99% Lindt dark chocolate than the sweet Milka chocolate:-) but they can make us think...