MATLAB EMBEDDED IDE LINK 4 - FOR USE WITH TEXAS INSTRUMENTS CODE COMPOSER STUDIO Guide de l'utilisateur

Naviguer en ligne ou télécharger Guide de l'utilisateur pour Logiciel MATLAB EMBEDDED IDE LINK 4 - FOR USE WITH TEXAS INSTRUMENTS CODE COMPOSER STUDIO. MATLAB EMBEDDED IDE LINK 4 - FOR USE WITH TEXAS INSTRUMENTS CODE COMPOSER STUDIO User`s guide Manuel d'utilisatio

  • Télécharger
  • Ajouter à mon manuel
  • Imprimer
  • Page
    / 575
  • Table des matières
  • MARQUE LIVRES
  • Noté. / 5. Basé sur avis des utilisateurs
Vue de la page 0
Embedded IDE Link™
CC 3
User’s Guide
Vue de la page 0
1 2 3 4 5 6 ... 574 575

Résumé du contenu

Page 1 - User’s Guide

Embedded IDE Link™CC 3User’s Guide

Page 2 - Natick, MA 01760-2098

Core Support (ccslinklib_core) ... 8-3Target Preferences (ccslinklib_tgtpref)... 8-3Blocks — Alphabetical List9Embedded

Page 3 - Revision History

3 Project GeneratorThe Target Preferences library appears in the next figure.3-10

Page 4

About the CCSLinkLib Blockset3-11

Page 5

3 Project GeneratorSchedulers and TimingIn this section...“Configuring Models for Asynchronous Scheduling” on page 3-12“Using Asynchronous Scheduling”

Page 6 - Project Generator

Schedulers and TimingNote Models in this section are for example purposes only. You cannot buildand run them without additional blocks.Also, you can s

Page 7

3 Project GeneratorAlgorithm Inside the Function Call Subsystem BlockHere’s the model inside the function call subsystem in the previous figure. Itis t

Page 8 - Exporting

Schedulers and TimingThe function generated for this task normally runs in free-runningmode—repetitively and inde finitely. Sub sy stem execu tion of t

Page 9 - Functions — Alphabetical List

3 Project GeneratorIn this model, the Hardware Interrupt block installs a task that runs whenit detects an external interrupt. This task performs the

Page 10 - Parameters

Schedulers and Timing• Generated code that incorporates DSP /B IO S real-time operating sy stem(RTOS)• Generated code that does not include DSP/BIOS R

Page 11 - Reported Limitations and Tips

3 Project GeneratorWhen you p lan your project or algorithm, select your scheduling techniquebased on your application needs.• If your application pro

Page 12 - Contents

Schedulers and TimingTimer PeriodCPU Clock Rate Base Sample TimeLow Resolu_(_ _)*(_ _)_=ttion Clock DividerPrescaler__*Thesoftwareconfiguresthetimersot

Page 13 - Getting Started

Supported HardwareASupported Platforms for Embedded IDE Link CC ... A-2Supported Hardware and Simulators... A-2Product Features Suppor

Page 14 - Product Overview

3 Project Generator• C onnecting the ISRs to the corresponding interrupt service vector tableentriesNote You are responsible for m apping and enabling

Page 15 - Automation Interface

Schedulers and TimingOne way to add the custom code to your generated code is to add a SystemOutputs block to your model. In the System Outputs block,

Page 16 - 1 Getting Started

3 Project GeneratorTo enable and map the interrupts, add the code to the dialog box as shown inthe following figure.3-22

Page 17 - Verification

Schedulers and TimingGenerating code from your m o del that includes the System Outputs b lockadds the enabling and mapping code to your project so th

Page 18 - Configuration Information

3 Project GeneratorThe following figure shows a top-level model c6000_hwi_interrupts thatincludes the System Outputs block in the Function-Call Subsyst

Page 19

Schedulers and TimingMultitasking scheduling also means that overruns, where a task runs beyondits intended tim e, can occur during execution.To under

Page 20

3 Project Generator• Sub-Rate 1.Thefirst subrate task. Sub-Rate 1 task runs more slowly thanthe Base-Rate task. Sub-Rate 1 task rate is 2ms in the exam

Page 21 - Configuration I nformation

Schedulers and TimingThree Odd-Rate Tasks Without Preemption and OverrunsIn this three task scenario, all of the tasks run as scheduled. No overrunsor

Page 22

3 Project GeneratorTwo Tasks with the Base-Rate Task Overrunning, NoPreemptionInthistworatescenario,theBase-Rateoverrunsthe1mstimeintendedandprevents

Page 23

Schedulers and TimingTask IdentificationIntended ExecutionScheduleActual ExecutionScheduleBase-Rate1ms2ms (overrunning)Sub-Rate 12ms4ms (overrunning)3

Page 24 - 2 Automation Interface

Using Mapped Drives ... B-14Indexxii Contents

Page 25 - 1 Select your processor

3 Project GeneratorTwo Tasks with Sub-Rate 1 Overrunning Without PreemptionIn this example, two rates running simultaneously—the Base-Rate task andone

Page 26

Schedulers and TimingTask IdentificationIntended ExecutionScheduleActual ExecutionScheduleBase-Rate1ms2ms (overrunning)Sub-Rate 12ms8ms (overrunning)T

Page 27

3 Project Generator• Both the Base-Rate and Sub-Rate 1 tasks preempt Sub-Rate 2 taskexecution.• Preempting the subrate tasks does not prevent the subr

Page 28

Schedulers and TimingThree Odd-Rate Tasks Without Preemption and the Base andSub-Rate1 Tasks OverrunThree tasks running simultaneously—the Base-Rate t

Page 29 - Selecting Your Processor

3 Project GeneratorTask IdentificationIntended ExecutionScheduleActual ExecutionScheduleBase-Rate1ms2ms (overrunning)Sub-Rate 12ms4ms (overrunning)Sub

Page 30

Schedulers and TimingThree Odd-Rate Tasks with Preemption and Sub-Rate 1 TaskOverrunsIn this three task scenario, the B as e-R ate preempts Sub-Rate 1

Page 31

3 Project GeneratorTask IdentificationIntended ExecutionScheduleActual ExecutionScheduleBase-Rate1ms2ms (overrunning)Sub-Rate 12ms4ms (overrunning)Sub

Page 32

Schedulers and TimingThree Even-Rate Tasks with Preemption and the Base-Rateand Sub-Rate 1 Tasks OverrunIn this three-task scenario, two of the tasks

Page 33

3 Project GeneratorTask IdentificationIntended ExecutionScheduleActual ExecutionScheduleBase-Rate1ms2ms (overrunning)Sub-Rate 12ms8ms (overrunning)Sub

Page 34

Project Generator TutorialProject Generator TutorialIn this section...“Creating the M odel” on page 3-40“Adding the Target Preferences Block to Your M

Page 35

1Getting Started• “Product Overview” on page 1-2• “Configuration Information” on page 1-6• “Requirements for Embedded IDE Link CC Software” on page 1-1

Page 36

3 Project GeneratorCreating the M odelTo create the model for audio reverberation, follow these steps:1 Start Simulink software.2 Create a new model b

Page 37

Project Generator TutorialAdding a Target Preferences block to a model triggers a dialog box that asksabout your model configuration settings. The mess

Page 38 - 2 Automa tion Interface

3 Project Generatorccslink_grt.stf system target file from the System Target File list in theReal-Time Workshop pane options.To add the Target Preferen

Page 39

Project Generator Tutorial5 In the Block dialog box, select your processor f rom the P rocessor list.6 Verify the CPU clock value and, if you are usin

Page 40

3 Project Generator7 Verify the settings on the Memory and Sections tabs to be sure they arecorrect for the processor you selected.8 Click OK to close

Page 41

Project Generator TutorialIgnore the Data Import/Export, Diagnostics,andOptimization categoriesin the Configuration Parameters dialog box. The default

Page 42

3 Project Generator3 Under Code Generation, select Inline run-time library functions.Cleartheotheroptions.4 Under Link Automation,verifythatExport IDE

Page 43 - Getting Started with RTDX

Project Generator TutorialWhen you click Build with Create_project sele cte d for Build action,theautomaticbuildprocessstartsCCSIDEandpopulatesannewpr

Page 44

3 Project GeneratorSetting Code Generation Parameters for T I ProcessorsBefore y ou generate code w ith Real-Time Workshop software, set thefixed-step

Page 45 - Functions From the RTDX Class

Setting C od e Gen e rati on Para meters for TI ProcessorsIn the Select tree, the categories provide access to the options you use tocontrol how Real-

Page 46

1 Getting StartedProduct OverviewIn this section...“Components of E mbedded IDE Link CC Software” on page 1-3“Automation Interface” on page 1-3“Projec

Page 47 - Getting Star ted with RTDX™

3 Project GeneratorThe following sections present each configuration parameters Select treecategory and the relevant options available in each.3-50

Page 48

Setting Model Configuration ParametersSetting Model Configuration ParametersIn this section...“Target File Selection” on p age 3-52“Build Pro cess” on

Page 49 - Creating the ticcs Objects

3 Project GeneratorTarget File SelectionSystem target fileClicking Browse opens the proce ssor File Brow ser whe re you selectccslink_grt.tlc as your

Page 50

Setting Model Configuration ParametersBuild ProcessEmbedded IDE Link CC software does not use makefiles or the build processto generate code. Code gene

Page 51

3 Project GeneratorCreate Code Generation reportAfter you generate code, this option tells the software whether to generatean H TM L report that docum

Page 52

Setting Model Configuration ParametersFor details about using the options in Debug, refer to “About the TL CDebugger” in your Real-Time Workshop proce

Page 53

3 Project GeneratorThesearetheoptionstypicallyselected for Real-Time W orkshop:• Conditional input branch execution• Signal storage reuse• Enable loca

Page 54

Setting Model Configuration ParametersEmbedded IDE Link CC Pane P arametersOn the select tree, the Embedded IDE Link CC entry provides options inthese

Page 55

3 Project Generatorworking directory. This file set contains many of th e same files thatReal-Time Workshop software generates to populate a CCS project

Page 56

Setting Model Configuration Parameters• Print_message — When the DSP encounters an overrun condition, itprints a message to the standard output device

Page 57

Product OverviewEmbedded IDE Link CC consists of these components:• Project Generator— ge nerate C code from Simulink models• Au tomation Interface—us

Page 58

3 Project GeneratorCompiler options stringTo determine the degree of optimization provided by the TI optimiz ingcompiler, enter the optimization level

Page 59

Setting Model Configuration ParametersTo enable the real-time execution profi le capability, select Profile rea l-timetask execution. With this selected

Page 60

3 Project GeneratorWhen you inline a block function, the compiler replaces each call to a blockfunction with the equivalent function code from the sta

Page 61

Setting Model Configuration ParametersIf you have used Embedded IDE Link CC, you are familiar w ith functionticcs, which creates objects the reference

Page 62

3 Project Generatorcode replacement files. Us e none when the replacement process is correct andyou do not want to see multiple messages during your bu

Page 63

Using Custom Source Files in Generated ProjectsUsing Custom Source Files in Generated ProjectsIn this section...“Preparing to Replace G enerated Files

Page 64

3 Project Generator• Modify a library file, such a s a chip support library (.csl file)• Add commands to a header file• Modify data in a data file• Add co

Page 65

Using Custom Source Files in Generated ProjectsThe build process stores the project files in the directorymodelname_multilink in your MATLAB working d

Page 66

3 Project GeneratorFollow these steps to configure the build process to use a replacement file.1 Double-click Target Preferences in your model. The bloc

Page 67

Using Custom Source Files in Generated Projects2 In the Board custom code options, select the type of file to replace—Sourcefilesor Libraries.3 Enter t

