Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 22

TMS320C6748 DSP BOARD

Package content:

The C6748 DSP Experimenter Kit packaged for Universities (TMDSEXPL138-UNV) provides
everything academics need to get started with teaching and projects using the TI TMS320C6000 DSP. The
TI TMS320C6000 family of DSPs is popular for use in Real-time DSP coursesThe Experimenter Kit for
Universities is a low-cost, flexible development platform for the OMAP-L138 which is a low-power dual
core processor based on C6748 DSP plus an ARM926EJ-S 32-bit RISC MPU.

The C6748 DSP kit has a TMS320C6748 DSP onboard that allows full-speed verification
of code with Code Composer Studio. The C6748 DSP kit provides:

A USB Interface
128MB DDRAM and ROM
An analog interface circuit for Data conversion (AIC) An I/O port
Embedded JTAG emulation support

Connectors on the C6748 DSP kit provide DSP external memory interface (EMIF) and peripheral
signals that enable its functionality to be expanded with custom or third party daughter boards.
The C6748 DSP kit includes a stereo codec. This analog interface circuit (AIC) has the
following characteristics:

High-Performance Stereo Codec

• Interfaces directly to digital or analog microphones

• Supports 8-96 ksps sampling rates

• High SNR (100-102dB DAC, 92dB ADC)

• Integrated PLL supporting a wide range of audio clocks

• Low-power headphone, speaker and playback modes for portable systems

• Programmable digital audio effects include 3D sound, bass, treble, EQ and de-emphasis Software Control
via TI McASP-Compatible Multiprotocol Serial Port. Glueless Interface to TI McASPs.
• Audio-Data Input/Output Via TI McASP-Compatible Programmable Audio Interface 16/20/24/32-Bit
Word Lengths.

The C6748DSP kit has the following features:

The 6748 DSP KIT kit is a low-cost standalone development platform that enables customers to
evaluate and develop applications for the TI C67XX DSP family. The DSP KIT also serves as a hardware
reference design for the TMS320C6748 DSP. Schematics, logic equations and application notes are
available to ease hardware development and reduce time to market.

An on-board AIC3106 codec allows the DSP to transmit and receive analog signals. McASP is
used for the codec control interface and for data. Analog audio I/O is done through two 3.5mm audio
jacks that correspond to line input, and line. The analog output is be driven to the line out .McASP1 can
re-routed to the expansion connectors in software.

The DSP KIT includes 2 LEDs and 8 DIP switches as a simple way to provide the user with interactive
feedback.

An included 5V external power supply is used to power the board. On-board voltage regulators provide
the 1.26V DSP core voltage, 3.3V digital and 3.3V analog voltages. A voltage supervisor monitors the
internally generated voltage, and will hold the board in reset until the supplies are within operating
specifications and the reset button is released.

Code Composer communicates with the DSP KIT through an embedded JTAG emulator with a USB
host interface. The DSP KIT can also be used with an external emulator through the external JTAG
connector.

TMS320C6748 DSP Features

 

Highest-Performance Floating-Point Digital Signal Processor (DSP):
Eight 32-Bit Instructions/Cycle

 
32/64-Bit Data Word

 
375/456-MHz C674x Fixed/Floating-Point

 
Up to 3648/2746 C674x MIPS/MFLOPS

 
Rich Peripheral Set, Optimized for Audio

 
Highly Optimized C/C++ Compiler
 
Extended Temperature Devices Available
 
Advanced Very Long Instruction Word (VLIW) TMS320C67x™ DSP Core
Eight Independent Functional Units:

Two ALUs (Fixed-Point)

Four ALUs (Floating- and Fixed-Point)

Two Multipliers (Floating- and Fixed-Point)
 
 Load-Store Architecture With 64 32-Bit General-Purpose Registers
Instruction Packing Reduces Code Size

All Instructions Conditional
 
Instruction Set Features
 
Native Instructions for IEEE
 754

Single- and Double-Precision

 
Byte-Addressable (8-, 16-, 32-Bit Data)

 
8-Bit Overflow Protection
 
Saturation; Bit-Field
 Extract, Set, Clear; Bit-Counting; Normalization
67x cache memory.

 
32K-Byte L1P Program Cache (Direct-Mapped)
 
32K-Byte L1D Data Cache (2-Way)

 
256K-Byte L2 unified Memory RAM\Cache.

 
Real-Time Clock with 32 KHz Oscillator and Separate Power Rail.
 
Three 64-Bit General-Purpose Timers
 
 (DIT) Supports:
Integrated Digital Audio Interface Transmitter
S/PDIF, IEC60958-1, AES-3, CP-430 Formats

