資源描述:
《手機藍牙的遙控小車的設(shè)計說明》由會員上傳分享,免費在線閱讀,更多相關(guān)內(nèi)容在行業(yè)資料-天天文庫。
1、.word格式,藍牙小車課程設(shè)計報告車課程設(shè)姓名:馬堅文班級:電子201201班指導(dǎo)老師:程智學(xué)號:201203043124日期:2014年6月6日,專業(yè).專注..word格式,手機藍牙的遙控小車的設(shè)計一控制系統(tǒng)31.1控制系統(tǒng)總體框圖31.2單片機最小系統(tǒng)的實現(xiàn)31.3系統(tǒng)的仿真與調(diào)試51.4步進電機驅(qū)動電路的實現(xiàn)61.5軟件設(shè)計71.6功能檢測與調(diào)試8二藍牙技術(shù)組成92.1藍牙無線電技術(shù)92.2藍牙互操作性92.3初始化本地藍牙9}2.4搜索藍牙設(shè)備102.5串口通信設(shè)計112.6單片機編程設(shè)計11三結(jié)語12四心得體會12五參考文獻13摘要:遙控電動小車
2、系統(tǒng)以89C52單片機為核心控制器,包含了主控制器模塊、電機驅(qū)動模塊、液晶顯示模塊、鍵盤模塊、測距模塊、藍牙通信模塊、電源模塊等。進而設(shè)計制作出一臺具有自動運行的智能小車控制系統(tǒng)。本系統(tǒng)以兩個步進電機作為驅(qū)動,通過各類傳感器件來采集各類信息,通過2.4GHz藍牙通信模塊實現(xiàn)小車在手機遙控的控制下前進、轉(zhuǎn)向、倒退、小車精確轉(zhuǎn)彎、自動定位等功能。智能小車系統(tǒng)具有很高的靈敏度和精確度,操控簡單、便捷。關(guān)鍵詞:89C52單片機;電動小車;電機驅(qū)動;藍牙軟件;手機TheDesignofRemoteControlElectricCarControlSystemBased
3、onBluetoothand89C52MCUAbstract:Theremotecontrolelectriccarsystemwith89C52asthecorecontroller,consistsofmaincontroller,專業(yè).專注..word格式,module,motordrivemodule,LCDmodule,keyboardmodule,rangingmodule,Bluetoothcommunicationmodule,powermodule,etc.Onthisbasis,anintelligentcarcontrolsystemi
4、sdesigned.Thissystemadoptstwosteppermotorsasthedrive,usesvariouskindsofsensortocollectallkindsofinformation,andutilizesthe2.4GHzBluetoothcommunicationmoduletoachievetheforwarding,back-warding,returning,automaticallyturningandpositioningofthecarunderthecontrolofhandholdwirelessremot
5、econtroller.Theintelligentcarsystemhashighsensitivityandaccuracy,anditsmanipulationissimpleandconvenient.Keywords:89C52;electriccar;motordrive;Bluetoothcommunication一控制系統(tǒng)1.1控制系統(tǒng)總體框圖本設(shè)計要求能夠?qū)崿F(xiàn)電動小車在手持無線遙控器的控制下前進、轉(zhuǎn)向、倒退等功能,而且能夠?qū)⑵湮恢玫淖鴺?biāo)值實時傳送至手持無線遙控器。考慮這些要求,我們決定用步進電機和單片機等組成核心電路[1-6]。系統(tǒng)總框圖如
6、圖1所示。圖1控制系統(tǒng)總框圖1.2單片機最小系統(tǒng)的實現(xiàn)單片最小系統(tǒng)由復(fù)位電路、電源和時鐘電路等組成。復(fù)位電路包括手動復(fù)位和自動上電復(fù)位,按鍵手動復(fù)位有電平方式和脈沖方式兩種。其中,按鍵電平復(fù)位是通過使復(fù)位端經(jīng)電阻與VCC電源接通而實現(xiàn)的。而按鍵脈沖復(fù)位則是利用RC,專業(yè).專注..word格式,微分電路產(chǎn)生的正脈沖來實現(xiàn)的。自動上電復(fù)位,是指計算機加電瞬間,要在RST引腳出現(xiàn)大于2個機器周期的正脈沖,使單片機進入復(fù)位狀態(tài)。單片機最小系統(tǒng)原,專業(yè).專注..word格式,L298N驅(qū)動電機電路,供給+5V和+12V電壓1.3系統(tǒng)的仿真與調(diào)試用簡單程序仿真測試電路連
7、接情況匯編程序代碼:org0000hajmpmainorg0080hmain:mova,#0ffhmovp1,a;不轉(zhuǎn)calldelay;延時loop:mova,#00ah;正轉(zhuǎn)movp1,acalldelaymova,#0ffh;停止movp1,acalldelaymova,#005h;反轉(zhuǎn)movp1,acalldelay,專業(yè).專注..word格式,mova,#0ffh;停止movp1,acalldelayjmploopdelay:movr5,#50;延時。d1:movr6,#40d2:movr7,#248djnzr7,$djnzr6,d2djnzr5,
8、d1retend仿真結(jié)果:電機正反轉(zhuǎn)均正常小車程序: