首先第一步我安装了C55XCSL-LOWPOWER这个库,发现里面有一些例程和源码,但是里面没有.lib文件。
之后我安装了下面的TMS320C5500 Chip Support Library,发现有lib文件。
之后我就新建了一个TMS320C5517的工程。
build和link的配置如下:
main函数只有下面几行代码:
#include "csl_gpio.h"
//#include "csl_intc.h"
#include <stdio.h>
//#include <csl_general.h>
//#include "csl_sysctrl.h"
void main(void)
{
CSL_init();
}
//#include "csl_intc.h"
#include <stdio.h>
//#include <csl_general.h>
//#include "csl_sysctrl.h"
void main(void)
{
CSL_init();
}
但是编译后出现的错误如下:
"C:\\ti\\ccsv6\\utils\\bin\\gmake" -k all
'Building file: ../main.c'
'Invoking: C5500 Compiler'
"C:/ti/ccsv6/tools/compiler/c5500_4.4.1/bin/cl55" -v5515 --memory_model=small -g --include_path="C:/ti/ccsv6/tools/compiler/c5500_4.4.1/include" --include_path="C:/ti/ccsv6/tools/compiler/c5500_4.4.1/include" --include_path="C:/Program Files/C55xxCSL/include" --define=CHIP_5510PG2_1 --display_error_number --diag_warning=225 --ptrdiff_size=16 --asm_source=algebraic --preproc_with_compile --preproc_dependency="main.d" "../main.c"
8 Assembly Errors, No Assembly Warnings
'Building file: ../main.c'
'Invoking: C5500 Compiler'
"C:/ti/ccsv6/tools/compiler/c5500_4.4.1/bin/cl55" -v5515 --memory_model=small -g --include_path="C:/ti/ccsv6/tools/compiler/c5500_4.4.1/include" --include_path="C:/ti/ccsv6/tools/compiler/c5500_4.4.1/include" --include_path="C:/Program Files/C55xxCSL/include" --define=CHIP_5510PG2_1 --display_error_number --diag_warning=225 --ptrdiff_size=16 --asm_source=algebraic --preproc_with_compile --preproc_dependency="main.d" "../main.c"
8 Assembly Errors, No Assembly Warnings
>> Compilation failure
subdir_rules.mk:7: recipe for target 'main.obj' failed
"C:\Users\GaoJL\AppData\Local\Temp\8729210", ERROR! at line 12: [E0004]
Substitution symbol operand expected
.asg DPH, MDP
^
"C:\Users\GaoJL\AppData\Local\Temp\8729210", ERROR! at line 71: [E0000]
parse error
AADD #-1, SP
^
"C:\Users\GaoJL\AppData\Local\Temp\8729210", ERROR! at line 81: [E0000]
parse error
MOV #0, T0
^
"C:\Users\GaoJL\AppData\Local\Temp\8729210", ERROR! at line 89: [E0000]
parse error
AADD #1, SP
^
"C:\Users\GaoJL\AppData\Local\Temp\8729210", ERROR! at line 94: [E0000]
parse error
RET
^
"C:\Users\GaoJL\AppData\Local\Temp\8729210", ERROR! at line 129:
[E0000]
parse error
AADD #-1, SP
^
"C:\Users\GaoJL\AppData\Local\Temp\8729210", ERROR! at line 139:
[E0000]
parse error
AADD #1, SP
^
"C:\Users\GaoJL\AppData\Local\Temp\8729210", ERROR! at line 144:
[E0000]
parse error
RET
^
subdir_rules.mk:7: recipe for target 'main.obj' failed
"C:\Users\GaoJL\AppData\Local\Temp\8729210", ERROR! at line 12: [E0004]
Substitution symbol operand expected
.asg DPH, MDP
^
"C:\Users\GaoJL\AppData\Local\Temp\8729210", ERROR! at line 71: [E0000]
parse error
AADD #-1, SP
^
"C:\Users\GaoJL\AppData\Local\Temp\8729210", ERROR! at line 81: [E0000]
parse error
MOV #0, T0
^
"C:\Users\GaoJL\AppData\Local\Temp\8729210", ERROR! at line 89: [E0000]
parse error
AADD #1, SP
^
"C:\Users\GaoJL\AppData\Local\Temp\8729210", ERROR! at line 94: [E0000]
parse error
RET
^
"C:\Users\GaoJL\AppData\Local\Temp\8729210", ERROR! at line 129:
[E0000]
parse error
AADD #-1, SP
^
"C:\Users\GaoJL\AppData\Local\Temp\8729210", ERROR! at line 139:
[E0000]
parse error
AADD #1, SP
^
"C:\Users\GaoJL\AppData\Local\Temp\8729210", ERROR! at line 144:
[E0000]
parse error
RET
^
Errors in Source - Assembler Aborted
gmake: *** [main.obj] Error 1
gmake: Target 'all' not remade because of errors.
gmake: *** [main.obj] Error 1
gmake: Target 'all' not remade because of errors.
**** Build Finished ****
CCS版本7.4.0和6.3.1都试过,结果一样。
编译器版本如下:
但不知道什么原因,麻烦请解答一下。






