历史上的今天
今天是:2024年08月26日(星期一)
2020年08月26日 | PICC编译错误
2020-08-26 来源:eefocus
程序一:
#include 程序二: #include 因为上边顺序的不同,造成编译时出错不断, Clean: Deleting intermediary and output files.
__CONFIG(WDTDIS);
#define delay_i 4
#define delay_j 10000
void delays()
{
int i=0;
int j=0;
for(i=0;i<=delay_i;i++)
{
for(j=0;j<=delay_j;j++)
;
}
}
void main(void)
{
int i=0;
char NUM[]={0b00111111,0b00000110,0b01011011,0b01001111,0b01100110,0b01101101,0b01011111,0b00000111,0b01111111,0b01101111};
TRISC=0;
while(1)
{
for(i=0;i<=9;i++)
{
delays();
PORTC=NUM[i];
}
}
}
__CONFIG(WDTDIS);
#define delay_i 4
#define delay_j 10000
void delays()
{
int i=0;
int j=0;
for(i=0;i<=delay_i;i++)
{
for(j=0;j<=delay_j;j++)
;
}
}
void main(void)
{
TRISC=0;
int i=0;
char NUM[]={0b00111111,0b00000110,0b01011011,0b01001111,0b01100110,0b01101101,0b01011111,0b00000111,0b01111111,0b01101111};
while(1)
{
for(i=0;i<=9;i++)
{
delays();
PORTC=NUM[i];
}
}
}
Clean: Deleted file "F:PICC04S044S044.obj".
Clean: Deleted file "F:PICC04S044S044.cce".
Clean: Deleted file "S044.cof".
Clean: Done.
Executing: "C:Program FilesHI-TECH SoftwarePICC9.50binpicc.exe" -C -E"S044.cce" "S044.C" -O"S044.obj" -Zg9 -O -ASMLIST -Q -MPLAB -16F877A
Advisory[1209] : An old MPLAB tool suite plug-in was detected. Some options may not work correctly
Advisory[1210] : Visit www.htsoft.com or contact support@htsoft.com for an update
Warning[176] F:PICC04S044S044.C 37 : missing newline
Warning[349] F:PICC04S044S044.C 11 : non-prototyped function declaration for "delays"
Error[249] F:PICC04S044S044.C 26 : probable missing "}" in previous block
Error[285] F:PICC04S044S044.C 29 : no identifier in declaration
Warning[374] F:PICC04S044S044.C 29 : missing basic type; int assumed
Error[314] F:PICC04S044S044.C 29 : ";" expected
Warning[374] F:PICC04S044S044.C 31 : missing basic type; int assumed
Error[314] F:PICC04S044S044.C 31 : ";" expected
Warning[374] F:PICC04S044S044.C 31 : missing basic type; int assumed
Error[314] F:PICC04S044S044.C 31 : ";" expected
Warning[374] F:PICC04S044S044.C 34 : missing basic type; int assumed
Error[983] F:PICC04S044S044.C 34 : storage class redeclared
Error[984] F:PICC04S044S044.C 34 : type redeclared
Error[239] F:PICC04S044S044.C 34 : identifier "PORTC" redefined (from line 26)
Error[188] F:PICC04S044S044.C 34 : constant expression required
Error[285] F:PICC04S044S044.C 35 : no identifier in declaration
Warning[374] F:PICC04S044S044.C 35 : missing basic type; int assumed
Error[314] F:PICC04S044S044.C 35 : ";" expected
Error[285] F:PICC04S044S044.C 36 : no identifier in declaration
Warning[374] F:PICC04S044S044.C 36 : missing basic type; int assumed
Error[314] F:PICC04S044S044.C 36 : ";" expected
Warning[337] F:PICC04S044S044.C 36 : line does not have a newline on the end
Error[285] F:PICC04S044S044.C 37 : no identifier in declaration
Warning[374] F:PICC04S044S044.C 37 : missing basic type; int assumed
Error[314] F:PICC04S044S044.C 37 : ";" expected
Halting build on first failure as requested.
BUILD FAILED: Mon Sep 26 11:58:20 2011
找了很久都找不出问题所在,只好挨条删除测试,最后终于发现问题所在,是由于引脚初始化与定义变量顺序的问题,写出来以供参考。
史海拾趣
|
摘自:https://www.eeworld.com.cn/exclusives/2010/1020/article_262.html 绯闻最终总会成真,这个定律不止适用于娱乐界。沸沸扬扬的成芯事件终于在10月15日这天落定。 其实这应该是两件事,一是成芯的去向有了最终结果,二是TI ...… 查看全部问答> |
|
I.MX5x 系列配合使用Freescale的MC13892做为PMIC 。 此处粘贴的原理图以I.MX51 EVK板为例。 Features 特点? Battery charger system for wall charging and USB charging 电池 ...… 查看全部问答> |
|
我使用的芯片是STM32F103VET6接SD卡读数据,据um中原文是:Data transfer up to 48 MHz for the 8 bit mode.我使cpu工作在72Mhz时(HCLK=72MHz),SDIO分频因子为0,即SD_CK=HCLK/2=36MHz, ...… 查看全部问答> |
|
DSP数据总线和地址总线都连接到FPGA上,FPGA有多个功能模块,需要与DSP进行多路通信,即通过不同的地址映射获得不同的数。请问能否不使用片选信号,只是通过地址译码就完成信号的传输呢,比如EMIFB的CE0上的地址 0x6000 0000映射的是双口写地址,0 ...… 查看全部问答> |




