Application of variable spacing planar capacitance sensor in inhomogeneous media detection

: In order to detect different non-uniform media, this thesis proposes a variable spacing type planar capacitance sensor, design the sensor hardware circuit system and PCB, experimental results show that the proposed planar capacitance sensor can realize the detection of different non-uniform media, non-uniform media detection provides a new method.


Introduction
Planar capacitance sensor is a capacitance sensor that utilizes the edge effect of capacitance. Planar capacitance sensors have the characteristics of simple structure, fast dynamic response and non-contact measurement, and have been widely used in nondestructive testing and water content measurement. Compared with X-ray, ultrasonic and other non-contact measurement methods, planar capacitance sensors have low cost, high efficiency and broad application prospects.
Planar capacitance sensors are used in many fields at home and abroad. Yu Zhenghui et al. optimized the parameters of the planar capacitance sensor and used the fitting curve to realize the quantitative evaluation of the defects of CFRP materials. Wang Beibei et al. optimized the structure of the sensor by studying the planar capacitance sensors of different structures and verified the effectiveness of the planar capacitance sensors for material flaw detection. Yang Liu et al. used the optimized planar capacitance sensor to measure the moisture content of grains, and the measurement error of the moisture content could be controlled at about 1.5% . Qu Huiqin et al. designed a non-contact low liquid level detection system based on a planar capacitance sensor, and measured the liquid level in the range of 0mm-100mm with a stable error of about 0.28%. Rashed H Bhuiyan et al. studied the structure of the planar capacitance sensor based on concrete moisture content detection, and the results show that the circular electrode structure can improve the signal strength and sensitivity of the sensor.
According to the properties of planar capacitance sensors, in the non-uniform medium, the required detection depth is small, such as defect detection, the sensor plate spacing should be small; If the detection depth is large, such as underground plant detection, the sensor plate spacing should be large. To solve the above problems, in order to enable the sensor to be applied to the detection of heterogeneous media in different scenarios, this thesis proposes a variable spacing planar capacitance sensor, and designs the hardware circuit system and PCB of the sensor. The experimental results show that the planar capacitance sensor proposed in the text can realize the detection of different heterogeneous media. The detection of heterogeneous media provides a new method.

Design of planar capacitance sensor
Planar capacitance sensor is composed of excitation electrode and induction electrode, which is essentially equivalent to opening the two plates of parallel plate capacitance sensor to both sides until the two plates are in the same horizontal plane. The two electrodes of the parallel plate capacitor sensor are placed relative to each other, and the electric field is evenly distributed in the middle of the plate, and the electric field lines at the edge are half spherical. Planar capacitance sensor is realized based on the edge effect of capacitance. When the capacitor plate is in the same horizontal plane, the electric field line expands to form a semi-spherical edge field, which penetrates the measured object. The change of the measured object's dielectric constant causes the change of the capacitance value. FIG. 1 shows the schematic diagram of parallel plate capacitance sensor and planar capacitance sensor. Because the electric field is concentrated near the plate, the smaller the plate spacing, the smaller the detection depth, and the larger the plate spacing, the greater the detection depth. Therefore, a planar capacitance sensor with variable spacing is designed in this thesis. The sensor can be divided into two parts, the left side has three capacitance plate as the measuring end, the plate through three 0Ω resistance wire to the back, connected to the measuring circuit through the socket. There is a capacitor plate on the right as the ground terminal, which is also wired to the back and connected to the measuring circuit through a socket. Each plate of the measuring end can form a pair of planar capacitance sensors with the plate of the grounding end. The 0Ω resistance can be removed at any time to select different plates of the measuring end. By controlling the distance between the measuring end and the grounding end of the plate, the distance can be variable.
The length and width of each plate are set as 7cm and 2cm, and the distance between the measured end plate and the grounded end plate is 5cm, 7cm and 9cm, respectively. Considering the influence of the external environment on the sensor measurement, a whole layer of copper is covered on the back of the sensor as a shield layer. All capacitor plates, wiring, components and shielding are completed on one PCB, making the sensor structure simpler. The sensor is connected with the measuring circuit in the way of socket, which also makes the sensor more flexible. The suitable capacitance sensor can be replaced according to different experimental environment, so as to realize the detection of different nonuniform medium scenes. The physical PCB diagram of this planar capacitance sensor is shown in Figure 2:

Selection of measurement circuit
In this thesis, the micro capacitance measurement circuit is used to realize the hardware measurement circuit. Micro capacitance measurement circuit mainly includes charge and discharge type, voltage time conversion type, AC excitation type, charge amplifier type and integrated circuit type. By comparing the above micro capacitance measurement circuits, it can be found that the integrated circuit type measurement circuit has the advantages of strong anti-interference ability, fast measurement speed, high resolution and high precision. Therefore, this thesis chooses IC micro capacitance measurement circuit to realize hardware measurement circuit.
Integrated circuit measurement circuit mainly through capacitance measurement chip to measure capacitance. With advances in microelectronics processing technology, electronics companies are integrating electrical components of capacitance detection circuits into chips, which are then used with capacitance sensors to quickly and accurately measure capacitance data. The integrated chip can realize high precision and high-resolution measurement, improve the anti-interference ability of the circuit and reduce the power consumption of the circuit.

