Improvement of Ultrasonic Distance Measuring System

Similar documents
School of Electronic Science and Engineering, Nanjing University of Posts and Telecommunications, Nanjing, , China

Design of double loop-locked system for brush-less DC motor based on DSP

Design of Frequency Characteristic Test Instrument Based on USB

Design of Virtual Sphygmomanometer Based on LABVIEWComparison, Reflection, Biological assets, Accounting standard.

The Application and Stimulation Research of PIC single chip in. waveform signal generator. Gao Yi

Embedded Voice Announcement Ultrasonic Distance Meter and. University Lab Teaching Reformation

A Digital Thyristor Trigger Control System based on DSP

Design and Implementation of Serial Port Ultrasonic Distance Measurement System Based on STC12 Jian Huang

Design of Signal Conditioning Circuit for Photoelectric Sensor. , Zhennan Zhang

Electronic Buzzer for Blind

2. The design and realization of the developed system

Distance Measurement of an Object by using Ultrasonic Sensors with Arduino and GSM Module

Design of high precision current signal source on DDS Han Ya Kun1, a, Suo Xue Song*,1, b

Design of High-Precision Infrared Multi-Touch Screen Based on the EFM32

Coal Mine Lead-acid Battery Intelligent Charger

Development of Bolt Crack Detection Device Based on Ultrasonic Wave

Digital microcontroller for sonar waveform generator. Aleksander SCHMIDT, Jan SCHMIDT

Design of intelligent vehicle control system based on machine visual

Simulation and Design of a Waveform Generator Based on DDS Technology

DESIGN OF HIGH-PERFORMANCE ULTRASONIC PHASED ARRAY EMISSION AND RECEPTION CON- TROLLING SYSTEM

Intelligent fish tank based on WiFi module People want to control the production through WiFi technology in order to achieve the purpose of convenienc

Design and Implementation of Digital Frequency Meter Based on SCM. Weiqiang Zheng

Design of Electromagnetic Ultrasonic Data Acquisition and Analysis System Based on USB

Design of High Precision Digital AC Constant Current Source

Measuring Distance Using Sound

Massachusetts Institute of Technology MIT

Design and verification of internal core circuit of FlexRay transceiver in the ADAS

Separately Excited DC Motor for Electric Vehicle Controller Design Yulan Qi

The Design and Realization of High Precision Micrometric. Displacement Measuring System Based on LVDT

Sonic Distance Sensors

ULTRASONIC TRANSMITTER & RECEIVER

Design of a Frequency Counter Based on Input Capture Function of a. Single Chip Computer. Wang Yanshuang; Liu Yuelong

STUDY OF A NEW PHASE DETECTOR BASED ON CMOS

I. INTRODUCTION II. LITERATURE REVIEW

NEW DIGITAL ANGLE MEASUREMENT FACILITY BASED ON FPGA

TAPR TICC Timestamping Counter Operation Manual. Introduction

REACTIVE POWER COMPENSATION IN DISTRIBUTION SYSTEM

The Design of Double YAG Laser Implement Controlled by Industrial Computer

Object Detection for Collision Avoidance in ITS

Research and Design on IGBT Induction Heating Power Supply

Exam Booklet. Pulse Circuits

CHAPTER 2 VSI FED INDUCTION MOTOR DRIVE

Reconstruction of Information Technology Curriculum From Empirical Selection to Projection of Thought

Houngninou 2. Abstract

THE DESIGN OF ENERGY-EFFICIENT MONITORING TERMINALFOR POWER SUPPLY AND DISTRIBUTION SYSTEM OF ENTERPRISE BASED ON STM32

The Design Of Multiple Nodes Wireless Temperature Transmission System Based On STC15W1K24S And CC1101

Study on the Control System of the Phase Controlled Rectifier for Mine

DEPARTMENT OF ELECTRICAL ENGINEERING LAB WORK EE301 ELECTRONIC CIRCUITS

International Journal of Advance Engineering and Research Development

Design of Ultrasonic Liquid Level Sensor Based on STM32 with MODBUS Protocol

ASTABLE MULTIVIBRATOR

2 Intelligent meter reading mode

Using Magnetic Sensors for Absolute Position Detection and Feedback. Kevin Claycomb University of Evansville

Associate In Applied Science In Electronics Engineering Technology Expiration Date:

Police Siren Circuit using NE555 Timer

Description of a device and software for precise sound velocity measurement

ELG3336 Design of Mechatronics System

Excitation and reception of pure shear horizontal waves by

