Varun Sontakke
Published © GPL3+

Plantoolighter

Plantoolighter is a system which redirect sunlight to the plants which are adjacent to garden wall and unable to get proper sunlight.

BeginnerFull instructions provided9 hours2,769
Plantoolighter

Things used in this project

Hardware components

Arduino UNO
Arduino UNO
×1
LDR, 5 Mohm
LDR, 5 Mohm
×1
Resistor 100k ohm
Resistor 100k ohm
×1
Power Bank
×1
SG90 Micro-servo motor
SG90 Micro-servo motor
×1
Mirror
×1
cardboard 20x20 cm
×1
Aluminium Sheet Strips
×1
Jumper wires (generic)
Jumper wires (generic)
×1

Software apps and online services

Arduino IDE
Arduino IDE

Hand tools and fabrication machines

Drill, Screwdriver
Drill, Screwdriver
Tape, Masking
Tape, Masking

Story

Read more

Schematics

Connection Diagram

Code

Plantolighter Code

Arduino
int ldr_pin = A0;
int ldr_val = 0;
int temp=0;
#include <Servo.h>
Servo myservo;
int pos = 0;
void setup() {
  Serial.begin(9600);
  pinMode(ldr_pin,INPUT);
  myservo.attach(9);
  myservo.write(pos);
}
void loop() {
  ldr_val = analogRead(ldr_pin);
  temp=map(ldr_val,0,1023,0,100);
  Serial.println(temp);
  if (temp >= 95){
    for (pos = 0; pos <= 45; pos += 1) { 
    myservo.write(pos);             
    delay(100);                      
  }
  for (pos = 45; pos >= 0; pos -= 1) { 
    myservo.write(pos);              
    delay(100);                      
  }
  }
 }

Credits

Varun Sontakke

Varun Sontakke

1 project • 2 followers

Comments