Hi
I am making a program that samples a signal, does a fft on the signal and sends the signal over can. I am using a STM32F446ZE with Keil for the programming.
I have a problem that the program crashes to the hardfault handler when the fft is doing a bitreversal. I am not so steady on Keil that i can pinpoint the assemblyline that causes the crash.
I am using the CMSIS DSP package to do the fft, although the problen was also present when using KISSFFT.
Does anyone here have any tips or solutions to my problem?
For more info here is the parts of the code with the FFT:
arm_rfft_fast_f32(&fftInst, ADC_Buffer, fft_Buffer,0 );
the variables:
float32_t ADC_Buffer[ADC_BUFFER_LENGTH]; float32_t fft_Buffer[ADC_BUFFER_LENGTH/2+1];
and the includes:
#define ARM_MATH_CM4 #include "stm32f4xx_hal.h" #include "arm_math.h" #include "math.h" #include "arm_const_structs.h"
ADC_Buffer is filled from the adc with dma