Arduino-powered system that maximizes solar energy by dynamically tracking the sun using LDR sensors and servo motors.
MIT License
This project is an implementation of a dual-axis solar tracker using an Arduino. The tracker continuously adjusts the position of a solar panel in two axes (horizontal and vertical) to ensure optimal alignment with the sun. This maximizes the panel's exposure to sunlight, thereby increasing its efficiency.
The dual-axis solar tracker uses Light Dependent Resistors (LDRs) to detect the intensity of sunlight in different directions. Based on these readings, the system controls two servos to adjust the position of the solar panel, ensuring it always faces the direction of maximum sunlight.
Additionally, the system monitors the voltage, current, and power output of the solar panel, displaying this information on an LCD screen and logging it via the Arduino's serial interface.
The project code is written in Arduino C/C++ and utilizes the following libraries:
Wire.h
: For I2C communication (if needed for additional components).LiquidCrystal.h
: For controlling the LCD display.Servo.h
: For controlling the horizontal and vertical servos.Servo Control:
servoh
and servov
: Variables that store the current positions of the horizontal and vertical servos.servohLimitHigh/Low
and servovLimitHigh/Low
: Set the maximum and minimum angles the servos can move to, preventing over-rotation.LDR Connections:
ldrlt
, ldrrt
, ldrld
, ldrrd
: Analog pins connected to LDRs that measure light intensity in the four quadrants around the solar panel.LCD Display:
Hardware Setup:
Code Upload:
Calibration:
servohLimitHigh/Low
and servovLimitHigh/Low
) to match the physical constraints of your setup.loop()
function reads the light intensity values from the LDRs and calculates the necessary adjustments for the servos.Power Up:
Monitor Performance:
Adjustments:
Feel free to reach out if you have any questions or suggestions for improvements!