- what are "different values" of the output? differing by how much from reading to reading?
- are you sure your input is not noisy?
- added a bypass cap for the reference voltage?
On the Kit-043 a bypass cap is already connected. Resolution of ADC is 11 bits, not 12 when VSS is selected for negative input. When you select Internal Vref range is 0..2048V @12 bits resolution.
@BOb you are right but in my case some times i got adc count 0 or some time random value for constant voltage.
I tested your project at my end and I am getting the right values. I checked in debug mode in the variable 'ouput' you have defined I am getting the correct output. I suspect something is wrong with your hardware or the input you are giving. Can you make sure that you are giving the right input value.
Sounds like a "loose" wire or a bad potentiometer contact.