Home · Academy · Robotics & Coding · Introduction to Electronics · Project: Light Alert Circuit

Project: Light Alert Circuit

Build, test and debug a low-voltage alert circuit that drives an LED and buzzer with a button.

PROJECT COMPASS

What will you use this page for?

Core idea

In this project we will build, test and debug a small, fully low-voltage circuit that gives a warning with an LED and a buzzer when a button is pressed (or a switch is turned on).

Evidence to produce

Complete the page task with your own input, test conditions and reasoning.

Control trap

The most common problem: you press the button but the LED does not light. No panic — debugging is part of learning. Check in order: Symptom: button pressed, LED does not light. 1. Polarity: is the LED's long leg on the resistor side? Reversed, it passes no current. Turn the legs around. 2. Resistor: a very high value…

Next connection

The Sensors and Actuators module: we will see how the circuit becomes "smart" when a sensor replaces the button and a program-controlled output replaces the LED.

Module sources: Python Tutorial · Arduino Learn

LevelBeginner
Age10–16
Duration45–75 min
PrerequisiteReading Circuit Schematics
ContentProject guide · 1,674 words
Last updated

One-sentence summary

In this project we will build, test and debug a small, fully low-voltage circuit that gives a warning with an LED and a buzzer when a button is pressed (or a switch is turned on).

Why does it matter?

Last lesson we read the symbols in a circuit diagram; now we turn them into real parts and build a working circuit. Even a simple light alert circuit brings together the core ideas of electronics: a power source, switching, current limiting and an output (light and sound). Everyday life is full of this pattern:

In both cases there is a condition (door open, belt not fastened), and when it is true an output runs (sound, light). Our circuit is the simplest form of that idea: a button sets the condition, and an LED and buzzer give the output.

What will we build?

The idea of the circuit

The job of our circuit in one sentence: when the button is pressed, the LED lights and the buzzer sounds; when it is released, both go quiet.

The button acts as a switch — the part that opens and closes the circuit's path. While it is open, no current flows and the outputs are silent; pressing the button completes the path and the warning begins. You could later swap the button for a lever switch that keeps warning while on; the logic is the same.

Parts list

Every part is low-voltage. Mains electricity or a wall socket is never used.

Parts list table
PartQtyNote
AA battery (1.5 V)34.5 V total in the holder
Battery holder (3×AA)1Red (+) and black (−) leads
Breadboard1Solderless connections
Push-button14-leg mini button
LED (red)1Long leg is plus (+)
Resistor1220–330 Ω, limits current
Active buzzer (3–5 V)1Sounds on its own
Jumper wires5–6Male-to-male

Why do we calculate the resistor value?

Connected straight to the battery, an LED gets too much current and can be damaged, so we add a resistor to limit it, sized with Ohm's law.

A red LED needs about 2 V and works well at 10 mA (0.01 A). Our battery gives 4.5 V, so the resistor takes the difference:

Voltage across resistor = Battery voltage − LED voltage
                        = 4.5 V − 2 V
                        = 2.5 V

R = Voltage / Current
R = 2.5 V / 0.01 A
R = 250 Ω

250 Ω is not a value sold exactly. The nearest easy-to-find sizes are 220 Ω and 330 Ω. With 330 Ω the current drops a little (about 7.5 mA), which is safe and still bright, so that is what we use. An active buzzer runs directly on 4.5 V, so it needs no resistor.

Circuit diagram (text)

Here the circuit is drawn in words: [ ] is a part, ─── is a wire. In diagrams the LED symbol is a triangle with a line; the tip points the way current flows, and the short leg is the minus (−) side.

        + side                                            − side
[Battery 4.5V] ─── [Button] ─── [Resistor 330Ω] ─── [LED ▷|] ───┐
     │                                                          │
     └──────────────────────────────────────────── (returns to same − side)

Buzzer branch (parallel to the LED):
[Button output] ─── [Buzzer +] ─── [Buzzer −] ─── (returns to − side)

Reading order: current leaves the plus side and reaches the button; if it is not pressed, the path stops there. Pressed, current flows through the resistor and the LED back to minus, and a branch runs to the buzzer, so light and sound work together.

