打印
[STM8]

stm8 固件库编译不过问题

[复制链接]
1967|2
手机看帖
扫描二维码
随时随地手机跟帖
跳转到指定楼层
楼主
miloCong|  楼主 | 2018-1-28 19:31 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式
IAR新创建的stm8工程添加固件库,芯片选型为STM8S103,编译时固件库报错,求解!

错误信息为:
Building configuration: Led - Debug
Updating build tree...
stm8s_adc1.c  
main.c  
stm8s_adc2.c  
Error[Pe020]: identifier "ADC2" is undefined D:\LedTest\Lib\STM8S_StdPeriph_Driver\src\stm8s_adc2.c 56
Error[Pe020]: identifier "ADC2_CSR_RESET_VALUE" is undefined D:\LedTest\Lib\STM8S_StdPeriph_Driver\src\stm8s_adc2.c 56
Error[Pe020]: identifier "ADC2_CR1_RESET_VALUE" is undefined D:\LedTest\Lib\STM8S_StdPeriph_Driver\src\stm8s_adc2.c 57
Error[Pe020]: identifier "ADC2_CR2_RESET_VALUE" is undefined D:\LedTest\Lib\STM8S_StdPeriph_Driver\src\stm8s_adc2.c 58
Error[Pe020]: identifier "ADC2_TDRH_RESET_VALUE" is undefined D:\LedTest\Lib\STM8S_StdPeriph_Driver\src\stm8s_adc2.c 59
Error[Pe020]: identifier "ADC2_TDRL_RESET_VALUE" is undefined D:\LedTest\Lib\STM8S_StdPeriph_Driver\src\stm8s_adc2.c 60
Error[Pe020]: identifier "ADC2" is undefined D:\LedTest\Lib\STM8S_StdPeriph_Driver\src\stm8s_adc2.c 113
Error[Pe020]: identifier "ADC2_CR1_ADON" is undefined D:\LedTest\Lib\STM8S_StdPeriph_Driver\src\stm8s_adc2.c 113
Error[Pe020]: identifier "ADC2" is undefined D:\LedTest\Lib\STM8S_StdPeriph_Driver\src\stm8s_adc2.c 128
Error[Pe020]: identifier "ADC2_CR1_ADON" is undefined D:\LedTest\Lib\STM8S_StdPeriph_Driver\src\stm8s_adc2.c 128
Error[Pe020]: identifier "ADC2" is undefined D:\LedTest\Lib\STM8S_StdPeriph_Driver\src\stm8s_adc2.c 132
Error[Pe020]: identifier "ADC2_CR1_ADON" is undefined D:\LedTest\Lib\STM8S_StdPeriph_Driver\src\stm8s_adc2.c 132
Error[Pe020]: identifier "ADC2" is undefined D:\LedTest\Lib\STM8S_StdPeriph_Driver\src\stm8s_adc2.c 149
Error[Pe020]: identifier "ADC2_CSR_EOCIE" is undefined D:\LedTest\Lib\STM8S_StdPeriph_Driver\src\stm8s_adc2.c 149
Error[Pe020]: identifier "ADC2" is undefined D:\LedTest\Lib\STM8S_StdPeriph_Driver\src\stm8s_adc2.c 154
Error[Pe020]: identifier "ADC2_CSR_EOCIE" is undefined D:\LedTest\Lib\STM8S_StdPeriph_Driver\src\stm8s_adc2.c 154
Error[Pe020]: identifier "ADC2" is undefined D:\LedTest\Lib\STM8S_StdPeriph_Driver\src\stm8s_adc2.c 170
Error[Pe020]: identifier "ADC2_CR1_SPSEL" is undefined D:\LedTest\Lib\STM8S_StdPeriph_Driver\src\stm8s_adc2.c 170
Error[Pe020]: identifier "ADC2" is undefined D:\LedTest\Lib\STM8S_StdPeriph_Driver\src\stm8s_adc2.c 193
Error[Pe020]: identifier "ADC2" is undefined D:\LedTest\Lib\STM8S_StdPeriph_Driver\src\stm8s_adc2.c 198
Error[Pe020]: identifier "ADC2" is undefined D:\LedTest\Lib\STM8S_StdPeriph_Driver\src\stm8s_adc2.c 206
Error[Pe020]: identifier "ADC2" is undefined D:\LedTest\Lib\STM8S_StdPeriph_Driver\src\stm8s_adc2.c 210
Error[Pe020]: identifier "ADC2" is undefined D:\LedTest\Lib\STM8S_StdPeriph_Driver\src\stm8s_adc2.c 217
Error[Pe020]: identifier "ADC2" is undefined D:\LedTest\Lib\STM8S_StdPeriph_Driver\src\stm8s_adc2.c 221
Error[Pe020]: identifier "ADC2" is undefined D:\LedTest\Lib\STM8S_StdPeriph_Driver\src\stm8s_adc2.c 244
Error[Pe020]: identifier "ADC2_CR2_ALIGN" is undefined D:\LedTest\Lib\STM8S_StdPeriph_Driver\src\stm8s_adc2.c 244
Error[Pe020]: identifier "ADC2_CR1_CONT" is undefined D:\LedTest\Lib\STM8S_StdPeriph_Driver\src\stm8s_adc2.c 251
Error[Pe020]: identifier "ADC2_CR1_CONT" is undefined D:\LedTest\Lib\STM8S_StdPeriph_Driver\src\stm8s_adc2.c 256
Error[Pe020]: identifier "ADC2_CSR_CH" is undefined D:\LedTest\Lib\STM8S_StdPeriph_Driver\src\stm8s_adc2.c 260
Error[Pe020]: identifier "ADC2" is undefined D:\LedTest\Lib\STM8S_StdPeriph_Driver\src\stm8s_adc2.c 282
Error[Pe020]: identifier "ADC2_CR2_EXTSEL" is undefined D:\LedTest\Lib\STM8S_StdPeriph_Driver\src\stm8s_adc2.c 282
Error[Pe020]: identifier "ADC2_CR2_EXTTRIG" is undefined D:\LedTest\Lib\STM8S_StdPeriph_Driver\src\stm8s_adc2.c 287
沙发
mmuuss586| | 2018-2-8 19:55 | 只看该作者
这么多错误,.h文件没添加完整吧;

使用特权

评论回复
板凳
ds86| | 2019-12-27 17:52 | 只看该作者
选择的器件型号内没有显示的相关硬件模块,去掉相关的模块即可或者选择错了器件型号

使用特权

评论回复
发新帖 我要提问
您需要登录后才可以回帖 登录 | 注册

本版积分规则

5

主题

17

帖子

0

粉丝