cs5460程序12864串行显示

合集下载

51单片机 12864液晶显示并口和串口连接程序

51单片机  12864液晶显示并口和串口连接程序
sent(DATA&0XF0); //先写高位后写低位
sent((DATA&0X0F)<<4); //低位
}
void AUTO(uchar *add)
{
uchar cnt=0;
while(*(add+cnt)!='\0')
{
writLCD(1,*(add+cnt));
cnt++;
}
}
void wirtthings(uchar lines,uchar *add)//writ data to which line
else
RW=0;
delay(10);
SCK=1;
DATA=DATA<<1;
}
}
void writLCD(bit flag,uchar DATA) //writ COM or data in address
{
if(flag)
sent(0xfa);//1写数据
else
sent(0xf8);//0写指令
//writLCD(0,0x01);
wirtthings(4,"什么,only You!");
//writLCD(0,0x01);
wirtthings(1,"联系方式:");
//writLCD(0,0x01);
wirtthings(2,"QQ:452658536");
delay(100);
writLCD(0,0x01);
}
}
void delay(uchar i)
{
uchar j;
while(i--)

12864串口程序

12864串口程序

12864串口程序#ifndef lcd12864_H#define lcd12864_H#includesbit SCLK=P2^4; //E :使能信号;串行时钟输入sbit SID=P2^5; //RW :读/写选择端:H 读; L 写; 串行数据线sbit CS=P2^6; //RS :寄存器选择端:H 数据; L 指令; 片选,低有效extern void LCDsendb(uint8 tdata) //一个发送8bit{uint8 i;for(i=0;i<8;i++){SID=tdata&0x80;tdata<<=1;_delay_us(1);SCLK=0;_delay_us(1);SCLK=1;_delay_us(1);}}extern void LCDsendcm(uint8 command) //写命令{CS=1;LCDsendb(0xf8);LCDsendb(command&0xf0);LCDsendb((command<<4)&0xf0);CS=0;}extern void LCDsendda(uint8 w_data) //写数据{CS=1;LCDsendb(0xfa);LCDsendb(w_data&0xf0);LCDsendb((w_data<<4)&0xf0);CS=0;}extern void outstr(uint8 *p) //输出字符串{while(*p>0)LCDsendda(*p++);}/*extern void LCDinch(uint32 num) //int转化为char {uint8 a[11]={'0'};int i=0;if(num==0) LCDsendda('0');while(num){a[i++]=num%10+48; num/=10;}while(i) LCDsendda(a[--i]);}*/extern void LCDflch(float number) //float转化为char { floatnum=number;uint8 a[11]={'0'};int i=0; uint32 num1;num1=(uint32)num;if(num1==0) LCDsendda('0');while(num1){a[i++]=num1%10+48; num1/=10;}while(i) LCDsendda(a[--i]);LCDsendda('.');LCDsendda((uint16)((uint32)(10*num)%10)+48);LCDsendda((uint16)((uint32)(100*num)%10)+48);LCDsendda((uint16)((uint32)(1000*num)%10)+48);LCDsendda((uint16)((uint32)(10000*num)%10)+48);}extern void LCDinit() //LCD12864初始化{_delay_ms(200);LCDsendcm(0x30); //选择基本指令集,选择8bit数据流_delay_us(1);LCDsendcm(0x0d); //开显示(有游标、反白)_delay_us(1);LCDsendcm(0x01); //清除显示,并且设定地址指针为00H _delay_ms(5);LCDsendcm(0x06); //设定游标的移动方向及指定显示的移位_delay_us(1);LCDsendcm(0x80);_delay_us(1);}#endif。

LCD12864_ESUART通过串口命令显示图片

LCD12864_ESUART通过串口命令显示图片

void delay_ms(uint t)//ms 延时函数
{ uint x,y; for(x=t;x>0;x‐‐) for(y=120;y>0;y‐‐);
}
void lcd12864_port_init()//LCD12864 端口初始化函数 {
//TRISB0=0;//选端‐CS,设为输出,低电平有效,已跳线接 GND TRISB2=0;//数据/命令选择端‐CD,设为输出 TRISB3=0;//复位端‐RST,设为输出 TRISB4=0;//数据输入端‐SDI,设为输出 TRISB5=0;//时钟输入端‐SCK,设为输出 TRISA4=0;//背光输入端‐BL,设为输出 //CS=1;//片选端初始化为 1,暂不选中 LCD12864 CD=0;//初始化选择发送命令 RST=1;//初始化复位端为高电平,暂不复位 SDI=1;//数据输入线初始化为 1 SCK=1;//时钟输入线初始化为高电平 }
LCD12864_ESUART 通过串口命令显示图片 原理图 1(图中红色方框处为 MCU 引脚端口)
原理图 2(LCD12864 引脚端口)
图 3(LC12864‐ST7565R 驱动的仅 SPI 写入时序图)
以下 3 幅图为要显示在 LCD12864 上的 BMP 单色位图(128*64 像素)
配置寄存器设置
********************************************************************* ******************************************/ __PROG_CONFIG(1,0xc100);//使能振荡器切换;使能故障保护时钟监控;XT 振荡器; __PROG_CONFIG(2,0x0a16);//看门狗分频 1:32;禁用看门狗;欠压复位 2.7V;硬件使 能欠压复位;使能上电延时定时器; __PROG_CONFIG(3,0x8100);//使能 MCLR 引脚;timer1 高功耗运行;PORTB<4:0>引 脚复位后为数字 I/O;CCP2 与 IO 与 RC1 复用; __PROG_CONFIG(4,0x0081);//禁止后台调试,RB6、7 为通用 I/O 口;禁止变址寻址; 禁止低压编程;堆栈满/下溢导致复位; __PROG_CONFIG(5,0xC00f);//数据 EEPROM 无代码保护;引导区无代码保护;程序 存储块 3-0 无代码保护; __PROG_CONFIG(6,0xe00f);//数据 EEPROM 无写保护;引导区无写保护;配置寄存 器无写保护;程序存储块 3-0 无写保护; __PROG_CONFIG(7,0x400f);//引导区无表读保护;程序存储块 3-0 无表读保护;

12864串行方式使用体会

12864串行方式使用体会

12864使用心得论文一、硬件连接1.1 12864引脚示意图1.2 本次实验中12864与MCU的连接示意图/****************晶振为11.0592**********************/sbit PSB = P1^0; //并1/串0选择//串行接法sbit CS = P1^3; //串片选sbit DS = P1^2; //串数据口sbit SCK = P1^1; //串时钟信号/*//并行接法sbit RS = P1^3; //数据/命令选择端sbit RW = P1^2; //读写选择端sbit E = P1^1; //使能信号端#define DataIO P0 //并行数据口*/二、底层基本程序(串行方式)2.1 基本写字节程序//写一个字节(以SCK上升沿接收一个位)void sendbyte(uint8 zdata){uint16 i;for(i=0; i<8; i++){if((zdata << i) & 0x80){DS = 1;}else {DS = 0;}SCK = 0;SCK = 1;}}2.2 写命令程序(若晶振频率>11.0592,则需加延时处理)//写命令void writeCmd(uint8 cmdcode){CS = 1;sendbyte(0xf8);sendbyte(cmdcode & 0xf0);sendbyte((cmdcode << 4) & 0xf0);// delayMs(1); //若晶振频率>11.0592,则需延时}2.3 写数据程序(若晶振频率>11.0592,则需加延时处理)//写数据void writeData(uint8 dispdata){CS = 1;sendbyte(0xfa);sendbyte(dispdata & 0xf0);sendbyte((dispdata << 4) & 0xf0);// delayMs(1); //若晶振频率>11.0592,则需延时}2.4 通用软件毫秒延时程序//延时程序void delayMs(uint16 xms){uint16 i,j;for (i=0;i<=xms;i++)for (j=0;j<=123;j++);}三、文本显示3.1 LCD12864初始化//LCD12864初始化void LCD12864Init(){PSB = 0; //串行writeCmd(0x30); //基本指令模式writeCmd(0x04); //游标右移一位writeCmd(0x0c); //显示开,关光标writeCmd(0x01); //清除LCD的内容(仅字符模式) }模块控制芯片提供两套控制命令,基本指令和扩充指令如下:指令表1:(RE=0:基本指令)指令表2:(RE=1:扩充指令)3.2 LCD12864字符串的显示//写字符串函数,参数line第1/2行beSpace字符前面的空格数pString指针uint8 write12864String(uint8 line,uint8 beSpace,char *pString){uint8 i=0;uint8 sLength = strlen(pString); //字符串长度if (pString == NULL) //空字符串return -1;writeCmd(0x30); //基本指令模式//设置写在的位置if (line == 1){writeCmd(0x80 + beSpace); //写在第一行的位置}else if (line == 2){writeCmd(0x90 + beSpace); //写在第二行的位置}else if (line == 3){writeCmd(0x88 + beSpace); //写在第三行的位置}else if (line == 4){writeCmd(0x98 + beSpace); //写在第四行的位置}else{return -1;}//写数据for (i=0;i< sLength;i++){writeData ( *pString );pString ++;}return 0;}12864每屏可显示4行8列共32个16×16点阵的汉字,每个显示RAM可显示1个中文字符或2个16×8点阵全高ASCII码字符,即每屏最多可实现32个中文字符或64个ASCII码字符的显示。

12864串行显示中文讲解

12864串行显示中文讲解

12864串行显示中文,按键选择显示页面,并且可调数值。

单片机P1口接矩阵按键,其它接口按程序中定义去接只需要接12864LCD上GND VCC RS RW E PSB RST A K程序如下/********************************12864.h头文件*******************************/ #ifndef _12864_h#define _12864_h/*****包含头文件**************/#include<reg51.h>/********定义I/0口**********/#define GPIO_KEY P1sbit LCD12864_SCLK = P2^7; //Esbit LCD12864_SID = P2^5; //RWsbit LCD12864_CS = P2^6; //RSsbit LCD12864_RET= P2^0;sbit LCD12864_PSB =P2^2;/*声明全局变量*/extern unsigned char keyvalue;/******声明全局函数*********/void Delay1ms(unsigned int); //声明延时函数unsigned char KeyDown(void);void LCD_sendbyte(unsigned char);void WrCom(unsigned char);void WrDat(unsigned char);void LcdInit(void);//void Print(unsigned char);void SetAddress( unsigned char,unsigned char );void DisplayString(unsigned char x ,unsigned char y,unsigned char *add);#endif/********************************12864.C*************************************/ #include"12864.h"#include<reg51.h>#include"string.h"//#define LCM_ST7920_FIRST_LINE_ADDRESS 0x80//#define LCM_ST7920_SECOND_LINE_ADDRESS 0x90//#define LCM_ST7920_THIRD_LINE_ADDRESS 0x88//#define LCM_ST7920_FOURTH_LINE_ADDRESS 0x98/*定义全局变量*/unsigned char keyvalue=0;/****************************************************************************** ** 函数名: Delay1ms* 函数功能: 延时函数,延时1ms* 输入: c* 输出 e : 无* 说名: 该函数是在12MHZ晶振下,12分频单片机的延时。

12864串行显示

12864串行显示
{
SCLK_H; delay(5);
SCLK_L; delay(5);
}
}
CS_L;
SCLK_L;
SID_H;
delay(5);
}
void lcd_show(unsigned char x, unsigned char y, char *ptr)//LCD显示
#include <msp430.h>
#define SID BIT1
#define SCLK BIT2
#define CS BIT3
#define LCDPORT P1OUT
#define SID_H LCDPORT |= SID
#define SID_L LCDPORT &= ~SID
address=j;
wr_lcd(0x00,address);
}
else if(x==0x03)
{
j=0x98+y;
address=j;
wr_lcd(0x00,address);
}
while(ptr[L]!=0x00)
{
if(j==0)
{
wr_lcd(0x00,0x80);
SCLK_L; delay(5);//同步脉冲高五 位置1
}
if(b123==1)
{//------写数据
SID_L; delay(5);
SCLK_H; delay(5);
SCLK_L; delay(5);
SID_H; delay(5);
delay(5);delay(5);
wr_lcd(0x00,0x30); //30---基本指令动作

12864最基本最简单并行串行C程序

12864最基本最简单并行串行C程序

write(0,0x01); //清屏
write(0,0x06); //进入点设定
}
void delay_lcd(int ms) {
uchar t; while(ms--) {
for(t=0; t<20; t++) ; } }//延时 Nhomakorabea200uS
void send(uchar bbyte)
{
uchar i;
void init() {
//初始化
lcden=0; write_com(0x30); write_com(0x0c); write_com(0x01); write_com(0x06); write_com(0x81);
//功能设定,基本指令集 //开显示 //清屏 //进入点设定 //设置启示位置,不写也行,因为默认的就是从第一行开始的
lcdrs=0; P1=com; delay(5); lcden=1; delay(5); lcden=0; }
写指令
void write_data(uchar date) // 写数据 {
lcdrs=1; P1=date; delay(5); lcden=1; delay(5); lcden=0; }
}
void main() {
init(); for(num=0;num<6;num++)
{ write_data(table[num]); delay(200);
}
write_com(0x81+0x10); // 换行
for(num=0;num<11;num++) {
write_data(table1[num]); delay(200); }

12864液晶串行如何显示?

12864液晶串行如何显示?

12864: 12864液晶串行显示这一篇只是简单的介绍了 12864液晶串行显示一些文字不能显示图片,先看一下 12864 的引脚。

从上面的引脚说明我们可以看出,如果要想串行显示只需要将 4、5、6 引脚接到单片机就行了,同时还需要将 1、15、20 引脚接地,17、19 引脚接电源,注意 17 号引脚所说的低电平有效,并不是将 17 号引脚接地复位功能就可以使用了,而是需要软件置低,为了节省IO 口要将 17 号引脚置高,置高说明 17 号引脚复位功能不使用。

3 号引脚接一 10k可调变阻以调节12864液晶的亮度。

具体接法可参考下图:12864:以下是程序:/********************************************************************串行12864液晶显示*引脚说明:CS P1.0SID P1.1SCLK P1.2PSB P1.3RST P1.4Ps:因为PSB和RST我们已经在电路中连接好了,所以这两个引脚没有使用***********************************************************************/ #include <msp430g2553.h> #define uchar unsignedchar#define uint unsignedint/********************************************************************* 名称 : delay()* 功能 : 延时,延时时间为 100us * t。

这是通过软件延时,有一定误差。

* 输入 : t* 输出 : 无***********************************************************************/ void delay( unsigned int t){ unsigned int i,j;for(i=0; i<t; i++) for(j=0; j<10;j++);}/********************************************************************* 名称 : sendbyte()* 功能 : 按照液晶的串口通信协议,发送数据* 输入 : zdata* 输出 : 无***********************************************************************/ void sendbyte( unsigned char zdata){ unsigned int i; for(i=0; i<8;i++){ if((zdata << i) & 0x80){P1OUT |= BIT1; //SID = 1;} else{P1OUT &= ~BIT1;//SID = 0;}P1OUT &= ~BIT2;//SCLK = 0; P1OUT |= BIT2;//SCLK =1;}}/********************************************************************* 名称 : write_com()* 功能 : 写串口指令* 输入 : cmdcode* 输出 : 无**********************************************************************/ void write_com( unsigned char cmdcode){P1OUT |= BIT0;//CS = 1;sendbyte(0xf8); //告诉12864接下来传送指令 sendbyte(cmdcode & 0xf0); sendbyte((cmdcode << 4) &0xf0);delay(2);}/********************************************************************* 名称 : write_data()* 功能 : 写串口指令* 输入 : cmdcode* 输出 : 无***********************************************************************/ void write_data( unsigned char Dispdata){P1OUT |= BIT0;//CS = 1;sendbyte(0xfa); //12864:告诉12864接下来传送数据 sendbyte(Dispdata & 0xf0); sendbyte((Dispdata << 4) & 0xf0);delay(2);}/******************************************************************** * 名称 : lcdinit()* 功能 : 初始化函数* 输入 : cmdcode* 输出 : 无***********************************************************************/ void lcdinit(){/* P1OUT &= ~BIT4;//RST = 0; delay(100);P1OUT |= BIT4;//RST = 1; 这一部分是LCD复位功能,我们已经将复位引脚置高,所以复位功能不能使用了,如果要使用复位功能就将其接到单片机IO口再加上这段函数就行*/delay(20000);write_com(0x30); //基本指令操作delay(50);write_com(0x0c); //显示开关闭光标delay(50);}/******************************************************************* ** 名称 : hzkdis()* 功能 : 显示字符串* 输入 : *s* 输出 : 无***********************************************************************/void hzkdis( char*s){ while(*s >0){write_data(*s);s++;delay(50);}}/******************************************** ************************* 名称 : Test()* 功能 : 显示子函数* 输入 : 无* 输出 : 无***********************************************************************/ void Test(){write_com(0x03); //地址归为 delay(50);write_com(0x81); //显示第一行hzkdis("二院科协");write_com(0x91); //显示第二行hzkdis("刘渠");}/********************************************************************* 名称 : Main()* 功能 : 主函数* 输入 : 无* 输出 : 无***********************************************************************/ void main(){P1DIR |= BIT0 + BIT1 + BIT2 +BIT3 + BIT4; WDTCTL = WDTPW + WDTHOLD; //关闭看门狗/* P1OUT &= ~BIT3; PSB = 0; 串并行选择,如果要使用并行方式,只要置高就行,我们已将PSB接地选择了串行这句可以不要*/delay(1);lcdinit();delay(10);while(1){Test();delay(5000);}}12864 程序的详细分析:void sendbyte( unsigned char zdata){ unsigned int i; for(i=0; i<8; i++){ if((zdata << i) &0x80){P1OUT |= BIT1; //SID = 1;} else{P1OUT &= ~BIT1;//SID = 0;}P1OUT &=~BIT2;//SCLK = 0;P1OUT |= BIT2;//SCLK = 1;}}这个函数的功能就是按照12864传送数据的时序图将数据一位一位的传送给12864,这部分程序需要参照 12864 的时序图来12864:if((zdata << i) & 0x80) 这是在判断传送过来的数据 zdata 的每一位数据是 0还是 1,假设 zadata 是 10101111 来分析一下,那么就是 zdata 先左进 0 还是10101111 不变,然后与 0x80 进行“与”运算,0x80 就是 10000000, 10101111& 10000000————10000000“与”完之后为 1000000,为非 0,所以 P1OUT 输出 1,然后 i++等于 1;zdata左进 1 为01011110;再与 0x80 进行“与”运算,结果为 00000000,所以 P1OUT 输出为 0;与 0x80 进行“与”运算,因为 0x80 只有第一位是 1,其他都是 0,所以这样就可以不改变 zdata 的第一位数据而使其他位为 0,如果 zdata 第一位为 1“与”后结果就是非零,就输出 1,反之相反。

12864显示程序,51单片机,C语言

12864显示程序,51单片机,C语言

12864显示程序,51单片机,C语言可显示固定中文,字符,数字;可实时动态刷新显示数字,字符;#include<reg52.h>sbit rs=P1^2;sbit rw=P1^1;sbit cs=P1^0;sbit psb=P1^3;unsigned char code table[]={" X0: Y0: "}; unsigned char code table1[]={"现在X1: Y1: "}; unsigned char code table2[]={"划线模式:"}; unsigned char code table3[]={"开始暂停"};void delay(unsigned char z) //延时{unsigned i,j;for(i=0;i<z;i++)for(j=0;j<110;j++);}void write_com(unsigned int com) //写命令{rs=0;rw=0;cs=0;P2=com;delay(5);cs=1;delay(5);cs=0;}void write_date(unsigned char dat) //写数据{rs=1;rw=0;cs=0;P2=dat;delay(5);cs=1;delay(5);cs=0;}void pos(unsigned char x,unsigned char y) //起点函数{unsigned char pos;if(x==0)x=0x80;else if(x==1)x=0x90;else if(x==2)x=0x88;else if(x==3)x=0x98;pos=x+y/2;write_com(pos);}void init(){unsigned char i;psb=1; //1并行,0串行write_com(0x30); //基本指令操作delay(5);write_com(0x0c); //显示开,关光标delay(5);write_com(0x01); //清除led的显示内容delay(5);pos(0,0);i=0;while(table[i]!='\0') //第一行固定显示{write_date(table[i]);i++;}pos(1,0);i=0;while(table1[i]!='\0'){write_date(table1[i]); //第二行固定显示i++;}pos(2,0);i=0;while(table2[i]!='\0'){write_date(table2[i]); //第三行固定显示i++;}pos(3,0);i=0;while(table3[i]!='\0'){write_date(table3[i]); //第四行固定显示i++;}}void write_dianya(unsigned char add_x,unsigned char add_y,int date){//12864刷新char bai,shi,ge;bai=date/100;shi=date%100/10;ge=date%10;pos(add_x,add_y);write_date(0x30+bai);write_date(0x30+shi);write_date(0x30+ge);}void main(){init();while(1){write_dianya(0,3,134);}}。

液晶显示12864程序(调试通过)

液晶显示12864程序(调试通过)
0x00,0x00,0x07,0xFF,0xFF,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
0x00,0x00,0x1F,0xFF,0xFF,0xE0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
0x00,0x38,0x0E,0x01,0xFF,0x1F,0xF8,0x00,0x07,0xFE,0x03,0xF8,0x00,0xFF,0xFF,0x00,
0x00,0x3C,0x06,0x01,0xFC,0x1F,0xF8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
0x00,0x00,0x00,0x03,0xFF,0xFF,0xC0,0x00,0x00,0x0F,0xFF,0xFF,0xF0,0x00,0x00,0x1F,
0xFF,0xFF,0xFE,0x00,0x00,0x3F,0xFF,0xFF,0xFF,0x00,0x00,0x7F,0xFF,0xF8,0x07,0x80,
0x00,0x00,0x3F,0xFF,0xFF,0xFC,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
0x00,0x00,0x7F,0xFF,0xFF,0xFE,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
0x7F,0xF8,0x07,0x80,0x3F,0x01,0xFF,0xF0,0x07,0xE0,0x00,0x07,0xFF,0xF0,0x03,0xF0,
0x00,0x1F,0xFF,0xE0,0x01,0xFF,0x03,0xFF,0xFF,0xC0,0x01,0xFF,0xFF,0xFF,0xFF,0xC0,

12864串行显示中文

12864串行显示中文
LCD12864_RET=1;
LCD12864_PSB=0; //串行
WrCom(0x01);//清屏
WrCom(0x30);//基本指令用0x30,扩展指令用0x34
Delay1ms(20);
WrCom(0x0C);//显示开,光标关
WrCom(0x06);//进入模式指针加1,屏幕不移动
}
/****************************************************************************
#endif
/********************************12864.C*************************************/
#include"12864.h"
#include<reg51.h>
#include"string.h"
//#define LCM_ST7920_FIRST_LINE_ADDRESS0x80
void LcdInit(void);
//void Print(unsigned char);
void SetAddress( unsigned char,unsigned char );
void DisplayString(unsigned char x ,unsigned char y,unsigned char *add);
sbit LCD12864_SID = P2^5; //RW
sbit LCD12864_CS = P2^6; //RS
sbit LCD12864_RET= P2^0;
sbit LCD12864_PSB =P2^2;

12864液晶 串行口传输进行图象显示程序-C语言

12864液晶 串行口传输进行图象显示程序-C语言

12864液晶串行口传输进行图象显示程序-C语言#include <reg52.h>#define uint unsigned int#define uchar unsigned char#define x1 0x80#define x2 0x88#define y 0x80#define comm 0#define dat 1sbit std = P2^1;sbit sclk = P2^2;uchar code tab1[]={"本系列中文模块内""任意位置反白显示""置二级字库,可在""使用更方便更灵活"};uchar code tab32[]={/*-- 调入了一幅图像:F:\梁\画图\HOCO12832.bmp --*//*-- 宽度x高度=128x32 --*/0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1E,0x00,0x00,0x00,0x00,0x00,0x07,0xF0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x80,0x00,0x00,0x00,0x00,0x18,0x0C,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x01,0xFF,0x80,0x00,0x00,0x00,0x00,0x20,0x00,0x00,0x00,0x13,0x10,0x03,0xFE,0x00,0x03,0xFF,0xC0,0x00,0x00,0x00,0x00,0x58,0x00,0x00,0x00,0x3F,0x30,0x1F,0xFF,0xC0, 0x03,0xFF,0xE0,0x00,0x00,0x00,0x00,0x8C,0x03,0xF0,0x00,0x7F,0xE0,0x7C,0x01,0xE0, 0x03,0xFF,0xF0,0x00,0x00,0x00,0x01,0x36,0x06,0xC0,0x00,0x5F,0xC0,0xFF,0xFC,0x60, 0x01,0xFF,0xF0,0x00,0x00,0x00,0x02,0x1B,0x0F,0x80,0x00,0xFF,0x01,0xFE,0x0F,0x30, 0x00,0xEF,0xF0,0x00,0x00,0x00,0x02,0x6D,0x9F,0x00,0x00,0x3E,0x03,0xFF,0xF1,0x90, 0x00,0xFF,0xF8,0x00,0x00,0x00,0x04,0x36,0xFE,0x00,0x01,0xFF,0x07,0xFF,0xFC,0x90, 0x00,0xEF,0xFF,0xFF,0x80,0x00,0x04,0xDB,0x7E,0x00,0x03,0xFF,0x87,0xFF,0xFC,0xD0, 0x00,0x0F,0xFF,0xFF,0xC0,0x00,0x04,0x6D,0xFC,0x00,0x07,0xFF,0x8F,0xFF,0xFE,0x50,0x00,0x0F,0xFF,0xFF,0xE0,0x00,0x04,0x36,0xFC,0x10,0x07,0xFF,0x8F,0xFF,0xFE,0x90,0x00,0x0F,0xFF,0xFF,0xE0,0x00,0x04,0x1B,0xF8,0x10,0x07,0xFF,0xCF,0xFF,0xFE,0x80,0x00,0x0F,0xFF,0xFF,0xF0,0x00,0x04,0x0F,0xF8,0x10,0x07,0xFF,0xFF,0xFF,0xFA,0x00,0x00,0x07,0xFF,0xFF,0xF0,0x00,0x04,0x07,0xF0,0x10,0x07,0xFF,0xFF,0xFF,0xFA,0x00,0x00,0xFF,0xFF,0xFF,0xF8,0x00,0x02,0x03,0xF0,0x20,0x07,0xFF,0xFF,0xFF,0xBA,0x00,0x00,0xFD,0xFF,0xFF,0xFC,0x00,0x02,0x03,0xF0,0x20,0x03,0xFF,0xFF,0xDF,0xB8,0x00,0x00,0xC1,0xC0,0x3F,0xFC,0x00,0x01,0x01,0xE0,0x40,0x00,0xFF,0xFF,0xDF,0xB0,0x00,0x00,0x81,0xC0,0x3F,0xCE,0x00,0x00,0x81,0xE0,0x80,0x00,0x7F,0xFF,0xDF,0xA0,0x00,0x00,0x81,0x80,0x1D,0xCF,0x00,0x00,0x41,0xE1,0x00,0x00,0x3F,0xFF,0x9B,0x00,0x00,0x01,0x83,0x80,0x1F,0xC7,0x80,0x00,0x21,0xE2,0x00,0x00,0x1F,0xFD,0xB6,0x00,0x00,0x01,0xC3,0x00,0x0E,0xE6,0x80,0x00,0x19,0xEC,0x00,0x00,0x07,0xFE,0x20,0x00,0x00,0x00,0xC3,0x00,0x07,0x67,0x40,0x00,0x07,0xF0,0x00,0x00,0x03,0x3E,0x00,0x00,0x00,0x00,0x02,0x00,0x03,0xE7,0xA0,0x00,0x00,0x00,0x00,0x00,0x02,0x8E,0x00,0x00,0x00,0x00,0x06,0x00,0x03,0x83,0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x03,0x00,0x00,0x00,0x00,0x06,0x00,0x07,0x03,0x00,0x77,0x46,0x74,0x24,0x80,0x06,0x04,0x00,0x00,0x00,0x00,0x1C,0x00,0x06,0x00,0x00,0x55,0x45,0x54,0x57,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x1C,0x00,0x0E,0x00,0x00,0x45,0x45,0x74,0x57,0x80,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1C,0x00,0x00,0x55,0x45,0x44,0x74,0x80,0xF0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x38,0x00,0x00,0x77,0x76,0x47,0x54,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00};uchar code tab5[]={/*-- 调入了一幅图像:F:\梁\画图\COCK.bmp --*//*-- 宽度x高度=128x64 --*/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, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x3D, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x20, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x22, 0x0C, 0x00, 0x00, 0x00, 0xC0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x22, 0x04, 0x00, 0x02, 0x00, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,0x00, 0x01, 0xC2, 0x01, 0x00, 0x01, 0x00, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x03, 0x03, 0x00, 0x00, 0x00, 0x80, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x06, 0x01, 0x00, 0x00, 0x00, 0xFF, 0x40, 0x00, 0x00, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x00, 0x1C, 0x01, 0x00, 0x00, 0x00, 0x40, 0x40, 0x00, 0x00, 0x00, 0x08, 0x01, 0x00, 0x00, 0x00, 0x00, 0x10, 0x01, 0x00, 0x00, 0x00, 0x40, 0x40, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0xC1, 0x00, 0x00, 0x00, 0x40, 0xC0, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x41, 0x00, 0x00, 0x00, 0x4C, 0x80, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x41, 0x00, 0x7C, 0x00, 0x79, 0x80, 0x00, 0x00, 0x80, 0x00, 0xE6, 0x00, 0x00, 0x00, 0x00, 0x00, 0x47, 0xFF, 0xC0, 0x00, 0x00, 0x00, 0x01, 0xE0, 0x78, 0x01, 0xBC, 0x07, 0x00, 0x00, 0x00, 0x00, 0x7C, 0x80, 0x00, 0x00, 0x01, 0xFC, 0x03, 0x31, 0x0C, 0x01, 0x1C, 0x0D, 0x80, 0x00, 0x00, 0x07, 0xC0, 0x80, 0x00, 0x00, 0x0E, 0x00, 0x02, 0x01, 0x04, 0x13, 0x18, 0x18, 0xC0, 0x00, 0x00, 0x7C, 0x40, 0x80, 0x00, 0x00, 0x38, 0x00, 0x06, 0x01, 0x06, 0x12, 0x18, 0x10, 0x45, 0xC0, 0x0F, 0xC0, 0x40, 0x80, 0x00, 0x01, 0xE8, 0x00, 0x04, 0x01, 0x02, 0x12, 0x30, 0x20, 0xC7, 0x38, 0x00, 0x00, 0x40, 0x80, 0x00, 0x1E, 0x04, 0x00, 0x06, 0x01, 0x02, 0x12, 0x30, 0xE0, 0x86, 0x00, 0x00, 0x00, 0x40, 0x80, 0x00, 0x10, 0x04, 0x00, 0x03, 0x01, 0x02, 0x32, 0x50, 0x7F, 0x8C, 0x00, 0x00, 0x00, 0x60, 0x80, 0x00, 0x00, 0x04, 0x00, 0x01, 0xC1, 0x06, 0x23, 0xD8, 0x40, 0x0C, 0x00, 0x00, 0x00, 0x60, 0x40, 0x00, 0x01, 0x04, 0x00, 0x00, 0x63, 0x0C, 0x20, 0x08, 0x40, 0x18, 0x00, 0x00, 0x00, 0xC0, 0x40, 0x40, 0x01, 0x04, 0x70, 0x00, 0x22, 0x10, 0x60, 0x00, 0x30, 0x18, 0x00, 0x00, 0x01, 0xC0, 0x40, 0x40, 0x01, 0x07, 0xC0, 0x00, 0x23, 0xE0, 0x00, 0x00, 0x0F, 0x18, 0x00, 0x00, 0x06, 0x40, 0x40, 0x80, 0x01, 0x04, 0x00, 0x00, 0x2E, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x0C, 0x40, 0x61, 0x80, 0x01, 0x04, 0x00, 0x00, 0xE2, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x18, 0x40, 0x21, 0x00, 0x01, 0x04, 0x00, 0x07, 0x82, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x30, 0x40, 0x23, 0x00, 0x01, 0x04, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0xE0, 0x40, 0x26, 0x00, 0x03, 0x04, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x20, 0x00, 0x01, 0x04, 0x40, 0x14, 0x00, 0x07, 0x86, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x06, 0x40, 0x18, 0x00, 0x04, 0x42, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xC0, 0x38, 0x10, 0x18, 0x70, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x80, 0xE8, 0x20, 0x30, 0x18, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x01, 0x8C, 0x20, 0x60, 0x0F, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0xC0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x20, 0x00, 0x01, 0xC0, 0x00, 0x08, 0x00, 0x00, 0x01, 0xF8, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x40, 0x00, 0x00, 0x70, 0x00, 0x08, 0x01, 0x00, 0x01, 0x0C, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x40, 0x00, 0x00, 0x0F, 0x80, 0x08, 0x01, 0x39, 0xF3, 0x04, 0x20, 0x00, 0x00, 0x00, 0x00, 0x01, 0xC0, 0x00, 0x00, 0x00, 0x70, 0x10, 0x01, 0x6F, 0x16, 0x14, 0x3C, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0C, 0x10, 0x01, 0xCC, 0x14, 0x34, 0x66, 0x00,0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x18, 0x24, 0xF8, 0xC2, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x10, 0x67, 0xB0, 0x82, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x40, 0x21, 0x82, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1D, 0x82, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x84, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 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, 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, 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, 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, };/*-----------------------------------*/void delay (uint us) //delay time{while(us--);}//**************************************//**************************************void delay1 (uint ms){uint i,j;for(i=0;i<ms;i++)for(j=0;j<15;j++)delay(1);}//**************************************/*---------------------------------------*///我发现在读指令码的时候,程序先调用了6位的低电平,然再在1调用了10位的指令码。

12864液晶显示资料及程序

12864液晶显示资料及程序

12864液晶显示资料及程序硬件连接方式是:并口直接访问。

这是汉字显示程序:#include<reg51.h>#include<absacc.h>#define uchar unsigned char#define datawr 0x1200 //写数据通道#define comwr 0x1000 //写控制命令通道#define datare 0x1300 //读数据通道#define comre 0x1100 //读忙通道uchar code disp_data[]={" 浙江大学" //第一行,第一页"04级通信工程一班" //第三行" 宁波理工学院" //第二行" 竞赛小组" //第四行"128X64液晶显示器" //第一行,第二页" 测试程序" //第三行" 07年07月25日" //第二行" Tornado "}; //第四行void set12864();void write_command(uchar command);void write_page(uchar data_add);void read_page(uchar data_add);void delays(uchar cont);void main(){while(1){set12864(); //初始化12864write_page(0); //写入一页数据read_page(0x30); //读出一页数据到内部RAMdelays(2); //延时2swrite_page(64); //写入下一页数据delays(2); //延时2s}}//初始化12864子程序void set12864(){write_command(0x30); //功能设定控制字write_command(0x0c); //显示开关控制字write_command(0x01); //清除屏幕控制字write_command(0x06); //进入设定点控制字}//写控制命令子程序void write_command(uchar command){bit flag=1; //12864空闲标志位while(flag) //检查12864是否空闲flag="XBYTE"[comre]&0x80;XBYTE[comwr]=command; //空闲传送控制字}//写一页子程序void write_page(uchar data_add){bit flag=1; //12864空闲标志位uchar num=64; //64个循环,连续写入32个汉字或是64个西文字符write_command(0x80);for(;num>0;num--){while(flag) //检查12864是否空闲flag="XBYTE"[comre]&0x80;XBYTE[datawr]=disp_data[data_add++]; //空闲传送数据}}//读一页子程序void read_page(uchar data_add){bit flag=1; //12864空闲标志位uchar num=64; //64个循环,连续写入32个汉字或是64个西文字符write_command(0x80);for(;num>0;num--){while(flag) //检查12864是否空闲flag="XBYTE"[comre]&0x80;DBYTE[data_add++]=XBYTE[datare]; //空闲传送数据}}//延时cont秒子程序void delays(uchar count){unsigned char h,i,j,k;do{for(h=5;h>0;h--)for(i=4;i>0;i--)for(j=116;j>0;j--)for(k=214;k>0;k--);}while(--count);}这是图象显示程序:#include<reg51.h>#include<absacc.h>#define uchar unsigned char#define uint unsigned int#define datawr 0x1200 //写数据通道#define comwr 0x1000 //写控制命令通道#define datare 0x1300 //读数据通道#define comre 0x1100 //读忙通道uchar code disp_data[] = // 数据表{0x00,0x01,0x3F,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0x00,0x00 ,0x00,0x00,0x00,0x00,0x01,0x7F,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0x80,0x00 ,0x00,0x00,0x00,0x00,0x07,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xC0,0x00 ,0x00,0x00,0x00,0x00,0x07,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xE0,0x00 ,0x00,0x00,0x00,0x00,0x0F,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xF0,0x00 ,0x00,0x00,0x00,0x00,0x0F,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xF8,0x00 ,0x00,0x00,0x00,0x00,0x1F,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFC,0x0 0,0x00,0x00,0x00,0x00,0x3F,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFE,0x8 0,0x00,0x00,0x00,0x00,0x7F,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xF F,0xFF,0xFF,0xFF,0x00,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xF0x00,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0x0 3,0xFF,0xFF,0xFF,0x00,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0x0 0,0x07,0xFF,0xFF,0x01,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0x8 0,0x00,0x0B,0xFF,0x01,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0x8 0,0x00,0x00,0x1F,0x01,0xFF,0xFF,0xFF,0xFF,0x7F,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xC 0,0x00,0x00,0x00,0x01,0xFF,0xFF,0xFF,0xF3,0x79,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xC 0,0x00,0x00,0x00,0x03,0xFF,0xFF,0xFF,0xE6,0x62,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xE 1,0x60,0x00,0x68,0x01,0xFF,0xFF,0xFE,0x00,0x60,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xE1 ,0x00,0x00,0x0E,0x01,0xFF,0xFF,0xF8,0x00,0x4B,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xF0 ,0x8E,0x08,0x79,0x07,0xFF,0xFF,0xF0,0x00,0x41,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xE6 ,0xC0,0x07,0x61,0xC3,0xFF,0xFE,0xC0,0x00,0x00,0x7F,0xFF,0xFF,0xFF,0xFF,0xFF,0xF F,0xED,0xEF,0x3F,0x83,0xFF,0xFE,0x60,0x00,0x00,0x7F,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF ,0xFF,0xFF,0xFF,0xC0,0xFF,0xFD,0xFC,0x6C,0x00,0x3F,0xFF,0xFF,0xFF,0xFF,0xFF,0xF F,0xFF,0xFF,0xFF,0xF0,0x7F,0xF3,0xFF,0xFE,0x60,0x3F,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF ,0xFF,0xFF,0xFF,0xFF,0xFF,0xF3,0xFF,0xFF,0x50,0x1F,0xFF,0xFF,0xFF,0xFF,0xFF,0xF F,0xFF,0xFF,0xC9,0xFB,0xFF,0xF1,0xF8,0x8C,0xD8,0x1F,0xFF,0xFF,0xFF,0xFF,0xFF,0xF F,0xFB,0x6F,0xD9,0xC2,0x3F,0xF8,0x40,0x00,0x00,0x1F,0xFF,0xFF,0xFF,0xFF,0xFF,0xF6 ,0xDF,0x1E,0xFF,0xFF,0x7F,0xFC,0x38,0x00,0x00,0x1F,0xFF,0xFF,0xFF,0xFF,0xFF,0x64 ,0x2F,0x6F,0xFF,0xFD,0x7B,0xFC,0x1F,0xE0,0x00,0x1F,0xFF,0xFF,0xFF,0xFF,0xFF,0x5 F,0x7C,0xEE,0xFF,0xC7,0xFF,0xBC,0x0F,0xFF,0x00,0x03,0xFF,0xFF,0xFF,0xFF,0xFF,0xD F,0xFE,0xEF,0xFF,0xFF,0xE7,0xDC,0x07,0xE7,0xF8,0x12,0x7F,0xFF,0xFF,0xFF,0xFF,0x4 7,0xFF,0xFF,0xFF,0xFF,0xE7,0x80,0x03,0xF4,0x00,0x00,0x5F,0xFF,0xFF,0xFE,0xFE,0xE30xFF,0xFE,0xC0,0x01,0xC0,0x00,0x00,0x1B,0xFF,0xFF,0xFB,0xFF,0xF F,0xFF,0xFF,0xFF,0x7F,0xEE,0xC0,0x00,0xC0,0x00,0x00,0x03,0xFF,0xFF,0xFF,0xFF,0xFF ,0xFF,0xFF,0xFF,0xFE,0x98,0x00,0x00,0x00,0x00,0x00,0x03,0xFF,0xFF,0xEF,0xFF,0xFF, 0xFF,0xFF,0xFF,0x20,0x0E,0x60,0x00,0x00,0x00,0x00,0x00,0xFF,0xFF,0x8F,0xFF,0xFF, 0xFF,0xFF,0xFF,0x05,0x80,0xE0,0x00,0x00,0x00,0x00,0x01,0xFF,0xFD,0xFF,0xFF,0xFF, 0xFF,0xFF,0xFF,0x09,0x80,0xA0,0x00,0x00,0x00,0x00,0x01,0xFF,0xFF,0x7F,0xFF,0xFF, 0xFF,0xFF,0xFF,0x85,0x2A,0xC0,0x00,0x00,0x00,0x00,0x01,0xFF,0xFB,0xFF,0xFF,0xFF, 0xFF,0xFF,0xFE,0xBF,0xF3,0xC0,0x00,0x00,0x00,0x00,0x00,0xFF,0xF7,0xFF,0xFF,0xFF, 0xFF,0xFF,0xF8,0xFF,0xFF,0x80,0x00,0x00,0x00,0x00,0x01,0xFF,0xE0,0xFF,0xFF,0xFF, 0xFF,0xFF,0x00,0xFF,0xFF,0x80,0x00,0x00,0x00,0x00,0x00,0xFF,0xC0,0xFF,0xFF,0xFF, 0xFF,0xC0,0x1F,0xFF,0xFF,0x80,0x00,0x40,0x00,0x00,0x00,0xFF,0x80,0xFF,0xFF,0xFF, 0x80,0x07,0xFF,0xFF,0xFF,0xC0,0x00,0xC0,0x00,0x00,0x01,0xFF,0x01,0xFF,0xFF,0xF8 ,0x00,0xFF,0xFF,0xFF,0xFF,0xE0,0x63,0x80,0x00,0x00,0x01,0xFE,0x01,0xFF,0x18,0x00, 0x3F,0xFF,0xFF,0xFF,0xFF,0xFE,0x00,0x00,0x00,0x00,0x01,0xCC,0x01,0xFE,0x00,0x07, 0xFF,0xFF,0xFF,0xFF,0xFF,0xFE,0x00,0x00,0x00,0x00,0x07,0xA0,0x03,0xFC,0x00,0xFF, 0xFF,0xFF,0xFF,0xFF,0xFF,0xFE,0x00,0x00,0x00,0x00,0x05,0xC0,0x03,0xC8,0x00,0x7F, 0xFF,0xFF,0xFF,0xFF,0xFF,0xFE,0x00,0x00,0x00,0x00,0x19,0x00,0x00,0x88,0x0C,0x07, 0xFF,0xFF,0xFF,0xFF,0xFF,0xFC,0x00,0x0C,0x00,0x00,0x00,0x00,0x01,0x00,0x01,0xC0, 0x7F,0xFF,0xFF,0xFF,0xFF,0xF8,0x07,0x0F,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x38,0 x0F,0xFF,0xFE,0xFF,0xFF,0xD0,0x07,0xFF,0xC0,0x00,0x00,0x00,0x00,0x00,0x00,0x0F, 0x03,0xFF,0xF8,0xFF,0xFC,0x00,0x00,0x60,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0 x3F,0xFF,0xC0,0xFF,0xF0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x00,0x00,0x00,00xFF,0xE0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x00,0x00,0x00,0 x00,0x1F,0xFE,0xFF,0xC0,0x00,0x00,0x00,0x00,0x00,0x78,0x02,0x00,0x00,0x00,0x00,0 x00,0x0F,0xFF,0xFF,0x00,0x00,0x00,0x00,0x00,0x03,0xF0,0x78,0x00,0x00,0x00,0x00,0 x00,0x02,0xFF,0xFE,0x00,0x00,0x00,0x00,0x00,0x1F,0xFF,0xF0,0x00,0x00,0x00,0x00, 0x00,0x00,0x7F,0xF0,0x00,0x00,0x00,0x00,0x00,0x7F,0xFF,0xC0,0x00,0x00,0x00,0x00, 0x00,0x00,0x1F,0xE0,0x00,0x00,0x00,0x00,0x00,0x3F,0xFF,0x80,0x00,0x00,0x00,0x00,0 x00,0x00,0x1F,0x00,0x00,0x00,0x00,0x00,0x00,0x0F,0xFF,0x00,0x00,0x00,0x00,0x00,0 x00,0x00,0x27,0xC0,0x00,0x00,0x00,0x00,0x00,0x01,0xFC,0x00,0x00,0x00,0x00,0x00, 0x00,0x00,0x01,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0 x00,0x00,0x04,0x80,0x00,0x00,0x00,0x00,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0 x00,0x00,0x01};void set12864();void setxy(uchar x,uchar y);void write_command(uchar command);void write_16byte(uint data_add);void delays(uchar count);void main(){uchar x,y,i;while(1){y="0x80"; //设置液晶上半部分坐标x="0x80";delays(2); //延时2sset12864(); //初始化12864delays(2);for(i=0;i<32;i++) //写入液晶上半图象部分{ //写入坐标setxy(x,y);write_16byte(i*16); //连续写入16字节数据y++; //y轴地址加1}y="0x80"; //设置液晶下半部分坐标x="0x88";for(i=0;i<32;i++) //写入液晶下半图象部分{setxy(x,y); //写入坐标write_16byte((32+i)*16);//连续写入16字节数据y++; //y轴地址加1}write_command(0x34); //写入扩充指令命令write_command(0x36); //显示图象}}//初始化12864子程序void set12864(){write_command(0x30); //功能设定控制字write_command(0x0c); //显示开关控制字write_command(0x01); //清除屏幕控制字write_command(0x06); //进入设定点控制字}//设置绘图坐标void setxy(uchar x,uchar y){write_command(0x34); //写入扩充指令命令write_command(y); //写入y轴坐标write_command(x); //写入x轴坐标write_command(0x30); //写入基本指令命令}//写控制命令子程序void write_command(uchar command){bit flag="1"; //12864空闲标志位while(flag) //检查12864是否空闲flag="XBYTE"[comre]&0x80;XBYTE[comwr]=command; //空闲传送控制字}void write_16byte(uint data_add){bit flag="1"; //12864空闲标志位uchar num="16"; //16个循环,连续写入16个字节for(;num>0;num--){while(flag) //检查12864是否空闲flag="XBYTE"[comre]&0x80;XBYTE[datawr]=disp_data[data_add++]; //空闲传送数据}}//延时count秒子程序void delays(uchar count){unsigned char h,i,j,k;do{for(h=5;h>0;h--)for(i=4;i>0;i--)for(j=116;j>0;j--)for(k=214;k>0;k--);}while(--count);}圣斗士之家2009-07-28 23:13:30#include#include#define uchar unsigned char#define datawr 0x1200 //写数据通道#define comwr 0x1000 //写控制命令通道#define datare 0x1300 //读数据通道#define comre 0x1100; //读忙通道uchar code disp_data[]={" 浙江大学 " //第一行,第一页"04级通信工程一班" //第三行" 宁波理工学院 " //第二行" 竞赛小组 " //第四行"128X64液晶显示器" //第一行,第二页" 测试程序 " //第三行" 07年07月25日 " //第二行&nbsp; " Tornado "}; //第四行void set12864();void write_command(uchar command);void write_page(uchar data_add);void read_page(uchar data_add);void delays(uchar cont);void main(){while(1){set12864(); //初始化12864write_page(0); &nbsp; //写入一页数据read_page(0x30); //读出一页数据到内部RAMdelays(2); //延时2swrite_page(64); //写入下一页数据delays(2); //延时2s}}//初始化12864子程序void set12864(){write_command(0x30); //功能设定控制字write_command(0x0c); //显示开关控制字write_command(0x01); //清除屏幕控制字write_command(0x06); //进入设定点控制字}//写控制命令子程序void write_command(uchar command){bit flag="1"; //12864空闲标志位while(flag) //检查12864是否空闲flag="XBYTE"[comre]&0x80;XBYTE[comwr]=command; //空闲传送控制字}//写一页子程序void write_page(uchar data_add){bit flag="1"; //12864空闲标志位uchar num="64"; //64个循环,连续写入32个汉字或是64个西文字符 write_command(0x80);for(;num>0;num--){while(flag)//检查12864是否空闲flag="XBYTE"[comre]&0x80;XBYTE[datawr]=disp_data[data_add++]; //空闲传送数据}}//读一页子程序void read_page(uchar data_add){bit flag="1"; //12864空闲标志位uchar num="64"; //64个循环,连续写入32个汉字或是64个西文字符 write_command(0x80);for(;num>0;num--){while(flag) //检查12864是否空闲flag="XBYTE"[comre]&0x80;DBYTE[data_add++]=XBYTE[datare]; //空闲传送数据}}//延时cont秒子程序void delays(uchar count){unsigned char h,i,j,k;do{for(h=5;h>0;h--)for(i=4;i>0;i--)for(j=116;j>0;j--)for(k=214;k>0;k--);}while(--count);}这是图象显示程序:#include#include#define uchar unsigned char#define uint unsigned int#define datawr 0x1200 //写数据通道#define comwr 0x1000&nbsp; //写控制命令通道#define datare 0x1300 //读数据通道#define comre 0x1100 //读忙通道uchar code disp_data[] = // 数据表{0x00,0x01,0x3F,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0x00,0x00,0x00,0x00, 0x00,0x00,0x01,0x7F,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0x80,0x00,0x00,0x00,0x00,0x00,0x07,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xC0,0x00,0x00,0x00, 0x00,0x00,0x07,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xE0,0x00,0x00,0x00, 0x00,0x00,0x0F,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xF0,0x00,0x00,0x00,0x00,0x00,0x0F,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xF8,0x00,0x00,0x00, 0x00,0x00,0x1F,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFC,0x00,0x00,0x00, 0x00,0x00,0x3F,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFE,0x80,0x00,0x00, 0x00,0x00,0x7F,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xF F,0xFF,0x00,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xF F,0xFF,0x00,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0x03,0xFF,0xF F,0xFF,0x00,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0x00,0x07,0xF F,0xFF,0x01,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0x80,0x00,0x0 B,0xFF,0x01,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0x80,0x00,0x00, 0x1F,0x01,0xFF,0xFF,0xFF,0xFF,0x7F,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xC0,0x00,0x0 0,0x00,&nb14#inc lude <stdio.h>#inc lude <conio.h>int main(void){int c;int a;a = getchar();printf ("%c",a);/* Note that getc har reads from stdin andis line buffered; this means it w illnot return until you press ENTER. */while ((c = getc har()) != '\n'){printf("%c", c);}return 0;}注:可以利用getchar()函数让程序调试运行结束后等待编程者按下键盘才返回编辑界面,用法:在主函数结尾,return 0;之前加上getchar();即可getchar 的用途是从从标准输入流读取一个字符,读回车符时退出getchar();永远只向缓存中输入一个字符,getchar();的用法很多;一种就是清空回车符这种情况一般发生在在循环中涉及到输入的情况还有一种是某些编译平台(IDE)在运行程序时并没有在程序运行后给人看结果的时间这时候在程序最后加上getchar()就能造成程序的暂停给程序员度结果的机会用getchar时,在键盘上按一个字符后,要按回车才能读取进去;用getch时,在键盘上按一个字符马上就被读取进去,不用按回车,因此可以作为“按任意键继续”的执行语句。

12864串行时序的实现

12864串行时序的实现

//12864串行时序的实现/**************************************/#include<reg52.h>#include<intrins.h>//端口定义sbit LCD_CS=P0^0; //片选,高有效sbit LCD_SID=P0^1; //串行数据线sbit LCD_SCLK=P0^2; //串上时钟输入sbit LCD_PSB=P0^3; //L:串口sbit LCD_RST=P0^4; //复位信号/**************************************/#define uchar unsigned char#define uint unsigned int/**************************************///延时函数/**************************************/void Delay_nms(uint n){uint i;uchar j;for(i=0;i<n;i++)for(j=0;j<125;j++) //大概1ms_nop_();}/**************************************///串行发送一个字节/**************************************/void LCD_sendbyte(uchar byte){uchar i;for(i=0;i<8;i++){LCD_SCLK=0; //拉低时钟线_nop_();LCD_SID=(bit)(byte&0x80);//发送最高位数据LCD_SCLK=1; //上升沿发送数据byte=byte<<1; //左移一位}LCD_SCLK=0;}/****************************************///写指令void LCD_write_com(uchar com){LCD_CS=1;Delay_nms(5); //串行不支持读操作,不可检测忙操作,这里用延时替代LCD_sendbyte(0xf8);//送入5个连续的“1“,启动一个周期,11111,RW(0),RS(0),0 LCD_sendbyte(0xf0&com); //取高四位,数据分两次传送,//每个字节的内容被送入两个字节//高四位放在第一个字节的高四位LCD_sendbyte(0xf0&(com<<4)); //低四位放在第二个字节的高四位LCD_CS=0;}/******************************************///写数据/******************************************/void LCD_write_dat(uchar dat){LCD_CS=1;Delay_nms(5);LCD_sendbyte(0xfa); //送入5个连续的“1“,启动一个周期,11111,RW(0),RS(1),0 LCD_sendbyte(0xf0&dat); //取高四位,数据分两次传送,//每个字节的内容被送入两个字节//高四位放在第一个字节的高四位LCD_sendbyte(0xf0&(dat<<4)); //低四位放在第二个字节LCD_CS=0;}/********************************************///LCd初始化/********************************************/void LCD_init(void){Delay_nms(50); //等待时间要大于40msLCD_PSB=0; //选择串口LCD_write_com(0x30); //选择基本指令集Delay_nms(3);LCD_write_com(0x0c); //开显示,无游标,不反白Delay_nms(3);LCD_write_com(0x01); //清除显示屏幕,把DDRAM位址计数器调整为00H Delay_nms(3);LCD_write_com(0x06); //设定光标右移,整体显示不移动Delay_nms(3);}/*************************************************/ //显示字符串/*************************************************/ void print(unsigned char *s){while(*s!='\0'){LCD_write_dat(*s);s++;}}/***************************************************/ //汉字显示/***************************************************/ void Hanzi_Display(void){LCD_write_com(0x80);print("黄河远上白云间,");LCD_write_com(0x90);print("一片孤城万仞山。

12864串行使用说明

12864串行使用说明

LCM128645ZK使用说明
1.综述
LCM128645ZK为带中文字库图形点阵液晶显示模块。

其液晶屏幕为128*64,可显示四行,每行可显示8个汉字。

其背光为蓝色,字符为白色中文液晶显示模块LCM128645ZK的字型ROM内含8192个16*16点中文字型和128个16*8半宽的字母符号字型;另外绘图显示画面提供一个64*256点的绘图区域GDRAM;而且内含CGRAM提供4组软件可编程的16*16点阵造字功能。

通过
2.电气特性
3.引脚定义:
4.硬件电路的连接
3.1串并行工作方式的选择
串并行工作方式的选择通过改接模块背面短路电阻来完成。

当PSB脚接低电位(模块背面S/P的短路电阻在“S”侧),模块将进入串行模式;在串行模式下将使用二条传输线作串行资料的传送,主控制系统将配合传输同步时钟(SCLK)与接收串行数据线(SID),来完成串行传输的动作。

不可在不改接短路电阻的情况下将此引脚直接引线改接低电平。

短路电阻位置如图所示:
3.2外部硬件电路(串行工作方式)
串行工作电路如下图所示:并行传输的RS信号作为片选CS信号直接接高电平,读写选择R/W作为串行数据输入SID,读写使能信号作为串行输入时钟信号。

VO与VOUT引脚跨接10K电位器以调节液晶对比度。

RST复位信号可悬空。

背光电源阳极A需接+5V。

数据输入端3.3V高电平可正常驱动。

  1. 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
  2. 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
  3. 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。
lcm_w_test(0,0x01);
delaynms(40); //启动等待,等LCM讲入工作状态
}
/*****************************************************************************/
//向LCM发送一个字符串,长度64字符之内。
{
lcm_w_test(comm,yy++);lcm_w_test(comm,xx);
for (j=0;j<16;j++)
{ lcm_w_test(dat,0x00);}
}
yy=0x80;xx=0x88;
for (i=0;i<32;i++)
#include <reg52.h>
#include <intrins.h>
//#include <math.h>
#include <absacc.h>
#define uchar unsigned char
#define uint unsigned int
//CS5460A的变量设置及端口设置
Ldata=(ddata<<4)&0xf0; //取低四位
lcm_w_byte(start_data); //发送起始信号
delaynms(5); //延时是必须的
lcm_w_byte(Hdata); //发送高四位
delaynms(5); //延时是必须的
{
for(i=0;i<124;i++)
{;}
}
} */
/*******************lcd串行子程序*************************/
/****************************************************************************/
void lcm_w_byte(unsigned char bbyte) {
unsigned char i;
for(i=0;i<8;i++){
SID=bbyte&0x80; //取出最高位
SCLK=1;
SCLK=0;
bbyte<<=1; //左移
sbit SDO=P3^3;
sbit SDI=P1^6;
sbit CLK=P1^7;
sbit CS=P3^4;
sbit RESTEN=P3^2;
/****************************************************************************/
//应用:lcm_w_word(0x80,"您好!");
void lcm_w_word(uchar addr,unsigned char *str)
{
lcm_w_test(0,addr);//写入显示地址
while(*str != '\0')
{
lcm_w_test(1,*str++);
{
lcm_w_test(0,locat);//写入起始地址
while(*str != '\0')
{
lcm_w_test(1,*str++);
}
*str = 0;
}*/
////////////////////////////////
/**********************************************************
//128*64引脚定义
sbit RS = P2^6; //此管脚没用
sbit SID = P2^5; //数据
sbit SCLK = P1^1; //时钟
sbit PSB = P2^4;
#define comm 0
#define dat 1
uint i0;
long int t0;
//uint q0,y;
uint s0;
void s_write_byte(unsigned char value);
char s_read_byte();
/****************************************************************************/
locat:字符的起始位置,范围为80到9F()
cnt:显示的字符个数
*str:指向要显示的字符指针
**************************************************
void lcm_w_array(uchar locat,uchar cnt,uchar *str)
lcm_w_byte(Ldata); //发送低四位
delaynms(5); //延时是必须的
}
/******************************************************************************/
//发送一个字节(底层函数)
delaynms(100); //启动等待,等LCM讲入工作状态
}
/******************************************************************************/
//写指令或数据 (0,指令) (1,数据)
void lcm_w_test(bit start, unsigned char ddata) {
uchar code tab3[]={" 电流值: A"};
uint c;
uint RawTemp_byte_MSB;
uint RawTemp_byte_LSB;
uint RawTemp_uVal;
uint RawTemp_uValu;
//int RawTemp_byte_MSB;
//int RawTemp_byte_LSB;
long int RawTemp_uVal1;
long int RawTemp_uVal2;
uchar v[4][5];
uchar idata q[4][5];
//uchar idata c1[3];
//uchar i[2][2];
uint v0;
置变为正常显示,则这次反白的位置反白。
;调 用:fan(uchar lcd_x,uchar lcd_y,uchar width)
;设 计:启蒙电子
;修 改:豆豆
;**********************************************************/
void lcm_w_byte(unsigned char bbyte); //写一个字节给lcm
void delaynms(unsigned int di); //延时
void lcm_init(void); //lcm初始化
void lcm_clr(void); //清屏
void delayXms(uint dlycnt) //延时1ms
//函数声明
void lcm_w_word(uchar addr,unsigned char *str) ; //写字符 例:lcm_w_word("您好!");
void lcm_w_test(bit start,unsigned char ddata); //(0,指令) (1,数据)
/*void fan(uchar lcd_x,uchar lcd_y,uchar width)
ቤተ መጻሕፍቲ ባይዱ{
uchar xx,yy,i,j,t;
yy=0x80;xx=0x80;
lcm_w_test(comm,0x36);
for (i=0;i<32;i++)
{
lcm_w_test(comm,yy++);lcm_w_test(comm,xx);
for (j=0;j<16;j++)
{ lcm_w_test(dat,0x00);}
}
lcm_w_test(comm,0x30);
//-------------------------------------------
;子程序名 fan(uchar lcd_x,uchar lcd_y,uchar width)
;功 能:12864液晶反白子程序
;说 明: X第几个字(1~8),Y第几行(1~4行),width反白的宽度(1~16)(单位:字符)
若width==0则上次反白的位置变为正常显示,若width!=0,上次反白的位
{
uint i;
for(;dlycnt>0;dlycnt--)
{
for(i=0;i<920;i++)
{;}
}
//i=0;
}
//延时子程序
void delay(void)
{_nop_();_nop_();_nop_();_nop_(); _nop_();_nop_();_nop_();_nop_();
//初始化LCM
void lcm_init(void) {
相关文档
最新文档