查看: 2725|回复: 5
打印 上一主题 下一主题

【我是新手我怕谁】【MAPS-K64四色板】之四-优化显示函数

[复制链接] qrcode

0

主题

79

帖子

6

积分

新手上路

Rank: 1

积分
6
楼主
发表于 2016-5-26 11:24 AM | 显示全部楼层
本帖最后由 qizc 于 2016-5-26 15:25 编辑

lcdc.c的修改部分
  1. void LCDC_DisplayString(unsigned int x, unsigned int y, unsigned char fontsize, unsigned short backcolor, unsigned short fc,char *string)
  2. {
  3.     while (*string)
  4.     {
  5.         switch(fontsize)
  6.         {
  7.         case 0:
  8.           LCDC_DisplayChar(x, y, fontsize, backcolor,fc, *string++);
  9.           x += 6;
  10.           break;
  11.         case 1:
  12.           LCDC_DisplayChar(x, y, fontsize, backcolor,fc, *string++);
  13.           x += 8;
  14.           break;
  15.         default:
  16.           LCDC_DisplayChar(x, y, fontsize, backcolor,fc, *string++);
  17.           x += 8;
  18.           break;
  19.         }
  20.     }
  21. }
复制代码


回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

快速回复 返回顶部 返回列表