B.E. SEMESTER III (ELECTRICAL) SUBJECT CODE: X30902 Subject Name: Analog & Digital Electronics

Design and Implementation of a New Gain Control RF Amplifier

Six-degree-of-freedom robot design

Devices and Op-Amps p. 1 Introduction to Diodes p. 3 Introduction to Diodes p. 4 Inside the Diode p. 6 Three Diode Models p. 10 Computer Circuit

Design and Research of Piezoelectric Ceramics Drive Power

Wireless Music Player Design Based on White LED Visible Light Communication Shu-min ZHANG, Chun-xian XIAO, Chen-qiao XUE and Jin-ming LU

Wireless Embedded Air Multi-Parameter Measuring System

Wireless Sensor Network for Intra-Venous Fluid Level Indicator Application

Abstract. 1 Introduction. 1.2 Concept. 1.1 Problematic. 1.3 Modelling

Design and Implementation of a Low Power Successive Approximation ADC. Xin HUANG, Xiao-ning XIN, Jian REN* and Xin-lei CHEN

LINEAR IC APPLICATIONS

PIC Functionality. General I/O Dedicated Interrupt Change State Interrupt Input Capture Output Compare PWM ADC RS232

A Simple Microcontroller-Based 4-20 ma Current Loop Receiver for Sensors with Current Transmitters

Keywords: Ultrasonic Testing (UT), Air-coupled, Contact-free, Bond, Weld, Composites

Design of stepper motor position control system based on DSP. Guan Fang Liu a, Hua Wei Li b

Design of Linear Sweep Source Based on DDS Used in Readout System for Wireless Passive Pressure Sensor

Programming and Interfacing

Lock-in and Signal Averaging Circuits for an NDIR Gas Spectroscopy Based Carbon Monoxide Detector

Advanced Soldier Monitoring and Tracking System Using GPS and GSM Introduction

The Breakdown. Figure 1: Block Diagram (above: Transmitter; below: Receiver)

15 th Asia Pacific Conference for Non-Destructive Testing (APCNDT2017), Singapore.

The Development and Application of High Compression Ratio Methanol Engine ECU

Significance of a low noise preamplifier and filter stage for under water imaging applications

An Ultrasonic Sensor Based Low-Power Acoustic Modem for Underwater Communication in Underwater Wireless Sensor Networks

Draw in the space below a possible arrangement for the resistor and capacitor. encapsulated components

Table 1 The wheel-set security system of China high-speed railway

Theoretical and Experimental Investigation of Fiber Bragg Gratings With Different Lengths for Ultrasonic Detection

Design of the circuit for FSK modulation based on AD9910. Yongjun 1,2

A High Precision Electronic Scale Based on STM32. Jiahui Chen

A Novel Integrated Circuit Driver for LED Lighting

HIGH LOW Astable multivibrators HIGH LOW 1:1

Ultrasonic Proximity Sensor/Module for Water Proof Types of Ultrasonic Sensors (HG-P40WP)

The Application of Clock Synchronization in the TDOA Location System Ziyu WANG a, Chen JIAN b, Benchao WANG c, Wenli YANG d

Proceedings Contactless Interrogation System for Capacitive Sensors with Time-Gated Technique

Acoustic Velocity Independent Ultrasonic Flow-Meter

DIGITAL ELECTRONICS: LOGIC AND CLOCKS

Corrosion Assessment of Offshore Oil Pipeline Based on Ultrasonic. Technique

Open Access On Improving the Time Synchronization Precision in the Electric Power System. Qiang Song * and Weifeng Jia

Research and design of PFC control based on DSP

Scope. Here are the times schedule of the pulse-echo technique detect method. Reflect pulse. Emit detect pulse (Ultrasound)

Control System of Tension Test for Spring Fan Wheel Assembly

Title: Reference-free Structural Health Monitoring for Detecting Delamination in Composite Plates

Transcription:

Improvement of Ultrasonic Distance Measuring System Yu Jiang 1, Rui Song 2,*, and Mingting Yuan 3 1 Qingdao University, College of automation and electrical engineering, 266071 Qingdao and Shangdong University,College of control science and engineering, 250000 Jinan, China 2 Shangdong University,College of control science and engineering, 250000 Jinan, China 3 Qingdao University, College of automation and electrical engineering, 266071 Qingdao, China Abstract. This paper mainly introduces a kind of ultrasonic distance measuring system with AT89C51 single chip as the core component. The paper expounds the principle of ultrasonic sensor and ultrasonic ranging, hardware circuit and software program, and the results of experiment and analysis.the hardware circuit based on SCM, the software design adopts the advanced microcontroller programming language.the amplitude of the received signal and the time of ultrasonic propagation are regulated by closed loop control. [1,2]The double closed loop control technology for amplitude and time improves the measuring accuracy of the instrument. The experimental results show that greatly improves the measurement accuracy of the system. 1 Introduction Ultrasonic is a kind of sound wave that frequency is higher than 2KHz. It has good directivity, strong penetration ability and easy to obtain more concentrated sound energy.[3]the use of ultrasonic detection is relatively fast, convenient, simple and easy to control in real time. And ultrasonic can meet the practical requirements of industry in terms of measurement accuracy. So it has been widely used in mobile robots, car safety, ocean measurement and so on. The design of the system mainly includes two parts, that is the hardware circuit and the software program. The hardware circuit mainly includes the single chip circuit, the transmitting circuit, the receiving circuit, the display circuit and the power supply circuit. This paper uses AT89C51 microcontroller as the core of the digital display ultrasonic range finder. The whole circuit is designed by modularization, which is composed of signal transmitting and receiving, power supply, display and so on. The received signal amplitude and the propagation time of ultrasonic extraction use double closed-loop control technology. The experimental results show that the system has high precision measurement level and can meet the range requirement in industry. * Corresponding author: rsong@sucro.org The Authors, published by EDP Sciences. This is an open access article distributed under the terms of the Creative Commons Attribution License 4.0 (http://creativecommons.org/licenses/by/4.0/).

2 Ultrasonic sensor and the principle of ultrasonic distance measurement 2.1 Ultrasonic sensor The ultrasonic sensor is a kind ofsensor that converts ultrasonic signals into other energy signals (usually electrical signals). It has the function of converting electrical signals into mechanical signals and converting mechanical signals into electrical signals. We chose the piezoelectric ultrasonic generator in the design.[4] The piezoelectric ultrasonic generator actually works by using the resonance of a piezoelectric crystal. This paper adopts HC- SR04 ultrasonic sensor. This module has stable performance, accurate measurement of the distance, module of high precision and small blind region. The ultrasonic time sequence diagram is shown in Fig. 1. Fig. 1. The ultrasonic time sequence diagram 2.2 The principle of ultrasonic distance measurement The principle of ultrasonic distance measurement is TOF (time of flight). [5]The emission circuit sends out the ultrasonic. The ultrasonic waves propagate in the air and is reflected back when it meets an obstacle. The receiving circuit receives the reflected ultrasonic wave, and the single chip microcomputer measures the time required for transmitting to receiving. The time for detecting the ultrasonic wave transmitted from the emitter to the receiving end is t, and the time is time of flight. The velocity of ultrasonic wave propagation in the air is C, and the distance between the emission point and the measured object is s. [6]The range formula is expressed as: 1 S = ct (1) 2 The wave velocity of ultrasonic wave is related to the propagating medium, which is the fastest in the solid and the slowest in the gas. Ultrasonic is a kind of sound wave, so its velocity is related to temperature. Table 1 lists the sound velocity at several different temperatures. When in use, if the temperature change is not big, it is considered that the velocity is basically unchanged. If the measurement accuracy is very high, it should be corrected through temperature compensation method. The relationship between the velocity of sound and the temperature in the air can be expressed as: v = 331. 41+0.6(m/s) (2) 2

Table 3. The sound velocity at several different temperatures temperature( ) -30-20 -10 0 10 20 30 Sound velocity(m/s) 313 319 325 333 338 344 349 In order to further improve the accuracy of the measurement, this design increases the angle compensation as shown in the diagram. Measuring distance is When s>>h, and c is the ultrasonic speed. d 2 2 = s ) (3) ( h 2 Fig. 2. Schematic diagram of ultrasonic ranging 3 System hardware design The hardware design of the instruments include Ultrasonic transducer receiving and sending circuit, Remote data communication circuit, LCD display circuit, High frequency counting timing circuit, Monitor timer, Alarm and clock circuit, temperature compensation circuit, AT89C51 single chip microcomputer and memory circuit. The principle diagram of the hardware system is shown in Fig. 3. Ultrasonic transducer Ultrasonic transducer Radiating circuit Receiving circuit AT89C51 MCU 32k program storage 8k data storage LCD Dot matrix liquid crystal display circuit 10Mhz high frequency timing circuit Single wire thermometer Isolated RS-485 telecommunication circuit,supervisory timer, nonvolatile RAM, reset and clock circuit, alarm circuit Fig. 3. Hardware system 3.1 Singlechip circuit The AT89C51 singlechip is the core component of the instrument. The singlechip timer sends out the square wave pulse signal around 40KHz. The pulse is added to the ultrasonic sensor through the ultrasonic driving circuit, and the ultrasonic sensor sends out the ultrasonic. Because the output power of the MCU port is relatively small, it is difficult to meet the requirement of measuring distance. The ultrasonic transducer is output by the ultrasonic transducer after enlarging the amplifying circuit. The emitted ultrasonic wave is used as the input of the system. [7]The phase locked loop locks this signal, and produces a 3

lock signal to start microcontroller interrupt program. The internal timer stops the timing, software system calculat and analyz the signal then. The corresponding calculation results are sent to the LED digital tube for display. The single ship sequence diagram is shown in figure 4. Fig.4.SCM sequence diagram Fig.5. Isolated RS-485 telecommunication circuit 3.2 Transmitting circuit The transmitting circuit uses square wave modulation pulse transmitting circuit. The principle is shown in Figure 3. The singlechip generates a control signal and this signal triggered monostable multivibrator generates a main control pulse. When the master pulse is in high level, square wave generator produces a square wave pulse, the frequency is same with frequency transmitting transducer. Through the drive switch, transformer coupled excites ultrasonic transducer to emit ultrasonic. 4

Fig. 6. Transmit circuit schematic Fig. 7 Transmitting circuit 3.3 Receiving circuit The receiving circuit filters the signal to form the echo envelope, and the high speed voltage comparator produces a receiving signal pulse and transmits it to the 51 single chip circuit. In order to overcome the received signal amplitude changes caused by changes in the distance test.mber equations consecutively. In the hardware circuit design, using 4 point CMOS analog switch, based on the principle that the amplification of the inverting amplifier depends on the ratio of the resistance value, the resistors with 1, 1/2, 1/4 and 1/8 weights are in parallel in turn, and the logic level is used to control the resistance, and the synthetic resistance of 0~15 times is obtained.[8] In this way, a programmable amplifier with 0~15 times gain is obtained. As shown in Figure 9. In the system, programmable operational amplifier circuit, bandpass filter, absolute value circuit, π filter circuit, peak value holding circuit, voltage comparator and single chip microcomputer form the closed loop control loop with adjustable amplitude. The peak holding circuit extracts the maximum envelope of the received signal, and compares it with the preset threshold circuit.[9]when it is lower than the preset threshold, that the received signal is in the best received signal amplitude range, digital signal generated by the microcontroller control programmable amplifier, gain adjustment circuit, to achieve closed-loop gain control, the received signal amplitude changes in the vicinity of the threshold setting, so as to overcome the increase or decrease the amplitude of the signal caused by the change of the distance. 5

Fig.9. The circuit principle The propagation time is extracted based on ultrasonic echo. When a fixed threshold is used to read the ultrasonic propagation time, the time error will be caused by the variation of the echo amplitude, which will greatly affect the accuracy of ranging. Therefore, in the system design, a programmable variable threshold generation circuit is designed by using digital potentiometer, and a time readable closed loop control circuit is formed by highspeed voltage comparator (reduced signal comparison delay), microcontroller and variable threshold circuit.for the same distance, the echo signal is adjusted from a gain adjustment loop to a reasonable range.[10] Its envelope passes through a high speed voltage comparator to form a receiving pulse, and the width of the receiving pulse is detected by a single chip microcomputer. When it is not within reasonable limits (the 990us 1000US), according to its value, the microcontroller output digital adjustment signal, control the digital potentiometer to produce a new threshold.[13,14] Thus the closed loop control of the received pulse width can be realized, and the timing error caused by the same distance is overcome by the amplitude change, and the measurement precision is improved. 3.4 Display circuit The system uses a Trinity LED digital tube to display the measured distance, such as figure 10. Fig.10. display circuit 6

3.5 Power circuit The working current of the system is about 30-45mA. In order to ensure the system to work and debug the system for convenience, we use the USB port to supply the power directly to the computer.the 6V AC current is rectified by diode into a pulsating DC current, then it passes through the filter capacitor C1 to form the direct current. The voltage in the circuit passes through the integrated circuit transforms into 5 volt DC to supply to the whole system for electricity. In order to further improve the quality of power supply, the 5 volt DC power is filtered by C3 and C4 again.the power supply circuit is shown in Figure 11. Fig. 11. power circuit 4 Software design The instrument software design use advanced microcontroller programming language. It is convenient to carry out various mathematical operations.the main modules include ultrasonic transceiver module, automatic gain control module, receiving pulse width modulation module, temperature measurement module, data sorting and filtering module, remote communication module and so on. [11]The program flow is shown in Figure 13. Fig. 13. Software design diagram 7

5 The result of the experiment Double loop control receives a pulse width range for (990us ~ 1000US). The typical experimental data are shown in Table 2 and table 3. Table 2 Experimental data of double closed loop control (Unit: mm) Measurement Actual Measuring distance Deviation Measuring distance Deviation times distance (double closed loop) (fixed threshold) 1 3000 2999.6-0.4 3003.2 3.2 2 3000 3000.1 0.1 2997.4-2.6 3 3000 3000.2 0.2 3004.1 4.1 4 3000 2999.8-0.2 3003.9 3.9 5 3000 2999.6-0.4 3005.3 5.3 Table 3 Typical experimental data of measured points (unit: mm) Actual distance 1500 1700 1900 2500 3000 3050 3500 4500 5000 Ultrasonic 1500.3 1700.2 1899.7 2499.7 2999.8 3049.6 3500.3 4499.8 4999.5 distance Deviation +0.3 +0.2-0.3-0.3-0.2-0.4 +0.3-0.2-0.5 Table 2 data is the average value of the 5 measured values at the same point. The data of Table 3 were obtained for the 3000mm test point. According to the Bessel formula,[12] the standard deviation of the double closed loop control is 0.32mm, and the standard deviation is 4.39mm when the fixed threshold is used. It can be seen that the measurement accuracy has been greatly improved when double closed loop control is adopted. 6 Conclusion The experimental results show that in the closed loop control of amplitude, the control of automatic gain control circuit is avoided, and the amplitude variation caused by distance variation is overcome. For the time variable threshold control, variable threshold generation circui and time readable closed loop control loop overcome the timing error caused by the change of amplitude. The results of laboratory studies show that the echo waveforms of different test distances are the same, but the echo amplitude is different. [15]For the same test distance, the echo waveform is almost the same, and the amplitude is still slightly changing. In the case of the same waveform, in the same distance and different distance, the wave amplitude of the wave should be changed because the sound wave is affected by the propagating medium. In the design of ultrasonic distance measuring system, the change of echo amplitude must be overcome so that the precision of distance measurement can be improved. Acknowledgements: Thanks for Project Name:Key Technology Research and Application Demonstration of Robot Welding Production Line for Large Scale Structure of Coal Mine Engineering Machinery; Project Number:2015BAF01B02; Project Type: Nation Science and Technology Supporting Plan Program. 8

References 1. K. Imano, H. Kawazu, H. Inoue, Elec. & Comm. in Japan, Volume 79, Issue 12, (1996) 2. Holmes C, Drinkwater B W, Wilcox P D. Ndt & E International,38(8), pp.701-711. (2005) 3. Y Mizutani, T Suzuki, H Ikeda, H Yoshida et al, IEEE, vol.2.983-986(1996) 4. J. K. Andersen,The Journal of the Acoustical Society of America 98(3) September (1995) 5. Fukuoka I, Iida M, Morimatsu H, et al. Ultrasonic wave transmitting system: US 4020446 A[P]. (1977) 6. Wheatley Iii, Charles E, and D. N. Punch, High dynamic range closed loop automatic gain control circuit.us, US5283536US,(1994) 7. A Bulavinov, Post-Print, 45(6),1141-1146(2012) 8. Z R Huang, H BQin, B Z Huang. Chinese Journal of Sensors & Actuators, (2006) 9. CY Chen, and T. P. Sun, 1794-1796, IEEE (2006) 10. M Lu, ICSICT.IEEE Beijing Section, April (2016) 11. W. Huang. IEEE International Conference on Electronic Measurement & Instruments,(2015) 12. A Velichko, PD Wilcox. AIP Conference Series American Institute of Physics, 137-144, (2009) 13. B Bayram, O Oralkan, AS Ergun, E Haeggström, GG Yaralioglu, et al. IEEE Trans Ultrason Ferroelectr Freq Control, 52(2):326.(2005) 14. Zhang, Jian Qiang, J. Zhang, and H. Y. Zhao.Applied Mechanics & Materials 563:199-202(2014). 15. Wang Y J, Zhang L, Instrument Technique & Sensor, (2014) 16. Tisserand, E., and Y. Berviller,Electronics Letters, 52.22, 1847-1849(2016) 9