Capacitor detection chip selection
At present, the commonly used capacitor detection chips mainly include AD7746, HT133, MS3110, PS021 and PCap01-AD. AD7746 and HT133 have a large measurement range and low accuracy, and are mainly used in the measurement environment with large capacitance changes [11][12][13]. The measurement accuracy and resolution of MS3110 chip are high, but the measurement speed is low and the measurement range is small, so it is not suitable for largescale and rapid measurement occasions [14][15]. PS021 measures the capacitance value by measuring the charging and discharging time of the capacitance under test using temporal digital conversion technology. However, its internal logic circuit is relatively complex, which is not conducive to design and development. PCap01-AD capacitance measurement accuracy, fast sampling speed, can compensate internal and external parasitic capacitance. It can measure internal capacitance up to 300pF by switching internal discharge resistance. It also has the ability to measure multiple capacitors and different types of capacitors, is a capacitive measurement chip with excellent functions.
PCap01-AD capacitance measurement chip has the following characteristics: (1) Under certain conditions, the accuracy is as high as 6aF; (2) The measurement frequency can be up to 500KHz; (3) The lowest power consumption is 4uA; (4) High temperature stability, temperature drift of 30aF per degree Celsius; (5) Up to 7 capacitance channels can be measured simultaneously; (6) With 4 sensor connection modes, can measure ordinary capacitance and differential capacitance; (7) External communication interface supports SPI and IIC communication; (8) single power supply; (9) It can be PWM or PDM output; (10) can be matched with a simple external working circuit. In summary, this thesis chooses PCap01-AD capacitance measurement chip as the main chip of the hardware circuit, and matches the planar capacitance sensor based on the finite element simulation results to realize the verification of the simulation experiment in Chapter 3. The system has the following functions: (1) The system can conduct non-contact and nondestructive detection of non-uniform medium, and can stably measure small capacitance changes caused by objects; (2) The system has the function of data processing. By adding the sliding average filtering algorithm, the interference noise to the signal is reduced and the accuracy of the data is improved; (3) The system has high integration, low power consumption and simple circuit structure.

Circuit design of capacitor data acquisition module
The PCap01-AD chip has four capacitor sensor connection modes. You can select the sensor connection mode based on the sensor type and measurement object. In this thesis, the earth mode is selected. In the ground mode, the PC0 pin of the chip is connected to the reference capacitor, and the other seven pins, PC1 to PC7, are connected to the capacitor sensor, which can process the data of a maximum of seven capacitor sensors. The sensor grounding mode is shown in Figure 3: Since the capacitance sensor designed in this thesis is of variable pitch type, considering that the logarithm of the sensor plate may increase in the subsequent research and expansion, the sensor grounding mode of the chip is selected in this thesis. The PC0 pin of the chip is connected to the reference capacitor Cre1, and Cx1, Cx2 and Cx3 respectively correspond to three capacitance plates at the measuring end of the capacitance sensor.
Capacitor data acquisition module uses SPI bus to communicate with main control chip STM32F103C8T6 to realize data transmission and command control of PCap01-AD chip. Since the OTP function of the chip is not used, the pin is grounded through the 470K pull-down resistance and the sensor common ground is isolated from the power ground to reduce circuit noise.

Circuit design of data processing module
In order to meet the requirements of low cost and low power consumption of the measurement system, the STM32F103C8T6 chip of ST Company is selected as the main control chip in this thesis. The chip is a 32-bit microprocessor with an ARM Cortex-M3 core architecture. It has a maximum operating frequency of 72MHz, single-cycle multiplication and hardware division, and can operate in -40 °C to 85°C. In addition, the chip also has up to nine communication interfaces, including two IIC interfaces, three USART interfaces, two SPI interface communication at speeds up to 18MB/s, one CAN interface and one USB2.0 full speed interface. Also integrated within the chip are two 12-bit ADCs with conversion time up to 1μs, three universal timers and one advanced timer, and a 7-channel DMA controller. The capacitor data acquisition module needs to use SPI bus to communicate with signal processing module. The rich peripheral interface of STM32F103C8T6 leaves the foundation for the expansion of system functions later. Meanwhile, the rich application cases and library functions of this chip greatly reduce the time cost of system development.

Hardware circuit PCB design
The main consideration in PCB design is to reduce the impact of parasitic capacitance on the measurement results. The placement of components and the layout of the circuit should also refer to this principle, and the route between capacitor plate and chip should be as short as possible. The overall PCB design of the measurement system is shown in Figure 4:

Experimental result
During the test, the sensor was fixed at a height of 2.2cm from the soil surface, and the distance between the sensor plates was set as 5cm, 7cm and 9cm, respectively. The absorbent sponge was buried in the soil at a depth of 0.2cm, 0.4cm, 0.6cm, 0.8cm, 1.0cm and 1.4cm, respectively. The influence of non-uniform medium surface on interior is reflected by the difference of sensor detection depth under different plate spacing.
To avoid water loss and control the water content of the sponge, wrap the sponge in a plastic sealable bag before it is buried in the soil. The scale is inserted vertically into the soil to control the depth of the object. During the test, different embedment depths of the object under different plate spacing are measured. The results of 10 measurements each time are taken as one set of data, with a total of 7 sets of data. The test results are shown in Table 1, Table 2 and

Conclusion
In this thesis, by studying the application of planar capacitance sensor in different scenarios, in order to enable the sensor to be applied to different detection depths in nonuniform media detection, a variable spacing planar capacitance sensor is proposed, and the design of the hardware circuit system and PCB is completed. Finally, the test experiment is carried out. The experimental results show that the sensor can meet the requirements of different detection depths, and provides a new method for the application of planar capacitance sensor in the scene with different detection depths, such as defect detection and underground plant detection.