Vibrating wire signal identification device
By designing a vibrating string signal recognition device combining time domain method and frequency domain method, using a microcontroller and a variety of signal processing modules, the problems of low measurement accuracy and high system cost in the prior art are solved. High-precision frequency measurement is achieved.
Patent Information
- Application Number
- CN202421443212.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Utility models(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-24
- Publication Date
- 2025-02-18
- Estimated Expiration
- 2034-06-24
AI Technical Summary
The existing vibrating string signal measurement methods are not very accurate when facing weak signals or external interference, and have high system cost, high requirements for algorithms and processors, and time-frequency correction algorithms are prone to errors when sampling in integer multiples.
A vibrating string signal recognition device is designed, combining time domain method and frequency domain method to realize preliminary processing and digital conversion of vibrating string signal through a microcontroller, signal preliminary processing module, analog-to-digital converter and zero crossing detection circuit. and square wave conversion, the frequency value is calculated separately, and combined with the advantages of the two methods, high-precision frequency measurement is achieved.
Without increasing cost and system complexity, high-precision frequency measurements within the entire signal bandwidth are achieved, the ability to identify weak signals is improved, and the requirements for processor memory and computing power are reduced.
Smart Images

Figure CN222506434U_ABST
Abstract
Description
Technical Field
[0001] The utility model relates to the technical field of industrial monitoring, in particular to a vibrating string signal recognition device. Background Art
[0002] Currently, there are two main methods for measuring signals from vibrating string sensors: time domain measurement and frequency domain measurement.
[0003] The time domain method mainly converts the vibrating string signal after shaping (amplification, filtering, waveform transformation, etc.) into a frequency value by measuring the number of cycles or pulse width of the signal. The advantages of this method are simplicity and low cost, but the disadvantage is that the measurement accuracy is not high when the original signal amplitude is weak or is subject to external interference;
[0004] The frequency domain method mainly involves amplifying the original vibrating string signal appropriately, sampling it through an analog-to-digital converter, obtaining a set of discrete time domain data, and then transforming it through FFT to obtain the spectrum of the signal, and obtaining the frequency value of the signal through a certain selection algorithm. The advantage of this method is that it can obtain high-precision frequency values based on the FFT algorithm through a correction algorithm, and it has greater advantages than the time domain method in identifying weak signals; the disadvantage is that the system cost is high, there are requirements for the algorithm, there are certain requirements for the processor's memory and computing power, and there are high requirements for the signal purity of the sensor. When the signal output by the sensor approximates the energy distribution of a narrowband signal, and when sampling at integer multiples, the correction algorithm of this method will produce certain errors. Utility Model Content
[0005] Based on this, the purpose of the utility model is to provide a vibrating string signal recognition device to solve the deficiencies in the prior art.
[0006] To achieve the above object, the utility model provides a vibrating string signal recognition device, comprising a microcontroller, and a signal preliminary processing module, an analog-to-digital converter, and a zero-crossing detection circuit connected to the microcontroller;
[0007] The signal preliminary processing module is used to perform preliminary processing on the vibrating string signal to obtain a preliminary signal;
[0008] The analog-to-digital converter is connected to the preliminary processing module, and the analog-to-digital converter is used to convert the preliminary signal into a digital signal;
[0009] The zero-crossing detection circuit is connected to the preliminary processing module, and the zero-crossing detection circuit is used to convert the preliminary signal into a square wave with the same frequency;
[0010] The microcontroller is used to calculate corresponding frequency values according to the digital signal and the square wave respectively;
[0011] The preliminary processing module includes a signal gain configuration unit and an analog bandpass filtering unit connected to each other, and the signal gain configuration unit is connected to the analog-to-digital converter and the zero-crossing detection circuit through the analog bandpass filtering unit.
[0012] The beneficial effects of the utility model are as follows: the vibrating string signal is preliminarily processed by the preliminary processing module to obtain a preliminary signal; when the vibrating string signal is relatively strong, the preliminary signal is converted by the analog-to-digital converter to obtain a digital signal, and then the microcontroller calculates the digital signal to obtain a frequency value; when the vibrating string signal is relatively weak, the preliminary signal is converted by the zero-crossing detection circuit to obtain a square wave of the same frequency, and then the microcontroller calculates the square wave to obtain a corresponding frequency value, and only processes it separately during terminal signal conditioning, so as to combine the advantages of the two measurement methods of the time domain method and the frequency domain method, and realize high-precision frequency measurement within the entire signal bandwidth without increasing the cost and system complexity.
[0013] Preferably, the signal gain configuration unit is connected to the microcontroller via a configuration pin, and the configuration pin is located on the microcontroller.
[0014] Preferably, the signal gain configuration unit comprises a programmable amplifier, the programmable amplifier is provided with a digital pin, and the programmable amplifier is used to amplify the signal and configure the gain of the vibrating string signal through the digital pin.
[0015] Preferably, the analog bandpass filtering unit includes an active low-pass filter and an active high-pass filter connected to each other, the signal output by the signal gain configuration unit passes through the active low-pass filter and the active high-pass filter in sequence, the active high-pass filter includes a first output end and a second output end, and the first output end and the second output end are respectively connected to the analog-to-digital converter and the zero-crossing detection circuit.
[0016] Preferably, the sampling rate of the analog-to-digital converter is 8Ksps-16Ksps.
[0017] Preferably, the analog-to-digital converter is connected to the microcontroller via a digital interface.
[0018] Preferably, the zero-crossing detection circuit comprises a voltage comparator, and the voltage comparator is used to filter out part of the interference around the threshold.
[0019] Additional aspects and advantages of the present invention will be given in part in the following description, and in part will become apparent from the following description, or will be learned through the practice of the present invention. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] Figure 1 A structural block diagram of a vibrating string signal recognition device provided by an embodiment of the utility model;
[0021] Figure 2 A circuit diagram of a signal gain configuration unit provided in an embodiment of the utility model;
[0022] Figure 3 A circuit diagram of a zero-crossing detection circuit provided in an embodiment of the utility model.
[0023] Description of main component symbols:
[0024] 10. Microcontroller; 21. Signal gain configuration unit; 22. Analog bandpass filter unit; 30. Analog-to-digital converter; 40. Zero-crossing detection circuit.
[0025] The following specific implementation manner will further illustrate the present invention in conjunction with the above-mentioned drawings. DETAILED DESCRIPTION
[0026] In order to facilitate the understanding of the present invention, the present invention will be described more fully below with reference to the relevant drawings. Several embodiments of the present invention are given in the drawings. However, the present invention can be implemented in many different forms and is not limited to the embodiments described herein. On the contrary, the purpose of providing these embodiments is to make the disclosure of the present invention more thorough and comprehensive.
[0027] It should be noted that when an element is referred to as being "fixed to" another element, it may be directly on the other element or there may be a central element. When an element is considered to be "connected to" another element, it may be directly connected to the other element or there may be a central element at the same time. The terms "vertical", "horizontal", "left", "right" and similar expressions used herein are for illustrative purposes only.
[0028] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by those skilled in the art in the technical field of the present invention. The terms used herein in the specification of the present invention are only for the purpose of describing specific embodiments and are not intended to limit the present invention. The term "and / or" used herein includes any and all combinations of one or more related listed items.
[0029] See also Figure 1 , is a vibrating-string signal recognition device in an embodiment of the utility model, comprising a microcontroller 10 , a preliminary signal processing module, an analog-to-digital converter 30 and a zero-crossing detection circuit 40 .
[0030] Among them: the signal preliminary processing module, the analog-to-digital converter 30 and the zero-crossing detection circuit 40 are all connected to the microcontroller 10, the signal preliminary processing module is used to perform preliminary processing on the vibrating string signal to obtain a preliminary signal, the analog-to-digital converter 30 is connected to the preliminary processing module, the analog-to-digital converter 30 is used to convert the preliminary signal into a digital signal, the zero-crossing detection circuit 40 is connected to the preliminary processing module, the zero-crossing detection circuit 40 is used to convert the preliminary signal into a square wave of the same frequency, the microcontroller 10 includes a first calculation module and a second calculation module, the first calculation module is used to calculate the corresponding frequency value according to the digital signal, and the second calculation module is used to calculate the corresponding frequency value according to the square wave.
[0031] It can be understood that when the vibrating string signal is strong, the preliminary signal is converted by the analog-to-digital converter 30 to obtain a digital signal, and then the microcontroller 10 calculates the frequency value for the digital signal, which is equivalent to measuring the frequency value by the frequency domain method. When the vibrating string signal is weak, the preliminary signal is converted by the zero-crossing detection circuit 40 to obtain a square wave of the same frequency, and then the microcontroller 10 calculates the corresponding frequency value for the square wave, which is equivalent to measuring the frequency value by the time domain method. That is to say, the vibrating string signal identification device achieves the highest efficiency and highest accuracy measurement of the vibrating string signal by combining the advantages of the time domain method and the frequency domain method.
[0032] In this embodiment, the signal preliminary processing module includes a signal gain configuration unit 21 and an analog bandpass filtering unit 22 connected to each other. The signal gain configuration unit 21 is connected to the analog-to-digital converter 30 and the zero-crossing detection circuit 40 through the analog bandpass filtering unit 22 .
[0033] It should be noted that the signal gain configuration unit 21 is connected to the microcontroller 10 via a configuration pin, and the configuration pin is located on the microcontroller 10. It can be understood that the gain control of the vibrating string signal and the amplification signal operation are implemented through the configuration pin of the microcontroller 10 to obtain a suitable signal-to-noise ratio, which is convenient for subsequent circuit processing and identification.
[0034] In this embodiment, if Figure 2 As shown, the signal gain configuration unit 21 includes a programmable amplifier (indicated by U1), which is used to amplify and configure the gain of the vibrating string signal. The gain is achieved by combining the digital pins CH1_PGA_A0 and CH1_PGA_A1 to achieve 1, 10, 100, and 1000 times amplification. The working process of the programmable amplifier is that the microcontroller 10 calculates the signal-to-noise ratio based on the signal power spectrum measured by the frequency domain method. When the signal-to-noise ratio is low, the microcontroller 10 changes the gain of U1 by configuring the pin to increase the signal amplification factor, thereby improving the signal-to-noise ratio, so as to facilitate the correct recognition of the preliminary signal.
[0035] It should be noted that if Figure 2As shown, the signal gain configuration unit 21 also includes an RFI radio frequency filter circuit, which is composed of two resistors (denoted by characters R6 and R7 respectively) and three capacitors (denoted by characters C9, C19, and C20 respectively), wherein R6, R7 and C9, C20 form a common-mode radio frequency filter circuit (R6=R7=R, C9=C20=Cc), and the cut-off frequency is f=1 / 2πRCc; R6, R7 and C9, C19, C20 form a differential-mode radio frequency filter circuit (C19=Cd), and the cut-off frequency is f=1 / 2πR(Cc+2Cd); R5 and R8 provide a bias current DC loop for the programmable amplifier U1 to ensure its stable operation; R1, R2, R3, and R4 are gain setting resistors of U1, and the gain of U1 is set to 1, 10, 100, and 1000 through the four logic combinations of CH1_PGA_A0 and CH1_PGA_A1.
[0036] In this embodiment, the analog bandpass filter unit 22 is responsible for filtering out the common power frequency interference in the measurement environment and the interference and noise outside the signal bandwidth to ensure the signal-to-noise ratio and quality of the vibrating string signal. The analog bandpass filter unit 22 includes an active low-pass filter and an active high-pass filter connected to each other. The signal emitted by the signal gain configuration unit 21 passes through the active low-pass filter and the active high-pass filter in turn. The active high-pass filter includes a first output end and a second output end. The first output end is connected to the analog-to-digital converter 30, and the second output end is connected to the zero-crossing detection circuit 40. It should be noted that the passband bandwidths of the active low-pass filter and the active high-pass filter both cover the operating frequency range of the vibrating string sensor. It can be understood that the vibrating string signal is obtained through the vibrating string sensor.
[0037] In this embodiment, for the signal path of a stronger vibrating string signal, the vibrating string signal is digitally sampled through the analog-to-digital converter 30, that is, the preliminary signal is converted into a digital signal through the analog-to-digital converter 30, so that the microcontroller 10 can perform digital signal calculation processing, thereby performing frequency value settlement and obtaining the corresponding frequency value. It should be noted that the analog-to-digital converter 30 is connected to the microcontroller 10 through a digital interface to achieve data interaction. The sampling rate of the analog-to-digital converter 30 needs to be more than twice the highest frequency of the vibrating string sensor to meet the requirements of the sampling theorem. The sampling rate of the analog-to-digital converter 30 is 8Ksps-16Ksps. Specifically, the sampling rate of the analog-to-digital converter 30 is generally set to 8Ksps or 16Ksps. It can be understood that, under the condition of satisfying the sampling theorem, the lower the sampling rate, the higher the frequency accuracy measured by the frequency domain method.
[0038] In this embodiment, for the signal path of the weaker vibrating string signal, the vibrating string signal in the form of a sine wave is converted into a square wave of the same frequency through the zero-crossing detection circuit 40, that is, the preliminary signal is converted into a square wave of the same frequency through the zero-crossing detection circuit 40, so that the microcontroller 10 can perform edge judgment later, and then obtain the period of the square wave or obtain the corresponding frequency value by counting the number of square waves within a period of time. It should be noted that, if Figure 3 As shown, the zero-crossing detection circuit 40 includes a voltage comparator, which is used to filter out some interference around the threshold. The voltage comparator uses a voltage comparator with a hysteresis function. Although the hysteresis function will have a certain delay on the input signal, the vibrating-wire signal recognition device only needs to ensure the periodicity of the signal and will not affect the phase delay, so it has no effect on the final frequency measurement accuracy.
[0039] It should be noted that the zero-crossing detection circuit 40 is a voltage comparator circuit with a hysteresis function, such as Figure 3 As shown, the zero-crossing detection circuit 40 also includes two comparison level voltage-dividing resistors (represented by characters R258 and R286 respectively), a positive feedback loop resistor (represented by characters R288), and an input resistor (represented by characters R287). This circuit adopts a common-phase input configuration. Since the signal chain is powered by a single power supply, two comparison level voltage-dividing resistors R258 and R286 are required to divide the power supply voltage 5V to obtain a reference comparison voltage between 0V and 5V, which is generally set to a midpoint of 2.5V; the input resistor R287 and the positive feedback loop resistor R288 determine the hysteresis voltage, that is, Vt=Vcc*R287 / R288, and the size of Vt determines the size of the noise threshold.
[0040] In this embodiment, the calculation process of the first calculation module in the microcontroller 10 is to read the discretized digital signal sampled by the analog-to-digital converter 30, obtain discrete frequency domain data through FFT fast Fourier transform, and then obtain the accurate frequency value by using the frequency correction algorithm.
[0041] In this embodiment, the calculation process of the second calculation module in the microcontroller 10 is to configure the IO port of the microcontroller 10 to be an edge interrupt trigger mode, start the timer, and record the number of rising edges or falling edges in a unit time, as well as the time value between each rising edge and falling edge, and then obtain the frequency value of the vibrating string signal from the time domain.
[0042] In a specific implementation, the vibrating string signal is preliminarily processed by the preliminary processing module to obtain a preliminary signal. When the vibrating string signal is strong, the preliminary signal is converted by the analog-to-digital converter 30 to obtain a digital signal, and then the microcontroller 10 calculates the digital signal to obtain a frequency value. When the vibrating string signal is weak, the preliminary signal is converted by the zero-crossing detection circuit 40 to obtain a square wave of the same frequency, and then the microcontroller 10 calculates the square wave to obtain the corresponding frequency value. It is only processed separately during the terminal signal conditioning to combine the advantages of the two measurement methods, the time domain method and the frequency domain method, and achieves high-precision frequency measurement within the entire signal bandwidth without increasing the cost and system complexity.
[0043] It should be noted that the above implementation process is only for illustrating the feasibility of the present application, but this does not mean that the vibrating string signal recognition device of the present application has only the above-mentioned single implementation process. On the contrary, as long as the vibrating string signal recognition device of the present application can be implemented, it can be included in the feasible implementation plan of the present application.
[0044] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "example", "specific example", or "some examples" means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the utility model. In this specification, the schematic representation of the above terms does not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described can be combined in any one or more embodiments or examples in a suitable manner.
[0045] The above-mentioned embodiments only express several implementation methods of the utility model, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the patent of the utility model. It should be pointed out that, for ordinary technicians in this field, several variations and improvements can be made without departing from the concept of the utility model, and these all belong to the protection scope of the utility model. Therefore, the protection scope of the utility model patent shall be based on the attached claims.
Claims
1. A vibrating string signal recognition device, characterized in that: It includes a microcontroller, and a signal preliminary processing module, an analog-to-digital converter, and a zero-crossing detection circuit connected to the microcontroller; The signal preliminary processing module is used to perform preliminary processing on the vibrating string signal to obtain a preliminary signal; The analog-to-digital converter is connected to the preliminary processing module, and the analog-to-digital converter is used to convert the preliminary signal into a digital signal; The zero-crossing detection circuit is connected to the preliminary processing module, and the zero-crossing detection circuit is used to convert the preliminary signal into a square wave with the same frequency; The microcontroller is used to calculate corresponding frequency values according to the digital signal and the square wave respectively; The preliminary processing module includes a signal gain configuration unit and an analog bandpass filtering unit connected to each other, and the signal gain configuration unit is connected to the analog-to-digital converter and the zero-crossing detection circuit through the analog bandpass filtering unit.
2. The vibrating wire signal recognition device according to claim 1, characterized in that: The signal gain configuration unit is connected to the microcontroller via a configuration pin, and the configuration pin is located on the microcontroller.
3. The vibrating wire signal recognition device according to claim 1, characterized in that: The signal gain configuration unit comprises a program-controlled amplifier, on which a digital pin is arranged, and the program-controlled amplifier is used for performing signal amplification and gain configuration on the vibrating string signal through the digital pin.
4. The vibrating wire signal recognition device according to claim 1, characterized in that: The analog bandpass filtering unit includes an active low-pass filter and an active high-pass filter connected to each other. The signal output by the signal gain configuration unit passes through the active low-pass filter and the active high-pass filter in sequence. The active high-pass filter includes a first output end and a second output end. The first output end and the second output end are respectively connected to the analog-to-digital converter and the zero-crossing detection circuit.
5. The vibrating wire signal recognition device according to claim 1, characterized in that: The sampling rate of the analog-to-digital converter is 8Ksps-16Ksps.
6. The vibrating wire signal recognition device according to claim 1, characterized in that: The analog-to-digital converter is connected to the microcontroller via a digital interface.
7. The vibrating wire signal recognition device according to claim 1, characterized in that: The zero-crossing detection circuit includes a voltage comparator, and the voltage comparator is used to filter out part of the interference around the threshold.