voltage sensor unstable in my code

Hello Tom

I am sending a value through the pwm port of the bridge and set something around 1v and would like to display this value on a lcd screen, like a multimeter, but when i try to read through the sensor i can not but by my multimeter it works.