Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

[SOLVED] Problem with ADC in PIC16F877A while connecting multiple inputs

Status
Not open for further replies.

STSCBE

Member level 2
Joined
Jul 9, 2016
Messages
43
Helped
0
Reputation
0
Reaction score
0
Trophy points
6
Activity points
360
hi friends,
im using pic16f877a for reading Solar(1.3W,7.5V) and Battery (12V,7Ah) voltages by voltage divider(4V max). i connected both to RA0 and RA1. in simulation working properly but in hardware there some fluctuations between the two inputs and showing one input is depends another. it means, if solar voltage is changed suddenly battery voltage is also changing..... I dont know, what is the problem.
In my analysis, is the fluctuations are varies depends on different input current rating(SOLAR and Battery)?
 

Almost certainly the problem is the settling time of the internal sample and hold circuits. When you change from one input to another, the existing voltage on the S&H has to charge or discharge to the new one you are applying. The solution is usually to add a small delay (a few mS) after changing the ADC input channel but before starting the ADC measurement.

Brian.
 
I think you are changing the channels and read ADC immediately after that, you should change channel give a time delay then read ADC , you can do some dummy reads also
 

Hi,

Show us your circuit and your software.

Klaus
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top