Example: bachelor of science

Flash Programming Solutions for the …

1 IntroductionApplicationReportSPRAAL3 (DSC)developmentcycle:firmwaredebug,prot otyping,production, ,UsefulDocumentation, , , August2008 TMS320F28xxxDSCs1 SubmitDocumentationFeedbackUser sApplicationFlash APIF lash AlgosOTP/FlashArray ControlBoot ROMJTAGSARAMAPI CodeExecutionOTP andFlashArrayCPUCTMS320F28xxxI2C-AeCAN-A SCI-AParallelCode (write) ,theFlashmustgothroughanerase,program, (RAM).Thesealgorithmsmustbeconfiguredfor thepropercentralprocessingunit(CPU) (API)algorithmsat[1],[2],[7]and[8]. )JTAG,b)Serial,andc) :TIHome DigitalSignalProcessing ProcessorPlatforms C2000 HighPerformance32-BitControllers ,IEEES tandardTestAccessPortandBoundary-ScanArc hitecture(JTAG)solutionscanapplytoallsta gesofthedevelopmentcycle,butarepredomina telyusedinthefirmwaredebugandprototyping stagesasthismethodallowsadesignertoprogr amtheFlashandthendebugitwithintheCodeCom poserStudio ,SDFlash, developmentboard, , ,thisprogrammerisavailableatF281xFlashTo ols[1],F280xFlashTools[2] , (GUI). , , , , , : LoadSymbols-Enables/DisablesCodeComposer StudiotoLoadSymbolsdirectlyafterprogramm ingFlashtoenabledebugging.

2.1.1.5 Code Security Password 2.1.2 Programming Example www.ti.com JTAG Solutions The Code Security Password portion of the programmer directly accesses the Code Security Module

Tags:

  Programming, Solutions, Flash, Flash programming solutions for the

Information

Domain:

Source:

Link to this page:

Please notify us if you found a problem with this document:

Other abuse

Advertisement

Transcription of Flash Programming Solutions for the …

1 1 IntroductionApplicationReportSPRAAL3 (DSC)developmentcycle:firmwaredebug,prot otyping,production, ,UsefulDocumentation, , , August2008 TMS320F28xxxDSCs1 SubmitDocumentationFeedbackUser sApplicationFlash APIF lash AlgosOTP/FlashArray ControlBoot ROMJTAGSARAMAPI CodeExecutionOTP andFlashArrayCPUCTMS320F28xxxI2C-AeCAN-A SCI-AParallelCode (write) ,theFlashmustgothroughanerase,program, (RAM).Thesealgorithmsmustbeconfiguredfor thepropercentralprocessingunit(CPU) (API)algorithmsat[1],[2],[7]and[8]. )JTAG,b)Serial,andc) :TIHome DigitalSignalProcessing ProcessorPlatforms C2000 HighPerformance32-BitControllers ,IEEES tandardTestAccessPortandBoundary-ScanArc hitecture(JTAG)solutionscanapplytoallsta gesofthedevelopmentcycle,butarepredomina telyusedinthefirmwaredebugandprototyping stagesasthismethodallowsadesignertoprogr amtheFlashandthendebugitwithintheCodeCom poserStudio ,SDFlash, developmentboard, , ,thisprogrammerisavailableatF281xFlashTo ols[1],F280xFlashTools[2] , (GUI). , , , , , : LoadSymbols-Enables/DisablesCodeComposer StudiotoLoadSymbolsdirectlyafterprogramm ingFlashtoenabledebugging.

2 DisplayTooltips Enables/Disablesdetailswithintheprogramm erwhenhoveringoveranoption. DisplayDiagnostics Enables/Disablesoutputscreenthatdisplays thestatusofprogramming. SaveClockSettings , : SpecifyingaCOFFFile , Erase,Program,andVerifyOperations Thesebuttonsallowtheerase,program,andver ifyoperationstosimultaneouslyrunorexecut eeachoperationindividually. DepletionRecovery Thisoptioninvokesthedepletionrecoveryalg orithmthatlooksforsectorsthatareindeplet ionandattemptstorecoverthem. FrequencyTest (GPIO)pinofchoice. CalculateChecksums PerformsachecksumoftheFlash,one-timeprog rammable(OTP),andFlash+OTP. LoadRAMOnly Thisoptionloadsinitializedsectionsthatar especifiedtorunfromRAM. WaitStates Duringprogramming,theWaitStatesfortheFla shandOTParesetwiththeseoptions. ExecuteOperation Thisbuttonwillexecutewhateveroptionissel ected. Help (CSM) ,seetheCodeSecurityModule(CSM)sectionof[ 10],[11]and[12].Thisportionoftheprogramm ercontainsthefollowingelements: KEY0 KEY7-16-bitpasswordlocations. Unlock UnlocksFlashifCSMissecuredandpasswordsar ewritteninKEY0 KEY7.

