主程序在下面:
程序:MCS-51驱动AMPIRE128*64液晶
内容:LCD12864综合显示--汉字,图片、几何图形
编译器:keil uVision3
开发板:Proteus仿真图
- #include<AT89C52.h>
- #include "intrins.h"
- #include "math.h"
- #include "source.h"
- #define uchar unsigned char
- #define uint unsigned int
- #define LCD_databus P0 //LCD12864的8位数据口
- sbit RS=P2^2; //RS为0---命令;1----数据
- sbit RW=P2^1; //RW为1---写;0---读
- sbit EN=P2^0; //使能端
- sbit CS1=P2^4; //片选1低电平有效,控制左半屏
- sbit CS2=P2^3; //片选1低电平有效,控制右半屏
- sbit KEY1=P3^0;
- sbit KEY2=P3^1;
- sbit KEY3=P3^2; //三个按键控制口
- void delay(uint i)
- {
- while(--i);
- }
- void Read_busy()//读“忙”函数-----数据线的最高位DB71则busy
- {
- P0=0x00;
- RS=0;
- RW=1;
- EN=1;
- while(P0 & 0x80);
- EN=0;
- }
- void write_LCD_command(uchar value) //写命令函数
- {
- Read_busy(); //对LCD的每次读写都要读忙
- RS=0; //选择命令
- RW=0; //读操作
- LCD_databus=value;
- EN=1; //EN由1----0锁存有效数据
- _nop_();
- _nop_();
- EN=0;
- }
- void write_LCD_data(uchar value)//写数据函数
- {
- Read_busy();
- RS=1; //选择数据
- RW=0;
- LCD_databus=value;
- EN=1; //EN由1----0锁存有效数据
- _nop_();
- _nop_();
- EN=0;
- }
- uchar Read_LCD(void) //读数据函数
- {
- uchar value;
- Read_busy();
- LCD_databus=0xFF; //先进行一次空读操作
- RS=1;
- RW=1;
- EN=1;
- _nop_();
- _nop_();
- EN=0;
-
- LCD_databus=0xFF; //读取真正的数据
- RS=1;
- RW=1;
- EN=1;
- value=LCD_databus;
- _nop_();
- _nop_();
- EN=0;
-
- return value;
- }
- void Set_page(uchar page) //设置“页”LCD12864共8页,一页是8行点阵点
- {
- page=0xb8|page; //页的首地址为0xB8
- write_LCD_command(page);
- }
- void Set_line(uchar startline) //设置显示的起始行
- {
- startline=0xC0|startline; //起始行地址为0xC0
- write_LCD_command(startline); //设置从哪行开始:共0--63;一般从0 行开始显示
- }
- void Set_column(uchar column) //设置显示的列
- {
- column=column &0x3f; //列的最大值为64
- column= 0x40|column; //列的首地址为0x40
- write_LCD_command(column); //规定显示的列的位置
- }
- void SetOnOff(uchar onoff) //显示开关函数:0x3E是关显示,0x3F是开显示
- {
- onoff=0x3e|onoff; //onoff:1---开显示;0---关显示
- write_LCD_command(onoff);
- }
- void SelectScreen(uchar screen) //选择屏幕
- {
- switch(screen)
- {
- case 0: CS1=0;CS2=0;break; //全屏
- case 1: CS1=0;CS2=1;break;//左半屏
- case 2: CS1=1;CS2=0;break;//右半屏
- default:break;
- }
- }
- void ClearScreen(uchar screen) //清屏函数
- {
- uchar i,j;
- SelectScreen(screen); //0--全屏;1---左半屏;2---右半屏
- for(i=0;i<8;i++) //控制页数0-7,共8页
- {
- Set_page(i);
- Set_column(0);
- for(j=0;j<64;j++) //控制列数0-63,共64列
- {
- write_LCD_data(0x00); //写入0,地址指针自加1
- }
- }
- }
- void init_LCD() //LCD的初始化
- {
- SetOnOff(1); //开显示
- SelectScreen(0);
- ClearScreen(0); //清屏
- Set_line(0); //开始行:0
- }
- void Draw_dots(uchar x,uchar y,uchar color)
- {
- uchar x_byte;
- uchar x_bit;
- uchar Temp_data; //暂时存放从LCD读出的数据
- x_byte=(y>>3); //计算出该点属于哪个字节
- x_bit=y-(x_byte<<3); //属于字节的哪一位
-
- if(x>63) //x>63则显示在右半屏
- {
- SelectScreen(2);
- x=x-64;
- }
- else //显示在左半屏
- {
- SelectScreen(1);
- }
- Set_page(x_byte); //设置行地址
- Set_column(x); //设置列地址
- Temp_data=Read_LCD(); //先读出没打点前LCD中的数据
- switch(color)
- {
- case 0x01 : Temp_data &= ~(1<<x_bit);break; //擦除
- case 0x02 : Temp_data ^= (1<<x_bit); break; //反白
- case 0x03 : Temp_data |= (1<<x_bit); break; //画点
- default : break;
- }
-
- Set_page(x_byte);
- Set_column(x);
- write_LCD_data(Temp_data); //将处理后的数据送到LCD中显示
-
- }
- /**********************************
- 两点间画直线:
- x1<x2<127,y1<y2<64
- ***********************************/
- void Draw_line(unsigned char x1,y1,x2,y2)
- {
- unsigned char i;
- for(i=x1;i<x2+1;i++)
- Draw_dots(i,(y2-y1)*(i-x1)/(x2-x1)+y1,2);
- }
- /**********************************
- 画圆:
- (x,y)为圆心,r为半径
- ***********************************/
- void Draw_circle(unsigned char x,y,r)
- {
- unsigned char i;
- for(i=x-r;i<x+r+1;i++)
- {
- Draw_dots(i,y-sqrt(r*r-(x-i)*(x-i)),2);
- Draw_dots(i,y+sqrt(r*r-(x-i)*(x-i)),2);
- }
- }
- /**********************************
- 两矩形:
- (x1,y1)为矩形左上角坐标点
- (x2,y2)为矩形右上角坐标点
- ***********************************/
- void Draw_retic(uchar x1,uchar y1,uchar x2,uchar y2)//画正方形,x1,y1为左上角坐标,x2,y2为右下角坐标
- {
- uchar i;
- for(i=0;i<=x2-x1;i++)
- {
- Draw_dots(x1+i,y1,2);
- Draw_dots(x1+i,y2,2);
- }
- for(i=0;i<=y2-y1;i++)
- {
- Draw_dots(x1,y1+i,2);
- Draw_dots(x2,y1+i,2);
- }
- }
- void Display_ASCII(uchar screen,uchar page,uchar column,uchar *p)
- {
- uchar i;
- SelectScreen(screen);
- Set_page(page);
- Set_column(column);
- for(i=0;i<8;i++) //显示字符上半部分:8*8
- {
- write_LCD_data(p[i]);
- }
- Set_page(page+1); //显示字符下半部分:8*8
- Set_column(column);
- for(i=0;i<8;i++)
- {
- write_LCD_data(p[i+8]);
- }
- }
- void Display_HZ(uchar screen,uchar page,uchar column,uchar *p)
- {
- uchar i;
- SelectScreen(screen);
- Set_page(page); //写上半页:16*8
- Set_column(column*16); //控制列
- for(i=0;i<16;i++) //控制16列的数据输出
- {
- write_LCD_data(p[i]); //汉字的上半部分
- }
- Set_page(page+1); //写下半页:16*8
- Set_column(column*16); //控制列
- for(i=0;i<16;i++) //控制16列的数据输出
- {
- write_LCD_data(p[i+16]); //汉字的下半部分
- }
- }
- void Display_picture(uchar a[][64])//显示图形—128*64大小
- {
- uchar i,j;
-
- for(j=0;j<8;j++)
- {
- SelectScreen(1);
- Set_page(j);
- Set_column(0);
- for(i=0;i<64;i++)
- {
- write_LCD_data(a[2*j][i]);//每隔一行取一次数组中的数据
- }
- SelectScreen(2);
- Set_page(j);
- Set_column(0);
- for(i=0;i<64;i++)
- {
- write_LCD_data(a[2*j+1][i]);//每隔一行取一次数组中的数据
- }
- }
- }
- void key_scan(void)
- {
- uchar i;
- if(KEY1==0) //按键1按下,显示汉字
- {
- delay(5000);
- if(KEY1==0)
- {
- while(!KEY1);
- ClearScreen(0);
- for(i=8;i>0;i--) //滚屏
- {
- Display_HZ(1,0+i,2,huan);
- Display_HZ(1,0+i,3,ying);
- Display_HZ(2,0+i,0,fang);
- Display_HZ(2,0+i,1,wen);
- Display_HZ(1,2+i,0,da);
- Display_HZ(1,2+i,1,hai);
- Display_HZ(1,2+i,2,xiang);
- Display_HZ(1,2+i,3,shu);
- Display_HZ(2,2+i,0,bai);
- Display_HZ(2,2+i,1,du);
- Display_HZ(2,2+i,2,kong);
- Display_HZ(2,2+i,3,jian);
- delay(30000);
- ClearScreen(0);
- }
- Display_HZ(1,0+i,2,huan);
- Display_HZ(1,0+i,3,ying);
- Display_HZ(2,0+i,0,fang);
- Display_HZ(2,0+i,1,wen);
- Display_HZ(1,2+i,0,da);
- Display_HZ(1,2+i,1,hai);
- Display_HZ(1,2+i,2,xiang);
- Display_HZ(1,2+i,3,shu);
- Display_HZ(2,2+i,0,bai);
- Display_HZ(2,2+i,1,du);
- Display_HZ(2,2+i,2,kong);
- Display_HZ(2,2+i,3,jian);
- }
- }
- if(KEY2==0) //按键2按下,显示图片---大海橡树
- {
- delay(5000);
- if(KEY2==0)
- {
- while(!KEY2);
- ClearScreen(0);
- Display_picture(BMP);
- }
- }
- if(KEY3==0) //按键3按下,显示几何图形
- {
- delay(5000);
- if(KEY3==0)
- {
- while(!KEY3);
- ClearScreen(0);
- Display_HZ(1,0,2,zhi);
- Display_HZ(1,0,3,xian);
-
- Display_HZ(2,2,1,ju);
- Display_HZ(2,2,2,xing);
-
- Display_HZ(1,4,1,yuan);
-
- Draw_line(0,0,127,63);
- Draw_retic(70,0,120,33);
- Draw_circle(30,40,20);
- }
- }
- }
- void main()
- {
- init_LCD(); //初始12864
- ClearScreen(0); //清屏
- Set_line(0); //显示开始行
- Display_HZ(1,2,1,qing);
- Display_HZ(1,2,2,an);
- Display_HZ(1,2,3,button);
- Display_HZ(2,2,0,xuan);
- Display_HZ(2,2,1,ze);
- Display_HZ(2,2,2,andsoon); //上电显示:“请按键选择…”
- while(1)
- {
-
- key_scan();
- }
- }
- source.h的代码如下:
- #ifndef _SOURCE_H_
- #define _SOURCE_H_
- unsigned char code BMP[][64]={/*-- 调入了一幅图像:G:\51 MCU\LCD12864\程序\大海橡树.BMP --*/
- /*-- 宽度x高度=128x64 --*/
- 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0xF0,0xE0,0xC0,
- 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
- 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
- 0xF0,0xF0,0x60,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
- 0x00,0x00,0x00,0x00,0x00,0x00,0x40,0xC0,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
- 0x80,0xF0,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
- 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xC0,0xC0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
- 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0xE0,0xC0,0x00,0x00,0x00,0x00,0x00,0x00,
- 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFF,0xFF,0x00,
- 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
- 0x00,0x00,0x00,0x00,0x00,0x00,0x1C,0x7C,0xF8,0xE0,0x00,0x00,0x00,0x00,0xE0,0xFE,
- 0x5F,0x67,0x60,0x70,0x70,0x38,0x38,0x1C,0x1C,0x08,0x00,0x00,0x00,0x00,0x00,0x00,
- 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFF,0xFF,0x00,0x00,0x00,0x00,0xC0,0x70,0x1C,
- 0x0F,0x07,0x06,0xF6,0x3F,0x1F,0x07,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
- 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFF,0xFF,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
- 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFF,0xFF,0x00,0x00,0x00,0x00,0x00,0x00,
- 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFF,0xFF,0x00,
- 0x80,0x80,0xC0,0xC0,0xC0,0xE0,0xE0,0xE0,0xC0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
- 0x00,0x00,0x40,0xC0,0x80,0x00,0x00,0x00,0x01,0x01,0x00,0x60,0x38,0x0F,0x83,0x80,
- 0x80,0xC0,0xC0,0xC0,0xE0,0x70,0xF0,0xE0,0xC0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
- 0x00,0x00,0x00,0x80,0x80,0xC0,0xC0,0xFF,0x6F,0x70,0x30,0x00,0x0C,0xFC,0x0C,0x04,
- 0x06,0xE6,0xFF,0x22,0x03,0x03,0xE3,0xFF,0x1F,0x0E,0x00,0x00,0x00,0x00,0x00,0x00,
- 0x00,0x00,0x00,0x00,0x00,0x00,0x80,0xFF,0xFF,0xC0,0xC0,0xC0,0x30,0x38,0x18,0x1C,
- 0x0E,0xFF,0xFE,0x08,0x80,0x80,0x80,0xC0,0xFF,0xFF,0xE0,0xF0,0xF0,0x70,0x60,0x00,
- 0x00,0x00,0x00,0x00,0x00,0x18,0x38,0x38,0x3C,0x1C,0x1C,0x0E,0x0E,0xFF,0xFF,0x07,
- 0x03,0x03,0x03,0x03,0x01,0x01,0x01,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
- 0x00,0x00,0x00,0x03,0x0F,0x1F,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0xFF,0x01,
- 0x01,0x1C,0x78,0x00,0x00,0x00,0x01,0xFF,0x9F,0x80,0x80,0x80,0x80,0x80,0x00,0x00,
- 0x00,0x00,0x01,0x01,0x01,0x81,0xF8,0xFF,0x20,0x60,0xE0,0x80,0x00,0x03,0xCE,0xF6,
- 0xBE,0x0F,0x03,0x03,0x03,0x03,0x07,0xF0,0xE0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
- 0x00,0x00,0x02,0x06,0x07,0x07,0xE3,0xFF,0xFF,0x81,0x00,0x00,0x04,0x18,0xF0,0xC0,
- 0xFF,0x3F,0x00,0x61,0xC3,0x03,0x01,0x01,0xFF,0xFF,0x00,0x00,0x00,0x00,0x00,0x00,
- 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0xFE,0x7F,0x07,0x3E,
- 0xF0,0xC0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
- 0x00,0x00,0x00,0x00,0x00,0x00,0xE0,0x3F,0x10,0x30,0x38,0x18,0xD8,0xFF,0x0D,0x0C,
- 0x2C,0xC6,0x86,0x06,0x07,0x03,0xFF,0xFF,0x03,0x03,0x03,0x03,0x03,0x03,0x03,0x00,
- 0x00,0x00,0x00,0xC0,0xFC,0x1F,0x01,0xFF,0x00,0x00,0x01,0x00,0x04,0xC3,0x71,0x1E,
- 0x07,0xDE,0xF8,0xE0,0xF8,0x9C,0x0F,0x03,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
- 0x00,0x00,0x00,0x80,0xF8,0x1F,0x03,0xFF,0x3F,0x03,0x0F,0x1E,0x00,0x00,0xF1,0x3F,
- 0x7F,0xF8,0xC0,0x00,0x07,0x1F,0x00,0x00,0xFF,0xFF,0x00,0x00,0x00,0x00,0x00,0x00,
- 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0xE0,0x78,0x1F,0x07,0x00,0x00,0x00,
- 0x00,0x07,0x3F,0xF8,0xF0,0xC0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
- 0x00,0x00,0x00,0x80,0xF0,0xFE,0x0F,0x00,0x00,0x00,0xC0,0xF8,0xFF,0xE0,0xE0,0xE0,
- 0xE0,0xE7,0xE7,0xE0,0xE0,0xE0,0xFF,0xFF,0xE0,0xC0,0xC0,0x00,0x00,0x00,0x00,0x00,
- 0x00,0x38,0x0E,0x03,0x00,0x00,0x00,0xFF,0x00,0x00,0x00,0x04,0x03,0x81,0xE0,0x38,
- 0x0F,0x03,0x03,0xFF,0x00,0x03,0x07,0x1E,0x7C,0xF8,0xF0,0xF0,0xE0,0xC0,0xC0,0x00,
- 0x00,0x30,0x0E,0x03,0x00,0x00,0x00,0xFF,0x00,0x00,0x00,0xC0,0x38,0x0F,0x03,0x00,
- 0x00,0x07,0x3F,0x00,0x00,0x00,0x00,0x00,0xFF,0xFF,0x00,0x00,0x00,0x00,0x00,0x00,
- 0x00,0x00,0x00,0x00,0x60,0x30,0x18,0x0E,0x07,0x01,0x00,0x00,0x00,0x00,0x00,0x00,
- 0x00,0x00,0x00,0x01,0x0F,0x3F,0xFF,0xFE,0xFC,0xF8,0xF0,0xF0,0xE0,0x60,0x40,0x00,
- 0x00,0x00,0x06,0x3F,0x7F,0x03,0x00,0x00,0x00,0x00,0x03,0x03,0x01,0x00,0x00,0x00,
- 0x00,0xC0,0x80,0x80,0x80,0xFE,0x7F,0x00,0x01,0x01,0x03,0x03,0x00,0x00,0x00,0x00,
- 0x00,0x00,0x00,0x00,0x00,0x00,0x78,0xFF,0x00,0x00,0x08,0x04,0x03,0x01,0x00,0x60,
- 0xC0,0xC0,0xF0,0xFF,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x01,0x00,0x00,0x00,0x00,
- 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFF,0x00,0x00,0x03,0x00,0x00,0x00,0x00,0x00,
- 0x00,0x00,0x00,0x00,0x00,0x30,0x70,0xE0,0xFF,0xFF,0x00,0x00,0x00,0x00,0x00,0x00,
- 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
- 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
- 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
- 0x00,0x00,0x03,0x3F,0x3F,0x0F,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
- 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
- 0x00,0x07,0x0F,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
- 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x07,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
- 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1F,0x0F,0x03,0x00,0x00,0x00,0x00,0x00,0x00
- };
- unsigned char code huan[]={/*-- 文字: 欢 --*/
- /*-- 楷体_GB231212; 此字体下对应的点阵为:宽x高=16x16 --*/
- 0x00,0xA0,0x20,0x10,0xF0,0x00,0x40,0x38,0xA7,0x10,0x50,0x30,0x10,0x00,0x00,0x00,
- 0x10,0x08,0x05,0x02,0x05,0x20,0x10,0x0C,0x03,0x04,0x08,0x10,0x30,0x20,0x20,0x00};
- unsigned char code ying[]={/*-- 文字: 迎 --*/
- /*-- 楷体_GB231212; 此字体下对应的点阵为:宽x高=16x16 --*/
- 0x40,0x40,0x44,0xC8,0x00,0xF8,0x08,0x84,0x06,0xF0,0x08,0x88,0xF8,0x00,0x00,0x00,
- 0x08,0x08,0x09,0x0E,0x08,0x09,0x09,0x08,0x10,0x17,0x10,0x30,0x30,0x10,0x10,0x00};
- unsigned char code fang[]={/*-- 文字: 访 --*/
- /*-- 楷体_GB231212; 此字体下对应的点阵为:宽x高=16x16 --*/
- 0x40,0x40,0x20,0xE2,0x04,0x00,0x20,0x20,0x22,0xE2,0x94,0x90,0x10,0x10,0x10,0x00,
- 0x00,0x00,0x00,0x0F,0x14,0x0A,0x04,0x02,0x11,0x20,0x18,0x07,0x00,0x00,0x00,0x00};
- unsigned char code wen[]={/*-- 文字: 问 --*/
- /*-- 楷体_GB231212; 此字体下对应的点阵为:宽x高=16x16 --*/
- 0x00,0x00,0xF8,0x02,0x04,0xC0,0x44,0x24,0x24,0xE2,0x02,0x02,0xFE,0x00,0x00,0x00,
- 0x00,0x00,0x1F,0x00,0x00,0x01,0x01,0x01,0x01,0x00,0x00,0x10,0x3F,0x00,0x00,0x00};
- unsigned char code da[]={/*-- 文字: 大 --*/
- /*-- 楷体_GB231212; 此字体下对应的点阵为:宽x高=16x16 --*/
- 0x00,0x00,0x40,0x40,0x40,0x40,0xFF,0x20,0x20,0x20,0x20,0x20,0x00,0x00,0x00,0x00,
- 0x00,0x20,0x10,0x08,0x04,0x03,0x00,0x01,0x02,0x04,0x08,0x10,0x30,0x20,0x20,0x00};
- unsigned char code hai[]={/*-- 文字: 海 --*/
- /*-- 楷体_GB231212; 此字体下对应的点阵为:宽x高=16x16 --*/
- 0x00,0x20,0x44,0x08,0x00,0x10,0xE8,0x2F,0xE8,0xA4,0x94,0xF4,0x80,0x80,0x80,0x00,
- 0x00,0x18,0x06,0x01,0x01,0x0D,0x0B,0x09,0x2B,0x48,0x38,0x0F,0x08,0x08,0x00,0x00};
- unsigned char code xiang[]={/*-- 文字: 橡 --*/
- /*-- 楷体_GB231212; 此字体下对应的点阵为:宽x高=16x16 --*/
- 0x00,0x20,0xA0,0xFE,0x90,0x00,0xB0,0x54,0xBB,0x2A,0x2E,0x98,0x00,0x00,0x00,0x00,
- 0x04,0x03,0x00,0x3F,0x00,0x15,0x0A,0x25,0x43,0x3E,0x03,0x04,0x0C,0x08,0x08,0x00};
- unsigned char code shu[]={/*-- 文字: 树 --*/
- /*-- 楷体_GB231212; 此字体下对应的点阵为:宽x高=16x16 --*/
- 0x40,0x40,0x40,0xFE,0x20,0x00,0x50,0x88,0x78,0x80,0x20,0x20,0xFE,0x10,0x10,0x00,
- 0x04,0x02,0x01,0x3F,0x09,0x04,0x02,0x01,0x02,0x04,0x01,0x20,0x7F,0x00,0x00,0x00};
- unsigned char code bai[]={/*-- 文字: 百 --*/
- /*-- 楷体_GB231212; 此字体下对应的点阵为:宽x高=16x16 --*/
- 0x00,0x08,0x08,0x08,0x88,0x48,0x78,0x44,0x44,0x44,0xC4,0x04,0x04,0x04,0x00,0x00,
- 0x00,0x00,0x00,0x00,0x1F,0x0A,0x0A,0x09,0x09,0x08,0x3F,0x00,0x00,0x00,0x00,0x00};
- unsigned char code du[]={/*-- 文字: 度 --*/
- /*-- 楷体_GB231212; 此字体下对应的点阵为:宽x高=16x16 --*/
- 0x00,0x00,0x00,0xF8,0x08,0x28,0xF8,0xA9,0xA6,0x7C,0x14,0x14,0x00,0x00,0x00,0x00,
- 0x20,0x18,0x06,0x21,0x20,0x22,0x16,0x0A,0x09,0x17,0x30,0x20,0x20,0x20,0x20,0x00};
- unsigned char code kong[]={/*-- 文字: 空 --*/
- /*-- 楷体_GB231212; 此字体下对应的点阵为:宽x高=16x16 --*/
- 0x00,0x20,0x18,0x08,0x88,0x68,0x09,0x0A,0x08,0x24,0x44,0x04,0x14,0x08,0x00,0x00,
- 0x00,0x20,0x20,0x21,0x20,0x22,0x22,0x1E,0x11,0x11,0x11,0x10,0x30,0x20,0x00,0x00};
- unsigned char code jian[]={/*-- 文字: 间 --*/
- /*-- 楷体_GB231212; 此字体下对应的点阵为:宽x高=16x16 --*/
- 0x00,0x00,0xF8,0x02,0x04,0xE0,0xA4,0x14,0xF4,0x02,0x02,0x02,0xFE,0x00,0x00,0x00,
- 0x00,0x00,0x1F,0x00,0x00,0x07,0x02,0x02,0x07,0x00,0x10,0x20,0x1F,0x00,0x00,0x00};
- unsigned char code yuan[]={/*-- 文字: 圆 --*/
- /*-- 宋体12; 此字体下对应的点阵为:宽x高=16x16 --*/
- 0x00,0xFF,0x01,0x01,0xDD,0x55,0x55,0x55,0x55,0x55,0xDD,0x01,0x01,0xFF,0x00,0x00,
- 0x00,0xFF,0x40,0x40,0x67,0x50,0x48,0x47,0x48,0x50,0x67,0x40,0x40,0xFF,0x00,0x00};
- unsigned char code ju[]={/*-- 文字: 矩 --*/
- /*-- 宋体12; 此字体下对应的点阵为:宽x高=16x16 --*/
- 0xA0,0x90,0x8F,0xF8,0x88,0x88,0x88,0x00,0xFE,0x22,0x22,0x22,0x22,0xE2,0x02,0x00,
- 0x40,0x20,0x18,0x07,0x02,0x04,0x18,0x00,0x7F,0x42,0x42,0x42,0x42,0x47,0x40,0x00};
- unsigned char code xing[]={/*-- 文字: 形 --*/
- /*-- 宋体12; 此字体下对应的点阵为:宽x高=16x16 --*/
- 0x40,0x42,0x42,0xFE,0x42,0x42,0xFE,0x42,0x42,0x40,0x10,0x88,0xE4,0x47,0x02,0x00,
- 0x80,0x40,0x30,0x0F,0x00,0x00,0x7F,0x00,0x84,0x42,0x21,0x10,0x08,0x0E,0x04,0x00};
- unsigned char code zhi[]={/*-- 文字: 直 --*/
- /*-- 宋体12; 此字体下对应的点阵为:宽x高=16x16 --*/
- 0x00,0x04,0x04,0xF4,0x94,0x94,0x9C,0x97,0x94,0x94,0x94,0xF4,0x04,0x04,0x00,0x00,
- 0x40,0x40,0x40,0x7F,0x4A,0x4A,0x4A,0x4A,0x4A,0x4A,0x4A,0x7F,0x40,0x40,0x40,0x00};
- unsigned char code xian[]={/*-- 文字: 线 --*/
- /*-- 宋体12; 此字体下对应的点阵为:宽x高=16x16 --*/
- 0x40,0x60,0x58,0xC7,0x62,0x00,0x90,0x90,0x90,0xFF,0x90,0x92,0x9C,0x94,0x80,0x00,
- 0x20,0x22,0x23,0x12,0x12,0x12,0x20,0x20,0x10,0x13,0x0C,0x14,0x22,0x40,0xF8,0x00};
- unsigned char code qing[]={/*-- 文字: 请 --*/
- /*-- 楷体_GB231212; 此字体下对应的点阵为:宽x高=16x16 --*/
- 0x40,0x40,0x20,0xE2,0x04,0x40,0x40,0x54,0xD4,0xBF,0xAA,0xAA,0x20,0x20,0x20,0x00,
- 0x00,0x00,0x18,0x0F,0x04,0x02,0x00,0x3F,0x0A,0x0A,0x20,0x7F,0x00,0x00,0x00,0x00};
- unsigned char code an[]={/*-- 文字: 按 --*/
- /*-- 楷体_GB231212; 此字体下对应的点阵为:宽x高=16x16 --*/
- 0x00,0x20,0x20,0xFF,0x90,0x00,0x60,0x20,0x20,0xD2,0x14,0x10,0x50,0x30,0x00,0x00,
- 0x02,0x02,0x11,0x3F,0x00,0x22,0x22,0x12,0x17,0x09,0x0D,0x13,0x21,0x21,0x01,0x00};
- unsigned char code button[]={/*-- 文字: 键 --*/
- /*-- 楷体_GB231212; 此字体下对应的点阵为:宽x高=16x16 --*/
- 0x80,0x40,0x70,0xCE,0x48,0x18,0xF0,0x00,0xA8,0xA8,0xFF,0x54,0x7C,0x10,0x10,0x00,
- 0x00,0x02,0x02,0x1F,0x29,0x14,0x0D,0x0B,0x14,0x15,0x1F,0x25,0x24,0x20,0x20,0x00};
- unsigned char code xuan[]={/*-- 文字: 选 --*/
- /*-- 楷体_GB231212; 此字体下对应的点阵为:宽x高=16x16 --*/
- 0x80,0x80,0x44,0xC8,0x00,0xA0,0x98,0x90,0x7F,0xC8,0x48,0x48,0x40,0x00,0x00,0x00,
- 0x10,0x10,0x0F,0x08,0x08,0x14,0x12,0x11,0x10,0x27,0x28,0x28,0x28,0x26,0x20,0x00};
- unsigned char code ze[]={/*-- 文字: 择 --*/
- /*-- 楷体_GB231212; 此字体下对应的点阵为:宽x高=16x16 --*/
- 0x00,0x20,0x20,0xFF,0x50,0x90,0x40,0x2C,0x14,0xD2,0xAA,0xA6,0x40,0x40,0x40,0x00,
- 0x02,0x02,0x09,0x1F,0x00,0x04,0x04,0x05,0x05,0x3F,0x02,0x02,0x02,0x02,0x00,0x00};
- unsigned char code andsoon[]={/*-- 文字: … --*/
- /*-- 楷体_GB231212; 此字体下对应的点阵为:宽x高=16x16 --*/
- 0x00,0x00,0x80,0x80,0x00,0x00,0x00,0x80,0x80,0x00,0x00,0x00,0x80,0x80,0x00,0x00,
- 0x00,0x00,0x01,0x01,0x00,0x00,0x00,0x01,0x01,0x00,0x00,0x00,0x01,0x01,0x00,0x00};
- #endif
复制代码
|