Arduino Controlling Multiple P.I.R Sensor on Same Bord

Introduction: Arduino Controlling Multiple P.I.R Sensor on Same Bord

About: Hye, I am Ajay. & it's all about Electronics and Programming.

Today I will tell you how to connect multiple PIR Sensors with single Arduino Bord

>here i have also used 4 channel relay module for some extra functionality.

ARDUINO + 4 Channel Relay Module + 4 PIR Sensor (OR You can used as many pin your arduino has )

Step 1: Hardware Required

Step 2: Hardware Connection

Arduino________________TO_____________________PIR SENSORS(PIR1,PIR2,PIR3,PIR4)

Arduino PIN 3........................................PIR1-output pin

Arduino PIN 4........................................PIR2-output pin

Arduino PIN 5........................................PIR3-output pin

Arduino PIN 6........................................PIR3-output pin

Arduino 5v..............................................PIR1,PIR2,PIR3,PIR4(VCC )//connect all Vcc pin of pir1, pir2 , pir3 , pir4

//to the Arduino 5 v

Arduino GND..........................................PIR1,PIR2,PIR3,PIR4(GND )

ARDUINO________________TO________________________REALY MODULE

Arduino PIN 9.................................................................IN1 RELAY

Arduino PIN 10.................................................................IN2 RELAY

Arduino PIN 11...............................................................IN3 RELAY

Arduino PIN 12................................................................IN4 RELAY

Arduino GND..................................................................Relay GND

Arduino Vin.....................................................................Relay VCC

12 v -2A Power Supply .................................................to...........................................Relay Model 12v Input &GND (Some Relay Module Does not have 12 v power input so you need a 12 v to 5 v converter ......or you can distribute power by yourself .

Step 3: Programming Part

Here Programming is most important part

while in this project I face lots of problem in programming only.

  • here i have used a Arduino internal pulled up resistor
  • I used (IF-Statement) Without else Statement for stability

If you face any problem do not forget to comment

Be the First to Share

    Recommendations

    • Laser Challenge

      Laser Challenge
    • 3D Printed Student Design Challenge

      3D Printed Student Design Challenge
    • Paint Challenge

      Paint Challenge

    6 Comments

    0
    kmutahi
    kmutahi

    20 days ago

    cant see code

    0
    muhammadhishaam583
    muhammadhishaam583

    Question 3 months ago on Step 3

    Hey I want to increase their time, and i don't want to add delay as it pause the program, also not from the PIR delay, is there any other option to increase their time?

    0
    hackplague
    hackplague

    Reply 4 months ago

    Code is in the end.

    0
    jivian111
    jivian111

    Question 1 year ago on Introduction

    How to add buzzer and gsm module for this

    0
    DRNFBN
    DRNFBN

    Answer 5 months ago

    Have you already known how? I also need it for my project