Night Light

About: I live in Pakistan . I am 16 year old and I am passionate about electronics since my childhood. I have a hobby to design and implement science projects involving electronics and I am working on instructables...

Nightlight is a very simple project for beginners. It is set of lights which will be light up when there is no light in the room.

Products you would need.





You can found all these products on amazon.

Step 1: Making a Led Strip

Make a LED strip. Just connect the leds in parallel connection and use long wire for connections. I have used four white LEDs and gave a distance of almost 1 foot between each LED. I have used thin wire to connect all the cathodes and anodes of all LEDs.

Step 2: Connections

The connections are simple.

  1. Positive terminal of LED strip to digital pin "12" of Arduino.
  2. "gnd" terminal of LED strip to "gnd" pin of Arduino.
  3. "gnd" terminal of sensor goes to "gnd" of Arduino.
  4. Positive terminal of sensor to 5v of Arduino.
  5. "do" pin of sensor to digital pin "11" of Arduino.
  6. 5v of adapter to "vin" pin of Arduino.
  7. "gnd" terminal of adapter to gnd of Arduino.

Step 3: Programing

Just plug your arduino with your computer and download "IDE SOFTWARE" of arduino. Then upload the code to arduino. The code is given below:

void setup() 
pinMode (12,OUTPUT);
pinMode (11,INPUT);
int buttonstate=0;

void loop()

Step 4: Ending

Just put every thing in a container. I used a project box. Make sure the LDR (Light Dependent Resistor) is out of the box so that light can reach it.



    • Optics Contest

      Optics Contest
    • Make it Glow Contest 2018

      Make it Glow Contest 2018
    • Plastics Contest

      Plastics Contest

    2 Discussions

    Nice idea for a night light. I like how it could look like fireflies in a jar. My kids would love to have something like this in their rooms.

    1 reply