0% found this document useful (0 votes)
11 views

Assignment -2 Report

The report details a simulation of a PIR sensor output using an Arduino to generate a HIGH pulse for testing motion detection systems without physical hardware. The simulation, conducted on Tinkercad, allows for efficient prototyping and debugging of motion-sensitive circuits. The successful demonstration confirms that the simulated HIGH pulse effectively mimics motion detection, enabling verification of connected components' responses.

Uploaded by

mishraspam5
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
11 views

Assignment -2 Report

The report details a simulation of a PIR sensor output using an Arduino to generate a HIGH pulse for testing motion detection systems without physical hardware. The simulation, conducted on Tinkercad, allows for efficient prototyping and debugging of motion-sensitive circuits. The successful demonstration confirms that the simulated HIGH pulse effectively mimics motion detection, enabling verification of connected components' responses.

Uploaded by

mishraspam5
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 3

REPORT

ASSIGNMENT-2
GENERATION OF PIR PULSE SIGNAL
Aim: To simulate a PIR (Passive Infrared) sensor output by
generating a HIGH pulse using an Arduino, in order to test and verify
motion detection response systems without using an actual PIR sensor
Theory:
A Passive Infrared (PIR) sensor is commonly used in motion
detection systems. It detects infrared radiation emitted by warm
objects (like humans or animals) within its range. When motion is
detected, the PIR sensor outputs a HIGH signal; otherwise, it remains
LOW. These sensors are widely used in applications like security
systems, automatic lighting, and home automation.
In this experiment, instead of using an actual PIR sensor, we simulate
its output using an Arduino microcontroller on Tinkercad, a browser-
based circuit simulator. The simulation involves generating a digital
HIGH pulse on a specific pin to mimic the behavior of a PIR sensor
during motion detection. This HIGH pulse represents the moment
when the PIR sensor would normally detect motion and activate
connected devices like LEDs or buzzers.
The purpose of this simulation is to test and verify the functioning of
systems that respond to PIR sensor signals without needing the
physical sensor. By doing so, developers and students can prototype
and debug motion-sensitive circuits efficiently in a virtual
environment.
This technique demonstrates how digital signals can be controlled in
software to simulate real-world sensor behavior, making it easier to
test response logic, component interactions, and timing without
hardware constraints.
Code:
#define PIR_SENSOR 3 // PIR sensor is connected to digital pin 3
#define LED 12 // Onboard LED is connected to digital pin 13
void setup() {
pinMode(PIR_SENSOR, INPUT); // Set PIR sensor pin as input
pinMode(LED, OUTPUT); // Set LED pin as output
Serial.begin(9600); // Start serial communication at 9600
baud
}
void loop() {
int motionDetected = digitalRead(PIR_SENSOR); // Read the state
of the PIR sensor

if (motionDetected == HIGH) { // If motion is detected


digitalWrite(LED, HIGH); // Turn the LED on
Serial.println(1); // Send "1" to Serial Monitor/Plotter
} else {
digitalWrite(LED, LOW); // Turn the LED off
Serial.println(0); // Send "0" to Serial Monitor/Plotter
}

delay(100); // Short delay to stabilize sensor reading


}
Plot:

Project link:
https://www.tinkercad.com/things/98dZmcuJmF6-dazzling-esboo-
wluff/editel?returnTo=https%3A%2F%2Ffanyv88.com%3A443%2Fhttps%2Fwww.tinkercad.com%2Fdas
hboard
Conclusion:
The simulation carried out on Tinkercad successfully demonstrated
how an Arduino can be used to generate a HIGH pulse to simulate the
output of a PIR sensor. The virtual environment allowed us to test the
behavior of a motion detection system without the need for physical
hardware. The simulated HIGH pulse on the output pin effectively
imitated motion detection, enabling us to verify the response of
connected components (such as LEDs or other devices).

You might also like