This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

CCS/TMS320C6748: TMS320C6748

Part Number: TMS320C6748
Other Parts Discussed in Thread: FFTLIB, CCSTUDIO

Tool/software: Code Composer Studio

Hello Sir,

i want a example code for fir filter, iir filter, and fourier transform using dsp core of tms32c6748. but i cant find it. can you help me.

How can i find codec libraries of tms320c6748?

  • Hi,

    In dsplib_c674x_3_4_0_0, there are code examples such as:
    DSPF_sp_fir_r2_opt.c -- FIR Filter implemented in C & assembly
    DSPF_sp_iir_opt.c -- IIR Filter implemented in C & assembly

    There is also the fftlib_3_1_0_0.

    Those are available in Processor SDK RTOS installation:
    www.ti.com/.../processor-sdk-c6748

    Best Regards,
    Yordan
  • Thank you for the reply.
    sir,
    i want to design a code for fir using dsp core and codec.
    for eg:-

    #include "FIRcfg.h"

    #include "C:\CCStudio_v3.3\C6000\dsk6713\include\dsk6713.h"
    #include "C:\CCStudio_v3.3\C6000\dsk6713\include\dsk6713_aic23.h"

    float filter_Coeff[] ={0.000000,-0.013457,-0.023448,-0.025402,-0.017127,-0.000000,0.020933,0.038103,0.043547,0.031399,
    0.000000,-0.047098,-0.101609,-0.152414,-0.188394,0.805541,-0.188394,-0.152414,-0.101609,-0.047098,
    0.000000,0.031399,0.043547,0.038103,0.020933,-0.000000,-0.017127,-0.025402,-0.023448,-0.013457,
    0.000000


    };

    static short in_buffer[100];


    DSK6713_AIC23_Config config = { \
    0x0017, /* 0 DSK6713_AIC23_LEFTINVOL Left line input channel volume */ \
    0x0017, /* 1 DSK6713_AIC23_RIGHTINVOL Right line input channel volume */\
    0x00d8, /* 2 DSK6713_AIC23_LEFTHPVOL Left channel headphone volume */ \
    0x00d8, /* 3 DSK6713_AIC23_RIGHTHPVOL Right channel headphone volume */ \
    0x0011, /* 4 DSK6713_AIC23_ANAPATH Analog audio path control */ \
    0x0000, /* 5 DSK6713_AIC23_DIGPATH Digital audio path control */ \
    0x0000, /* 6 DSK6713_AIC23_POWERDOWN Power down control */ \
    0x0043, /* 7 DSK6713_AIC23_DIGIF Digital audio interface format */ \
    0x0081, /* 8 DSK6713_AIC23_SAMPLERATE Sample rate control */ \
    0x0001 /* 9 DSK6713_AIC23_DIGACT Digital interface activation */ \
    };


    /*
    * main() - Main code routine, initializes BSL and generates tone
    */

    void main()
    {
    DSK6713_AIC23_CodecHandle hCodec;

    Uint32 l_input, r_input,l_output, r_output;

    /* Initialize the board support library, must be called first */
    DSK6713_init();

    /* Start the codec */
    hCodec = DSK6713_AIC23_openCodec(0, &config);

    DSK6713_AIC23_setFreq(hCodec, 1);

    while(1)
    { /* Read a sample to the left channel */
    while (!DSK6713_AIC23_read(hCodec, &l_input));

    /* Read a sample to the right channel */
    while (!DSK6713_AIC23_read(hCodec, &r_input));

    l_output=(Int16)FIR_FILTER(&filter_Coeff ,l_input);
    r_output=l_output;

    /* Send a sample to the left channel */
    while (!DSK6713_AIC23_write(hCodec, l_output));

    /* Send a sample to the right channel */
    while (!DSK6713_AIC23_write(hCodec, r_output));
    }

    /* Close the codec */
    DSK6713_AIC23_closeCodec(hCodec);
    }


    signed int FIR_FILTER(float * h, signed int x)
    {
    int i=0;
    signed long output=0;

    in_buffer[0] = x; /* new input at buffer[0] */

    for(i=30;i>0;i--)
    in_buffer[i] = in_buffer[i-1]; /* shuffle the buffer */

    for(i=0;i<32;i++)
    output = output + h[i] * in_buffer[i];

    return(output);

    }



    like this. how can i implement a code like this in dsp tms320c6748

    thank you