NivaarExam PrepOfficial exam papers ↗

22-Agric-A5 Principles of Instrumentation · December 2018

Question 4 of 7: Capacitive Sensing & the Hysteresis Oscillator

Nivaar worked solution (AI-drafted; not reviewed by a licensed engineer)

Notes on this paper

Paper format. 04-Agric-A5 Principles of Instrumentation, National Exams December 2018 — a three-hour open-book exam; any non-communicating calculator is permitted. Questions 1 and 2 are compulsory (20 marks each); candidates then choose any three (3) of Questions 3-7 (20 marks each) for a 100-mark paper. All seven questions are worked here.

Reference texts. E.O. Doebelin, Measurement Systems: Application and Design, 5th ed. (calibration, standards, static/dynamic sensor characteristics, second-order step response, sampling and ADCs); J.P. Bentley, Principles of Measurement Systems, 4th ed. (accuracy vs. precision, error propagation, signal conditioning); P. Horowitz and W. Hill, The Art of Electronics, 3rd ed. (Johnson noise, CMRR, ADC architectures, anti-aliasing, op-amp signal conditioning); J. Fraden, Handbook of Modern Sensors: Physics, Designs, and Applications, 5th ed. (thermistors, capacitive sensors, photodetectors); D.A. Skoog, F.J. Holler and S.R. Crouch, Principles of Instrumental Analysis, 7th ed. (detection limits, selectivity, optical sensing).

Question 4: Capacitive Sensing & the Hysteresis Oscillator (20 marks)

Question text not reproduced: the examination questions are © Engineers and Geoscientists BC. Open the official past paper (linked at the top of this page) to read the question, then follow the worked solution below.

a) This circuit is a relaxation (astable) oscillator built around a Schmitt-trigger comparator with an $RC$ timing network, and its output is a square wave whose frequency encodes the sensor capacitance $C_{sens}$.

+ − Vout Rfeedback Rhyst Rref Csens Hysteresis (relaxation) oscillator
Fig. Q4(a) — positive feedback ($R_{feedback}$, $R_{hyst}$) sets the Schmitt thresholds; the $R_{ref}$–$C_{sens}$ path charges toward $V_{out}$ and re-triggers the comparator each time it crosses a threshold.

Given. Output saturation levels $V_{sat}=\pm10\,\text{V}$; positive feedback divider $R_{feedback}$ (output to non-inverting input) and $R_{hyst}$ (non-inverting input to ground); negative path $R_{ref}$ (output to inverting input) charging $C_{sens}$ (inverting input to ground).

Find. The oscillation period/frequency as a function of $C_{sens}$, and the qualitative operating principle.

Approach. Find the Schmitt thresholds set by the positive-feedback divider, then solve the exponential charging of $C_{sens}$ through $R_{ref}$ between successive threshold crossings.

  1. Switching thresholds. The positive-feedback divider sets the non-inverting input to a fraction $\beta=R_{hyst}/(R_{hyst}+R_{feedback})$ of whichever rail the output currently sits at, so the comparator flips whenever the capacitor voltage crosses $\pm V_{th}$ with $$V_{th}=\beta V_{sat}.$$
  2. Capacitor charging between flips. With the output pinned at $+V_{sat}$, $C_{sens}$ charges through $R_{ref}$ toward $+V_{sat}$ starting from $-V_{th}$ (where it landed at the last flip): $$v_C(t)=V_{sat}-(V_{sat}+V_{th})e^{-t/(R_{ref}C_{sens})}.$$ The output flips again the instant $v_C$ reaches $+V_{th}$; solving for that time and doubling it by symmetry (the discharge half-cycle is identical) gives the period $$\boxed{T=2R_{ref}C_{sens}\ln\!\left(\dfrac{1+\beta}{1-\beta}\right)},\qquad f=\dfrac{1}{T}.$$
  3. Response to the sensor capacity. Everything in the boxed expression except $C_{sens}$ is a fixed circuit constant, so the period is directly proportional to $C_{sens}$: a larger sensor capacitance charges more slowly through the same $R_{ref}$, taking longer to cross the threshold and lengthening the period (lowering the output frequency). Measuring the oscillator's output frequency (or period) with a counter and inverting the boxed relation therefore gives $C_{sens}$, and with it — via the sensor's known geometry and the dielectric constant of the sample — the water content being measured.

The circuit is self-running: each output transition immediately restarts the opposite charging ramp, so once triggered it free-runs indefinitely without needing any external clock, continuously reporting the sensor capacitance as a frequency that is easy to count digitally.

b) A cylindrical container with a grounded outer wall and a central rod electrode forms a coaxial capacitor, $$C=\dfrac{2\pi\varepsilon_0\varepsilon_r L}{\ln(b/a)},$$ whose value depends on the dielectric constant $\varepsilon_r$ of whatever fills the annular gap and is otherwise fixed by the sensor's own geometry ($a$, $b$, $L$) — a simple, calculable, and highly repeatable relationship. Grounding the outer wall also makes it act as an electrostatic shield, confining the sensing field to the annular gap and rejecting external interference, and it eliminates the fringing-field edge effects that complicate a parallel-plate design.

c) The measured capacitance depends on the effective dielectric constant of the material filling the gap between the electrodes, which for grain is a mixture of solid grain (moderate $\varepsilon_r$), water (very high $\varepsilon_r$), and air (low $\varepsilon_r$). How densely the grain is packed changes the volume fraction of air versus solid/water in the sensing volume independently of the grain's actual moisture content, so loose versus tightly-packed grain of the identical moisture content will read differently unless packing (bulk density) is controlled or separately measured and corrected for.

d) The same coaxial or parallel-plate capacitive principle measures liquid level (dielectric or effective plate-area changes with fill height), proximity or displacement/position, relative humidity (a hygroscopic dielectric film whose $\varepsilon_r$ changes with absorbed moisture), pressure (a flexing diaphragm changing the plate gap), and material thickness or composition sensing wherever the property of interest correlates with dielectric constant.

ItemResult
Schmitt threshold$V_{th}=\beta V_{sat}$, $\beta=R_{hyst}/(R_{hyst}+R_{feedback})$
Oscillation period$T=2R_{ref}C_{sens}\ln[(1+\beta)/(1-\beta)]$ — proportional to $C_{sens}$