Up to 16 transmit pins


Enhanced Channel Status/User Data
 
Extensive Error Checking and Recovery

 
Two Inter-Integrated Circuit Bus (I 2 C Bus™) .

 
3 64-Bit General-Purpose Timers (each configurable as 2 32-bit timers)

 
Flexible Phase-Locked-Loop (PLL) Based Clock Generator Module

 
IEEE-1149.1 ) Boundary-Scan-Compatible
 3.3-V I/Os,
 -V Internal (GDP & PYP)

 
3.3-V I/Os, 1.4-V Internal (GDP)(300 MHz only)

 
LCD Controller

 
Two Serial Peripheral Interfaces (SPI) Each With Multiple Chip-Selects

 Two 
Multimedia Card (MMC)/Secure Digital (SD) Card Interface with Secure Data I/O (SDIO)
Interfaces

 
One Multichannel Audio Serial Port.
 
Two Multichannel Buffered Serial Ports
General Procedure to work on Code Composer Studio V4 for non-real time
projects

1. Launch ccs
Launch the CCS v4 icon from the Desktop or goto All Programs ->Texas Instruments -
>CCSv4

2.
Choose the location for the workspace, where your project will be saved.

3.
Click the CCS icon from the welcome page to go the workbench, it is marked in the
below picture.
4. Configure ccs to your target
A. From the Target menu select New target Configuration
Target -> New target Configuration.
It will open a window like given below.

Specify any arbitrary target name. For Eg., 6748config.ccxml (Extension should be
.ccxml).. Click Finish then you will get configuration window for the created target.

B.
1. Select the Connection: Texas instruments XDS100v1 USB Emulator
2. Select the Device: TMS320C6748. To make search easier type 6748 in device block.

*
Check the box
TMS320C67
4 8 and
finally Click
Save.
C. Next goto Advanced tab give the suitable Gel file path as shown below.

Follow the path. “C:\6748support\c6748.gel”

D.
Go to view option and select the Target Configuration:
View->Target Configuration.
A wizard will open in the workspace expand the User Defined folder and you can find your target,
Right click on 6748config.ccxml and select the Launch Selected Configuration.

E. Connect CCS to the target


Goto Target -> Connect Target

Now our target is successfully configured and connected.


In future we no need to repeat these steps. If we are working with the same hardware we
can just open the already configured target and launch the selected configuration and
connect it.
5. Creating the New Project
Step P1:
Change the Perspective Debug to C/C++ from the right corner of the CCS

Step P2:
 
Go to File New CCS Project.

Step P3:
Specify the name of the project in the
space provided .and Click Next

Eg., Project Name: Hello World


Select the project type

Project Type: C6000

Click Next

*However our target is based on C6000 family, Based on the family we need to select the
Project
Type.
Set the project settings window as shown below.

Click finish
6. To write the program select one new file.
 
A.Go to File New Source File.

B. Specify the arbitrary source file name. It should be in the source folder (current project name.).

Note:
Extension of the source file must be the language what we preferred to write the code. Eg:
For c-> .c C++ -
> .cpp
Assembly -> .asm

C.Type your C – Code


7. BUILD
Build the program to check your code
Have any errors and

warnings. Go to


Project Build active project.

If your code doesn‟t have any errors and warnings, a message will be printed in the console window
that

“Build Complete for the project”

Problems window display errors or warnings, if any.


8. DEBUG
After successful Build, Debug your code. During this step ccs will connect to target and it
will
load program on to target.


Goto Target Debug Active project.

During debug ccs will display following error message.

Now press reset button on the 6748 hardware , then click on retry.

Once you click on retry ccs will load program on to processor and then ccs will guide
us to debug mode, if it is not done automatically.

Change the Perspective C/C++ to Debug


from the right corner of the CCS.

Dept of ECE Page | 54


9. RUN
Now you can run the code, by selecting the option run from the dialog box else you can

Go to Target Run

Once you run the program the output will be printed in the Console
PROGRAM 1

LINEAR CONVOLUTION OF TWO GIVEN SEQUENCES

Aim: To write the C code to perform Linear Convolution upon two given discrete time signals.

C Code:

/* PROGRAM TO IMPLEMENT LINEAR CONVOLUTION */


