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.

error on hwafft.asm compilation

I try (unsuccessful) to implement FFT application on C5535.

As recommended on  TI's sprabb6b I execute hwafft module:

void do_fft(Int16 *real_data, Int16 *fft_real, Int16 *fft_imag, Uint16 scale)
{

Uint16 i, data_selection = 0;
Int32 *complex_data, *bitrev_data, *temp_data, *fft_data;

/* Initialize relevant pointers */
bitrev_data = bitreversed_buffer;
temp_data = temporary_buffer;
complex_data = complex_buffer;

/* Convert real data to "pseudo"-complex data (real, 0) */
/* Int32 complex = Int16 real (MSBs) + Int16 imag (LSBs) */
for (i = 0; i < FFT_LENGTH; i++)
{
    *(complex_data + i) = ( (Int32) (*(real_data + i)) ) << 16;
}

/* Perform bit-reversing */
hwafft_br(complex_data, bitrev_data, FFT_LENGTH);

/* Perform FFT */
if (scale)
{
data_selection = hwafft_256pts(bitrev_data, temp_data, FFT_FLAG, SCALE_FLAG);
}
else
{
data_selection = hwafft_256pts(bitrev_data, temp_data, FFT_FLAG, NOSCALE_FLAG);
}

/* Return appropriate data pointer */
if (data_selection)
{
   fft_data = temp_data;
}
else
{
  fft_data = bitrev_data;
}

/* Extract real and imaginary parts */
for (i = 0; i < FFT_LENGTH; i++)
{
  *(fft_real + i) = (Int16)((*(fft_data + i)) >> 16);
  *(fft_imag + i) = (Int16)((*(fft_data + i)) & 0x0000FFFF);
}

}

On compilation of hwafft_rom.asm and hwafft.asm receive error :

[E9999] Illegal directive or mnemonic.

The change of "mnemonic" to "algebraic" on assembly source language - not resolve the problem

 

Can I ask You to supply implemented  FFT (HWA FFT) on C5535.  

  • Hi GenaChap,

    Have you tried right clicking on the hwafft.asm file and assigning just that file to use assembly source language "algebraic", while the rest of the project uses "mnemonic" (right click on project, Build, Compiler, Runtime Model Options)?

    When the asm file has a assembly source language that differs from the rest of the project, a small wrench appears in the top right corner of the icon. See below screen shots.

    Project uses mnemonic:

    hwafft.asm file uses algebraic (see the icon):

    Hope this helps,
    Mark

  • Please show us the complete text of the error mesage. You can find the complete text in the build console. It might be helpful to post the entire build console log here.