Electronic Projects, forums and more.

Go Back   Electronic Circuits Projects Diagrams Free > Electronics Forums > General Electronics Chat


General Electronics Chat This forum is for general chat about electronics, eg: Dont know what a part does? Dont know how to read a circuit? Want to get an opinion?

Reply
 
Tools
Old 6th November 2009, 10:33 AM   #1
Unhappy Help!How to choose capacitor and resistor for RC circuit?

Hi. I need help from experts. I'm doing a project on reading analogue voltage humidity sensor (HIH 4000) using PIC16F917 (datasheet) and then showing the converted value on a LCD. I'm using the built in ADC in the PIC for the value conversion. The problem is I cannot get the accurate reading from the PIC. A quick check up on the Humidity sensor datasheet,I found that the sensor's maximum settling time is 70ms. Meanwhile the AD acquisition time (page 183) Tacq with 10kHz source of impedance and 50degreesC temperature is 4.67us. So I suspect the causes of the inaccurate reading are because of high possible transient amplitude and slow settling time. I have read somewhere that I need to build an RC circuit in between the output voltage,Vout, of humidity sensor and input of the ADC in order to rectify this problems. Now, my problem is I do not know how to build one and the theories behind it. I just know the basic design of RC circuit: .
What value of resistor and capacitance should I used in my RC circuit?
garygothic is offline  
Old 6th November 2009, 10:53 AM   #2
Default

The Pic input impedance should be 10K or less, so try a series 10K, with the Pic ADC pin shunted to ground with a 100nF. That will give a settling time of about 3msec. If you need longer, increase the cap to 1uF.
__________________
Mike ML.
MikeMl is offline  
Old 6th November 2009, 12:45 PM   #3
Default

May I know how did you get the value of settling time of 3ms from the resistance and capacitor value?What is the formula?
garygothic is offline  
Old 6th November 2009, 03:07 PM   #4
Default

Quote:
Originally Posted by garygothic View Post
May I know how did you get the value of settling time of 3ms from the resistance and capacitor value?What is the formula?
2.2*R*C, I used three time-constants: 3*1*10^4*100*10^-9 = 300*10^-5 = 3ms
__________________
Mike ML.
MikeMl is offline  
Old 6th November 2009, 03:08 PM   #5
Default

Quote:
Originally Posted by garygothic View Post
May I know how did you get the value of settling time of 3ms from the resistance and capacitor value?What is the formula?
I used three time-constants: 3*1*10^4*100*10^-9 = 300*10^-5 = 3ms.

Maybe 5 would be better?
__________________
Mike ML.

Last edited by MikeMl; 6th November 2009 at 03:13 PM.
MikeMl is offline  
Old 7th November 2009, 07:31 AM   #6
Default

But the AD acquisition time,Tacq,is 4.67us. I'm supposed to make a settling time below 4.67us right?Let say I take 4 time-constants and 10K source impedance,so the value for capacitor is 0.1nF which will equal the Tacq time.
garygothic is offline  
Old 9th November 2009, 06:00 AM   #7
Default

The important thing is not the acquisition time, but the sampling rate. e.g., ff you were only doing a conversion once per second, the sample has the whole second to settle, even though it might only take 3us to actually do the conversion.
__________________
Mike ML.

Last edited by MikeMl; 9th November 2009 at 06:01 AM.
MikeMl is offline  
Old 9th November 2009, 06:05 AM   #8
Default

Meaning the longer sampling rate the better AD conversion value?
garygothic is offline  
Old 18th November 2009, 09:02 AM   #9
Default

it might be electrical noise on the adc power supply, try averaging 128 readings.
angophora is offline  
Reply

Tags
capacitor, choose, circuit, helphow, resistor

Thread Tools
Display Modes


Similar
Title Starter Forum Replies Latest
Resistor and Capacitor in Parallel mark_3094 General Electronics Chat 9 8th April 2009 12:57 PM
DC Circuit - Parallel Capacitor and Resistor Shelton General Electronics Chat 5 15th December 2007 11:37 AM
Capacitor across resistor? BeëlzeM General Electronics Chat 12 15th November 2007 10:36 PM
Capacitor and resistor needed moody07747 Datasheet/Parts Requests 2 8th June 2006 12:52 PM
resistor and capacitor assortments jrz126 General Electronics Chat 5 8th September 2005 05:28 PM



All times are GMT. The time now is 12:07 AM.


Electronic Circuits  |  Learning Electronics
eXTReMe Tracker