Welcome To Atul R’s Project Blog!

Light that only works in darkness when motion is detected

I recently saw a video from OneCircuit (@onecircuit-as (yt)) in my Subscriptions feed a few days back where he utilised a Padauk MCU and a Joule Thief to build a light that only works in darkness when motion is detected. He also built a fader into it for a nicer effect.

However, I thought to myself how hard it would be if I were to replicate the same utilising discreet components alone. And it was not too bad.

Final Circuit

I built a NOT GATE configuration for the LDR which gives a HIGH output when the INPUT is low. The LDR works such that its resistance increases as light falls. So, the current reduces. For accurate working, the LDR is in a resistor divider configuration.

The PIR sensor gives a 3.3V output when motion is detected. The time for which it stays HIGH and the sensitivity can be adjusted with the two potentiometers on the sensor. I have set it such that the output will be high for a short period and the sensititvity is high.

PIR Sensor without the lens.
PIR Sensor circuit.

The outputs of both are pushed into an AND gate which will only give a HIGH output when both inputs are high. However, I have had to take a slightly different approach to the gate because neither outputs are perfectly LOW. The updated circuit makes up for the same.

In the end, I have tied the OUTPUT of the gate to a transistor that acts as a switch which gives a really nice 5V output. For the fade effect, I have added a capacitor in parallel to the LED that will discharge through the LED providing a superfast Fade action.

When all of these parts are connected together, it leads to an amazing Motion detection light that only works in the dark. I have omitted the Solar circuitry and the recharging circuit since implementing its not as tough. However, this small challenge of trying pure transistors instead of a MCU was nice.

It must be noted that I replaced the LED with a 1N4007 diode so that 2 different lights will not be on.

When I checked the current draw of the circuit, when the light is detected and the PIR does not sense motion, it draws 0.86mA. When light is detected and the PIR detects motion, it draws 1.01mA. When light is not detected and PIR senses nothing, it draws 0.96mA. When the light is not detected and the PIR senses motion, it draws 18mA (Possibly because of the light driving circuit drawing some power). The video of me taking the readings is below. Feel free to make your own opinions and decisions.

The funny thing is that the Padauk chip probably costs less than all of these combined. However, it’s the fun the matters. 🙂

Hope you had fun having a look at this as much as I did troubleshooting and building it. I also suggest you subscribe to OneCircuit if you haven’t already. If you like such quirky projects, you will like his channel too. If you have any suggestions or queries, feel free to comment below!


Leave a Reply

Your email address will not be published. Required fields are marked *


©2015-2024 ESC crasci (By Atul Ravi A part of its ON group of companies)