《无字库12864液晶屏滚动显示程序》由会员分享,可在线阅读,更多相关《无字库12864液晶屏滚动显示程序(11页珍藏版)》请在金锄头文库上搜索。
1、无字库12864液晶屏滚动显示程序转#include#include#include#define Lcd_Bus P0 /MCU P0 LCM#define Disp_On 0x3f/开显示#define Disp_Off 0x3e/关显示#define Col_Add 0x40/列地址#define Page_Add 0xb8/页地址#define Start_Line 0xc0/起始页sbit cs1=P23; /Master chip enablesbit cs2=P24; /Slave chip enablesbit Enable=P22; / mode Enable singles
2、bit Di=P20; /Data or Instrument Selectsbit RW=P21; /Write or Readsbit Lcd_Rst=P25; /Lcm reset/*字模,此字体下对应的点阵为:宽x高=16x16*/unsigned char code Chinese_character32=0x02,0xF2,0x12,0x12,0x12,0xFE,0x12,0x12,0x12,0xFE,0x12,0x12,0x12,0xF2,0x02,0x00 , 0x00,0x7F,0x28,0x24,0x22,0x21,0x20,0x20,0x20,0x21,0x22,0x22
3、,0x22,0x7F,0x00,0x00,/*西,0*/0x80,0x90,0x8C,0x84,0x84,0xF4,0xA5,0x86,0x84,0x84,0x84,0x84,0x94,0x8C,0x84,0x00, 0x80,0x80,0x80,0x40,0x47,0x28,0x28,0x10,0x28,0x24,0x43,0xC0,0x40,0x00,0x00,0x00,/*安,1*/0x00,0x42,0x62,0x5A,0xC6,0x10,0x54,0x54,0x54,0xFF,0x54,0x54,0x7C,0x10,0x10,0x00, 0x40,0x23,0x14,0x08,0x1
4、7,0x28,0x29,0x49,0x49,0x7F,0x49,0x49,0x49,0x49,0x40,0x00,/*建,2*/0x10,0x48,0x47,0xCC,0x54,0x44,0x14,0xE8,0x27,0x24,0x2C,0xF4,0x04,0x04,0x04,0x00, 0x10,0x30,0x10,0x0F,0x88,0x48,0x30,0x0F,0x01,0x06,0x00,0x3F,0x40,0x40,0x70,0x00,/*筑,3*/0x10,0x12,0x92,0x72,0xFE,0x51,0x91,0x00,0x22,0xCC,0x00,0x00,0xFF,0x0
5、0,0x00,0x00, 0x04,0x02,0x01,0x00,0xFF,0x00,0x04,0x04,0x04,0x02,0x02,0x02,0xFF,0x01,0x01,0x00,/*科,4*/0x08,0x08,0x88,0xFF,0x48,0x28,0x00,0xC8,0x48,0x48,0x7F,0x48,0xC8,0x48,0x08,0x00, 0x01,0x41,0x80,0x7F,0x00,0x40,0x40,0x20,0x13,0x0C,0x0C,0x12,0x21,0x60,0x20,0x00,/*技,5*/0x20,0x20,0x20,0x20,0x20,0x20,0x
6、A0,0x7F,0xA0,0x20,0x20,0x20,0x20,0x20,0x20,0x00, 0x00,0x80,0x40,0x20,0x10,0x0C,0x03,0x00,0x01,0x06,0x08,0x30,0x60,0xC0,0x40,0x00,/*大,6*/0x40,0x30,0x10,0x12,0x5C,0x54,0x50,0x51,0x5E,0xD4,0x50,0x18,0x57,0x32,0x10,0x00, 0x00,0x02,0x02,0x02,0x02,0x02,0x42,0x82,0x7F,0x02,0x02,0x02,0x02,0x02,0x02,0x00,/*学
7、,4*/0x00,0x02,0x1C,0xE8,0x00,0x40,0x60,0x58,0x47,0x22,0x20,0x28,0x30,0xE0,0x40,0x00, 0x02,0x02,0x7F,0x00,0x00,0x00,0x7F,0x21,0x21,0x21,0x21,0x21,0x7F,0x00,0x00,0x00,/*冶,0*/0x40,0x40,0x20,0x20,0x50,0x48,0x44,0xC3,0x44,0x48,0x50,0x50,0x20,0x60,0x20,0x00, 0x40,0x40,0x42,0x42,0x4A,0x72,0x42,0x7F,0x42,0x
8、62,0x5A,0x42,0x42,0x40,0x40,0x00,/*金,1*/0x00,0x00,0x02,0x02,0x02,0x02,0x02,0xFE,0x02,0x02,0x02,0x02,0x02,0x02,0x00,0x00, 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x3F,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x00,/*工,2*/0x10,0x12,0xD2,0xFE,0x91,0x11,0x80,0xBF,0xA1,0xA1,0xA1,0xA1,0xBF,0x80,0x00,0x00, 0x04,0x03,0
9、x00,0xFF,0x00,0x41,0x44,0x44,0x44,0x7F,0x44,0x44,0x44,0x44,0x40,0x00,/*程,3*/0x40,0x30,0x10,0x12,0x5C,0x54,0x50,0x51,0x5E,0xD4,0x50,0x18,0x57,0x32,0x10,0x00, 0x00,0x02,0x02,0x02,0x02,0x02,0x42,0x82,0x7F,0x02,0x02,0x02,0x02,0x02,0x02,0x00,/*学,4*/0xFE,0x02,0x32,0x4A,0x86,0x0C,0x24,0x24,0x25,0x26,0x24,0
10、x24,0x24,0x0C,0x04,0x00, 0xFF,0x00,0x02,0x04,0x83,0x41,0x31,0x0F,0x01,0x01,0x7F,0x81,0x81,0x81,0xF1,0x00,/*院,5*/0x10,0x10,0xD0,0xFE,0x50,0x90,0x00,0x10,0x10,0x10,0xD0,0xFE,0x10,0x10,0x10,0x00, 0x08,0x06,0x01,0xFF,0x00,0x01,0x10,0x08,0x04,0x43,0x80,0x7F,0x00,0x00,0x00,0x00,/*材,0*/0x20,0x24,0xA8,0x70,
11、0xFF,0x68,0xA4,0x20,0x42,0x8C,0x00,0x00,0xFF,0x00,0x00,0x00, 0x08,0x06,0x01,0x00,0xFF,0x00,0x01,0x02,0x02,0x03,0x02,0x02,0xFF,0x01,0x01,0x00,/*料,1*/ 0x00,0x08,0x08,0x08,0xFF,0x08,0x08,0xF8,0x00,0xF8,0x08,0x08,0x08,0xF8,0x00,0x00, 0x40,0x20,0x18,0x07,0x00,0x20,0x40,0x3F,0x00,0x7F,0x10,0x10,0x10,0x3F,
12、0x00,0x00,/*加,2*/0x00,0x00,0x02,0x02,0x02,0x02,0x02,0xFE,0x02,0x02,0x02,0x02,0x02,0x02,0x00,0x00, 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x3F,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x00,/*工,4*/0x00,0x00,0x02,0x02,0x02,0x02,0x02,0xFE,0x02,0x02,0x02,0x02,0x02,0x02,0x00,0x00, 0x20,0x20,0x20,0x20,0x20,0x20,0x20
13、,0x3F,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x00,/*工,4*/0x10,0x12,0xD2,0xFE,0x91,0x11,0x80,0xBF,0xA1,0xA1,0xA1,0xA1,0xBF,0x80,0x00,0x00, 0x04,0x03,0x00,0xFF,0x00,0x41,0x44,0x44,0x44,0x7F,0x44,0x44,0x44,0x44,0x40,0x00,/*程,5*/;unsigned char code E16=0xC0,0x30,0x08,0x08,0x08,0x08,0x38,0x00,0x07,0x18,0x20,
14、0x20,0x20,0x10,0x08,0x00,/*C,0*/0x80,0x80,0x80,0x00,0x80,0x80,0x80,0x00,0x20,0x20,0x3F,0x21,0x20,0x00,0x01,0x00,/*r,1*/0x00,0x00,0x80,0x80,0x80,0x80,0x00,0x00,0x00,0x19,0x24,0x22,0x22,0x22,0x3F,0x20,/*a,2*/0x00,0x00,0x80,0x80,0x80,0x80,0x80,0x00,0x00,0x33,0x24,0x24,0x24,0x24,0x19,0x00,/*s,3*/0x80,0x
15、80,0x80,0x00,0x00,0x80,0x80,0x80,0x80,0x81,0x8E,0x70,0x18,0x06,0x01,0x00,/*y,4*/0x08,0xF8,0x00,0x80,0x80,0x00,0x00,0x00,0x00,0x3F,0x11,0x20,0x20,0x11,0x0E,0x00,/*b,5*/0x00,0x00,0x80,0x80,0x80,0x80,0x00,0x00,0x00,0x1F,0x20,0x20,0x20,0x20,0x1F,0x00,/*o,6*/0x80,0x80,0x80,0x00,0x00,0x80,0x80,0x80,0x80,0x81,0x8E,0