Capacitance Measuring Circuit - Can This Circuit Be Changed For Higher Frequency?

Thread Starter

Mahonroy

Joined Oct 21, 2014
406
I came across this circuit that measures capacitance mainly between 30pF and 300pF, and is typically used between 31KHz and 250KHz. It basically outputs a 0-5V analog value that correlates with the capacitance. I drew a green arrow pointing to where the measurement is taking place. Its basically an RC circuit with a peak voltage detection circuit. I believe the op-amp is in place because the RC circuit has really high impedance, so this corrects it for the peak voltage detection portion. Here is the circuit:
1608333524620.png

My question is, how should I go about modifying this so I can use a much higher frequency of 80MHz instead of 31KHz-250KHz, and so I can read larger capacitance values (up to say 40uF). I simulated the circuit as-is, at different frequencies, and different capacitance values. The square wave I used here is a 0 to 5V square wave, 50% duty cycle:
1608333956517.png
It looks like the only thing that needs to be done is either change the values of the RC component of the circuit, or change the values of the peak detector? Or both? How do you determine what would be appropriate values for these? And I'm guessing I'll just pick an op-amp that has a "Gain Bandwidth Product" of something greater than 80MHz?

Any help or advice is greatly appreciated, thanks!
 

Papabravo

Joined Feb 24, 2006
21,158
What opamp do you propose to use? Can you afford one that has the required GBW?
Do you have the skills to layout a board to work at that frequency?
Do you have the test equipment?
 

Thread Starter

Mahonroy

Joined Oct 21, 2014
406
What opamp do you propose to use? Can you afford one that has the required GBW?
Do you have the skills to layout a board to work at that frequency?
Do you have the test equipment?
I just did a quick search in digikey, looking at rail-to-rail, 100MHz and above GBP, and there are a TON of different ones for cheap. So yes I can afford one.
https://www.digikey.com/en/products...k9sEABNuNbTBAvdxbABHDgAT24piYBATbEtPpNyAkEiAA

I can layout high frequency PCB's and I have an oscilloscope. I'm assuming I will be generating some unintentional interference that I can most likely solve with just a ferrite bead or a filter of some sort. But I'll cross that bridge at some point.
 

Papabravo

Joined Feb 24, 2006
21,158

bassbindevil

Joined Jan 23, 2014
824
My gut says this doesn't look like a great way to measure capacitance over a wide range. The square wave has harmonics forever, the op-amp does not have bandwidth to infinity, and the diode isn't perfect. Maybe for a specific application where capacitance varies by no more than a factor of 10 or so and you just need an indication (like the level of material in a tank).
But, anyway, to measure large capacitances, use a lower frequency. Or consider a different method; maybe one that involves measuring time or frequency, which can be done very precisely using digital circuits.
 

Thread Starter

Mahonroy

Joined Oct 21, 2014
406
My gut says this doesn't look like a great way to measure capacitance over a wide range. The square wave has harmonics forever, the op-amp does not have bandwidth to infinity, and the diode isn't perfect. Maybe for a specific application where capacitance varies by no more than a factor of 10 or so and you just need an indication (like the level of material in a tank).
But, anyway, to measure large capacitances, use a lower frequency. Or consider a different method; maybe one that involves measuring time or frequency, which can be done very precisely using digital circuits.
Thanks for the info. Regarding the range, I could even do from like 500pF to 40uF. I only need like 100 steps in that range, it doesn't have to be that precise really. I originally wanted to do the low frequency method of keeping track of time it takes to charge and discharge beyond a threshold to determine capacitance. In this specific problem, I need the frequency to be above 50MHz minimum. So I could go down in frequency slightly if that helps?
Do you know what I should look for as far as a diode is concerned?
 

Papabravo

Joined Feb 24, 2006
21,158
As in I'm sure to fail? I still don't quite know the best way to tweak the resistors/capacitors to appropriate values for 80MHz.
That is not even remotely accurate. From your initial reply I take it that you are confident in your ability to succeed. I would like to see you succeed. Is there another way to express encouragement?
 

michael8

Joined Jan 11, 2015
410
> If I remember correctly (1/(2*pi*f*c)), the impedance of a 40 uF capacitor
> at 50 MHz is a dead short, so good luck measuring anything.

Won't a real capacitor have some inductance and resistance? And at
80 MHz you might be measuring the inductance more than anything else:
2*pi*f*L -> 2*pi*80MHz*10nH -> about 5 ohms... (Wire is about 1 nH/mm)
 

Thread Starter

Mahonroy

Joined Oct 21, 2014
406
If I remember correctly (1/(2*pi*f*c)), the impedance of a 40 uF capacitor at 50 MHz is a dead short, so good luck measuring anything.
So the reason behind the frequency... I am trying to determine soil moisture content by taking a capacitance reading. The salinity of a soil effects resistive measurements, but effects capacitance measurements much less...... but still effects them. There are some studies that show when using higher frequencies to measure capacitance, that salinity barely has an effect on the capacitance reading, and that the "sweet spot" is between 50 MHz and 150 MHz. This is why I am trying to figure out how to take a capacitance reading of something using these high frequencies.
 

Papabravo

Joined Feb 24, 2006
21,158
So the reason behind the frequency... I am trying to determine soil moisture content by taking a capacitance reading. The salinity of a soil effects resistive measurements, but effects capacitance measurements much less...... but still effects them. There are some studies that show when using higher frequencies to measure capacitance, that salinity barely has an effect on the capacitance reading, and that the "sweet spot" is between 50 MHz and 150 MHz. This is why I am trying to figure out how to take a capacitance reading of something using these high frequencies.
Well the answer to your conundrum is to rent a VNA for a month and confirm that theory. You might find that over that frequency range things don't behave as you expect. At least they never have in my experience.
 

Papabravo

Joined Feb 24, 2006
21,158
Is this for an AC frequency though? My question is regarding a 0-5VDC square wave, would that still apply?
Yes, the square wave has a rich harmonic content that will be attenuated by the capacitor resulting in something that looks quite a bit like a sine wave. As has already been mentioned, as you go up in frequency, any capacitor will start looking more and more like an inductor. The dual is also true as you go up in frequency any inductor will start looking more and more like a capacitor.
 

Thread Starter

Mahonroy

Joined Oct 21, 2014
406
Yes, the square wave has a rich harmonic content that will be attenuated by the capacitor resulting in something that looks quite a bit like a sine wave. As has already been mentioned, as you go up in frequency, any capacitor will start looking more and more like an inductor. The dual is also true as you go up in frequency any inductor will start looking more and more like a capacitor.
Would that prevent the above circuit from working?
 

Papabravo

Joined Feb 24, 2006
21,158
Would that prevent the above circuit from working?
I'm not absolutely certain. I don't think you will be able to use an idealized component model at those frequencies. If you use a model that includes parasitic effects you may be able to calibrate a particular instrument to give a reliable indication of component values. How close to reality you can get will depend on the components selected and your understanding of all that is going on that you cannot see. Having access to a VNA would go a long way to understanding what is going on.

For a single component, the VNA plot of impedance vs. frequency, will spiral around the origin of the complex plan. An ideal capacitor should spiral in toward the origin and an ideal inductor should spiral out towards the point at ∞
 

Thread Starter

Mahonroy

Joined Oct 21, 2014
406
I'm not absolutely certain. I don't think you will be able to use an idealized component model at those frequencies. If you use a model that includes parasitic effects you may be able to calibrate a particular instrument to give a reliable indication of component values. How close to reality you can get will depend on the components selected and your understanding of all that is going on that you cannot see. Having access to a VNA would go a long way to understanding what is going on.

For a single component, the VNA plot of impedance vs. frequency, will spiral around the origin of the complex plan. An ideal capacitor should spiral in toward the origin and an ideal inductor should spiral out towards the point at ∞
I am going to be calibrating this thing after the fact. That analog reading is going to go into an ADC, and I will create a function that converts that reading into a rough capacitance value, and then eventually a moisture %.
 

Ian0

Joined Aug 7, 2020
9,667
So the reason behind the frequency... I am trying to determine soil moisture content by taking a capacitance reading. The salinity of a soil effects resistive measurements, but effects capacitance measurements much less...... but still effects them. There are some studies that show when using higher frequencies to measure capacitance, that salinity barely has an effect on the capacitance reading, and that the "sweet spot" is between 50 MHz and 150 MHz. This is why I am trying to figure out how to take a capacitance reading of something using these high frequencies.
So how do you measure capacitance of soil? What actually are you measuring? It's dielectric constant?
If you are trying to remove electrolytic effects, would it be better to measure the resistance with AC? There's a very convenient 50Hz signal source available (which might be 60Hz in some parts of the world)
 

MisterBill2

Joined Jan 23, 2018
18,167
At the much higher frequencies the capacitive reactance at higher values of capacitor will be very low. Xc=1/ 2(pi) fC.
In addition the circuit shown actualy reads the sum of capacitive reactance and equivalent series resistance in parallel with the capacitor leakage resistance. So your results will not be very useful
 
Last edited:

bassbindevil

Joined Jan 23, 2014
824
What I'm picturing is a 50 MHz (or so) oscillator driving an insulated metal electrode through an LC low-pass filter to reduce the harmonics, and a second insulated electrode connected to an RF millivoltmeter probe that produces a DC output proportional to the amplitude of the 50 MHz signal. I'm not sure what gets grounded to what, when you're trying to measure "ground".

Now, if lower frequencies are acceptable, the LM1830 was designed for liquid level sensing and generated an AC signal to prevent electrolytic effects at the electrodes.
 
Top