Distance measuring device and terminal
By designing a range measurement device including analog-to-digital conversion, frequency doubling, filtering and related processing, the problem of carrier frequency deviation in ultrasonic range measurement is solved, and the ranging accuracy and stability are improved.
Patent Information
- Application Number
- CN202010801568.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-08-11
- Publication Date
- 2025-03-18
- Estimated Expiration
- 2040-08-11
AI Technical Summary
In the ultrasonic ranging device, the frequency temperature of the crystal oscillator is poor, resulting in a change in the carrier frequency, affecting the envelope demodulation accuracy of the receiving circuit, and thus reducing the accuracy of the peak ranging method.
A ranging device is designed, including an analog-to-digital conversion module, a frequency multiplication module, a filtering module, a related module and a ranging module. The device eliminates carrier frequency deviation and improves ranging accuracy through analog-to-digital conversion, frequency multiplication processing, filtering and related processing.
By eliminating the carrier frequency deviation, the distance measurement accuracy is improved, ensuring that the device can work normally under short distance measurement in centimeters, and the stability and environmental adaptability are improved.
Smart Images

Figure CN114076948B_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of measurement technology, and in particular to a distance measuring device and a terminal. Background Art
[0002] Since ultrasonic distance measurement is a non-contact detection technology, it is not affected by light, the color of the object being measured, etc. It is more hygienic than other instruments, and more resistant to harsh environments such as moisture, dust, high temperature, corrosive gases, etc. It has the characteristics of low maintenance, no pollution, high reliability, and long life. Therefore, ultrasonic distance measurement in the air has a wide range of applications in special environments, and can be used for online calibration of distance accuracy in different environments. Ultrasonic detection is often faster, more convenient, simpler to calculate, and easy to achieve real-time control, and can meet industrial practical index requirements in terms of measurement accuracy.
[0003] Ultrasonic sensors are generally self-transmitting and self-receiving, but due to cost considerations, the frequency temperature of the crystal oscillator used in the peripheral circuit is poor, which will cause a large change in the carrier frequency between the receiving time and the transmitting time. The receiving circuit using related technology will cause the demodulated envelope to have a large distortion, which will seriously affect the accuracy of the peak ranging method. Summary of the invention
[0004] In view of this, the present disclosure proposes a distance measuring device, the device comprising:
[0005] The analog-to-digital conversion module is used to perform bandpass sampling on the received analog ultrasonic signal and perform analog-to-digital conversion on the sampled signal to obtain a digital ultrasonic signal;
[0006] A frequency doubling module, electrically connected to the analog-to-digital conversion module, for performing frequency doubling processing on the digital ultrasonic signal to obtain a frequency doubling signal;
[0007] A filtering module, electrically connected to the frequency multiplication module, for filtering the frequency multiplication signal to obtain an envelope signal;
[0008] A correlation module, electrically connected to the filtering module, for performing correlation processing on the envelope signal and a preset envelope signal to obtain a correlation signal;
[0009] The distance measuring module is electrically connected to the correlation module and is used to perform peak value detection on the correlation signal and determine the distance using the peak value obtained by the detection.
[0010] In a possible implementation, the analog-to-digital conversion module includes an analog-to-digital converter, and the analog-to-digital converter is configured to operate in a Sigma-Delta mode.
[0011] In a possible implementation manner, the frequency multiplication module includes a multiplier.
[0012] In a possible implementation, the filtering module includes a low-pass filter.
[0013] In a possible implementation, the related module includes a multiplication unit and an accumulation unit.
[0014] The multiplication unit is used to multiply the envelope signal and corresponding bits of the preset envelope signal to obtain multiple intermediate results;
[0015] The accumulation unit is electrically connected to the multiplication unit, and is used to accumulate a plurality of the intermediate results to obtain the correlation signal.
[0016] In a possible implementation, the ranging module includes a peak detection unit, and the peak detection unit is used to perform peak detection on the correlation signal, including:
[0017] A comparison subunit, used to compare the correlation signal at the current moment with the peak value at the previous moment to obtain a comparison result;
[0018] The peak determination subunit is electrically connected to the comparison subunit, and is used to set the relevant signal at the current moment as the peak value at the current moment when the comparison result is that the relevant signal at the current moment is greater than the peak value at the previous moment; or to set the peak value at the previous moment as the peak value at the current moment when the comparison result is that the relevant signal at the previous moment is greater than the relevant signal at the current moment.
[0019] In a possible implementation manner, the peak detection unit further includes:
[0020] The peak value storage subunit is electrically connected to the comparison subunit and the peak value determination subunit, and is used to store the peak value.
[0021] In a possible implementation manner, the ranging module further includes:
[0022] A distance measuring unit is electrically connected to the peak value detection unit and is used to determine the distance using the peak value detected, wherein the distance determination using the peak value detected includes:
[0023] The distance is determined by using the data bit where the peak is located and the rate of the correlation data.
[0024] According to another aspect of an embodiment of the present disclosure, a terminal is provided, the terminal comprising:
[0025] The distance measuring device.
[0026] Through the above device, the embodiment of the present disclosure can use the analog-to-digital conversion module to perform bandpass sampling on the received analog ultrasonic signal, and perform analog-to-digital conversion on the sampled signal to obtain a digital ultrasonic signal, use the frequency doubling module to perform frequency doubling processing on the digital ultrasonic signal to obtain a frequency doubling signal, filter the frequency doubling signal through the filtering module to obtain an envelope signal, use the correlation module to correlate the envelope signal with the preset envelope signal to obtain a correlation signal, use the ranging module to perform peak detection on the correlation signal, and use the detected peak value to determine the distance. Using the above device for ranging eliminates the influence of carrier frequency deviation and improves the accuracy of ranging.
[0027] Further features and aspects of the present disclosure will become apparent from the following detailed description of exemplary embodiments with reference to the attached drawings. BRIEF DESCRIPTION OF THE DRAWINGS
[0028] The accompanying drawings, which are incorporated in and constitute a part of the specification, illustrate exemplary embodiments, features, and aspects of the disclosure and, together with the description, serve to explain the principles of the disclosure.
[0029] Figure 1 A schematic diagram of the ultrasonic ranging principle according to an embodiment of the present disclosure is shown.
[0030] Figure 2 A block diagram of a distance measuring device according to an embodiment of the present disclosure is shown.
[0031] Figure 3 A block diagram of a distance measuring device according to an embodiment of the present disclosure is shown. DETAILED DESCRIPTION
[0032] Various exemplary embodiments, features and aspects of the present disclosure will be described in detail below with reference to the accompanying drawings. The same reference numerals in the accompanying drawings represent elements with the same or similar functions. Although various aspects of the embodiments are shown in the accompanying drawings, the drawings are not necessarily drawn to scale unless otherwise specified.
[0033] The word “exemplary” is used exclusively herein to mean “serving as an example, example, or illustration.” Any embodiment described herein as “exemplary” is not necessarily to be construed as preferred or advantageous over other embodiments.
[0034] In addition, in order to better illustrate the present disclosure, numerous specific details are given in the following specific embodiments. It should be understood by those skilled in the art that the present disclosure can also be implemented without certain specific details. In some examples, methods, means, components and circuits well known to those skilled in the art are not described in detail in order to highlight the subject matter of the present disclosure.
[0035] See also Figure 1 , Figure 1A schematic diagram of the ultrasonic ranging principle according to an embodiment of the present disclosure is shown.
[0036] like Figure 1 As shown in the figure, in ultrasonic ranging, the ultrasonic transmitter transmits ultrasonic waves in a certain direction, and the timing starts at the same time as the transmission. The ultrasonic waves propagate in the air, and immediately return when they encounter obstacles on the way. The ultrasonic receiver stops timing immediately when it receives the reflected wave. The propagation speed of ultrasonic waves in the air is 340m / s. According to the time t recorded by the timer, the distance (s) from the transmitting point to the obstacle can be calculated, that is: s = 340t / 2.
[0037] Since ultrasound is a sound wave, its sound velocity V is related to temperature. When in use, if the temperature of the propagation medium does not change much, it can be approximately considered that the speed of ultrasound is basically unchanged during the propagation process. If the distance measurement accuracy is very high, the measurement result should be numerically corrected by temperature compensation. After the sound velocity is determined, the distance can be obtained by measuring the round-trip time of the ultrasound.
[0038] according to Figure 1 We can get:
[0039] H=S*cosθ (1)
[0040] θ=arctg(L / H) (2)
[0041] Among them, S represents the length of the ultrasonic wave to reach the obstacle, L represents half of the distance between the ultrasonic transmitter and the ultrasonic receiver, H represents the distance to be measured, and θ represents the angle between H and L.
[0042] The distance that ultrasound travels is:
[0043] 2S=vt (3)
[0044] Among them, v represents the propagation speed of ultrasound in the medium, and t represents the time required for ultrasound to be transmitted and received.
[0045] Substituting formula (2) and formula (3) into formula (1), we get:
[0046]
[0047] Because the propagation speed v of ultrasound is a constant at a certain temperature (for example, at temperature T = 30 degrees, V = 349 m / s), when the distance H to be measured is much greater than L, formula (4) becomes:
[0048] H=1 / 2vt (5)
[0049] Therefore, through the above formula, the measured distance H can be obtained.
[0050] The ranging accuracy of the related technology is low. In order to increase the ranging accuracy, an automatic frequency control circuit can be used, but this greatly increases the complexity of the receiving circuit. On the other hand, when working in the centimeter-level short-distance ranging mode, the frequency locking time of the automatic frequency control circuit may be greater than the echo delay time, causing it to not work properly.
[0051] To solve the above problems, the embodiments of the present disclosure provide a ranging device that can achieve high-precision ranging with a low-complexity circuit and can still work normally under centimeter-level short-distance ranging, thereby improving the stability and environmental adaptability of the device.
[0052] See also Figure 2 , Figure 2 A block diagram of a distance measuring device according to an embodiment of the present disclosure is shown.
[0053] like Figure 2 As shown, the device comprises:
[0054] The analog-to-digital conversion module 10 is used to perform bandpass sampling on the received analog ultrasonic signal and perform analog-to-digital conversion on the sampled signal to obtain a digital ultrasonic signal;
[0055] The frequency doubling module 20 is electrically connected to the analog-to-digital conversion module 10 and is used to perform frequency doubling processing on the digital ultrasonic signal to obtain a frequency doubling signal;
[0056] A filtering module 30, electrically connected to the frequency multiplication module 20, for filtering the frequency multiplication signal to obtain an envelope signal;
[0057] A correlation module 40, electrically connected to the filtering module 30, for performing correlation processing on the envelope signal and a preset envelope signal to obtain a correlation signal;
[0058] The distance measuring module 50 is electrically connected to the correlation module 40, and is used to perform peak detection on the correlation signal and determine the distance using the detected peak value.
[0059] Through the above device, the embodiment of the present disclosure can use the analog-to-digital conversion module to perform bandpass sampling on the received analog ultrasonic signal, and perform analog-to-digital conversion on the sampled signal to obtain a digital ultrasonic signal, use the frequency doubling module to perform frequency doubling processing on the digital ultrasonic signal to obtain a frequency doubling signal, filter the frequency doubling signal through the filtering module to obtain an envelope signal, use the correlation module to correlate the envelope signal with the preset envelope signal to obtain a correlation signal, use the ranging module to perform peak detection on the correlation signal, and use the detected peak value to determine the distance. Using the above device for ranging eliminates the influence of carrier frequency deviation and improves the accuracy of ranging.
[0060] It should be noted that, in the device of the embodiment of the present disclosure, each module can be implemented by a digital circuit.
[0061] In a possible implementation, the analog-to-digital conversion module may include an analog-to-digital converter, and the analog-to-digital converter (ADC) is configured to operate in a Sigma-Delta mode.
[0062] The embodiment of the present disclosure can minimize quantization noise by setting the analog-to-digital converter to the sigma-delta mode, and the signal rate after bandpass sampling of the received analog ultrasound signal is much greater than the bandwidth of the envelope signal.
[0063] In a possible implementation, the frequency multiplication module may include a multiplier.
[0064] In one example, the frequency multiplication module may be implemented by a multiplier, or may be implemented by a frequency multiplier in related technologies.
[0065] Through the frequency doubling module, the embodiment of the present disclosure can realize the square operation of the digital ultrasonic signal. The frequency doubling module is realized by using a frequency multiplier and a multiplier, and the circuit area of the device is increased slightly and can be ignored. The bandwidth of the envelope signal extracted by the frequency doubling module is doubled compared to the original bandwidth. In combination with the analog-to-digital converter working in the sigma-delta mode, carrier synchronization is realized, so that the performance of the distance measuring device proposed in the embodiment of the present disclosure is not affected by the carrier frequency deviation.
[0066] In a possible implementation, the filtering module may include a low-pass filter.
[0067] The disclosed embodiment can perform low-pass filtering on the frequency doubling signal obtained by the frequency doubling module through a low-pass filter, thereby obtaining an accurate envelope signal. Moreover, due to the frequency doubling effect of the frequency doubling module, the bandwidth of the envelope signal obtained after the low-pass filter performs low-pass filtering on the frequency doubling signal is wider, which can improve the ranging accuracy.
[0068] The embodiments of the present disclosure do not limit the specific implementation of the low-pass filter, and those skilled in the art may adopt the low-pass filter in the related technology as needed.
[0069] In a possible implementation, the correlation module may include a multiplication unit and an accumulation unit.
[0070] The multiplication unit is used to multiply the envelope signal and corresponding bits of the preset envelope signal to obtain multiple intermediate results;
[0071] The accumulation unit is electrically connected to the multiplication unit, and is used to accumulate a plurality of the intermediate results to obtain the correlation signal.
[0072] In one example, the correlation module can be implemented by using a correlator in the related art, or by using a digital circuit as needed.
[0073] In one example, the multiplication unit may include one or more multipliers, and the accumulation unit may include one or more adders.
[0074] Through the correlation module, the embodiment of the present disclosure can multiply the envelope signal obtained by the filtering module with the preset Paul signal, and accumulate the multiple intermediate results obtained to obtain the correlation signal for subsequent ranging. The implementation method is simple, the circuit complexity is not high, it is easy to implement, and the cost is low.
[0075] In a possible implementation, the ranging module may include a peak detection unit, and the peak detection unit may be used to perform peak detection on the correlation signal, including:
[0076] A comparison subunit, used to compare the correlation signal at the current moment with the peak value at the previous moment to obtain a comparison result;
[0077] The peak determination subunit is electrically connected to the comparison subunit, and is used to set the relevant signal at the current moment as the peak value at the current moment when the comparison result is that the relevant signal at the current moment is greater than the peak value at the previous moment; or to set the peak value at the previous moment as the peak value at the current moment when the comparison result is that the relevant signal at the previous moment is greater than the relevant signal at the current moment.
[0078] In one example, the comparison subunit may be implemented by a comparator, and the peak value determination subunit may be implemented by a dedicated hardware circuit or by a general hardware circuit combined with control logic.
[0079] In a possible implementation manner, the peak detection unit may further include:
[0080] The peak value storage subunit is electrically connected to the comparison subunit and the peak value determination subunit, and is used to store the peak value.
[0081] In one example, the peak value storage subunit may include a non-volatile memory.
[0082] In a possible implementation, the ranging module may further include:
[0083] A distance measuring unit is electrically connected to the peak value detection unit and is used to determine the distance using the peak value detected, wherein the distance determination using the peak value detected includes:
[0084] The distance is determined by using the data bit where the peak is located and the rate of the correlation data.
[0085] For example, assuming that the peak value detected by the correlation module after correlation processing is the 100th data point, and the data rate during correlation is 100 KHz, then the distance can be determined according to the formula H=1 / 2*v*t.
[0086] Assuming that the speed of ultrasound in the air is 343 m / s, according to the ranging formula, we can get H = 0.5*343*100 / 100000 = 0.343*0.5 m.
[0087] In one example, the distance measuring unit may be implemented using a dedicated hardware circuit (eg, a digital circuit) or a general hardware circuit (eg, a central processing unit CPU, a microprocessor MCU, etc.) in combination with existing control logic.
[0088] The frequency multiplier proposed in the embodiment of the present disclosure can be implemented by a multiplier, carrier synchronization is achieved, and the increased circuit area can be ignored. The bandwidth of the envelope signal extracted by the frequency multiplier will be doubled than the original one, and the analog-to-digital converter ADC used in the device proposed in the embodiment of the present disclosure works in Sigma-Delta mode, that is, the signal rate after extraction and filtering is still much larger than the bandwidth including the signal, which makes full use of the characteristics of both Sigma-Delta mode ADC and frequency multiplier, so that the performance of the distance measuring device is not affected by the carrier frequency deviation, and the accuracy of the distance measurement is not reduced, and the cost is low.
[0089] See also Figure 3 , Figure 3 A block diagram of a distance measuring device 800 according to an embodiment of the present disclosure is shown. For example, the device 800 may be a mobile phone, a computer, a digital broadcast terminal, a messaging device, a game console, a tablet device, a medical device, a fitness device, a personal digital assistant, etc.
[0090] Reference Figure 3 , the device 800 may include one or more of the following components: a processing component 802 , a memory 804 , a power component 806 , a multimedia component 808 , an audio component 810 , an input / output (I / O) interface 812 , a sensor component 814 , and a communication component 816 .
[0091] The processing component 802 generally controls the overall operation of the device 800, such as operations associated with display, phone calls, data communications, camera operations, and recording operations. The processing component 802 may include one or more processors 820 to execute instructions to complete all or part of the steps of the above-mentioned method. In addition, the processing component 802 may include one or more modules to facilitate the interaction between the processing component 802 and other components. For example, the processing component 802 may include a multimedia module to facilitate the interaction between the multimedia component 808 and the processing component 802.
[0092] The memory 804 is configured to store various types of data to support operations on the device 800. Examples of such data include instructions for any application or method operating on the device 800, contact data, phone book data, messages, pictures, videos, etc. The memory 804 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disk or optical disk.
[0093] The power supply component 806 provides power to the various components of the device 800. The power supply component 806 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power for the device 800.
[0094] The multimedia component 808 includes a screen that provides an output interface between the device 800 and the user. In some embodiments, the screen may include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive input signals from the user. The touch panel includes one or more touch sensors to sense touch, slide, and gestures on the touch panel. The touch sensor may not only sense the boundaries of the touch or slide action, but also detect the duration and pressure associated with the touch or slide operation. In some embodiments, the multimedia component 808 includes a front camera and / or a rear camera. When the device 800 is in an operating mode, such as a shooting mode or a video mode, the front camera and / or the rear camera may receive external multimedia data. Each front camera and rear camera may be a fixed optical lens system or have a focal length and optical zoom capability.
[0095] The audio component 810 is configured to output and / or input audio signals. For example, the audio component 810 includes a microphone (MIC), and when the device 800 is in an operating mode, such as a call mode, a recording mode, and a speech recognition mode, the microphone is configured to receive an external audio signal. The received audio signal can be further stored in the memory 804 or sent via the communication component 816. In some embodiments, the audio component 810 also includes a speaker for outputting audio signals.
[0096] I / O interface 812 provides an interface between processing component 802 and peripheral interface modules, such as keyboards, click wheels, buttons, etc. These buttons may include but are not limited to: a home button, a volume button, a start button, and a lock button.
[0097] The sensor assembly 814 includes one or more sensors for providing various aspects of the status assessment of the device 800. For example, the sensor assembly 814 can detect the open / closed state of the device 800, the relative positioning of components, such as the display and keypad of the device 800, and the sensor assembly 814 can also detect the position change of the device 800 or a component of the device 800, the presence or absence of user contact with the device 800, the orientation or acceleration / deceleration of the device 800, and the temperature change of the device 800. The sensor assembly 814 may include a proximity sensor configured to detect the presence of a nearby object without any physical contact. The sensor assembly 814 may also include an optical sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, the sensor assembly 814 may also include an accelerometer, a gyroscope sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.
[0098] The communication component 816 is configured to facilitate wired or wireless communication between the device 800 and other devices. The device 800 can access a wireless network based on a communication standard, such as WiFi, 2G or 3G, or a combination thereof. In an exemplary embodiment, the communication component 816 receives a broadcast signal or broadcast-related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 816 also includes a near field communication (NFC) module to facilitate short-range communication. For example, the NFC module can be implemented based on radio frequency identification (RFID) technology, infrared data association (IrDA) technology, ultra-wideband (UWB) technology, Bluetooth (BT) technology and other technologies.
[0099] The embodiments of the present disclosure have been described above, and the above description is exemplary, not exhaustive, and is not limited to the disclosed embodiments. Many modifications and changes will be apparent to those of ordinary skill in the art without departing from the scope and spirit of the described embodiments. The selection of terms used herein is intended to best explain the principles of the embodiments, practical applications, or improvements to the technology in the market, or to enable other persons of ordinary skill in the art to understand the embodiments disclosed herein.
Claims
1. A distance measuring device, characterized in that: The device comprises: An analog-to-digital conversion module is used to perform bandpass sampling on the received analog ultrasonic signal and perform analog-to-digital conversion on the sampled signal to obtain a digital ultrasonic signal, wherein the analog-to-digital conversion module includes an analog-to-digital converter, and the analog-to-digital converter is configured to operate in a Sigma-Delta mode; A frequency doubling module, electrically connected to the analog-to-digital conversion module, for performing frequency doubling processing on the digital ultrasonic signal to obtain a frequency doubling signal; A filtering module, electrically connected to the frequency multiplication module, for filtering the frequency multiplication signal to obtain an envelope signal; A correlation module, electrically connected to the filtering module, for performing correlation processing on the envelope signal and a preset envelope signal to obtain a correlation signal; The distance measuring module is electrically connected to the correlation module and is used to perform peak value detection on the correlation signal and determine the distance using the peak value obtained by the detection. The related modules include a multiplication unit and an accumulation unit. The multiplication unit is used to multiply the envelope signal and corresponding bits of the preset envelope signal to obtain multiple intermediate results; The accumulation unit is electrically connected to the multiplication unit, and is used to accumulate a plurality of the intermediate results to obtain the correlation signal.
2. The device according to claim 1, characterized in that The frequency multiplication module includes a multiplier.
3. The device according to claim 1, characterized in that The filtering module includes a low-pass filter.
4. The device according to claim 1, characterized in that The ranging module includes a peak detection unit, and the peak detection unit is used to perform peak detection on the correlation signal, including: A comparison subunit, used to compare the correlation signal at the current moment with the peak value at the previous moment to obtain a comparison result; The peak determination subunit is electrically connected to the comparison subunit, and is used to set the relevant signal at the current moment as the peak value at the current moment when the comparison result is that the relevant signal at the current moment is greater than the peak value at the previous moment; or to set the peak value at the previous moment as the peak value at the current moment when the comparison result is that the relevant signal at the previous moment is greater than the relevant signal at the current moment.
5. The device according to claim 4, characterized in that The peak detection unit also includes: The peak value storage subunit is electrically connected to the comparison subunit and the peak value determination subunit, and is used to store the peak value.
6. The device according to claim 4, characterized in that The ranging module also includes: A distance measuring unit is electrically connected to the peak value detection unit and is used to determine the distance using the peak value detected, wherein the distance determination using the peak value detected includes: The distance is determined by using the data bit where the peak is located and the rate of the correlation signal.
7. A terminal, characterized in that: The terminal comprises: A device as claimed in any one of claims 1 to 6.
Citation Information
Patent Citations
System and method for demodulating optical-fiber interference-type sensing signals
CN102620757A
Ultrasonic ranging method and ranging device for wireless ranging
CN104931971A
Correlation operation circuit and semiconductor device
CN107423025A
Method and apparatus for echo detection
CN108663673A
Distance measuring device and terminal
CN212301882U