RC Circuit Natural Response Implementation - Page 1
Forum section: electronics / beginners

author: Mechatrommer
author_rank: Super Contributor
timestamp: April 14, 2011, 06:56:34 pm
content: ok ok i know, this is the 1st semester 1st year ee subject. but i'm the slow learner. so to fellow mentors, pls verify my method...the objective is to measure the value of C from the decaying graph (picture) using the basic rc natural response formula thats on the page i'm opening infront of me right now (red text below).assuming my DMM is good and accurate enough to measure the resistant of a resistor. so i'll work out the C value.so from the graph...Vo = 3.48V, V(t) = 0.56V, t = 0.25s,DMM measured R = 130.8KOhmso using the formula, i got C = 1.0462uF, this is pretty close to DMM reading,but earlier i was testing the "said to be" 1nF smd capacitor, DMM confirm the value is close to that,but using this method, using DMM measured 10.568MOhm, i calculated the C as 0.4-0.6nF, quite far from DMM reading.so pls advice on any possible error source of this method of finding C using the formula below.

author: jahonen
author_rank: Super Contributor
timestamp: April 14, 2011, 07:04:44 pm
content: I think that the scope (Ri=10 M) is loading the circuit so that decay is faster than expected. Or, you can take it into account, in fact, it seems to be half of the expected value which seems to be right.Regards,Janne

author: Mechatrommer
author_rank: Super Contributor
timestamp: April 15, 2011, 03:16:30 am
content: ok now with 1MOhm built in Rigol DSO, i dont have to use external R for small F. i measured and confirmed the input impedance of the Rigol is 1.001MOhm. so working it outfrom the graph below and formula above, the capacitance is calculated to be:if R 1.000M... C = 1.027nF, butif R 1.001M... C = 1.026nF, close!so i calculated how much small the Rigol DS1052E can measure a capacitance...say its sampling at 1GSa/s = 1ns/Sa, we take 10 points to be comfortable = 10ns = tworking out R = 1MOhm, t = 10ns, and say Vt/Vo = 0.1... C is... 4.34fF4.34 femto Farad, or 0.00434 pF! is this for real?sounds like a science fiction?!edit: yes its a delussional science fiction

author: Mechatrommer
author_rank: Super Contributor
timestamp: April 15, 2011, 12:21:02 pm
content: i setup pic12f509 program to make latched switch as my finger is far from good for a stable switching OFF (natural respond). the diagram as below. ie when pin 2 is high, pin 5 will transit cleanly from low to high vice versa (as shown in ch1 graph, high to low).procedure:1) all measurement is done at node 1 and ground.2) measure impedance using DMM while dso and pic are turned ON and connected to circuit (dso to node 1), pic is output low at pin 5 (i assume tied to ground), you'll get Xi (internal impedance)3) calibrate (top graph) by removing C (DUT) and measure. using natural response formula, you'll get Ci (internal capacitance, incl cable etc)4) measure the DUT capacitance... by placing it as in the schematic, using the formula and subtract the Ci, you'll get roughly the DUT C value5) redo (4) several time to get more confidence in C reading, as it can jump up and down a little bit. more answers, you'll better picture which one is more reliable.two graphs below is my measurement on a 2.2 pF smd cap (smallest i have). from calculation...Xi = 127,390 OhmCi = 22.67 pFafter subtraction, the DUT is measured as 2.6 pF. not very close but can be used as rough estimation. my Uni-T read 13pF after several minutes of wait, hopeless!

author: saturation
author_rank: Super Contributor
timestamp: April 15, 2011, 01:47:20 pm
content: This is beautify done work, and great photos. You have it now and answered the question raised here:https://www.eevblog.com/forum/index.php?topic=3126.msg41723#msg41723

author: Mechatrommer
author_rank: Super Contributor
timestamp: April 15, 2011, 04:01:30 pm
content: but i still dont 100% trust reading less than 8bit data. ok my question answered by me. at least this is the best we have.... reading graticules

author: saturation
author_rank: Super Contributor
timestamp: April 15, 2011, 04:18:09 pm
content: Recall, the Rigol is rated ~4% accurate on Voltage. But relative readings, Vout/Vin are likely to be better.Quote from: Mechatrommer on April 15, 2011, 04:01:30 pm

author: Unknown
author_rank: Unknown
timestamp: April 15, 2011, 09:17:44 pm
content: Quote from: saturation on April 15, 2011, 04:18:09 pmAs long as the frequency and vertical attenuator setting are the same, I agree, short term stability is likely to be better. The 8 bits are an obvious theoretical limit, and I'd expect the effective number of bits to be significantly lower (6?).

