photoresistor using arduino

Introduction

In this blog we gonna talk about photoresistor. photoresistor also known as light dependent resistor (LDR)
LDR are light sensitive devices most often used to indicate the presence or absence of light, or to measure the light intensity. The idea of photoresistor developed in 1873 by willoughby smith .photoresistor are made up of high resistance semiconductor such as silicon or germanium. They are also made of other materials such as cadmium sulphide or cadmium selenide. when the ldr sensor is exposed to light , the resistance drop dramatically ,even down to few ohms, depending on the light-intensity. 

Things Required

  • Arduino
  • Breadboard
  • jumper wire
  • ldr or photoresistor sensor
CODE:

// the setup routine runs once when you press reset:
void setup() {
  // initialize serial communication at 9600 bits per second:
  Serial.begin(9600);
}

// the loop routine runs over and over again forever:
void loop() {
  // read the input on analog pin 0:
  int sensorValue = analogRead(A0);
  // print out the value you read:
  Serial.println(sensorValue);
  delay(1);        // delay in between reads for stability
}



Comments

Popular Posts