The Maker’s Toolkit: Essential Arduino Components, Sensors, Motors, and LEDs
Follow the path from a sensor reading to a light or motion output.
An Arduino project combines a board, a program, and components that sense or act. Using the UNO R3 as a reference, this lesson shows how breadboards, sensors, LEDs, and motors work together. Two virtual activities let you test the logic without hardware.

What goes into an Arduino project?
A desk lamp that turns on when the room gets dark and a model gate that lifts when an object approaches have the same basic structure. Something measures a change, a program decides what to do, and an output device acts. An Arduino board runs the program and provides the connections that let these parts work together. Once you can trace the path from measurement to action, it becomes easier to choose parts and explain why a project behaves the way it does.
Before you start: You only need to know that a program follows instructions and that a circuit needs a complete path for current. This lesson uses the Arduino UNO R3 as a reference and can be completed without physical hardware.
- Identify the job of each common Arduino accessory.
- Trace a sensor reading through a program to a light or motion output.
- Explain why a bare LED needs a series resistor and why a DC motor needs a driver.
Start with the board, breadboard, and jumper wires
The UNO R3 contains a microcontroller, a small computer that runs your program. The rows of connectors along the board let the microcontroller receive signals and send commands. A digital input can distinguish two logic states, often called HIGH and LOW. An analog input such as A0 measures a voltage relative to ground. A digital output sets a logic state, for example to turn a light on or send a command to a driver.
The board also provides power connections, such as 5V and GND on the UNO R3. Ground supplies a reference for interpreting signals and is part of the current return path. The same-looking connector on a different Arduino model can have different limits. When choosing a module, check both its supply voltage and the voltage levels on its signal pins.
A solderless breadboard holds parts while you test a prototype. Hidden metal clips join groups of holes. Two leads in one connected group are electrically joined even if they never touch above the plastic. The center gap separates the terminal strips on either side. Some boards also have long power rails whose connections may be split midway. Jumper wires carry a connection between otherwise separate groups or between the board and a module. Trace the groups before you assume a wire or rail reaches where you expect.
| Part | Job | Example interaction |
|---|---|---|
| Pushbutton | Gives the program a user input. | A digital input reads one state when pressed and another when released, with a pull-up or pull-down to define the resting state. |
| Photoresistor | Changes resistance as the light changes. | A two-resistor voltage divider produces a voltage the analog input can measure. |
| LED | Produces a visible signal. | A board output switches an external LED circuit with a series resistor. |
| DC motor and driver | Produce continuous rotation. | The board commands the driver, which switches motor current from a suitable supply. |
| Positional hobby servo | Moves its shaft toward a commanded position. | The board sends timed pulses to the servo's control input. A suitable power supply serves the servo's power leads. |
Sense, decide, act
A sensor makes a physical condition available to the program. A photoresistor usually has lower resistance in brighter light. A circuit combines it with a fixed resistor to turn that change into a measurable voltage. Which way the measured voltage moves depends on the placement of the two resistors. A sensor module may instead provide a digital signal or send measurements using a communication protocol, so the label on the module matters.
Once the program reads the input, it applies a rule. The rule might compare the reading with a threshold, a cutoff that divides two cases. The program can then choose an output, such as turning on an indicator or commanding a motor driver. A weak connection can affect the reading even when the rule is correct. A reversed comparison can make the wrong decision even when the reading is correct. Checking each stage helps isolate the cause.
Worked example: An automatic night light
- Sense. Use a virtual brightness scale from 0 to 100, with higher readings meaning brighter conditions. Suppose the reading is 25. The scale represents a normalized classroom model and has no unit of physical light measurement.
- Decide. Apply the rule “turn the LED on when brightness is below 40.” Compare 25 with 40. Since 25 is below 40, the rule selects ON.
- Act. The program commands the LED to light. A real external LED needs a resistor in series so the same limited current passes through both parts.
- Check the boundary. At exactly 40, the condition “below 40” is false. The LED switches off. If your design should light at 40 as well, the rule must say “40 or below.”
Open the interactive activities below
Choose the output circuit
LEDs for visible feedback
A bare LED is a light-emitting diode. Current flows in its intended direction from anode to cathode. On many new through-hole LEDs the longer lead is the anode, but check the part markings or datasheet if the leads have been clipped. A series resistor limits current. Its resistance depends on the supply or output voltage, the LED's forward voltage, the target current, and the circuit's limits. For a first code experiment, you can use the UNO R3's built-in LED, whose circuit is already on the board.
This short sketch demonstrates an output command using the same value as the worked example. A full sensor project would replace the fixed number with a reading converted to the intended scale.
const int brightness = 25;
void setup() {
pinMode(LED_BUILTIN, OUTPUT);
}
void loop() {
if (brightness < 40) {
digitalWrite(LED_BUILTIN, HIGH);
} else {
digitalWrite(LED_BUILTIN, LOW);
}
}
On an UNO R3, the built-in LED stays on with this sketch. pinMode prepares the pin to send a signal. The comparison selects a branch on each pass through loop. With a fixed reading of 25, the same branch runs each time.
Motors for movement
A small brushed DC motor can spin a wheel or turn a fan. An Arduino signal pin should command a compatible driver rather than carry the motor current. The driver and motor supply need ratings that account for the higher current a motor can draw at startup or when blocked. When a motor is switched off, its inductance can create a voltage spike. A suitable driver circuit provides a path for that current, such as a flyback diode in a simple one-direction circuit.
A positional servo suits a model gate that should move to a chosen position and hold it within its working range. Its control circuit interprets the timed pulses and drives the motor inside the servo. A stepper motor moves in increments and needs its own compatible driver. You might choose one for indexing a turntable through a series of positions. The power supply and driver requirements depend on the exact parts. Keep physical builds to classroom low-voltage equipment, disconnect power before changing wiring, and have a teacher check any motor setup before powering it.
Worked example: Match the output to the job
A model fan must rotate continuously when a temperature sensor reports a warm condition. Choose a brushed DC motor and a compatible driver. The sensor provides the input, the Arduino decides when to start the fan, and the driver switches current in the motor circuit. For a positionable air vent, a positional servo would be a better fit because the output must go to an angle instead of spinning continuously.
Open the interactive activities below
Common mistakes and what to check
- The night light turns on in daylight. Check whether higher readings really mean brighter light before you change the comparison.
- The LED stays dark. In a supervised build with power disconnected, check diode orientation, the path through the series resistor, and whether the correct pin is configured as an output.
- The motor and board reset together. Have a teacher check whether the motor supply and driver can handle startup current and whether the setup follows the driver documentation.
- A breadboard circuit looks connected but behaves as if a wire is missing. Follow the electrical groups under the holes. A center gap or a split rail can interrupt the path.
Practice and check your reasoning
- For brightness 39, 40, and 41, predict the night light state before using the simulator.
Worked solution
39 is below 40, so the LED is on. 40 equals the cutoff, so the LED is off. 41 is above the cutoff, so the LED stays off. The comparison is strict.
- A pet-feeder model has a flap that must move to a set angle. Choose between a positional servo and a brushed DC motor with a basic on/off driver. Explain your choice.
Worked solution
Choose the positional servo. It receives a position command and moves toward that angle. A basic on/off driver lets a DC motor turn, but provides no position control by itself.
- A warm model enclosure should activate a fan. Explain what flows from the Arduino to the driver and what flows through the motor circuit.
Worked solution
The Arduino sends a control signal to the driver. The driver switches the motor current supplied by a power source chosen for the motor and driver. This allows a low-current signal to control the higher-current load.
Key takeaways
Trace the project in order: input, program decision, output. Then trace power separately. A bare LED needs current limiting, a brushed DC motor needs a suitable driver, and a positional servo accepts an angle-related command while drawing power through its power leads. When debugging, record the reading, the decision, and the observed output before changing anything.
For a next step without wiring, use the sketch to predict and compare the LED behavior for constants of 25 and 55. The Arduino Blink example is a starting point for changing the built-in LED over time. For more on sensors, see Arduino Analog Input. For hardware specifications, consult the UNO R3 pinout.
Interactive activities
Definitions
Microcontroller
A small computer on the board that runs the program and uses pins to communicate with circuits.
Breadboard
A solderless prototyping board whose internal metal clips connect groups of holes.
Sensor
A component that responds to a physical condition such as light or temperature.
Threshold
A cutoff used by the program to choose between cases.
LED
A diode that produces light when current flows through it in the intended direction.
Motor driver
A circuit that uses a control signal to switch current through a motor.
Positional servo
A motor assembly with internal control that moves its shaft toward a commanded position within its range.
Worked examples
An automatic night light
On a virtual brightness scale from 0 to 100, a night light turns on only below 40. What happens at 25 and 40?
Compare each reading with the threshold. At 25, the comparison is true, so the program commands the LED on. At 40, the reading equals the cutoff and is therefore outside the strict below-40 condition. The LED is off.
Match the output to the job
Choose outputs for a continuously rotating fan and a positionable vent.
For the fan, choose a brushed DC motor with a compatible driver so the motor can rotate continuously. A temperature sensor supplies the reading, the Arduino applies the rule, and the driver switches motor current. For the vent, choose a positional servo because the output needs to reach a commanded angle.
Common mistakes to avoid
- Assuming analog readings always increase with light. Check how the sensor circuit maps brightness to voltage.
- Treating “below 40” as “40 or below.” Test the exact boundary to confirm which branch runs.
- Omitting a series resistor for a bare LED. Use current limiting appropriate to the circuit.
- Expecting an Arduino I/O pin to supply a DC motor. Use a compatible motor driver and suitable motor supply.
- Assuming the breadboard rails connect end to end. Check the layout for a split in the rail.
Practice exercises
Test the cutoff
For readings of 39, 40, and 41, predict the night light state under the below-40 rule.
Hint: Decide whether each value is strictly below 40.
Show solution
39 is below 40, so the LED is on. 40 equals the cutoff and 41 is above it, so the LED is off in both cases.
Choose a feeder mechanism
A model feeder flap must move to a set angle. Choose a positional servo or a brushed DC motor with a basic on/off driver.
Hint: Look for the component that accepts a position command.
Show solution
Choose the positional servo. It moves toward the commanded position. A basic on/off driver can start or stop a DC motor, but provides no position control by itself.
Separate signal and power
A warm enclosure activates a fan. Explain what flows from the Arduino to the driver and what flows in the motor circuit.
Hint: Trace the board command separately from the current that turns the fan.
Show solution
The Arduino sends a control signal to the driver. The driver switches current in the motor circuit from a power supply selected for the motor and driver.
Key takeaways
- Sensors provide input, a program applies a decision rule, and output devices act.
- Breadboard groups and jumper wires form electrical connections.
- An external bare LED needs a series resistor to limit current.
- An Arduino controls a brushed DC motor through a compatible driver.
- A positional servo receives an angle-related command and has separate power connections.