Try changing the ADC_CLOCK to 2 or 3.
FOSC/8 is too fast for 20mhz.
Datasheet says max of 5mhz OSC with FOSC/8.
FOSC/32 (ADC_CLOCK 2) should work at 20Mhz.
But, FRC (ADC_CLOCK 3) will work at any OSC.
HTH,
Try changing the ADC_CLOCK to 2 or 3.
FOSC/8 is too fast for 20mhz.
Datasheet says max of 5mhz OSC with FOSC/8.
FOSC/32 (ADC_CLOCK 2) should work at 20Mhz.
But, FRC (ADC_CLOCK 3) will work at any OSC.
HTH,
DT
That was the ticket set ADC_CLOCK 3
set vref to 2.55
lm34 .734
debug states 73 degrees
Thanks for all of your help I have been fighting with this for a bit and it was something as simple as that.
Bookmarks