#include<stdio.h> int y[20];
main()
{
int m=6; /*Length of i/p samples sequence*/ /*Length
int n=6; of impulse response Coefficients

int i=0,j;
/*Input Signal Samples*/
int x[15]={1,2,3,4,5,6,0,0,0,0,0,0};
/*Impulse Response Coefficients*/
int h[15]={1,2,3,4,5,6,0,0,0,0,0,0};

/*Calculate Values*/
for(i=0;i<m+n-1;i++)
{
y[i]=0;
for(j=0;j<=i;j++)
y[i]+=x[j]*h[i-j];
}

/* Display Values*/

printf("Sequence 1: \n");
for(i=0;i<m;i++)
printf("%d\t",x[i]);

printf("\nSequence 2: \n");
for(i=0;i<n;i++)
printf("%d\t",h[i]);

printf("\nConvolved Sequence: \n");


for(i=0;i<m+n-1;i++)
printf("%d\t",y[i]);
}
OUTPUT:

Sequence 1:
1 2 3 4 5 6
Sequence 2:
1 2 3 4 5 6
Convolved Sequence:
1 4 10 20 35 56 70 76 73 60 36

Procedure:

1. Open Code Composer Studio v4.

2. Connect the target (step 4).

3. Create new project with name as sine wave (step 5).

4. Create new source file and type the code linear.c and save it.(step 6)

5. Now perform steps 7, 8and 9.Once you run the program you can watch convolution
result in the console window.

6. To view the values in graph

 
a. Go to Tools Graph Single Time
7. Set the Graph Properties as shown

Buffer size : 11

DSP Data Type : 16-Bit Unsigned Int

Start Address: y

Display Data Size : 11

8. Click : Ok
9. Note down the output waveform.

NOTE : Follow the same procedure for the rest of the experiments.
PROGRAM 2

CIRCULAR CONVOLUTION OF TWO GIVEN SEQUENCES

Aim: To write the C code to perform Circular Convolution upon two given discrete time signals.

C Code 1: Program with User Input Prompt and Fold-Shift Technique Implementation

