版權(quán)說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請進(jìn)行舉報或認(rèn)領(lǐng)
文檔簡介
ProgrammingDevelopmentEnvironmentCopyright?2023TexasInstruments.Allrightsreserved.
TechnicalTrainingOrganizationT
TOModule2TMS320C28x?MCUWorkshop第1頁LearningObjectivesUseCodeComposerStudioto:CreateaProjectSetBuildOptionsCreateauserlinkercommandfilewhich:Describesasystem’savailablememoryIndicateswheresectionswillbeplacedinmemory第2頁LearningObjectivesUseCodeComposerStudioto:CreateaProjectSetBuildOptionsCreateauserlinkercommandfilewhich:Describesasystem’savailablememoryIndicateswheresectionswillbeplacedinmemory第3頁CodeComposerStudioCodeComposerStudioincludes:IntegratedEdit/DebugGUICodeGenerationToolsDSP/BIOSAsmLinkEditorDebugCompileGraphs,ProfilingCodeSimulatoreZdsp?ExternalEmulatorMCUBoardLibrarieslnk.cmdBuild第4頁CodeComposerStudio:IDEIntegrates:edit,codegeneration,anddebugSingle-clickaccessusingbuttonsPowerfulgraphing/profilingtoolsAutomatedtasksusingGELscriptsandCCSscriptingBuilt-inaccesstoBIOSfunctionsSupportsTIand3rdpartyplug-ins第5頁TheCCSProjectListoffiles:Source(C,assembly)LibrariesDSP/BIOSconfigurationfileLinkercommandfilesProjectsettings:Buildoptions(compiler,Linker,assembler,andDSP/BIOS)BuildconfigurationsProject(.pjt)filescontain:第6頁BuildOptionsGUI-CompilerGUIhas8pagesofcategoriesforcodegenerationtoolsControlsmanyaspectsofthebuildprocess,suchas:OptimizationlevelTargetdeviceCompiler/assembly/linkoptions第7頁BuildOptionsGUI-LinkerGUIhas3categoriesforlinkingSpecifyvariouslinkoptions.\DebugmeansthedirectorycalledDebugonelevelbelowthe.pjtfiledirectory$(Proj_dir)\Debugisanequivalentexpression第8頁DefaultBuildConfigurationsAdd/RemoveyourowncustombuildconfigurationsusingProjectConfigurationsEditaconfiguration:SetitactiveModifybuildoptionsSaveprojectFornewprojects,CCSautomaticallycreatestwobuildconfigurations:Debug (unoptimized)Release (optimized)Usethedrop-downmenutoquicklyselectthebuildconfiguration第9頁LearningObjectivesUseCodeComposerStudioto:CreateaProjectSetBuildOptionsCreateauserlinkercommandfilewhich:Describesasystem’savailablememoryIndicateswheresectionswillbeplacedinmemory第10頁SectionsAllcodeconsistsofdifferentpartscalledsectionsAlldefaultsectionnamesbeginwith“.”Thecompilerhasdefaultsectionnamesforinitializedanduninitializedsectionsint x=2;int y=7;voidmain(void){longz;z=x+y;}Globalvars(.ebss)Initvalues(.cinit)Localvars(.stack)Code(.text)第11頁CompilerSectionNamesName Description LinkLocation.text code FLASH.cinit initializationvaluesfor FLASH globalandstaticvariables.econst constants(e.g.constintk=3;) FLASH.switch tablesforswitchstatements FLASH.pinit tablesforglobalconstructors(C++)FLASHInitializedSectionsName Description LinkLocation.ebssglobalandstaticvariables RAM.stackstackspace low64KwRAM.esysmemmemoryforfarmallocfunctions RAMUninitializedSectionsNote: DuringdevelopmentinitializedsectionscouldbelinkedtoRAMsince theemulatorcanbeusedtoloadtheRAM第12頁P(yáng)lacingSectionsinMemory.ebss.cinit.textMemoryM0SARAM(0x400)0x0000000x3000000x000400M1SARAM(0x400)FLASH(0x40000)Sections.stack第13頁LinkingLinkerLink.cmd.map.obj.out
Memorydescription
Howtoplaces/wintoh/w第14頁LinkerCommandFileMEMORY{PAGE0:/*ProgramMemory*/FLASH:origin=0x300000,length=0x40000PAGE1:/*DataMemory*/M0SARAM:origin=0x000000,length=0x400M1SARAM:origin=0x000400,length=0x400}第15頁LinkerCommandFileMEMORY{PAGE0:/*ProgramMemory*/FLASH:origin=0x300000,length=0x40000PAGE1:/*DataMemory*/M0SARAM:origin=0x000000,length=0x400M1SARAM:origin=0x000400,length=0x400}SECTIONS{.text:>FLASHPAGE=0.ebss:>M0SARAMPAGE=1.cinit:>FLASHPAGE=0 .stack:> M1SARAM PAGE=1}第16頁Exercise2GenericF28xdeviceM0SARAM(0x400)M1SARAM(0x400)L0SARAM(0x1000)L1SARAM(0x1000)0x0000000x0004000x0080000x009000FLASH(0x40000)0x300000Createthelinkercommandfileforthegivenmemorymapbyfillingintheblanksonthefollowingslide第17頁MEMORY{PAGE__:/*ProgramMemory*/_____:origin=____
___,length=___
_________:/*DataMemory*/_______:origin=__
____,length=____________:origin=____
___,length=____________:origin=___
____,length=__
__________:origin=___
____,length=_
____}SECTIONS{.text:>FLASHPAGE=0.ebss:>M0SARAMPAGE=1.cinit:>FLASHPAGE=0.stack:>M1SARAMPAGE=1}Exercise2-CommandFile第18頁MEMORY{PAGE0:/*ProgramMemory*/
FLASH:origin=0x300000,length=0x40000
PAGE1:/*DataMemory*/
M0SARAM:origin=0x000000,length=0x400
M1SARAM:origin=0x000400,length=0x400
L0SARAM:origin=0x008000,length=0x1000
L1SARAM:origin=0x009000,length=0x1000}SECTIONS{.text:>FLASHPAGE=0.ebss:>M0SARAMPAGE=1.cinit:>FLASHPAGE=0.stack:>M1SARAMPAGE=1}Exercise2-Solution第19頁LinkerCommandFileSummaryMemoryMapDescriptionNameLocationSizeSectionsDescriptionDirectssoftwaresectionsintonamedmemoryregionsAllowsper-filediscriminationAllowsseparateload/runlocations第20頁Lab2:LinkerCommandFileSystemDescription:
TMS320F28335AllinternalRAMblocksallocatedPlacementofSections:
.textintoRAMBlockL0123SARAMonPAGE0(programmemory).cinitintoRAMBlockL0123SARAMonPAGE0(programmemory).ebssintoRAMBlockL4SARAMonPAGE1(datamemory).stackintoRAMBlockM1SARAMonPAGE1(datamemory)F28335Memoryon-chipmemory0x008000L0SARAM(0x1000)0x000400M1SARAM(0x400)0x00C000L4SARAM(0x1000)0x00B000L3SARAM(0x1000)0x000000M0SARAM(0x400)0x009000L1SARAM(0x1000)0x00A000L2SARAM(0x1000)0x00D000L5SARAM(0x1000)0x00E000L6SARAM(0x1000)0x00F000L7SARAM(0x1000)第21頁Lab2:Solution
溫馨提示
- 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)方式做保護(hù)處理,對用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對任何下載內(nèi)容負(fù)責(zé)。
- 6. 下載文件中如有侵權(quán)或不適當(dāng)內(nèi)容,請與我們聯(lián)系,我們立即糾正。
- 7. 本站不保證下載資源的準(zhǔn)確性、安全性和完整性, 同時也不承擔(dān)用戶因使用這些下載資源對自己和他人造成任何形式的傷害或損失。
最新文檔
- 2025年度個性化美發(fā)店服務(wù)股份制合作合同4篇
- 二零二五版新能源汽車充電樁投資分紅合同3篇
- 2025年倉儲租賃協(xié)議審核
- 二零二五年度木地板工程環(huán)保認(rèn)證與施工合同4篇
- 2025年民用航空器租賃合規(guī)審查協(xié)議
- 2025年度綠色校園綠植種植與教育推廣合同4篇
- 2024 年浙江公務(wù)員考試行測試題(A 類)
- 二零二五年度二手挖掘機(jī)轉(zhuǎn)讓與長期維護(hù)服務(wù)協(xié)議3篇
- 二零二五年度SSL協(xié)議安全審計與合規(guī)檢查合同3篇
- 2025年度鮮花電商物流配送與銷售合作協(xié)議3篇
- 2024年供應(yīng)鏈安全培訓(xùn):深入剖析與應(yīng)用
- 飛鼠養(yǎng)殖技術(shù)指導(dǎo)
- 壞死性筋膜炎
- 整式的加減單元測試題6套
- 股權(quán)架構(gòu)完整
- 山東省泰安市2022年初中學(xué)業(yè)水平考試生物試題
- 注塑部質(zhì)量控制標(biāo)準(zhǔn)全套
- 銀行網(wǎng)點(diǎn)服務(wù)禮儀標(biāo)準(zhǔn)培訓(xùn)課件
- 二年級下冊數(shù)學(xué)教案 -《數(shù)一數(shù)(二)》 北師大版
- 晶體三極管資料
- 石群邱關(guān)源電路(第1至7單元)白底課件
評論
0/150
提交評論