TI中文支持网
TI专业的中文技术问题搜集分享网站

debug 工程时报错,关于startup.c

一个spi的例程,debug后,全速跑起来后点选终止,会报错: cant find a source file at "D:/startware_gitorious_omapl138/startwarr_01_10_04_01/system_config/armv5/cgt/init.asm",我的工程里没有该路径,希望大家可以指点一下,还有另外一种报错,也是这个路径下,找不到startup.c

Shine:

改成您电脑上starterware的安装路径,或者说改成您电脑上init.asm所在的路径。

kun liu:

回复 Shine:

谢谢您的回复。
首先,我想问的是这个路径在哪里设置,我自己的电脑上没有“startware_gitorious_omapl138”这个文件夹,但是我在c盘ti文件夹“C:/ti/startware_01_10_04_01/system_config/armv5/cgt/init.asm”找到该文件,并添加近来。
然后重新debug,跑到主循环里循环一次后,再次循环在断点不能停下,点击suspend后停在刚才添加进来的“init.asm”文件。
118行~130行
; Enter the start_boot function. The execution still happens in system mode
;
LDR r10, _start_boot ; Get the address of start_boot
MOV lr,pc ; Dummy return
BX r10 ; Branch to start_boot
SUB pc, pc, #0x08 ; looping

; MSR cpsr_c, #MODE_SVC|I_F_BIT ; change to SVC mode
; BX lr
;
; End of the file
;
请问这个是什么情况。
我看这句话“ SUB pc, pc, #0x08 ; looping”,looping的意思貌似是在循环里,但是这句“Enter the start_boot function. The execution still happens in system mode”感觉应该程序启动后先运行init文件,但是我的情况好像相反,我已经跑进main函数,执行到while循环里,却跳转到这里,我很迷惑。请求赐教!

Shine:

回复 kun liu:

您指的“一个spi的例程”是starterware里自带的例程吗?

kun liu:

回复 Shine:

您好,不是的。

赞(0)
未经允许不得转载:TI中文支持网 » debug 工程时报错,关于startup.c
分享到: 更多 (0)