Step-by-step build

Do these steps with an adult, at a calm table.

  1. Do not put the batteries in yet. Make all connections first, power last.
  2. Place the button across the gap in the middle of the breadboard, legs on both sides.
  3. Connect the red (+) lead of the holder to the row of one button leg.
  4. From the opposite button leg, run a jumper to one end of the 330 Ω resistor.
  5. Connect the resistor's other end to the LED's long leg (plus side).
  6. Connect the LED's short leg (minus) with a jumper to the row of the black (−) lead.
  7. Add the buzzer: (+) to the point between resistor and LED, (−) to the LED's minus line.
  8. Trace every connection by eye and compare with the diagram.
  9. Now insert the batteries, watching polarity. The circuit is powered.

Test scenarios

With the circuit powered, try each case:

One error and its fix

The most common problem: you press the button but the LED does not light. No panic — debugging is part of learning. Check in order:

Symptom: button pressed, LED does not light.

1. Polarity: is the LED's long leg on the resistor side?
   Reversed, it passes no current. Turn the legs around.

2. Resistor: a very high value (e.g. 10,000 Ω) gives
   too little current to light it. Confirm it is 330 Ω.

3. Connection: a jumper may not be fully seated.
   Press each end and compare with the diagram.

4. Power: batteries may be dead or backwards.
   Review the + and − directions of the holder.

Most of the time it is the first item: the LED inserted the wrong way. Change one thing at a time and retry, so you see which change fixed it.

Ideas to improve the circuit

Once the basic circuit works, try these:

Mini practice

On paper: if you wanted the LED to light when the button is released and go off when it is pressed, what would you change, and what kind of switch would you need?

Hint: our button is the "close when pressed" type (normally open). A "normally closed" switch does the opposite. Write your answer in two sentences, then check the Answers section.

Common mistakes

Forgetting the resistor

Wiring the LED straight to the battery is the most common mistake. With no current limit, it can be damaged. Always put a resistor in each LED branch.

Connecting the LED backwards

An LED is direction-sensitive: long leg to plus, short leg to minus. Reversed, no current flows and it stays dark.

Creating a short circuit

Joining the plus and minus sides directly, with no part between, is a short circuit. The batteries heat up and drain fast. Trace the diagram before connecting.

Powering up too early

Changing connections while the batteries are in can cause a wrong reading or a spark. Build first, power last.

Safety note

Lesson summary

Check questions

  1. What is the job of the button in the circuit?
  2. Why do we add a resistor to the LED branch?
  3. Calculate the resistor for a 4.5 V battery and a 2 V, 10 mA LED using Ohm's law.
  4. If the button is pressed but the LED does not light, what should you check first?
  5. Why is a wall socket or mains electricity never used in this project?

Answers

  1. The button acts as a switch; it opens and closes the circuit's path. Pressed, the path is completed and current flows.
  2. The resistor limits the current. Without it, too much current passes through the LED and it can be damaged.
  3. R = (4.5 V − 2 V) / 0.01 A = 2.5 V / 0.01 A = 250 Ω. The nearest easy-to-find value, 220–330 Ω, is used.
  4. Polarity: check that the LED's long leg (plus) is on the resistor side. Reversed, no current flows.
  5. Mains electricity is high-voltage and dangerous. Learning circuits use only low-voltage sources — batteries, USB or a micro:bit.

Mini practice answer: You would need a "normally closed" switch. It keeps the circuit closed while not pressed and cuts the path when pressed, so the LED lights when released and goes off when pressed.

Source and verification note

For “Project: Light Alert Circuit”, verification focuses on whether the relationship between What will we build? and Parts list remains consistent across examples. Activities are designed only for low-voltage direct-current circuits; mains electricity is not used. Component values must be rechecked for the actual circuit, and connections should be reviewed with an adult before power is applied.

Next lesson

The Sensors and Actuators module: we will see how the circuit becomes "smart" when a sensor replaces the button and a program-controlled output replaces the LED.

Start QuizBack to Introduction to Electronics
QUESTION POOL

Reinforce this lesson with 10 questions

This lesson has a pool of 20 questions. Each attempt selects 10 and reshuffles the choices.