1,300
26
Essay, 7 pages (1800 words)

Distance range of distance measurement methods to cope

Distance Measurement by Ultrasonic Sensor – An Efficient Remedyfor Perilous Situations in MeasurementLe Tuan Vu1, Van Dinh Trieu1 and Dang Thanh Tin11 Bach Khoa University, Ho Chi Minh City, Vietnam Email: [email protected]

edu. vnAbstract—Up untilnow, measurement is considered as a fundamental demand in man’s life andinnovation process. In many aspects of life, theneed for accurate measurement is increasing as measuring size and distance ofthe object serves the purpose of designing, installing and establishing. There is availably a wide range of distance measurementmethods to cope with specific situations and environments.  Sharing the same aim, distance measurementdevice using ultrasonic sensor is examined for a straightforward performance inmeasuring from a distance. Keywords—ultrasound, ultrasonic waves, ultrasonic sensor, distance measurement, arduino.                                                                                                  I.

INTRODUCTION It is a fact that traditional measurement techniques such asseveral categories of rulers expose their crucial flaws which are the inabilityto mete from long distance, the danger when users have to tackle the arduousgeographic environment and the time-consuming implementation. As a solutiongiven by the development of technology, ultrasonic sensor or laser beam areoften applied in measuring distance for the purpose of facilitating users anddiminishing the risk during meting process as well as the time requirement. These methods have their own upsides and downsides and vary in the price, sizeof device, the accuracy, the productivity, energy consumption level as well. Inthe market of this field, there are a number of companies taking up producingthese devices with a relatively high price and the diversity of theirfunctions.

Take Bosch GLM product as an example, it is a measurement deviceusing laser beam, which is challenging to individually purchase. With an aim tobuilding a portable, energy-saving, reasonably priced and highly accurateequipment, Ultrasonic sensor is chosen for this project. The distance measurement device using ultrasonic includes anultrasonic sensor, a temperature sensor DS18B20, a LCD screen displaying theresult, a microcontroller Arduino Nano and 9V battery. Brief discussion on theapplied methods is in section 2, principle in section 3, result analysis insection 4. The conclusion will be in the section 5.                                                                                                   II.

MethodA. ToolsUS-015- Ultrasonic sensor is used to define the distance. This sensor is chosen as a result of being low-cost and providing relativelyprecise capacity of measuring which meets the primary needs of users. Fig. 1 Ultrasonic sensorUS-015Table1Specification of US-015 Working voltage 5V DC Static current 3mA Working temperature 0 ~ +70oC Output way GPIO Induction Angle Less than 15o Detection range 2cm to 400cm Detecting precision 0. 3cm + 1% Sensor size 45 x 20 x 1. 6 mm  The DS18B20 is a digitalthermometer which provides high resolution (12 bits).

IC uses one wirecommunication which is succinct, straightforward to program, and enables thecommunication between numbers of DS18B20 in one wire.  In addition, IC has function of warning when thetemperature exceeds the allowanced level and be able to supply power from datapin (parasite power). Fig.

2 DS18B20 Temperature SensorTable2Specification of DS18B20 Working voltage 3 – 5. 5V Usable Temperature Range -55 oC ~ 125 oC Accuracy ±0. 5oC from -10 oC to +85 oC Resolution 9 ~ 12 bits Communication protocol 1 – Wire  Arduino nano is a small, complete, and breadboard-friendly version of Arduino Uno R3 SMD basing on MCUAtmega328P. Sharing the same MCU, Ithas more or less the same functionality and program of the Arduino Uno. Fig. 3 Arduino Nano v3. 0Table3Specification of Arduino Nano Microcontroller Atmega328P Architecture AVR Operating Voltage 5V Flash Memory 32KB of which 2KB used by bootloader SRAM 2KB Clock Speed 16 MHz Analog I/O Pins 8 EEPROM 1KB DC Current per I/O Pins 40mA Input Voltage 7-12V Digital I/O Pins 22 PWM Output 6 Power Consumption 19mA PCB Size 18 x 45mm B. Theoretical base 2Ultrasound is sound waves with frequencies higher than the upperaudible limit of human hearing.

This upper audible limit depends on eachindividual and human hearing normally tops out ataround 20 kHz. Ultrasound can pass through several substances which aresimilar to sound environment such as air, solid and liquid by the speed ofsound. Despite having the same speed of propagation, the ultrasound’s frequencyis much higher than that of the sound which leads to their short wavelengths. Due to this characteristic, resolution of the ultrasonic images allows user todefine objectives whose dimension is in centimeter or millimeter. Therefore, Ultrasonic imaging applications include industrialnon-destructive testing, quality control and medical uses. Due to the invisibilityof ultrasound, it is currently applied in observation applications to measuredistance or speed of things. Besides, Ultrasound technology is spreading inmany aspects of life such as ultrasonic cleaner, ultrasonic soldering, ultrasonography and so forth. Innature, a number of animals are capable of emitting and receiving ultrasound.

