Same voltage, 1 directly from external PSU and 1 through voltage divider, give 2 different ADC readings
Hey!
I am having trouble with my ADC readings on my STM32G071RB.
I am currently using 2 ACD-s for testing. VREF is set to 2.048 V. On 1 ADC, I give the input of 1.65 V directly from an external PSU. On the other ADC, I use the boards 3.3 V and run it through a voltage divider to also get 1.65 V.
When I measure the voltage with a multimeter, the voltage on both cables going into the MCU is about 1.65 V . The result from the ADC that measures input from the PSU gives me a reading in the range of ~3360 which calculates to about 1.68 V. But the result from the ADC that measures the input from the voltage divider gives me a reading of about ~2890 which calculates to about 1.45 V.
Where could this difference come from if the actual voltage going to the ADC pin is the same? Tried swapping the ADCs, calibration on/off but the result is the same.