指導教授:張帆人臺灣大學:電機工程學研究所柯志陽Ke, Chih-YangChih-YangKe2014-11-282018-07-062014-11-282018-07-062014http://ntur.lib.ntu.edu.tw//handle/246246/262857室外定外系統已被發展多年,相當成熟,如全球定位系統(GPS)的服務被廣 泛使用在任何地方,然而室內定位系統發展還未到達此水準。 超音波裝置有眾多優點,如低成本,操作簡易等,但缺點則是超音波訊號在 空氣中衰減得相當嚴重,為了改善此現象,我們將直接展頻序列(Direct Sequence Spread Spectrum : DSSS)應用於超音波測距,在發射端以偽雜訊碼(Pseudo Random Noise Code : PRN Code)和二元相位反轉調變(Binary Phase Shift Keying :BPSK)來調變訊號,其偽雜訊碼速率為4KHz,長度為1023 碼片(Chips),載波頻率為40KHz。而在接收端,我們使用取樣頻率為320KHz 來截取超音波訊號。再使用複數解調變,相關運算,偵測真實峰值等,來計算超音波從發射端傳送訊號至接收端之飛行時間,再將其乘上當時的音速,其可得到發射端與接收端的距離。 在本文採用到達時間差(Time Difference of Arrival : TDOA)演算法,進行定位運算。本系統採用四組超音波發射器與一組超音波接收器實現。由於使用了直接展頻序列的技術主要貢獻有兩部分,第一部分是高處理增益(High ProcessingGain),即使強度低於背景雜訊的微弱超音波訊號仍可以被偵測,進而造成可測距距離長,定位範圍也可增廣。第二部分為具有良好的測距解析度,所以定位精準度提高。而此兩貢獻均由室內定位實驗結果得到佐證。Outdoor positioning systems have been matured for many years. Now days, people enjoy the service of GPS (Global Positioning System) almost everywhere at any time. However, the indoor positioning systems are still lacking. Ultrasonic devices own the advantages of low cost, simple operation etc. Unfortunately, the strength of sound wave decays quickly in the air. To overcome this disadvantage, we propose the direct sequence spread spectrum (DSSS) approach for range detection. The 4KHz rate pseudo random noise (PRN) code of 1023 chips are binary phase modulated to a 40KHz ultrasonic carrier as transmitting signal. At the receiving side, 320KHz sampler is used to collect all needed data for ranging. The complex number demodulation, correlation computation, peak detection, etc. will be applied to determine the travelling time of the signal from the transmitter to the receiver. The above value being multiplied with speed of sound will be the distance. Finally, TDOA (Time Difference of Arrival) model is used to get the position coordinate of the receiver when 4 ranging data are measured from 4 transmitters; respectively. The main contributions of spread spectrum technology are two. The first one is the high processing gain, so that the very weak ultrasonic signal can be detected even its power is less than that of environmental background noise. The second one is the fine ranging resolution, so that the positioning accuracy is improved. The proposed approach is confirmed by the indoor experiment results.致謝.................................................................................................................................i 中文摘要........................................................................................................................ii Abstract....................................................................................................................... iii 第一章緒論 .................................................................................................................1 1.1 研究動機..............................................................................................................1 1.2 章節介紹..............................................................................................................2 第二章超音波理論基礎.............................................................................................3 2.1 聲音基礎特性......................................................................................................3 2.1.1 聲音的原理...................................................................................................3 2.1.2 聲音的強度...................................................................................................4 2.1.3 聲音的速度...................................................................................................5 2.1.4 聲音的波長..................................................................................................6 2.2 超音波.................................................................................................................7 2.2.1 超音波原理..................................................................................................7 2.2.2 超音波感測器..............................................................................................7 2.2.3 超音波在空氣中的衰減............................................................................10 第三章直接序列展頻...............................................................................................13 3.1 DSSS 原理.........................................................................................................13 3.2 PRN Code ..........................................................................................................15 3.3 自相關函數.......................................................................................................16 v 第四章超音波測距原理與硬體架構.......................................................................19 4.1 超音波測距原理...............................................................................................19 4.1.1 發射端........................................................................................................19 4.1.2 接收端........................................................................................................22 4.2 硬體架構...........................................................................................................24 第五章大範圍超音波室內定位系統.......................................................................27 5.1 發射器...............................................................................................................27 5.2 接收器...............................................................................................................28 5.3 到達時間差定位演算法(TDOA).....................................................................29 5.3.1 二維TDOA 定位......................................................................................29 5.3.2 三維TDOA 定位......................................................................................30 5.4 反向定位法.......................................................................................................32 5.5 硬體架構...........................................................................................................33 第六章模擬與實驗結果...........................................................................................36 6.1 模擬結果...........................................................................................................36 6.1.1 PRN code 產生...........................................................................................36 6.1.2 背景雜訊....................................................................................................36 6.1.3 模擬環境設定與結果................................................................................38 6.2 實驗結果...........................................................................................................40 6.2.1 超音波測距實驗........................................................................................43 6.2.2 超音波定位實驗........................................................................................44 第七章結論與未來展望...........................................................................................53 6.1 結論...................................................................................................................53 vi 6.2 未來展望...........................................................................................................54 參考文獻......................................................................................................................552171100 bytesapplication/pdf論文公開時間:2014/08/08論文使用權限:同意有償授權(權利金給回饋學校)到達時間差定位演算法室內定位系統超音波訊號偽雜訊碼相關運算大範圍超音波定位系統Large Area Ultrasound Positioning Systemthesishttp://ntur.lib.ntu.edu.tw/bitstream/246246/262857/1/ntu-103-R01921069-1.pdf