Bat, for instance, is known as an animal having weak sigh but they transmit andsensor the ultrasound-a trick called echolocation to locate their surroundings. Toothed whales, including dolphins, can hear ultrasound and use such sounds intheir navigational system (biosonar) to orient and capture prey.  Ultrasound radar is a practical solution forthe fact that radio wave is inactive in water environment.

A discernableapplication of ultrasound is submarine’s navigational system, radar, depthmeasurement of the ocean. The picture below depicts the advent of ultrasound innature: Fig. 4 The advent of ultrasound in natureBasing on the observation of animal activities relating tothe utility of ultrasound, it can be concluded that the principle manipulatingultrasound in the navigation is such simple that can be summarized in threesteps: Initially, the subject produces ultrasonic waves which travel throughdistance and collide with obstacles in the surrounding environment and thenreverberate. Afterward, the time ultrasonic waves are emitted and received isrecorded for further calculation for the distance between the subject andobject. The computation depends significantly on the transmission medium.

Thiscan be proven by the fact that sound waves travel faster in water or metal thanthe air.  It is noticeable thatultrasonic wave is impossible to transmit in vacuum. As usual, the problem relating to ultrasound is solved usinga constant speed of v = 340m/s. This figure is acceptable in case error ispermissive in order to simplify the computation.

In reality, this case isabolished as a result of the requirement for high accuracy in a number oftasks. Thus, calculating precisely the speed of ultrasonic wave is crucial. Temperature is also a condition that affects the speed of sound 1. Heat, likesound, is a form of kinetic energy.

Molecules at higher temperatures have moreenergy, thus they can vibrate faster. Since the molecules vibrate faster, soundwaves can travel more quickly. The speed of sound in room temperature air is346 meters per second.

This is faster than 331. 3 meters per second, which isthe speed of sound in air at freezing temperatures. The formula to find thespeed of sound in air is as follows:   Where v is the speed of sound and T is the temperature ofthe air. One thing to keep in mind is that this formula finds the average speedof sound for any given temperature. The speed of sound is also affected byother factors such as humidity and air pressure.                                                                                                    III. PrincipleIn this project, Arduino nano is chosen on account of itsfavourableness, reasonable price, size as well as efficiency.

Besides theaforementioned features, Arduino is back up by Arduino IDE programmingenvironment that facilitates users and shortens the programming process. Before measuring the distance, ultrasonic speed value at a time must be defined. According to theaforementioned theory, temperature value is worth considering due to the factthat speed of ultrasound depends much more on this parameter. Measuringenvironmental temperature requires DS18B20 digital thermometer which will beinserted to the Arduino. The reason for the manipulation of this digitalthermometer in this project is its received value will be digit whichdiminishes the loss of value during transmission and the appreciable errorscompared to other analog devices. For the purpose of saving time and energy, Onewire library is used for 1-wire communication and Dallas Temperature libraryto read the value taken from sensor 4.

After initializing the object fortemperature measurement, the t_sensor in this case, will be activated by t_sensor. requestTemperatures() command. Temperature values from sensor are read by: float Temp = t_sensor. getTempCByIndex(0); During the process, sensor performsproperly, its results are stable and the errors are acceptable ? T = 0. 3oC. With the obtained temperature value, the speed of ultrasound is computed basingon the formula (1) which is precedently discussed. float Speed = 331. 3 + 0.

6 * Temp; From then, the criticalparameters for measuring method are all obtained. Next, ultrasonic sensor isconnected to Arduino’s two digital pins and supplied power. Ultrasonic sensorincludes 2 power pins, a trigger pins and an echo pin. Its trigger pin connectsto transmitter in order to emit ultrasonic wave, whereas, echo pin connects toreceiver to receive forward wave signal. Basing on this fundamental principle, the time interval between emitting and receiving point is calculated. There ispulseIn() function availably on Arduino that copes with the aforementionedcomputation. This function returns the time points from when it is initiallyreferred to when echo receives the signal 3, 5. Firstly, the two pins ofsensor must be set up its mode:                    pinMode(TRIG_PIN, OUTPUT);                    pinMode(ECHO_PIN, INPUT); Secondly, a pulse is sent toTrigger which then emits ultrasonic waves: digitalWrite(TRIG_PIN, HIGH); Changing pin’s mode into LOW thenthe time that ultrasonic wave travels from start point, collides the obstacles, reverberates and returns to receivers is recorded and calculated: long duration = pulseIn(ECHO_PIN, HIGH); Fig.

