Author Topic: Stable and fast measurement of variable capacitor  (Read 17418 times)

0 Members and 1 Guest are viewing this topic.

Offline Zero999

  • Super Contributor
  • ***
  • Posts: 19491
  • Country: gb
  • 0999
Re: Stable and fast measurement of variable capacitor
« Reply #25 on: October 20, 2020, 08:26:45 pm »
The circuit on the left is a Colpitts oscillator and the one on the right Hartley. U1 is an unbuffered CMOS inverter IC, i.e. pins 9 & 10 on the '4060.
https://assets.nexperia.com/documents/data-sheet/74HC_HCT4060.pdf


In the Hartley oscillator, vary C1 and make C2 much greater, than the minimum value of C1.

In the Colpitts oscillator either C1 or C2 can variable.

« Last Edit: October 20, 2020, 08:28:16 pm by Zero999 »
 

Offline kaljTopic starter

  • Contributor
  • Posts: 34
  • Country: se
Re: Stable and fast measurement of variable capacitor
« Reply #26 on: October 20, 2020, 08:31:26 pm »
https://wiki.analog.com/university/courses/electronics/electronics-lab-21
Did you try the LC oscillator I suggested? It's much more stable than an RC time constant, irrespective of whether it's an oscillator, or charging the capacitor from an MCU output.

I did start playing around with a simple LC resonance circuit, and it does look like the resonance frequency is very stable, so this method looks promising. I have ordered the CD4069UB part that is used in the page you linked.

You would have to recreate the circuit around Q3 out to and including L4
The temperature grades of C14 and C13 would have been selected to offset ( tend to null)  thermal drift in Q3 and L4.
So they are not necessarily NPO.

But if L4 has been discarded, it might be a job to do another stable oscillator.
"Synthetic Rock" comes to mind but you can search it for VHF versions, or otherwise look for 2 metre VFO circuits.

Perhaps someone on here versed in the statistics of it, can explain why a high Q oscillator is perhaps the best way to accurately measure L & C.

I like your original idea for restoration. I have some old vacuum tube receivers I restored, in good condition.
A very early 1940's Philco FM, here woodwork looks good, but is too far gone to receive FM properly, maybe a candidate for your idea.
Looked around for some of the oscillator circuits you mention, but felt that those old pieces of analog art are a bit above my understanding. Hand-winding coils and stuff seem like a very daunting task!

Yeah it feels good to give old devices new life. In this case, the radio belonged to my father in law who bought it as his first radio in his youth. Now the plan is to fix it and give it back as a Christmas present.
 

Offline kaljTopic starter

  • Contributor
  • Posts: 34
  • Country: se
