FFT filter code for Sam4s2a

The below code is FFT filter code for SAM4SD32C



uint32_t ifftFlag = 0;
uint32_t doBitReverse = 1;
uint32_t fftSize = 1024;



                mt[xt] =  adc_get_channel_value(ADC, ADC_CHANNEL_0);

               testInput_f32_10khz[xt] =(0.6-((float)mt[xt]/4100.00))*16.00;
            arm_cfft_f32(&arm_cfft_sR_f32_len1024, testInput_f32_10khz, ifftFlag, doBitReverse);
            arm_cmplx_mag_f32(testInput_f32_10khz, testOutput, fftSize);
            arm_max_f32(testOutput, fftSize, &maxValue, &testIndex);
            maxi = maxValue;
            printf("Maxi %d test Index %d\n",maxi,testIndex);



I trying to work out the same code in SAM4S2A controller


But the output values maxi and testIndex are changing.Due to this output is not as getting and testIndex value is getting 0.


can any one help me out to resolve the issue.

More questions in this forum