5 Transmitting and receiving ultrasound process3Due to the fact that thisrecorded time covers the entire length ultrasound travel, whereas the distancefrom device to objective is a half of it, the recorded time must be dividedinto halves: float distance = Speed * (duration / 2); The following flow chartillustrates the overview of this process:  Fig. 6 Process overview                                                                                            IV. Result AnalysisTable 4 Statistical result Distance (cm) Result (cm) Error (%) 30 30. 30 1 50 50. 20 0. 40 80 79. 95 0.

06 100 99. 76 0. 24 150 150.

23 0. 15 200 200. 10 0. 05 250 250. 10 0.

04 300 299. 87 0. 04 350 350. 17 0. 05 400 400. 22 0.

06 Average of Error   0. 21  As can be seen, the error of 0. 21% is inconsiderable andacceptable. The recorded figures in the interval of measured distance have theallowable errors from 30cm to 400cm. For the distance under 30cm, the errorbecomes greater which partially results from the restricted capability ofArduino.

With such a short distance, time required for measurement is so smallthat the capacity of microcontroller to store the variables is irresponsive. Another factor causing this issue is the diffraction that happens when thedevice is set at a short distance to the object. Ultrasonic sensor can notaccess the distance above 400 cm. This depends on the decision of this sensor’smanufacture.

To expand the measurement interval for mass production, this projectneeds the greater investment.                                                                                                  V. CONCLUSIONS The total expense for this project is roughly $16 inwhich the Arduino nano costs $5, ultrasonic sensor, temperature sensor, LCDcosts $6 and packaging costs $5 excluding the labour. It is a fact that thesignificant decrease of price will result from the advent of mass productions. As a result, the price of this device is much more reasonable compared with theexisting products on the market. For example, the price of Bosch device isseven times as much as that of our product.

The accomplished device performsaccurately and smoothly. Its upsides are being portable, reasonably-priced, energy-saving and highly accurate. However, there are some obstacles inmeasurement process such as the system is unstable, thesignificant error when measuring out of the allowable range. Theseinconveniences result from the sensor itself as listed by the manufacturers andthe limit of algorithm as well as formula. In the upcoming version, the devicewill be designed and developed more carefully to achieve user’s higher reliance.

REFERENCES  1.      EberhardS, Calculation of the Speed of Sound in Air and the effective Temperature at http://www. sengpielaudio. com/calculator-speedsound. htm, accessed November 10th 2017. 2.      Ultrasoundat https://en.

wikipedia. org/wiki/Ultrasound, accessed October 25th  2017. 3.      UltrasonicSensor HC-SR04 and Arduino Tutorial at http://howtomechatronics. com/tutorials/arduino/ultrasonic-sensor-hc-sr04/, accessed Oct 5th20174.

Howto Use DS18B20 Temperature Sensor at http://howtomechatronics. com/tutorials/arduino/ultrasonic-sensor-hc-sr04/, accessed Oct 5th 20175.      PulseInat https://www. arduino. cc/reference/en/language/functions/advanced-io/pulsein/, accessed Oct 5th 2017

Thank's for Your Vote!
Distance range of distance measurement methods to cope. Page 1
Distance range of distance measurement methods to cope. Page 2
Distance range of distance measurement methods to cope. Page 3
Distance range of distance measurement methods to cope. Page 4
Distance range of distance measurement methods to cope. Page 5
Distance range of distance measurement methods to cope. Page 6
Distance range of distance measurement methods to cope. Page 7
Distance range of distance measurement methods to cope. Page 8
Distance range of distance measurement methods to cope. Page 9

This work, titled "Distance range of distance measurement methods to cope" was written and willingly shared by a fellow student. This sample can be utilized as a research and reference resource to aid in the writing of your own work. Any use of the work that does not include an appropriate citation is banned.

If you are the owner of this work and don’t want it to be published on AssignBuster, request its removal.

Request Removal
Cite this Essay

References

AssignBuster. (2022) 'Distance range of distance measurement methods to cope'. 11 September.

Reference

AssignBuster. (2022, September 11). Distance range of distance measurement methods to cope. Retrieved from https://assignbuster.com/distance-range-of-distance-measurement-methods-to-cope/

References

AssignBuster. 2022. "Distance range of distance measurement methods to cope." September 11, 2022. https://assignbuster.com/distance-range-of-distance-measurement-methods-to-cope/.

1. AssignBuster. "Distance range of distance measurement methods to cope." September 11, 2022. https://assignbuster.com/distance-range-of-distance-measurement-methods-to-cope/.


Bibliography


AssignBuster. "Distance range of distance measurement methods to cope." September 11, 2022. https://assignbuster.com/distance-range-of-distance-measurement-methods-to-cope/.

Work Cited

"Distance range of distance measurement methods to cope." AssignBuster, 11 Sept. 2022, assignbuster.com/distance-range-of-distance-measurement-methods-to-cope/.

Get in Touch

Please, let us know if you have any ideas on improving Distance range of distance measurement methods to cope, or our service. We will be happy to hear what you think: [email protected]