2013年8月8日星期四

ILI9341's inital code for 2.8" TFT LCD display

The driver IC of 2.8" TFT LCD display module have been changed from ILI9340 to ILI9341, here is the inital code for ILI9341.


Hope it helps.


    //************* Start Initial Sequence **********//
writei2(0x00,0xCF);
writed2(0x00,0x00);
writed2(0x00,0x99);
writed2(0x00,0X30);

writei2(0x00,0xED);
writed2(0x00,0x67);
writed2(0x00,0x03);
writed2(0x00,0X12);
writed2(0x00,0X81);

writei2(0x00,0xE8);
writed2(0x00,0x85);
writed2(0x00,0x0A);
writed2(0x00,0x78);

writei2(0x00,0xCB);
writed2(0x00,0x39);
writed2(0x00,0x2C);
writed2(0x00,0x00);
writed2(0x00,0x34);
writed2(0x00,0x02);

writei2(0x00,0xF7);
writed2(0x00,0x20);

writei2(0x00,0xEA);
writed2(0x00,0x00);
writed2(0x00,0x00);

writei2(0x00,0xC0);       //Power control
writed2(0x00,0x26);     //VRH[5:0]

writei2(0x00,0xC1);       //Power control
writed2(0x00,0x11);     //SAP[2:0];BT[3:0]

writei2(0x00,0xC5);       //VCM control
writed2(0x00,0x2B);
writed2(0x00,0x2C);

writei2(0x00,0xC7);       //VCM control2
writed2(0x00,0xD4);

writei2(0x00,0xF6);      
writed2(0x00,0x01);
writed2(0x00,0x30);
writed2(0x00,0x00);

writei2(0x00,0xB6);      
writed2(0x00,0x0A);
writed2(0x00,0xA2);

writei2(0x00,0x36);       // Memory Access Control
writed2(0x00,0x48);    //48 Portrait screen    68 landscape

writei2(0x00,0x3A);      
writed2(0x00,0x55);

writei2(0x00,0xB1);  
writed2(0x00,0x00);
writed2(0x00,0x19);

writei2(0x00,0xF2);       // 3Gamma Function Disable
writed2(0x00,0x00);

writei2(0x00,0x26);       //Gamma curve selected
writed2(0x00,0x01);

writei2(0x00,0xE0);       //Set Gamma
writed2(0x00,0x0F);
writed2(0x00,0x25);
writed2(0x00,0x23);
writed2(0x00,0x0A);
writed2(0x00,0x0E);
writed2(0x00,0x09);
writed2(0x00,0x50);
writed2(0x00,0xA9);
writed2(0x00,0x41);
writed2(0x00,0x07);
writed2(0x00,0x10);
writed2(0x00,0x03);
writed2(0x00,0x28);
writed2(0x00,0x2A);
writed2(0x00,0x00);

writei2(0x00,0XE1);       //Set Gamma
writed2(0x00,0x00);
writed2(0x00,0x1A);
writed2(0x00,0x1C);
writed2(0x00,0x05);
writed2(0x00,0x11);
writed2(0x00,0x06);
writed2(0x00,0x2F);
writed2(0x00,0x56);
writed2(0x00,0x3E);
writed2(0x00,0x08);
writed2(0x00,0x0F);
writed2(0x00,0x0C);
writed2(0x00,0x17);
writed2(0x00,0x15);
writed2(0x00,0x0F);


writei2(0x00,0x11);       //Exit Sleep

writei2(0x00,0x29);       //Display on


Also for 2.8" TFT's datasheet, you may take this as a reference:

http://www.tslcd.com/uploadfile/20130305204031811.pdf

Well, can anyone tell me how to updownload the full specification? Vielen Dank.

没有评论:

发表评论