1
\$\begingroup\$

I am currently in the middle of migrating a project from PIC16LF1947 to a PIC18F87K22 as I am in need of extra GPIOS and the PIC18 part fits the bill. There is one thing that is nagging me right now is the internal ADC reference of the PIC. The PIC16LF has an internal bandgap reference. I tried to post a screen shot of the datasheet snipped but looks like I need more reputation to do that. REf- PIC16LF1946/47 page 4 Voltage reference module:.

It is nice in the sense that it lets you program the internal reference in increments of 1.024V. Now, the PIC18F has an internal bandgap reference too, but the datasheet is not divulging too much information. I spoke to the MCHP tech support and it was futile. At this point I would like to know how to set the internal BGR for my ADC conversions.

\$\endgroup\$
0
\$\begingroup\$

Your new PIC doesn't have the same set of voltage reference options which the old one does.
A quick scan through the ADC section of the new PIC's datasheet shows me that your reference options are:

REGISTER 23-2: ADCON1: A/D CONTROL REGISTER 1
VCFG<1:0>: A/D VREF+ Configuration bits
11 = Internal VREF+ (4.096V)
10 = Internal VREF+ (2.048V)
01 = External VREF+
00 = AVDD

So no 1.024V option.

\$\endgroup\$
  • \$\begingroup\$ thanks. Reg23 ADCON1 bits 4&5. The FVR on the PIC16 had a range over temperature 05 -8% to +6%. Wonder how stable this internal reference is on the PIC18. \$\endgroup\$ – ultrasounder Apr 21 '15 at 18:02
  • \$\begingroup\$ I wonder too... While the specs for the Comparator Voltage Reference module are easy to find, any detail on the ADC's bandgap reference seem to be either missing or well hidden... Good job Microchip. \$\endgroup\$ – brhans Apr 21 '15 at 18:24
  • \$\begingroup\$ @brhans Down in "Electrical Characteristics"on page 500 of the family datasheet, I see for -40 to 125C the specifications of 1/2 LSB accuracy. \$\endgroup\$ – justing Apr 21 '15 at 20:56
  • \$\begingroup\$ @justing That's the Comparator's 32-step resistor-divider ref which I already referred to, not the bandgap ref which is fed to the ADC. \$\endgroup\$ – brhans Apr 21 '15 at 20:59
  • \$\begingroup\$ @brhans My bad, I agree with you. Had no luck finding specifications for the references either. \$\endgroup\$ – justing Apr 25 '15 at 0:49

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.