Supplier photo of an assembled infinity mirror light cube illuminated on a dark background.
Supplier photo
Temu affiliate offer · Project idea

Build an infinity light cube

Listing specifies 5-volt direct current. Soldering required; battery and glue not included.

View kit on Temu

Tricky Circuit may earn a commission through these links. Product ideas have not been bench-tested by Tricky Circuit and are not verified lesson parts lists.

Choose an NPN Base Resistor: A 5 V LED Switch

A transistor lets a small control current turn another current path on and off. But the base pin is not a magic switch input: it needs a resistor, and the load needs its own current limit. Build this low-current light circuit to see what each resistor is doing.

Your goal: wire a 2N3904 transistor, calculate its base current and check its collector voltage with a meter.

2N3904 LED switch with a 680 Ω LED resistor, 4.7 kΩ base resistor, pushbutton and 100 kΩ base-emitter pull-down.
Original Tricky Circuit connection diagram. Component values are design values; physical build results have not been measured.

Meet the transistor terminals

The 2N3904 is an NPN bipolar junction transistor, often abbreviated BJT. NPN describes its n-type, p-type and n-type semiconductor regions; it does not mean three charged terminals. Its terminals are base (B), collector (C) and emitter (E).

In this circuit, base current turns on a path from collector to emitter. The emitter connects to the common 0 V reference, called ground (GND). Because the transistor sits between the load and ground, this arrangement is a low-side switch. In the drawing, the emitter arrow points outward from the base.

Parts and wiring

  • A regulated 5 V direct-current (DC) supply.
  • One 2N3904 transistor, with the pinout checked against its manufacturer’s package drawing.
  • A red light-emitting diode (LED) rated for at least 20 mA continuous current.
  • A 680 Ω LED resistor, a 4.7 kΩ base resistor and a 100 kΩ base-to-emitter resistor, all rated at least 0.25 W.
  • A normally open pushbutton, breadboard, wires and multimeter.

With power disconnected, connect +5 V → 680 Ω → LED anode → LED cathode → collector. The LED cathode is the terminal marked by the bar in its schematic symbol. Connect the emitter to GND. Connect +5 V → pushbutton → 4.7 kΩ → base. Finally, connect 100 kΩ from base to emitter. One kilohm (kΩ) is 1,000 ohms.

The 100 kΩ resistor pulls the base toward the emitter when the button is released. The button supplies the control voltage in this experiment; no microcontroller or program is required. A package’s apparent left-to-right pin order depends on the viewing direction. Do not copy physical pin positions from this schematic.

Predict the currents

Use a 2.0 V LED drop and a 0.2 V collector-to-emitter drop as a simple on-state model. Then the LED current is (5 − 2.0 − 0.2) / 680 = 4.12 mA. A milliampere (mA) is one thousandth of an ampere.

Assume 0.8 V from base to emitter. The 4.7 kΩ resistor carries (5 − 0.8) / 4,700 = 0.894 mA. The 100 kΩ resistor takes 0.8 / 100,000 = 0.008 mA, leaving about 0.886 mA of base current. These assumed junction voltages are teaching values, not guaranteed measurements.

The collector-current to base-current ratio is approximately 4.65. Providing ample base current helps drive the transistor into saturation, its low collector-voltage switching state. Saturation still has a voltage drop; the transistor is not a perfect wire.

Measure instead of guessing from brightness

  1. Keep the meter leads in COM (common) and V, and select DC voltage. Apply power with the button released. The LED should be off and the base should be near 0 V.
  2. Hold the button. Measure base relative to emitter, then collector relative to emitter. Record both voltages. A low collector voltage is useful evidence that the switch is on.
  3. Measure across the 680 Ω resistor. Divide that voltage by 680 Ω to find the actual LED current.
  4. Measure across the 4.7 kΩ resistor. Divide by 4,700 Ω, then subtract the current through 100 kΩ if you want a closer base-current estimate.
  5. Release the button. Confirm that the light turns off. Disconnect power before moving wires.

If the collector stays high while the button is held, check the transistor pinout, emitter ground, base path and LED direction. Brightness alone cannot distinguish all of these faults.

Why the datasheet’s gain is not a resistor calculator

The onsemi 2N3904 datasheet specifies current gain under particular conditions and gives separate saturation tests. For example, its 10 mA collector-current saturation test uses 1 mA of base current at 25°C. Do not assume that a gain number measured in the amplifying region guarantees saturation at every load and temperature.

The 680 Ω resistor controls LED current; the base resistor controls base drive. Removing either because “the transistor limits current” changes the circuit into a different and poorly controlled experiment.

Challenge: change only the base resistor

Replace 4.7 kΩ with 10 kΩ after switching power off. Using the same 0.8 V assumption, what base current do you predict? Must the LED current fall by exactly the same proportion?

Show the reasoning

The new base current is approximately (5 − 0.8) / 10,000 − 0.8 / 100,000 = 0.412 mA. The collector/base ratio is now about ten at the modeled LED current. If the transistor still saturates, the LED current can remain close to its previous value. Measure collector voltage to see what actually happened.

For background, read Switching Transistors. Practice measurement with the resistor-voltage method, then explore transistor controls in the laboratory.

📡Broadcast the signal — amplify the connection.

Leave a Reply

Temu affiliate offers

Find your next electronics project

Explore these do-it-yourself project kits. Check the selected option, included parts and instructions on each offer.

Tricky Circuit may earn a commission if you buy through these Temu affiliate links. These are product ideas; they have not been bench-tested by Tricky Circuit and are not verified lesson parts lists.

Supplier photo of a breadboard, jumper wires and assorted electronic components in a plastic storage case.

Supplier product photo

Try breadboard experiments

Breadboard, wires and assorted parts. Arduino controller board not included.

View kit on Temu

Supplier photo of an assembled blue surface-mount soldering practice board with a circular ring of small lights.

Supplier product photo

Solder a chasing-light board

Surface-mount soldering practice. Battery and battery holder not included.

View kit on Temu

Supplier photo of an assembled two-wheeled line-following car with a blue circuit board, two motors and an empty battery holder.

Supplier product photo

Build a line-following car

Soldering and assembly required. Check battery and track requirements before buying.

View kit on Temu