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

omapl138 starterware 使用delay()函数时编译出错

我的工程里面加了delay()之后就编译报错

# Making ../bin/server_dsp.xe674 …
/opt/ti/ccsv5/tools/compiler/c6000_7.4.4/bin/lnk6x –abi=eabi -w -q -c -m ../bin/server_dsp.xe674.map -o ../bin/server_dsp.xe674 main.oe674 sys.oe674 shm_ipc.oe674 shm_ipc_handler.oe674 hostmsg.oe674 osdep.oe674 bsp/uart.oe674 bsp/timer.oe674 bsp/emif.oe674 bsp/gpio.oe674 bsp/led.oe674 bsp/edma.oe674 bsp/adc.oe674 utils/utility.oe674 diagnose/diagnose.oe674 ../shared/public_memory.oe674 ../shared/adcdata.oe674 ../algorithm/analytic.oe674 ../algorithm/basic_random.oe674 ../algorithm/curvefit.oe674 ../algorithm/diagnonsis_analysis.oe674 ../algorithm/DigitalIIR.oe674 ../algorithm/fct.oe674 ../algorithm/fft.oe674 ../algorithm/fht.oe674 ../algorithm/ifct.oe674 ../algorithm/irfft.oe674 ../algorithm/light_matrix.oe674 ../algorithm/linearInterpolation.oe674 ../algorithm/math_basic.oe674 ../algorithm/rfft.oe674 ../algorithm/spectrum_analysis.oe674 ../algorithm/spectrum_basic.oe674 ../algorithm/statistics_utils.oe674 ../algorithm/transform.oe674 ../algorithm/wave_basic.oe674 ../algorithm/wdt.oe674 ../algorithm/window.oe674 ../algorithm/testalgo.oe674 configuro/linker.cmd -l /opt/ti/ccsv5/tools/compiler/c6000_7.4.4/lib/rts6740_elf.lib -l/opt/ti/OMAPL138_StarterWare_1_10_04_01/binary/c674x/cgt/omapl138/drivers/Release/drivers.lib -l/opt/ti/OMAPL138_StarterWare_1_10_04_01/binary/c674x/cgt/utils/Release/utils.lib -l/opt/ti/OMAPL138_StarterWare_1_10_04_01/binary/c674x/cgt/omapl138/evmOMAPL138/platform/Release/platform.lib -l/opt/ti/OMAPL138_StarterWare_1_10_04_01/binary/c674x/cgt/omapl138/system_config/Release/system_config.lib

undefined first referenced 
symbol in file 
——— —————- 
TimerConfigure /opt/ti/OMAPL138_StarterWare_1_10_04_01/binary/c674x/cgt/omapl138/evmOMAPL138/platform/Release/platform.lib<sysdelay.obj>
TimerCounterSet /opt/ti/OMAPL138_StarterWare_1_10_04_01/binary/c674x/cgt/omapl138/evmOMAPL138/platform/Release/platform.lib<sysdelay.obj>
TimerDisable /opt/ti/OMAPL138_StarterWare_1_10_04_01/binary/c674x/cgt/omapl138/evmOMAPL138/platform/Release/platform.lib<sysdelay.obj>
TimerEnable /opt/ti/OMAPL138_StarterWare_1_10_04_01/binary/c674x/cgt/omapl138/evmOMAPL138/platform/Release/platform.lib<sysdelay.obj>
TimerIntDisable /opt/ti/OMAPL138_StarterWare_1_10_04_01/binary/c674x/cgt/omapl138/evmOMAPL138/platform/Release/platform.lib<sysdelay.obj>
TimerIntEnable /opt/ti/OMAPL138_StarterWare_1_10_04_01/binary/c674x/cgt/omapl138/evmOMAPL138/platform/Release/platform.lib<sysdelay.obj>
TimerIntStatusClear /opt/ti/OMAPL138_StarterWare_1_10_04_01/binary/c674x/cgt/omapl138/evmOMAPL138/platform/Release/platform.lib<sysdelay.obj>
TimerPeriodSet /opt/ti/OMAPL138_StarterWare_1_10_04_01/binary/c674x/cgt/omapl138/evmOMAPL138/platform/Release/platform.lib<sysdelay.obj>

error: unresolved symbols remain
error: errors encountered during linking; "../bin/server_dsp.xe674" not built
makefile:43: recipe for target '../bin/server_dsp.xe674' failed
make[2]: *** [../bin/server_dsp.xe674] Error 1
make[2]: Leaving directory '/mnt/hgfs/win/czbox_ompl138/dsp'
makefile:39: recipe for target 'all' failed
make[1]: *** [all] Error 2
make[1]: Leaving directory '/mnt/hgfs/win/czbox_ompl138/dsp'
makefile:43: recipe for target 'all' failed
make: *** [all] Error 2

错误中提示定时器相关的函数未定义,这几个函数应该是在driver.lib中定义的吧,这个库位已经链接了,为什么还报错,不知道是什么情况,还请高手指点,谢谢了!

huozhen:

我后来将driver.lib 放在platform.lib后面就可以编译通过,但是运行的时候,直接停在delay语句处,我怀疑是starterware的定时器库和sysbios中的定时器冲突了,不知道是不是这个原因,现在我放弃使用starterware 库中的delay了。如果哪位高手知道原因还请指出,谢谢!

Shine:

回复 huozhen:

starterware的delay函数用到是timer0,看一下sys/bios cfg里clock module用的是哪个timer ID,看有没有冲突。

huozhen:

回复 Shine:

非常感谢!在 https://e2echina.ti.com/question_answer/dsp_arm/c6000_multicore/f/53/t/52276 这个帖子中TI的工程师Lin Feng1提到timer0~7被sysbios内部使用,不知这些timer默认是用来做什么的,能不能改呢?如果不行恐怕只能修改starterware里的了。

Tony Tang:

回复 huozhen:

SYSBIOS只会用到一个Timer用做Tick/clock. 

huozhen:

回复 Tony Tang:

好的,谢谢

huozhen:

回复 Tony Tang:

好的,谢谢

赞(0)
未经允许不得转载:TI中文支持网 » omapl138 starterware 使用delay()函数时编译出错
分享到: 更多 (0)