WriteComm(0xFE); WriteComm(0xEF); //内部寄存器使能80~8Fh WriteComm(0x80); WriteData(0xFF); WriteComm(0x81); WriteData(0xFF); WriteComm(0x82); WriteData(0xFF); WriteComm(0x83); WriteData(0xFF); WriteComm(0x84); WriteData(0xFF); WriteComm(0x85); WriteData(0xFF); WriteComm(0x86); WriteData(0xFF); WriteComm(0x87); WriteData(0xFF); WriteComm(0x88); WriteData(0xFF); WriteComm(0x89); WriteData(0xFF); WriteComm(0x8A); WriteData(0xFF); WriteComm(0x8B); WriteData(0xFF); WriteComm(0x8C); WriteData(0xFF); WriteComm(0x8D); WriteData(0xFF); WriteComm(0x8E); WriteData(0xFF); WriteComm(0x8F); WriteData(0xFF); WriteComm(0x3A); WriteData(0x05); //设置翻转方式 WriteComm(0xEC); WriteData(0x11); //VGL大小 WriteComm(0x7E); WriteData(0x7a); //修改帧频 WriteComm(0x74); WriteData(0x02); WriteData(0x0E); WriteData(0x00); WriteData(0x00); WriteData(0x28); WriteData(0x00); WriteData(0x00); //内部电压调整 WriteComm(0x98); WriteData(0x3E); WriteComm(0x99); WriteData(0x3E); //内部porch设置 WriteComm(0xB5); WriteData(0x0E); WriteData(0x0E); //gip timing start WriteComm(0x60); WriteData(0x38); WriteData(0x09); WriteData(0x6D); WriteData(0x67); WriteComm(0x63); WriteData(0x38); WriteData(0xAD); WriteData(0x6D); WriteData(0x67); WriteData(0x05); WriteComm(0x64); WriteData(0x38); WriteData(0x0B); WriteData(0x70); WriteData(0xAB); WriteData(0x6D); WriteData(0x67); WriteComm(0x66); WriteData(0x38); WriteData(0x0F); WriteData(0x70); WriteData(0xAF); WriteData(0x6d); WriteData(0x67); WriteComm(0x6A); WriteData(0x00); WriteData(0x00); WriteComm(0x68); WriteData(0x3B); WriteData(0x08); WriteData(0x04); WriteData(0x00); WriteData(0x04); WriteData(0x64); WriteData(0x67); WriteComm(0x6C); WriteData(0x22); WriteData(0x02); WriteData(0x22); WriteData(0x02); WriteData(0x22); WriteData(0x22); WriteData(0x50); WriteComm(0x6E); WriteData(0x00); WriteData(0x00); WriteData(0x00); WriteData(0x00); WriteData(0x07); WriteData(0x01); WriteData(0x13); WriteData(0x11); WriteData(0x0B); WriteData(0x09); WriteData(0x16); WriteData(0x15); WriteData(0x1D); WriteData(0x1E); WriteData(0x00); WriteData(0x00); WriteData(0x00); WriteData(0x00); WriteData(0x1E); WriteData(0x1D); WriteData(0x15); WriteData(0x16); WriteData(0x0A); WriteData(0x0C); WriteData(0x12); WriteData(0x14); WriteData(0x02); WriteData(0x08); WriteData(0x00); WriteData(0x00); WriteData(0x00); WriteData(0x00); //gip timing end //内部电压设定开始 WriteComm(0xA9); WriteData(0x1B); WriteComm(0xA8); WriteData(0x6B); WriteComm(0xA8); WriteData(0x6D); WriteComm(0xA7); WriteData(0x40); WriteComm(0xAD); WriteData(0x47); WriteComm(0xAF); WriteData(0x73); WriteComm(0xAF); WriteData(0x73); WriteComm(0xAC); WriteData(0x44); WriteComm(0xA3); WriteData(0x6C); WriteComm(0xCB); WriteData(0x00); WriteComm(0xCD); WriteData(0x22); WriteComm(0xC2); WriteData(0x10); WriteComm(0xC5); WriteData(0x00); WriteComm(0xC6); WriteData(0x0E); WriteComm(0xC7); WriteData(0x1f); WriteComm(0xC8); WriteData(0x0E); //内部电压设定结束 //选择single gate mode WriteComm(0xbf); WriteData(0x00); //SOU相关调整 WriteComm(0xF9); WriteData(0x20); //vreg电压调整 WriteComm(0x9b); WriteData(0x3b); WriteComm(0x93); WriteData(0x33); WriteData(0x7f); WriteData(0x00); //VGH/VGL CLK调整70,71h WriteComm(0x70); WriteData(0x0E); WriteData(0x0f); WriteData(0x03); WriteData(0x0e); WriteData(0x0f); WriteData(0x03); WriteComm(0x71); WriteData(0x0e); WriteData(0x16); WriteData(0x03); //内部电压调整 WriteComm(0x91); WriteData(0x0e); WriteData(0x09); //vreg电压调整 WriteComm(0xc3); WriteData(0x2c); WriteComm(0xc4); WriteData(0x1a); //gamma F1~F3h WriteComm(0xf0); WriteData(0x51); WriteData(0x13); WriteData(0x0c); WriteData(0x06); WriteData(0x00); WriteData(0x2f); WriteComm(0xf2); WriteData(0x51); WriteData(0x13); WriteData(0x0c); WriteData(0x06); WriteData(0x00); WriteData(0x33); WriteComm(0xf1); WriteData(0x3c); WriteData(0x94); WriteData(0x4f); WriteData(0x33); WriteData(0x34); WriteData(0xCf); WriteComm(0xf3); WriteData(0x4d); WriteData(0x94); WriteData(0x4f); WriteData(0x33); WriteData(0x34); WriteData(0xCf); WriteComm(0x36); WriteData(0x40); WriteComm(0x11); Delay(200); WriteComm(0x29); WriteComm(0x2C);