Chinaunix首页 | 论坛 | 博客
  • 博客访问: 140457
  • 博文数量: 27
  • 博客积分: 1405
  • 博客等级: 上尉
  • 技术积分: 362
  • 用 户 组: 普通用户
  • 注册时间: 2008-03-10 15:48
文章存档

2013年(3)

2011年(1)

2010年(1)

2008年(22)

我的朋友

分类:

2008-03-10 17:14:06

所罗门(SOLOMON)SSD1298的初始化及调试方法

1、(胜华2.4寸)WK-THE327-TH-B+SSD1298

初始化代码:

void LCD_INIT_SSD1298(void){

     LCD_WRITE_CMD(0x00,0x28);LCD_WRITE_DATA(0x00,0x06);
     LCD_WRITE_CMD(0x00,0x00);LCD_WRITE_DATA(0x00,0x01);
     LCD_WRITE_CMD(0x00,0x03);LCD_WRITE_DATA(0xae,0xa4);//power control 1---line frequency and VHG,VGL voltage
     LCD_WRITE_CMD(0x00,0x0c);LCD_WRITE_DATA(0x00,0x04);//power control 2---VCIX2 output voltage
     LCD_WRITE_CMD(0x00,0x0d);LCD_WRITE_DATA(0x00,0x0c);//power control 3---Vlcd63 voltage
     LCD_WRITE_CMD(0x00,0x0e);LCD_WRITE_DATA(0x28,0x00);//power control 4---VCOMA voltage VCOML=VCOMH*0.9475-VCOMA
     LCD_WRITE_CMD(0x00,0x1e);LCD_WRITE_DATA(0x00,0xb5);//POWER CONTROL 5---VCOMH voltage
    
     LCD_WRITE_CMD(0x00,0x01);LCD_WRITE_DATA(0x3b,0x3f);
    
     LCD_WRITE_CMD(0x00,0x02);LCD_WRITE_DATA(0x06,0x00);
     LCD_WRITE_CMD(0x00,0x10);LCD_WRITE_DATA(0x00,0x00);
     LCD_WRITE_CMD(0x00,0x11);LCD_WRITE_DATA(0x68,0x30);
     LCD_WRITE_CMD(0x00,0x05);LCD_WRITE_DATA(0x00,0x00);
     LCD_WRITE_CMD(0x00,0x06);LCD_WRITE_DATA(0x00,0x00);
     LCD_WRITE_CMD(0x00,0x16);LCD_WRITE_DATA(0xef,0x1c);
    
     LCD_WRITE_CMD(0x00,0x07);LCD_WRITE_DATA(0x00,0x33);//Display control 1
                                                        //when GON=1 and DTE=0,all gate outputs become VGL
                                                        //when GON=1 and DTE=0,all gate outputs become VGH
                                                        //non-selected gate wires become VGL
     
     LCD_WRITE_CMD(0x00,0x0b);LCD_WRITE_DATA(0x00,0x00);
     LCD_WRITE_CMD(0x00,0x0f);LCD_WRITE_DATA(0x00,0x00);
     LCD_WRITE_CMD(0x00,0x41);LCD_WRITE_DATA(0x00,0x00);
     LCD_WRITE_CMD(0x00,0x42);LCD_WRITE_DATA(0x00,0x00);
     LCD_WRITE_CMD(0x00,0x48);LCD_WRITE_DATA(0x00,0x00);
     LCD_WRITE_CMD(0x00,0x49);LCD_WRITE_DATA(0x01,0x3f);
     LCD_WRITE_CMD(0x00,0x4a);LCD_WRITE_DATA(0x00,0x00);
     LCD_WRITE_CMD(0x00,0x4b);LCD_WRITE_DATA(0x00,0x00);
    
     LCD_WRITE_CMD(0x00,0x44);LCD_WRITE_DATA(0xef,0x00);//Horizontal RAM start and end address
     LCD_WRITE_CMD(0x00,0x45);LCD_WRITE_DATA(0x00,0x00);//Vretical RAM start address
     LCD_WRITE_CMD(0x00,0x46);LCD_WRITE_DATA(0x01,0x3f);//Vretical RAM end address
    
     LCD_WRITE_CMD(0x00,0x4e);LCD_WRITE_DATA(0x00,0x00);//set GDDRAM x address counter
     LCD_WRITE_CMD(0x00,0x4f);LCD_WRITE_DATA(0x00,0x00);//set GDDRAM y address counter
    
     //y control
     LCD_WRITE_CMD(0x00,0x30);LCD_WRITE_DATA(0x07,0x07);
     LCD_WRITE_CMD(0x00,0x31);LCD_WRITE_DATA(0x02,0x02);
     LCD_WRITE_CMD(0x00,0x32);LCD_WRITE_DATA(0x02,0x04);
     LCD_WRITE_CMD(0x00,0x33);LCD_WRITE_DATA(0x05,0x02);
     LCD_WRITE_CMD(0x00,0x34);LCD_WRITE_DATA(0x05,0x07);
     LCD_WRITE_CMD(0x00,0x35);LCD_WRITE_DATA(0x02,0x04);
     LCD_WRITE_CMD(0x00,0x36);LCD_WRITE_DATA(0x02,0x04);
     LCD_WRITE_CMD(0x00,0x37);LCD_WRITE_DATA(0x05,0x02);
     LCD_WRITE_CMD(0x00,0x3a);LCD_WRITE_DATA(0x03,0x02);
     LCD_WRITE_CMD(0x00,0x3b);LCD_WRITE_DATA(0x03,0x02);
    
    
     LCD_WRITE_CMD(0x00,0x23);LCD_WRITE_DATA(0x00,0x00);
     LCD_WRITE_CMD(0x00,0x24);LCD_WRITE_DATA(0x00,0x00);
     LCD_WRITE_CMD(0x00,0x25);LCD_WRITE_DATA(0x80,0x00);
     LCD_WRITE_CMD(0x00,0x26);LCD_WRITE_DATA(0x70,0x00);
     LCD_WRITE_CMD(0x00,0x20);LCD_WRITE_DATA(0xb0,0xeb);
     LCD_WRITE_CMD(0x00,0x27);LCD_WRITE_DATA(0x00,0x7c);
     LCD_WRITE_CMD(0x00,0x22);//RAM data write/read

    

 }

调试方法:

a、颜色深浅控制:调节000d h寄存器的值:Vlcd voltage 变大 ==》 颜色加深

       IB3     IB2     IB1    IB0

       VRH3    VRH2    VRH1   VRH0

b、水波纹控制:协同调节000e h 和 001e h寄存器的值可消掉水波纹

    

阅读(2758) | 评论(2) | 转发(0) |
0

上一篇:没有了

下一篇:手机TFT屏FPC设计规范

给主人留下些什么吧!~~

showmyth2008-11-29 09:45:39

您好!能否提供SSD1298的IC资料给我,show_myth@yahoo.com.cn 谢谢

chinaunix网友2008-05-16 15:19:12

好东西,感谢!!