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.
Tool/software: Code Composer Studio
7802.pruebas_matlab.m.zip6888.Protesis_de_mano_nov_2016.zipHi
Im having some problems when doing the FFT. I attach an image of the problem and the code:
As can be seen, the green line (MATLAB PROCESS) matches the red line (MCU PROCESS) perfectly at the begging but then the they don't match in amplitude and I have been trying to figure out why could that be happening... I had this problem before but it kinda solved by itself but now is the same error...
I attach the Matlab code with the data and the processes and the MCU code. The Matlab code has almost the same functions as the MCU code and some other things for testing.
Thanks for the help...
Hi Martin
I would prefer to write in english in case another person has the same problem, it thats ok for you
The problem persist yes. emmm a problem with the ADC resolution? what do you mean?
The data I used for the Matlab code was directly retrieved from the MCU. The data used for the processing is exactly the same. I don't see how the ADC resolution could be causing a problem there....
The processed data in both the MCU and the Matlab code is exactly the same.
Saludos!!
Hi Martin
Sorry for the late reply. I have been quite busy with the project. ammm yes I could make the comparison.
Just give me a couple of days and I let you know.
I calculate the magnitude using the DSP library on the hercules and the abs() function in matlab
Hi Martin
I already check the values and they are different.
They begin being similar but then the difference is quite big... I check if the Hanning window could be the problem but no. They are the same numbers and everything...
In this case the signal was white noise. Just that. Its quite similar to EMG signals.
I really have no idea but the problem appears just after performing the FFT on the MCU. Im not sure is its a problem with the library or a problem with my matlab. I attach my code from matlab. 1565.arreglo_datos.m.zip