element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Avnet & Tria Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • About Us
    About the element14 Community
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Japan
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      •  Vietnam
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
Embedded and Microcontrollers
  • Technologies
  • More
Embedded and Microcontrollers
Pic Microcontrollers Forum Wrong operation when using internally generated negative voltage reference for A/D converter on PIC16F18877
  • Blog
  • Forum
  • Documents
  • Quiz
  • Polls
  • Files
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Join Embedded and Microcontrollers to participate - click to join for free!
Actions
  • Share
  • More
  • Cancel
Forum Thread Details
  • State Not Answered
  • Replies 5 replies
  • Subscribers 205 subscribers
  • Views 1263 views
  • Users 0 members are here
  • pic16
  • reference
  • adc
Related

Wrong operation when using internally generated negative voltage reference for A/D converter on PIC16F18877

Mila_G
Mila_G over 2 years ago

Hello,

please can you help me with the wrong operation when using internally generated negative voltage reference for A/D converter on PIC16F18877?

I would like to use ADC with references 0.416 V and Vdd (5 V).
It works perfectly when I connect 0.416 V to the Vref- pin (RA2) from an external source.

Then I generate 0.416 V on RA2 from FVR and D/A converter as follows:
  FVRCON = 0x84;
  DAC1CON0 = 0xA8;
  DAC1CON1 = 0x0D;
The DAC also works perfectly and there is about 0.416 V on the Vref- pin (RA2).

But now ADC works only if the negative reference is Gnd. If I switch this from Gnd to Vref- (just by changing ADREF from 0 to 0x10), a failure occurs. The voltage on the RA2 pin changes to 2.1 V (and of course the A/D gives bad results).

Workaround attempts:
- 0.416 V output from DAC to RB7, directly conneted to RA2 via a wire, works just as badly as above.
- After interconnecting via an op amp voltage follower instead of the wire, the A/D starts to work properly.

I assumed the PIC analog circuits were designed for internal connections from the VRef- pin, without any external workaround. Please, advise.

Many thanks.

Mila.

  • Sign in to reply
  • Cancel

Top Replies

  • shabaz
    shabaz over 2 years ago in reply to Mila_G +1
    You explicitly mention in your workaround attempts: Workaround attempts: - 0.416 V output from DAC to RB7, directly conneted to RA2 via a wire, works just as badly as above. I'm merely explaining the…
Parents
  • James123
    0 James123 over 1 year ago

    ADC input signals are really sensitive to source impedance, and it's generally recommended to keep the maximum impedance of your analog signal source around 10 kΩ. If the source impedance is too high, it can lead to longer sampling times, which may mess up your conversion results. This could be one of the issues you're facing when using an internally generated negative voltage reference.
    To avoid problems, make sure your circuit design doesn't introduce extra impedance that could affect the ADC's performance. For more detailed information, check out the PIC16F18877 datasheet, especially the sections on ADC configuration and operation.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
Reply
  • James123
    0 James123 over 1 year ago

    ADC input signals are really sensitive to source impedance, and it's generally recommended to keep the maximum impedance of your analog signal source around 10 kΩ. If the source impedance is too high, it can lead to longer sampling times, which may mess up your conversion results. This could be one of the issues you're facing when using an internally generated negative voltage reference.
    To avoid problems, make sure your circuit design doesn't introduce extra impedance that could affect the ADC's performance. For more detailed information, check out the PIC16F18877 datasheet, especially the sections on ADC configuration and operation.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
Children
No Data
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2026 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube