I try to use the fft code provided in the arm library. For the moment i only generate a sinus to test these codes but i already have an issue. Here is the code that i use to generate the sin :
int freqHz = 100;
int fsanpling = 4000;
Then i apply the fft :
The problem is that when i plot (with excel or Matlab) the output of the fft, i get the first spike at f=200Hz instead of 100Hz. And this for differents values of fsampling (Always over 2*fmax). However when i process the fft on Matlab with the sinus values obtained above (with the first code), the output is fine and i get the spike at the right position. So i guess the problem comes from the way i use the fft or configurate it. I tried with the radix4 and get the same problem.
If anybody has already used these codes, thanks in advance for your help