Matlab-RTW實(shí)時(shí)仿真與嵌入式系統(tǒng)開發(fā)-史維佳_第1頁
Matlab-RTW實(shí)時(shí)仿真與嵌入式系統(tǒng)開發(fā)-史維佳_第2頁
Matlab-RTW實(shí)時(shí)仿真與嵌入式系統(tǒng)開發(fā)-史維佳_第3頁
全文預(yù)覽已結(jié)束

下載本文檔

版權(quán)說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請(qǐng)進(jìn)行舉報(bào)或認(rèn)領(lǐng)

文檔簡介

Matlab/RTWu給出一種開發(fā)嵌入式系統(tǒng)的新方法主要基于Matlab的RTW(Rea-lTimeWorkshop)工具箱的代碼生成功能,采用Keil作為中間工具,將RTW生成的C語言代碼轉(zhuǎn)換為單片機(jī)可以運(yùn)行的HEX文件,并利用Proteus軟件進(jìn)行仿真,以驗(yàn)證代碼的正確性,從而快速開發(fā)嵌入式系統(tǒng),并且實(shí)現(xiàn)了實(shí)時(shí)仿真測(cè)試結(jié)果驗(yàn)證了該方法的可行性與正確性Matlab/RTWKeilProteus快速原型法實(shí)時(shí)仿真嵌入式系統(tǒng)112,,,,Matlab/RTW2:,sMicrosoftWindowsXPSP3;2sMatlabVersion7.5.0.342(R2007b);2sKeiluVersion2V2.30;sProteus7.1SP2Matlab/RTW(CRTW(Rea-lStoptimeTypeInfTimeSolverFixed-step),KeilSolverOde5(Dormand-Prince)Matlab,DevicevendorIntelHardwareImplementationDevicetype8051CompatibleCSystemtargetfileErt.tlcHEX,Rea-lTimeWorkshopMake_rtwoptimized_floating_point=1ProteusMakecommand,,,Matlab_TestRea-lTimeWork-1shopBuild,Matlab1Matlab:###StartingRea-lTimeWorkshopbuildprocedureformodel:,2Matlab_Test12,,,,1Simulink,###SuccessfulcompletionofRea-lTimeWorkshopbuildproce-12,,dureformodel:Matlab_Test2,42200910adv@mesnet.com.cn()32rtmSetErrorStatus(Matlab_Test_M,"Overrun");RTWMatlab_Test_TLC(TgtLn-U.In1=P1_6;/Matlab_Test_rt_OneStep/*Stmodlinutsh*guageComil,)TLCU.In2=P1_7;ert_main.c/*Getmodeloutputshere*/P1_0=atlab_Test_Y.Out133int_Tmin(int_Targc,constch_T*argv[])intmain(void)rt_OneStep(),SimulinkTLCmin/*Initializemodel*/Printf(*****);3Cfflush(NULL);,,,HEXRTW,KeilErt.tlcProteus\ModelVDM51.dllRTW:Kil\C51\INC,1Min,ert_main.c,,TOOLS.INI,VDM51.DLL,4oMtlab_Test_initiliz,Min?rt_OneSt,MinMatlab_Test.c,,ert_main.c,,,Mtlb_Test_step?Mtlb_Tst_st,rt_OnStMtlb_Test.c,,/Mtlb_Test_Y.Out1=Mtlb_Test_U.In1+Matlab_Tst_U.In2;0,RTW:Mtlb_Test_U.In1Mtlb_Test_Y.Out11Mtlb_Test_U,,oMtlb_Test_Y,,3KeilKeilKeil4,AtmelcAT89C51,CPU,ert_,KeilKil,ProtusProteusMtlb*.c:1,min.cMatlab_Test.,;*.hProteusVSMMo-Mtlab_Test.hMatlab_Test_nito-51,Keil5vit.hMtlb_Tst_tys.hrtwtypes.hProtus320091043@mesnet.com.cn()Microcontrollers&EmbeddedSystmsDebug,,UseRemoteDebugMonitor80C51,,ProgramFileKeilHEX(Keil_Test.HEX),5,Matlab1Proteus,Matlab;o?Matlab,,5;,Proteus,P1.0,80C51,;,P1.6P1.7,6[1][2][3][4][5].Matlab/Simulink,1999.[M].:.[M].:,2003.,,,.Matlab/Simulink,2008.[M].:,.Matlab6.5[M].:,2003.,.Matlab[M].:,2008.何鵬舉(博士后副教授),研究方向?yàn)榫W(wǎng)絡(luò)化智能傳感器;史維佳李杰(本科)(收稿日期:2009-05-11)6Rea-ltimeSimulationandEmbeddedSystemDevelopmentBasedonMatlab/RTWNorthwesternPolytechnicalUniversityAnewmethodisproposedtodevelopanembeddedsystem.PrimarilybasedonthecodegenerationfunctionofMatlabRTW(Rea-lTimeWorkshop)toolbox,withtheKeilsoftwareasanintermediatetool,itcanchangetheCcodecreatedbyRTWtotheHEXfilethatMCUuses.Proteusisusedassimulationtooltoverifycodecorrectness;therefore,theembeddedsystemdevelopmentandrea-ltimesimulationprocessesarequickened.Thetestverified

溫馨提示

  • 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請(qǐng)下載最新的WinRAR軟件解壓。
  • 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請(qǐng)聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
  • 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁內(nèi)容里面會(huì)有圖紙預(yù)覽,若沒有圖紙預(yù)覽就沒有圖紙。
  • 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
  • 5. 人人文庫網(wǎng)僅提供信息存儲(chǔ)空間,僅對(duì)用戶上傳內(nèi)容的表現(xiàn)方式做保護(hù)處理,對(duì)用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對(duì)任何下載內(nèi)容負(fù)責(zé)。
  • 6. 下載文件中如有侵權(quán)或不適當(dāng)內(nèi)容,請(qǐng)與我們聯(lián)系,我們立即糾正。
  • 7. 本站不保證下載資源的準(zhǔn)確性、安全性和完整性, 同時(shí)也不承擔(dān)用戶因使用這些下載資源對(duì)自己和他人造成任何形式的傷害或損失。

評(píng)論

0/150

提交評(píng)論