Resonant pressure sensor digital measurement and control circuit
By designing a digital amplitude and phase dual closed-loop driving circuit in a resonant pressure sensor, and using AGC and PLL modules to achieve stable amplitude and phase control, the limitations of accuracy and miniaturization design under analog circuit driving are solved, and a high-precision and low-complexity pressure sensor system is realized.
Patent Information
- Application Number
- CN202411939394.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-26
- Publication Date
- 2025-05-30
AI Technical Summary
Driven by analog circuits, existing resonant pressure sensors are easily affected by the parameter drift of analog devices, resulting in driving amplitude and phase drift, limiting the accuracy and miniaturization of the pressure sensor, and at the same time output is square wave, which increases the complexity of the air pressure control system.
A digital amplitude and phase dual closed-loop driving circuit is designed to realize stable amplitude and phase control of the sensor through automatic gain control (AGC) and phase locked loop (PLL) modules, lock the resonant frequency and output binary code.
It effectively avoids the impact of analog device parameter drift on accuracy, improves the stability and accuracy of the sensor, realizes locking of resonant frequency and real-time output, and reduces the complexity of system design.
Smart Images

Figure CN120065800A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of digital measurement and control circuits for resonant pressure sensors, and relates to a digital measurement and control circuit for a resonant pressure sensor, and particularly to a digital dual closed-loop drive circuit for a resonant pressure sensor. Background Art
[0002] The principle of a resonant pressure sensor is to transfer the measured pressure to a resonator through a sensitive diaphragm, causing a change in the resonant frequency of the resonator, and indirectly detecting the measured pressure by detecting the frequency of the resonator. Therefore, keeping the resonator in a stable resonant state is a necessary condition for the pressure sensor to work. At present, most resonant pressure sensors maintain the resonant state of the resonator by means of a self-excited oscillation circuit loop, and this method is implemented by an analog circuit. Due to the parameter drift characteristics of the analog devices in the sensor circuit, it will cause the drift of the driving amplitude and phase of the resonant pressure sensor, which limits the accuracy of the pressure sensor to a certain extent. Moreover, analog devices occupy more space, resulting in the inability to further reduce the volume of the sensor. In addition, the output of the resonant pressure sensor is generally a square wave, and a pneumatic control system is required to collect the resonant square wave and perform further calculations to obtain the frequency, which brings a certain degree of complexity to the design of the pneumatic system.
[0003] In order to further improve the accuracy and miniaturization design of the sensor, etc., it is necessary to design a measurement and control circuit to further improve the accuracy of the resonant pressure sensor, further reduce the volume size, and at the same time have the functions of frequency calculation and digital output. Summary of the Invention
[0004] The present invention aims to solve at least one of the technical problems existing in the prior art or related technologies.
[0005] To this end, the present invention provides a digital measurement and control circuit for a resonant pressure sensor, which is realized by a digital amplitude and phase dual closed-loop drive circuit, enabling the sensor to perform resonant motion with a stable amplitude, and realizing the locking and output of the resonant frequency.
[0006] The technical solution of the present invention is as follows: providing a digital measurement and control circuit for a resonant pressure sensor, including a sensor core, a first chip unit, a second chip unit, a third chip unit, and a fourth chip unit, wherein:
[0007] The first chip unit includes an automatic gain control module AGC, a phase-locked loop control module PLL, SPI, and I2S. Among them, AGC includes an amplitude calculation module, a controller 1, and an amplitude control switch S2 connected in sequence. PLL includes a phase calculation module, a controller 2, a phase control switch S1, and DDS. The sensor core is respectively connected to the second chip unit and the third chip unit;
[0008] The sensor core outputs a detection signal. The first chip unit controls the second chip unit to collect the detection signal through the on-chip SPI peripheral, and then enters the amplitude calculation module for amplitude calculation and the phase calculation module for phase calculation respectively. The calculated amplitude is subtracted from the control input amplitude Vc and then input to Controller 1 to control the signal amplitude. The calculated phase is input to Controller 2 to control the signal frequency. When the control switches S1 and S2 are in the closed state, Controller 2 outputs a signal to the DDS. The output of the DDS is coupled with the output of Controller 1 to obtain the output of the first chip unit. The first chip unit sends the obtained output to the fourth chip unit to blindly transmit data outward in real time. In addition, the first chip unit also controls the third chip unit to generate a driving signal through I2S as the input of the sensor core.
[0009] When the system starts, S1 and S2 are in the open state and work in the frequency sweep mode to find the resonance frequency point. Then S1 and S2 are closed and work in the phase-locked mode to drive the sensor core to work in the resonance state with a stable amplitude.
[0010] Further, in the frequency sweep mode, the resonance frequency point is found in the following way:
[0011] Control the DDS to generate a signal S with a continuously changing frequency f 0 and input it to the sensor core through the third chip unit. The amplitude calculation module calculates the amplitude of the output of the sensor core. i First, judge whether the amplitude maximum point is found according to the algorithm criterion. If not, continue to sweep the frequency in the same direction. If so, make a secondary judgment. The secondary criterion is whether the frequency sweep interval reaches the accuracy requirement. If not, reverse the frequency sweep direction and reduce the frequency sweep interval to continuously approach the resonance frequency point of the sensitive core. If so, output the frequency f
[0012] 0 At this time, the f 0 is the resonance frequency of the sensitive core, that is, the resonance frequency point to be found.
[0013] Further, when working in the phase-locked mode, set the center frequency of the phase-locked loop to the resonance frequency of the sensitive core found by frequency sweeping. The phase-locked loop works to lock the phases of the detection signal and the driving signal at 90°.
[0014] Further, the first chip unit, the second chip unit, the third chip unit, and the fourth chip unit are respectively configured as an ARM chip, an ADC chip, a DAC chip, and an RS422 chip.
[0015] Further, Controller 1 is a PID controller.
[0016] Further, the expression of Controller 2 is designed as follows:
[0017]
[0018] ω 0 = 2πf 0
[0019] where ω is the angular frequency of the detection signal; k ω is the frequency gain; is the phase gain; ω 0 is the center frequency; f 0 is the resonant frequency of the sensitive core found in the frequency sweep mode.
[0020] Further, the amplitude calculation method is as shown in the following formula:
[0021]
[0022] In the formula: t is the time; is the expression of the detection signal; ω 1 is the frequency of the detection signal; is the phase of the detection signal; A is the amplitude of the detection signal.
[0023] Further, the phase calculation method is as shown in the following formula:
[0024]
[0025] In the formula: t is the time; is the expression of the detection signal; ω 1 is the frequency of the detection signal; is the phase of the detection signal; A is the amplitude of the detection signal; is the expression of the unit drive signal with an amplitude of 1; ω 2 is the frequency of the drive signal; is the phase of the drive signal; is the phase gain; is the phase difference; when it is zero, it indicates successful phase locking, the phase difference between the drive signal and the detection signal is 90°, satisfying the resonance condition, and the resonator operates in the resonance state.
[0026] In the above technical solution, except for the sensor core and its interface circuit which are analog devices, the rest of the circuits are all implemented with digital circuits, which can effectively avoid the influence of analog device parameter drift on the pressure measurement accuracy. Designing a sweep control algorithm can quickly calculate the structural characteristic parameters of the sensor core, and then adjust the parameters of the drive control system to ensure that the sensor starts normally and stably in any environment, improving the reliability of the pressure sensor. An AGC phase-locked drive method is adopted for the closed-loop control of the amplitude and phase of the drive loop, ensuring the stability of the amplitude and phase. At the same time, the frequency can be calculated in real time, and the calculation result is output in binary code, reducing the design complexity of the overall system. The present invention is implemented through a digital amplitude and phase dual closed-loop drive circuit, enabling the sensor to perform resonant motion with a stable amplitude and achieving the locking and output of the resonant frequency. BRIEF DESCRIPTION OF THE DRAWINGS
[0027] The accompanying drawings included are used to provide a further understanding of the embodiments of the present invention, which form a part of the specification, are used to illustrate the embodiments of the present invention, and together with the written description are used to explain the principles of the present invention. Obviously, the drawings in the following description are only some embodiments of the present invention, and those of ordinary skill in the art can obtain other drawings based on these drawings without creative efforts.
[0028] Figure 1 is a schematic diagram of a digital measurement and control circuit solution for a resonant pressure sensor;
[0029] Figure 2 is a schematic diagram of an approximation sweep algorithm;
[0030] Figure 1 In the figure: PLL is a phase-locked loop control module; AGC is an automatic gain control module; Controller 1 is an amplitude controller; Controller 2 is a frequency controller; I is the in-phase signal and also the detection signal; Q is the quadrature signal and also a unit drive signal with an amplitude of 1; A is the amplitude of the detection signal; is the phase difference of the detection signal; S2 is an amplitude control switch; S1 is a phase control switch; f is the calculated frequency.
[0031] Figure 2 In the figure: Δf is the input signal frequency interval between the front and rear time points, k is the signal frequency change direction, n is the current time point, A n is the calculated amplitude at the current time point, S i is the input signal, f 0 is the input signal frequency, ω 0 is the input signal angular frequency, T is the sampling period. DETAILED DESCRIPTION OF THE EMBODIMENTS
[0032] It should be noted that, without conflict, the embodiments in the present application and the features in the embodiments may be combined with each other. The following will clearly and completely describe the technical solutions in the embodiments of the present invention with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all the embodiments. The description of at least one exemplary embodiment below is actually only illustrative and in no way limits the present invention and its application or use. All other embodiments obtained by those of ordinary skill in the art based on the embodiments of the present invention without creative efforts belong to the scope of protection of the present invention.
[0033] It should be noted that the terms used herein are only for describing specific embodiments and are not intended to limit the exemplary embodiments according to the present application. As used herein, unless the context clearly indicates otherwise, the singular form is also intended to include the plural form. In addition, it should be understood that when the terms "comprise" and / or "include" are used in this specification, they indicate the presence of features, steps, operations, devices, components, and / or combinations thereof.
[0034] Unless otherwise specifically stated, the relative arrangements, numerical expressions, and numerical values of the components and steps set forth in these embodiments do not limit the scope of the present invention. At the same time, it should be understood that, for the sake of convenience of description, the dimensions of the various parts shown in the drawings are not drawn in actual proportional relationships. Technologies, methods, and devices known to those of ordinary skill in the relevant art may not be discussed in detail, but where appropriate, the said technologies, methods, and devices should be regarded as part of the authorized specification. In all the examples shown and discussed here, any specific value should be construed as merely exemplary and not as a limitation. Therefore, other examples of the exemplary embodiments may have different values. It should be noted that like reference numerals and letters denote like items in the following drawings, and thus, once an item is defined in one drawing, it does not need to be further discussed in subsequent drawings.
[0035] As Figure 1 shown, in an embodiment of the present invention, a digital measurement and control circuit for a resonant pressure sensor is provided, including a sensor core, a first chip unit, a second chip unit, a third chip unit, and a fourth chip unit, where: the first chip unit includes an automatic gain control module AGC, a phase-locked loop control module PLL, SPI, and I2S. Among them, the AGC includes an amplitude calculation module, a controller 1, and an amplitude control switch S2 connected in sequence, and the PLL includes a phase calculation module, a controller 2, a phase control switch S1, and a DDS; the sensor core is respectively connected to the second chip unit and the third chip unit;
[0036] The sensor core outputs a detection signal. The first chip unit controls the second chip unit to collect the detection signal through the on-chip SPI peripheral, and the collected signal enters the amplitude calculation module for amplitude calculation and the phase calculation module for phase calculation respectively. The calculated amplitude (i.e., the amplitude of the detection signal) is subtracted from the control input amplitude Vc and then input to Controller 1 to control the signal amplitude. The calculated phase (i.e., the phase of the detection signal) is input to Controller 2 to control the signal frequency. When control switches S1 and S2 are in the closed state, Controller 2 outputs a signal to the DDS. The output of the DDS is coupled (multiplied) with the output of Controller 1 to obtain the output of the first chip unit, and the first chip unit sends the obtained output to the fourth chip unit to blindly transmit data outward in real time. In addition, the first chip unit also controls the third chip unit to generate a driving signal through I2S as the input of the sensor core.
[0037] When the system starts, S1 and S2 are in the open state and operate in the frequency sweep mode to find the resonance frequency point. Then S1 and S2 are closed and operate in the phase-locked mode to drive the sensor core to work in the resonance state with a stable amplitude.
[0038] The amplitude A of the detection signal is obtained by multiplying the I signal by the I signal and then passing through a low-pass filter, which is called the amplitude calculation process. After the calculated amplitude is subtracted from Vc, it passes through Controller 1 to control the signal amplitude. The phase difference of the detection signal is obtained by multiplying the I signal by the Q signal and then passing through a low-pass filter, which is called the phase calculation process. The calculated phase is input to Controller 2 to control the signal frequency.
[0039] For example, the first chip unit, the second chip unit, the third chip unit, and the fourth chip unit are respectively configured as an ARM chip, an ADC chip, a DAC chip, and an RS422 chip. That is, the output signal of the sensor core is an analog signal. The ARM chip controls the ADC chip to collect the analog signal through the on-chip SPI peripheral and converts the analog signal into a digital signal. In addition, the calculation unit of the ARM chip runs embedded control software to implement frequency sweep control and AGC phase-locked drive control of the core, obtains a control signal through digital operations, and then the on-chip I2S peripheral of the ARM chip controls the DAC chip to generate an analog signal as the input of the sensor core. The RS422 chip blindly transmits the calculation result outward at a certain frequency and in a certain frame format (that is, the ARM chip sends the calculation result to the RS422 chip through the USART).
[0040] In this embodiment, as Figure 2 shown, the resonance frequency point is found in the frequency sweep mode by the following method:
[0041] Control the DDS to generate a signal S with a continuously changing frequency f 0 i, and is input into the sensor core through the third chip unit, and the amplitude calculation module calculates the amplitude of the output of the sensor core;
[0042] First, judge whether the maximum amplitude point is found according to the algorithm criterion. If not, continue to sweep the frequency in the same direction; if so, make a secondary judgment again. The secondary criterion is whether the sweep frequency interval reaches the accuracy requirement. If not, reverse the sweep direction and reduce the sweep frequency interval to continuously approach the resonant frequency point of the sensitive core; if so, output the angular frequency ω 0 , and the ω at this time 0 is the resonant angular frequency of the sensitive core, that is, the resonant frequency point to be found.
[0043] In the embodiment of the present invention, when working in the phase-locked mode, the center frequency of the phase-locked loop is set to the resonant frequency of the sensitive core found by sweeping the frequency, and the phase-locked loop works to lock the phase difference between the detection signal and the drive signal to 90°.
[0044] That is, S1 and S2 are disconnected, and the frequency sweeping mode is first performed to find the approximate resonant frequency point of the core structure by judging the detected amplitude; S1 and S2 are closed, the center frequency of the phase-locked loop is set to the resonant frequency found by sweeping the frequency, the phase-locked loop works, and the phase difference between the detection signal and the drive signal is locked to 90° to ensure the resonant state; at the same time, AGC controls the detection signal to work at a stable amplitude by adjusting the amplitude of the drive signal.
[0045] Preferably, the controller 1 is a PID controller.
[0046] Preferably, the expression of the controller 2 is designed as follows:
[0047]
[0048] ω 0 = 2πf 0
[0049] where ω is the angular frequency of the detection signal; k ω is the frequency gain; is the phase gain; ω 0 is the center frequency; f 0 is the resonant frequency of the sensitive core found in the frequency sweeping mode.
[0050] That is, through the resonant frequency of the resonant state of the sensor core in the phase-locked mode can be calculated.
[0051] In this embodiment, the amplitude calculation method is shown in the following formula:
[0052]
[0053] In the formula: t is time; is the detection signal expression; ω 1 is the detection signal frequency; is the detection signal phase; A is the detection signal amplitude.
[0054] After the right - hand side term of the above equation passes through a low - pass filter, it is multiplied by 2 and then square - rooted to calculate the amplitude A of the detection signal.
[0055] In this embodiment, the phase calculation method is as shown in the following equation:
[0056]
[0057] In the formula: t is time; is the detection signal expression; ω 1 is the detection signal frequency; is the detection signal phase; A is the detection signal amplitude; is the drive signal expression; ω 2 is the drive signal frequency; is the drive signal phase; is the phase gain; is the phase difference; when it is zero, it indicates that the phase - locked is successful, the drive signal and the detection phase differ by 90°, satisfying the resonance condition, and the resonator works in the resonance state.
[0058] Among them, the above - mentioned phase calculation is obtained through simplification. That is, before simplification, the phase calculation method is as follows:
[0059]
[0060] After the right - hand side of the above equation passes through a low - pass filter to filter out high - frequency components, considering that when in the phase - locked state ω 1 = ω 2 , and is relatively close and almost equal, it can be simplified to
[0061]
[0062] In summary, in the digital measurement and control scheme of the resonant pressure sensor in the embodiment of the present invention, except that the sensor core and its interface circuit are analog devices, the rest of the circuits are all implemented by digital circuits, which can effectively avoid the influence of analog device parameter drift on the pressure measurement accuracy. Designing a sweep - frequency control algorithm can quickly calculate the structural characteristic parameters of the sensor core, and then adjust the parameters of the drive control system to ensure that the sensor starts normally and stably in any environment, improving the reliability of the pressure sensor. Adopting the AGC phase - locked drive method for closed - loop control of the amplitude and phase of the drive loop ensures the stability of the amplitude and phase. At the same time, the frequency can be calculated in real - time, and the calculation result is output in binary code, reducing the design complexity of the overall system.
[0063] Features described and / or illustrated above for one embodiment can be used in the same or similar manner in one or more other embodiments, and / or combined with or replace features in other embodiments.
[0064] It should be emphasized that the term "comprising / including" as used herein refers to the presence of features, wholes, steps or components, but does not preclude the presence or addition of one or more other features, wholes, steps, components or combinations thereof.
[0065] The above method of the present invention can be implemented by hardware or by a combination of hardware and software. The present invention relates to such a computer-readable program that, when executed by a logic component, can cause the logic component to implement the device or component described above, or cause the logic component to implement the various methods or steps described above. The present invention also relates to a storage medium for storing the above program, such as a hard disk, a magnetic disk, an optical disk, a DVD, a flash memory, etc.
[0066] Many features and advantages of these embodiments are apparent from this detailed description, and thus the appended claims are intended to cover all such features and advantages of these embodiments that fall within their true spirit and scope. In addition, since many modifications and changes are readily envisioned by those skilled in the art, the embodiments of the present invention are not to be limited to the exact structures and operations illustrated and described, but may cover all suitable modifications and equivalents that fall within their scope.
[0067] The parts not detailed in the present invention are well-known techniques to those skilled in the art.
Claims
1. A resonant pressure sensor digital measurement and control circuit, characterized in that: The circuit includes a sensor core, a first chip unit, a second chip unit, a third chip unit and a fourth chip unit, wherein: The first chip unit includes an automatic gain control module AGC, a phase-locked loop control module PLL, SPI and I2S, wherein the AGC includes an amplitude solver module, a controller 1 and an amplitude control switch S2 connected in sequence, and the PLL includes a phase solver module, a controller 2, a phase control switch S1 and a DDS connected in sequence; the sensor core is connected to the second chip unit and the third chip unit respectively; The sensor core outputs a detection signal, and the first chip unit controls the second chip unit through the on-chip SPI peripheral to collect the detection signal, and enters the amplitude solution module for amplitude solution and the phase solution module for phase solution respectively, and the obtained solution amplitude and the control input amplitude Vc are input to the controller 1 after being subtracted to control the signal amplitude; the obtained solution phase is input to the controller 2 to control the signal frequency; when the control switches S1 and S2 are closed, the controller 2 outputs a signal to the DDS, and the DDS output is coupled with the output of the controller 1 to obtain the output of the first chip unit, and the first chip unit sends the obtained output to the fourth chip unit, and blindly sends data out in real time; in addition, the first chip unit also controls the third chip unit through I2S to generate a drive signal as the input of the sensor core; When the system starts, S1 and S2 are disconnected and work in the sweep mode to find the resonant frequency point; then S1 and S2 are closed and work in the phase-locked mode to drive the sensor core to work in the resonant state with a stable amplitude.
2. A resonant pressure sensor digital measurement and control circuit according to claim 1, characterized in that: Find the resonant frequency point in sweep mode by the following method: Control DDS to generate a signal S with a changing frequency f0 i , and input to the sensor core through the third chip unit, and the amplitude calculation module performs amplitude calculation on the output of the sensor core; First, determine whether the maximum amplitude point is found according to the algorithm criteria. If not, continue to sweep the frequency in the same direction; if yes, make a second judgment again, and the secondary judgment criterion is whether the sweep frequency interval meets the accuracy requirement. If not, flip the sweep direction and reduce the sweep interval to continuously approach the resonant frequency point of the sensitive core; if yes, output the frequency f0, and f0 at this time is the resonant frequency of the sensitive core, that is, the resonant frequency point being sought.
3. A resonant pressure sensor digital measurement and control circuit according to claim 1 or 2, characterized in that: When working in the phase-locked mode, the center frequency of the phase-locked loop is set to the sensitive core resonance frequency found by frequency sweeping, and the phase-locked loop works to lock the detection signal and the drive signal to a phase of 90°.
4. A resonant pressure sensor digital measurement and control circuit according to claim 1, characterized in that: The first chip unit, the second chip unit, the third chip unit and the fourth chip unit are respectively configured as an ARM chip, an ADC chip, a DAC chip and an RS422 chip.
5. A resonant pressure sensor digital measurement and control circuit according to any one of claims 1 to 3, characterized in that: The controller 1 is a PID controller.
6. A resonant pressure sensor digital measurement and control circuit according to any one of claims 1 to 3, characterized in that: The expression of the controller 2 is designed as follows: ω0=2πf0 Where, ω is the angular frequency of the detection signal; k ω is the frequency gain; is the phase gain; ω0 is the center frequency; f0 is the resonance frequency of the sensitive core found in the sweep frequency mode.
7. A resonant pressure sensor digital measurement and control circuit according to claim 1 or 2, characterized in that: The amplitude calculation method is shown in the following formula: Where: t is time; is the expression of detection signal; ω1 is the detection signal frequency; is the detection signal phase; A is the detection signal amplitude.
8. The digital measurement and control circuit of a resonant pressure sensor according to claim 3, characterized in that: The phase solution method is shown in the following formula: Where: t is time; is the expression of detection signal; ω1 is the detection signal frequency; is the detection signal phase; A is the detection signal amplitude; is the unit driving signal expression with an amplitude of 1; ω2 is the driving signal frequency; is the driving signal phase; is the phase gain; is the phase difference; when it is zero, It indicates that the phase locking is successful, the phase difference between the driving signal and the detection signal is 90°, the resonance condition is met, and the resonator works in the resonant state.
Citation Information
Cited By
Wireless transmission wall turbulence pulsating pressure surface array measurement system based on FPGA
CN120274989A