author: Mechatrommer
author_rank: Super Contributor
timestamp: April 16, 2011, 06:32:05 am
content: i mentioned somewhere else its 7.6 bit, 200 resolution, WYSIWYG on screen. but it could be 7.82 bit, 226 resolution = 2^7.82 from the data i observed.

author: Unknown
author_rank: Unknown
timestamp: April 16, 2011, 02:43:07 pm
content: Effective number of bitsdepends on noise floor and distortion, not just on the number of pixels. I highly doubt that the Rigol DSO has an ENOB of 7.6 over the full bandwidth.This articleexplains some of the issues, it shows a DSO with 8 bits of vertical resolution only having an ENOB of 5.8 at high frequencies (not sure how close this is to the bandwidth limit), and a DSO with 10 bits of vertical resolution with an ENOB of 7.2 at low frequencies and 5.5 at high frequencies.

author: Mechatrommer
author_rank: Super Contributor
timestamp: April 16, 2011, 10:38:36 pm
content: let me put an end to this... the finale...measuring capacitance from natural response graph."for the sake of measurement" - the poor man's methodps:1) any further improvement advice will be appreciated.2) RIP 1x pic10f206 due to 12V application.

author: jahonen
author_rank: Super Contributor
timestamp: April 17, 2011, 11:49:12 am
content: I think that curve fit technique (least squares or whatever) might give some robustness against noise.Also, if that seems too radical, I think it would be better just choose two points from the exponential decay portion which are far away from each other. That eliminates the uncertainities regarding the start point. This is possible since we can arbitrarily choose the initial voltage, and exponential behaves same way regardless what the initial point was. This is suitable for scope tracking cursors, since we can freely choose the points and use exact time and voltage values given for cursor locations.tau = -t/(ln(U(t)/U(0))Regards,Janne

author: Mechatrommer
author_rank: Super Contributor
timestamp: April 17, 2011, 12:44:43 pm
content: i have thought of that, averaging it to get less noisier input, and thanks for your suggestion and reminder on least square technique. but i think not much point to it, since there is no way on earth a few cents circuit can rival the dedicated C meter, let alone the top class 10K++ capacitance meter, keyword: accuracy and repeatability problem. about choosing which point to do the calculation, thats exactly what i did (nrc_calc.zip), and i did more, the brute force approach, i tried to calculate every points at a predefined step between the 600 points i got from rigol. from my observation, its best (closer to spec'ed capacitance) if we choose the point from starting of decay as V(o) and somewhere at Vo/2 (in the middle of decay) as V(t). (i coded to find those points). well, a picture worth 1K words. you can see how nasty the results are (brute force calculation) below, esp at the far edge.shown is a measurement of a 470pF smd (ceramic?) capacitor. pls give attention to index1 and index2, thats the data/sample index (array) i choose from 600 samples as Vo and Vt, and attention to "Mid" capacitance value, thats using latest Zs (Mid) measurement of the circuit (by DMM) and thats the one is plotted (the max and min are just ranges the "unstable" DMM ohm measurement gave during my many Zs measurements earlier)the superimposed windows app showing result using the above mentioned "best observed" method, Vo = start of decay, Vt = somewhere near the middle of decay (from Vo to 0.05Vo, roughly Vo/2, or lower). it supposed that "Mid" Capacitance value should get the answer, Min and Max are just to give me idea on tolerance.

author: Mechatrommer
author_rank: Super Contributor
timestamp: April 19, 2011, 02:20:31 am
content: found a writing on how to measure esr and self-inductance of a capacitor. i think is a good read and am halfway through reading it. so just let me put the link here...http://www.emcesd.com/tt020100.htm

author: Mechatrommer
author_rank: Super Contributor
timestamp: April 19, 2011, 04:51:14 pm
content: this is a PITA!set the rigol to averaging 16reprogram the pic for auto switch on-off 100ms interval (pwm like stuff)reprogram the pc app to do loop calculation and averaging,made a graph for qualitative evaluationclose all windows and fan, and stay put. dont let my breath goes to the circuit, yet....the result still oscillating like crazy!i wonder how actually the standardized party like Fluke, Agilent, NIST or even scientist do the calibration?do they faced the problem that i had? what a pain in the ass!and here's the kicker (470pF measurement):my method calculates460.34pF ±5.6pF(that is after maaaaany calculations! averaging! waiting and qualitative check!)my UT71A measured493pF ±4pF(after writing down a few measurements for a day or two)my DT890G measured479pF ±1pFa quick check just nowi have to find reason why should i believe my UT71A.i really missing something.ps: to complete the graph drawing from left to right (bottom picture) is worth minutes of wait and lying down.