Voltage Sensor Proteus Library ((better)) Direct
Check the "Reference Voltage" in your code. Proteus defaults to 5V; if your MCU is set to 3.3V, your math will be off.
Most standard voltage sensor modules used in simulation (like the voltage sensor proteus library
Ensure your resistor values won't fry your virtual MCU. Check the "Reference Voltage" in your code
No filtering capacitor in the sensor output. Fix: Add a 10µF capacitor from sensor output to ground inside your library design. voltage sensor proteus library