Cirkit Designer Logo
Cirkit Designer
Your all-in-one circuit design IDE
Home / 
Component Documentation

How to Use PIR HC-SR501: Examples, Pinouts, and Specs

Image of PIR HC-SR501
Cirkit Designer LogoDesign with PIR HC-SR501 in Cirkit Designer

Introduction

The PIR HC-SR501 is a Passive Infrared (PIR) sensor module designed to detect motion through changes in infrared levels emitted by objects in its field of view. It is widely used in security systems, lighting controls, and home automation projects due to its low cost, ease of use, and reliability.

Explore Projects Built with PIR HC-SR501

Use Cirkit Designer to design, explore, and prototype these projects online. Some projects support real-time simulation. Click "Open Project" to start designing instantly!
PIR Motion-Activated LED Light
Image of 0: A project utilizing PIR HC-SR501 in a practical application
This circuit is a simple motion-activated LED light system. The HC-SR505 Mini PIR Motion Sensing Module is powered by a 9V battery and detects motion, upon which it sends an output signal to turn on the red LED. The LED and the PIR sensor share a common ground with the battery, completing the circuit.
Cirkit Designer LogoOpen Project in Cirkit Designer
Raspberry Pi 5 Motion Detection System with HC-SR501 Sensor
Image of PIR: A project utilizing PIR HC-SR501 in a practical application
This circuit connects a Raspberry Pi 5 to an HC-SR501 motion sensor. The Raspberry Pi provides power to the motion sensor and reads its output signal through GPIO 17, allowing the Raspberry Pi to detect motion events.
Cirkit Designer LogoOpen Project in Cirkit Designer
Raspberry Pi Motion-Activated LED System with PIR Sensor
Image of Detection project: A project utilizing PIR HC-SR501 in a practical application
This circuit uses a Raspberry Pi 5 to control an LED based on input from an HC-SR501 PIR motion sensor. The motion sensor is powered by the Raspberry Pi and its output is connected to a GPIO pin, which the Raspberry Pi monitors to detect motion. When motion is detected, the Raspberry Pi can turn on the LED through another GPIO pin, with a current-limiting resistor in series with the LED.
Cirkit Designer LogoOpen Project in Cirkit Designer
Arduino UNO-Based Security System with PIR Motion Detection and Bluetooth Connectivity
Image of 아두이노 캡스톤 : A project utilizing PIR HC-SR501 in a practical application
This circuit features an Arduino UNO microcontroller interfaced with a PIR motion sensor (HC-SR501), a Bluetooth module (HC-06), a buzzer (FIT0449), and a soil moisture sensor (SEN040129). The Arduino is programmed to interact with these sensors and actuators, likely to monitor environmental conditions and provide alerts or communication via Bluetooth. Additionally, there are two LED components (JLED-START and JLED-ARROW-9) daisy-chained together, which could be used for visual signaling or status indication.
Cirkit Designer LogoOpen Project in Cirkit Designer

Explore Projects Built with PIR HC-SR501

Use Cirkit Designer to design, explore, and prototype these projects online. Some projects support real-time simulation. Click "Open Project" to start designing instantly!
Image of 0: A project utilizing PIR HC-SR501 in a practical application
PIR Motion-Activated LED Light
This circuit is a simple motion-activated LED light system. The HC-SR505 Mini PIR Motion Sensing Module is powered by a 9V battery and detects motion, upon which it sends an output signal to turn on the red LED. The LED and the PIR sensor share a common ground with the battery, completing the circuit.
Cirkit Designer LogoOpen Project in Cirkit Designer
Image of PIR: A project utilizing PIR HC-SR501 in a practical application
Raspberry Pi 5 Motion Detection System with HC-SR501 Sensor
This circuit connects a Raspberry Pi 5 to an HC-SR501 motion sensor. The Raspberry Pi provides power to the motion sensor and reads its output signal through GPIO 17, allowing the Raspberry Pi to detect motion events.
Cirkit Designer LogoOpen Project in Cirkit Designer
Image of Detection project: A project utilizing PIR HC-SR501 in a practical application
Raspberry Pi Motion-Activated LED System with PIR Sensor
This circuit uses a Raspberry Pi 5 to control an LED based on input from an HC-SR501 PIR motion sensor. The motion sensor is powered by the Raspberry Pi and its output is connected to a GPIO pin, which the Raspberry Pi monitors to detect motion. When motion is detected, the Raspberry Pi can turn on the LED through another GPIO pin, with a current-limiting resistor in series with the LED.
Cirkit Designer LogoOpen Project in Cirkit Designer
Image of 아두이노 캡스톤 : A project utilizing PIR HC-SR501 in a practical application
Arduino UNO-Based Security System with PIR Motion Detection and Bluetooth Connectivity
This circuit features an Arduino UNO microcontroller interfaced with a PIR motion sensor (HC-SR501), a Bluetooth module (HC-06), a buzzer (FIT0449), and a soil moisture sensor (SEN040129). The Arduino is programmed to interact with these sensors and actuators, likely to monitor environmental conditions and provide alerts or communication via Bluetooth. Additionally, there are two LED components (JLED-START and JLED-ARROW-9) daisy-chained together, which could be used for visual signaling or status indication.
Cirkit Designer LogoOpen Project in Cirkit Designer

