430单片机程序很多报错 找不到改正方法。急求啊。

2019-03-24 10:14发布

Building configuration: adc12 - Debug
Updating build tree...
12864.c  
Error[Pe020]: identifier "CS1" is undefined C:UsersAdministratorDesktopAD新建文件夹12864.c 92
Error[Pe020]: identifier "CS2" is undefined C:UsersAdministratorDesktopAD新建文件夹12864.c 93
Error while running C/C++ compiler
main.cpp  
Error[Pe127]: expected a statement C:UsersAdministratorDesktopAD新建文件夹main.cpp 51
Error[Pe020]: identifier "CALDCO_16MHZ" is undefined C:UsersAdministratorDesktopAD新建文件夹main.cpp 68
Error[Pe020]: identifier "CALBC1_16MHZ" is undefined C:UsersAdministratorDesktopAD新建文件夹main.cpp 69
Error[Pe020]: identifier "ADC10CTL0" is undefined C:UsersAdministratorDesktopAD新建文件夹main.cpp 70
Error[Pe020]: identifier "ADC10SHT_2" is undefined C:UsersAdministratorDesktopAD新建文件夹main.cpp 70
Error[Pe020]: identifier "ADC10ON" is undefined C:UsersAdministratorDesktopAD新建文件夹main.cpp 70
Error[Pe020]: identifier "ADC10CTL1" is undefined C:UsersAdministratorDesktopAD新建文件夹main.cpp 71
Error[Pe020]: identifier "ADC10AE0" is undefined C:UsersAdministratorDesktopAD新建文件夹main.cpp 72
Error[Pe020]: identifier "ADC10SC" is undefined C:UsersAdministratorDesktopAD新建文件夹main.cpp 74
Error[Pe020]: identifier "TA1CTL" is undefined C:UsersAdministratorDesktopAD新建文件夹main.cpp 75
Error[Pe020]: identifier "TA1CCTL0" is undefined C:UsersAdministratorDesktopAD新建文件夹main.cpp 76
Error[Pe020]: identifier "TA1CCR0" is undefined C:UsersAdministratorDesktopAD新建文件夹main.cpp 77
Warning[Pe177]: variable "num" was declared but never referenced C:UsersAdministratorDesktopAD新建文件夹main.cpp 65
Error[Pe077]: this declaration has no storage class or type specifier C:UsersAdministratorDesktopAD新建文件夹main.cpp 99
Warning[Pe609]: this kind of pragma may not be used here C:UsersAdministratorDesktopAD新建文件夹main.cpp 98
Error[Pe065]: expected a ";" C:UsersAdministratorDesktopAD新建文件夹main.cpp 99
Warning[Pe012]: parsing restarts here after previous syntax error C:UsersAdministratorDesktopAD新建文件夹main.cpp 122
Error[Pe077]: this declaration has no storage class or type specifier C:UsersAdministratorDesktopAD新建文件夹main.cpp 123
Error[Pe247]: variable "max" has already been defined (at line 15) C:UsersAdministratorDesktopAD新建文件夹main.cpp 123
Error[Pe077]: this declaration has no storage class or type specifier C:UsersAdministratorDesktopAD新建文件夹main.cpp 123
Error[Pe247]: variable "i" has already been defined (at line 16) C:UsersAdministratorDesktopAD新建文件夹main.cpp 123
Error[Pe077]: this declaration has no storage class or type specifier C:UsersAdministratorDesktopAD新建文件夹main.cpp 123
Error[Pe247]: variable "n" has already been defined (at line 18) C:UsersAdministratorDesktopAD新建文件夹main.cpp 123
Error[Pe077]: this declaration has no storage class or type specifier C:UsersAdministratorDesktopAD新建文件夹main.cpp 124
Error[Pe247]: variable "TACTL @ 0x160" has already been defined (at line 493 of "D: oolsIAR EW430MSP430开发板经济版  BSL编程 MSP430F149单片机  C:UsersAdministratorDesktopAD新建文件夹main.cpp 124
学习板实验板相关软件MSP430编译开发软件新建文件夹430incmsp430f149.h")
Error[Pe065]: expected a ";" C:UsersAdministratorDesktopAD新建文件夹main.cpp 124
Error[Pe077]: this declaration has no storage class or type specifier C:UsersAdministratorDesktopAD新建文件夹main.cpp 125
Error[Pe247]: variable "TACCR0 @ 0x172" has already been defined (at line 503 of "D: oolsIAR EW430MSP430开发板经济版  BSL编程 MSP430F149单片机  C:UsersAdministratorDesktopAD新建文件夹main.cpp 125
学习板实验板相关软件MSP430编译开发软件新建文件夹430incmsp430f149.h")
Warning[Pe068]: integer conversion resulted in a change of sign C:UsersAdministratorDesktopAD新建文件夹main.cpp 125
Error[Pe077]: this declaration has no storage class or type specifier C:UsersAdministratorDesktopAD新建文件夹main.cpp 126
Error[Pe247]: variable "P1IE @ 0x25" has already been defined (at line 270 of "D: oolsIAR EW430MSP430开发板经济版  BSL编程 MSP430F149单片机 学习板实验板 C:UsersAdministratorDesktopAD新建文件夹main.cpp 126
相关软件MSP430编译开发软件新建文件夹430incmsp430f149.h")
Error[Pe065]: expected a ";" C:UsersAdministratorDesktopAD新建文件夹main.cpp 126
Error[Pe077]: this declaration has no storage class or type specifier C:UsersAdministratorDesktopAD新建文件夹main.cpp 127
Error[Pe247]: variable "TACCTL0 @ 0x162" has already been defined (at line 495 of "D: oolsIAR EW430MSP430开发板经济版  BSL编程 MSP430F149单片机  C:UsersAdministratorDesktopAD新建文件夹main.cpp 127
学习板实验板相关软件MSP430编译开发软件新建文件夹430incmsp430f149.h")
Error[Pe169]: expected a declaration C:UsersAdministratorDesktopAD新建文件夹main.cpp 128
Warning[Pe606]: this pragma must immediately precede a declaration C:UsersAdministratorDesktopAD新建文件夹main.cpp 129
Warning[Pe606]: this pragma must immediately precede a declaration C:UsersAdministratorDesktopAD新建文件夹main.cpp 138
Warning[Pe012]: parsing restarts here after previous syntax error C:UsersAdministratorDesktopAD新建文件夹main.cpp 187
Error[Pe077]: this declaration has no storage class or type specifier C:UsersAdministratorDesktopAD新建文件夹main.cpp 188
Error[Pe147]: declaration is incompatible with "__cc_version2 void lcd_dis_letter(unsigned char, unsigned char, unsigned char, char)" (declared at line 15 of "C: C:UsersAdministratorDesktopAD新建文件夹main.cpp 188
UsersAdministratorDesktopAD新建文件夹12864.h")
Error[Pe018]: expected a ")" C:UsersAdministratorDesktopAD新建文件夹main.cpp 188
Error[Pe077]: this declaration has no storage class or type specifier C:UsersAdministratorDesktopAD新建文件夹main.cpp 189
Error[Pe247]: variable "lcd_dis_letter" has already been defined (at line 188) C:UsersAdministratorDesktopAD新建文件夹main.cpp 189
Error[Pe018]: expected a ")" C:UsersAdministratorDesktopAD新建文件夹main.cpp 189
Error[Pe077]: this declaration has no storage class or type specifier C:UsersAdministratorDesktopAD新建文件夹main.cpp 190
Error[Pe147]: declaration is incompatible with "__cc_version2 void lcd_dis_num(unsigned char, unsigned char, unsigned char, char)" (declared at line 14 of "C: C:UsersAdministratorDesktopAD新建文件夹main.cpp 190
UsersAdministratorDesktopAD新建文件夹12864.h")
Error[Pe018]: expected a ")" C:UsersAdministratorDesktopAD新建文件夹main.cpp 190
Error[Pe077]: this declaration has no storage class or type specifier C:UsersAdministratorDesktopAD新建文件夹main.cpp 191
Error[Pe247]: variable "lcd_dis_num" has already been defined (at line 190) C:UsersAdministratorDesktopAD新建文件夹main.cpp 191
Error[Pe018]: expected a ")" C:UsersAdministratorDesktopAD新建文件夹main.cpp 191
Error[Pe077]: this declaration has no storage class or type specifier C:UsersAdministratorDesktopAD新建文件夹main.cpp 192
Error[Pe247]: variable "lcd_dis_num" has already been defined (at line 190) C:UsersAdministratorDesktopAD新建文件夹main.cpp 192
Error[Pe018]: expected a ")" C:UsersAdministratorDesktopAD新建文件夹main.cpp 192
Error[Pe077]: this declaration has no storage class or type specifier C:UsersAdministratorDesktopAD新建文件夹main.cpp 193
Error[Pe247]: variable "lcd_dis_num" has already been defined (at line 190) C:UsersAdministratorDesktopAD新建文件夹main.cpp 193
Error[Pe018]: expected a ")" C:UsersAdministratorDesktopAD新建文件夹main.cpp 193
Error[Pe077]: this declaration has no storage class or type specifier C:UsersAdministratorDesktopAD新建文件夹main.cpp 194
Error[Pe247]: variable "lcd_dis_num" has already been defined (at line 190) C:UsersAdministratorDesktopAD新建文件夹main.cpp 194
Error[Pe018]: expected a ")" C:UsersAdministratorDesktopAD新建文件夹main.cpp 194
Error[Pe169]: expected a declaration C:UsersAdministratorDesktopAD新建文件夹main.cpp 195
Error while running C/C++ compiler

Total number of errors: 55
Total number of warnings: 7
此帖出自小平头技术问答
友情提示: 此问题已得到解决,问题已经关闭,关闭后问题禁止继续编辑,回答。
6条回答
qiushenghua
2019-03-24 15:25
这个没人帮得了你,一堆的变量没定义,是不是哪个头文件没有包含成功?
连CALDCO_16MHZ都没定义,那肯定是环境配置得不对了……要么就是选错芯片了。

一周热门 更多>

相关问题

    相关文章