This Project Report Is Submitted In Partial Fulfillment of Requirements for the Degree of Bachelor in Electrical Engineering (Industry Power)
May 2006
ABSTRACT
Ultrasound is sound with a frequency approximately above 40kHz, greater than the upper limit of human hearing. The ultrasound waves follow the rules of propagation and reflection; it can be reflected and absorbed by a medium. The ultrasound can be produced by sending a high frequency alternating for example using ultrasonic transmitter. Hence this project is done to implement the direct reading of ultrasound distance meter. This approach is used in order to measure the Qstance (in centimeter) using ultrasound signal to a target. Air is used as the medium for the ultrasound to transmit while the distance is horizontally located The SRF04 consists of transmitter and receiver, requiring a short trigger pulse and providing an echo pulse. The echo line is therefore a pulse whose width is proportional to the distance
to the object. Theoretically, ultrasound signal is send to a target then time is taken by
counter (clock) and finally the distance will appear at 7- segment display panel.
ABSTRAK
melebihi had pendengaran bag^ seseorang manusiaGelombang ultrmwtd mematuhi hukum pembiasan dan pantulan dimana ia dapat dipantulkan dan diserap oleh medium. Wtrasound boleh dihasilkan dengan menghantarkan fkkuensi yang tinggi contohnya menggunakan pemancar ultrasonik. Justeru itu projek ini dihasilkan untuk mengukur j arak dengan memancarkan ul~ra~ozmd. Dengan kaedah ini sesuatu jarak dalam unit sentimeter dapat diketahui apabila ultrasound dipancarkan ke arah sesuatu objek Medium penghantaraan adalah udara manakala objek diletakkan secara melintang dari pemancar sernasa ujian dijalankan Pemancar dan penerima jenis SRF04 digunakan dalam projek ini dimana ia memerlukan signal pendek untuk dihidupkan dan akan mengbasilkan gelombang pantulan dimana ia berkadar langsung dengan jarak dari objek tersebut. Secara teorinya, signal ul~rmound akan dihantm ke target kemudia litar pengira akan menentukan masa yang diambil untuk signal dipantul dan diserap semula oleh penerima. Sebagainya outputnye, jarak akan dipaparkan pada p e l 7-bahagian
1 3 Scope
The ultrasound distance meter consists of several circuits that are very important that need to be study of the operation and find the best design. Each component that been needed in this project had to been specific and fulfill the target of this project After doing research and study, below are the main components and set as the scope of this project. It consists of three difference circuit:
1. Triggering circuit
1.
2.
The equipments used are not high-tech created. The reading is not precisely and accurate measured. The devices carmot display the reading in digital d u e . It required long time to complete the measure process.
3.
4.
1.
2.
Geologies face difficulties to measure distance from one surface to another surface. Scientists especially surgeons have to know the exact l o d o n for detecting cancer cell.
3.
Below is few application of ultrasound distance meter that been applied in industry and commercials used:
1.
To locate a school of fish Medical purpose; physical therapy, cancer treatment, scanning fetus Detect crack in metal widely used by geologies Use as ultrasonic cleaners for jewellery, lenses
2.
3.
4.
1.5
Layout of Thesis
This report consists of six chapters. Chapter 1 gives the overview of the
entire project with a summary of the project background and the objectives of the project. Chapter 2 consists of literahue review that been used in order to understand and have a better view for this project. Therefore literature review on several of topic related had been done throughout this period throughout journals, books and related internet sites. Chapter 3 discuss about methodology that consist of all the component that been used for this circuit. It also included the function and the operation of each component. Chapter 4 consists of discussion on the result. It will show the final result for this project Chapter 5 will gives the recommendations for this report and highli&ts the suggestions for the future development. Chapter 6 will conclude the project that been develop.
CHAPTER 2
LITERATURE REVIEW
Reviews of available literature of this project have been performed to ensure more understanding to construct ultrasonic distance meter. The areas that were focused are on behavior of ultrasound through journals, books, and internet.
21 .
wave phenomena. It can be thought of as being produced by many small point sources making up the transducer face and thus producing a characteristic interference pattern at any point in the field. As ultrasound is propagated fi-om the transducer, there is a zone where the overall beam size remains relatively constant (the near field), though there are many variations of intensity within the zone itself,
both across and along the beam axis. This zone is followed by a zone where the
beam diverges and becomes more uniform the far field. For a circular piston source of diameter D radiating sound of wavelength lambda, the Fresne zone extends from the transducer to a distance equal to D2/4 lambda (when D is much greater than lambda); beyond this distance is the Fraunhofer zone of the transducer [I]. For a given radius of the transducer, the near field becomes more complex (exhibiting more maxima and minima) as the wavelength of the ultrasound becomes shorter.
The acoustic field of a pulsed transducer can be thought of as being composed of contributions from all the frequencies within the bandwidth of a short pulse. It has been shown in Figure 2.1 that the near field is less structured than that of transducer, and that the length of the near field corresponds to that of transducer oscillating at the centre frequency of the pulsed field.
E~'4'4+r;
I
X sin 0 = 1.22j=j
'
rx
4
I
I
Fnr field
(Fraunh~fw zone}
zone}
WH 8 3 4 + O 2.
Figure 2.1: Prediction of ultrasonic waveforms in highly attenuating plastic materials [I].
2.2
Speed of Sound
The speed, c at which ultrasonic vibrations are transmitted through a medium
is inversely proportional to the square root of the product of the density, o and the adiabatic compressibility, B of the material, such that in equation 2.1. The speeds together with the frequency, f of the ultrasound determine the wavelength lambda,A of the waves that are propagated as in equation 2.2.
2.3
Ultrasonic sensors are commonly used for a wide variety of noncontact presence, proximity, or distance measuring applications. These devices typically transmit a short burst of ultrasonic sound toward a target, which reflects the sound back to the sensor. The system then measures the time for the echo to return to the sensor and computes the distance to the target using the speed of sound in the medium .The wide variety of sensors currently on the market differ from one another in their mounting configurations, environmental sealing, and electronic features. Acoustically3 they operate at different frequencies and have different radiation pattern.
i.
ii.
.*-
Variation in the speed of sound Variation in the wavelength of sound Variation in the attenuation of sound Variation of the amplitude
111.
iv.
2.4
Speed of Sound in Air as a Function of Temperature In an echo ranging system, the elapsed time between the emission of the
ultrasonic pulse and its return to the receiver is measured. The range distance to the target is then computed using the speed of sound in the transmission medium, which is usually air. The accuracy of the target distance measurement is directly proportional to the accuracy of the speed of sound used in the calculation. The actual speed of sound is a function of both the composition and temperature of the medium through which the sound travels.
speed
Temperature ( degree C )
Figure 2.2: The speed of sound is plotted as a function of the temperature. At room temperature, sound travels at -13,500 ips [2].
2.5
The wavelength of sound changes as a function of both the speed of sound and the frequency, as shown by the expression:
temperature in air.
Wavelength
Frequency (kHz)
Figure 2.3: The wavelength of sound in air at room temperahrre is plotted as a function of frequency
2.6
Relative Echo Levels from a Flat Surface for different Ultrasonic Frequencies If the sound pulse is reflected from a large flat surface, then the entire beam
is reflected. This total beam reflection is equivalent to a virtual source at twice the distance. Therefore, the spreading loss for the sound reflected from a large flat surface is equal to 20 log (2R), and the absomon loss is equal to 2QR. For this to hold, it is important that the reflecting surface be both larger than the entire sound beam to ensure total reflection, and perpendicular to the sound beam [3].
Reflecting plate
Figure 2.4: A sound beam reflected from a flat surface is equivalent to the sound as
generated from virtual transducer at an equal range behind the reflecting plate.
and is a vibration at a frequency above the range of human 0 kHz. The microphones and loudspeakers used to receive and
nd are called transducers. Most ultrasonic sensors use a
both transmit the sound pulse and receive the reflected echo,
,t frequencies between 40 kHz and 250 k z A variety of H. iransducers are used in these systems. The foliowing sections how the sound pulse is affected by some of the fundamental
~ ~ t r u c t i o n Refraction of Sound, and somd is critical in determining the acoustics of a room or concert
(2.4)
CHAPTER 3
METHODOLOGY
3.1
The Hardware Development The flow charts of hardware development in Figure 3.1 shows the step of
progress which will be followed to achieve the project objective. The first step is searching information, the activities in this step is to find out the resources and references about the ultrasound distance meter. Next step is to find out the scope, objective, problem and expectations of this project. Step 3 is to identifl suitable circuits and components, by doing this step the concept and the circuit operation can be understand because there are many kinds of circuits that can operate as ultrasound distance meter. Next step is simulation using Multisim This step is uses to simulate the input triggering circuit. The Multisim can approve the circuit and ensure the components that been used can give the short input for the SRF04 to activate. If the result satisfied the condition, the input triggering circuit is been constructed. The same method is applied for counter and display circuit before been constructed Next step is interfkcing all the circuit that been constructed and test the functionality. This step is to test the circuit whether it operates according to achieve the expected result. Finally, project realization. If the output of the circuit is within the expected resulf which means the objective of this project is achieved
Searching Information
I
I
\..,-,
Project realization
.....................................
Triggering circuit Target (wall)
Reset
*
.....................................
Counter and Clock
7 Segment Display
3.1.1
General Operation of Ultrasound Distance Meter Figure 3.2 shows that the block diagrams of hardware design. First,
transmitter will be activated to generate ultrasonic pulse after receiving pulse from triggering circuit. Triggering circuit will generate a square pulse for a certain length of time depending on time constant of the circuit. It is combination of two unit of 555 timer (monostable circuit) to produce a short trigger pulse for activate
SRF04. When SRF 04 is activated, it will produce output pulse with high
frequency approximately 40 kHz (ultrasonic pulse). So the ultrasonic pulse will hit the target (wall) that located horizontally. Then the echo pulse will hit the receiver. The width of the pulse is actually present the flight time of sonic burst. The output from receiver will then multiply with the frequency of square wave. The frequency of square wave will be generated by 555 timer in counter and clock circuit. The counter circuit is to obtain the total time for the ultrasound to travel back and forward. It will start counting when the signal is transmitted and stop counting upon receiving the reflected signal. The calculation for the distance is actually done using counter circuit using 7490 counter and 7447 counter.
In this chapter, all the components that been used is discuss and explain in
details. Basically, there are three main circuits that going to be discussed. It included:
Each component is related to each other starting from trigger circuit until 7segment display. Each circuit that been design is simulated using Multisim in order to know the output of each circuit. After all circuit is design, these circuit will be interfacing to another circuit to make it complete and produce output in terms of distance by display the value at 7-segment display panel. Below are the descriphons of all the related circuit that has been develop in this project
32 .
INPUT TRIGGER CIRCUIT In this project trigger circuit is constructed to generate trigger jmlse for
activate SRFO4. Triggering circuit will generate a short triggering pulse that will be used to activate SRFO4 with minimum value approximately lops. This circuit consists of 555 timer, AND gate, resistors, variable resistor, capacitors with 12volt as the input supply. Figure 3.3 shows the input triggen'ng circuit. Both 555 Timer works as monostable multivibrator in this circuit. The second 555 Timer is used variable resistor to generate shorter pulse compared to the pulse that generated by first 555 Timer. Then the output fiom both timer will be multiplied a NAND gate to t get final output that has short pulse. This is because only short pulse needed as input triggering pulse to activate SRF04.
16
555 TIMER
(monostable),
-.
#I
7400 7400
555 TIMER
7400
#2
be used in triggering circuit. Three of the most common circuits that using 555 IC
are: The Astable Circuit produces a continuous train of pulses a any frequency t you require. The name "astable" means "never stable" - the output of the circuit never stays stable in any of the two states. The Monostable Circuit produces one pulse of a set length in response to a
trigger input such as a push button. The output of the circuit stays in the low
state until there is a trigger input, hence the name "monostable" meaning "one stable state". The Bistable Circnit toggles between the states. Triggering one input sets the output to the low state, while triggering another input sets the output to the high state. The name "bistablenmeans "two stable states".
$ 21
THR
Figure 3.4: 555 timer Table 3.1 : Pin function of 555 timer iNo. Name
'1
1
Purpose Ground
A short pulse on the trigger starts the timer
GND
1 2
TR
F'CV voltage allows access to the internal voltage divider (Zn Vcc) Control
I
1 6
1 7
I
THR DIS
timing intend
'8
v+,
:Vcr
All IC timers rely upon an external capacitor to determine the off-on time intervals of the output pulses. It takes a finite period of time for a capacitor (C) to charge or discharge through a resistor (R). Those times are clearly defined and can be calculated given the values of resistance and capacitance. The basic RC charging circuit is shown in Figure 3.5. Assume that the capacitor is initially discharged. When the switch is closed, the capacitor begins to charge through the resistor. The voltage across the capacitor rises fiom zen,up to the value of the applied DC voltage. The time that it takes for the capacitor to charge to 63.7% of the applied voltage is known as the time constant (t). That time can be calculated by simple expression:
Trigger
Capacitor Voltage
fl
.----
. . . . -
. .
213 Vcc
Output
I--..
-c
. . . . . . -
. .. : .. . . . . . . . -. . . . . . .
ov
+Vcc
ti
ov
Reset
+ vcc
ov
A reset pulse applied during timing interval terminates the output pulse
3.2.1.1.1
Figure 3.6: Monostable Circuit Figure 3.6 shows that when 555 IC is used to produce an monostable circuitit only will pulse once. Monostable circuits can be used to turn lights/LED on or off just once. The easiest way of recognizing that a 555 IC has been set up as monostable when Pin 6 and Pin 7 are connected together and go to the positive terminal. Monostable multivibrator often called a one shot multivibrator is a pulse generating circuit in which the duration of this pulse is determined by the RC network connected externally to the 555 timer. In a stable or standby state, the output of the circuit is approximately zero or a logic-low level. The time for which output remains high is determined by the external RC network connected to the timer. At the end of the timing interval, the output automatically reverts back to its logic-low stable state. The output stays low until trigger pulse is again applied Then the cycle repeats.
The monostable circuit has only one stable state (output low) hence the name monostable.The waveforms in figure 3.7 illustrate the operation of a monostable. A monostable circuit produces one pulse of a set length (time period T) in response to a trigger input such as a push button. The output of the circuit stays in the low state until there is a trigger input, hence the name "monostable" meaning "one stable state". This type of circuit is ideal for use in a "push to operate" system. Testing can be done by pushing a button to start a model's mechanism moving, and the mechanism will automatically switch off after a set time. Another use for the circuit is to 'de-bounce' a push button input to a digital.
TRIGGER
INPUT
GUTPUT mm *E
m
TIME PERIOD T
-C(
MONOSTABLE TRIGGERED
called a monostable because it is stable in just one state: 'output low'. The 'output high' state is temporary. The circuit diagram of the 555 monostable circuit is given in figure 3.6 Notice that the resistor value R and the capacitor d u e C are unspecified. The values of these components determine the length of time that the monostable output is in the high state, and they may be calculated using the equation below.
The duration of the pulse is called the time period (T) and this is determined
by resistor R 1 and capacitor C1 :
timeperiod,T = 1.1x Rl x C1 (3.2)
322 ..
The 74LS00 IC
The output is high when either of inputs A or B is high, or if neither is high.
In other words, it is normally high, going low only if both A and B is high.
GND
4
Figure 3.8: The 74LS00 IC Table 3.2: Truth table for AND Gate
INPUT
OUTPUT
Troubleshooting for this circuit is done to make sure the output is supposed to be. Figure shows the complete circuit for input triggering circuit. So by putting
LED at each timer and at 7400 IC it will show the sequence of the lighting as in
simulation using the Multisim. Once the push button is push, LED 1 and LED 3 at both timer will light on but LED 3 at the second timer light off first Shortly after that, the LED 5 at 7400 IC will light on in a short time as the final output that going to be the input triggering circuit for SRFO4. Another method is used to troubleshoot this circuit is by using oscilloscope. When the push button is push, a short pulse can
be detected occur showing that a small pulse is been generated by this circuit.
This high performance ultrasonic range finder is compact and measures an amazingly wide range from 3cm to 3m.The sensor transmits a burst of pulses; if there is a sonically reflective obstacle, then that burst will be reflected back to the receiver component of the sensor. The sensor works by ultrasounds and contains all the electronics in charge to make the measurement. Its use is as simple as to send the starting pulse and to measure the width of the return pulse. Of very small size,
SRF04 emphasizes by his under consumption, high accuracy and low price. The
figure to the right shows the simple case. Our job is to determine the range d given that we can measure the time taken to get the echo. The first important thing to know is the speed (velocity) of sound in air, Vs, at sea level, at room temperature, which is approximately: Vs = 343 meters per second So, if we know the amount of time between the transmission and the reception (t, in seconds) then all we need to do is half t (because t represents a return trip) and multiply by the speed of sound.
That is:
dzstance,r = Vsx 2
where r is in meters