头痛中求大神帮忙解决。
//main.c
void Main(void)
{
static unsigned char strbuf[256] = "万泰电子";
Set_Clk();
MMU_Init();
init_lcd();
get_time();
clear_lcd(0xffffff);
dis_char(10,10,0x0,strbuf);
dis_char(10,60,0x0,systime);
while(1)
{
//dis_char(10,60,0x0,systime);
}}
//LCD_800X480
void dis_char(int x,int y,int color, unsigned char str[])
{
int i;
unsigned char *moudle;
for(i = 0; i < strlen(str);) //这里的strlen编译错误。。。用sizeof可以但结果不对
{
if(str[i]&0x80)
{
moudle = &szHZK16[((str[i]-161)*94+(str[i+1]-161))*32];
draw_16x16(x+8*i,y,color,moudle);
i+=2;
}
else
{
moudle = &szASC16[str[i]*16];
draw_8x16(x+8*i,y,color,moudle);
i++;
}}}
Error : C3028E: <argument 1 to 'strlen'>: implicit cast of pointer to non-equal pointer
我在其他环境中这样用没事啊
F:\LCD屏显示控制\lcd_800X480.c: 0 warnings, 1 error, 0 serious errors
我要赚赏金打赏帖 |
|
|---|---|
| 在K230DBOX上实现多时段语音提示功能被打赏¥14元 | |
| 使K230DBOX实现相机持续拍照功能被打赏¥12元 | |
| 基于K230DBOX的文本管理器设计被打赏¥14元 | |
| 基于K230DBOX的彩色画板功能实现被打赏¥15元 | |
| 在K230DBOX上实现音乐播放器功能被打赏¥15元 | |
| NXP MCU系列开发板MCULink固件升级方法【VSCode】被打赏¥28元 | |
| 三分钟快速搭建NXP MCU开发环境(VSCode)被打赏¥22元 | |
| 为遥控小车巧添功能被打赏¥26元 | |
| 【S32K3XX】FlexCAN 模块配置使用被打赏¥30元 | |
| 【S32K3XX】FlexCAN RAM 资源分配整理被打赏¥25元 | |