Seeing the Light: The Arduino Photoresistor
A Photoresistor, also known as a Light Dependent Resistor (LDR), is one of the most common sensors in the Arduino world. It allows your projects to "see" and react to light levels, much like an automatic night light or a solar tracker.
![images/projects/expanded/images/projects/expanded/photoresistor_basic_circuit_1772704138840.png)
How It Works
The LDR is a variable resistor. When light shines on its surface, its resistance decreases. When it's dark, its resistance increases significantly. By using a voltage divider circuit (usually with a 10k-ohm resistor), the Arduino can read a changing analog voltage that corresponds to the light intensity.
Project Features
- Sensitive Detection: Detects everything from pitch black to bright flashlight beams.
- Dynamic Response: The Arduino can fade an LED proportionately to the light level (using PWM) or simply toggle it at a specific threshold.
- Data Logging: You can view the raw light values (0-1023) on the Serial Monitor to calibrate your project.
![images/projects/expanded/images/projects/expanded/ldr_sensor_graph_display_1772704482482.png)
Components List
- Arduino Uno/Nano: The processor.
- Photoresistor (LDR): The light sensor.
- 10k-ohm Resistor: For the voltage divider.
- LED and 220-ohm Resistor: To act as the output.
- Breadboard and Jumper Wires: For easy assembly.
This fundamental project is the gateway to building sophisticated systems like automated blinds, light-seeking robots, or smart streetlights.