You are currently viewing DECIMATION USING TMS320C5505 DSP

DECIMATION USING TMS320C5505 DSP

Spread the love

Aim

To perform the Decimation process from a given discrete sequence in TMS320C5505 KIT

Requirements

☞CCS v4

TMS320C5505 KIT

☞USB Cable

☞5V Adapter

Theory

Decimation is the process of filtering and downsampling a signal to decrease its effective sampling rate. The filtering is employed to prevent aliasing that might otherwise result from downsampling. Finally, “Decimation” is the process of reducing the sampling rate. In practice, this usually implies lowpass-filtering a signal, then throwing away some of its samples.

“Downsampling” is a more specific term which refers to just the process of throwing away samples, without the lowpass filtering operation. Throughout this FAQ, though, we’ll just use the term “decimation” loosely, sometimes to mean “downsampling”.

The downsampling factor (commonly denoted by M) is usually an integer or a rational fraction greater than unity. This factor multiplies the sampling time or, equivalently, divides the sampling rate. For example, if compact disc audio at 44,100 Hz is downsampled to 22,050 Hz before broadcasting over FM radio, the bit rate is reduced in half, from 1,411,200 bit/s to 705,600 bit/s, assuming that each sample retains its size of 16 bits. The audio was therefore downsampled by a factor of 2

Procedure for build a project on DECIMATION USING TMS320C5505 DSP

1. Open Code Composer Studio v4 .

2. In WorkSpace Launcher.

☞BROWSE → Select the project location and make one new folder, MAKE NEW FOLDER → Type the Workspace name, OK → OK.

3. FILE ⇒ NEW ⇒ CCS PROJECT

☞Project name: Type your project name.

☞Tick use default location. → NEXT

☞Project type: C5500.

☞Tick Debug And Release. → NEXT → NEXT.

☞Output type: Executable.

☞Device Variant : TMS320C55XX – TMS320C5505.

☞Device Endianness : big

☞Code Generation Tools: TI v4.3.5.

☞Run time support library: automatic.

☞Target content: none. →FINISH

4.FILE ⇒ NEW ⇒ SOURCE FILE

☞Source file: Type your projectname.c( .c extension is must ).

☞Type the program.

☞FILE → SAVE.

5. Paste the following board library files in workspace location.

☞include folder (contains header files)

☞Gel folder (contains gel file)

☞Library folder(contains library files)

6. Paste the Linker file in the project location.(linker file is available in cd)

Note: Those folders and linker file are availble at cd.

7. PROJECT ⇒ PROPERTIES ⇒ C/C++ BUILD ⇒ BASIC OPTION

☞Target processor version(–silicon version, -mv)    :   5505 OK.

8. FILE ⇒ NEW ⇒ TARGET CONFIGURATION FILE

☞file name: projectname. ccxml (.ccxml extension is must)

☞Connection: Texas Instrument XDS100 v1 USB Emulator.

☞Device: TMS320C5505. (Tick the TMS320C5505)→ SAVE → TARTGET CONFIGURATION →C55XX_0 →BROWSE, browse the workspace location, open the gel folder and select the GEL file. → OPEN → SAVE.

9. In C/C++ Project window, Right click the project ⇒ REBUILD PROJECT.

10. Connections :

☞Connect the usb cable, PC to TMS320C5505 KIT.

☞Connect the 5v adapter.

☞Power on the kit.

11. TARGET ⇒ DEBUG ACTIVE PROJECT.

12. TARGET ⇒ RUN.

☞Enter the No of input vector: 10 (ENTER)

☞ Enter sampling value: 2 (ENTER)

☞ Enter values for i/p x(n): 1 2 3 4 5 6 7 8 9 0 (ENTER)

13. Output is displayed at Console Window.

14. TARGET ⇒ HALT.

Program for DECIMATION USING TMS320C5505 DSP

#include 
#include 

int x[100],h[100],y[100],c1[100],y1[100];

void main()
{
	int a,b,d;
	int i,j,z;
		printf("\n Enter the No of input vector");
		scanf("%d",&a);

		printf("\n Enter sampling value");
		scanf("%d",&b);

		printf("Enter values for i/p x(n):\n");
		for(i=1;i<=a;i++)
		scanf("%d",&x[i]);
	
		j = 1;
		for (i=1;i<=a;i++)
		{
			y[i] = x[j];
			j = j+b;
		}
	
		    d = a/b;
		    z = round(d);
	
			for(i=1;i<=z;i++)
	
			printf("\n The first order decimation values are y[%d]=%d",i,y[i]);
			printf( "\n***ALL Tests Passed***\n" );
}

Result

Thus, the Decimation process was performed and displayed the results in console window.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.