3 Lock LockstheFlashiftheCSMhaspreviouslybeenpr ogrammedwiththepasswordswritteninKEY0 KEY7. ProgramPassword ProgramsthepasswordstotheCSMthatiswritte ninKEY0 , , ,theTMS320F28335eZdsp, ,andFlashexamplefromRunninganApplication fromInternalFlashMemoryontheTMS320F28xxx DSP(SPRA958)[3] OpenfollowedbyProject ,Program, ,theprogramisstoredontheFlashandtheboard isreadyforstandaloneoperationordebugging ,throughCodeComposerStudio, , , ,algorithms,exampleprojects,andfulldocum entationexplaininghowtousetheutilityarea vailableattheSDFlashUtilityhomepage[4].T MS320F28xxxDSCs6 SPRAAL3 ,erase, Programming , ,thesettingsareconfiguredbyselectingProj ect-> : Driver SelectstheCodeComposerStudioemulationdri verusedtocommunicatewiththedevice. EmulatorAddress/ID BoardFile-ProvidesinformationtotheSDFlas hregardingthenumberofdevicesontheJTAG scanchain. ProcessorName : AlgorithmFile Timeout Settimeoutfortheeraseprocessintermsofsec onds. UserOptions2/UserOptions4 NotUsed. UserOptions3 Runfrequencytoggletest.

4 ST0/ST1/PMST/PMSTA ddress : AlgorithmFile FlashDataFile Timeout Settimeoutfortheprogrammingprocessinterm sofseconds. UserOptions3 Runfrequencytoggletest. UserOptions1/UserOptions2/UserOptions4 NotUsed. ST0/ST1/PMST/PMSTA ddress : AlgorithmFile Timeout Settimeoutfortheverifyprocessintermsofse conds. UserOptions1/UserOptions2 SpecifywaitstatesusedfortheFlashandOTPdu ringtheverifyoperation. UserOptions3-Runfrequencytoggletest. UserOptions4 NotUsed. ST0/ST1/PMST/PMSTA ddress ,theTMS320F28335eZdsp, (providedSDFlashproject),andFlashexample fromRunninganApplicationfromInternalFlas hMemoryontheTMS320F28xxxDSP(SPRA958)[3] [4]. , , , (Inthisexample, (SPRA958)[3].) , ,CSM,depletionrecovery, JTAGjet-TMS-C2000emulatorwithouttheneedo fCodeComposerStudio, [5]. (SCI) , ,theutility, [4].Someapplicationsrequirere-programmin gallorpartoftheFlashmemoryorOTPblocktore configuretheapplicationcodeortostoredata ( ,calibrationparameters) ;inthiscontext, , ,theFlashroutines(erase,writeoperations) , ,entireFlashAPIneedstobecopiedtoRAM; , , , , WhenusingtheFlashAPI,buildyourcodewithth elargememorymodel.

