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.

When AC input source is open, still ADC giving output on lcd

Status
Not open for further replies.

ecaits

Member level 4
Member level 4
Joined
Jan 16, 2014
Messages
76
Helped
0
Reputation
0
Reaction score
0
Trophy points
6
Visit site
Activity points
579
Dear Sir,

In PIC16F877, I am taking 0-5V analog input source from pot of 5K and given on RA0 pin for ADC conversion and display on 16x2 LCD by Hi-tech C compiler.

It is working nicely.

But I have observe that when the source is open, still the ADC gives random output on LCD. How can I solve the problem???
 

The input is 'floating' because there is nothing to drain charges picked up from the environment away. Add a high value resistor (~100K) between the ADC input and ground. The value is high enough not to influence the ADC measurement but is low enough to drain the tiny charges away.

Brian.
 

It means that I have to put one ~100K resistor between RA0 pin of PIC16F877 and ground, as I am using 0-5 V analog input to RA0 pin. Is it right???
 

That is Correct!

I general, if something is driving an analog or digital input it will provide the voltage and also remove it but if you disconnect a pin so nothing is driving it you should add a resistor (pull-down or pull-up) so the pin adopts a known level and is better protected from static discharges.

Brian.
 

I have already added 470 ohm in series with source and RA0 pin.
 

I would remove it, the more resistance you add in SERIES with the ADC input the slower it will be to respond. The resistor I'm suggesting you add is ACROSS the ADC input and ground (between RA0 and VSS).

Brian.
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top