Technical discussions about the TI C54x DSPs (including the c5401, c5402, c5402a, c5404, c5407, c5409, c5409a, c5410, c5410a, c5416, c5420, c5421, c5441, c549, c5470 and c5471).
Hello people! Does someone in this groups use the RIFFT or CIFFT function? I´m using it, but I can´t reach some results. I´m doing a FFT of a real signal (using RFFT) anda after I want to reconstruct the same signal. As the FFT is a complex signal, I´m using the CIFFT function. My original signal has 256 points. The RFFT256 give only the half of the axis, so it has 128 complex values (256 on the RE-Im format). To reconstruct, I´m padding the other 128 comples values with the same values rotated. Then, I´m using the CIFFT256 function. Before this, I´m bit-reversing the data, with the cbrev function setting nx=256. Is something wrong? I´m not using #pragma. Thanks a lot, Guilherme _____________________ Guilherme Martinhon Engenheiro Eletricista Mestrando em Engenharia Elétrica Área: Instrumentação Eletrônica Laboratório de Ultra-Som UNESP - Campus de Ilha Solteira
Hi Dileepan, 1) Yes, I´m using the bit-reverse function cbrev before the RFFT and before the CIFFT again. When I´m using the CIFFT, I put nx=FFT size. Here is the part of the code: cbrev(sinal1br,fftinvbr,TAMANHO_FFT/2); /*nx é a qtde de valores complexos*/ cifft128(fftinvbr, 0); /*FFT inversa*/ q15tofl(fftinvbr,sinal1rec,TAMANHO_FFT); My original signal has 256 samples and the FFT has 128 complex values. 2) The imaginary part is not zero. 3) The real part is not the same original signal. Besides this, I have the doubt if it´s not necessary to fill the FFT array with zeros before applying the CIFFT... Do you think it´s necessary to introduce the #pragma and section? I have no experience in it. My FFT don´t use this and is correctly. Thanks, Guilherme ----- Original Message ----- From: "Dileepan C" <d...@yahoo.com> To: "Guilherme Martinhon" <g...@aluno.feis.unesp.br> Sent: Wednesday, June 07, 2006 3:58 AM Subject: Re: [c54x] Using RIFFT and CIFFT > hi Guilherme, > > i have not used these functions before. but some quick > questions that may help us to find out the problem: > > 1) the rfft() expects the input to be in bit reversed > manner. Are you giving the input that way? > 2) if yes, what is the result after cifft() ? are the > imaginary part of the output array all zeros? > 3) if yes, are the real part of the output array a > scaled version of your original array? > origianl array means the array before the bit reversal > before giving as input to rfft(). > > other than this, your processing steps seems to be > ok.. > hope you are using the latest dsplib functions... > > regards, > Dileepan. > > --- Guilherme Martinhon > <g...@aluno.feis.unesp.br> wrote: > >> >> Hello people! >> >> Does someone in this groups use the RIFFT or CIFFT >> function? I´m using it, but I can´t reach some >> results. I´m doing a FFT of a real signal (using >> RFFT) anda after I want to reconstruct the same >> signal. As the FFT is a complex signal, I´m using >> the CIFFT function. My original signal has 256 >> points. The RFFT256 give only the half of the axis, >> so it has 128 complex values (256 on the RE-Im >> format). To reconstruct, I´m padding the other 128 >> comples values with the same values rotated. Then, >> I´m using the CIFFT256 function. Before this, I´m >> bit-reversing the data, with the cbrev function >> setting nx=256. Is something wrong? >> I´m not using #pragma. >> >> Thanks a lot, >> >> Guilherme >> _____________________ >> Guilherme Martinhon >> Engenheiro Eletricista >> Mestrando em Engenharia Elétrica >> Área: Instrumentação Eletrônica >> Laboratório de Ultra-Som >> UNESP - Campus de Ilha Solteira >