Page 68 - Constructing ticcs Objects

1 Getting Started• Automate project creation, including adding source files, include paths, andpreprocessor defines.• Configure batch building of p rojec

Page 69 - Constructing ticc s Objects

3 Project GeneratorOptimizing Embedded Code with Target Function LibrariesIn this section...“About Target Function Libraries and Optimization” on page

Page 70

Optimizing Embedded Code with Target Function LibrariesCode Generation Using the Target Function LibraryThe build process begins by converting your mo

Page 71

3 Project GeneratorFor more information about target function libraries in the build process, referto “Introduction to T arget Function Libraries” in

Page 72

Optimizing Embedded Code with Target Function LibrariesWith the target function library s elected, your generate d code us es the specificfunctions in

Page 73

3 Project GeneratorReviewing P rocessor-Specific Target Function LibraryChanges in Generated CodeUse one of the following techniques or tools to see t

Page 74

Optimizing Embedded Code with Target Function Libraries4 Press Ctrl+B to generate code from your model.The Real-Time Workshop Repo rt window opens on

Page 75

3 Project Generator5 Save the project with a new name—newproject26 Compare the contents of the modelname.c files from newproject1 andnewproject2. The d

Page 76

Model Reference and Embedded IDE Link™ CCModel Reference and Embedded IDE Link CCModel reference lets your mo de l include other m odels as modular co

Page 77

3 Project Generatoran executable (a MEX file , .mex) for each reference model that is used tosimulate the top model.When you rebuild reference models f

Page 78

Model Reference and Embedded IDE Link™ CCThe Configuration Parameters dialog box opens.3 From the Select tree, choose Embedded IDE Link CC.4 In the rig

Page 79

Product Overview• Highly customized code generation with the system target fileccslink_ert.tlc and ccslink_grt.tlc that enable you to use theConfigurati

Page 80

3 Project Generator• No blocks from the C62x DSP Librar y (in c6000lib) (because these arenoninlined S-functions)• No blocks from the C64x DSP Librar

Page 81

Model Reference and Embedded IDE Link™ CCModels that you develop with versions 2.4 and later of Embedded IDE LinkCC automatically include the model re

Page 82

3 Project Generator3-82

Page 83 - To Add a Ty

4Verification• “What Is Verification?” on page 4-2• “Using Pro cessor in the L oop” on page 4-3• “Real-Time Execution Profiling” on page 4-11• “System St

Page 84

4 VerificationWhat Is Verification?Verification consists broadly of running generated code on a processor andverifying that the code does what you inte

Page 85

Using Proc essor in the LoopUsing Processor in the LoopProcessor in the loo p provides one pow erful verification capability in yourdevelopment process

Page 86

4 VerificationYour starting point in developing a plant/controller system is to modelthe system a s two subsystems in closed-loop s imulation. As your

Page 87 - Struct, Enum, Union Types

Using Proc essor in the LoopPIL AlgorithmThe algorithmic code, such as the control algorithm, to be tested d uring thePIL cosimulation. The PIL algori

Page 88

4 VerificationPIL tests do not run in real time. After each sample period, the simulationhalts to ensure that all data has been exchanged between the

Page 89

Using Proc essor in the Loop• “PIL with DSP/BIOS Enabled Does Not Support System Stack Profiling”on page 4-7• “Real-Time Workshop grt.tlc-BasedTargetsN

Page 90

1 Getting StartedConfiguration InformationTo determine whether Embedded IDE Link CC is installed on y our sy stem,type this command at the MATLAB soft

Page 91

4 Verification• The code g enerated by a model referred to by the PIL algorithm changesafter you generate code for the PIL algorithm. T o update the P

Page 92 - Introducing Project Generator

Using Proc essor in the Loopa From the model menu bar, go to Simulation > ConfigurationParam ete rs in your mo del to open the Con figuration Paramet

Page 93

4 Verification8 Click Simu lation > Start to run the PIL simulation and view the results.4-10

Page 94

Real-Time Execution ProfilingReal-Time Execution ProfilingIn this section...“Overview” on page 4-11“Profiling Execution by Tasks” on page 4-12“Profiling

Page 95

4 Verification• An HTML report that provides statistical data about the execution of eachtask or atomic subsystem in the running process.These reports

Page 96

Real-Time Execution Profiling3 Select Enable real-time profiling.4 On the Profile by list, select Task to enable real-time task profiling.5 Select Export

Page 97

4 Verificationprofile(handlename, execution , report )to view the MATL AB software graphic of the execution report and theHTML execution report.Refer

Page 98

Real-Time Execution Profiling2 Select Embedded IDE Link CC from the Select tree. The pane appears asshowninthefollowingfigure.3 Select Enable real-time

Page 99

4 Verification2 To stop the running program, select Debug > Halt in CCS, or usehalt(objectname) from the MATLAB command prompt. Gathering profiledat

Page 100 - 3 Project Generator

Real-Time Execution ProfilingThe following figure presents the model that contains the subsystems re portedin the profiling plot.4-17

Page 101 - About the CCSLinkLib Blockset

Configuration I nformationccsdebug/display - Display properties of a TICCS object.ccsdebug/halt - Immediately terminate execution of the processor.ccs

Page 102 - Schedulers and Timing

4 VerificationAtomic Subsystem ProfilingTo WorkspacesimoutRate Transition 3Rate Transition 2Rate Transition 1Rate TransitionIdleTaskSubsystemfunction

Page 103

System Stack ProfilingSystem Stack ProfilingIn this section...“Overview” on page 4-19“Profiling System Stack Use” on page 4-21OverviewEmbedded IDE Link

Page 104

4 VerificationSystem Stack: 532/1024 (51.95%) MAUs used.name: System StackstartAddress: [512 0]endAddress: [1535 0]stackSize: 1024 MAUsgrowthDirection

Page 105

System Stack ProfilingProfiling System Stack UseTo profile the system stack operation, perform these tasks i n order:1 Load an application.2 Set up the

Page 106

4 Verification5 Use the profile method to capture a nd view the results of profiling thestack.profile(cc,'stack','report')The follo

Page 107 - Timer setup

5Exporting FilterCoefficients from FDATool• “About FDATool” on page 5-2• “Preparing to Export Filter Coefficients to Code Compose r Studio Projects”on p

Page 108

5 Exporting F ilter Coefficients from FDAToolAbout FDAToolSignal Processing Toolbox™ software provides the Filter Design and Analysistool (FD ATo ol)

Page 109 - Using Asynchronous Scheduling

About FDATool• ticcs — Create a connection between MATLAB software and CCS IDE soyou can w ork with the project in CCS from the MATLAB Command window.

Page 110

5 Exporting F ilter Coefficients from FDAToolPreparing to E xport Filter Coefficients to Code ComposerStudio ProjectsIn this section...“Features of a

Page 111

Preparing to E xport F ilter Coefficients to Code Co mposer Studio™ ProjectsSelecting the Export ModeYou can export a filter by generating an ANSI C he

Page 112

How to Contact The MathWorkswww.mathworks.comWebcomp.soft-sys.matlab Newsgroupwww.mathworks.com/contact_TS.html Technical [email protected]

Page 113

1 Getting StartedIfyoudonotseethelisting,orMATLABsoftwaredoesnotrecognizethecommand, you need to install E mbedded IDE Link CC. Without the software,y

Page 114

5 Exporting F ilter Coefficients from FDAToolChoosing the Export Data TypeThe export processprovidestwowaysyoucanspecifythedatatypetouseto represent t

Page 115

Preparing to E xport F ilter Coefficients to Code Co mposer Studio™ Projectstype to suggest, refer to “How FDATool Determine s the Export SuggestedDat

Page 116

5 Exporting F ilter Coefficients from FDAToolIf you set custom word and fraction lengths to represent your filter coefficients,theexportprocesssuggestsa

Page 117

Exporting Filter Coefficients to Your Code Composer Studio ProjectExpor ting Filter Coefficients to Your Code Composer StudioProjectIn this section...

Page 118

5 Exporting F ilter Coefficients from FDATool4 To export the filter coefficients, select Targets > Code Composer StudioIDE from the FDATool menu bar.

Page 119

Exporting Filter Coefficients to Your Code Composer Studio ProjectNote You cannot use reserved ANSI C programming keywords, such asif or int as variab

Page 120

5 Exporting F ilter Coefficients from FDATool• Click Select target to open the Selection Utility: Embedded IDE LinkCC dialog box.• From the list of bo

Page 121

