PIR Night Light

Night light with motion sensing and RTC

Similar projects worth following
I'm building a night light for my hallway. The light switches are to far apart, so I'm installing a LED-stripe with a motion sensor. It should be only active at night time, so I will use a RTC module to make that happen.

This is my first project here on It's not very sophisticated, but I want to document it here nonetheless.

The basic idea is to have a night light in the hallway which is only turned on when somebody actually is in there. I want to use a PIR sensor for motion sensing and a LED strip as the light source. I don't want it to turn on the LEDs during the day so I want to use a RTC module for timekeeping.

  • 1 × RTC module based on DS1302
  • 1 × PIR sensor module
  • 1 × Arduino Uno
  • 1 × RGB LED strip
  • 1 × ULN2003 or MCP1416P transistor array to interface the LED strip

  • Schematic

    Markus04/18/2015 at 12:48 0 comments

    Just finished the schematic. It's pretty straight forward and nothing fancy. I also ordered a RTC module and a PIR sensor and have to wait for them to arrive. Seems like the hardest part will be the software.

    (I know, the sensor is huge. I was lazy and didn't want to edit the part.)

View project log

Enjoy this project?



Martin wrote 05/01/2017 at 08:27 point

OK, of course it depends. The place I needed the light was just at the door of the garden house. I needed an energy saving light to find the keyhole, which should go out when I leave and not drain the batteries of the solar power system. I have a RGBW LED strip there also, but not with PIR control. So for me PIR control is nice for illumination purposes, I don't want it for light effects.

You know that there are cheap (~8$) ESP8266 5 channel (RGB+W+WW) WiFi LED controllers on AliExpress? Which of course could be reflashed, if you want to do your own firmware. I don't have the SKU at hand, but it looks like a black plastic box (8*4*2,3cm) with green screw terminals, if you want to look for it.

  Are you sure? yes | no

Martin wrote 04/27/2017 at 09:51 point

The PIR sensor is probably one with a BISS001 chip in it and you can fit an LDR to it. Which is more usefull than an RTC in my opinion. Normally you want light, when it's dark, independant of the time. The ULN2003 is a darlington driver which has 1V of drop. Use MOSFETs instead. For iillumination  I would recommend a whte LED strip. Making white with RGB has very awkward looking color rendition as yellow is missing and it has only have the luminous efficiency (Lumen/Watt).

"Seems like the hardest part will be the software." true, therefore I avoid it where possible. For lighting applications the BISS001 in the sensor module has everything you need: PIR sensor signal processing, LDR interface and the timers

There was a similar project some weeks ago. The guy added an arduino just because he was not sure, if the module can handle delay times  of sufficient length (some minutes). Yes it does.

  Are you sure? yes | no

Markus wrote 05/01/2017 at 08:19 point

Hey Martin,

thanks for your input. The project is long finished (I was just too lazy to update it) but your suggestions are great.

I really didn't want to use a white LED strip, as I wanted to have the ability to dim the LEDs and change the light's colour.

Doing the project without an MCU would be a nice touch, but for the next iteration I plan to use a WS2812 strip (or something similar) with a Particle Photon to have Wi-Fi connectivity. So it's rather the opposite direction ;-)

  Are you sure? yes | no

Similar Projects

Does this project spark your interest?

Become a member to follow this project and never miss any updates