Skip to content
LearnTronics menu

LearnTronics

LED Fade-Off

Tutorial Index

Recipe #24 — led fade-off

A large capacitor can make stored electrical energy visible. Charge it, remove the charging command, and let the capacitor keep a transistor conducting while its voltage slowly decays.

LED FADE-OFF — STORED CHARGE +9 V PUSH TO CHARGE R1 4.7 kΩ C1 470 µF RB 10 kΩ BCE +9 V1 kΩLED Release the button: C1 discharges slowly → transistor current falls → LED fades
Press: the button charges C1 and turns Q1 on. Release: C1 keeps supplying base current for a while, then its voltage falls and the LED fades.

The capacitor is a temporary energy store

C1 stores charge while the button is pressed. After the charging path is opened, that stored charge has only the discharge path through RB and the transistor base, so the voltage falls gradually instead of instantly.

VC(t) = V0 e−t/RC

The fade is not perfectly linear

Exponential capacitor discharge, transistor base-emitter behavior, and LED brightness perception all make the visible fade non-linear. That is useful here: the circuit lets the eye see an RC transient directly.

Try these yourself

What keeps the LED on briefly after the pushbutton is released?
C1 remains charged and supplies decreasing base current to Q1.
What happens if C1 is made much larger?
More capacitance stores more charge for a given voltage and increases the discharge time constant.
Is the fade expected to be perfectly linear with time?
The capacitor voltage decays exponentially and the transistor and LED are also non-linear devices.