Learn & build · Electronics · Chapter 1

Voltage, current, resistance

Three words do almost all the work in electronics. Voltage is the push, measured in volts. Current is how much charge flows each second, in amps. Resistance is how hard a part makes it to flow, in ohms. Every circuit below is solved live by the same method circuit simulators use; the yellow dots move as fast as the current they carry.

In plain words: think of water in a closed loop of pipe. The battery is a pump: voltage is how hard it pushes. Current is how much water flows past any point each second, and it's the same all the way around the loop. A resistor is a narrow section of pipe: the narrower it is, the less flows for the same push. Nothing gets used up as it goes around; the pump's push is spent squeezing through the narrow parts, and that effort turns into heat.

1. Ohm's law

A battery pushes current around a loop through one resistor. Double the push and the current doubles; double the resistance and it halves:

current = voltage ÷ resistance    (I = V / R)

🎯 Challenge: make exactly 10 mA flow from a 5 V battery. Which resistor does it take?

Where does the energy go? Into heat in the resistor: power = V × I, in watts. A common through-hole resistor is rated for ¼ W. Turn the resistance down with a high voltage and watch it go past that: in real life it smells, then smokes.

The math, step by step

Units first, because most mistakes are unit mistakes: 1 mA = 0.001 A, 1 kΩ = 1000 Ω. A handy shortcut: volts ÷ kilohms = milliamps. 5 V across 1 kΩ is 5 mA.

Power three ways. Power is voltage times current, \(P = V I\). Put Ohm's law into it and you get two more forms, each handy when you know different things:

\[ P = V I = I^2 R = \frac{V^2}{R} \]

Example: 9 V across 330 Ω. \(P = 9^2 / 330 = 81 / 330 = 0.245\) W, right at a ¼ W resistor's limit: it will run hot. Halve the voltage and the power drops to a quarter, because \(V\) is squared.

A 9 V battery across a 330 Ω resistor. How much power turns into heat?

\(V^2 / R = 81 / 330 \approx 0.245\) W. A ¼ W resistor would be at its limit; use a ½ W one, or a bigger resistance.

You double the battery voltage across the same resistor. What happens to the heat?

\(P = V^2 / R\): twice the voltage, twice the current, four times the power.

Current is the push divided by the resistance, \(I = V/R\); it's the same all the way around a loop, and every watt the push spends there turns into heat.

2. In series: a voltage divider

Two resistors in a row share the same current, and they split the battery's voltage in proportion to their size. The middle point sits at

Vout = V × R₂ / (R₁ + R₂)

🎯 Challenge: with two plain resistors, make the middle point exactly 1.00 V.

"The voltage at the middle point" hides a second point. A voltage is always a difference between two points, like a height measured from the floor. So circuits pick one point as the floor and call it ground, 0 V: here the battery's − end. The middle point's voltage is how far it sits above ground.

This is how a microcontroller reads most simple sensors. A light-dependent resistor (LDR) drops from about 100 kΩ in the dark to about 1 kΩ in sunlight; put it in a divider and the middle voltage tracks the light. The chip's analog-to-digital converter (ADC) turns that voltage into a number, here 0 to 4095 for 3.3 V like an ESP32. Tick the box and change the light.

The math, step by step

Why the divider formula holds: both resistors carry the same current, \(I = V / (R_1 + R_2)\) (in series, resistances add). The middle point sits \(I R_2\) above ground:

\[ V_{\text{out}} = I R_2 = V \cdot \frac{R_2}{R_1 + R_2} \]

The catch: loading. Connect something to the middle point, say a 10 kΩ input, and it sits in parallel with \(R_2\), lowering it, so \(V_{\text{out}}\) sags. Rule of thumb: whatever reads the divider should have at least 10× the resistance of \(R_2\). Microcontroller inputs (millions of ohms) are fine; driving a motor from a divider is not. The numbers, from this page's solver, for 9 V across 10 kΩ over 5 kΩ (3.00 V with nothing connected): a 1 MΩ load gives 2.99 V, 100 kΩ gives 2.90 V, 10 kΩ gives 2.25 V, and 1 kΩ drags it down to 0.69 V.

