I've set up a PIC16F77 to repeatedly sample an analogue DC signal. The problem is when I apply a 0v signal, the ADC does not read as
0x00. It's an 8-bit ADC and at 0v reads about
0x06. (I'm using the Vref pin for scaling, and have set it to 2.55V).
What I have done to try to fix the issue:
- A well regulated 5v power supply
- Smoothing capacitors on the Vref pin
- Smoothing capacitors on the power supply
- Tied all other analogue inputs to ground
- Increased the acquisition delay to about 40us (recommended is 16us)
- The signal to the analogue inputs is in the order of a few ohms - the recommended is less than 10k
The datasheet says +/- 1LSB should be possible, and I'm mystified. Can I expect better from this PIC? And how can it be achieved?