Exporting Filter Coefficients to Your Code Composer Studio Project/** Filter Coefficients (C Source) generated by the Filter Design and Analysis Tool*

Page 122

5 Exporting F ilter Coefficients from FDATool{0.2436793028081, 0.4873586056161, 0.2436793028081},{1, 0, 0},{0.3768793219093, 0.7537586438185, 0.37687

Page 123 - Sub-Rate1 Tasks Overrun

Preventing Memory Corruption When You Export C oefficients to Processor MemoryPreventing Memor y Corruption When You ExportCoefficients toProcessor Me

Page 124

Configuration I nformation• Connections to the RTDX™ (RTDX) interface. This object is a subset of theobject that refers to the CCS IDE.Concepts to kno

Page 125 - Overruns

5 Exporting F ilter Coefficients from FDATooltoreal64_T NUM[256] = {...}allocates enough m emory for NUM tostoreupto256numeratorfiltercoefficients rathe

Page 126

Preventing Memory Corruption When You Export C oefficients to Processor MemoryCaution Identify changes that require additional memory to store thecoef

Page 127

5 Exporting F ilter Coefficients from FDAToolFor important guidelines on writing directly to processor memory, refer to“Preventing Memory Corruption W

Page 128

Preventing Memory Corruption When You Export C oefficients to Processor MemoryIf you did not store your filter from a previous session, design the filte

Page 129 - Project Generator Tutorial

5 Exporting F ilter Coefficients from FDAToolFor m ore information about how FDATooldeterminesthedatatypetosuggest, refe r to “How FD ATo ol Determine

Page 130

Preventing Memory Corruption When You Export C oefficients to Processor MemoryYou can continue to export the filter, or cancel the export process. Topr

Page 131

5 Exporting F ilter Coefficients from FDATool5-22

Page 132

6Function ReferenceOperations on Objects for CC S IDE(p. 6-2)Work with links for CCS IDEOperations on Obje cts for RTDX(p. 6-4)Work with links to RTDX

Page 133

6 Function ReferenceOperations on Objects for CCS IDEactivateMake specified project, file, or buildconfiguration active in CCS IDEaddAdd files or n ew typ

Page 134

Operations on Objects for CCS IDEisreadableDetermine whether MATLA Bsoftware can read specified memoryblockisrtdxcapableDetermine whether processorsupp

Page 135

1 Getting StartedRequirements for Embedded IDE Link CC SoftwareFor detailed information about the software and hardware required touse Embedded IDE Li

Page 136

6 Function ReferencerunExecute prog ram loaded on processorsymbolProgram symbol table from CCS IDEticcsCreate object that refers to CCS IDEvisibleSet

Page 137

Operations on Objects for RTDX™openOpen channel to proces sor or loadfile into CCS I DEreadmatMatrix of data from RTDX channelreadmsgRead mes sages fro

Page 138

6 Function Reference6-6

Page 139

7Functions — AlphabeticalList

Page 140

activatePurpose Make specified project, file, or build configuration active in CCS IDESyntax activate(cc,'objectname','type')Descript

Page 141

activatevisible(cc,1)Now make two projects in CCS IDE.new(cc,'myproject1.pjt','project')new(cc,'myproject2.pjt')In CCS I

Page 142

addPurpose Add files or new typedef to active project in CCSSyntax add(cc,'filename')info = add(cc.type,'typedefname','datatyp

Page 143 - Report Opt

addFile Types and Extensions Supported by add and CCS IDE(Continued)File TypeExtensionsSupported CCS Project FolderObject and libraryfiles.o*, .lib Lib

Page 144

addBoard number : 0Processor number : 0Default timeout : 10.00 secsRTDX channels : 0cc.visible(1) % Optional. Makes CCS IDE visible on your desktop.ne

Page 145 - Optimization Pane Parameters

addressPurpose Address and page for entry in symbol table in C CS IDESyntax a = address(cc,'symbolstring')Description a = address(cc,'s

Page 146

2Automation Interface• “Getting Started with Automation Interface” on page 2-2• “Getting Started with RTDX ” on page 2-21• “Constructing ticcs Objects

Page 147 - Embedded IDE Lin

addressExamples After you load a program to your processor, address lets you readand write to specific entries in the symbol table for the program. For

Page 148

animatePurpose Run application on proc es sor to breakpo intSyntax animate(cc)Description animate(cc) starts the processor application, which runs unt

Page 149 - Project Options

buildPurpose Build active p roject in CCS IDESyntax build(cc,timeout)build(cc)build(cc,'all',timeout)build(cc,'all')[result,numwar

Page 150

buildNote C CS IDE opens a Save As dialog box when the requested projectbuild overwrites any files in the project. You must respond to the dialogbox be

Page 151

buildpassed. If you omit the timeout option in the syntax, build defaults tothe global timeout defined incc.build(cc,'all') isthesameasbuild(

Page 152

buildRTDX channels : 0build(cc,'all',20)You just completed a full build of the proje ct in CCS IDE. On the BuildpaneinCCSIDE,youseetherecord

Page 153 - Diagnostic Option

ccsboardinfoPurpose Information about boards and simulators known to CCS IDESyntax ccsboardinfoboards = ccsboardinfoDescription ccsboardinfo returns c

Page 154

ccsboardinfoInstalled BoardConfiguration DataConfigurationItem Name DescriptionProcessor numberprocnumThe number assigned by CCS to theprocessor on th

Page 155

ccsboardinforeturnsboards =name: 'C6xxx Simulator (Texas Instruments)'number: 0proc: [1x1 struct]where the structure proc contains the proce

Page 156

ccsboardinfoboards(1).proc(2).name);Examples On a PC with both a simulator and a DSP Starter K it (DSK) boardinstalled,ccsboardinforeturns something s

Page 157 - When You Generate Code

2 Automation InterfaceGetting Started with Automation InterfaceIn this section...“Introducing the Automation Interface Tutorial” on page 2-2“Selecting

Page 158

ccsboardinfoat the MATLAB desktop prompt. You getBoard Board Proc Processor ProcessorNum Name Num Name Type--- ---------------------------------- ---

Page 159

ccsboardinfo1). Board 0 has three CPUs defi ned for it. To determine the type of thesecond process or on board 0 (the b oard whoseboardnum = 0), enterb

Page 160

cdPurpose Change CCS IDE working directorySyntax cd(cc,'directory’)wd = cd(c,'directory')cd(cc,pwd)Description cd(cc,'directory’)

Page 161

cdwhere the drive letter D may be different based on wh ere you installedCCS IDE.Now check your MATLAB environment working dire ctory:pwdans =J:\bin\w

Page 162

clearPurpose Remove links to CCS IDE and RTDX interface, or clear type entriesin type objectsSyntax clear(cc)clear('all')clear(cc.type,&apos

Page 163 - C89/C90 ANSI library

closePurpose Close CCS IDE files or RTDX channelNote close(cc,filename,'text') produces an error.Support forclose(rx,...) on C5000 and C6000

Page 164

closeclose(rx,'channel1','channel2',...) closes the channels specifiedby the stringschannel1, channel2,andsoonasdefined in rx.close(

Page 165 - Embedded IDE Link CC options

closerx=cc.rtdx % Create an alias to the RTDX portion of this link.open(rx,'ichan','w') % Open a channel for write access.enable(r

Page 166

configurePurpose Define size and number of RTDX channel buffersNote configure produces a warning on C5000 and C6000 processorsand will be remov ed in a

Page 167 - How Model Reference Works

configurerx=cc.rtdx % Create an alias to the rtdx portion.RTDX channels : 0configure(rx,4096,6) % Use the alias rx to configure the length% and number

Page 168

Getting Started with Automation Interface1 Select your processor.2 Create and query objects to CCS IDE.3 UseMATLABsoftwaretoloadfiles into CCS IDE.4 Wo

Page 169 - Other Block Limitations

datatypemanagerPurpose Open Data Type Managerdatatypemanager produces a warning and will be removed in a futureversion.Syntax datatypemanager(cc)cc2 =

Page 170

datatypemanager• Refresh list —updatesthelistinTypedef name (Equivalentdata type). Refreshing the list ensures the contents are current. Ifyou changed

Page 171

datatypemanagerindependent objects. When you change a property of either cc or cc2,the corre sponding property in the other o bject changes as well.Da

Page 172

datatypemanagerBefore you add a type definition, the Typedef name (E quivalent d atatype) lis t shows a num ber of data types already defined:•Void(void

Page 173 - Verification

datatypemanager• Short(short) — short data type used in a function input or returnargument•Char(char) — character data type used in a function input o

Page 174 - What Is Verification?

datatypemanagerAdd Typedef Dialog BoxClicking Add typedef in the DTM opens the List o f K nown DataTypes dialog box. As shown in this fig ure, you add

Page 175 - Using Processor in the Loop

datatypemanagerOptions in this dialog box let you review the data types you are usingor that are available in your projects. By selecting different da

Page 176 - 4 Verification

datatypemanagerData Type Descriptionuint32Unsigned 32-bit integer dataint6464-bit integer datauint64Unsigned 64-bit integer datasingle32-bit IEEE®float

Page 177 - Using Proc essor in the Loop

datatypemanagerData Type Description (For C6000 Compiler)double64-bit numeric datalong doubleOn the C2000 a nd C5000 processors –32-bit IEEE floating-p

Page 178

datatypemanagerappear in the Loaded program option. MATLAB software cannotdetermine what program you have loaded.•Others such as pointers and typedefs

Page 179 - Profiling

2 Automation InterfaceFunction DescriptionclearRemove a specific object to CCS IDE or removeall existing objects.ticcsConstruct an object to communicat

Page 180

datatypemanagerFirst ExampleCreate a typedef (typedef1) that uses a MATLAB software data type.typedef1 uses the equivalent data type uint32.7-38

Page 181

datatypemanagerSecond ExampleCreate a second typedef ( typedef2) that uses one of the TI C datatypes. Definetypedef2 to use the signed long data type.7

Page 182

datatypemanagerThird ExampleCreate a typedef (typedef3) that refers to another typedef (typedef2).Call this a nested typedef.Notice that the reference

Page 183 - Real-Time Execution Profiling

datatypemanagerThe next figure shows typedef4 created to use typedef2 rather thantypedef2* for a nested typedef. Under Equivalent type, typedef4has an

Page 184

datatypemanager7-42

Page 185

deletePurpose Remove debug points in addresses or source files in CCSSyntax delete(cc,addr,'type')delete(cc,addr,'type',timeout)del

Page 186

deletereturns an error reporting that it could not find the specified debuggingpoint.delete(cc,addr,'type',timeout) adds the optional input pa

Page 187

deletedelete(cc,'all','break',timeout) removes all of the validbreakpoints in the project source files. T his command d oes not rem

Page 188

dirPurpose List files in current CCS IDE w orking directorySyntax dir(cc)Description dir(cc) lists the files and directories in the current CCS IDE work

Page 189

disablePurpose Disable R TDX interface, specified channel, or all RTDX channelsNote Support for disable on C5000 and C6000 processors will beremoved in

Page 190

Getting Started with Automation InterfaceMethodDescriptionrunExecute the program loaded on theprocessor.visibleSet whether CCS IDE w indow isvisible o

Page 191 - System Stack Profiling

disableSee Also close, enable, open7-48

Page 192

displayPurpose Display properties of object that refers to CCS IDE or RTDX linkNote display(rx) produces a warning on C5000 and C6000 processorsand wi

Page 193 - Profiling System Stack Use

displayTICCS Object:API version : 1.0Processor type : C67Processor name : CPURunning? : NoBoard number : 0Processor number : 0Default timeout : 10.00

Page 194

enablePurpose Enable RTDX interface, specified channel, or all RTDX channelsNote Support for enable on C5000 and C6000 processors will beremoved in a f

Page 195 - Coefficients from FDATool

enableExamples To use channels to RTDX, you must both open and enable the channels:cc = ticcs; % Create a new connection to the IDE.enable(cc.rtdx) %

Page 196 - About FDATool

flushPurpose Flush data or messages from specified RTDX channelsNote flush support C 5000 and C6000 processors will be remove d in afuture version.Synt

Page 197

flushflush(rx,channel) removesallpendingdatamessagesfromtheRTDX channel queue specified bychannel in rx.Unliketheprecedingsyntax o ptions, you use this

Page 198 - Studio Projects

getPurpose Access object propertiesSyntax get(cc,'propertyname')v = get(cc,'propertyname')get(rx,'propertyname')get(rx)v

Page 199 - Selecting the Ex

getProcessor type : C67Processor name : CPURunning? : NoBoard number : 0Processor number : 0Default timeout : 10.00 secsRTDX channels : 0RTDX channels

Page 200 - Choosing the Exp

haltPurpose Terminate execution of pro cess running on processorSyntax halt(cc,timeout)halt(cc)Description halt(cc,timeout) immediately stops program

Page 201

2 Automation InterfaceRunning Code Composer Studio Software on Your Desktop— VisibilityWhen you create a ticcs object , Embedded IDE Link CC starts CC

Page 202

haltans =1cc.isrunning % Alternate syntax for checking the run status.ans =1halt(cc) % Stop the running application on the processor.isrunning(cc)ans

Page 203 - IDE Editor

infoPurpose Information about processorNote Support for info(rx) on C5000 and C6000 processors will beremoved in a future version.Syntax info = info(c

Page 204 - C header file

infoStructure Element Data Type Descriptioninfo.subfamilyDecimalDecimal representation of the hexadecimalidentification value that TI assigns to the pr

Page 205

infofamily: 320subfamily: 103timeout: 10This example simulates the TMS320C6211 processor running inlittle-endian mode. When you use CCS Setup Utility

Page 206 - .h) file that

insertPurpose Add debug point to source file or address in CCSSyntax insert(cc,addr,'type')insert(cc,addr,'type',timeout)insert(cc,

Page 207

insertWhen you use the line input a rgument to insert a breakpoint on aspecified line,line must represent a valid line. If line does not s pe cifya val

Page 208

insertinsert(cc,filename,line) defaults to type 'break' to insert abreakpoint.Example Open a project in CCS IDE, such as volume.pjt in the t

Page 209 - Processor Memor y

insertSee Also address, remove, run7-65

Page 210 - - Increasing the filter order

isenabledPurpose Determine w hether RTDX link is enabled for communicationsNote Support for isenabled on C5000 and C6000 processors will beremoved in

Page 211 - Processor

isenabledNote For isenabled to return reliable results, your processor mustbe running a loaded program. When the processor is not running,isenabled re

Page 212 - 2 Start FDATool

Getting Started with Automation InterfaceTo run the tutorial in MA TLAB software, click run ccstutorial.Thiscommand opens the tutorial in an interacti

Page 213 - Write directly to memory

isreadablePurpose Determine whether MATLAB software can read specified memory blockNote Support for isreadable(rx,'channel') on C5000 and C60

Page 214

isreadableExamples of Address Property ValuesPropertyValue Address Type Interpretation’1F’ StringLocation is 31 decimal on thepage referred to by cc.p

Page 215

isreadabledatatypeStringNumberofBytes/Value Description'int8' 1Signed 8-bit integers'int16'2Signed 16-bit integers'int32&apos

Page 216

isreadablefamily and 216for the C5xxx series. W h en the function identi fies anillegal address, it returns an error message stating that the addressva

Page 217 - Function Reference

isrtdxcapablePurpose Determine whether processor supports R TDXNote Support for isrtdxcapable on C5000 and C6000 processors willbe removed in a future

Page 218 - 6 Function Reference

isrunningPurpose Determine whether processor is executing processSyntax isrunning(cc)Description isrunning(cc) returns 1 when the processor is executi

Page 219

isrunning1halt(cc)isrunning(cc)ans =0See Also halt, restart, run7-74

Page 220

isvisiblePurpose Determine whether CCS IDE is runningSyntax isvisible(cc)Description isvisible(cc) determines whether CCS ID E is running on the deskt

Page 221

isvisiblevisible(cc,0)isvisible(cc)ans =0Notice that CCS IDE is not visible on your d es kto p. Recall thatMATLAB software did not open CCS IDE. When

Page 222

iswritablePurpose Determine whether MATLAB softw are can write to specified memoryblockNote Support for iswritable(rx,'channel') on C5000 and

Page 223 - Functions — Alphabetical

Revision HistoryJuly 2002 Online only New for Version 1.0 (Release 13)October 2002 Online only Revised for Version 1.1May 2003 Online only Revised for

Page 224

2 Automation Interface3 Select a b oard name and processor name from the lists.You are selecting a board and processor number that identifies yourparti

Page 225 - See Also build, new, remove

iswritableFor processors that have one memory page, setting thepagevalueto0lets you specify all memory locations in the processor using the memo ryloc

Page 226

iswritableiswritable w rites 30 values to the processor.datatype — a string that represents a MATLAB data type. The totalmemory block size i s derived

Page 227

iswritableLike the isreadable, read,andwrite functions, iswritable checksfor valid address values. Illegal address values would be any addressspace la

Page 228

listPurpose Information listings from CCSSyntax list(ff,varname)infolist = list(cc,'type')infolist = list(cc,'type',typename)Note

Page 229

lista function declaration to MATLAB software and the declarationstring does not match the declaration forff as determined whenyou createdff.In an exa

Page 230

list• When varname is an input to a library function. list always fails inthis case. It does not matter whether you use declare to provide thedeclarat

Page 231 - See Also halt, restart, run

listAlso, list may report incorrect information when you make changesto variables from MATLAB software. To report variable information,list uses the C

Page 232 - Syntax build(cc,timeout)

listinfolist = list(cc,'project') returns a vector of structurescontaining project information in the format shown here when youspecify opti

Page 233

listinfolist = list(cc,'variable’,varname) returns information aboutthe specified variablevarname.infolist = list(cc,’variable’,varnamelist) retur

Page 234

listreturned information follows the same format a s the syntaxinfolist = list(cc,'variable',...).infolist = list(cc,'function') r

Page 235 - RTDX channels : 0

Getting Started with Automation Interface1 Create an object that refers to your selected board and processor. Enter thefollowing command at the p romp

Page 236 - Syntax ccsboardinfo

listinfolist Structure Element Descriptioninfolist.functionname(1).lineposStart and end linepositions of functioninfolist.functionname(1).funcinfoMisc

Page 237

listinfolist Structure Element Descriptioninfolist.typename(2)... ...infolist.typename(n)... ...For the field name, list uses the type n ame to refer

Page 238

listuclass: 'numeric'type: 'int'bitsize: 16To demonstrate using list with a defined C type, variable typename1includes the type arg

Page 239

loadPurpose Transfer program fi le (*.out,*.obj) to processor in active projectSyntax load(cc,'filename',timeout)load(cc,'filename'

Page 240

loadGEL files folder in CCS. To remove GEL files, use remove.Youcanload any GEL file — you must be sure the GEL file is the correct one.load does not atte

Page 241 - See Also info, ticcs

msgcountPurpose Number of m essages in read-enabled channel queueNote Support for msgcount on C5000 and C6000 processors will beremoved in a future ve

Page 242

newPurpose Create and open text file, project, or build configuration in CCS IDENote new(cc,objectname,'text') produces an error.Syntax new(cc

Page 243 - See Also dir, load, open

newtype String Description'project'Create a new project.'projext'Create a new CCS external make project.Using this option indicate

Page 244 - Syntax clear(cc)

newCaution After you create an object in CCS IDE, save the file in CCSIDE.new does not automatically save the file, and you lose your changeswhen you cl

Page 245 - 'channel')

openPurpose Open channel to processor or load file into CCS IDENote Support for open(rx,...) on C5000 and C6000 processors willbe removed in a future v

Page 246 - Using clos

2 Automation Interface4 Type linkinfo = info(cc).Thecc link status information provides information about the hardware asfollows:linkinfo =boardname:

Page 247 - See Also disable, open

openCCS IDE w orking d irectory, you can use a relative path, such as thename of the file.Note Program files (.out extension) and project files (.mak ext

Page 248

openperiod MATLAB software w aits for the load. If MATLAB software w aitsmore thantimeout seconds, load returns immediately with a timeouterror. Retur

Page 249 - , readmsg, write, writemsg

openenable(rx,'ichannel');When you are working with CCS ID E, open adopts a differentoperational form based on your input arguments forfilen

Page 250 - Syntax datatypemanager(cc)

profilePurpose Code execution and stack usage profile reportNote The tic and raw profile report options that depend on DSP/BIOSwill be removed in a futu

Page 251

profileobjects and DSP/BIOS, refer to your Texas Instruments documentationthat came with C CS IDE .Note Profiling works with and without en a bling DSP

Page 252 - Data Type Manager

profileformatStringProfiling byParameterDSP/BIOSProjectNon-DSP/BIOSProjectTaskNo NorawAtomicSubsystemYes NoTaskNo YesreportAtomicSubsystemYes YesTaskN

Page 253

profile2name: 'processing_SWI'units: 'Hi Time'max: 1528total: 3052avg: 1526pdfactor: 0.0075count: 23name: 'TSK_idle'unit

Page 254

profilecpuload: 0obj: [3x1 struct]ps.obj(1)ans =name: 'KNL_swi'units: 'Hi Time'max: 1.1759e-005avg: 2.7597e-006count: 29for k=1:le

Page 255 - Add Typedef Dialog Box

profileWhen you choose raw, returned variable ps contains an undocumentedlist of the information provided by CCS IDE. Thetic option providesthe same i

Page 256

profileinstrumentation in the project. You enable the DSP/BIOS reportcapability with the Profile performance at atomic subsystemboundaries option on th

Page 257

Getting Started with Automation InterfaceIn this part of the tutorial, you load the executable code for the processor CPUin CCS IDE. Em bedded IDE Lin

Page 258

profileReport EntryUnits Descrip tionendAddressDecimal address andpageListstheaddressoftheend of the stack andthe memory page.stackSizeAddresses Repor

Page 259

profileUsing ProfilingThe following items affect your ability to profile project execution andstack usage:Execution profiling works on code you generate

Page 260 - First Example

profileunits: 'Hi Time'max: 1.1759e-005avg: 2.7597e-006count: 29for k=1:length(ps.obj),disp(k),disp(ps.obj(k)),end;1name: 'KNL_swi&apos

Page 261 - Second Example

profilecpuload: 0error: 0avgperiod: 1000rate: 1000obj: [4x1 struct]for k=1:length(ps.obj),disp(k),disp(ps.obj(k)),end;1name: 'KNL_swi'units:

Page 262 - Third Example

profile4name: 'IDL_busyObj'units: 'User Def'max: -2.1475e+009total: 0avg: 0pdfactor: 0count: 0Your results can differ from this ex

Page 263

profileprofile(cc,'stack','report') % Request stack use report.Maximum stack usage:System Stack: 356/1024 (34.77%) MAUs used.name:

Page 264

readPurpose Data from memory on processor or in CCSSyntax mem = read(cc,address,'datatype',count,timeout)mem = read(cc,address,'datatyp

Page 265

readdecimal value. When the processor has only one memory page, as istrue for many digital signal processors, the value of the page portionof the memo

Page 266

readInput ResponsenRead n values into a column vector. Return t hevector inmem.[m,n]Read (m* n) values from memory into an m-by-nmatrix in column majo

Page 267 - See Also address, insert, run

readWorking with Negative ValuesWriting a negative value causes the data written to be saturatedbecausechar is unsigned on the process or. Hence, a 0

Page 268 - See Also cd, open

2 Automation InterfaceC:\Temp\LinkForCCSDemos_v3.2\ccstutorial\c6x\c67x\ccstut.pjtdemoPjt.DemoDirans =C:\Temp\LinkForCCSDemos_v3.2\ccstutorial\c6x\c67

Page 269

readdefaults to a value of 1. This syntax reads one memory location ofdatatype.Note To ensure seamless read operatio n, use address to extractaddress

Page 270 - See Also close, enable, open

read14 15 16 17 18 19 20 21 22 23 24 25outdata now contains the values in indata, returned from theprocessor.As a further demonstration ofread, try th

Page 271 - Syntax display(cc)

readmatPurpose Matrix of data from RTDX channelNote Support for readmat on C5000 and C6000 processors will beremoved in a future version.Syntax data =

Page 272 - See Also get

readmatCaution If the timeout period expires before the output data matrix isfully populated, you lose all the messages read from the channel tothat p

Page 273 - 3 Channels must be open

readmatopen(rx,'ochannel','r');enable(rx,'ochannel');indata = 1:25; % Set up some data.write(cc,0,indata,30);outdata=rea

Page 274

readmsgPurpose Read messages from specified RTDX channelNote Support for readmsg on C5000 and C6000 processors will beremoved in a future version.Synta

Page 275

readmsgdatatype String Specified Data Type'single'Floating-point data, 32-bits(single -precision).'uint8'Unsigned 8-bit integers.W

Page 276 - See Also enable, open

readmsgdata = readmsg(rx,channelname,datatype,nummsgs) reads thenumber of messages defined bynummsgs. data becomes a cell array ofrow matrices,data = {

Page 277

readmsgColumns 1 through 1312345678910111213Columns 14 through 2514 15 16 17 18 19 20 21 22 23 24 25Now use RTDX to read the messages into a 4-by-5 ar

Page 278

regreadPurpose Value from processor registerSyntax reg = regread(cc,'regname','represent',timeout)reg = regread(cc,'regname&a

Page 279 - Syntax halt(cc,timeout)

Getting Started with Automation Interface4 To determine the memory address of the global symbol ddat,enterthefollowing command at the p rompt:ddata =

Page 280 - , isrunning, run

regreadThe represent inputargumentdefines the format of the data stored inregname. Input argument represent takes one of three input strings:represent

Page 281 - Syntax info = info(cc)

regreadlater. Therefore, getting the values of register variables during programexecution may return unexpected answers.Values that you write to regis

Page 282

regreadFor processors in the C6xxx family, regread lets you a ccess processorregisters directly . To read the value in general p urpose register A0,ty

Page 283 - See Also ticcs, dec2hex, get

regwritePurpose Write data values to registers on processorSyntax regwrite(cc,'regname',value,'represent',timeout)regwrite(cc,&apo

Page 284 - 'type',timeout)

regwriteprocessor family prov ides the following register names that are validentries forregname:Register Names Register ContentsA0, A1, A2,..., A15Ge

Page 285

regwriteReading and Writing Register ValuesRegister variables can be difficult to read and write because theregisters which hold their value are n ot d

Page 286

regwriteregwrite(cc,'b1:b0',hex2dec('1010'),'ieee')Registers B1:B0 now contain the value 4112 in double-precision format

Page 287 - See Also address, remove, run

reloadPurpose Reload most recent program file to processor signal proce ssorSyntax s = reload(cc,timeout)s = reload(cc)Description s = reload(cc,timeou

Page 288

reloadcc=ticcs;s=reload(cc,23)Warning: No action taken - load a valid Program file beforeyou reload...s=''open(cc,'D:\ti\tutorial\sim62

Page 289

removePurpose Remove file from active CCS IDE projectSyntax remove(cc,'filename')remove(cc,'gelfilename')Description remove(cc,&apo

Page 290 - 'datatype')

2 Automation Interfaceccstut.c has two global data arrays — ddat an d idat — that you declare andinitialize in the source code. You use the functionsr

Page 291

resetPurpose Reset processorSyntax reset(cc,timeout)reset(cc)Description reset(cc,timeout) stops program execution on the processor andasynchronously

Page 292

restar tPurpose Restore program counter to entry point for current programSyntax restart(cc,timeout)restart(cc)Description restart(cc,timeout) halts t

Page 293

restartWhen your process gets lost or halts, restart is a quick way to restoreyour program.See Also halt, isrunning, run7-140

Page 294 - Syntax b=isrtdxcapable(cc)

runPurpose Execute program loaded on processorSyntax run(cc,'state',timeout)run(cc,'main')run(cc,'tofunc','function

Page 295 - Syntax isrunning(cc)

runstate String Run Action'tofunc'Run the program from the current position ofthe program counter to the start of a specifiedfunctionfunction

Page 296

runExamples After y ou build and load a program to your processor, use run to startexecution.cc = ticcs('boardnum',0,'procnum',0);

Page 297 - Syntax isvisible(cc)

runconfigure(rx,1024,4);See Also halt, isrunning, restart7-144

Page 298 - See Also info, visible

savePurpose Save files and projects in CCS IDENote save(cc,filename,'text') produces an error.Syntax save(cc,'filename','type&

Page 299

saveCommand Resultsave(cc,'all','text')Save all open text files.Includes source files, li braries,command files, and others.save(cc,&

Page 300

symbolPurpose Program symbol table from CCS IDESyntax s = symbol(cc)Description s = symbol(cc) returns the symbol table for the prog ram loaded inCCS

Page 301

Getting Started with Automation Interfacea Enter ddatv = read(cc,address(cc,'ddat'),'double',4).MATLAB software responds withddatv

Page 302

symbolc6711dskafxr;Now set the simulation parameters for the model and build the m odel toyour process or. With the model loaded on your processor, us

Page 303 - Syntax list(ff,varname)

ticcsPurpose Create object that refers to CCS IDESyntax cc = ticcscc = ticcs('propertyname’,'propertyvalue’,...)Description cc = ticcs retur

Page 304

ticcsObject Property Name Property Default Description'status'RunningNoStatus of the programcurrently loaded on theprocessor'boardnum&a

Page 305

ticcsObject Property Name Property Default Description'timeout'Timeout10.0 sSpecifies how long CCSwaits for a responsefrom the processor afte

Page 306

ticcsGiven these two properties, the most comm on forms of the ticcsmethod arecc = ticcs('boardnum',value)cc = ticcs('boardnum',va

Page 307

ticcsUsing ticcs with Multiple Processor BoardsWhen you create ticcs objects that access boards that contain morethan one processor, such as the O MAP

Page 308

ticcsYou can include both the board number and the processor number intheticcs syntax, as shown here:cc = ticcs('boardnum',2,'procnum&a

Page 309

ticcsAPI version : 1.2Board name : OMAP 3.0 Platform Simulator [TexasInstruments]Board number : 2Processor 0 (element 1) : TMS470R2127 (MPU, Not Runni

Page 310

ticcswhich sets the default property value procnum= 0 to connect to theprocessor on the third board.cc = ticcsTICCS Object:API version : 1.2Processor

Page 311

visiblePurpose Set whether CCS IDE window is vi sib le w h ile CCS runsSyntax visible(cc,state)Description visible(cc,state) sets CCS IDE to be visibl

Page 312 - See Also info

2 Automa tion InterfaceThe Stdout tab in CCS IDE reveals that ddat and idat contain newvalues. Next, read those new values back into MATLAB software.f

Page 313 - 'filename')

visibleFor more information about visibility and CCS, refer to “Running CodeComposer Studio Software on Your Desktop — Visibility” on page 2-6.Example

Page 314 - See Also cd, dir, open

writePurpose Write data to m emory on processorSyntax write(cc,address,data,timeout)write(cc,address,data)Description ticcs Object Syntaxeswrite(cc,ad

Page 315

writeWhen the processor has only one memory page, as is true for manydigital signal processors, the value of the page portion of the memoryaddressis0.

Page 316

writeDatatypes Descriptionint16Signed 16-bit integersint32Signed 32-bit integerssingleSingle-precision floating point d atauint8Unsigned 8-bit integers

Page 317

writeWriting Negative ValuesWriting a negative value causes the data written to be saturatedbecausechar is unsigned on the process or. Hence, a 0 (a N

Page 318

writeIt may be more conv enient to return the data in an array. If you entera vector forcount, mem contains a matrix of d imensions the same asvectorc

Page 319

writemsgPurpose Writemessagestospecified RTDX channelNote Support for writemsg on C5000 and C6000 processors will beremoved in a future version.Syntax

Page 320

writemsgenable(rx,'ichannel');inputdata(1:25);writemsg(rx,'ichannel',int16(inputdata));As a further illustration, the following co

Page 321

writemsg7-166

Page 323

Getting Started with Automation Interface-1 508 647 7000If you used 8-bit integers (int8), the returned values would be incorrect.idatv=read(cc,addres

Page 324

8 Block ReferenceC280x/C28x3x DSP Chip Support (ccslinklib_c280x)C280x/C28x3x Hardware Interrupt Interrupt Service Routine tohandle hardware interrupt

Page 325

Core Suppo rt (ccslinklib_core)Core Support (ccslinklib_core)Idle TaskCreate free-running taskMemory A llocate Allocate memory sectionMemory Copy Copy

Page 326

8 Block Reference8-4

Page 327

9Blocks — Alphabetical List

Page 328

C280x/C28x3x Hardware InterruptPurpose Interrupt Service Routine to handle hardware interrupt onC280x/C28x3x processorsLibrary ccslinklib_c280x in Emb

Page 329

C280x/C28x3x Hardware InterruptEach interrupt is described by:• CPU interrupt numbers• PIE interrupt numbers• Task priorities• Preemption flagsSo one i

Page 330 - 4 Stop the running program

C280x/C28x3x Hardware InterruptC280x Peripheral Interrupt Vector ValuesRow numbers = CPU values/Column numbers = PIE values876543211WAKEINT(LPM/WD)TIN

Page 331 - Using Profiling

C280x/C28x3x Hardware InterruptThe task priority indicates the relative importance tasks associated withthe asynchronous interrupts. If an interrupt t

Page 332

C280x/C28x3x Hardware InterruptSeethetableofC280xPeripheral Interrupt Vector Values for amapping of CPU interrupt number to interrupt names.PIE interr

Page 333

C280x/C28x3x Hardware InterruptSee Also The following links refer to block reference pages that require theTarget Support Package TC2 software.C280x/C

Page 335 - See Also ticcs

2 Automa tion InterfaceMATLAB software returns the new values for idatv.idatv =1234h Use restart to reset the program counter for your program to theb

Page 336

C281x Hardware InterruptPurpose Interrupt Service Routine to handle hardware interruptLibrary ccslinklib_c281x in Embedded IDE Link CCDescription For

Page 337 - is 18 decimal on memory

C281x Hardware InterruptEach interrupt is represented b y one element from each parameter (fourelements total), one from the same position in each of

Page 338

C281x Hardware InterruptC281x Peripheral Interrupt Vector ValuesRow numbers = CPU values / Column numbers = PIE values876543211WAKEINT(LPM/WD)TINT0(TI

Page 339 - Working with Negative Values

C281x Hardware InterruptThe task priority indicates the relative importance tasks associated withthe asynchronous interrupts. If an interrupt triggers

Page 340

C281x Hardware InterruptCPU interrupt numbersEnter a vector of CPU interrupt numbers for the interrupts youwant to process asynchronously.Seethetableo

Page 341

C281x Hardware InterruptReferences Detailed information interrupt processing i s in TMS320x281x DSPSystem Control and Interrupts Reference G uide, Lit

Page 342

Hardware InterruptPurpose Interrupt Service Routine to handle hardware interrupt on C5000 andC6000 processorsLibrary C5000 DSP Chip Support in Embedde

Page 343

Hardware InterruptProcessor Family Valid Interrupt NumbersC5xxx2, 3, 5-21, 23C6xxx4-15The width of the block output signal corresponds to the number o

Page 344 - See Also readmsg, writemsg

Hardware Interruptthe interrupts in Interrupt numbers.IfInterrupt numberscontains more than one interrupt, and you enter only one flagvalue in this fiel

Page 345

Idle TaskPurpose Create free-running taskLibrary Cxxxx DSP Chip Support in Embedded IDE Link CCDescription TheIdleTaskblock,andthesubsystem connected

Page 346

Getting Started with Automation Interfacec Verify that the PC register contains the value you wrote.cc.regread('PC','binary')C6xxx

Page 347 - Examples cc = ticcs;

Idle TaskDialogBoxTask numbersIdentifies the created ta sk s b y n u m b er. Enter a s many tasks asyou need by entering a vector of integers. The defa

Page 348 - , readmat, writemsg

Idle TaskFor example, en t erin g [2,3, 1] in this field indicates that therearethreefunctionstobeexecuted,andthatthethirdfunctionis executed first, the

Page 349

Memory AllocatePurpose Allocate memory sectionLibrary Cxxxx DSP Chip Support in Embedded IDE Link CCDescription On C2xxx, C5xxx, or C6xxx processors,

Page 350

Memory AllocateThefollowingsectionsdescribethecontentsofeachpaneinthedialogbox.9-21

Page 351

Memory AllocateMemory ParametersYou fi nd the following memory parameters on this tab.Variable nameSpecify the name of the variable to allocate. The va

Page 352

Memory AllocateSpecify variable alignmentSelect this option to direct the compiler to align the variable inVariable name to an alignment b oundary. Wh

Page 353

Memory AllocateSection ParametersParameters on this pane specify thesectioninmemorytostorethevariable.SpecifymemorysectionSelecting this parameter ena

Page 354

Memory Allocatestandard memory sections or a custom section that you declareelsewhere in your code.Memory sectionIdentify a specific memory s ection to

Page 355

Memory CopyPurpose Copy to and from memory sectionLibrary Cxxx DSP Chip Support in Embedded IDE Link CCDescription In generated code, this block copie

Page 356 - See Also read, regread, write

Memor y Copycontrol when and how the block initializes memory, copies to andfrom memory, and terminates mem ory operations. The parametersenable you t

Page 357 - Syntax s = reload(cc,timeout)

2 Automa tion Interfaceduring the tutorial, the tutorial program executes the following comm and atthe prompt:clear cvar cfield uintcvarThis tutorial

Page 358 - See Also cd, load, open

Memory CopySections that follow describe the parameters on each tab in the dialogbox.9-28

Page 359

Memor y CopySource ParametersCopy fromSelect the source of the data to copy. Choose one of the entrieson the list:•Input port — This source reads the

Page 360 - Syntax reset(cc,timeout)

Memory Copy• Specified address — This source reads the data at thespecified location in Specify address s ou rce and A ddress .•Specified source code s

Page 361 - Syntax restart(cc,timeout)

Memor y CopyAddressWhen you select Specify via d ialog for the address source, youenter the variable address here. Addresses should be in decimalform.

Page 362 - See Also halt, isrunning, run

Memory CopyOffsetOffset tells the block whether to copy the first element of thedata at the input address or value, or skip one or more valuesbefore st

Page 363

Memor y Copy9-33

Page 364

Memory Copy9-34

Page 365

Memor y CopyDestination ParametersCopy toSelect the destina tion for the data. Choose one of the e ntries onthe list:•Outputport— Copies the data to t

Page 366 - , isrunning, restart

Memory Copy• Specified source code symbol — Tells the block to copy thevariable or sy mbol (variable) to the symbol you enter in Sourcecode symbol. Wh

Page 367

Memor y CopyFor this example, you could enter either 8192 or hex2dec('2000')as the address.Data typeUse this parameter to specify the type o

Page 368 - See Also add, cd, close, open

Getting Star ted with RTDX™Getting Started with RTDXIn this section...“Introducing the Tutorial for Using RTDX” on page 2-22“Creating the ticcs O b je

Page 369 - Syntax s = symbol(cc)

Memory Copythe figure, you can use both an input stride and output stride atthesametimetoenableyoutomanipulateyourmemorymorefully.Sample timeSample tim

Page 370 - See Also load, run

Memor y Copyor the Simulink software model (when there are no input ports onthe block). Enter the sample timeinsecondsasyouneed.9-39

Page 371 - Syntax cc = ticcs

Memory CopyOptions Parameters9-40

Page 372

Memor y CopySet memory value at initializationWhen you check this optio n , you direct the block to initializethe memory location to a specific value w

Page 373

Memory CopyChecking this parameter enables the Bitwise operatorparameter for you to define how to apply the mask value.To use your initialization value

Page 374

Memor y CopyApplying a mask to the copy process lets you select individualbits in the result, for example, to read the value of the fi fth bit byapplyi

Page 375

Memory CopyUse QDMA for copy (if available)For p rocessors that support quick direct memory access (Q D M A),select th is parameter to enab le the QDM

Page 376 - Support Coemulation and OMAP

Targ et PreferencesPurpose Configure model for Texas Instruments processorLibrary Target Preferences in Em bedded IDE Link CCDescription Options on the

Page 377

Tar get Preferencesmemory map for your processor. Both steps are essential for generatingcode for any board that is custom or explicitly supported, su

Page 378 - , ccsboardinfo, set

Targ et PreferencesTargetPreferences b lock dialog boxes provide tabbed access to thefollowing panes with options you set for the processor and board:

Page 379 - Syntax visible(cc,state)

2 Automa tion Interfacehardware simulator in CCS IDE to run this tutorial. The tutorial uses theTMS320C6 7 11 DSK as the board, with the C6711 DSP as

Page 380 - See Also isvisible, load

Tar get Preferences• Sections — Determine the arrangement and location of the sectionson the processor such a s where to put the DSP/BIOS and compiler

Page 381

Targ et PreferencesAdding the ne w processor puts the processor on the Processorlist for all Target Preferences blocks, not just this one.The new proc

Page 382 - is 18 decimal

Tar get PreferencesCorrectly generating interrupts for yo ur model depends on theclock rate of the CPU on your processor. You can change therate w ith

Page 383

Targ et PreferencesEnable High-Speed RTDXSelect this option to tell the code generation p rocess to enablehigh-speed R TDX for this m odel.Operating S

Page 384 - Writing Negative Values

Tar get PreferencesNote When you enter a file path, library, or function, the blockdoes not verify that the path or function exists or is valid. Invali

Page 385 - See Also read, symbol

Targ et PreferencesThe Memory pane contains memory options for three k inds of memory:• Physical Memo ry —Specifies the processor and board memory map•

Page 386

Tar get PreferencesBe aware that these options may affect the options on the Sectionspane. You can make selections here that change how you configureop

Page 387

Targ et PreferencesAfter you add the segment, you can configure the starting address,length, and contents for the new segment. New segments startwith c

Page 388

Tar get PreferencesAddClick Add to add a new memory segment to the processor memorymap. When you click Add, a new segment name appears, forexampleNEWM

Page 389 - Block Reference

Targ et PreferencesHeap SizeAfter you select Create heap,thisoptionletsyouspecifythesize of the heap in words. Enter the number of words in decimalfor

Page 390 - C281x DSP Chip S

Getting Star ted with RTDX™Functions From Objects for CCS IDEFunction DescriptionticcsCreate connections to CCS IDE andRTDX.cdChange your CCS IDE w or

Page 391 - Target Prefere

Tar get PreferencesCache level lets you select one of the available cache l evels toconfigure by selecting one of its configurations. For example, youca

Page 392 - 8 Block Reference

Targ et PreferencesWithinthis pane, you configure the allocatio n of sections f or Compiler,DSP/BIOS,andCustom needs.This table provides brief definitio

Page 393

Tar get PreferencesStringSectionList Description of t h e Section Contents.argsDSP/BIOS Argument buffers.bssCompiler Static and global C variables in

Page 394 - Vectorized Output

Targ et PreferencesStringSectionList Description of th e Se c tion Contents.sysinitDSP/BIOS DSP/BIOS initialization startup code.sysmemCompilerDynamic

Page 395

Tar get PreferencesCustom sections list contains no fixed entries, but instead, onlya placeholder for a section for you to define.NameYou enter the name

Page 396

Targ et PreferencesWhen you set the Operating system option to None,youdisabletheoptions in this pane.For more information about tasks, refer to the C

Page 397

Tar get PreferencesDSP/BIOS sections/objectsDuring program compilation, DSP/BIOS produces bothuninitialized and initialized blocks of data and code. T

Page 398

Targ et Preferencesuse m ore memory than you allo cate. While any task can use morememory than the stack includes, exceeding the stack memory sizemigh

Page 399

Tar get PreferencesPeripheralNameDescriptionADC Report the settings for the Analog-to-Digital ConvertereCAN_A Report or set the enhanced Controlle r A

Page 400 - C281x Hardware Interrupt

Targ et PreferencesPeripheralNameDescriptionGPIO[pin#] Configure inpu t qualification types for GeneralPurpose Input Output pinsFlash_loaderEnable and c

Page 401

2 Automa tion InterfaceFunction DescriptionisreadableDetermine whether MATLA Bsoftware can read the specifiedmemory location.iswritableDetermine whethe

Page 402

Tar get PreferencesADCThe internal timing of the ADC module is controlled by thehigh-speed peripheral clock (HSPCLK). The A DC operating clockspeedis

Page 403

Targ et PreferencesYou can set the following parameters for the AD C clock prescaler:ACQ_PSThis value does not actually have a dire ct effect on the A

Page 404

Tar get PreferencesEnhanced CAN modeWhether to use the CAN m odule in extended mode, whichprovides additional mailboxes and time stamping. Thedefault

Page 405

Targ et PreferenceseCAN_BThe parameters you can se t for theeCAN_B module include all theparameters for theeCAN_A module plus the following parameters

Page 406 - Hardware Interrupt

Tar get PreferencesSYNCO pin assignmentAssigns the ePWM external sync pulse output (SYNCO)to a GPIO pin. Choices areNone (the default), GPIO6,andGPIO3

Page 407

Targ et PreferencesThe Mode parameter corresponds to bit 10 (M ST) of theI2C M ode Reg ister (I2CMDR).Addressing form atIf Mode isSlave, determine the

Page 408

Tar get PreferencesNumber: SPRU721, available on the Texas InstrumentsWeb site.Module clock prescalerIf Mode isMaster,configure the m odule clock frequ

Page 409 - Idle Task

Targ et PreferencesMaster clock H igh -time dividerWhen Mode isMaster, this divider determines the durationof the high state on the serial clock pin (

Page 410

Tar get PreferencesEnable Rx interruptThis parameter corresponds to bit 5 (RXFFIENA) of the I2CReceive FIFO Register (I2CFFRX).Rx FIFO interrupt level

Page 411

Targ et PreferencesThis parameter corresponds to bit 6 (AAS ) of the InterruptEnable Register (I2CIER).Enable SCD interru ptEnable stop condition dete

Page 412 - Memory Allocate

Getting Star ted with RTDX™Creating the links in Task 1 did not o pen com munications to t he processor.With the links in place, you open as manychann

Page 413

Tar get PreferencesThis parameter corresponds to bit 1 (NACK) of the InterruptEnable Register (I2CIER).Enable AL interruptEnable arbitra t ion-lost in

Page 414

Targ et PreferencesNo deadlock condition can occur because there is no waitstate. Data transmission is asynchronous. W ith this mode,it is possible th

Page 415

Tar get Preferencesis enabled, a C28x DSP’s Tx pin is internally connected toits R x pin and can transmit data from its output port to itsinputporttoc

Page 416

Targ et Preferencesread. If data is present, it reads and outputs the contents.If no data is present, the system outputs the last value andcontinues.C

Page 417

Tar get PreferencesNote Deadlocks can occur i f one SC I Transmit block triesto communicate with more than one SCI Receive block ondifferent COM po rt

Page 418 - Memory Copy

Targ et PreferencesSuspension mo deType of suspension to use when debugging your programwith Code Composer Studio. When your program encountersa break

Page 419 - Memor y Copy

Tar get Preferencesto its Rx pin and can transmit data from its o utput port toits input port to check the integrity of the transmission.Enable FIFOSe

Page 420

Targ et PreferencesClock phaseSelectNo_delay or Delay_half_cycle.Clock polaritySelectRising_edge or Falling_edge.Data bitsLength in bits from1 to 16 o

Page 421

Tar get PreferencesSOMI pin assignmentAssigns the SPI something (SOMI) to a GPIO pin. ChoicesareNone (default), GPI013,orGPI025.STE pin assignmentAssi

Page 422

Targ et PreferencesEQEP1I pin assignmentSelect an option from the list—GPIO23 or GPIO53.WatchdogWhen enabled, the watchdog rese ts the processor or ge

Page 423

2 Automa tion InterfaceNote To be able to open and enable channels over a link to RTDX, theprogram loaded on your processor m ust include functions or

Page 424

Tar get Preferences• Select Chip reset to generate a signal that resets theprocessor (WDRST signal) and disable the watchdoginterrupt signal (W DIN T

Page 425

Targ et Preferencesoutput from the qua lifier change s to 0 immediately after thethird consecutive value is rece iv ed .• Qualification using 6 samples

Page 426

Tar get PreferencesSYSCLKOUTescaler2*Prwith the exception of zero. When Qualification samplingperiod prescaler=0, a sample is taken every SYSCLKOUTcloc

Page 427

Targ et PreferencesFlash_loaderYou can use Flash_loader to:• Automatically program generated code to flashmemoryonthetarget wh en you build the code.•

Page 428

Tar get PreferencesSpecify API locationSpecify the directory path of the TI flash API executable youdownloaded and installed on your computer.ExecuteCl

Page 429

Targ et PreferencesIf your model includes an C280x/C28x3x ADC block with theUse DMA (with C28x3x) parameter enabled, disable thesame DMA channel here

Page 430

Tar get PreferencesInterrupt sourceSelect the peripheral interrupt that triggers a DMA burstfor the specified channel.Selecting SEQ1INT or SEQ2IN T gen

Page 431

Targ et PreferencesNote When you select Use DMA (with C28x3x) theC280x/C28x3x ADC block:• If the AD C block Module isA or A and B, Interrup tsource is

Page 432

Tar get PreferencesSpecify the number of 16-bit words in a burst, from 1 to32. The DMA module must complete a burst before itcan service the next chan

Page 433

Targ et PreferencesSpecify the number of bursts in a transfer, from 1 to65536.This parameter corresponds to bits 15-0(TRANSFERSIZE) in the Transfer Si

Page 434

Getting Star ted with RTDX™rx = cc.rtdx;Creating the ticcs ObjectsWith your processing model converted to an executable suitable for yourdesired proce

Page 435

Tar get PreferencesThis parameter corresponds to bits 15-0(DST_WRAP_SIZE) in the Destination WrapSize Register (DST_WRAP_SIZE ).Note When you select U

Page 436

Targ et Preferencesburst. Enter a value from –4096 (decrement) to 4095(increment).To disable incrementing or decrementing the addresspointer, set Burs

Page 437 - Targ et Preferences

Tar get PreferencesIf DM A is configured to perform memory wrapping(if SRC wrap is enabled) the corresponding sourceTransfer step has no effect.Note Th

Page 438 - Tar get Preferences

Targ et PreferencesDestinationThe following parameters configure the D MA channeloutputs.• Begin addressSet the starting address for the current destin

Page 439

Tar get PreferencesTo disable incrementing or decrementing the addresspointer, set Burst step to 0. For example, becauseMcBSP does no t u se FIFO, you

Page 440

Targ et PreferencesIf DMA is confi gured to perform memory wrapping (ifDST wrap is enabled) the corresponding destinationTransfer step has no effect.No

Page 441

Tar get PreferencesModeThe follow ing parameters configure the DMA channel.• Enable one shot modeEnable this parameter to have the DMA channel complete

Page 442

Targ et PreferencesSelect this parameter to leave the D MA channel enabledupon completing a transfer. The channel w ill wait for thenext interrupt eve

Page 443

Tar get Preferencesand the other DM A channels are configured to handlelower-priority data.When e nable d, the DMA module s ervices each enabledchannel

Page 444

Targ et PreferencesNote When you select Use DMA (with C28x3x) theC280x/C28x3x ADC block, this parameter is disabled.New Processor Dialog BoxWhen you c

Page 445

ContentsGetting Started1Product Overview ... 1-2Components of Embedded IDE Link CC Software... 1-3Auto mation Inter

Page 446

2 Automa tion Interfacecc=ticcs('boardnum',0);boardnumdefines which board the new link accesses. In this example,boardnum is 0. Embedded IDE

Page 447

Tar get PreferencesSetting CPU clock to the actual b oard rate allows the code yougenerate to run correctly according to the actual clock rate of theh

Page 448

Targ et Preferences9-109

Page 449

Tar get PreferencesGeneralNameProvide a name to identify your new processor. You can use a nyvalid C string value in this field. The name you enter in

Page 450

Targ et PreferencesProcessor Family Processor Class StringDM64x and DM64xx 64xx where xx designates theprocessor, such as DM6433 orDM643.C55xx55xx whe

Page 451

Tar get PreferencesProcessor Family Compiler Switch StringC62xxNoneC64xxNoneC67xxNoneDM64x and DM64xxNoneC55xx-mlC28xx, F28xx, R28xx, F28xxx-mlCode ge

Page 452

Targ et PreferencesDefine internal memory banks (one or more memory banks)Parameters in this group configure the mem ory map for the newprocessor.Define

Page 453

Tar get Preferencesaddressable data units (MADUs). For the C6000 p rocessor family,for example, the MADU is 8 bytes, one word.ContentsContents details

Page 454

Targ et PreferencesDefine cache configurationOptionsEnter the label for each option of the selected cache configuration,one label on each line, such as

Page 455

Tar get Preferencesblock changes, the kinds of information you store in listed sectionsmay change. Generally, the Contents list contains these strings

Page 456

Targ et PreferencesCustom Code Entr yDescriptionInclude pathsIf you require additional header files onyour path, add them by typing the path intothe te

Page 457

Getting Star ted with RTDX™% Go to processor directorycd(cc,processor_dir);cd(cc,tgt_dir); % Or cc.cd(tgt_dir)dir(cc); % Or cc.dirTo load the appropri

Page 458

Tar get Preferences9-118

Page 459

10Embedded IDE Link CCConfiguration Parameters

Page 460

10 Embedded IDE Link™ CC Configuration ParametersEmbedded IDE Link CC PaneIn this section...“Embedded IDE Link C C Overview” on page 10-4“Export IDE l

Page 461

Embedded IDE Link CC PaneIn this section...“System stack size (MAUs)” on p age 10-22“Build action” on page 10-23“Interrupt overrun notification method”

Page 462

10 Embedded IDE Link™ CC Configuration ParametersEmbedded IDE LinkCCOverviewOptionsonthispane configu re the generated projects and code for TexasInstr

Page 463

Embedded IDE Link CC PaneExport IDE link handle to base workspaceDirects the software to export theticcs object to your MATLAB workspace.SettingsDefau

Page 464

10 Embedded IDE Link™ CC Configuration ParametersSee AlsoFor more informatio n, refer to “Embedded IDE Link CC Pane P arameters”on page 3-57.10-6

Page 465

Embedded IDE Link CC PaneIDE link handle namespecifies the nameoftheticcs object that the build process creates.SettingsDefault: CCS_Obj• Enter any val

Page 466

10 Embedded IDE Link™ CC Configuration ParametersProfile real-time executionenables real-time ex ecutio n profiling in the generated code by addinginst

Page 467

Embedded IDE Link CC PaneApplicat ionSettingEfficiencyNo impactSafety precautionNo impactSee AlsoFor more informatio n, refer to “Embedded IDE Link CC

Page 468

2 Automa tion InterfaceNotice where the demo files are stored on your machine. In ge ne ral,Embedded IDE Link CC software stores the demo project files

Page 469

10 Embedded IDE Link™ CC Configuration ParametersProfile byDefines which execution profiling technique to use.SettingsDefault: TaskTaskProfiles model exe

Page 470

Embedded IDE Link CC PaneFor more information about PIL, refer to “Using Processor in the L oop” onpage 4-3.For more information about en abling profil

Page 471

10 Embedded IDE Link™ CC Configuration ParametersNumber of profiling samples to collectSpecifies the number of profiling samples to collect. Collection

Page 472

Embedded IDE Link CC PaneSee AlsoFor more informatio n, refer to “Embedded IDE Link CC Pane P arameters”on page 3-57.10-13

Page 473

10 Embedded IDE Link™ CC Configuration ParametersInline run-time library functionsMarks run-time library functions generated by the Signal Processing

Page 474

Embedded IDE Link CC PaneRecommended SettingsApplicat ionSettingDebuggingOffTraceabilityOnEfficiency OnSafety precautionNo impactSee AlsoFor more infor

Page 475

10 Embedded IDE Link™ CC Configuration ParametersProject optionsSets the proje ct options for building y our project from the model.SettingsDefault: C

Page 476

Embedded IDE Link CC PaneValue: Custom | Debug | ReleaseDefault: CustomRecommended SettingsApplicat ionSettingDebuggingCustom or DebugTraceabilityCust

Page 477

10 Embedded IDE Link™ CC Configuration ParametersCompiler optionsstringLets you enter a string of compiler options to define your project configura tion

Page 478

Embedded IDE Link CC PaneApplicat ionSettingTraceabilityCustomEfficiencyNo impactSafety precautionNo impactSee AlsoFor more informatio n, refer to “Emb

Page 479

Getting Star ted with RTDX™a string that does not identify an existing channel in the executable, theopen operation fails.In this tutorial, two channe

Page 480

10 Embedded IDE Link™ CC Configuration ParametersLinker options stringEnables you to specify linker command options that determine how to linkyour pro

Page 481

Embedded IDE Link CC PaneSee AlsoFor more informatio n, refer to “Embedded IDE Link CC Pane P arameters”on page 3-57.10-21

Page 482

10 Embedded IDE Link™ CC Configuration ParametersSystem stack size(MAUs)Allocates memory for the system stack on the processor.SettingsDefault: 8192Mi

Page 483

Embedded IDE Link CC PaneBuild actionDefines how Real-Time W orkshop software resp onds when you press Ctrl+Bto build your model.SettingsDefault: Build

Page 484

10 Embedded IDE Link™ CC Configuration Parameters• Reset• Export IDE link han dle to base workspaceSelectingCreate_processor_in_the_loop_project remov

Page 485

Embedded IDE Link CC PaneSee AlsoFor more informatio n, refer to “Embedded IDE Link CC Pane P arameters”on page 3-57.For more information about PIL, r

Page 486

10 Embedded IDE Link™ CC Configuration ParametersInterrupt overrun notification methodSpecifies how your program responds to overrun conditions during

Page 487

Embedded IDE Link CC PaneRecommended SettingsApplicat ionSettingDebuggingPrint_message or Call_custom_functionTraceabilityPrint_messageEfficiencyNoneSa

Page 488

10 Embedded IDE Link™ CC Configuration ParametersInterrupt overrun notification functionSpecifies the name of a custom function your code runs when it

Page 489

Embedded IDE Link CC PanePIL block actionSpecifies wh ether Real-Time Workshop software builds the PIL block anddownloads the block to the proc esso rS

Page 490

2 Automa tion Interfacecc.rtdx.enable;You could do this step before you confi gure the channels — the order doesnot matter.6 Reset the global time-out

Page 491

10 Embedded IDE Link™ CC Configuration Parameters• When you select None or Create_PIL_block, t he generated project willnot compile in the ID E. To us

Page 492

Embedded IDE Link CC PaneMaximum time allowed to build project (s)Specifies how long, in seconds, the software waits for the project build processto re

Page 493

10 Embedded IDE Link™ CC Configuration ParametersApplicat ionSettingEfficiencyNo impactSafety precautionNo impactSee AlsoFor more informatio n, refer t

Page 494

Embedded IDE Link CC PaneMaximum time to complete IDE operations (s)specifies how long the so ftw are wa its for IDE function s, such asread orwrite,to

Page 495

10 Embedded IDE Link™ CC Configuration ParametersSee AlsoFor more informatio n, refer to “Embedded IDE Link CC Pane P arameters”on page 3-57.10-34

Page 496

Embedded IDE Link CC PaneSource file replacementSelects the diagnostic action to take if Embed d ed IDE Link CC softwaredetects conflicts that you are

Page 497

10 Embedded IDE Link™ CC Configuration ParametersRecommended SettingsApplicat ionSettingDebuggingerrorTraceabilityerrorEfficiencywarningSafety precauti

Page 498

ASupported HardwareThis appendix provides the details about the hardware, simulators, andsoftware that work with Embedded IDE Link CC.• “Supported Pla

Page 499

A Supported HardwareSupported Platforms for Embedded IDE Link CCIn this section...“Supported Hardware and Simulators” on page A-2“Product Features Sup

Page 500

Supported Platforms for Embedded IDE Link™ CCSupportedHardware Supported Simulators DescriptionC5000Simulators (C54x, C5x) Simulators for the C5000 DS

Page 501

Getting Star ted with RTDX™Restarting the processor doe s not start the program executing. Y ou use runto start program execution.2 Type cc.run('

Page 502

A Supported HardwareSupportedHardware Supported Simulators DescriptionOMAP5910Boards and simulators basedon the OMAP5910.TMS470TMS470R1xBoards and sim

Page 503

Supported Platforms for Embedded IDE Link™ CCComponentUseDebug FunctionUse objects to create referenceconnections between CCS IDEand MATLAB . From the

Page 504

A Supported HardwareProcessor Family Supporting Embedded IDE Link CC Components and SubcomponentsAutomation Inter face Compo nentProject GeneratorComp

Page 505

Supported Platforms for Embedded IDE Link™ CCOMAP Coemulation SupportAn added featurefor O MAP processors is coemulation for the two proces sorsthat c

Page 506

A Supported HardwareSupported Versions of Code Composer StudioThe following table lists versions of Embedded IDE Link CC and the versionsof Code Compo

Page 507

Supported Versions of Code Composer StudioEmbedd edIDE Link CCVersionMATLABReleaseSupported Version of Code ComposerStudio1.3.2R14SP1 • CCS 2.2 for C2

Page 508

A Supported HardwareA-10

Page 509

BReported Limitations andTips

Page 510

B Reported Limitations and TipsRepor ted Issues Using Embedded IDE Link CC SoftwareIn this section...“Demonstration Programs Do Not Run Properly Witho

Page 511 - Configuration Parameters

Reported Issues Using Embedded IDE Link™ CC SoftwareThe latest issues in the list appear at the bottom. HIL refers to “hardw are intheloop,”alsocalled

Page 512 - Embedded IDE Link CC Pane

2 Automa tion Interfaceand exit the program, or respond in s ome way. When you are writing orreading data to your processor in a script or M-file, chec

Page 513

B Reported Limitations and TipsIssues Using USB-Based RTDX Emulators a nd theC6416 DSK and C6713 DSKYou may encounter a few problems when you try to u

Page 514

Reported Issues Using Embedded IDE Link™ CC Software• Section 5.0 Some Basics on How it Works• Quick Start Installation Guide , “Debu g Hints an d Tro

Page 515 - Export IDE link h

B Reported Limitations and Tips• add(cc.type,'mytypedef','int')To access type without the error, reference the individual elements

Page 516 - See Also

Reported Issues Using Embedded IDE Link™ CC Software4.6255e+018Take care when you change the value of the represent property to float.Only change this

Page 517 - IDE link handle n

B Reported Limitations and Tipsfind the source code for debug. You can either find the source code to debug itor select the Don’t show this message agai

Page 518 - Profile real-time execution

Reported Issues Using Embedded IDE Link™ CC SoftwareIf two fi les have the same name and are located in different directories,the file located in the di

Page 519

B Reported Limitations and Tipscc = ticcsEmbedded IDE Link CC starts the CCS version you last used. If you last usedyour C5000 version, thecc object a

Page 520 - Profile by

Reported Issues Using Embedded IDE Link™ CC SoftwareFour options let you decide how to respond to the failure:• Abort — Closes CCS and suspend s contr

Page 521

B Reported Limitations and TipsCCS is not connected to a processor, you cannot use the object to performprocessor operations from MATLAB, such as load

Page 522 - Recommended Settings

Reported Issues Using Embedded IDE Link™ CC Software1.0000000e+020andresult2 = read(ptr1)returns1.000000020040877e+020The results appear to differ aft

Page 523

Getting Star ted with RTDX™num_of_msgs should be zero. Using this process to check the amount ofdata can m ake your reads more reliable by letting you

Page 524

B Reported Limitations and TipsUsing Mapped DrivesLimitations in Code Composer Studio do not allow you to load programs afteryou set your CCS working

Page 525

IndexIndexAactivate 7-2add 7-4address 7-7address, read 7-114animate 7-9apiversion 2-52Archive_library 3-78asynchronous scheduling 3-12Bblock limitatio

Page 526 - Project options

Indexmanaging 2-58datatypemanager 7-28debug point, insert 7-62default build configuration 3-64default compiler options 3-64delete 7-43breakpoint 7-43so

Page 527

IndexLlink propertiesabout 2-50 2-52apiversion 2-52boardnum 2-53ccsappexe 2-53numchannels 2-53page 2-54procnum 2-54quick reference table 2-50rtdx 2-55

Page 528 - Compiler option

IndexPpage 2-54PIL block 4-6PIL cosimulationdefinitions 4-4how cosimulation works 4-5overview 4-3PIL issues 4-6process, halt 7-57processorgeneral code

Page 529

IndexSsave 7-145selecting boards 3-3set stack size 3-60set visibility 7-157solver option settings 3-48source code replacement 3-65stack size, set stac

Page 530 - Linker options s

2 Automa tion Interface234567891011Notice the ’int16’ represent o ption. When you read data from yourprocessor you need to tell MATL AB software the d

Page 531

Getting Star ted with RTDX™To specify the number of messages to read and the data format in yourworkspace, you used thesiz and nummsgs options set to

Page 532 - System stack siz

Constructing ticcs Objects ... 2-46Example — Constructor for ticcs Objects... 2-46ticcs Properties and Property Valu

Page 533 - Build action

2 Automa tion Interface12 1713 18Because a 5-by-2 matrix requires ten elements, MATLAB software readsone message intooutdata to fill th e matrix.17 To

Page 534

Getting Star ted with RTDX™15 16 14 18 1916 17 18 19 2017 18 19 20 2118 19 20 21 2219 20 21 22 2320 21 22 23 2421 22 23 24 2521 Recheck the number of

Page 535

2 Automa tion InterfaceWe use four functions in this section; each has a purpose — the operationaldetails in the following list explain how and why we

Page 536

Getting Star ted with RTDX™Your processor may already be stopped at this point. In a script, you mightput the function in anif-statement as we have d

Page 537

2 Automa tion InterfaceThe following if statement checks the CCS IDE visibility and changesit if needed.if cc.isvisible,cc.visible(1);endVisibility ca

Page 538 - Call_custom_function

Getting Star ted with RTDX™Instruments processors. While the processor may change, the essentials ofthe p rocess remain the same.Listing the Functions

Page 539 - PIL block action

2 Automa tion Interfaceboardnum. On boards with more than one processor, usethis value to specify the processor on the board. Onboards with one proces

Page 540 - Dependency

Getting Star ted with RTDX™PROFILE Return execution and stack profile reportREAD Return a block of data from the memory of the processorREGREAD Return

Page 541 - Maximum time all

2 Automa tion InterfaceConstructing ticcs ObjectsWhen you create a connection to CCS IDE using the ticcs command, you arecreating a “ticcs object for

Page 542

Constructing ticc s ObjectsRTDX channels : 0Inspecting the output reveals tw o objects listed—a CCS IDE object and anRTDX object. CCS IDE and RTDX obj

Page 543 - Maximum time to c

Setting Code Generation Parameters for TIProcessors... 3-48Setting Model Configuration Parameters... 3-51Ta

Page 544

2 Automa tion Interfaceticcs Properties and Property Va luesObjects in Embedded IDE Link CC software have properties associated withthem. Each propert

Page 545 - Source file replacement

Overloaded FunctionsforticcsObjectsOverloaded Functions for ticcs ObjectsSeveral functions in this Embedded IDE Link CC have the same name asfunctions

Page 546

2 Automa tion Interfaceticcs Object PropertiesIn this section...“Quick Reference to ticcs Object Properties ” on page 2-50“Details About ticcs Object

Page 547

ticcs Object PropertiesPropertyNameAppliesto WhichConnection?UserSettable? DescriptionapiversionCCS IDENoReports the versionnumber of your CCSAPI.boar

Page 548 - A Supported Hardware

2 Automa tion InterfaceDetails About ticcs Object PropertiesTo use the links for CCS IDE and RTDX interface you set values for:•boardnum —specify the

Page 549

ticcs Object PropertiesNote th at the API version is not the same as the CCS IDE version.boardnumProperty boardnum iden tifies the board referenced by

Page 550

2 Automa tion Interfacerx=cc.rtdxRTDX channels : 0open(rx,'ichan','r','ochan','w');get(cc.rtdx)ans =numChannel

Page 551

ticcs Object PropertiesrtdxProperty rtdx is a subclass of the ticcs link and represents the RTDX portionof a link for CCS IDE. As shown in the example

Page 552

2 Automa tion InterfacertdxchannelProperty rtdxchannel,alongwithnumchannels and proctype,isaread-onlyproperty for the RTDX portion of a link for CCS I

Page 553 - Custom Hardwar

ticcs Object Propertiesget(rx) % rx is an alias for cc.rtdx.ans =version: 1numChannels: 0Rtdx: [1x1 COM ]RtdxChannel: {'' [] ''}pr

Page 554

Verification4What Is Verification?...4-2Using Processor intheLoop...4-3Processor-in-the-Loop Overview..

Page 555

2 Automa tion InterfaceManaging Custom Data Types with the Data Type ManagerUsing custom data types, called typedefs (using the C keyword typedef), is

Page 556

Managing Custom Data Ty pes with the Data Type Managerat the MATLAB command line opens the DTM, with the Data Type Managerdialog box shown here:When t

Page 557 - Reported Limitations and

2 Automa tion Interfacewhen you pass the cc object to the DTM, and then add a typedef,thecommandcc.typereturns the list of data types in the type prop

Page 558

Managing Custom Data Ty pes with the Data Type ManagerEach custom type definition added in the DTM becomes part o f the ticcsobject passed to the DTM i

Page 559 - Without Correct GEL Files

2 Automa tion Interface• Typedefs that use pointers or typedefs in the type definitio nTo define custom data types that use structs, enums, or unions fr

Page 560 - C6416 DSK and C67

Managing Custom Data Ty pes with the Data Type Manager2-63

Page 561 - Size Greater Then 1

2 Automa tion Interface4 Click Add typedef to add your first custom data type. The List of KnownData Types dialog box appears as shown.Add a MATLAB t y

Page 562

Managing Custom Data Ty pes with the Data Type Manager6 Select an appropriate M ATLAB data type from the MATLAB Types inKnown Types.uint16 isthechoice

Page 563 - Halt a Program

2 Automa tion Interface11 From the Struct, Enum, Union Types list, s ele ct the appropriateenumerated data type to use withtypedef_enum.Theenum_TAG_my

Page 564 - File Not Found

Managing Custom Data Ty pes with the Data Type ManagerAfter you close the dialog box, the Typedef name list in the Data TypeManager looks like this.To

Page 565 - Code Composer Studio

Preventing Memory Corruption When You ExportCoefficients to Processor Memory... 5-15Allocating Sufficient or Extra M emory for FilterCoeffi

Page 566 - Find a Board

2 Automa tion InterfaceClicking Close in the DTM prompts you to save your session. Saving thesession creates an M-file that contains operations that cr

Page 567

3Project Generator• “Introducing Project Generator” on page 3-2• “Project Generation and Boa rd Selection” on page 3-3• “About the CCSLinkLib Blockset

Page 568 - % in single format

3 Project GeneratorIntroducing Project GeneratorProject generator provides the following features for de veloping p roje ct andgenerating code:• Suppo

Page 569

Project G eneration and Board SelectionProject Generation and Board SelectionProject Generator uses ticcs objects to connect to the IDE. Each time you

Page 570 - Using Mapped Dri

3 Project GeneratorCCS Board Configuration State Response by SoftwareCode Compos er Studio has morethan one board configured. Theboard name specified in

Page 571 - Archive_library 3-78

About the CCSLinkLib BlocksetAbout the CCSLinkLib BlocksetEmbeddedIDELinkCCblocklibraryccslinklib comprises block librariesthat contain blocks designe

Page 572

3 Project Generator• Memory Allocate block• Memory Copy blockBlocksfortheprocessorfamiliesare almost identical. The followingdescriptions about each b

Page 573

About the CCSLinkLib BlocksetThe following figure shows the C280x/C28x3x DSP Chip Support library.The C281x D SP Chip Support library contains the bloc

Page 574

3 Project GeneratorFor the C5000 processor family, the C5000 DSP C hip Support library appearsin the following figure.3-8

Page 575

About the CCSLinkLib BlocksetThe C6000 DSP Chip Support library appear in the next figure.The Core Support library appears in the next figure.3-9

Commentaires sur ces manuels

Pas de commentaire