Arduino UNO-Based LED Brightness Controller with Potentiometer
View and Edit Project In Cirkit Designer
Circuit Documentation
Summary
This circuit involves an Arduino UNO microcontroller, a potentiometer, a red LED, and a resistor. The potentiometer is used to provide an analog input to the Arduino, which can be read on pin A0. The LED is connected to a digital pin (D9) through a resistor to limit the current. The Arduino can control the LED based on the input from the potentiometer.
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
- Purpose in Circuit: Acts as the main controller, reading the potentiometer value and controlling the LED.
LED: Two Pin (red)
- Description: A red light-emitting diode.
- Pins: cathode, anode
- Purpose in Circuit: Provides visual feedback controlled by the Arduino.
Resistor
- Description: A 220 Ohm resistor.
- Pins: pin1, pin2
- Properties:
- Resistance: 220 Ohms
- Purpose in Circuit: Limits the current flowing through the LED to prevent damage.
Potentiometer
- Description: A variable resistor.
- Pins: GND, Output, VCC
- Purpose in Circuit: Provides an adjustable voltage to the Arduino's analog input.
Wiring Details
Arduino UNO
- 5V: Connected to VCC of the Potentiometer.
- GND: Connected to GND of the Potentiometer and cathode of the LED.
- A0: Connected to Output of the Potentiometer.
- D9: Connected to pin2 of the Resistor.
LED: Two Pin (red)
- cathode: Connected to GND of the Arduino.
- anode: Connected to pin1 of the Resistor.
Resistor
- pin1: Connected to anode of the LED.
- pin2: Connected to D9 of the Arduino.
Potentiometer
- VCC: Connected to 5V of the Arduino.
- Output: Connected to A0 of the Arduino.
- GND: Connected to GND of the Arduino 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:
}
This code is a basic template for the Arduino. The setup() function is where you initialize your settings, and the loop() function is where you place the main code that runs repeatedly. In this circuit, you would typically read the potentiometer value in the loop() function and use it to control the LED.
Additional Documentation (documentation.txt)
This file is currently empty and can be used to add further documentation or notes about the circuit and its operation.