• 大小: 10KB
    文件类型: .c
    金币: 1
    下载: 0 次
    发布日期: 2021-06-18
  • 语言: 其他
  • 标签: danpianji  

资源简介

51单片机 LCD12864程序显示文字或者图片的代码51单片机 LCD12864程序显示文字或者图片的代码51单片机 LCD12864程序显示文字或者图片的代码51单片机 LCD12864程序显示文字或者图片的代码希望可以给到大家帮助

资源截图

代码片段和文件信息

#include 
#include 
//#include 

sbit LCD_RS=P1^0;//定义引脚
sbit LCD_RW=P1^1;
sbit LCD_E=P1^2;
sbit PSB =P3^6; //PSB脚为12864-12系列的串、并通讯功能切换,我们使用8位并行接口,PSB=1
#define LCD_Data P2




#define Busy    0x80 //用于检测LCD状态字中的Busy标识
void WriteDataLCD(unsigned char WDLCD);
void WriteCommandLCD(unsigned char WCLCDBuysC);
unsigned char ReadDataLCD(void);
unsigned char ReadStatusLCD(void);
void LCDInit(void);
void LCDClear(void);
void LCDFlash(void);
void DisplayOneChar(unsigned char X unsigned char Y unsigned char DData);
void DisplayListChar(unsigned char X unsigned char Y unsigned char code *DData);
void DisplayImage (unsigned char code *DData);
void Delay5Ms(void);
void Delay400Ms(void);

code unsigned char  uctech[] = {“大雄电子营业部“};
code unsigned char  net[] = {“ic2012.taobao.co“};
code unsigned char  mcu[] = {“专业元件供应商!“};
code unsigned char  qq[] = {“  QQ: 571630059 “};
code unsigned char tmp[]={//128*64点阵图形数据
0X000X000X000X000X000X000X000X000X000X000X000X000X000X000X000X00
0X000X000X000X000X000X000X000X000X000X000X000X000X000X000X000X00
0X000X000X000X1E0X000X000X000X000X000X000X000X000X000X000X000X00
0X000X000X000X5F0X800X000X000X000X000X000X000X000X000X000X000X00
0X000X000X000XFF0XC00X000X000X000X000X000X000X000X000X000X000X00
0X000X000X010XFF0XE00X000X000X000X000X000X000X000X000X000X000X00
0X000X010XE10XFF0XE00X800X000X000X000X000X000X000X000X000X000X00
0X000X0F0XF90XFF0XEF0XF00X000X000X000X000X000X000X000X000X000X00
0X000X1F0XFD0XFF0XFF0XF80X000X000X180X000X870X000X180X000X000XC0
0X000X1F0XFE0XFF0XFF0XF80X000X000X180X010X8D0X800X180X010XF70XC0
0X000X3F0XFF0XFF0XFF0XFC0X000X000X180X010X8D0XA00X180X000X030X80
0X000X3F0XFF0XFF0XFF0XFC0X000X000X180X270XFF0XF10XFF0XC00X060X00
0X000X3F0XFF0XFF0XFF0XFC0X000X030XFF0XF10X9D0X010X080XC00X0C0X00
0X000X3F0XFF0XFF0XFF0XFC0X000X000X180X010X7D0X610X180XC00X080X60
0X000X1F0XFF0XFF0XFF0XFC0X000X000X180X010XDF0XE10XFF0XC70XFF0XF0
0X000X1F0XFF0XFF0XFF0XFC0X000X000X1C0X030XED0X010X180XC00X080X00
0X000X1F0XFF0X010XFF0XF80X000X000X160X020X8D0X610X180XC00X080X00
0X000X0F0XFE0X000XFF0XF80X000X000X320X020XAD0X810XFF0XC00X080X00
0X000X070XF80X000X3F0XD00X000X000X230X070X3D0X010X180X200X080X00
0X000XFD0XF80X000X3F0XE00X000X000X610X850XFD0X200X180X200X080X00
0X010XFF0XF00X000X1F0X400X000X000X800XF00X0F0XE00X180X200X780X00
0X030XFF0XF00X000X0F0X800X000X030X000X600X0C0X000X0F0XE00X180X00
0X030XFF0XE00X000X0F0XF00X000X000X000X000X000X000X000X000X000X00
0X070XFF0XE00X000X0F0XF40X000X000X000X000X000X000X000X000X000X00
0X070XFF0XE00X000X0F0XFE0X000X000X000X000X0

评论

共有 条评论