STM32F10x_StdPeriph_Lib_V3.5.0在Keil上编译遇到的问题总结

【1】出warning: #223-D: function "assert_param" declared implicitly

解决方法很简单,MDK的在工程上点右键,选择options,选择C/C++选项,在defined的框里填上USE_STDPERIPH_DRIVER就可以了。

还要根据自己所用芯片在defined填上如STM32F10X_HD,这样就编译就不会出错了。

stm32f10x芯片分类表
STM32F10X_LDSTM32F10X_MDSTM32F10X_HDSTM32F10X_CL
CPU型号STM32F101xx

STM32F102xx

STM32F103xx

STM32F101xx

STM32F102xx

STM32F103xx

STM32F101xx

STM32F103xx

STM32F105xx

STM32F107xx

flash大小16 ~ 32 Kbytes64 ~ 128 Kbytes256 ~ 512 Kbytes所有flash大小
LD == Low Density

HD == High Density

CL == Connective Line

【2】在汇编代码中/× ×/这样的C语言注释符号,keil不认识,报错, 怎么办

报错形式:error: A1167E: Invalid line start

MDK的在工程上点右键,选择options,选择Asm选项,在Misc Controls框框中输入 --cpreproc

意思所在汇编armasm编译汇编代码之前先用armcc将代码中C注释预编译掉

参考:http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.kui0100a/armasm_chdhcfgd.htm

【3】error: A1137E: Unexpected characters at end of line

This is given when extra characters that are not part of an instruction are found on an instruction line.

For example:
ADD r0, r0, r1 comment

Can be changed to:
ADD r0, r0, r1 ; comment

参考:http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.dui0496c/CACHCBBJ.html





  • 0
    点赞
  • 5
    收藏
    觉得还不错? 一键收藏
  • 1
    评论
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值