I don't believe you are still using these PIC toys. :-) :-) :-) Yingdan wrote: > Hello, > > I am using VREF+ and AVss for a potentiometer. Below is my setting: > > status_rp = 01 -- select bank 1 > CVRCON = 0b_1110_0110 > ANSEL = 0b_0001_1001 > ADCON1 = 0b_0010_0000 -- VREF+/AVSS > status_rp = 00 -- select bank 0 > > The VREF+ pin gives ~1.2v and I can get the reading 0 - 255 in the range of 0 - ~1.2v. The problem is the reading is unstable. When I rotate the shaft from high to low, and low to high, I got different readings for a specific position. From high to low, I got a relative bigger reading and from low to high, I got a much smaller reading for the similar position. > > I have no idea how to fix the problem. Can anyone help to take a look at my CVRCON and ADCON1 registers since I am not confident with them, or offer any help about what might be wrong? > > Your help is highly appreciated, > Yingdan >
Message
Re: [AVR-Chat] 16f88 vref problem
2009-08-05 by enkitec@gmail.com
Attachments
- No local attachments were found for this message.