Level 4 · Motion · project 10 of 13 · 25 min · ●●●○○
Trip Wire Fan
Trip Wire Alarm's brain wearing a motor. The wire is intact — the fan is silent. Snap it — the fan spins as the alarm.
new here? Start with First Light — one battery, one resistor, one LED. It teaches the loop, LED direction, and why the 220 Ω resistor matters.
What you need
- 1× 3×AA battery pack (4.5 V) L1
- 1× Solderless breadboard L1
- 7× Jumper wires one long jumper doubles as the trip wire itself across the doorway L1
- 1× Slide switch stands in for the trip wire while you prototype (closed = wire intact, open = wire cut) L1
- 1× 10 kΩ resistor pull-up — holds the base up whenever the trip wire is open L1
- 1× NPN transistor (2N2222) flat face toward you: legs are E-B-C L3
- 1× DC motor (3 V) the same little hobby motor from First Spin — a paper flag on the shaft makes the "alarm" visible
- 1× Diode (1N4001) flyback protection — cathode toward battery +, same as First Spin
you'll learn: Transistor switching · Switches · Ohm's law
Circuit map
The circuit you'll build, running on the Workbench right now — shown with the switch opened.
simulating…
If it doesn't work
The boring ways this circuit actually breaks — check these first before you unwire everything.
- Fan spins when the trip wire is intact. The slide switch isn't shorting the base to −. Tactile-style switches often bridge diagonally; slide switches bridge the two closest legs when the actuator sits over that half. Move a wire until closing the switch actually stops the fan.
- Fan silent even when the trip wire is cut. The 10 kΩ pull-up is missing or on the wrong side. It should sit between + and the base node — trace + → 10 kΩ → base → transistor B with a finger.
- Transistor gets hot even when the wire is intact. E-B-C pins scrambled. Flat face toward you, legs left-to-right are Emitter, Base, Collector. Backwards transistors dump heat instead of switching.
- Fan spins weakly and something smells warm. 1N4001 wired backwards — banded end (cathode) must face battery +. Reversed, it lets current skip the motor and pour through the diode and the transistor instead, so the fan barely turns and the transistor heats up.
- Fan doesn't quite start when the wire is cut. Static friction — a stopped motor needs a nudge to spin at 76 mA. Flick the blade once with your finger; the transistor's linear-region drive holds it going but doesn't always break stiction.
- Fan stops as soon as I close the wire again. That's correct — the base gets pulled back to −, the transistor turns off, the flyback diode dumps the coil's kick. For an alarm that *latches* on until reset, you'll need a Level 6 chip (the 555 in flip-flop mode).
What you're building
Stretch a thin wire across a doorway. Tie both ends to a little box on the floor. As long as the wire is intact, the box is silent and the battery barely notices. Snap the wire — a foot walking through, a door swinging open, a sibling sneaking in — and the fan spins as the alarm.
You already built this shape at Level 3 in Trip Wire Alarm. Only the mouth changed. The brain — a pull-up resistor + a normally-closed switch + a transistor — is exactly the one you learned there. Swap the buzzer for a motor + flyback diode and the same trip-wire circuit becomes a motion alarm: a spinning shaft you can see (and, if you tape a paper flag to it, hear thwapping against the desk).
The big idea: fail-safe means "failure sounds the alarm"
Compare this to Handheld Fan. That circuit is normally open: no button press, no motor. If the button's wire quietly fell off in the night, the fan just wouldn't spin — and you'd never know until you tried it.
This project is normally closed: the trip wire holds the alarm silent. If anything opens that loop — the wire is cut, a joint fails, a jumper gets bumped out — the alarm fires. A spinning motor means "either someone crossed the wire OR the loop broke; either way, come look".
It doesn't cover every failure, though. A dead battery, a loose motor lead or a burnt-out transistor all fail silent. That's why real alarms get tested now and then, and why this one is a teaching circuit, not a security system.
Burglar alarm loops and lots of door switches use this same trick. A broken loop sounds the alarm.
Reuse from Level 3 (the "brain")
- 10 kΩ pull-up from the + rail to the base node. When nothing else pulls the node down, the pull-up quietly tries to drag the base up to +.
- Slide switch as the trip wire between the base node and the − rail. Closed = wire intact = base shorted to − = transistor off. Open = wire cut = pull-up wins = transistor on.
- 2N2222 transistor turns on when its base sits above the ~0.7 V wake-up line.
New at Level 4 (the "mouth")
- DC motor (~30 Ω coil).
- 1N4001 flyback diode across the motor, cathode (banded end) toward battery +. Reverse-biased and invisible while the motor runs; catches the coil's inductive kick the moment the transistor turns off.
Do the math
Trip wire intact (switch closed):
- The switch pins the base to − through ~0 Ω. Base at 0 V.
- Transistor off. Motor idle. Battery current through the coil: microamps of leakage.
- The pull-up still sees a full 4.5 V across it: I = 4.5 V ÷ 10 kΩ = 0.45 mA flowing continuously from + through the 10 kΩ, through the closed trip wire, back to −. That's the armed drain.
- Three fresh AA cells in series (still ~2500 mAh — series adds volts, not capacity) at 0.45 mA last about 5,500 hours ≈ 7 months armed. Real house-alarm loops draw about this much for exactly this reason.
Trip wire cut (switch open):
- No path from the base node to −.
- Pull-up drags the base up until it clamps at ~0.7 V (transistor's base junction acting as a diode).
- I_base = (4.5 − 0.7) V ÷ 10 kΩ = 0.38 mA — modest.
- β × I_base ≈ 200 × 0.38 = 76 mA — the collector's maximum.
- The motor's natural current at 4.5 V is (4.5 − V_CE) ÷ 30 Ω. If the transistor were fully saturated, V_CE ≈ 0.2 V and the motor would pull ~143 mA. But 76 mA < 143 mA, so the transistor can't quite saturate the motor. It stays in its linear region and passes exactly what the base commanded.
- Motor at ~76 mA. V_R_motor ≈ 76 mA × 30 Ω = 2.3 V. V_CE ≈ 4.5 − 2.3 = 2.2 V. Transistor dissipates I_C × V_CE ≈ 170 mW — warm to the touch, well inside the 2N2222's 625 mW ceiling.
- Motor sees ~2.3 V — roughly half of full-speed voltage. Fan runs at about half speed. Slower than Handheld Fan, but unmistakably alive.
Why not saturate the motor? You could shrink the pull-up to 1 kΩ. That gives the base 3.8 mA and reaches full saturation → 143 mA motor. But then the armed drain climbs to 4.5 mA, and the AAs die in three weeks. The 10 kΩ pull-up is the same value Trip Wire Alarm used, for the same reason: a trip wire needs to sit armed for months without draining the battery. Trading fan speed for battery life is the right call for a burglar alarm.
Compare to Trip Wire Alarm
Same left half, different right half:
| Trip Wire Alarm | Trip Wire Fan (this) | |
|---|---|---|
| Pull-up | 10 kΩ | 10 kΩ |
| Trigger | slide switch (NC) | slide switch (NC) |
| Transistor | 2N2222 | 2N2222 |
| Output lane | active buzzer | motor + 1N4001 |
| Current when firing | ~29 mA (saturated) | ~76 mA (linear) |
| Battery drain armed | ~0.45 mA | ~0.45 mA |
| Alarm signal | audible beep | spinning fan / flapping flag |
The buzzer saturates the transistor because 76 mA of collector cap is way more than a 29 mA buzzer needs. The motor doesn't saturate because its 143 mA appetite outruns the collector cap. Same brain; different-appetite mouths land the transistor in different operating regions. That's a real insight — every big industrial motor driver has to reason about "am I going to actually saturate this transistor with the base drive I've got?"
Build it
If your Trip Wire Alarm is still on the breadboard, this is a one-minute upgrade: pull the buzzer out and drop a motor + flyback diode in its place.
Fresh build:
- Power rails: battery + to a top row, battery − to a bottom row.
- Pull-up: battery + → 10 kΩ → base node (call it row B).
- Trip wire: base node → slide switch → battery −. Closed = wire intact.
- Base link: row B → transistor Base (middle leg; flat face toward you, legs E-B-C left-to-right).
- Transistor: Emitter → − rail; Collector → fresh row A.
- Motor lane: motor between the + rail and row A.
- Flyback diode across the motor: cathode (banded end) on the + rail side, anode on row A. Same placement as First Spin and every L4 project.
- Slide switch closed → fan silent. Slide switch open → fan spins at about half speed. You'll hear the difference from Handheld Fan: this fan isn't being pushed to its limit, so it sounds calmer.
From breadboard to real trip wire
The slide switch is a stand-in. Once the breadboard version works:
- A loop of thin thread taped across the doorway, with each end wound around a small metal pad or paper clip on the breadboard. A snapped thread breaks the connection → fan spins.
- Kitchen aluminium foil across the doorway, bridging two paper clips. Pushing through tears the foil → fan spins.
- A magnetic reed switch on the door frame: closed while the door is shut, opens as it swings.
- A pressure-mat switch under a rug: closed while nobody's standing on it; broken when weight lifts.
Every one of these is "a normally-closed sensor" replacing the slide switch. The circuit doesn't care what the sensor's made of — only whether it's currently short-circuit or open.
What this pattern opens up
- Freezer alarm: a reed switch on the door. Door open = motor spins on a warning fan.
- Bedroom "did anyone come in" sensor: thread across the door before you go out. Snapped = fan spun = someone was here.
- Chair monitor: a switch under a cushion held closed by weight. Person stands up = switch opens = fan spins as an "empty chair" alert.
Level 6 will let you latch the alarm on so it stays running after the wire is retied (a 555 in flip-flop mode). Level 7 replaces the wire itself with an infrared beam and an Arduino reading it. The mouth — the motor with a flyback diode — stays exactly this.
🧠 Your challenge
No single right answer. That's the point.
- Trip wire + horn. Add an active buzzer in parallel with the motor (buzzer's − leg on the collector, + leg on the + rail). Now cutting the wire spins the fan and beeps. What's the total collector current when firing? (The transistor is already at its 76 mA cap. The buzzer wants ~29 mA, the motor wants 143 mA — together 172 mA. The cap doesn't get any bigger, so the two loads share the 76 mA available. Both end up under-driven: fan slower still, buzzer quieter than Trip Wire Alarm. Real fix: shrink the pull-up.)
- Faster fan, shorter armed life. Swap the 10 kΩ pull-up for the 1 kΩ. Redo the math. What's the new base current? Motor current? Armed drain? (I_base = 3.8 mA → deep saturation → motor at 143 mA. Armed drain = 4.5 mA — AAs last three weeks instead of seven months. Whether the trade is worth it depends on what you're monitoring.)
- Two trip wires, one alarm. Wire a second slide switch in parallel with the first — both go from the base node to −. Either one closed = base held low = alarm silent. BOTH cut = alarm fires. When would you want this? (Two-of-two safety — the alarm only fires if both sensors agree "something's up", useful for a system prone to false alarms. The trade is that a single failing wire won't sound it.)
- AND-gate trip wires. Now put the two slide switches in series between the base node and −. Both must be closed (intact) to keep the alarm silent. Either wire cut → alarm fires. What's the failure story now? (Cutting the window wire OR the door wire spins the fan. That's the more common alarm topology — cover more zones with one motor.)
- Add a manual disarm. Put your push button in parallel with the slide switch. Pressing the button (while the wire is cut) shorts the base back to − — the fan stops as long as you hold it. Useful for silencing the alarm while you inspect. Draw the schematic first.
For grown-ups: safety notes
- Battery-safe throughout. The motor draws ~76 mA, but 4.5 V can't push any current you'd feel through dry skin.
- Diode polarity matters most. Cathode (banded end) toward battery +. Reversed, the diode lets current skip the motor and run straight through the diode and transistor the moment the transistor turns on. The fan barely turns and the transistor gets hot. Disconnect and flip it if you smell anything warm.
- The transistor gets warm when firing. That's real physics, not a mistake — the transistor is in linear region (not saturated), dissipating ~170 mW as heat. Warm to the touch is normal. Hot enough to hurt within seconds isn't — that means E-B-C pins are scrambled. Flat face toward you, legs left-to-right are Emitter, Base, Collector.
- The 10 kΩ pull-up drains ~0.45 mA while the loop is armed. Fresh AAs last months in this state — the battery outliving a normal-use flashlight.
- The trip wire can be any conductor: thin thread wrapped around bared jumper ends, aluminium foil, a reed switch, a pressure mat. Don't use stripped mains wire; use only low-voltage hobby wire. Nothing in this project should ever touch the wall socket.
- Fingers, hair, and paper blades don't mix well. At half-speed the motor is still turning fast — tie hair back and keep loose sleeves clear.
- If you tape a paper flag to the motor shaft as the visible-alarm trick, make sure it's small and light so it doesn't unbalance the shaft or catch on nearby parts.
- Never wire this to mains. Every part is 4.5 V-safe.
Checked against
Keep building
You might also like
shares ideas with this one