Arduino UNO Light-Activated LED Circuit with Photocell and Resistors
View and Edit Project In Cirkit Designer
Circuit Documentation
Summary
This circuit involves an Arduino UNO microcontroller, a red LED, a photocell (LDR), and two resistors. The circuit is designed to read the light intensity using the photocell and control the LED based on the light intensity.
Component List
Arduino UNO
- Description: A microcontroller board based on the ATmega328P.
- Pins: UNUSED, IOREF, Reset, 3.3V, 5V, GND, Vin, A0, A1, A2, A3, A4, A5, SCL, SDA, AREF, D13, D12, D11, D10, D9, D8, D7, D6, D5, D4, D3, D2, D1, D0
LED: Two Pin (red)
- Description: A red light-emitting diode.
- Pins: cathode, anode
Resistor (220 Ohms)
- Description: A resistor with a resistance of 220 Ohms.
- Pins: pin1, pin2
Resistor (10k Ohms)
- Description: A resistor with a resistance of 10k Ohms.
- Pins: pin1, pin2
Photocell (LDR)
- Description: A light-dependent resistor that changes its resistance based on the light intensity.
- Pins: pin 0, pin 1
Wiring Details
Arduino UNO
- 5V: Connected to pin1 of the 10k Ohms resistor.
- A0: Connected to pin2 of the 10k Ohms resistor and pin 0 of the Photocell (LDR).
- GND: Connected to pin 1 of the Photocell (LDR) and cathode of the LED.
- D2: Connected to pin2 of the 220 Ohms resistor.
LED: Two Pin (red)
- cathode: Connected to GND of the Arduino UNO and pin 1 of the Photocell (LDR).
- anode: Connected to pin1 of the 220 Ohms resistor.
Resistor (220 Ohms)
- pin1: Connected to anode of the LED.
- pin2: Connected to D2 of the Arduino UNO.
Resistor (10k Ohms)
- pin1: Connected to 5V of the Arduino UNO.
- pin2: Connected to A0 of the Arduino UNO and pin 0 of the Photocell (LDR).
Photocell (LDR)
- pin 0: Connected to pin2 of the 10k Ohms resistor and A0 of the Arduino UNO.
- pin 1: Connected to GND of the Arduino UNO and cathode of the LED.
Documented Code
Arduino UNO Code (sketch.ino)
void setup() {
// put your setup code here, to run once:
}
void loop() {
// put your main code here, to run repeatedly:
}
Additional Documentation (documentation.txt)
This documentation provides a comprehensive overview of the circuit, including a summary, detailed component list, wiring details, and the code used in the microcontroller.