I'm not 100% sure but HIGH set 2 registers, tris and port. Who know what is happening when you try to set tris of ADCON0...
HIGH and LOW should be used only with PIN on uC.
You should look at disassembly to know what is going on.
I would try this:
ADCON0 = %11000001 ' Set RC clock and enable ADC
ADCON1 = %00001110 ' Set PORTA.0 to analog,left justify, rest digital
TRISA = %00000101 ' RA0:Analog input 0
adcon0.2=1 ' start conversion
while adcon0.2:wend ' wait to finish
level=adresh
Bookmarks