9 V across \(R_1 = 10\) kΩ on top and \(R_2 = 5\) kΩ on the bottom. What's the middle voltage?

\(9 \times 5 / (10 + 5) = 3\) V. \(R_2\) is a third of the total, so it gets a third of the voltage.

The LDR is the bottom resistor. The room gets brighter. What happens to the voltage the ADC reads?

More light, less resistance in \(R_2\), smaller share \(R_2 / (R_1 + R_2)\). Swap the LDR to the top position and the reading goes up with light instead.

3. In parallel: the current splits

Side by side, each resistor gets the full battery voltage and takes its own current, V / R. The battery supplies the sum. Electrons don't get lost at a junction: what flows in flows out (that's Kirchhoff's current law). The more paths, the lower the total resistance.

The math, step by step

Each branch takes \(V / R_i\); the battery supplies the sum. Calling the total \(V / R_{\text{total}}\) and dividing out \(V\):

\[ \frac{1}{R_{\text{total}}} = \frac{1}{R_1} + \frac{1}{R_2} + \frac{1}{R_3} + \cdots \qquad \text{two of them: } R_{\text{total}} = \frac{R_1 R_2}{R_1 + R_2} \]

The total is always smaller than the smallest branch: adding a path can only make it easier to flow. Two equal resistors in parallel give half; ten equal ones, a tenth.

Two 1 kΩ resistors side by side. What's the total resistance?

\(1000 \cdot 1000 / (1000 + 1000) = 500\) Ω: two equal paths, twice the flow for the same push.

A 1 kΩ and a 1 MΩ resistor in parallel. Without calculating: is the total closer to 1 kΩ or to 500 Ω, and why?

Very close to 1 kΩ (999 Ω). The 1 MΩ path carries a thousandth of the current: almost all of it takes the easy path. A huge resistor in parallel barely matters; a tiny one dominates.

🎯 Challenge: draw 20 mA from the battery in total (within 1 mA).

4. Every LED needs a resistor

An LED isn't a resistor: below about 1.8 V (for red) almost nothing flows, and just above it the current shoots up steeply. Connect it straight to a battery and the current is limited only by the battery and wires: it flashes once and dies. A resistor in series sets the current. Pick a supply, then a resistor, and aim for about 10 mA.

supply

🎯 Challenge: light the LED at 10 mA from the 9 V battery, without burning it.

The rule of thumb is the loop again: the resistor takes whatever voltage the LED doesn't, so R = (Vsupply − VLED) / I. From 5 V for a red LED at 10 mA: (5 − 1.9) / 0.010 = 310 Ω, so the nearest standard value, 330 Ω. The solver here models the LED with the Shockley diode equation, which is why the current climbs so steeply near 2 V.

The math: why the LED's current shoots up

The solver uses the Shockley diode equation:

\[ I = I_s \left( e^{V / (n V_T)} - 1 \right), \qquad V_T = \frac{kT}{q} \approx 26 \text{ mV at room temperature} \]

\(I_s\) is a tiny leakage (here \(1.2 \times 10^{-18}\) A) and \(n \approx 2\) for this LED, so \(n V_T \approx 52\) mV. Every extra 52 mV multiplies the current by \(e \approx 2.7\); every extra 0.1 V, by \(e^{0.1/0.052} \approx 6.8\). Between 1.8 V and 2.2 V the current grows about 2,000 times. That's why you never set an LED's current with its voltage: a tiny voltage error is a huge current error. A resistor turns that steep curve into a gentle one you can control.

A blue LED drops about 3.0 V. From a 3.3 V supply, what resistor gives 10 mA?

\((3.3 - 3.0) / 0.010 = 30\) Ω. With only 0.3 V of margin, small changes in the LED's voltage swing the current a lot; blue and white LEDs on 3.3 V are touchy.

Want to try your own? Build any of these in the circuit lab. Next: capacitors and time, the RC circuit, which is also the simplest filter in the radio course.

All chapters: Learn & build. Circuits solved by our own modified nodal analysis (learn/circuit.js).

Last updated