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.

Problem regarding fft32x32.asm program

Other Parts Discussed in Thread: TMS320C6474

hi

I am using  fft32x32.asm (ti program) to calculate the fft of a complex data. This program doesn't work properly for 16 points fft. i am giving DC value x[16]={1,1,....}

and expecting a DC value y[16]={16,0,0 ...}, but the output is different from the  expected value. Can you suggest me how to find 16 points fft using fft32x32.asm program. This program work fine with 64 or more points fft.

  • Brajesh,

    Can you let us know what code you are refering to here? Is this code from the C64x+ DSPLIB ? I tried to replicate the problem that you are seeing but don`t see any issue with that function. Try this code with your function and let me know if you see the same output.

    Here is the code

     int main()
    {
       int i;
       int w[32],y[32];
       int x[32]= {1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0};
         
        gen_twiddle_fft32x32(w,16,2147483647.5);
        DSP_fft32x32(w,16,x,y);
        for ( i= 0;i<32;i=i+2){
         printf("FFT sample %d: %d+ i %d\n", i/2, y[i],y[i+1]);
        }
        printf("FFT done");
        return (1);
    }

    You should observe the following output with this function

    FFT sample 0: 16+ i 0
    FFT sample 1: 0+ i 0
    FFT sample 2: 0+ i 0
    FFT sample 3: 0+ i 0
    FFT sample 4: 0+ i 0
    FFT sample 5: 0+ i 0
    FFT sample 6: 0+ i 0
    FFT sample 7: 0+ i 0
    FFT sample 8: 0+ i 0
    FFT sample 9: 0+ i 0
    FFT sample 10: 0+ i 0
    FFT sample 11: 0+ i 0
    FFT sample 12: 0+ i 0
    FFT sample 13: 0+ i 0
    FFT sample 14: 0+ i 0
    FFT sample 15: 0+ i 0
    FFT done

    Which is exactly what you expect from the code isn`t it? If you can share your test code we will be able to tell you exactly what you need to do to get the correct output.

    Regards,

    Rahul

     

     

     

  • Hi

    I am not using  C64x+ DSPLIB code. I got the code from the following link http://focus.ti.com/dsp/docs/dspplatformscontento.tsp?sectionId=2&familyId=1635&tabId=2432 This code contain SPLOOP ,SPKERNEL and it is different from the DSP_fft32x32  .The code is working fine with 64 or more points FFT but is is not working for 16 points FFT.

    i am using TMS320C6474 processor.I have attached the fft32x32.asm code.

    1033.fft32x32.zip

  • Brajesh,

    If you are using the C6474 platform, I will advice you to use the 32 bit FFT function from the C64x+ DSPLIB. This library also contains a source driver project that you can use as sample code. In the meantime I will take a look at the code that you obtained from the above link and will report this if I can replicate the issue that you are seeing.

    Thanks and Regards,

    Rahul