Interfacing PIR Motion Sensor with Arduino:

PIR Sensor Circuit Diagram
Drag Me
Serial Monitor (COM3)
Waiting for simulation to start...

Instructions

Objective:

Learn how a PIR motion sensor detects movement and triggers an LED output.

Steps to Perform:

  1. Click "Start Simulation" to power up the Arduino circuit
  2. Drag the person icon near the PIR sensor to trigger motion detection
  3. Observe how the LED turns ON when motion is detected
  4. Drag the person away to stop the motion
  5. Watch the LED turn OFF when motion ends
  6. Check the Serial Monitor for motion detection messages

Key Concepts:

  • PIR Sensor: Detects infrared radiation changes from moving objects
  • Detection Zone: Area where sensor can detect motion (shown in green)
  • Digital Input: Sensor provides HIGH (motion) or LOW (no motion) signal
  • Digital Output: Arduino controls LED based on sensor reading
  • digitalRead(): Reads motion sensor state from digital pin 2
  • digitalWrite(): Sets LED pin HIGH (ON) or LOW (OFF)
Arduino Code - sketch_pir_sensor.ino