Common Applications and Use Cases

  • Motion-activated alarms
  • Automatic lighting control
  • Presence detection for energy-saving systems
  • Robotics and interactive installations

Technical Specifications

Key Technical Details

  • Voltage: 5V – 20V
  • Current: 65mA (typical)
  • Power Consumption: 0.15mW (static), 0.3mW (active)
  • Detection Range: Up to 7 meters
  • Detection Angle: < 120 degrees
  • Delay Time: Adjustable from 0.3 seconds to 5 minutes
  • Output Level: High 3.3V, Low 0V
  • Operating Temperature: -20°C to +80°C

Pin Configuration and Descriptions

Pin Name Description
VCC Power supply (5V – 20V)
OUT Digital output signal (High/Low)
GND Ground

Usage Instructions

How to Use the Component in a Circuit

  1. Connect the VCC pin to a 5V power supply.
  2. Connect the GND pin to the ground of the power supply.
  3. Connect the OUT pin to a digital input pin on a microcontroller, such as an Arduino UNO.

Important Considerations and Best Practices

  • Ensure that the power supply voltage does not exceed 20V.
  • Avoid placing the sensor in an environment with rapid temperature changes to prevent false triggers.
  • The sensor requires a warm-up time of approximately 20-60 seconds to calibrate to the infrared level of the environment.
  • Adjust the delay time and sensitivity knobs on the sensor module to suit your application needs.

Example Arduino UNO Code

// Define the PIR motion sensor pin
const int PIRPin = 2; // Connect PIR sensor's OUT pin to Arduino's pin 2

void setup() {
  pinMode(PIRPin, INPUT); // Set the PIR pin as an input
  Serial.begin(9600);    // Initialize serial communication
}

void loop() {
  int motionStatus = digitalRead(PIRPin); // Read the PIR sensor's output

  if (motionStatus == HIGH) {
    // When motion is detected, print a message
    Serial.println("Motion detected!");
    // Add your code here to handle the motion detection event
  } else {
    // When no motion is detected, print a message
    Serial.println("No motion detected.");
  }

  delay(1000); // Wait for 1 second before reading again
}

Troubleshooting and FAQs

Common Issues Users Might Face

  • False triggers: Adjust the sensitivity and delay time knobs to fine-tune the sensor's performance.
  • No response: Check the power supply and connections to ensure the sensor is properly powered and connected.
  • Intermittent operation: Ensure that the sensor is not facing a heat source or window where moving heat signatures can cause false triggers.

Solutions and Tips for Troubleshooting

  • If the sensor is not responding, verify that the power supply is within the specified voltage range and that all connections are secure.
  • In case of false triggers, try repositioning the sensor away from potential environmental interferences.
  • Allow the sensor to warm up and calibrate upon initial power-up before testing its functionality.

FAQs

Q: Can the sensor detect motion through walls? A: No, the PIR sensor cannot detect motion through walls as it relies on detecting infrared radiation from objects.

Q: How can I adjust the range and sensitivity of the sensor? A: The HC-SR501 module typically has two potentiometers to adjust the delay time and sensitivity. Rotate these knobs to increase or decrease the respective settings.

Q: Is it possible to power the sensor with a 3.3V supply? A: The sensor is designed to operate with a supply voltage of 5V to 20V. Using a voltage lower than 5V may result in unreliable or non-functional operation.