cancel
Showing results for 
Search instead for 
Did you mean: 

How to include DSP Filtering Functions?

JoBackMonkey
Associate III

In the last month, I did an example of FFT using the CMSIS DSP library. Now, I am trying to design a simple "matched filter".

 

In my code I am using "arm_fir_init_f32" and "arm_fir_f32". While debugging, on the line of "arm_fir_f32", I am getting "HardFault_Handler(void)".

 

According to the "Debug" panel, the file for "arm_fir_f32.c" can not be found. And the file path which is being shown on the screen is wrong (there is no file path like that on my PC), where is this file path coming from?

 

Any advice to solve the problem?

 

0693W00000JMI46QAH.png

1 ACCEPTED SOLUTION

Accepted Solutions

Thanks for your advice. You're right, I just typed the wrong variable into the function. I corrected it, it worked!

View solution in original post

4 REPLIES 4
TDK
Guru

The source for these is not available.

> Any advice to solve the problem?

The issue is likely an invalid pointer in the structure you're passing to the function or similar memory mismanagement issue.

If you feel a post has answered your question, please click "Accept as Solution".

You must find math library and header files for your MCU and configure "Paths and Symbols" in project properties. Check this article: Using STM32 CMSIS DSP library in STM32CubeIDE

For example, on H7 MCU:

0693W00000JMJSiQAP.png0693W00000JMJSnQAP.png0693W00000JMJSsQAP.png0693W00000JMJSjQAP.pngI copied library files to separate directory from Cube firmware package (remember to keep it up to date with firmware libraries):

0693W00000JMJSxQAP.png 

arm_fir_init_f32 is inside "xxxx_math.a" library:

0693W00000JMJTlQAP.png

Thanks for your advice. You're right, I just typed the wrong variable into the function. I corrected it, it worked!

Thanks for the advice. I have done the first steps already, however, the last part of your explanation is so valuable. Helpful!