Automatic Street Lights using PIR Sensor code and circuit diagram

(Last Updated On: July 17, 2019)

 

street lights

Automatic Street Lights- In today’s tutorial, you will learn how to make an automatic street lights control system using only a PIR sensor. PIR Sensor is one of the most commonly used sensors for motion detection. You can also use a laser-based car detection system. But I will be using a PIR sensor. This is the second part of the car parking system.

The first part was based on the car parking slots monitoring system using infrared sensors and a computer application designed in vb.net.  “Click here to watch this tutorial

A few months back I uploaded two tutorials on the PIR sensor. In the first tutorial, I covered all the basics, including the pinouts, the purpose of the variable resistors, and how to use a PIR sensor with Arduino.

While in the second tutorial I used this PIR sensor with the GSM SIM900A module and designed a security system. The links are given in the description, if in case you want to watch these tutorials.

In this tutorial, we are not using Arduino or any other microcontroller. We will only be using a PIR sensor to control the street lights. This tutorial covers

  1. making
  2. Circuit explanation
  3. Interfacing and finally
  4. Testing


The components and tools used in this project can be purchased from Amazon, the components Purchase links are given below:

Pir motion sensor: https://amzn.to/2KWErNd
Super bright LEDs: https://amzn.to/2BVmtax
5v 2A adaptor: https://amzn.to/2GsNfcw
2n2222 NPN transistors: https://amzn.to/2EmXsIb
10k Resistor: https://amzn.to/2KTd6OW
lm7805 Voltage Regulator: https://amzn.to/2IZEl5x
330-ohm resistors pack: https://amzn.to/2NtlAeh
female DC power jack socket: https://amzn.to/2KEo1gt
470 uf capacitors: https://amzn.to/2xDCOzf
5×7 cm Vero board: https://amzn.to/2OHGbvn
female headers: https://amzn.to/2zqmtiJ
connection wires: https://amzn.to/2DpBuW7
Super Starter kit for Beginners: https://amzn.to/2KJvmKG
Jumper Wires: https://amzn.to/2KMoVXs
Bread Board: https://amzn.to/2MS4q8X
12v Adaptor: https://amzn.to/2Ntr6h1
PCB plate: https://amzn.to/2IUwpCt
Variable Supply: https://amzn.to/2MT4Qfj
Digital Multimeter: https://amzn.to/2Nvft9i
Vero Board / stripboard: https://amzn.to/2MTf9jD
Soldering iron kit: “best” You guys should purchase this: https://amzn.to/2zfoNuJ
Solder wire: https://amzn.to/2ufUMWf
Wire Stripper: https://amzn.to/2KOqxfU
wirecutter: https://amzn.to/2ucIq14
PCB small portable drill machine: https://amzn.to/2Nu62XF

Circuit Diagram of the Automatic Street Lights control sys :

street lights

This is the regulated 5v power supply based on the LM7805 voltage regulator. This power supply will be used to power up the PIR Sensor Module. J1 is the dc female power jack. A 10uf capacitor is connected at the input side of the 7805 voltage regulator. Another 10uf capacitor is connected at the output side of the voltage regulator. A 330-ohm resistor is connected in series with a 2.5v led. This is a current limiting resistor.


A wire from the output of the voltage regulator is connected with the Vcc pin of the PIR sensor module, and also make sure you connect the ground of voltage regulator with the ground of the PIR Sensor module. The Out pin of the PIR sensor is connected with the base of the 2n2222 NPN transistor through a 10k resistor. the emitter of the 2n2222 NPN transistor is connected with the ground while the collector side is connected with one side of the relay coil and the relay coil other side is connected with the 12 volts.

This is another 5v regulated power supply the same as explained. This 5 volt will be used to power up the white color LEDs. This 5 volt is given to the LEDs through this relay. 330-ohm resistors are connected with the anode sides of all the Leds. While the cathode sides of all the LEDs are connected with the ground.  When the PIR sensor detects any motion the relay is turned on, so the common pin of the relay will be connected with the normally open pin, which connects 5 volts with the anode side of the LEDs, and so the led’s will turned On.

The relay driver circuit simply consists of the 2n2222 NPN transistor and a 10k resistor.


Interfacing of street lights :

For the complete Model designing and making watch video Tutorial given at the end of this Article.

Watch Video Tutorial:

 

PIR related Project:

How to make Motion Sensor light Homemade | PIR light sensor | Automatic light switch

 

GSM Alarm System Using Arduino and a PIR Sensor

 

Arduino Image processing CCTV camera system using VB.net

 

 

 

Recommended For You

About the Author: Engr Fahad

My name is Shahzada Fahad and I am an Electrical Engineer. I have been doing Job in UAE as a site engineer in an Electrical Construction Company. Currently, I am running my own YouTube channel "Electronic Clinic", and managing this Website. My Hobbies are * Watching Movies * Music * Martial Arts * Photography * Travelling * Make Sketches and so on...

Leave a Reply

Close