Code Composer Studio CCS Code Composer Studio The

  • Slides: 18
Download presentation
“Code Composer Studio (CCS)”

“Code Composer Studio (CCS)”

Code Composer Studio The Code Composer Studio (CCS) application provides an integrated environment with

Code Composer Studio The Code Composer Studio (CCS) application provides an integrated environment with the following capabilities: w w w Chapter 4, Slide 2 Integrated development environment with an editor, debugger, project manager, profiler, etc. ‘C/C++’ compiler, assembly optimiser and linker (code generation tools). Simulator. Real-time operating system (DSP/BIOS™). Real-Time Data Exchange (RTDX™) between the Host and Target. Real-time analysis and data visualisation.

LAB: What is a Project? Project (. PJT) file contains Project files (by reference):

LAB: What is a Project? Project (. PJT) file contains Project files (by reference): Source Libraries Linker, etc … Project settings: Chapter 4, Slide 11 Build configurations (compiler, asm options) DSP/BIOS Linking, etc …

LAB: (1) Create a new projects Chapter 4, Slide 12

LAB: (1) Create a new projects Chapter 4, Slide 12

LAB: Add files to the project (2) Add files to the project (source, command,

LAB: Add files to the project (2) Add files to the project (source, command, library) Chapter 4, Slide 13

LAB: Compiler Build Options Nearly one-hundred compiler options available to tune your code's performance,

LAB: Compiler Build Options Nearly one-hundred compiler options available to tune your code's performance, size, etc. Following table lists most commonly used options: debug optimize (release) Chapter 4, Slide 14 Options Description -mv 6700 -mv 6400 -fr <dir> -q -g -s -o 3 -gp -k Generate ‘C 67 x code (‘C 62 x is default) Generate 'C 64 x code Directory for object/ouput files Quiet mode (display less info while compiling) Enables src-level symbolic debugging Interlist C statements into assembly listing Invoke optimizer (-o 0, -o 1, -o 2/-o, -o 3) Enable function-level profiling Keep asm files, but don't interlist

LAB: Two Default Build Configurations -g -q -fr"c: modemDebug" -d"_DEBUG" -mv 6700 -q -o

LAB: Two Default Build Configurations -g -q -fr"c: modemDebug" -d"_DEBUG" -mv 6700 -q -o 3 -fr"c: modemRelease" -mv 6700 Chapter 4, Slide 15 For new projects, CCS automatically creates two build configurations: Debug (unoptimized) Release (optimized)

LAB: Two Default Build Configurations -g -q -fr"c: modemDebug" -d"_DEBUG" -mv 6700 For new

LAB: Two Default Build Configurations -g -q -fr"c: modemDebug" -d"_DEBUG" -mv 6700 For new projects, CCS automatically creates two build configurations: Debug (unoptimized) Release (optimized) Use the drop-down to quickly select build config. -q -o 3 -fr"c: modemRelease" -mv 6700 Chapter 4, Slide 16

LAB: Build Options GUI -g -q -fr"c: modemDebug" -d"_DEBUG" -mv 67 These are the

LAB: Build Options GUI -g -q -fr"c: modemDebug" -d"_DEBUG" -mv 67 These are the default build options for a new project GUI has 8 pages of options for code generation tools Basic page defaults are -g -mv 6700 Chapter 4, Slide 17

LAB: Linker Options -o<filename> -m<filename> -c -x Description Output file name Map file name

LAB: Linker Options -o<filename> -m<filename> -c -x Description Output file name Map file name Auto-initialize global/static C variables Exhaustively read libs (resolve back ref's) Like Compiler Options, Build Configurations also contain Linker Options Default linker options are shown for the Debug configuration of a project name lab 3. pjt ". Debug" indicates one subfolder level below project (. pjt) location -q -c -o". Debuglab 3. out" -x . Debuglab 3. out Run-time Autoinitialization Chapter 4, Slide 18

LAB: Configuration Tool Chapter 4, Slide 19 Simplifies system design Automatically includes the appropriate

LAB: Configuration Tool Chapter 4, Slide 19 Simplifies system design Automatically includes the appropriate runtime support libraries Automatically handles interrupt vectors and system reset MEM handles system memory configuration (builds CMD file) Many other capabilities will be discussed later …

LAB: Config Tool Chapter 4, Slide 20

LAB: Config Tool Chapter 4, Slide 20

LAB: Build (3) Build the output program (lab 1. out): (a) Build the project

LAB: Build (3) Build the output program (lab 1. out): (a) Build the project by: (i) Clicking the Rebuild All toolbar icon. (ii) Selecting Rebuild All in the project menu. (b) Verify that the build output window is complete with “ 0 errors, 0 warnings”: Chapter 4, Slide 21

LAB: Load Program (4) Load the output file lab 3. out into DSP memory:

LAB: Load Program (4) Load the output file lab 3. out into DSP memory: (a) Load the lab 3. out by selecting File: Load Program as shown below: Chapter 4, Slide 22

LAB: Watch variables (5) Debug and run code: (a) Go to the beginning of

LAB: Watch variables (5) Debug and run code: (a) Go to the beginning of the program, that is main() by selecting Debug: Go Main. (b) Watch variables: (i) Select the variable (to be watched) from the lab 1. c file, right click and select “Add To Watch Window”. If the variable is ret for instance, the following window will be shown Chapter 4, Slide 24 (ii) To add another variable to the watch select it and then drag and drop it on to the window.

LAB: Watch variables (5) Debug and run code: (c) CCS will automatically add the

LAB: Watch variables (5) Debug and run code: (c) CCS will automatically add the local variables: Chapter 4, Slide 25

LAB: Run / Step (5) Debug and run code: (d) You can run or

LAB: Run / Step (5) Debug and run code: (d) You can run or step through the code by using the various icons on the toolbar or use the Debug menu: (e) Stop the processor from running and watch the variable ret: ret = 7 Chapter 4, Slide 26

“Code Composer Studio (CCS)” - END -

“Code Composer Studio (CCS)” - END -