Voltage measurement

For the algorithm of the MPPT controller, the input voltage and the output voltage at the solar module optimiser are required. These voltages are to be measured with a ADC, which is available as a peripheral as part of the microcontroller. The measurable voltage range of these ADC is 0V<Vadc<3.3V and is thus significantly smaller than the voltages of 0V<Vin/out<50V applied to the solar module optimiser. In order to be able to measure the larger voltages with the ADC, a voltage divider is dimensioned as shown in figure, which only passes on a fraction of the high voltage but with the correct ratio to the ADC. The voltage divider ratio between R1 and R2 determines this ratio so that the input voltage of Vin=50V corresponds to a measured voltage at the ADC of Vadc=2.9V. Some free space is built in here to have protection against overvoltages.

Voltage divider

image

The resistance values for R1 and R2 are calculated as follows:

  • A very high input impedance Z>100kΩ of the ADC is assumed according to the data sheet, so the voltage divider is calculated as unloaded.

  • The output voltage can thus be used directly according to:

    (1)Uout=UinR2R1+R2
  • To prevent the current across the resistors from becoming too large and generating unnecessary losses, R2=2.2kΩ is chosen.

  • For R1 (1) is transformed to:

    (2)R1=R2VinVoutVout=2.2kΩ50V2.9V2.9V=35.7kΩ
  • Resistors are selected from the E24 resistor series with R1=36kΩ and R2=2.2kΩ.


Copyright © 2023 Arne Christian Schmidt. Distributed by an CC BY-NC 4.0.