Re: Stable and fast measurement of variable capacitor
« Reply #27 on: October 20, 2020, 08:44:31 pm »
Here is the idea of my previous post.
SW1 is a switch (any reasonably fast high isolation SPST switch, didn't have time to look what is available in my LTSpice library) to reset the measurement (discharging C2) just before starting counting.  R1,R2,R4 set the ratio charging voltage/comparator voltage, C3 is to filter power voltage fluctuations during a measurement cycle.
There is of course a tradeoff between the resolution and the measureement time (depending on the values of C2 and R4) but you can easily get a 4-digit resolution. Anyway I bet this will be orders of magnitude more accurate than any 555 crap (I hate 555s  ;D)

NB. The simulation won't work with a generic SW1, should be removed or replaced by a real one.

Edit: One question not to overlook is how the resolution of each measurement technique varies across the capacitance range.  Since the radio frequency varies like 1/sqrt(C)  the resolution on C should vary like 1/C^3/2 to get a constant resolution over the radio frequency range. In my circuit the resolution varies like 1/C but in time-constant measurements it would vary the wrong way (roughly proportional to C) making it difficult for small  capacitances.  With a 555 we should measure the frequency rather than the time constant (roughly equivalent to averaging many measurements).

That looks very interesting. Let me see if I understand this: The LTC1043 charges the varcap, then switches over so that the varcap charges the 1µF capacitor, then switches back, etc. This process repeats until the reset switch is flipped and the 1µF cap is discharged. I can sense Vcomp- and Vcomp+ and measure the number of cycles needed to charge the big cap. Correct?

I am curious why this would be more stable than the other charge-time methods I have tried. Any idea?

Anyways, I have ordered the LTC1043 and will have a shot at your suggested circuit when it arrives.
 

Offline kaljTopic starter

  • Contributor
  • Posts: 34
  • Country: se
Re: Stable and fast measurement of variable capacitor
« Reply #28 on: October 20, 2020, 08:49:45 pm »
At first I thought the OP wanted to do this primarily with the hardware on an Arduino, but since the OP included fresh hardware involving 4000 family parts and the 555 I presume it's OK to suggest other new hardware.

Take a good look at the Charge Time Measurement Unit (CTMU) included in a bunch of Microchip PIC MCU's. I've used that in several designs and it's literally tailor made to do exactly what you want to do here: Measure capacitance. Everything you need in both the analog and digital domains is already on the chip, and this approach will give you the flexibility of firmware control over the entire process. It will also unburden the Arduino from requiring time-specific operations to measure C... just let the MCU handle it like it was specifically designed to do.

Once you're measuring C with the CTMU, having the MCU gives you lots of options to communicate the results to your Arduino. SPI, UART, roll your own, whatever you like.

I have successfully measured capacitance down into the low double digit picofarad range, and on the other end you can scale (dynamically in your firmware if necessary) to almost any upper value. Obviously you'll need to pay attention to layout but that's true of any method when measuring C down to ~14pF as mentioned in the first post.

In addition to the spec sheets for the MCU's that include the CTMU, there are at least two Microchip appnotes that focus specifically on it. Do a Google search. Lots of reading material and example applications to get you started. This is a one-chip answer to your question with nearly infinite flexibility.

Thanks for the tip! It is amazing how many approaches there are to solving such a seemingly simple problem.

I am quite inexperienced with PIC MCUs though. Have always found them more complicated to work with than say the Arduino. Do you have a suggestion for a suitable - preferably cheap - PIC if I want to try out the CTMU for this simple task?
 

Offline kaljTopic starter

  • Contributor
  • Posts: 34
  • Country: se
Re: Stable and fast measurement of variable capacitor
« Reply #29 on: October 20, 2020, 09:12:34 pm »
The circuit on the left is a Colpitts oscillator and the one on the right Hartley. U1 is an unbuffered CMOS inverter IC, i.e. pins 9 & 10 on the '4060.
https://assets.nexperia.com/documents/data-sheet/74HC_HCT4060.pdf


In the Hartley oscillator, vary C1 and make C2 much greater, than the minimum value of C1.

In the Colpitts oscillator either C1 or C2 can variable.

Thanks! That looks similar to the oscillator based on CD4069 linked by Zero999 (https://wiki.analog.com/university/courses/electronics/electronics-lab-21). I have ordered the CD74HCT4060 now so I will try your circuit out once it arrives.

Anyways, what inductor type and value do you suggest for combining with my 14-680pF varcap? And are regular old ceramic caps okay, or are any other type preferable?
 

Offline IDEngineer

  • Super Contributor
  • ***
  • Posts: 1925
  • Country: us
Re: Stable and fast measurement of variable capacitor
« Reply #30 on: October 20, 2020, 09:55:58 pm »
I am quite inexperienced with PIC MCUs though. Have always found them more complicated to work with than say the Arduino. Do you have a suggestion for a suitable - preferably cheap - PIC if I want to try out the CTMU for this simple task?
First, be prepared for naysayers who will speak poorly of the PIC family. But they're like every other MCU out there - you select the one that is best suited for the specific application. In this case, what you're buying is the CTMU and it happens to come wrapped in a PIC. We're not focused on the purity of some CPU architecture, we're trying to get a job done!

There are quite a few PIC's with the CTMU. You can pick one using Microchip's website selectors, but take a look at the PIC18F23K22. You don't need much code space nor memory, it's available in a 28 pin PDIP package which will make breadboarding easy, etc. To get started debugging you can use their cheap PICkit3 debugger which costs like $50. That, their free compiler, and a laptop and you're ready to go. You could be testing this in a couple of hours.

EDIT: The PIC's aren't any more complex than anything else. You'll program in C, just like the Arduino, and you control the on-chip peripherals via hardware registers that have handy mnemonic names. Not hard at all.

EDIT2: Here's the link to the spec sheet: http://ww1.microchip.com/downloads/en/DeviceDoc/40001412G.pdf . The CTMU starts on page 311.
« Last Edit: October 20, 2020, 10:02:31 pm by IDEngineer »
 

Offline pwlps

  • Frequent Contributor
  • **
  • Posts: 372
  • Country: fr
Re: Stable and fast measurement of variable capacitor
« Reply #31 on: October 20, 2020, 11:53:39 pm »
That looks very interesting. Let me see if I understand this: The LTC1043 charges the varcap, then switches over so that the varcap charges the 1µF capacitor, then switches back, etc. This process repeats until the reset switch is flipped and the 1µF cap is discharged. I can sense Vcomp- and Vcomp+ and measure the number of cycles needed to charge the big cap. Correct?

Yes, the process repeats until you detect that the comparator tripped, then you save the counter value and programatically close the switch to discharge the 1µF capacitor. To start a new measurement you reset the counter and reopen the switch at the same time.

I don't know the electrical and timing characteristics of arduino pins but in a first approximation you might possibly simulate the switch action (if you don't have a switch already) toggling a pin between the input (high impedance-switch open) and output (low state-switch closed) configurations.

Note that you can also provide your own clock from an arduino pin (overriding the LTC1043 internal clock, see datasheet), this gives more flexibility (e.g. the exact timing and speed of the switch will be irrelevant if you drive the clock programatically).  From my estimations you can use a clock frequency up to at least 200-300kHz (taking roughly 5 RC time constants for charging/discharging the varcap, with R being the on-state resistance of LTC1043, but double-check my estimations).


Quote
I am curious why this would be more stable than the other charge-time methods I have tried. Any idea?

I would say the most relevant difference is that the total amount of charge involved is thousands times bigger, the process is effectively averaging the measurement of charge on the varcap. However note that this is not exactly the same as averaging many charge-time measurements because there is no averaging of errors due to jitter (mathematically speaking and leaving aside the clock speed, the jitter error here scales like 1/N whereas for averaged charge-time measurements it would scale like 1/sqrt(N) (*); this "1/sqrt" behavior of jitter contribution is also found in RC-discharge based frequency generators, cf. 555 style generators).  Maybe there are other subtle points, I'm open to a discussion on this interesting question.

(*) for the math see https://en.wikipedia.org/wiki/Random_walk#Gaussian_random_walk; the total excursion varies like sqrt(N) therefore the average over N samples varies like 1/sqrt(N)
« Last Edit: October 21, 2020, 01:14:27 am by pwlps »
 

Offline David Hess

  • Super Contributor
  • ***
  • Posts: 16604
  • Country: us
  • DavidH
Re: Stable and fast measurement of variable capacitor
« Reply #32 on: October 21, 2020, 08:52:54 am »
An easier and more accurate way to use the LTC1043 is to configure it as a voltage-to-frequency converter, which is very simple, but with a fixed voltage so the frequency varies with the capacitance instead of voltage.
 

Offline pwlps

  • Frequent Contributor
  • **
  • Posts: 372
  • Country: fr
Re: Stable and fast measurement of variable capacitor
« Reply #33 on: October 21, 2020, 09:17:47 am »
An easier and more accurate way to use the LTC1043 is to configure it as a voltage-to-frequency converter, which is very simple, but with a fixed voltage so the frequency varies with the capacitance instead of voltage.

I saw this application in the datasheet and thought of it too but it's not necessarily more accurate because it is directly related to the voltage stability, you would need to add a precision voltage regulation stage. I actually preferred a circuit where the measurement result is determined by the values of passive components only and does not depend on any voltage, at least in first order.

Edit: and I don't find it easier at all, at least the circuit proposed in the datasheet is more complicated.  But it certainly depends on our personal experience with various approaches.
« Last Edit: October 21, 2020, 09:23:05 am by pwlps »
 

Offline David Hess

  • Super Contributor
  • ***
  • Posts: 16604
  • Country: us
  • DavidH
Re: Stable and fast measurement of variable capacitor
« Reply #34 on: October 22, 2020, 09:20:30 am »
That is right; the frequency is proportional to the capacitance *and* the voltage so a voltage reference is required and that voltage reference limits accuracy.  In practice however the variable film capacitor has a larger temperature coefficient than even an inexpensive voltage reference so the voltage reference does not limit accuracy.  Indeed, accuracy could be improved considerably by including a thermister or diode to deliberately vary the voltage slightly with temperature.

The advantage of this circuit is extreme linearity without any additional effort.  For instance there are no effects from having to periodically reset including dielectric absorption.  An LC oscillator would have the same advantage.
 

Offline pwlps

  • Frequent Contributor
  • **
  • Posts: 372
  • Country: fr
Re: Stable and fast measurement of variable capacitor
« Reply #35 on: October 22, 2020, 01:24:47 pm »
That is right; the frequency is proportional to the capacitance *and* the voltage so a voltage reference is required and that voltage reference limits accuracy.  In practice however the variable film capacitor has a larger temperature coefficient than even an inexpensive voltage reference so the voltage reference does not limit accuracy.  Indeed, accuracy could be improved considerably by including a thermister or diode to deliberately vary the voltage slightly with temperature.

The advantage of this circuit is extreme linearity without any additional effort.  For instance there are no effects from having to periodically reset including dielectric absorption.  An LC oscillator would have the same advantage.

I must agree with your point on the temperature drift and possibly on the effects of dielectric absorption (although I have no idea at which level of accuracy the dielectric absorption and related memory effects may become a concern, I'm curious to know if you have experience with such problems).
I also agree that an LC oscillator might be the simplest solution. Still I'm curious what the performance of my circuit would be compared to others, and apparently the OP ordered an LTC1043 already... :) 

PS. Just an additional info not related to this discussion: I updated the schematic and added some simulations in my post of oct 19.
« Last Edit: October 22, 2020, 07:18:03 pm by pwlps »
 

Offline mag_therm

  • Frequent Contributor
  • **
  • Posts: 656
  • Country: us
Re: Stable and fast measurement of variable capacitor
« Reply #36 on: October 22, 2020, 01:49:33 pm »
Thanks for adding the sim traces.
As I see it, the Cvariable carries back its residual charge to S1a, so next charge is to the difference Q_c5 - Q_c2 and the staircase has smaller steps toward the end.
So accuracy might be better if V_C2 is not charged too  close to V_C5.

Why did you move reference Vcomp+ away from R3? I thought it was in a good place for overall error cancellation in your first revision.
« Last Edit: October 22, 2020, 03:01:55 pm by mag_therm »
 

Offline David Hess

  • Super Contributor
  • ***
  • Posts: 16604
  • Country: us
  • DavidH
Re: Stable and fast measurement of variable capacitor
« Reply #37 on: October 22, 2020, 04:41:27 pm »
I must agree with your point on the temperature drift and possibly of the effects of dielectric absorption (although I have no idea at which level of accuracy the dielectric absorption and related memory effects may become a concern, I'm curious to know if you have experience with such problems).

Designs which continuously integrate their input have at least an order of magnitude more accuracy, but that probably does not matter here because of the limited accuracy of the variable capacitor unless its temperature coefficient is compensated.  1 part in 100,000 is possible while reset based designs have trouble even below 1 part in 10,000.

Multi-slope integrating analog-to-digital converters get around this by using "run-up" and "run-down" designs which make the integrating capacitor effectively much much larger so that its error contribution from dielectric absorption is smaller.

Quote
I also agree that an LC oscillator might be the simplest solution.

The only disadvantage of the LC oscillator is the temperature coefficient of the inductor.  Extra accuracy is available by selecting an inductor which has the opposite temperature coefficient of the variable capacitor but this can be difficult.
 

Offline pwlps

  • Frequent Contributor
  • **
  • Posts: 372
  • Country: fr
Re: Stable and fast measurement of variable capacitor
« Reply #38 on: October 22, 2020, 05:43:01 pm »
Why did you move reference Vcomp+ away from R3? I thought it was in a good place for overall error cancellation in your first revision.

As I explain in the update notes this is to easier and better decouple the reference comparator voltage from spikes at S1A. (I had overlooked this little potential problem and changed the circuit after I saw spikes on Vcomp+ in my simulations of the first version). There shouldn't be any difference in the error cancellation (at least as long as all resistances have the same temperature coefficient), in fact the only difference is that the current through the R1/R4 divider does not flow through R2. 
« Last Edit: October 22, 2020, 05:49:52 pm by pwlps »
 

Offline mag_therm

  • Frequent Contributor
  • **
  • Posts: 656
  • Country: us
Re: Stable and fast measurement of variable capacitor
« Reply #39 on: October 22, 2020, 05:52:58 pm »
Old type shortwave receiver with a variable capacitor VFO  ( warmed up)  might typically drift by +/- 100 Hz over 24 hours when tuned to WWV @ 10 MHz.
That is "accuracy, free run /day " of +/- 1e-5

A TCXO might be spec'ed at +/- 1e-7

Usually the old coils were air cored litz wound solenoids with a  diameter of 25 to 50 mm. Larger diameter has higher Q factor.
Look at photos and circuits ( Colpitts)  of the Geloso 104 VFO which was well respected 70 years ago.
 

Offline pwlps

  • Frequent Contributor
  • **
  • Posts: 372
  • Country: fr
Re: Stable and fast measurement of variable capacitor
« Reply #40 on: October 22, 2020, 06:27:02 pm »
Multi-slope integrating analog-to-digital converters get around this by using "run-up" and "run-down" designs which make the integrating capacitor effectively much much larger so that its error contribution from dielectric absorption is smaller.

So it would take two more SPDT (reference and charging voltages) to implement multi-slope here.   If the OP has enough courage...  :)
 

Offline kaljTopic starter

  • Contributor
  • Posts: 34
  • Country: se
Re: Stable and fast measurement of variable capacitor
« Reply #41 on: October 22, 2020, 07:49:03 pm »
Interesting discussions on the LTC1043-based approach! I will try out some of your suggestions once I get a hold of the the chip.

Meanwhile, I have started to play around with the LC oscillator using CD4069 / 74HCT4060. I tried both the Hartley and the Colpitts types and managed to get something that seems to oscillate very solidly. I used some random 100µH coils and a 470pF ceramic capacitor, and got oscillations in the 380kHz - 1.6MHz range. However, I notice that at higher frequencies, the waveforms look less and less sine shaped, if that is a problem. Also, there seems to be an amplitude dependence on the frequency (higher frequency -> smaller amplitude). With the 74HCT4060, the damping was strong enough to not yield oscillations for the smallest capacitances.

I really feel lost concerning the ideal choice of coils and capacitors for the oscillator. If anyone has any insight and suggestions that would be very appreciated!

To determine the frequency using the Arduino, I guess I can either measure pulse lengths (accuracy decreases with frequency), or pulse counts per time unit (accuracy increases with frequency). It is an interesting question what combination of frequency range of the oscillator and measurement method produces the overall smallest noise. What do you guys think?
 

Offline kaljTopic starter

  • Contributor
  • Posts: 34
  • Country: se
Re: Stable and fast measurement of variable capacitor
« Reply #42 on: October 22, 2020, 07:55:09 pm »
To determine the frequency using the Arduino, ... or pulse counts per time unit (accuracy increases with frequency).

I just realized that if I can get the oscillator working using the 74HCT4060, I will essentially get a pulse counter for free. I.e., arduino resets 4060 counter, waits say a millisecond, then reads of the value of the counter, and then F=count/1ms. Perhaps I need to add a register to latch the counter to not get race conditions in the readings.

How about that solution?
 

Offline pwlps

  • Frequent Contributor
  • **
  • Posts: 372
  • Country: fr
Re: Stable and fast measurement of variable capacitor
« Reply #43 on: October 22, 2020, 08:17:33 pm »
To determine the frequency using the Arduino, I guess I can either measure pulse lengths (accuracy decreases with frequency), or pulse counts per time unit (accuracy increases with frequency). It is an interesting question what combination of frequency range of the oscillator and measurement method produces the overall smallest noise. What do you guys think?

The standard high-resolution frequency measurement technique working at either low or high frequencies combines both counting and period measurements and is known as "reciprocal frequency counting", see eg.
https://www.instructables.com/High-Resolution-Frequency-Counter/
 

Offline mag_therm

  • Frequent Contributor
  • **
  • Posts: 656
  • Country: us
Re: Stable and fast measurement of variable capacitor
« Reply #44 on: October 22, 2020, 08:41:29 pm »
There are not many hits for cmos gate LC oscillators!
In 74HC4060 data sheet ( Nexperia) Fig 13, the crystal oscillator feedback is via a 2k2 limiting resistor, which might be OK for a crystal,
but I think will reduce the Q factor (and hence accuracy) of an LC, unless C2 can be increased to be >> C_variable.
I would add a jfet and make a standard colpitts of which there are lots of examples.
The aim is to get it oscillating in the linear range without too much over-drive,
across the C_Variable's range, with a pure fundamental
by adjusting the feedback side capacitor C2 (maybe the cause of the distortion you mention)

Looks '4060  need to be safely below 20MHZ.
 

Offline Zero999

  • Super Contributor
  • ***
  • Posts: 19491
  • Country: gb
  • 0999
Re: Stable and fast measurement of variable capacitor
« Reply #45 on: October 22, 2020, 08:52:20 pm »
There are not many hits for cmos gate LC oscillators!
In 74HC4060 data sheet ( Nexperia) Fig 13, the crystal oscillator feedback is via a 2k2 limiting resistor, which might be OK for a crystal,
but I think will reduce the Q factor (and hence accuracy) of an LC, unless C2 can be increased to be >> C_variable.
I would add a jfet and make a standard colpitts of which there are lots of examples.
The aim is to get it oscillating in the linear range without too much over-drive,
across the C_Variable's range, with a pure fundamental
by adjusting the feedback side capacitor C2 (maybe the cause of the distortion you mention)

Looks '4060  need to be safely below 20MHZ.
The 74HC4060 should work as an LC oscillator. The link I posted above shows the crusty old CD4007/4069 working fine as an LC oscillator. It's not on the data sheet because it isn't something one would normally do, because an inductor is no cheaper than a crystal, or ceramic resonator, which will have far superior stability and accuracy.
https://wiki.analog.com/university/courses/electronics/electronics-lab-21

Overdrive is only an issue for a fragile crystal, which can easily be damaged by too much power. The 74HC4060 can whack an LC circuit as hard as it can without any damage. In this case a squarewave is the desired outcome so it's no problem if it goes into clipping, which is good and to be expected. The only potential issue I can see is high current draw. If the 74HC4060 draws more than 10mA or so, add a resistor between the output and LC circuit, try 100R to 1k first, to dial down the drive a little.


Try a discrete JFET if you like, but I don't see anything wrong with the MOSFETs inside the 74HC4060.

The circuit on the left is a Colpitts oscillator and the one on the right Hartley. U1 is an unbuffered CMOS inverter IC, i.e. pins 9 & 10 on the '4060.
https://assets.nexperia.com/documents/data-sheet/74HC_HCT4060.pdf


In the Hartley oscillator, vary C1 and make C2 much greater, than the minimum value of C1.

In the Colpitts oscillator either C1 or C2 can variable.

Thanks! That looks similar to the oscillator based on CD4069 linked by Zero999 (https://wiki.analog.com/university/courses/electronics/electronics-lab-21). I have ordered the CD74HCT4060 now so I will try your circuit out once it arrives.

Anyways, what inductor type and value do you suggest for combining with my 14-680pF varcap? And are regular old ceramic caps okay, or are any other type preferable?
The inductance depends on what output frequency you desire and will be divided by the counter inside the 74HC4060 (you've got the choice of 2n, where n can be from 4 to 10, or 12 to 14)  which is only guaranteed to work up to 25MHz at 5V, over the full temperature range. The inductor can't be too higher value because the resistance will be too high and its parasitic capacitance will dominate too much. You could try a common more choke, in which case the inductors will be coupled, so can be smaller, but it might be too lossy over a few MHz.

The formula to calculate the frequency for the Colpitts and Hartley oscillators can be found on Wikipedia:
https://en.wikipedia.org/wiki/Colpitts_oscillator
https://en.wikipedia.org/wiki/Hartley_oscillator

For the Colpitts oscillator, the variable capacitor can be either C1 or C2, with the fixed capacitor being around 330pF, around the middle value of the variable capacitor.

As I said, for the Hartley oscillator, C1 is the variable capacitor and C2 much greater, than the maximum value of C1, so 10nF will do, as it's much higher than 10nF.

I think the Hartley oscillator might be the better option, for this application, but try both.
« Last Edit: October 22, 2020, 09:00:24 pm by Zero999 »
 

Offline mag_therm

  • Frequent Contributor
  • **
  • Posts: 656
  • Country: us
Re: Stable and fast measurement of variable capacitor
« Reply #46 on: October 22, 2020, 10:58:45 pm »
Hi Zero, Agreed, mostly.
But for an accurate LCR oscillator, the limiting condition for maintenance of oscillation, is R = 0
The active device effectively puts a negative R.
If R < 0 as you "wack a circuit as hard as it can" the LCR oscillator will drive up to a rail and will become non-linear and clip, reducing accuracy.
If R > 0 damped, the oscillation will die out , moreover before that the frequency will skew, as the DE solutions show.
There is a "oscillator maintenance equation" that allows gain selection, and allows best accuracy.

If you put a probe on a well designed oscillator, you will see the ouput level within the linear range of the active device.
« Last Edit: October 22, 2020, 11:00:27 pm by mag_therm »
 

Offline CatalinaWOW

  • Super Contributor
  • ***
  • Posts: 5226
  • Country: us
Re: Stable and fast measurement of variable capacitor
« Reply #47 on: October 22, 2020, 11:33:03 pm »
Hi Zero, Agreed, mostly.
But for an accurate LCR oscillator, the limiting condition for maintenance of oscillation, is R = 0
The active device effectively puts a negative R.
If R < 0 as you "wack a circuit as hard as it can" the LCR oscillator will drive up to a rail and will become non-linear and clip, reducing accuracy.
If R > 0 damped, the oscillation will die out , moreover before that the frequency will skew, as the DE solutions show.
There is a "oscillator maintenance equation" that allows gain selection, and allows best accuracy.

If you put a probe on a well designed oscillator, you will see the ouput level within the linear range of the active device.

R identically equal to zero is impossible to maintain in a real linear circuit (and causes an interesting startup problem if you think about it).  The gain will change slightly with temperature, aging, supply voltages and a myriad of other things.  Real and well design oscillators either have a feedback loop controlling gain, or are slightly non-linear so that effective gain is reduced as amplitude increases.
 

Offline vk6zgo

  • Super Contributor
  • ***
  • Posts: 7584
  • Country: au
Re: Stable and fast measurement of variable capacitor
« Reply #48 on: October 23, 2020, 01:48:01 am »
If we are talking about L2 and/or L4, I believe I might have lost them unfortunately. As I said previously, I was completely set on replacing the whole analog circuit with stuff that I understand. Do you think there is a way of replacing those coils?

So  when in doubt, instead of spending a bit of time learning about analog circuitry, replace a perfectly good design with one which probably won't work as well?------Bravo!

OK, I've had my rant, here's a possible solution:-
Make or modify a rotary encoder, mount it on the capacitor shaft, read the angle it has moved through, program the Arduino to display that in frequency & all is well.
OK it entails a bit of mechanical work, but it gives you nice, clean, repeatable pulses to look at.
 

Offline Zero999

  • Super Contributor
  • ***
  • Posts: 19491
  • Country: gb
  • 0999
Re: Stable and fast measurement of variable capacitor
« Reply #49 on: October 23, 2020, 09:28:13 pm »
Hi Zero, Agreed, mostly.
But for an accurate LCR oscillator, the limiting condition for maintenance of oscillation, is R = 0
The active device effectively puts a negative R.
If R < 0 as you "wack a circuit as hard as it can" the LCR oscillator will drive up to a rail and will become non-linear and clip, reducing accuracy.
If R > 0 damped, the oscillation will die out , moreover before that the frequency will skew, as the DE solutions show.
There is a "oscillator maintenance equation" that allows gain selection, and allows best accuracy.

If you put a probe on a well designed oscillator, you will see the ouput level within the linear range of the active device.
I don't think I've every seen a nice sine wave from an oscillator made with a CMOS inverter, irrespective of the topology.

Real and well design oscillators either have a feedback loop controlling gain, or are slightly non-linear so that effective gain is reduced as amplitude increases.
Like a CMOS inverter, which has a lower gain, when the output voltage approaches either supply rail.

I plugged it into LTSpice using the HEF4007 model for the inverter with a 12V power supply and works over the 14pF to 680pF range. The Colpitts oscillator seems to require a lower ESR, than the Hartley, but it produces a better waveform, over the entire frequency range, not that it really matters.

 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf