当前位置:网站首页>Adding DSP library to STM32F103 and its solution
Adding DSP library to STM32F103 and its solution
2022-07-28 03:58:00 【_ jym】
Use cubemx add to dsp library .



Finally found "arm_const_structs.h" Header file cannot be imported .

../Core/Src/main.c(23): error: #5: cannot open source input file "arm_const_structs.h": No such file or directory
#include "arm_const_structs.h"
If you're in keil add to dsp

The following error message will appear :
D:\Keil_v5\ARM\PACK\ARM\CMSIS\5.9.0\CMSIS\DSP\Include\arm_math_types.h(601): error: #101: "ARM_MATH_SUCCESS" has already been declared in the current scope
ARM_MATH_SUCCESS = 0, /**< No error */
D:\Keil_v5\ARM\PACK\ARM\CMSIS\5.9.0\CMSIS\DSP\Include\arm_math_types.h(602): error: #101: "ARM_MATH_ARGUMENT_ERROR" has already been declared in the current scope
ARM_MATH_ARGUMENT_ERROR = -1, /**< One or more arguments are incorrect */
D:\Keil_v5\ARM\PACK\ARM\CMSIS\5.9.0\CMSIS\DSP\Include\arm_math_types.h(603): error: #101: "ARM_MATH_LENGTH_ERROR" has already been declared in the current scope
ARM_MATH_LENGTH_ERROR = -2, /**< Length of data buffer is incorrect */
D:\Keil_v5\ARM\PACK\ARM\CMSIS\5.9.0\CMSIS\DSP\Include\arm_math_types.h(604): error: #101: "ARM_MATH_SIZE_MISMATCH" has already been declared in the current scope
ARM_MATH_SIZE_MISMATCH = -3, /**< Size of matrices is not compatible with the operation */
D:\Keil_v5\ARM\PACK\ARM\CMSIS\5.9.0\CMSIS\DSP\Include\arm_math_types.h(605): error: #101: "ARM_MATH_NANINF" has already been declared in the current scope
ARM_MATH_NANINF = -4, /**< Not-a-number (NaN) or infinity is generated */
D:\Keil_v5\ARM\PACK\ARM\CMSIS\5.9.0\CMSIS\DSP\Include\arm_math_types.h(606): error: #101: "ARM_MATH_SINGULAR" has already been declared in the current scope
ARM_MATH_SINGULAR = -5, /**< Input matrix is singular and cannot be inverted */
D:\Keil_v5\ARM\PACK\ARM\CMSIS\5.9.0\CMSIS\DSP\Include\arm_math_types.h(607): error: #101: "ARM_MATH_TEST_FAILURE" has already been declared in the current scope
ARM_MATH_TEST_FAILURE = -6, /**< Test Failed */
D:\Keil_v5\ARM\PACK\ARM\CMSIS\5.9.0\CMSIS\DSP\Include\arm_math_types.h(609): error: #256: invalid redeclaration of type name "arm_status" (declared at line 408 of "../Middlewares/ST/ARM/DSP/Inc/arm_math.h")
} arm_status;
D:\Keil_v5\ARM\PACK\ARM\CMSIS\5.9.0\CMSIS\DSP\Include\arm_math_memory.h(63): warning: #47-D: incompatible redefinition of macro "__SIMD32_CONST" (declared at line 483 of "../Middlewares/ST/ARM/DSP/Inc/arm_math.h")
#define __SIMD32_CONST(addr) ( (__SIMD32_TYPE * ) (addr))
D:\Keil_v5\ARM\PACK\ARM\CMSIS\5.9.0\CMSIS\DSP\Include\arm_math_memory.h(64): warning: #47-D: incompatible redefinition of macro "_SIMD32_OFFSET" (declared at line 484 of "../Middlewares/ST/ARM/DSP/Inc/arm_math.h")
#define _SIMD32_OFFSET(addr) (*(__SIMD32_TYPE * ) (addr))
D:\Keil_v5\ARM\PACK\ARM\CMSIS\5.9.0\CMSIS\DSP\Include\arm_math_memory.h(65): warning: #47-D: incompatible redefinition of macro "__SIMD64" (declared at line 485 of "../Middlewares/ST/ARM/DSP/Inc/arm_math.h")
#define __SIMD64(addr) (*( int64_t **) & (addr))
D:\Keil_v5\ARM\PACK\ARM\CMSIS\5.9.0\CMSIS\DSP\Include\dsp/none.h(136): error: #247: function "clip_q63_to_q31" has already been defined
__STATIC_FORCEINLINE q31_t clip_q63_to_q31(
D:\Keil_v5\ARM\PACK\ARM\CMSIS\5.9.0\CMSIS\DSP\Include\dsp/none.h(146): error: #247: function "clip_q63_to_q15" has already been defined
__STATIC_FORCEINLINE q15_t clip_q63_to_q15(
D:\Keil_v5\ARM\PACK\ARM\CMSIS\5.9.0\CMSIS\DSP\Include\dsp/none.h(156): error: #247: function "clip_q31_to_q7" has already been defined
__STATIC_FORCEINLINE q7_t clip_q31_to_q7(
D:\Keil_v5\ARM\PACK\ARM\CMSIS\5.9.0\CMSIS\DSP\Include\dsp/none.h(166): error: #247: function "clip_q31_to_q15" has already been defined
__STATIC_FORCEINLINE q15_t clip_q31_to_q15(
D:\Keil_v5\ARM\PACK\ARM\CMSIS\5.9.0\CMSIS\DSP\Include\dsp/none.h(176): error: #247: function "mult32x64" has already been defined
__STATIC_FORCEINLINE q63_t mult32x64(
D:\Keil_v5\ARM\PACK\ARM\CMSIS\5.9.0\CMSIS\DSP\Include\dsp/none.h(245): error: #247: function "__QADD8" has already been defined
__STATIC_FORCEINLINE uint32_t __QADD8(
D:\Keil_v5\ARM\PACK\ARM\CMSIS\5.9.0\CMSIS\DSP\Include\dsp/none.h(263): error: #247: function "__QSUB8" has already been defined
__STATIC_FORCEINLINE uint32_t __QSUB8(
D:\Keil_v5\ARM\PACK\ARM\CMSIS\5.9.0\CMSIS\DSP\Include\dsp/none.h(281): error: #247: function "__QADD16" has already been defined
__STATIC_FORCEINLINE uint32_t __QADD16(
D:\Keil_v5\ARM\PACK\ARM\CMSIS\5.9.0\CMSIS\DSP\Include\dsp/none.h(298): error: #247: function "__SHADD16" has already been defined
__STATIC_FORCEINLINE uint32_t __SHADD16(
D:\Keil_v5\ARM\PACK\ARM\CMSIS\5.9.0\CMSIS\DSP\Include\dsp/none.h(314): error: #247: function "__QSUB16" has already been defined
__STATIC_FORCEINLINE uint32_t __QSUB16(
D:\Keil_v5\ARM\PACK\ARM\CMSIS\5.9.0\CMSIS\DSP\Include\dsp/none.h(330): error: #247: function "__SHSUB16" has already been defined
__STATIC_FORCEINLINE uint32_t __SHSUB16(
D:\Keil_v5\ARM\PACK\ARM\CMSIS\5.9.0\CMSIS\DSP\Include\dsp/none.h(346): error: #247: function "__QASX" has already been defined
__STATIC_FORCEINLINE uint32_t __QASX(
D:\Keil_v5\ARM\PACK\ARM\CMSIS\5.9.0\CMSIS\DSP\Include\dsp/none.h(362): error: #247: function "__SHASX" has already been defined
__STATIC_FORCEINLINE uint32_t __SHASX(
D:\Keil_v5\ARM\PACK\ARM\CMSIS\5.9.0\CMSIS\DSP\Include\dsp/none.h(378): error: #247: function "__QSAX" has already been defined
__STATIC_FORCEINLINE uint32_t __QSAX(
D:\Keil_v5\ARM\PACK\ARM\CMSIS\5.9.0\CMSIS\DSP\Include\dsp/none.h(394): error: #247: function "__SHSAX" has already been defined
__STATIC_FORCEINLINE uint32_t __SHSAX(
D:\Keil_v5\ARM\PACK\ARM\CMSIS\5.9.0\CMSIS\DSP\Include\dsp/none.h(410): error: #247: function "__SMUSDX" has already been defined
__STATIC_FORCEINLINE uint32_t __SMUSDX(
D:\Keil_v5\ARM\PACK\ARM\CMSIS\5.9.0\CMSIS\DSP\Include\dsp/none.h(421): error: #247: function "__SMUADX" has already been defined
__STATIC_FORCEINLINE uint32_t __SMUADX(
D:\Keil_v5\ARM\PACK\ARM\CMSIS\5.9.0\CMSIS\DSP\Include\dsp/none.h(433): error: #247: function "__QADD" has already been defined
__STATIC_FORCEINLINE int32_t __QADD(
D:\Keil_v5\ARM\PACK\ARM\CMSIS\5.9.0\CMSIS\DSP\Include\dsp/none.h(444): error: #247: function "__QSUB" has already been defined
__STATIC_FORCEINLINE int32_t __QSUB(
D:\Keil_v5\ARM\PACK\ARM\CMSIS\5.9.0\CMSIS\DSP\Include\dsp/none.h(455): error: #247: function "__SMLAD" has already been defined
__STATIC_FORCEINLINE uint32_t __SMLAD(
D:\Keil_v5\ARM\PACK\ARM\CMSIS\5.9.0\CMSIS\DSP\Include\dsp/none.h(469): error: #247: function "__SMLADX" has already been defined
__STATIC_FORCEINLINE uint32_t __SMLADX(
D:\Keil_v5\ARM\PACK\ARM\CMSIS\5.9.0\CMSIS\DSP\Include\dsp/none.h(483): error: #247: function "__SMLSDX" has already been defined
__STATIC_FORCEINLINE uint32_t __SMLSDX(
The problem is through cubemx Added a dsp library , And through the keil added dsp library . repeated .
Get rid of cubemx Inside dsp Library is enough . Remove the tick below .

Then only through keil add to dsp library .


It's easy to use at this time .
边栏推荐
- I did these three things before the interview, and the result was actually direct
- LeetCode 0140. 单词拆分 II
- Dynamic planning - 1049. Weight of the last stone II
- 8000 word explanation of OBSA principle and application practice
- Ch340 RTS DTR pin programming drives OLED
- [leetcode] 34. Find the first and last positions of elements in the sorted array
- un7.27:如何在idea中成功搭建若依框架项目?
- 月薪28K学员 自动化测试经验分享
- Monotonic stack - 739. Daily temperature
- 高等数学(第七版)同济大学 习题3-4 个人解答(后8题)
猜你喜欢

WordPress简约mkBlog博客主题模板v2.1

C语言:不创建临时变量实现两数交换

How to solve MySQL deep paging problem

xml文件使用及解析

MySQL Basics (create, manage, add, delete, and modify tables)

Advanced Mathematics (Seventh Edition) Tongji University exercises 3-6 personal solutions

Selenium -- Web automated testing tool

Summary of static blog building tools

《剑指offer》| 刷题小记

Differences among BRD, MRD and PRD
随机推荐
离职前一定要做好这7件事情,少一件都很麻烦。
LeetCode 0141. 环形链表 - 三种方法解决
After 95, Alibaba P7 published the payroll: it's really heartbreaking
Leetcode58. 最后一个单词的长度
常用的接口测试工具
WordPress simple mkblog blog theme template v2.1
Notes on writing questions in sword finger offer
Tungsten Fabric SDN — BGP as a Service
In the official online CV2 document, check the optional values of OpenCV specific parameters
Protocols in swift
WordPress简约mkBlog博客主题模板v2.1
基于SSM实现在线租房系统
ES6 from getting started to mastering 08: extended object functions
Monotonous stack -- 42. Receiving rain -- a difficult problem that big factories must know
My creation anniversary
[prototype and prototype chain] get to know prototype and prototype chain~
Ch340 RTS DTR pin programming drives OLED
LabVIEW loads and uses custom symbols in tree control projects
Advanced Mathematics (Seventh Edition) Tongji University exercises 3-4 personal solutions (the last 8 questions)
Advanced Mathematics (Seventh Edition) Tongji University exercises 3-4 personal solutions (first 8 questions)