AREAS OF SCIENCE
Build a motion-activated guard robot and adjust its behavior to avoid false alarms.
Have you ever seen a movie with a guard robot or a battle droid, and wished you could have your own? While this project will not show you how to build a robot that can fly or shoot lasers, you can build a simple motion-activated robot that will suddenly come to life to scare away intruders. Figure 1 shows a picture of the robot, and you can watch the video for a demonstration.
Figure 1. The motion-activated guard robot you will build in this project.
How does the robot detect motion and know when to turn on? The robot can detect infrared (IR) light, which is a type of electromagnetic radiation. Humans can only see a small part of the electromagnetic spectrum (visible light), but there are many other types of electromagnetic radiation, like radio waves, x rays, and ultraviolet light. Infrared light is given off by warm objects, like a human body or a hot stove top, but it is just outside the range of what humans can see.
The robot relies on a special type of sensor to detect infrared light. Sensors are electronic components that can tell a robot or computer something about its surroundings. For example, cameras and microphones are types of sensors (very similar to eyes and ears for a human). This robot uses a passive infrared (PIR) sensor, which is designed to detect changes in infrared light. So, if a person is not moving, even though they still emit infrared light, they will not trigger the sensor. If a person walks by the sensor, however (or an intruder walks past the robot!), the sensor will detect a moving source of infrared light. The sensor is connected to a circuit, or group of other electronic parts, that turn on the robot's motors to make it move.
You might have actually encountered PIR sensors in everyday life, even if you did not realize it. They are very commonly used in home security systems, since they can "see" a person walking through a room, even at night! They are also used in energy-saving lighting systems to make motion-activated lights. The lights can automatically turn on when someone walks into a room, and will turn off if no movement has been detected for a certain period of time. Figure 2 shows the type of PIR sensor you might see in a house, school, or other building.
Figure 2. The type of PIR sensor you might see as part of a home security system or motion-controlled lighting system.
PIR sensors are usually designed to have a very wide field of view, or area that the sensor can "see." This can be great for a security system when you need a sensor to see an entire room, but it can be annoying if you only want your robot to guard a specific area. Watching for changes over a large area can create a false alarm and cause the robot to turn on accidentally. In this project, you will follow directions to build a motion-activated robot, then follow the Engineering Design Process to make adjustments to your PIR sensor's field of view to help avoid false alarms.
The rest of the Introduction contains more details about the electronic components used in the circuit. The following information is provided as a reference, and you do not need to fully understand it in order to do the project. If are ready to just start building the robot, you can move on to the Procedure.
If you would like to read the rest of the Introduction, it will help if you are familiar with basic electronics terms like voltage, current, and resistance. Science Buddies has many beginner and intermediate level electronics projects, an Electronics Primer, and an Electricity, Magnetism, & Electromagnetism Tutorial that can help you learn more about these topics. You can also refer to the Bibliography section for more information.
For a complete technical explanation of how the circuit works, including a circuit diagram, see the Help section.
The circuit you will build in this project requires a variety of electronic components. All of the components are combined on a chassis, or plastic base for the robot, which includes wheels. Some of the components, like batteries and switches, you probably use every day (even if you do not notice it). Others, like diodes and transistors, might be new to you if you have not done an electronics project before. Table 1 has pictures and descriptions of each component you will use in this project. For a more detailed explanation of what each component does in the circuit, see the Help section.
How do you combine all these components to control the motors and make the robot move forward? While the full details are in the Help section, there are two basic things that will help you understand:
Can you see how these two things could be set up to control a motor, and spin a wheel, based on whether or not the sensor detects motion? You need to connect the output of the sensor to the input of the MOSFET. Figure 3 shows a simplified diagram of this process (remember to refer to the Help section for the full explanation).
General terms:
Circuit components:
Advanced terms (see Help section):
Item Name
Battery pack
Picture
Description
This is the power supply for your robot. Battery packs come in all shapes and sizes. The one in this project holds 4 AA batteries.
Breadboard
A breadboard allows you to quickly and easily connect wires and electronic components in order to build a circuit. The connections are not permanent, so you can easily move things around if you make a mistake.
Switch
You use switches every day to turn lights and appliances on and off. This is a tiny switch that fits on a breadboard, to let you turn your robot on and off.
Jumper wire
Jumper wires are short wires used to make electrical connections on a breadboard. They come with many colors of plastic insulation, which makes it easy to color-code and organize complicated circuits.
DC Motor
Electrical current causes a motor to spin. Two motors drive the robot's wheels. This type of motor runs on direct current (DC) from a battery (as opposed to alternating current [AC] from a wall outlet).
MOSFET
A MOSFET is a special type of transistor, which acts like a control valve to let electrical current flow. As an analogy, think of how a valve can control the flow of water through a garden hose. In this circuit, the MOSFETs control the flow of current through the motors. See the Help section for more detailed information about MOSFETs, including what MOSFET stands for.
Diode
A diode is like a one-way valve for electricity. It only lets current flow in one direction. In this circuit, diodes are used to protect the MOSFETs from voltage spikes that can be caused by abruptly stopping the motors.
PIR Sensor
The passive infrared sensor acts as a motion detector. It has an output put that stays "low" (0 volts [V]) when it does not detect motion, and goes "high" (3.3 V) when it detects motion. This output can be used to activate other things in the circuit.
Male-female jumper wire
Table 1. Pictures and descriptions of each circuit component used in this project.