Это видео недоступно.
Сожалеем об этом.

Automatic Night Lamp using LDR | Tinkercad | Beginner Arduino Project 1

Поделиться
HTML-код
  • Опубликовано: 21 июн 2021
  • Hello and Welcome to Learn It Easily. In this video, you will learn to make Automatic Night Lamp Arduino Project Using LDR in Step by Step manner.
    ▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬
    Automatic Night Lamp Arduino Project Using LDR
    Requirements:
    1 x Mini Breadboard
    1 x Arduino UNO R3
    1 x LDR ( Photoresistor) Sensor
    2 x 1 kΩ resistors
    1 x Red LED
    Website Used:
    www.tinkercad.com
    ▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬
    I hope you enjoyed this tutorial. I'll see you in the next one.
    Thanks for watching it.
    #Arduino #programming #electronics #tutorials #projects #makerspace #coding #DIY #c++ #python #Robotics #Automation #IoT #CircuitDesign #Prototyping #sensors #english #best

Комментарии • 40

  • @learniteasily321
    @learniteasily321  Год назад +3

    You all can post your doubts here !!!
    I will definitely answer all your comments.

  • @corradobaggieri3346
    @corradobaggieri3346 5 месяцев назад +1

    thx man u really helpd me

    • @learniteasily321
      @learniteasily321  4 месяца назад +1

      You're welcome!!!
      Happy to hear it was useful.

  • @user-zi5zb6hk7e
    @user-zi5zb6hk7e 15 дней назад +1

    Hy sir
    Can i still add morning alarm to this project?

    • @learniteasily321
      @learniteasily321  15 дней назад +1

      Yes, you can add an alarm clock to this project.

  • @RealBeauty-iq7ql
    @RealBeauty-iq7ql Месяц назад +1

    Sir which software are you using to build cct. Please reply

    • @learniteasily321
      @learniteasily321  Месяц назад +1

      I am using this website:
      www.tinkercad.com/
      Also the design can be implemented in a real Arduino device. The website provides a virtual simulation environment for Arduino for free.

    • @RealBeauty-iq7ql
      @RealBeauty-iq7ql Месяц назад +1

      @@learniteasily321 thank you so much

  • @itszalleeya
    @itszalleeya 22 дня назад +1

    Sir, can you tell me the app that you used?

    • @learniteasily321
      @learniteasily321  22 дня назад +1

      Sure. I am using this website:
      www.tinkercad.com/
      Also the design can be implemented in a real Arduino device. The website provides a free virtual simulation environment for Arduino.

  • @qwerty0202
    @qwerty0202 Год назад +1

    Sir it should be if(c>500) then led low ... right? Led should turn on when its dark right?

    • @learniteasily321
      @learniteasily321  Год назад +2

      Actually when their will be dark, the resistance of LDR will increase. I googled the same and found this:
      When the light level decreases, the resistance of the LDR increases. As this resistance increases in relation to the other Resistor, which has a fixed resistance, it causes the voltage dropped across the LDR to also increase.
      So at night, value of c will increase because c stores resistance. I wrote in the code:
      if(c

    • @learniteasily321
      @learniteasily321  Год назад +1

      Tell me if you want to know anything more !!!

  • @muhdwalid7949
    @muhdwalid7949 Год назад +1

    sir, can I know what the function of "Serial.begin(9600);" and "Serial.println(c) ;" in the coding part. And also the 500 represent for what in this part "if(c

    • @muhdwalid7949
      @muhdwalid7949 Год назад

      hope you can reply ASAP, I need to explain it for my presentation on this project in next 2 weeks

    • @learniteasily321
      @learniteasily321  Год назад +3

      @@muhdwalid7949
      1. Serial.begin(9600) is used to start communication between board and photoresistor/LED. 9600 represents the speed of data to be sent. You can also change the value
      2. c = here we have stored the value of analogRead(A0) in c. analogRead will tell us the value of Voltage at A0. I am finding voltage of A0 because you can see the photoresistor/LDR is connected to A0 using red wire.
      3. Serial.println(C) = It is used to convert the voltage value you stored in previous step to human readable form. It converts to ASCII so that it can be compared in the next step.
      4. c

  • @iqrasejal9660
    @iqrasejal9660 2 месяца назад

    my led is switched on even in light
    please help
    i have to submit the project tomorrow

    • @learniteasily321
      @learniteasily321  2 месяца назад +1

      This is not possible. You have to make sure that all the connections are made correctly. The light only turns ON whenever there is dark. If you click on LDR, you will get a slider which can be moved to left or right. Moving to right means increasing brightness. If brightness is increased, LED turns OFF.
      Please verify all the connections from this circuit diagram:
      www.tinkercad.com/embed/kbwURvVLI0R?editbtn=1
      Also make sure you copied the exact code:
      drive.google.com/file/d/1wf7UQyFO9yLvidfwUr0pyKmcVwTLlvC6/view

  • @sai_vardhan536
    @sai_vardhan536 5 месяцев назад +1

    Sir how to add 3 to 4 leds in the circuit pls reply

    • @learniteasily321
      @learniteasily321  5 месяцев назад +1

      I have developed a modified code for you to add 4 leds into the circuit:
      void setup() {
      Serial.begin(9600);
      pinMode(7, OUTPUT);
      pinMode(8, OUTPUT); // Set pin 8 as output for LED 2
      pinMode(9, OUTPUT); // Set pin 9 as output for LED 3
      pinMode(10, OUTPUT); // Set pin 10 as output for LED 4
      }
      void loop() {
      int ldrValue = analogRead(A0);
      Serial.println(ldrValue);
      if (ldrValue < 500) {
      digitalWrite(7, LOW); // Turn off all LEDs
      digitalWrite(8, LOW);
      digitalWrite(9, LOW);
      digitalWrite(10, LOW);
      } else {
      digitalWrite(7, HIGH); // Turn on all LEDs
      digitalWrite(8, HIGH);
      digitalWrite(9, HIGH);
      digitalWrite(10, HIGH);
      }
      }
      For connecting the leds, you need to do this:
      Connect the long leg (the positive one) of each LED to a different digital pin. Pick pins 8, 9, 10, and so on. Attach a resistor before each LED's long leg to keep the current safe. Finally, connect the short leg (negative) of each LED to the ground on your breadboard.

    • @learniteasily321
      @learniteasily321  5 месяцев назад +1

      Tell me if you want to know anything more !!!

    • @sai_vardhan536
      @sai_vardhan536 5 месяцев назад +1

      Thank you sir ❤

  • @qwerty0202
    @qwerty0202 Год назад

    What does int c actually give the resistance or light intensity reading?
    For ldr when light falls on it resistance decreases right?

    • @learniteasily321
      @learniteasily321  Год назад +2

      int c = analogRead(A0);
      c is a variable which stores the resistance. You can also see the red wire is connected to LDR to AO whose value we are storing in c.
      And yes light falling is inversely proportional to resistance. In simple terms, If Light increases then resistance decreases and vice versa.
      When the light level decreases, the resistance of the LDR increases. As this resistance increases in relation to the other Resistor, which has a fixed resistance, it causes the voltage dropped across the LDR to also increase.
      When this voltage is large enough, it will cause the Transistor to turn on. The value of the fixed resistor will depend on the LDR used, the transistor used and the supply voltage.

    • @learniteasily321
      @learniteasily321  Год назад +2

      Tell me if you want to know anything more !!!

  • @srgplay4526
    @srgplay4526 Год назад

    Sir if it becomes dark it's resistance decreases and lamp turns on rigth but the resistance will again increase from the light of the lamp right? then how to overcome this?

    • @learniteasily321
      @learniteasily321  Год назад +3

      Actually when their will be dark, the resistance of LDR will increase. I googled the same and found this:
      When the light level decreases, the resistance of the LDR increases. As this resistance increases in relation to the other Resistor, which has a fixed resistance, it causes the voltage dropped across the LDR to also increase.
      When this voltage is large enough, it will cause the Transistor to turn on. The value of the fixed resistor will depend on the LDR used, the transistor used and the supply voltage.

    • @srgplay4526
      @srgplay4526 Год назад +1

      @@learniteasily321 thank you.

    • @learniteasily321
      @learniteasily321  Год назад +2

      Tell me if you want to know anything more !!!

    • @srgplay4526
      @srgplay4526 Год назад

      @@learniteasily321 Sure sir thanks.

    • @srgplay4526
      @srgplay4526 Год назад

      @@learniteasily321 Actually I just had some toggling issue like when It is dark the light tuned on and the LDR took the input and the light was again turned off, so light was getting on and off within short period of time, so I just added timer for taking the readings and it pretty much solved the issue.

  • @user-vr9fq5oq5r
    @user-vr9fq5oq5r Год назад

    how can we do the same thing but with 2 ldr with gm90?

    • @learniteasily321
      @learniteasily321  Год назад +2

      I think there is no need to use 2 ldrs while designing automatic night lamp.
      Also I have never heard of gm90. Maybe you wanted to write "SG90" which is SG90 Servo Motor?

    • @learniteasily321
      @learniteasily321  Год назад +2

      Tell me if you want to know anything more !!!

  • @MR_SHIVA_-ml2vj
    @MR_SHIVA_-ml2vj Год назад

    Sir can u plz tell the code how to set timer to led so that it should after certain time

    • @learniteasily321
      @learniteasily321  Год назад +3

      These might help you
      create.arduino.cc/projecthub/user16726/control-your-lights-with-arduino-and-a-relay-3dcfc0
      create.arduino.cc/projecthub/nexsus/blinking-of-two-leds-with-the-delay-of-0-5-sec-19b76d
      forum.arduino.cc/t/switch-on-a-led-for-5-sec-and-turn-off/112548/5

    • @MR_SHIVA_-ml2vj
      @MR_SHIVA_-ml2vj Год назад +1

      @@learniteasily321 Thank you brooo