Motion Activated Lamp Switch

Introduction: Motion Activated Lamp Switch

About: I am an Electronics Engineer and hobbyist......I'm interested in work in robotics and automation, I make projects using Arduino and other hardware. I love to share things which I learn.

Whenever we leave our desk or room, most of the time we forget to turn off the lights there. This causes loss of electricity and increment in your electricity bill. But what, if the lights get turnoff automatically, after you leave the room. Yes in this tutorial we are going to learn how to make a simple Motion Activated light switch, to save electricity and reduce your electricity bill.

Step 1:

To make this switch you need following components.

1- PIR sensor X 1

2- Transistor BC547 X 1

3- Resistors 1K, 220R X 2

4- 5volt relay X 1

5- piece of PCB X 1

6- Old cell phone charger/ 5volt SMPS X1

Look at the PIR sensor, two potentiometers are there. Left one is to adjust the sensitivity of sensor and right one is to adjust the output pulse time. Rotate left potentiometer towards right till end, this will sets high sensitivity of the sensor. And Rotate right potentiometer till center position, it will set the output pulse time of 2 to 3 minutes. Also there is a jumper for retriggering setting, put it on high position. Also there are 3 pins for interfacing the sensor with any microcontroller or any other circuit. First pin is ground, next is Output, and last one is Vcc.

Step 2: Circuit Description:

PIR sensor’s ground pin connected to the ground, Vcc connected to the +5volt power and output pin connected to the base of transistor through the resistor R1. Transistors collector connected to one end of the relay coil and another end of relay connected to the 5volt power. Diode d1 is connected across relay. One end of lamp is connected to the mains wire it can be live or neutral wire, other end of lamp is connected to NO contact of relay. Common contact of relay is connected to another wire of input mains supply. NC contact of relay will remains not connected. To provide power to the circuit I’m using this old cell phone charger circuit board or you can use any 5 volt SMPS unit.

When PIR sensor sense any motion in it’s vision angle, it generates high pulse on it’s output pin. As I connected this output pin to the transistors base, it goes in saturation mode, which causes the lower collector- emitter voltage, approximately 0 volts. Thus the transistor act as short circuit, resulting the current flow through relay coil. Due to this common contact of relay is shifted towards the NO contact, this action completes the ac circuit and turns on the lamp.

Step 3: Place Components and Solder

Take a piece of PCB put all components at suitable position on it and solder them according to circuit diagram. Solder charger wires positive one and negative one to the PCB. Connect wires for lamp and for input mains supply as shown. In my case yellow wires are for lamp and black wires are for input AC mains supply. Put this whole circuit inside of a box and close it. I make this box from cardboard, you can use any suitable box as enclosure. And all set’s

Fix it on such position that
sensor can look you. Connect output wires to lamp and input wires to mains supply, while connecting it with mains make sure that mains supply is turn off.

Since it runs on 220 volt ac Be careful while handling this circuit, mishandling of it, can gives you heavy electric shock also can lead to fatal injuries.

Hope you find this useful. if yes, like it, share it, comment your doubt. For more such projects, follow me! Support my channel on YouTube.

Thank you!


Follow My Facebook Page

Be the First to Share


    • The 1000th Contest

      The 1000th Contest
    • Battery Powered Contest

      Battery Powered Contest
    • Hand Tools Only Challenge

      Hand Tools Only Challenge