完善资料让更多小伙伴认识你,还能领取20积分哦, 立即完善>
关于液晶显示实验有以下几个问题:
1、ILI9320跟LCD在原子大哥的开发板中是怎么连接的? 2、else if(DeviceCode==0x9320||DeviceCode==0x9300) { LCD_WriteReg(0x00,0x0000); LCD_WriteReg(0x01,0x0100); //Driver Output Contral. LCD_WriteReg(0x02,0x0700); //LCD Driver Waveform Contral. LCD_WriteReg(0x03,0x1030);//Entry Mode Set. //LCD_WriteReg(0x03,0x1018); //Entry Mode Set. LCD_WriteReg(0x04,0x0000); //Scalling Contral. LCD_WriteReg(0x08,0x0202); //Display Contral 2.(0x0207) LCD_WriteReg(0x09,0x0000); //Display Contral 3.(0x0000) LCD_WriteReg(0x0a,0x0000); //Frame Cycle Contal.(0x0000) LCD_WriteReg(0x0c,(1<<0)); //Extern Display Interface Contral 1.(0x0000) LCD_WriteReg(0x0d,0x0000); //Frame Maker Position. LCD_WriteReg(0x0f,0x0000); //Extern Display Interface Contral 2. delay_ms(50); LCD_WriteReg(0x07,0x0101); //Display Contral. delay_ms(50); LCD_WriteReg(0x10,(1<<12)|(0<<8)|(1<<7)|(1<<6)|(0<<4)); //Power Control 1.(0x16b0) LCD_WriteReg(0x11,0x0007); //Power Control 2.(0x0001) LCD_WriteReg(0x12,(1<<8)|(1<<4)|(0<<0)); //Power Control 3.(0x0138) LCD_WriteReg(0x13,0x0b00); //Power Control 4. LCD_WriteReg(0x29,0x0000); //Power Control 7. LCD_WriteReg(0x2b,(1<<14)|(1<<4)); LCD_WriteReg(0x50,0); //Set X Star //水平GRAM终止位置Set X End. LCD_WriteReg(0x51,239); //Set Y Star LCD_WriteReg(0x52,0); //Set Y End.t. LCD_WriteReg(0x53,319); // LCD_WriteReg(0x60,0x2700); //Driver Output Control. LCD_WriteReg(0x61,0x0001); //Driver Output Control. LCD_WriteReg(0x6a,0x0000); //Vertical Srcoll Control. LCD_WriteReg(0x80,0x0000); //Display Position? Partial Display 1. LCD_WriteReg(0x81,0x0000); //RAM Address Start? Partial Display 1. LCD_WriteReg(0x82,0x0000); //RAM Address End-Partial Display 1. LCD_WriteReg(0x83,0x0000); //Displsy Position? Partial Display 2. LCD_WriteReg(0x84,0x0000); //RAM Address Start? Partial Display 2. LCD_WriteReg(0x85,0x0000); //RAM Address End? Partial Display 2. LCD_WriteReg(0x90,(0<<7)|(16<<0)); //Frame Cycle Contral.(0x0013) LCD_WriteReg(0x92,0x0000); //Panel Interface Contral 2.(0x0000) LCD_WriteReg(0x93,0x0001); //Panel Interface Contral 3. LCD_WriteReg(0x95,0x0110); //Frame Cycle Contral.(0x0110) LCD_WriteReg(0x97,(0<<8)); // LCD_WriteReg(0x98,0x0000); //Frame Cycle Contral. LCD_WriteReg(0x07,0x0173); //(0x0173) }关于这一大堆关于LCD的初使化函数,原子大哥是看着数据手册写出来的,还是这些芯片有这部分的程序给我们的?? 3、#define MAX_CHAR_POSX 232 #define MAX_CHAR_POSY 312 这两个不是最大值分别是240,320吗?这里为什么要设置成这些值呢?? 4、void LCD_ShowChar(u16 x,u16 y,u8 num,u8 size,u8 mode) { #if USE_HORIZONTAL==1 #define MAX_CHAR_POSX 312 #define MAX_CHAR_POSY 232 #else #define MAX_CHAR_POSX 232 #define MAX_CHAR_POSY 312 #endif u8 temp; u8 pos,t; u16 x0=x; u16 colortemp=POINT_COLOR; if(x>MAX_CHAR_POSX||y>MAX_CHAR_POSY)return; //设置窗口 num=num-' ';//得到偏移后的值 这里是什么意思?? if(!mode) //非叠加方式 { for(pos=0;pos if(size==12)temp=asc2_1206[num][pos];//调用1206字体 else temp=asc2_1608[num][pos]; //调用1608字体 for(t=0;t if(temp&0x01)POINT_COLOR=colortemp; else POINT_COLOR=BACK_COLOR; LCD_DrawPoint(x,y); temp>>=1; x++; } x=x0; y++; } }else//叠加方式 { for(pos=0;pos if(size==12)temp=asc2_1206[num][pos];//调用1206字体 else temp=asc2_1608[num][pos]; //调用1608字体 for(t=0;t if(temp&0x01)LCD_DrawPoint(x+t,y+pos);//画一个点 temp>>=1; } } } OINT_COLOR=colortemp; } |
|
相关推荐
2个回答
|
|
原子哥,//设置窗口 这句注释 和 num=num-' ';//得到偏移后的值 这之间是不是缺少程序?并没有设置窗口的语句
|
|
|
|
原子哥,程序中没有采用开辟窗口的形式来做是吗?
|
|
|
|
只有小组成员才能发言,加入小组>>
调试STM32H750的FMC总线读写PSRAM遇到的问题求解?
1617 浏览 1 评论
X-NUCLEO-IHM08M1板文档中输出电流为15Arms,15Arms是怎么得出来的呢?
1543 浏览 1 评论
977 浏览 2 评论
STM32F030F4 HSI时钟温度测试过不去是怎么回事?
683 浏览 2 评论
ST25R3916能否对ISO15693的标签芯片进行分区域写密码?
1595 浏览 2 评论
1863浏览 9评论
STM32仿真器是选择ST-LINK还是选择J-LINK?各有什么优势啊?
644浏览 4评论
STM32F0_TIM2输出pwm2后OLED变暗或者系统重启是怎么回事?
515浏览 3评论
531浏览 3评论
stm32cubemx生成mdk-arm v4项目文件无法打开是什么原因导致的?
504浏览 3评论
小黑屋| 手机版| Archiver| 电子发烧友 ( 湘ICP备2023018690号 )
GMT+8, 2024-11-22 05:49 , Processed in 0.814554 second(s), Total 79, Slave 62 queries .
Powered by 电子发烧友网
© 2015 bbs.elecfans.com
关注我们的微信
下载发烧友APP
电子发烧友观察
版权所有 © 湖南华秋数字科技有限公司
电子发烧友 (电路图) 湘公网安备 43011202000918 号 电信与信息服务业务经营许可证:合字B2-20210191 工商网监 湘ICP备2023018690号