Closed effemmeffe closed 1 month ago
@effemmeffe What is the compiler you're using ? I never had this with different compilers like gcc, clang, Arm AC6 or even MSVC ...
I think it may be due to a compile option.
It is not clear what is meant by conflicting type in this context but often it means there are two definitions and the compiler computed different types for both.
But the function is defined as __STATIC_FORCEINLINE so it should no occur unless for some reason __STATIC_FORCEINLINE is not defined in your build.
__STATIC_FORCEINLINE is defined in CMSIS-Core that is used by CMSIS-DSP
dsp/none.h
is normal. It is to improve portability of library when compiling for different targets.
I am using arm-none-eabi-gcc that comes with STM32CubeIde. I have
#ifndef __STATIC_FORCEINLINE
#define __STATIC_FORCEINLINE __attribute__((always_inline)) static inline
#endif
in cmsis_gcc.h in my path, so it should work.
Can you confirm that I can download the sources from github, setup the correct tree in my project, setup the correct include paths and compile without having to add a library (.a file) to my project?
@effemmeffe Yes, you can add the sources.
What you have done looks right to me.
@effemmeffe It would be good to understand the cause of the problem. But you can also comment the clip_q63_to_q31
in the header since this function is probably not used in the float versions.
I found the problem: STM32CubeIde somehow [add here profanity and cursing] removed a bunch of files from the compilation, one of them was arm_math.h so even if I had the include in my code it was not compiled. Hence the error. Now I fixed the issue and everything is working. Thanks, I'll close the issue.
I am trying to calculate the FFT using CMSIS-DSP. I downloaded the latest CMSIS-DSP from github, copied folders CMSIS\DSP\Include, CMSIS\DSP\PrivateInclude and CMSIS\DSP\Source in my Drivers folder, added CMSIS\DSP\Include and CMSIS\DSP\PrivateInclude to my include path and removed all .c files in CMSIS\DSP\Source that does not have _f32 in the filename, since I am planning to use only float32 data. My project is build with STM32CubeIDE and the microcontroller is a STM32L476RG. The symbol ARM_MATH_CM4 is defined.
This is the code I'm trying to use:
When I compile I get the following error:
conflicting types for 'clip_q63_to_q31'; have 'q31_t(q63_t)' {aka 'long int(long long int)'}
in file none.h I noticed that none.h is included in arm_math.h, besides a lot of other include files. What am I doing wrong?