Arduino UNO Smart Light with BH1750 and Rotary Potentiometer
View and Edit Project In Cirkit Designer
Circuit Documentation
Summary
This circuit involves an Arduino UNO microcontroller interfacing with various components including resistors, a rotary potentiometer, a photocell (LDR), an LED, and a BH1750 light sensor. The circuit is designed to read analog values from the potentiometer and the photocell, control an LED, and communicate with the BH1750 sensor over I2C.
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
Resistor (200 Ohms)
- Description: A resistor with a resistance of 200 Ohms.
- Pins: pin1, pin2
Rotary Potentiometer
- Description: A variable resistor with a total resistance of 10,000 Ohms.
- Pins: leg1, wiper, leg2
Photocell (LDR)
- Description: A light-dependent resistor.
- Pins: pin 0, pin 1
Resistor (8200 Ohms)
- Description: A resistor with a resistance of 8200 Ohms.
- Pins: pin1, pin2
LED: Two Pin (red)
- Description: A red LED.
- Pins: cathode, anode
BH1750
- Description: A digital light sensor.
- Pins: VCC, GND, SCL, SDA, ADDR
Wiring Details
Arduino UNO
- D10: Connected to the anode of the LED.
- 5V: Connected to leg1 of the rotary potentiometer, pin 0 of the photocell, and VCC of the BH1750.
- GND: Connected to leg2 of the rotary potentiometer, pin1 of the 200 Ohms resistor, pin1 of the 8200 Ohms resistor, and GND of the BH1750.
- A0: Connected to the wiper of the rotary potentiometer.
- A1: Connected to pin 1 of the photocell.
- A4: Connected to SDA of the BH1750.
- A5: Connected to SCL of the BH1750.
Resistor (200 Ohms)
- pin1: Connected to leg2 of the rotary potentiometer and GND of the Arduino UNO.
- pin2: Connected to the cathode of the LED.
Rotary Potentiometer
- leg1: Connected to 5V of the Arduino UNO.
- wiper: Connected to A0 of the Arduino UNO.
- leg2: Connected to pin1 of the 200 Ohms resistor and GND of the Arduino UNO.
Photocell (LDR)
- pin 0: Connected to 5V of the Arduino UNO.
- pin 1: Connected to pin2 of the 8200 Ohms resistor and A1 of the Arduino UNO.
Resistor (8200 Ohms)
- pin1: Connected to leg2 of the rotary potentiometer and GND of the Arduino UNO.
- pin2: Connected to pin 1 of the photocell and A1 of the Arduino UNO.
LED: Two Pin (red)
- anode: Connected to D10 of the Arduino UNO.
- cathode: Connected to pin2 of the 200 Ohms resistor.
BH1750
- VCC: Connected to 5V of the Arduino UNO.
- GND: Connected to GND of the Arduino UNO.
- SDA: Connected to A4 of the Arduino UNO.
- SCL: Connected to A5 of the Arduino UNO.
Documented Code
sketch.ino
void setup() {
// put your setup code here, to run once:
}
void loop() {
// put your main code here, to run repeatedly:
}
documentation.txt