当前位置:网站首页>Error[pe147]: declaration is incompatible with 'error problem
Error[pe147]: declaration is incompatible with 'error problem
2022-07-26 10:42:00 【aping_ cs_ dn】
Below there is the solution.
The customer's file:
...\Libraries\CMSIS\CM3\CoreSupport\core_cm3.h
is a very old version of CMSIS (V1.30 from 2009) with no adaptations for IAR Embedded Workbench for ARM.
It is not possible to use this old header file with EWARM 6.30.6.
Included and integrated in IAR Embedded Workbench for ARM 6.30.6 is "core_cm3.h" version V2.11 from 2011.
See the directory:
<EWARM>\arm\CMSIS\Include\core_cm3.h
To take advantage of this new, improved CMSIS library, just select:
Project -> Options -> General Options -> Library Configuration -> Use CMSIS
The fix for this project as described by Technical Note 75890:
http://supp.iar.com/Support/?note=75890
is to:
A. Rename the outdated CMSIS file "...\Libraries\CMSIS\CM3\CoreSupport\core_cm3.h" to "core_cm3.h.old" (for example)

B. Enable CMSIS: Project -> Options -> General Options -> Library Configuration -> Use CMSIS

Index
-
CMSIS build problems with IAR Embedded Workbench ver. 6.20
...........
...........
Error[Og006]: Syntax error in inline assembly: "Error[446]: The selected cpu/core does not support this status register" C:\TraningSTM-Castelletto-F200-052011\Copia\Examples\LABS\Libraries\CMSIS\CM3\CoreSupport\core_cm3.c 268
Error[Og006]: Syntax error in inline assembly: "Error[438]: This instruction is not available in the selected cpu/core" C:\TraningSTM-Castelletto-F200-052011\Copia\Examples\LABS\Libraries\CMSIS\CM3\CoreSupport\core_cm3.c 324
Error[Pe147]: declaration is incompatible with "__thumb __softfp unsigned long __REV16(unsigned long)" (declared at line 173 of "C:\Program Files\IAR C:\TraningSTM-Castelletto-F200-052011\Copia\Examples\LABS\Libraries\CMSIS\CM3\CoreSupport\core_cm3.h 1124
Systems\Embedded Workbench 6.0 Kickstart_2\arm\inc\c\intrinsics.h")
Error[Pe147]: declaration is incompatible with "__thumb __softfp unsigned long __RBIT(unsigned long)" (declared at line 174 of "C:\Program Files\IAR C:\TraningSTM-Castelletto-F200-052011\Copia\Examples\LABS\Libraries\CMSIS\CM3\CoreSupport\core_cm3.h 1134
Systems\Embedded Workbench 6.0 Kickstart_2\arm\inc\c\intrinsics.h")
Error[Pe147]: declaration is incompatible with "__thumb __softfp unsigned long __REV16(unsigned long)" (declared at line 173 of "C:\Program Files\IAR C:\TraningSTM-Castelletto-F200-052011\Copia\Examples\LABS\Libraries\CMSIS\CM3\CoreSupport\core_cm3.h 1124
Systems\Embedded Workbench 6.0 Kickstart_2\arm\inc\c\intrinsics.h")
Error[Pe147]: declaration is incompatible with "__thumb __softfp unsigned long __REV16(unsigned long)" (declared at line 173 of "C:\Program Files\IAR C:\TraningSTM-Castelletto-F200-052011\Copia\Examples\LABS\Libraries\CMSIS\CM3\CoreSupport\core_cm3.h 1124
Systems\Embedded Workbench 6.0 Kickstart_2\arm\inc\c\intrinsics.h")
Error[Pe147]: declaration is incompatible with "__thumb __softfp unsigned long __STREXH(unsigned short, unsigned short *)" (declared at line 182 of "C:\ C:\TraningSTM-Castelletto-F200-052011\Copia\Examples\LABS\Libraries\CMSIS\CM3\CoreSupport\core_cm3.h 1186
Program Files\IAR Systems\Embedded Workbench 6.0 Kickstart_2\arm\inc\c\intrinsics.h")
...........
...........
This is caused to the fact that IAR now incorporate CMSIS files that are also inside the STM Library.
This problem is known and the IAR solution is here (html page) or here (pdf).
My solution is: commenting the line 93 in the file core_cm3.c, see below.

It is not an elegant solution but it work.
边栏推荐
- 同步方法中不使用asyncTask<T> 修饰和await获取异步返回值(同步方法中调用异步方法)
- 【论文下饭】Deep Mining External Imperfect Data for ChestX-ray Disease Screening
- 构建ARM嵌入式开发环境
- 7-25 0-1背包 (50分)
- MySQL速学笔记-2021-08-31
- [machine learning notes] [face recognition] deeplearning ai course4 4th week programming
- display-inline+calc实现左中右布局,中间自适应
- Issue 5: the second essential skill for College Students
- [转]ArcGIS中判断两个Geometry之间的关系
- 第6期:大学生应该选择哪种主流编程语言
猜你喜欢
Uniapp uses the simple method signalr (only for web debugging, cannot package apps)
第7期:内卷和躺平,你怎么选
一文详解Nodejs中fs文件模块与path路径模块
Dry goods likeshop takeout order system is open source, 100% open source, no encryption
第6期:大学生应该选择哪种主流编程语言
解决:无法加载文件 C:\Users\user\AppData\Roaming\npm\npx.ps1,因为在此系统上禁止运行脚本 。
工厂模式详解
RT-Thread 学习笔记(一)---配置RT-Thread开发环境
[leetcode每日一题2021/8/31]1109. 航班预订统计【中等】差分数组
[machine learning notes] [style transfer] deeplearning ai course4 4th week programming(tensorflow2)
随机推荐
鹏哥C语言第四课(3)
剑指Offer(五):用两个栈实现队列
Flutter编译报错 version of NDK matched the requested version 21.0.6113669. Versions available locally: 2
在altium designer中禁用USBJATG
比较器(Comparable与Comparator接口)
Redis special data type usage scenarios
第6期:大学生应该选择哪种主流编程语言
解决:无法加载文件 C:\Users\user\AppData\Roaming\npm\npx.ps1,因为在此系统上禁止运行脚本 。
[leetcode每日一题2021/2/13]448. 找到所有数组中消失的数字
SAP ABAP 守护进程的实现方式
Asynctask < T> decoration and await are not used in synchronous methods to obtain asynchronous return values (asynchronous methods are called in synchronous methods)
10 令 operator= 返回一个 reference to *this
flutter 背景变灰效果,如何透明度,灰色蒙板遮罩
2021-08-14三子棋
父类对子类的引用(父类引用指向子类对象)
剑指Offer(二十):包含min函数的栈
Flutter TextField怎样去除下划线及有焦点时颜色
工厂模式详解
[machine learning notes] [style transfer] deeplearning ai course4 4th week programming(tensorflow2)
2021-08-13和鹏哥学C语言-数组