Warning: The header file ‘cmsis_iar.h’ is obsolete and should not be used.

解决方法:

找到IAR安装arm路径:
image.png
对比以前的老版本CMSIS文件,正确的解决方法可以将IAR8.0版本安装路径……\Embedded Workbench 8.0\arm\inc\c下的cmsis_iar.h文件进行修改,将pragma-message(29-34行)语句替换成:

#if defined(CM_CMSIS_VERSION) && (CM_CMSIS_VERSION >= 0x50001)
#pragma message(“\nWarning: The header file ‘cmsis_iar.h’ is obsolete and should not be used.”)
#pragma message(“ A suitable version is automatically included from the CMSIS-core package.”)
#endif

image.png