|
发表于 2020-11-30 20:56:19
|
显示全部楼层
void lcd_putnum (int x, int y,const char *str)
//void lcd_putnum (int x, int y,char *str)
{
char c;
int i;
char str2 = str; // error: #144: a value of type "const char *" cannot be used to initialize an entity of type "char"
lcd_gotoxy(x,y);
while( (c = (str2++)) )
{
for(i=0; i<6; i++)
{
if(c>=0x30 && c<= 0x39){
lcd_write(DATA, digits[(c-0x030)*12+i]);
}else{
lcd_write(DATA,0);
}
}
lcd_write(DATA,0);
}
str2 = str; //..\User\n1110.c(142): error: #513: a value of type "const char *" cannot be assigned to an entity of type "char"
lcd_gotoxy(x,y+1);
while( ... ...
这个是n1110屏的文件,实际买到的是图像反转的1202屏幕
|
|