/* PROGRAM TO IMPLEMENT CIRCULAR CONVOLUTION


*/ #include<stdio.h>
int m,n,x[30],h[30],y[30],i,j,temp[30],k,x2[30],a[30];
void main()
{
printf("Enter the length of the first sequence\n");
scanf("%d",&m);
printf("\nEnter the length of the second sequence\n");
scanf("%d",&n);
printf("\nEnter the first
sequence\n"); for(i=0;i<m;i++)
scanf("%d",&x[i]);
printf("\nEnter the second sequence\n");
for(j=0;j<n;j++)
scanf("%d",&h[j]);

if(m-n!=0) /* If length of both sequences are not equal */


{

if(m>n) /* Pad the smaller sequence with zero */


{
for(i=n;i<m;i++)
h[i]=0;
n=m;
}
/*Initialize Array of Zeros*/
for(i=m;i<n;i++)
x[i]=0;
m=n;
}
/* Convert linear sequence to circular
sequence*/ y[0]=0;
a[0]=h[0];
for(j=1;j<n;j++) /* folding h(n) to h(-n) */ a[j]=h[n-j];
/*Circular convolution*/
for(i=0;i<n;i++)
y[0]+=x[i]*a[i];

for(k=1;k<n;k++)
{
y[k]=0;

/*circular shift*/
for(j=1;j<n;j++)
x2[j]=a[j-1];
x2[0]=a[n-1];

for(i=0;i<n;i++)
{
a[i]=x2[i];
y[k]+=x[i]*x2[i];
}
}
/* displaying the result */
printf("\nConvolved Sequence:\n");
for(i=0;i<n;i++)
printf("%d \t",y[i]);
}

C Code 2: Alternate Program with Modulus and without user input prompt

#include<stdio.h>
int y[20];
main()
{
int m=4; /*Length of i/p samples sequence*/ /*Length
int n=4; of impulse response Coefficients*/

int i=0,j;
/*Input Signal Samples*/
int x[15]={2,1,2,1};
/*Impulse Response Coefficients*/
int h[15]={1,2,3,4};
/*Calculate Values*/
for(i=0;i<m;i++)
{
y[i]=0;
for(j=0;j<n;j++)
w = i-j; if(w<0)
w+=4;
y[i]+=x[j]*h[w];
}

/* Display Values*/
printf("Sequence 1: \n");
for(i=0;i<m;i++)
printf("%d\t",x[i]);

printf("\nSequence 2: \n");

for(i=0;i<n;i++)

printf("%d\t",h[i]);

printf("\nConvolved Sequence: \n");


for(i=0;i<m;i++)
printf("%d\t",y[i]);
}

OUTPUT:
Enter the length of the first sequence 4
Enter the length of the second sequence 4
Enter the first sequence 2 1 2 1
Enter the second sequence 1 2 3 4
Convolved Sequence:
14 16 14 16
PROGRAM 3:

COMPUTATION OF N- POINT DFT OF A GIVEN SEQUENCE

Aim: Computation of N point DFT of a given sequence.

C Code:

#include<stdio.h>
#include<math.h>
int N,k,n,i;
float pi=3.1416,sumre=0, sumim=0,out_real[8]={0.0}, out_imag[8]={0.0};
int x[32];
void main(void)
{
printf("Enter the length of the sequence\n");
scanf("%d",&N);
printf("\nEnter the sequence\n");
for(i=0;i<N;i++)
scanf("%d",&x[i]);

printf("DFT of the Sequence :\n");


for(k=0;k<N;k++)
{
sumre=0; sumim=0;

for(n=0;n<N;n++)
{
sumre=sumre+x[n]* cos(2*pi*k*n/N);
sumim=sumim-x[n]* sin(2*pi*k*n/N);
}
out_real[k]=sumre;
out_imag[k]=sumim;
printf("X([%d])=\t%f\t+\t%fi\n",k,out_real[k],out_imag[k]);
}
}

OUTPUT:
Enter the length of the sequence 4
Enter the sequence 0 1 2 3
DFT of the Sequence
6.0
-2.0 + 2.0i
-2.0 - 0.0i
-2.0 - 2.0i
PROGRAM 4:

IMPULSE RESPONSE OF FIRST ORDER AND SECOND ORDER SYSTEM

Aim: To Calculate the Impulse Response of the First Order and Second Order Systems.

1. First Order System:

C Code:

#include <stdio.h>

#define Order 1 /*First Order Filter*/ /*Length


#define Len 10 of Impulse Response*/

float y[Len] = {0,0,0}, sum;

main()
{
int j,k;
float b[Order+1]={1, 3}; /*Input Coefficients*/
float a[Order+1]={1, 0.2}; /*Output
Coefficients*/ printf("Impulse Response
Coefficients:\n"); for(j=0;j<Len;j++)
{
sum = 0;
for (k=1;k<=Order;k++)
{
if ((j-k)>=0)
sum=sum+(b[k]*y[j-k]);
}
if(j<=Order)
y[j]=a[j]-sum;
else
y[j]=-sum;
printf("Response [%d] = %f\n",j,y[j]);
}
}
OUTPUT:

Impulse Response Coefficients:


Response [0] = 1.000000
Response [1] = -2.800000
Response [2] = 8.400000
Response [3] = -25.199999
Response [4] = 75.599998
Response [5] = -226.799988
Response [6] = 680.399963
Response [7] = -2041.199951
Response [8] = 6123.599609
Response [9] = -18370.798828
VIVA QUESTION:

1. What is CCS? Explain in detail to execute a program using CCS.


2. Why do we need of CCS?
3. How to execute a program using ‘dsk’ and ‘simulator’?
4. Which IC is used in CCS? Explain the dsk, dsp kit.
5. What do you mean by noise?
6. Explain the program for linear convolution for your given sequence.
7. Why we are using command ‘float’ in CCS programs.
8. Where we use ‘float’ and where we use ‘int’?
9. Explain the entire CCS program in step by step of execution
10. What is the difference between DFT and IDFT?
11. What do you mean by built in function ‘abs’ and where it is used?
12. What do you mean by phase spectrum and magnitude spectrum/ give comparison.
13. How to compute maximum length N for a circular convolution using DFT and
IDFT.(what is command).
14. Explain the statement- y=x1.*x2
15. What is FIR and IIR filter define, and distinguish between these two.
16. What is filter?
17. What is window method? How you will design an FIR filter using window method.
18. What are low-pass and band-pass filter and what is the difference between these two?
19. Explain the command : N = ceil(6.6 *pi/tb)
20. Write down commonly used window function characteristics.
21. What is the MATLAB command for Hamming window? Explain.
22. What do you mea by cut-off frequency?
23. What do you mean by command butter, cheby1?
24. Explain the command in detail- [N,wc]=buttord(2*fp/fs,2*fstp/fs,rp,As)
25. What is CCS? Explain in detail to execute a program using CCS.
26. Why do we need of CCS?
27. How to execute a program using ‘dsk’ and ‘simulator’?
28. Which IC is used in CCS? Explain the dsk, dsp kit.
29. What do you mean by noise?
30. Explain the program for linear convolution for your given sequence.
31. Why we are using command ‘float’ in CCS programs.
32. Where we use ‘float’ and where we use ‘int’?
33. Explain the command- i= (n-k) % N
34. Explain the entire CCS program in step by step of execution.
35. What is MATLAB? What does it stand for?

You might also like