Undefined symbol SystemInit(referred from startup_stm32f2xx.o) while building using Keil STM32

拟墨画扇 提交于 2019-12-04 19:19:46
aGuegu

"Libraries\CMSIS\CM3\DeviceSupport\ST\STM32F10x\system_stm32f10x.c" is needed it be added, as SystemInit() is defined within it.

Well, you should define (or take it from somewhere) function SystemInit, since it is called from startup.s file.

Or you can comment lines in startup file, where SystemInit function is called. There will be something like:

1 IMPORT  SystemInit
2 IMPORT  __main
3 LDR     R0, =SystemInit
4 BLX     R0
5 LDR     R0, =__main
6 BX      R0

You can comment lines 1,3,4 with ; symbol.

Actually, function SystemInit usually is part of STM Peripheral library and it's aimed to initialize all periphery that you need. Without it, you'll have to do initialization yourself.

May be it is too late, but: You should check Keil uVision installation folder and there are files with SystemInit function on board for all (I hope) vendors:)

~\Keil\ARM\Startup\ST\STM32F2xx\system_stm32f2xx.c

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!