Sumanth Mi MPC Lab
Sumanth Mi MPC Lab
CG,BILASPUR
SUBMITTED BY :
P . Sumanth
SUBMITTED TO: 22030144
RAJIV DEY B.Tech (ECE)5th Sem
Objective
Components Used
Solar Panel
A solar panel generates DC electricity by converting
solar energy into electrical energy. The power output of
the panel depends on various factors such as the
intensity of sunlight, the angle of incidence, and the
efficiency of the solar cells.
Arduino Code
void setupADC() {
// Set the ADC prescaler and enable ADC
ADMUX = 0; // Set the input channel (A0 by
default)
ADCSRA |= (1 << ADEN); // Enable ADC
ADCSRA |= (1 << ADPS2) | (1 << ADPS1); // Set ADC
prescaler to 64
}
void loop() {
// Read the voltage sensor (pin A1)
uint16_t sensorValueVoltage =
readADC(SENSOR_PIN_VOLTAGE);
float voltage = (sensorValueVoltage * 5.0) / 1023.0; //
Convert to voltage
voltage *= 5; // Actual voltage reading in volts
Procedure
1. Assembly of Components:
- Connect the solar panel to the ACS712 and LM044L
sensors as per the circuit diagram.
- Attach the LCD display to the Arduino.
- Ensure that the Arduino Uno is connected to the
computer via USB for power and programming.
4. Data Collection:
- Monitor the readings displayed on the LCD display
and record the values for voltage, current, and power
under different light conditions (e.g., cloudy, sunny, or
overcast).
Result;