Hi Sven, Thanks for your response. I will take a look at the newest datasheet and errata to see about those problems. Off hand, I don't know which revision I am using,and the chip isn't here as I type so I can't look. I tried even a 100K resistor across the xtal pins and all it did was slightly decrease the overall amplitude of the oscillation, it didn't alter the characteristics during sleep. Thanks for your help, Sean At 12:32 PM 5/30/99 +0200, you wrote: >Hi > >There is are are a few errors on the older 16C71 silicons that you might have bumped into. One error is the RA4 not operating properly, and one is the sleep mode (I don't rercall the other errors, and am too lazy to look it up for you; sorry). > >If you use an old version (that is not the 16C71A or 16C711), you need to stop the oscillator from sponaneous actions by putting 10 Meg across the XTAL-pins. Or much better: use a 16C711 ! As I remember, this would apply in RC-mode - but I suggest you try it anyway. > >Hope I contributed > > >Sven >-----Ursprungligt meddelande----- >FrŒn: Sean Breheny >Till: PICLIST@MITVMA.MIT.EDU >Datum: den 30 maj 1999 07:19 >€mne: Sleep > > >>Hi All, >> >>Thanks in advance for any help you can give me with a problem I am having: >> >>I am trying to use the ADC on a 16C71 and I am getting an error of as much >>as 2 LSB (when the datasheet says +/- 1 LSB max). I am measuring the >>voltage directly between the ADC pin and the PIC's Vss pin and the output >>code seems to be off. I am waiting about 800 uS from the time I enable the >>ADC until I begin the conversion, and the output impedance of my source is >>2.2K >> >>Now as to the reason why this is entitled "SLEEP": AS recommended in the >>datasheet, I am placing the pic in sleep mode during the ADC,using the >>internal RC oscillator for the ADC. My normal oscillator element is a 4MHz >>xtal with 20 pF load caps. When I observe the pic's oscillator pins with my >>scope (about 20pF loading with my x10 probe),instead of seeing the >>oscillator exponentially decay to zero during sleep (as I would expect), I >>see the DC level increase slightly and the the amplitude remain constant. >>This region of the waveform is about 50 uS long after which there is a >>small glitch and then the DC level returns back to the same as before >>sleep. Is this normal for sleep mode? I thought the whole idea was to >>disable the oscillator (and other internal PIC circuits) to prevent digital >>switching noise! Perhaps the xtal's Q is so high that it won't even begin >>to decay in only 50uS? (This is my guess, since 50uS is only a few 100 >>cycles at 4MHz,BUT if this is the case,are we loosing some of the benefit >>of sleep mode?) >> >>I know that 2 LSB error isn't that bad,but in my case,it is really annoying >>because the actual ADC count gets multiplied by 7 before being displayed on >>an LCD display. SO, if I calibrate it to be correct in one portion of the >>scale, I get as much as 14 or sometimes even 21 counts (after being >>multiplied by 7). Yeah, I know,an 8 bit ADC on a ucontroller is not a >>really precision device and multiplying by 7 is making things worse,but I >>think I could live with 1 LSB of error more easily. MORE IMPORTANTLY, I >>want to make sure I am not doing something dumb with the sleep mode. >> >>Thanks, >> >>Sean >> >> >>| >>| Sean Breheny >>| Amateur Radio Callsign: KA3YXM >>| Electrical Engineering Student >>\--------------=---------------- >>Save lives, please look at http://www.all.org >>Personal page: http://www.people.cornell.edu/pages/shb7 >>mailto:shb7@cornell.edu ICQ #: 3329174 >>________________________________________________________ >>NetZero - We believe in a FREE Internet. Shouldn't you? >>Get your FREE Internet Access and Email at >>http://www.netzero.net/download/index.html >> > | | Sean Breheny | Amateur Radio Callsign: KA3YXM | Electrical Engineering Student \--------------=---------------- Save lives, please look at http://www.all.org Personal page: http://www.people.cornell.edu/pages/shb7 mailto:shb7@cornell.edu ICQ #: 3329174 ________________________________________________________ NetZero - We believe in a FREE Internet. Shouldn't you? Get your FREE Internet Access and Email at http://www.netzero.net/download/index.html