dsp2812flash运行程序加速的方法

dsp2812flash运行程序加速的方法

ID:35530844

大小:84.44 KB

页数:6页

时间:2019-03-25

dsp2812flash运行程序加速的方法_第1页
dsp2812flash运行程序加速的方法_第2页
dsp2812flash运行程序加速的方法_第3页
dsp2812flash运行程序加速的方法_第4页
dsp2812flash运行程序加速的方法_第5页
资源描述:

《dsp2812flash运行程序加速的方法》由会员上传分享,免费在线阅读,更多相关内容在行业资料-天天文库

1、日期:2009.3.11上午9:49刚刚把2812内部flash运行程序加速调试通了,结果比较成功。为了以后少走弯路,把刚才的调试过程记录一下。参考的资料是TI的RunninganApplicationfromInternalFlashMemoryontheTMS320F28xxxDSP,文档编号是SPRA958H。由于我是采用的自己编写CMD的方式,所以工程属于Non-DSP/BIOSProjectso内部flash运行加速需要添加的文件有CodeStartBranch.asm,Passwords.asm,DSP281x_MemCopy.c,另外还需要有voidInitFlash(void

2、)函数完成对FLASH的初始化配置。1.InitializingtheFlashControlRegisters(DSP/BIOSandnon-DSP/BIOSprojects)^pragmaCODE_SECTIOK(InitFlash,'fsecureRairrjncsn)voidInitFlash(void)asm(nEALLOW11);FlashRegs.FPWR.bit.PWR二3;FlashRegs.FSTATJS.bit.V3STAT=1;//EnableEALLOWprotectedregisteraccess//Flashsettoactivenode//Clearthe3V

3、STATbit//SleeptostandbycyclesFlashRegs.FSTEBYWAIT.bit.STDBYV?AIT二OxOlFF;FlashRegs.FACTIVE祛I?.bit.UnVEWAITOxOlFF;//StandbytoactivecyclesFlashRegs.FBANKWAIT.bit.RANDWAIT二3;FlashRegs.FBAKKWAIT.bit.PAGEWA:T=3;FlashRegs.FOTPWAIT.b辻.OTPWAIT=5;FlashRegs.FOPT.bit.ENPIPE=1;//F280xRandomaccesswaitstates//F28

4、0xPagedaccesswaitstates//F280xOTPwaitstates//Enabletheflashpipeline//DisableEALLOWprotectedregisteraccess***Forceacompletepipelineflushtoensurethatthewritetoth?lastregisterconfiguredoccursbeforereturning.Safestthingistowait8fullcycles.***asm(nRPT#6

5、

6、NOP”);}//endofInitFlashf)★User1slinkercoirjnandfi

7、leSECTIONS{/***UserDefinedSections***/secureRamFuncs:LOAD=FLASH,PAGE=0RUN=SECURE_RAM,PAGE=0RUN_START(_secureRamFuncs_runstart)fL0A3_START(_secureRamFuncs_loadsta工t)fLOAD_END(_secureRamFuncs_loadend)}~~/★**'k*'k'k'k*'k*W*'k*'k*'k*'k***'k*'k***********'k*'k*'k*'k'k*********'k***'k********ak*User1sC-s

8、ourcefile★**★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★責★★★★/irincludeexternunsignedintexrernunsignedintexternunsignedintsecureRamFuncs_loadstart;secureRamFuncs_loadend;secureRamFuncs_runstart;voidmain(void){^/★CopythesecureRamFuncssection*/ir.emcpy(&secureRair.Funcs_runstart#&secureRar.Funcs_load

9、stRMt#&secureRair.Funcs_loaaend-&secureRamFuncs_loadstazrt);/*Initializetheon-chipflashregisters*/InitFlash();}1.ProgrammingtheCodeSecurityModulePasswords*File:oasswords.asm★**t*******A****icA***A***A*i*i:*

当前文档最多预览五页,下载文档查看全文

此文档下载收益归作者所有

当前文档最多预览五页,下载文档查看全文
温馨提示:
1. 部分包含数学公式或PPT动画的文件,查看预览时可能会显示错乱或异常,文件下载后无此问题,请放心下载。
2. 本文档由用户上传,版权归属用户,天天文库负责整理代发布。如果您对本文档版权有争议请及时联系客服。
3. 下载前请仔细阅读文档内容,确认文档内容符合您的需求后进行下载,若出现内容与标题不符可向本站投诉处理。
4. 下载文档时可能由于网络波动等原因无法下载或下载错误,付费完成后未能成功下载的用户请联系客服处理。