# Is the circuit in this answer wrong?

In the Q/A link below, the circuit in the answer seems to be wrong to me.

Circuit:

simulate this circuit – Schematic created using CircuitLab

In my point of view, after you turn on the power to that circuit, transistor is immediatelly ON, what means that LED is immediatelly ON, and it will be OFF after some time elapsed when capacitor will be charged enough.

Am I wrong?

• No, the transistor is not immediately on as the capacitor has 0V drop without charge. – Eugene Sh. Nov 30 '18 at 20:03
• So what is the voltage across the capacitor? $V_C = 0$ after a time constant determined by RC, the cap will charge up to 0.7V and the LED will come on. – StainlessSteelRat Nov 30 '18 at 20:03
• You can run the simulation to see for yourself, but be sure to say "Yes" in the "Skip Initial" box for the Time Domain analysis. – Dave Tweed Nov 30 '18 at 20:28
• It looks like it will work. But it could be made better by re-arranging things a bit and maybe adding one or two resistors. – mkeith Dec 1 '18 at 7:55

## RC Voltage

Start out just thinking about $$\R_1\$$ and $$\C_1\$$ and forget the rest of the circuit, for now. Also, assume for a moment that $$\C_1\$$ is fully discharged, to begin with.

simulate this circuit – Schematic created using CircuitLab

When power is applied (and since the voltage across $$\C_1\$$ is zero, at first), all of the supply voltage is across $$\R_1\$$ and an initial starting current equal to $$\\frac{9\:\text{V}}{R_1}\$$ flows into the capacitor, charging it upwards. The voltage across the capacitor will follow a curve described by $$\V_C=9\:\text{V}\left(1-e^\frac{-t}{R\:C}\right)\$$.

Before going further, there is something else to consider. If you disconnect the power source from this $$\R_1\$$ and $$\C_1\$$ pair then in theory nothing much changes, even after time has passed. The capacitor holds its charge (and voltage) and just sits there. (Leakage occurs. But it can take a while.) This might be desirable. But it's probably not in this case because once the power is disconnected it's almost always desired to have the circuit reset itself so that turning the power back on results in the same behavior as before. One possible cheap approach would be to add a resistor in parallel to the capacitor to encourage it to discharge more quickly when the power is removed.

(The units of Ohms $$\\times\$$ Farads is time, and "tau" is conveniently set up so that $$\\tau=R\cdot C\$$, where $$\\tau\$$ is in units of seconds. Then $$\V_C=9\:\text{V}\left(1-e^\frac{-t}{\tau}\right)\$$, with the fraction $$\\frac{-t}{\tau}\$$ being a unitless ratio. If $$\R=10\:\text{k}\Omega\$$ and $$\C=10\:\mu\text{F}\$$ then $$\\tau=100\:\text{ms}\$$. In one $$\\tau\$$ of time, 63.2% of the $$\9\:\text{V}\$$ is achieved. In two $$\\tau\$$ of time, 86.5%. In three $$\\tau\$$, 95%. And so on. Just a few $$\\tau\$$ worth of time and it has almost entirely settled to its final value.)

## Collector current with BJT as emitter-follower

So what happens when you add an NPN BJT in this configuration, with its base connected to the RC junction node?

simulate this circuit

The emitter tip will follow and will be about one diode drop below the capacitor voltage (relative to ground.) At first, this means that the BJT is completely off since the capacitor's voltage starts out well below the diode drop needed by the BJT to turn on. But it's not a lot of time. In this case, considering a $$\9\:\text{V}\$$ supply rail and the approximate figure of $$\750\:\text{mV}\$$ for the base-emitter diode drop at a peak LED current of $$\20\:\text{mA}\$$, it's only about 8.7% of one $$\\tau\$$. (You can work this out by solving the $$\V_C\$$ equation for time.)

If you place a resistor between the emitter and ground:

simulate this circuit

then you can predict the voltage across the emitter resistor as being $$\V_E\left(t\right)=9\:\text{V}\left(1-e^\frac{-t}{R\:C}\right)-750\:\text{mV}\$$ and that the collector current will then be $$\I_C\left(t\right)=\frac{9\:\text{V}\left(1-e^\frac{-t}{R\:C}\right)-750\:\text{mV}}{R_2}\$$.

The usual minimum diode drop will be about $$\600\:\text{mV}\$$. So prior to about 7% of one $$\\tau\$$ the BJT will be entirely off. Between the time of 7% and 8.7% of $$\\tau\$$, the transistor will see its base-emitter diode drop increase from about $$\600\:\text{mV}\$$ to $$\750\:\text{mV}\$$ (assuming that $$\R_2\$$ is selected to top out at about $$\I_C\approx 20\:\text{mA}\$$.) This short transition period isn't terribly important to know in detail. It's enough to realize that the collector current will start just a little earlier than expected, but will quickly just "follow" or "track" the rising voltage at the capacitor. Before the needed base-emitter diode voltage drop, this collector current will be close to zero. Afterwards, it will closely follow the above estimated $$\I_C\left(t\right)\$$ behavior.

It's convenient at this point to add an LED into the collector leg:

simulate this circuit

With that handled, the LED will experience the collector current as indicated by the $$\I_C\left(t\right)\$$ equation. This will be an exponentially rising result, which is good because the human eye has a logarithmic response to current in the LED as "perceived brightness." This makes the perception of brightness seem "linear" to the eye. Which is probably desired.

To select, for example, a final LED current of $$\20\:\text{mA}\$$ it is enough to assume that the collector of the BJT will be about one LED voltage drop below the $$\9\:\text{V}\$$ rail, or about $$\7\:\text{V}\$$ and that while in active mode the BJT's difference between its collector and emitter is about $$\1\:\text{V}\$$, so the emitter will be about $$\6\:\text{V}\$$. This means the base is about $$\6.75\:\text{V}\$$ as the circuit reaches close to its final end-point. So $$\R_2= \frac{6\:\text{V}}{20\:\text{mA}}=300\:\Omega\$$. I'd select $$\R_2=330\:\Omega\$$ here.

In your case, the LED isn't in the collector leg but instead in the emitter leg. The effect here is that no LED current (or collector current) takes place until the capacitor voltage reaches at least the BJT's base-emitter voltage drop plus also the required voltage drop for the LED. This is a higher voltage, obviously. So it delays the onset to about 35% of $$\\tau\$$ instead of the earlier onset I indicated before.

It's otherwise not a lot different.

## Remaining thoughts

The only other consideration to worry about is the base current of the BJT. $$\R_1\$$ supplies this, as well as supplying current to $$\C_1\$$. So the process will stop when the current in $$\R_1\$$ reaches the point where the base current takes over and there's nothing left to continue charging $$\C_1\$$. Conservatively, this is when $$\I_{R_1}= \frac{20\:\text{mA}}{\beta=100}\approx 200\:\mu\text{A}\$$.

The actual values of the resistors and capacitor will vary a little depending on your choice (my original topology or the one you selected in your question.) But the basic ideas aren't much different. Just the calculations vary somewhat. Either approach works.

## Summary

Either way you go, the result should be a circuit that really does cause the LED current to vary in such a way that it will appear to be rising (to the human eye) approximately linearly. And counter to your thoughts, it really should work okay.

The only issue will be discharging $$\C_1\$$ so that the circuit can be re-started fairly quickly when the power is removed and then re-applied. Here, there are a number of various options to consider varying from very simple by using a resistor across $$\C_1\$$, but requiring substantial discharging time, to more complex methods requiring more parts but providing a much faster discharge time.

• Like always, the best answer is from jonk. – Iron Maiden Dec 1 '18 at 17:53

No, the transistor is not immediately on, because the capacitor holds the base at zero volts until it charges up through R1, the 10k resistor.

Nothing happens until the capacitor reaches about 650 mV, at which point the transistor begins to conduct. The transistor functions as an emitter follower, so this is the point at which the emitter voltage begins to rise.

However, even then, the LED doesn't light up (no current flows) until the emitter voltage reaches the LED forward voltage value. From this point on, the current increases in proportion to the change in voltage, as determined by R2.