




版權(quán)說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請進行舉報或認領(lǐng)
文檔簡介
1、畢業(yè)設(shè)計論文英文資料翻譯 Ultrasonic ranging system design 系 別 專 業(yè) 班 級 學生姓名 學 號 指導教師 中文翻譯超聲測距系統(tǒng)設(shè)計摘要:超聲測距技術(shù)在工業(yè)現(xiàn)場、車輛導航、水聲工程等領(lǐng)域都具有廣泛的應(yīng)用價值,目前已應(yīng)用于物位測量、機器人自動導航以及空氣中與水下的目標探測、識別、定位等場合。因此,深入研究超聲的測距理論和方法具有重要的實踐意義。為了進一步提高測距的精確度,滿足工程人員對測量精度、測距量程和測距儀使用的要求,本文研制了一套基于單片機的便攜式超聲測距系統(tǒng)。關(guān)鍵詞:超聲波,測距儀,單片機 隨著科技的開展,人們生活水平的提高,城市開展建設(shè)加快,城市給排
2、水系統(tǒng)也有較大開展,其狀況不斷改善。但是,由于歷史原因合成時間住的許多不可預(yù)見因素,城市給排水系統(tǒng),特別是排水系統(tǒng)往往落后于城市建設(shè)。因此,經(jīng)常出現(xiàn)開挖已經(jīng)建設(shè)好的建筑設(shè)施來改造排水系統(tǒng)的現(xiàn)象。城市污水給人們帶來了困擾,因此箱涵的排污疏通對大城市給排水系統(tǒng)污水處理,人們生活舒適顯得非常重要。而設(shè)計研制箱涵排水疏通移動機器人的自動控制系統(tǒng),保證機器人在箱涵中自由排污疏通,是箱涵排污疏通機器人的設(shè)計研制的核心局部??刂葡到y(tǒng)核心局部就是超聲波測距儀的研制。因此,設(shè)計好的超聲波測距儀就顯得非常重要了。 微控制器(MCU)是一種單片計算機。這是一種強調(diào)自給自足和本錢效益形成鮮明比照的通用微處理器PC。現(xiàn)
3、在使用的大多數(shù)的計算機系統(tǒng)是嵌入到其他機器中,如 、時鐘、電器、汽車和根底設(shè)施。嵌入式系統(tǒng)通常對內(nèi)存和程序長度的要求很小并且可能需要簡單但不尋常的輸入/輸出系統(tǒng)。例如,大多數(shù)嵌入式系統(tǒng)缺乏鍵盤,屏幕,磁盤、打印機或其他可識別的個人計算機的I/O設(shè)備。他們可能控制電動機、繼電器或電壓和閱讀開關(guān)、可變電阻或者其他電子設(shè)備。通常情況下,人類可讀的唯一的I/O設(shè)備是一個發(fā)光二極管,嚴重的甚至可以消除這種本錢或權(quán)力約束。 與通用CPU相比,微控制器沒有一個地址總線或一個數(shù)據(jù)總線,因為他們整合了所有的內(nèi)存和非易失性內(nèi)存相同的芯片CPU。因為他們需要更少的別針,芯片可以放置在一個更小,更廉價的包。在單個芯片
4、上集成內(nèi)存和其他外圍設(shè)備并且作為一個單元測試它們會增加芯片的本錢,但往往導致降低作為一個整體的嵌入式系統(tǒng)的凈本錢。(即使整合周邊設(shè)備的一個CPU的本錢略高于一個CPU+外部外圍設(shè)備,擁有更少的芯片通常允許一個更小、更廉價的電路板,并減少了所需的勞動力來組裝和測試電路板)。這種趨勢下來設(shè)計。單片機是一個單一的集成電路,通常有以下特點:中央處理單元從小型、簡單的4比特處理器變?yōu)?2位或64位處理器。輸入/輸出接口如串行端口(UARTs),其他串行通信接口像IC,串行外圍接口和控制器區(qū)域網(wǎng)絡(luò)系統(tǒng)互連的外圍設(shè)備如定時器和監(jiān)督機構(gòu),數(shù)據(jù)存儲器RAM,程序存儲器ROM、EPROM、EEPROM或閃存存儲,
5、時鐘發(fā)生器通常是一個一個石英計時晶體振蕩器、諧振器或RC電路。許多包括模擬數(shù)字轉(zhuǎn)換器,這種集成大大減少芯片的數(shù)量和連接的數(shù)量而且需要PCB空間使用單獨的芯片產(chǎn)生等效系統(tǒng),而且在1970年代他們的介紹中已被證明在嵌入式系統(tǒng)中是非常受歡送的。 一些微控制器可以使用哈佛架構(gòu):指令和數(shù)據(jù)單獨的內(nèi)存總線,允許訪問同時發(fā)生。外圍設(shè)備整合的決定通常是困難,單片機供給商經(jīng)常用操作頻率和系統(tǒng)設(shè)計的靈活性對上市時間要求換取從他們的客戶和整體較低的系統(tǒng)本錢。制造商必須平衡需要減小的芯片大小和其他功能。3.超聲波測距原理 壓電式超聲波發(fā)生器原理 壓電式超聲波發(fā)生器實際上是利用壓電晶體的諧振來工作的。超聲波發(fā)生器內(nèi)部結(jié)
6、構(gòu),它有兩個壓電晶片和一個共振板。當它的兩極外加脈沖信號,其頻率等于壓電晶片的固有振蕩頻率時,壓電晶片將會發(fā)生共振,并帶動共振板振,便產(chǎn)生超聲波。反之,如果兩電極間未外加電壓,當共振板接收到超聲波時,將壓迫壓電晶片作振動,將機械能轉(zhuǎn)換為電信號,這時它就成為超聲波接收器了。 測量脈沖到達時間的傳統(tǒng)方法是以擁有固定參數(shù)的接收信號開端為根底的。這個界限恰恰選于噪音水平之上,然而脈沖到達時間被定義為脈沖信號剛好超過界限的第一時刻。一個物體的脈沖強度很大程度上取決于這個物體的自然屬性尺寸還有它與傳感器的距離。進一步說,從脈沖起始點到剛好超過界限之間的時間段隨著脈沖的強度而改變。結(jié)果,一種錯誤便出現(xiàn)了兩個
7、擁有不同強度的脈沖在不同時間超過界限卻在同一時間到達。強度較強的脈沖會比強度較弱的脈沖超過界限的時間早點,因此我們會認為強度較強的脈沖屬于較近的物體。超聲波測距原理 超聲波發(fā)射器向某一方向發(fā)射超聲波,在發(fā)射時刻的同時開始計時,超聲波在空氣中傳播,途中碰到障礙物就立即返回來,超聲波接收器收到反射波就立即停止計時。超聲波在空氣中的傳播速度為340m/s,根據(jù)計時器記錄的時間t,就可以計算出發(fā)射點距障礙物的距離(s),即:s=340t/2。4.超聲波測距系統(tǒng)的電路設(shè)計 系統(tǒng)的特點是利用單片機控制超聲波的發(fā)射和對超聲波自發(fā)射至接收往返時間的計時,單片機選用C52,經(jīng)濟易用,且片內(nèi)有4K的ROM,便于編
8、程。電路原理圖如圖1所示。圖1 電路原理圖4.1 40kHz 脈沖的產(chǎn)生與超聲波發(fā)射 測距系統(tǒng)中的超聲波傳感器采用UCM40的壓電陶瓷傳感器,它的工作電壓是40kHz的脈沖信號,這由單片機執(zhí)行下面程序來產(chǎn)生。puzel: mov 14h, #12h;超聲波發(fā)射持續(xù)200mshere: cpl p1.0 ; 輸出40kHz方波 nop ; nop ; nop ; djnz 14h,here; ret 前方測距電路的輸入端接單片機P1.0端口,單片機執(zhí)行上面的程序后,在P1.0 端口輸出一個40kHz的脈沖信號,經(jīng)過三極管T放大,驅(qū)動超聲波發(fā)射頭UCM40T,發(fā)出40kHz的脈沖超聲波,且持續(xù)發(fā)射
9、200ms。右側(cè)和左側(cè)測 距電路的輸入端分別接P1.1和P1.2端口,工作原理與前方測距電路相同。4.2超聲波的接收與處理 接收頭采用與發(fā)射頭配對的UCM40R,將超聲波調(diào)制脈沖變?yōu)榻蛔冸妷盒盘?,?jīng)運算放大器IC1A和IC1B兩極放大后加至IC2。IC2是帶有鎖定環(huán)的音頻譯碼集成塊LM567,內(nèi)部的壓控振蕩器的中心頻率f0=1/1.1R8C3,電容C4決定其鎖定帶寬。調(diào)節(jié)R8在發(fā)射的載頻上,那么LM567 輸入信號大于25mV,輸出端8腳由高電平躍變?yōu)榈碗娖?,作為中斷請求信號,送至單片機處理。 前方測距電路的輸出端接單片機INT0端口,中斷優(yōu)先級最高,左、右測距電路的輸出通過與門IC3A的輸出
10、接單片機INT1端口,中斷源的識別由程序查詢來處理,中斷優(yōu)先級為先右后左。局部源程序如下:receive1:push psw push acc clr ex1; 關(guān)外部中斷1,right;P1.1引腳為0,轉(zhuǎn)至右測距電路中斷效勞程序,left;P1.2引腳為0,轉(zhuǎn)至左測距電路中斷效勞程序return: SETB EX1; 開外部中斷1 pop acc pop psw retiright: . ; 右測距電路中斷效勞程序入口 ajmp returnleft: . ; 左測距電路中斷效勞程序入口 ajmp return計算超聲波傳播時間 在啟動發(fā)射電路的同時啟動單片機內(nèi)部的定時器T0,利用定時器的
11、計數(shù)功能記錄超聲波發(fā)射的時間和收到反射波的時間。當收到超聲波反射波時,接收電路輸出端產(chǎn)生一個負跳變,在INT0或INT1端產(chǎn)生一個中斷請求信號,單片機響應(yīng)外部中斷請求,執(zhí)行外部中斷效勞子程序,讀取時間差,計算距離。其局部源程序如下:RECEIVE0: PUSH PSW PUSH ACC CLR EX0 ; 關(guān)外部中斷0 MOV R7,TH0 ; 讀取時間值 MOV R6,TL0 CLR C MOV A,R6 SUBB A, #0BBH; 計算時間差 MOV 31H,A ; 存儲結(jié)果 MOV A,R7 SUBB A, #3CH MOV 30H,A SETB EX0 ; 開外部中斷0 POP AC
12、C POP PSW RETI對于一個平坦的目標,距離測量包括兩個階段:粗糙的測量和精細測量。 第一步:脈沖的傳送產(chǎn)生一種簡單的超聲波。 第二步:根據(jù)公式改變回波放大器的獲得量直到回撥被檢測到。 第三步:檢測兩種回波的振幅與過零時間。 第四步:設(shè)置回波放大器的所得來規(guī)格輸出,假定是3伏。通過脈沖的周期設(shè)置下一個脈沖。根據(jù)第二部的數(shù)據(jù)設(shè)定時間窗。 第五步:發(fā)射兩串脈沖產(chǎn)生干擾波。測量過零時間與回波的振幅。如果逆向發(fā)生在回波中,決定要不通過在低氣壓插入振幅。 第六步:通過公式計算距離y。5.超聲波測距系統(tǒng)的軟件設(shè)計 軟件分為兩局部,主程序和中斷效勞程序。主程序完成初始化工作、各路超聲波發(fā)射和接收順序
13、的控制。定時中斷效勞子程序完成三方向超聲波的輪流發(fā)射,外部中斷效勞子程序主要完成時間值的讀取、距離計算、結(jié)果的輸出等工作。6.結(jié)論 對所要求測量范圍30cm200cm內(nèi)的平面物體做了屢次測量發(fā)現(xiàn),且重復性好??梢娀趩纹瑱C設(shè)計的超聲波測距系統(tǒng)具有硬件結(jié)構(gòu)簡單、工作可靠、測量誤差小等特點。因此,它不僅可用于移動機器人,還可用在其它檢測系統(tǒng)中。 思考:至于為什么接收不用晶體管做放大電路呢,因為放大倍數(shù)搞不好,集成放大電路,還帶自動電平增益控制,放大倍數(shù)為76dB,中心頻率是38k到40k,剛好是超聲波傳感器的諧振頻率。英文翻譯Ultrasonic ranging system designABST
14、RACT:Ultrasonic ranging technology has wide using worth in many fields, such as the industrial locale, vehicle navigation and sonar engineering. Now it has been used in level measurement, self-guided autonomous vehicles, fieldwork robots automotive navigation, air and underwater target detection, id
15、entification, location and so on. So there is an important practicing meaning to learn the ranging theory and ways deeply. To improve the precision of the ultrasonic ranging system in hand, satisfy the request of the engineering personnel for the ranging precision, the bound and the usage, a portabl
16、e ultrasonic ranging system based on the single chip processor was developed.Keywords:Ultrasound r, Ranging System, Single Chip Processor With the development of science and technology, the improvement of peoples standard of living, speeding up the development and construction of the city. urban dra
17、inage system have greatly developed their situation is constantly improving. However, due to historical reasons many unpredictable factors in the synthesis of her time, the city drainage system. In particular drainage system often lags behind urban construction. Therefore, there are often good build
18、ing excavation has been building facilities to upgrade the drainage system phenomenon. It brought to the city sewage, and it is clear to the city sewage and drainage culvert in the sewage treatment system. comfort is very important to peoples lives. Mobile robots designed to clear the drainage culve
19、rt and the automatic control system Free sewage culvert clear guarantee robot, the robot is designed to clear the culvert sewage to the core. Control System is the core component of the development of ultrasonic range finder. Therefore, it is very important to design a good ultrasonic range finder.2
20、.The SCM describes A microcontroller (or MCU) is a computer-on-a-chip.It is a type of microprocessor emphasizing self-sufficiency and cost-effectiveness, in contrast to a general-purpose microprocessor (the kind used in a PC). The majority of computer systems in use today are embedded in other machi
21、nery, such as telephones, clocks, appliances, vehicles, and infrastructure. An embedded system usually has minimal requirements for memory and program length and may require simple but unusual input/output systems. For example, most embedded systems lack keyboards, screens, disks, printers, or other
22、 recognizable I/O devices of a personal computer. They may control electric motors, relays or voltages, and read switches, variable resistors or other electronic devices. Often, the only I/O device readable by a human is a single light-emitting diode, and severe cost or power constraints can even el
23、iminate that. In contrast to general-purpose CPUs, microcontrollers do not have an address bus or a data bus, because they integrate all the RAM and non-volatile memory on the same chip as the CPU. Because they need fewer pins, the chip can be placed in a much smaller, cheaper package. Integrating t
24、he memory and other peripherals on a single chip and testing them as a unit increases the cost of that chip, but often results in decreased net cost of the embedded system as a whole. (Even if the cost of a CPU that has integrated peripherals is slightly more than the cost of a CPU + external periph
25、erals, having fewer chips typically allows a smaller and cheaper circuit board, and reduces the labor required to assemble and test the circuit board). This trend leads to design. A microcontroller is a single integrated circuit, commonly with the following features:central processing unit - ranging
26、 from small and simple 4-bit processors to sophisticated 32- or 64-bit processors input/output interfaces such as serial ports (UARTs) other serial communications interfaces like IC, Serial Peripheral Interface and Controller Area Network for system interconnect peripherals such as timers and watchd
27、og RAM for data storage ROM, EPROM, EEPROM or Flash memory for program storage clock generator - often an oscillator for a quartz timing crystal, resonator or RC circuit many include analog-to-digital converters This integration drastically reduces the number of chips and the amount of wiring and PC
28、B space that would be needed to produce equivalent systems using separate chips and have proved to be highly popular in embedded systems since their introduction in the 1970s. Some microcontrollers can afford to use a Harvard architecture: separate memory buses for instructions and data, allowing ac
29、cesses to take place concurrently. The decision of which peripheral to integrate is often difficult. The Microcontroller vendors often trade operating frequencies and system design flexibility against time-to-market requirements from their customers and overall lower system cost. Manufacturers have
30、to balance the need to minimize the chip size against additional functionality.3. A principle of ultrasonic distance measurement 3.1 The principle of piezoelectric ultrasonic generator Piezoelectric ultrasonic generator is the use of piezoelectric crystal resonators to work. Ultrasonic generator, th
31、e internal structure as shown, it has two piezoelectric chip and a resonance plate. When its two plus pulse signal, the frequency equal to the intrinsic piezoelectric oscillation frequency chip, the chip will happen piezoelectric resonance, and promote the development of plate vibration resonance, u
32、ltrasound is generated. Conversely, if the two are not inter-electrode voltage, when the board received ultrasonic resonance, it will be for vibration suppression of piezoelectric chip, the mechanical energy is converted to electrical signals, then it becomes the ultrasonic receiver. The traditional
33、 way to determine the moment of the echos arrival is based on thresholding the received signal with a fixed reference. The threshold is chosen well above the noise level, whereas the moment of arrival of an echo is defined as the first moment the echo signal surpasses that threshold. The intensity o
34、f an echo reflecting from an object strongly depends on the objects nature, size and distance from the sensor. Further, the time interval from the echos starting point to the moment when it surpasses the threshold changes with the intensity of the echo. As a consequence, a considerable error may occ
35、ur Even two echoes with different intensities arriving exactly at the same time will surpass the threshold at different moments. The stronger one will surpass the threshold earlier than the weaker, so it will be considered as belonging to a nearer object.3.2The principle of ultrasonic distance measu
36、rement Ultrasonic transmitter in a direction to launch ultrasound, in the moment to launch the beginning of time at the same time, the spread of ultrasound in the air, obstacles on his way to return immediately, the ultrasonic reflected wave received by the receiver immediately stop the clock. Ultra
37、sound in the air as the propagation velocity of 340m / s, according to the timer records the time t, we can calculate the distance between the launch distance barrier (s), that is: s = 340t /2. 4.Ultrasonic Ranging System for the Second Circuit Design System is characterized by single-chip microcomp
38、uter to control the use of ultrasonic transmitter and ultrasonic receiver since the launch from time to time, single-chip selection of 8751, economic-to-use, and the chip has 4K of ROM, to facilitate programming. Circuit schematic diagram shown in Figure 1. Figure 1 circuit principle diagram4.1 40 k
39、Hz ultrasonic pulse generated with the launch Ranging system using the ultrasonic sensor of piezoelectric ceramic sensors UCM40, its operating voltage of the pulse signal is 40kHz, which by the single-chip implementation of the following procedures to generate. puzel: mov 14h, # 12h; ultrasonic firi
40、ng continued 200ms here: cpl p1.0; output 40kHz square wave nop; nop; nop; djnz 14h, here; ret Ranging in front of single-chip termination circuit P1.0 input port, single chip implementation of the above procedure, the P1.0 port in a 40kHz pulse output signal, after amplification transistor T, the d
41、rive to launch the first ultrasonic UCM40T, issued 40kHz ultrasonic pulse, and the continued launch of 200ms. Ranging the right and the left side of the circuit, respectively, then input port P1.1 and P1.2, the working principle and circuit in front of the same location. 4.2 Reception and processing
42、 of ultrasonic Used to receive the first launch of the first pair UCM40R, the ultrasonic pulse modulation signal into an alternating voltage, the op-amp amplification IC1A and after polarization IC1B to IC2. IC2 is locked loop with audio decoder chip LM567, internal voltage-controlled oscillator cen
43、ter frequency of f0 = 1/1.1R8C3, capacitor C4 determine their target bandwidth. R8-conditioning in the launch of the carrier frequency on the LM567 input signal is greater than 25mV, the output from the high jump 8 feet into a low-level, as interrupt request signals to the single-chip processing. Ra
44、nging in front of single-chip termination circuit output port INT0 interrupt the highest priority, right or left location of the output circuit with output gate IC3A access INT1 port single-chip, while single-chip P1.3 and P1. 4 received input IC3A, interrupted by the process to identify the source
45、of inquiry to deal with, interrupt priority level for the first left right after. Part of the source code is as follows: receive1: push psw push acc clr ex1; related external interrupt 1 jnb p1.1, right; P1.1 pin to 0, ranging from right to interrupt service routine circuit jnb p1.2, left; P1.2 pin
46、to 0, to the left ranging circuit interrupt service routine return: SETB EX1; open external interrupt 1 pop acc pop psw reti right: .; right location entrance circuit interrupt service routine Ajmp Return left: .; left Ranging entrance circuit interrupt service routine Ajmp Return 4.3 The calculatio
47、n of ultrasonic propagation time When you start firing at the same time start the single-chip circuitry within the timer T0, the use of timer counting function records the time and the launch of ultrasonic reflected wave received time. When you receive the ultrasonic reflected wave, the receiver cir
48、cuit outputs a negative jump in the end of INT0 or INT1 interrupt request generates a signal, single-chip microcomputer in response to external interrupt request, the implementation of the external interrupt service subroutine, read the time difference, calculating the distance . Some of its source
49、code is as follows: RECEIVE0: PUSH PSW PUSH ACC CLR EX0; related external interrupt 0 MOV R7, TH0; read the time value MOV R6, TL0 CLR C MOV A, R6 SUBB A, # 0BBH; calculate the time difference MOV 31H, A; storage results MOV A, R7 SUBB A, # 3CH MOV 30H, A SETB EX0; open external interrupt 0 POP ACC
50、POP PSW RETI For a flat target, a distance measurement consists of two phases: a coarse measurement and. a fine measurement: Step 1: Transmission of one pulse train to produce a simple ultrasonic wave. Step 2: Changing the gain of both echo amplifiers according to equation , until the echo is detected. Step 3: Detection of the amplitudes and zero-crossing times of both echoes. Step 4: Setting the gains of both echo amplifiers to normalize the output at, say 3 volts. Set
溫馨提示
- 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請下載最新的WinRAR軟件解壓。
- 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
- 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁內(nèi)容里面會有圖紙預(yù)覽,若沒有圖紙預(yù)覽就沒有圖紙。
- 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
- 5. 人人文庫網(wǎng)僅提供信息存儲空間,僅對用戶上傳內(nèi)容的表現(xiàn)方式做保護處理,對用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對任何下載內(nèi)容負責。
- 6. 下載文件中如有侵權(quán)或不適當內(nèi)容,請與我們聯(lián)系,我們立即糾正。
- 7. 本站不保證下載資源的準確性、安全性和完整性, 同時也不承擔用戶因使用這些下載資源對自己和他人造成任何形式的傷害或損失。
最新文檔
- 蔬菜代售合同范本
- 2025年中國字車馬達板行業(yè)市場發(fā)展前景及發(fā)展趨勢與投資戰(zhàn)略研究報告
- 七年級語文下冊課文知識點總結(jié)
- 七上文言文《寓言二則》知識歸納
- 環(huán)境影響評價報告公示年產(chǎn)3萬噸聚羧酸高性能減水劑生產(chǎn)線技改項目環(huán)評
- 2025年中國沙漠旅游行業(yè)市場供需格局及行業(yè)前景展望報告
- 高校教師韓雷:從一方灶臺走向三尺講臺
- 2025年網(wǎng)絡(luò)通信柜行業(yè)深度研究分析報告
- 【報告】苯乙烯和二乙烯基苯共聚實驗報告
- 磷石膏綜合利用項目可行性研究報告
- 一年級下冊勞動教案
- 付款申請英文模板
- 大同大學綜測細則
- 生活會前談心談話提綱
- 比較思想政治教育(第二版)第十二章課件
- 普通外科常見疾病臨床路徑
- 人教版九年級下冊初中英語全冊作業(yè)設(shè)計一課一練(課時練)
- 2021新版GJB9001C-2017體系文件內(nèi)審檢查表
- 風篩式清選機的使用與維護
- 《計算流體力學CFD》
- 馬克思主義宗教觀課件
評論
0/150
提交評論