5 TheAPIL ibraryisbuiltin28xObjectcode(OBJMODE=1,A MODE=1) (PLLCR) , (optional).IftheAPIistobecopiedfromFlash /OTPintointernalSARAM memory, , (optional). (optional). (optional). : Thewatchdogtimerisdisabled. ChecksthePARTID(memorylocation0x0882)reg istertomakesurethepartisthecorrectdevice Performsthecalledoperationand: Disablesandrestoresglobalinterrupts(viaI NTM,DBGM,XNMICR)aroundtimecriticalcodese gments. InvokesthecallbackfunctionifFlash_Callba ckPtrisnotNULL (optional).12 TMS320F28xxxDSCsSPRAAL3 sandDon t s5 ProductionSolutions6 Debugging,UsefulDocumentation, APIDo s (L0-L3)andonewaitstateSARAM(L4-L7).TheFl ashAPIsshouldberunfromL0-L3 SARAM. ConfiguretheAPIforthecorrectCPUfrequency ofoperation. FollowthechecklistoftheFlashAPIdocumenta tiontointegratetheAPIintoanapplication. InitializethePLLCR andwaitforthePLLtolockbeforecallinganAPI function. InitializetheAPIcallbackfunctionpointer( Flash_CallbackPtr).Ifthecallbackfunction isnotgoingtobeused, CarefullyreviewtheAPIrestrictionsforthec allbackfunction,interrupts,andwatchdogth ataredescribedinthedocument.

6 APIDon ts ,theymustfirstbecopiedtointernalzero-wai tstateSARAM beforetheyareexecuted. Donotexecuteanyinterruptserviceroutines( ISRs)thatcanoccurduringanerase, ,programordepletionrecoveryroutine, Donotstoptheerase,programordepletionreco veryfunctionswhiletheyareexecuting(forex ample,don tstopthedebuggerwithinAPIcode,don tresetthepart,etc). DonotexecutecodeorfetchdatafromtheFlasha rrayorOTPwhiletheFlashand/orOTPisbeinger ased, , (runningonPC) (.out) (>1K).Forlargerquantities, [1]andF280xFlashtools[2]. , ,precautions,etc., ,UsefulDocumentation, , :Run,Halt,SingleStep,ResetCPU, LoadSymbols , (seeFigure14). Customize Program/ ,however, ,seeRunninganApplicationfromInternalFlas hMemoryontheTMS320F28xxxDSP(SPRA958)[3]. ,seeCopyingCompilerSectionsFromFlashtoRA MontheTMS320F28xxxDSCs(SPRAAU8)[6].[3] , ,seeTMS320F281xBootROMS erialFlashProgramming(SPRAAQ2)[9]. : , , :IfFlashisindepletionmode,thedepletionre coveryfunctionalityprovidedwiththeCodeCo mposerStudioOn-ChipFlashProgrammerandSDF lashcanbeusedtoattempttobringtheFlashout ofdepletion.

7 EnsurethattheCSMpasswordlocationslocated ataddresses0x3F7FF8 ,thepasswordwillbewrittenwiththeprojectc odeandthepasswordwillbeunknowncausingthe Flashtobepermanentlylocked. WhenusingtheFlashAPI,youcannotmodifytheF lashmemorywhilerunningfromFlashrequiring thatthealgorithmsberanfrominternalRAM. , :JTAG,Serial,Embedded, , : : (SPRA958) : : (SPRAAU8) :TMS320F2823xFlashAPIs(SPRC665) :TMS320F2833xFlashAPIs( )(SPRC539) (SPRAAQ2) (SPRU078) ,2801x,2804xDSPS ystemControlandInterruptsReferenceGuide( SPRU712) ,2823xSystemControlandInterruptsReferenc eGuide(SPRUFB0)SPRAAL3 August2008 TMS320F28xxxDSCs15 SubmitDocumentationFeedbackIMPORTANTNOTI CET exasInstrumentsIncorporatedanditssubsidi aries(TI)reservetherighttomakecorrection s,modifications,enhancements,improvement s, , , ,eitherexpressorimplied,isgrantedunderan yTIpatentright,copyright,maskworkright,o rotherTIintellectualpropertyrightrelatin gtoanycombination,machine, , ,conditions,limitations, (suchaslifesupport)whereafailureoftheTIp roductwouldreasonablybeexpectedtocausese verepersonalinjuryordeath, ,andacknowledgeandagreethattheyaresolely responsibleforalllegal,regulatoryandsafe ty-relatedrequirementsconcerningtheirpro ductsandanyuseofTIproductsinsuchsafety-c riticalapplications, , "enhancedplastic.

8 " 'srisk, ,iftheyuseanynon-designatedproductsinaut omotiveapplications, :TexasInstruments,PostOfficeBox655303,Da llas,Texas75265 Copyright 2008,TexasInstrumentsIncorporat


Related search queries