<< Chapter < Page
  From matlab and simulink to real     Page 2 / 3
Chapter >> Page >
Startup Screen for Code Composer Studio (CCS)

Opening an existing model

Start MATLAB 7.3.0 R2006b

In the top left hand corner of the MATLAB screen, select File ->Open.

Opening an Existing Model(CCS)

The following screen will appear.

Selecting an Existing Model

Highlight “C6713_Audio_Template” then click on “Open”.

Viewing the “c6713 audio template”

The “C6713_Audio_Template” is now displayed.

The C6713 DSK Audio Template>

Overview of the complete echo subsystem

You are now going to implement the Echo Subsystem shown below.

The Complete Echo Subsytem

Implementing the echo subsystem

Double click on the “Effect 1” subsystem block. An empty model will appear.

The Blank “Effect 1” Subsystem

You will now drag-and-drop some library components onto the model.

Select View ->Library Browser. Expand the “Simulink” section.

A list of available blocks will appear. We are initially interested in the “Commonly Used Blocks”.

Commonly Used Blocks

From “Commonly Used Blocks”, drag-and-drop a ”Gain” block, a “Sum” block and two “Data Type Conversion” blocks onto the model.

From the Simulink Library Browser, select “Discrete”. Highlight “Integer Delay” and drag-and-drop this block onto the model.

Blocks

Setting the integer delay time

The delay time will be 0.5 seconds. Using a sampling rate of 8000 Hz, this requires 8000 x 0.5 = 4000 samples. In the equation given in the lecture, this would make N = 4000.

Double click on the “Integer Delay” block. Change the “Number of delays” field to 4000, then click on “OK”.

Setting the Integer Delay Time

Setting the output data conversion to single

We want to set the gain to 0.9. If you multiply an integer value by 0.9, then the value 0.9 will be rounded-down to zero. Instead, you need to convert the integer value to a floating-point value such as “single”, and then convert it back later. Click on “OK”.

Setting the Data Conversion to Single

Setting the delay gain

We required that 0.9 of the delayed input is added to the normal input. Therefore, set the “Gain” to 0.9 then click on “OK”.

Setting the Echo Delay Gain

Setting the output data conversion to int16

Double click on the second “Data Type Conversion” block. Set the “Output data type mode” to int16. This is compatible with the DAC on the C6713 DSK.

Data Type Conversion to 16-bit Integer

The completed echo subsystem

Join the blocks as shown and add a title.

Joining the Blocks

Returning to the parent system

From the Toolbar, select the “Up Arrow” icon. This returns you to the next higher level.

Returning to the Parent System

The reverberation subsystem

The next subsystem to be implemented will be Reverberation.

Overview of the completed reverberation subsystem

We are now going to implement the Reverberation System shown below.

Overview of the Reverberation Subsystem

Note that the reverberation subsystem is very similar to that of echo. We will cut-and-paste from the Echo Subsystem

Opening the effects 2 subsystem

From the “C6713 Audio Template” top level, double-click on the “Effect 2” subsystem.

Get Jobilize Job Search Mobile App in your pocket Now!

Get it on Google Play Download on the App Store Now




Source:  OpenStax, From matlab and simulink to real-time with ti dsp's. OpenStax CNX. Jun 08, 2009 Download for free at http://cnx.org/content/col10713/1.1
Google Play and the Google Play logo are trademarks of Google Inc.

Notification Switch

Would you like to follow the 'From matlab and simulink to real-time with ti dsp's' conversation and receive update notifications?

Ask