/** * @brief Set the start display point of lcd. * @param x,y * @retval None */ void Lcd_SetXY(uint16_t x,uint16_t y) { Lcd_WriteIndex(0x2a); Lcd_WriteData16Bit(x>>8,x); Lcd_WriteIndex(0x2b); Lcd_WriteData16Bit(y>>8,y); Lcd_WriteIndex(0x2c); }
/************************************************* 函数名:LCD_Set_XY 功能:设置lcd显示起始点 入口参数:xy坐标 返回值:无 *************************************************/ void Lcd_SetXY(u16 x,u16 y) { Lcd_WriteIndex(0x2a); Lcd_WriteData16Bit(x>>8,x); Lcd_WriteIndex(0x2b); Lcd_WriteData16Bit(y>>8,y); Lcd_WriteIndex(0x2c); }
/************************************************* 函数名:LCD_Set_Region 功能:设置lcd显示区域,在此区域写点数据自动换行 入口参数:xy起点和终点,Y_IncMode表示先自增y再自增x 返回值:无 *************************************************/ void Lcd_SetRegion(u16 x_start,u16 y_start,u16 x_end,u16 y_end) { Lcd_WriteIndex(0x2a); Lcd_WriteData16Bit(x_start>>8,x_start); Lcd_WriteData16Bit(x_end>>8,x_end); Lcd_WriteIndex(0x2b); Lcd_WriteData16Bit(y_start>>8,y_start); Lcd_WriteData16Bit(y_end>>8,y_end); Lcd_WriteIndex(0x2c); }
/** * @brief Set lcd display region. * @param x_start,y_start,x_end,y_end * @retval None */ void Lcd_SetRegion(uint16_t x_start,uint16_t y_start,uint16_t x_end,uint16_t y_end) { LCD_CS_CLR; Lcd_WriteIndex(0x2a); Lcd_WriteData16Bit(x_start>>8,x_start); Lcd_WriteData16Bit(x_end>>8,x_end); Lcd_WriteIndex(0x2b); Lcd_WriteData16Bit(y_start>>8,y_start); Lcd_WriteData16Bit(y_end>>8,y_end); Lcd_WriteIndex(0x2c); LCD_CS_SET; }
void Lcd_SetRegion(uint16_t x_start, uint16_t y_start, uint16_t x_end, uint16_t y_end) { Lcd_WriteIndex(0x2a); Lcd_WriteData(0x00); Lcd_WriteData(x_start); Lcd_WriteData(0x00); Lcd_WriteData(x_end); Lcd_WriteIndex(0x2b); Lcd_WriteData(0x00); Lcd_WriteData(y_start); Lcd_WriteData(0x00); Lcd_WriteData(y_end); Lcd_WriteIndex(0x2c); }
/************************************************* Lcd_Clear *************************************************/ void Lcd_Clear(u16 Color) { unsigned int i,m; Lcd_SetRegion(0,0,X_MAX_PIXEL-1,Y_MAX_PIXEL-1); Lcd_WriteIndex(0x2C); for(i=0;i<128;i++) for(m=0;m<160;m++) { Lcd_WriteData(Color>>8); Lcd_WriteData(Color); } }
/************************************************* Lcd_Clear *************************************************/ void Lcd_Clear(u16 Color) { unsigned int i,m; // Lcd_SetRegion(0,0,X_MAX_PIXEL-1,Y_MAX_PIXEL-1);// Kullan1lmayacak. Text le gozukmuyor Lcd_WriteIndex(0x2C); for(i=0;i<X_MAX_PIXEL;i++)// orjinali 128 for(m=0;m<Y_MAX_PIXEL;m++)//orjinali 160 { Lcd_WriteData(Color>>8); Lcd_WriteData(Color); } }
void Lcd_Clear(uint16_t Color) { unsigned int i,m; Lcd_SetRegion(0, 0, X_MAX_PIXEL-1, Y_MAX_PIXEL-1); Lcd_WriteIndex(0x2C); for(i = 0; i < X_MAX_PIXEL; i++){ for(m = 0; m < Y_MAX_PIXEL; m++){ Lcd_WriteData(Color>>8); Lcd_WriteData(Color); } } LCD_CS_SET; }
/**************************************************************************** * 名 称:void LCD_WriteReg(u8 Index,u16 Data) * 功 能:写寄存器数据 * 入口参数:Index,Data * 出口参数:无 * 说 明:本函数为组合函数,向Index地址的寄存器写入Data值 ****************************************************************************/ void LCD_WriteReg(u8 Index,u16 Data) { Lcd_WriteIndex(Index); Lcd_WriteData_16Bit(Data); }
void Lcd_WriteReg(u8 Index, u16 Data) { Lcd_WriteIndex(Index); Lcd_WriteData( Data>>8 ); Lcd_WriteData(Data); }
void Lcd_WriteReg(u8 Index,u8 Data) { Lcd_WriteIndex(Index); Lcd_WriteData(Data); }
void Lcd_WriteIndex16Bit(u8 DataH,u8 DataL) { Lcd_WriteIndex(DataH); Lcd_WriteIndex(DataL); }
/** * @brief Lcd Init. * @param None * @retval None */ void Lcd_Init(void) { SPI1_Init(); LCD_CS_CLR; Lcd_Reset(); Lcd_WriteIndex(0xCB); Lcd_WriteData(0x39); Lcd_WriteData(0x2C); Lcd_WriteData(0x00); Lcd_WriteData(0x34); Lcd_WriteData(0x02); Lcd_WriteIndex(0xCF); Lcd_WriteData(0x00); Lcd_WriteData(0XC1); Lcd_WriteData(0X30); Lcd_WriteIndex(0xE8); Lcd_WriteData(0x85); Lcd_WriteData(0x00); Lcd_WriteData(0x78); Lcd_WriteIndex(0xEA); Lcd_WriteData(0x00); Lcd_WriteData(0x00); Lcd_WriteIndex(0xED); Lcd_WriteData(0x64); Lcd_WriteData(0x03); Lcd_WriteData(0X12); Lcd_WriteData(0X81); Lcd_WriteIndex(0xF7); Lcd_WriteData(0x20); /* Power control VRH[5:0] */ Lcd_WriteIndex(0xC0); Lcd_WriteData(0x23); /* Power control SAP[2:0];BT[3:0] */ Lcd_WriteIndex(0xC1); Lcd_WriteData(0x10); /* VCM control */ Lcd_WriteIndex(0xC5); Lcd_WriteData(0x3e); Lcd_WriteData(0x28); /* VCM control2 */ Lcd_WriteIndex(0xC7); Lcd_WriteData(0x86); Lcd_WriteIndex(0x36); #ifdef H_VIEW Lcd_WriteData(0xE8); #else Lcd_WriteData(0x48); #endif Lcd_WriteIndex(0x3A); Lcd_WriteData(0x55); Lcd_WriteIndex(0xB1); Lcd_WriteData(0x00); Lcd_WriteData(0x18); /* Display Function Control */ Lcd_WriteIndex(0xB6); Lcd_WriteData(0x08); Lcd_WriteData(0x82); Lcd_WriteData(0x27); /* 3Gamma Function Disable */ Lcd_WriteIndex(0xF2); Lcd_WriteData(0x00); /* Gamma curve selected */ Lcd_WriteIndex(0x26); Lcd_WriteData(0x01); /* Set Gamma */ Lcd_WriteIndex(0xE0); Lcd_WriteData(0x0F); Lcd_WriteData(0x31); Lcd_WriteData(0x2B); Lcd_WriteData(0x0C); Lcd_WriteData(0x0E); Lcd_WriteData(0x08); Lcd_WriteData(0x4E); Lcd_WriteData(0xF1); Lcd_WriteData(0x37); Lcd_WriteData(0x07); Lcd_WriteData(0x10); Lcd_WriteData(0x03); Lcd_WriteData(0x0E); Lcd_WriteData(0x09); Lcd_WriteData(0x00); /* Set Gamma */ Lcd_WriteIndex(0XE1); Lcd_WriteData(0x00); Lcd_WriteData(0x0E); Lcd_WriteData(0x14); Lcd_WriteData(0x03); Lcd_WriteData(0x11); Lcd_WriteData(0x07); Lcd_WriteData(0x31); Lcd_WriteData(0xC1); Lcd_WriteData(0x48); Lcd_WriteData(0x08); Lcd_WriteData(0x0F); Lcd_WriteData(0x0C); Lcd_WriteData(0x31); Lcd_WriteData(0x36); Lcd_WriteData(0x0F); /* Exit Sleep */ Lcd_WriteIndex(0x11); delay_ms(120); /* Display on */ Lcd_WriteIndex(0x29); Lcd_WriteIndex(0x2c); LCD_CS_SET; }
void Lcd_Init(void) { //SPIv_Init(); SPI2_Init(); Lcd_Reset(); lcddev.width=320; lcddev.height=240; Lcd_WriteIndex(0xCB); Lcd_WriteData(0x39); Lcd_WriteData(0x2C); Lcd_WriteData(0x00); Lcd_WriteData(0x34); Lcd_WriteData(0x02); Lcd_WriteIndex(0xCF); Lcd_WriteData(0x00); Lcd_WriteData(0XC1); Lcd_WriteData(0X30); Lcd_WriteIndex(0xE8); Lcd_WriteData(0x85); Lcd_WriteData(0x00); Lcd_WriteData(0x78); Lcd_WriteIndex(0xEA); Lcd_WriteData(0x00); Lcd_WriteData(0x00); Lcd_WriteIndex(0xED); Lcd_WriteData(0x64); Lcd_WriteData(0x03); Lcd_WriteData(0X12); Lcd_WriteData(0X81); Lcd_WriteIndex(0xF7); Lcd_WriteData(0x20); Lcd_WriteIndex(0xC0); //Power control Lcd_WriteData(0x23); //VRH[5:0] Lcd_WriteIndex(0xC1); //Power control Lcd_WriteData(0x10); //SAP[2:0];BT[3:0] Lcd_WriteIndex(0xC5); //VCM control Lcd_WriteData(0x3e); //对比度调节 Lcd_WriteData(0x28); Lcd_WriteIndex(0xC7); //VCM control2 Lcd_WriteData(0x86); //-- Lcd_WriteIndex(0x36); // Memory Access Control #ifdef H_VIEW Lcd_WriteData(0xE8); //C8 //48 68竖屏//28 E8 横屏 #else Lcd_WriteData(0x48); #endif Lcd_WriteIndex(0x3A); Lcd_WriteData(0x55); Lcd_WriteIndex(0xB1); Lcd_WriteData(0x00); Lcd_WriteData(0x18); Lcd_WriteIndex(0xB6); // Display Function Control Lcd_WriteData(0x08); Lcd_WriteData(0x82); Lcd_WriteData(0x27); Lcd_WriteIndex(0xF2); // 3Gamma Function Disable Lcd_WriteData(0x00); Lcd_WriteIndex(0x26); //Gamma curve selected Lcd_WriteData(0x01); Lcd_WriteIndex(0xE0); //Set Gamma Lcd_WriteData(0x0F); Lcd_WriteData(0x31); Lcd_WriteData(0x2B); Lcd_WriteData(0x0C); Lcd_WriteData(0x0E); Lcd_WriteData(0x08); Lcd_WriteData(0x4E); Lcd_WriteData(0xF1); Lcd_WriteData(0x37); Lcd_WriteData(0x07); Lcd_WriteData(0x10); Lcd_WriteData(0x03); Lcd_WriteData(0x0E); Lcd_WriteData(0x09); Lcd_WriteData(0x00); Lcd_WriteIndex(0XE1); //Set Gamma Lcd_WriteData(0x00); Lcd_WriteData(0x0E); Lcd_WriteData(0x14); Lcd_WriteData(0x03); Lcd_WriteData(0x11); Lcd_WriteData(0x07); Lcd_WriteData(0x31); Lcd_WriteData(0xC1); Lcd_WriteData(0x48); Lcd_WriteData(0x08); Lcd_WriteData(0x0F); Lcd_WriteData(0x0C); Lcd_WriteData(0x31); Lcd_WriteData(0x36); Lcd_WriteData(0x0F); Lcd_WriteIndex(0x11); //Exit Sleep delay_ms(120); Lcd_WriteIndex(0x29); //Display on Lcd_WriteIndex(0x2c); }
void Lcd_WriteReg(uint8_t Index, uint8_t Data) { Lcd_WriteIndex(Index); Lcd_WriteData(Data); }
void Lcd_Init(void) { LCD_GPIO_Init(); Lcd_Reset(); Lcd_WriteIndex(0x11);//Sleep exit xSysCtlDelay(xSysCtlClockGet()/10); //ST7735R Frame Rate Lcd_WriteIndex(0xB1); Lcd_WriteData(0x01); Lcd_WriteData(0x2C); Lcd_WriteData(0x2D); Lcd_WriteIndex(0xB2); Lcd_WriteData(0x01); Lcd_WriteData(0x2C); Lcd_WriteData(0x2D); Lcd_WriteIndex(0xB3); Lcd_WriteData(0x01); Lcd_WriteData(0x2C); Lcd_WriteData(0x2D); Lcd_WriteData(0x01); Lcd_WriteData(0x2C); Lcd_WriteData(0x2D); Lcd_WriteIndex(0xB4); //Column inversion Lcd_WriteData(0x07); //ST7735R Power Sequence Lcd_WriteIndex(0xC0); Lcd_WriteData(0xA2); Lcd_WriteData(0x02); Lcd_WriteData(0x84); Lcd_WriteIndex(0xC1); Lcd_WriteData(0xC5); Lcd_WriteIndex(0xC2); Lcd_WriteData(0x0A); Lcd_WriteData(0x00); Lcd_WriteIndex(0xC3); Lcd_WriteData(0x8A); Lcd_WriteData(0x2A); Lcd_WriteIndex(0xC4); Lcd_WriteData(0x8A); Lcd_WriteData(0xEE); Lcd_WriteIndex(0xC5); //VCOM Lcd_WriteData(0x0E); Lcd_WriteIndex(0x36); //MX, MY, RGB mode Lcd_WriteData(0xC8); //ST7735R Gamma Sequence Lcd_WriteIndex(0xe0); Lcd_WriteData(0x0f); Lcd_WriteData(0x1a); Lcd_WriteData(0x0f); Lcd_WriteData(0x18); Lcd_WriteData(0x2f); Lcd_WriteData(0x28); Lcd_WriteData(0x20); Lcd_WriteData(0x22); Lcd_WriteData(0x1f); Lcd_WriteData(0x1b); Lcd_WriteData(0x23); Lcd_WriteData(0x37); Lcd_WriteData(0x00); Lcd_WriteData(0x07); Lcd_WriteData(0x02); Lcd_WriteData(0x10); Lcd_WriteIndex(0xe1); Lcd_WriteData(0x0f); Lcd_WriteData(0x1b); Lcd_WriteData(0x0f); Lcd_WriteData(0x17); Lcd_WriteData(0x33); Lcd_WriteData(0x2c); Lcd_WriteData(0x29); Lcd_WriteData(0x2e); Lcd_WriteData(0x30); Lcd_WriteData(0x30); Lcd_WriteData(0x39); Lcd_WriteData(0x3f); Lcd_WriteData(0x00); Lcd_WriteData(0x07); Lcd_WriteData(0x03); Lcd_WriteData(0x10); Lcd_WriteIndex(0x2a); Lcd_WriteData(0x00);Lcd_WriteData(0x00); Lcd_WriteData(0x00);Lcd_WriteData(0x7f); Lcd_WriteIndex(0x2b); Lcd_WriteData(0x00);Lcd_WriteData(0x00); Lcd_WriteData(0x00);Lcd_WriteData(0x9f); Lcd_WriteIndex(0xF0); //Enable test command Lcd_WriteData(0x01); Lcd_WriteIndex(0xF6); //Disable ram power save mode Lcd_WriteData(0x00); Lcd_WriteIndex(0x3A); //65k mode Lcd_WriteData(0x05); Lcd_WriteIndex(0x29);//Display on }
void Lcd_Init(void) { // int i=0; LCD_GPIO_Init(); Lcd_Reset(); Lcd_WriteIndex(0x11);//Sleep out delay_ms(500); Lcd_WriteIndex(0x3A);//Color Mode Lcd_WriteData(0x05); delay_ms(10); Lcd_WriteIndex(0xB1);//Frame rate control Lcd_WriteData(0x00); Lcd_WriteData(0x06); Lcd_WriteData(0x03); delay_ms(10); Lcd_WriteIndex(0x36);//Memory access ctrl Lcd_WriteData(0x08); Lcd_WriteIndex(0xB6);//Display settings #5 Lcd_WriteData(0x15); Lcd_WriteData(0x02); Lcd_WriteIndex(0xB4);//Display inversion control Lcd_WriteData(0x0); Lcd_WriteIndex(0xC0);//Power control1 Lcd_WriteData(0x02); Lcd_WriteData(0x70); delay_ms(10); Lcd_WriteIndex(0xC1);//Power control2 Lcd_WriteData(0x05); Lcd_WriteIndex(0xC2);//Power control3 Lcd_WriteData(0x01); Lcd_WriteData(0x02); Lcd_WriteIndex(0xC5);//VPower control Lcd_WriteData(0x3C); Lcd_WriteData(0x38); delay_ms(10); Lcd_WriteIndex(0xFC);//Power control6 Lcd_WriteData(0x11); Lcd_WriteData(0x15); Lcd_WriteIndex(0xE0);//Magical unicorn dust Lcd_WriteData(0x09); Lcd_WriteData(0x16); Lcd_WriteData(0x09); Lcd_WriteData(0x20); Lcd_WriteData(0x21); Lcd_WriteData(0x1B); Lcd_WriteData(0x13); Lcd_WriteData(0x19); Lcd_WriteData(0x17); Lcd_WriteData(0x15); Lcd_WriteData(0x1E); Lcd_WriteData(0x2B); Lcd_WriteData(0x04); Lcd_WriteData(0x05); Lcd_WriteData(0x02); Lcd_WriteData(0x0E); Lcd_WriteIndex(0xE1);//Sparkles and rainbows Lcd_WriteData(0x0B); Lcd_WriteData(0x14); Lcd_WriteData(0x08); Lcd_WriteData(0x1E); Lcd_WriteData(0x22); Lcd_WriteData(0x1D); Lcd_WriteData(0x18); Lcd_WriteData(0x1E); Lcd_WriteData(0x1B); Lcd_WriteData(0x1A); Lcd_WriteData(0x24); Lcd_WriteData(0x2B); Lcd_WriteData(0x06); Lcd_WriteData(0x06); Lcd_WriteData(0x02); Lcd_WriteData(0x0F); delay_ms(10); Lcd_WriteIndex(0x2A);//Column addr set Lcd_WriteData(0x00); Lcd_WriteData(0x02); Lcd_WriteData(0x00); Lcd_WriteData(0x81); Lcd_WriteIndex(0x2B);//Row addr set Lcd_WriteData(0x00); Lcd_WriteData(0x02); Lcd_WriteData(0x00); Lcd_WriteData(0x81); Lcd_WriteIndex(0x13);//Normal display on delay_ms(10); Lcd_WriteIndex(0x29);//Main screen turn on delay_ms(500); // Lcd_WriteIndex(0xB9);//SETEXTC // Lcd_WriteData(0xFF); // Lcd_WriteData(0x83); // Lcd_WriteData(0x53); // // Lcd_WriteIndex(0xB0);//RADJ // Lcd_WriteData(0x3C); // Lcd_WriteData(0x01); // // // Lcd_WriteIndex(0xB6);//VCOM // Lcd_WriteData(0x94); // Lcd_WriteData(0x6C); // Lcd_WriteData(0x50); // // Lcd_WriteIndex(0xB1);//PWR // Lcd_WriteData(0x00); // Lcd_WriteData(0x01); // Lcd_WriteData(0x1B); // Lcd_WriteData(0x03); // Lcd_WriteData(0x01); // Lcd_WriteData(0x08); // Lcd_WriteData(0x77); // Lcd_WriteData(0x89); // // Lcd_WriteIndex(0xE0); //Gamma setting for tpo Panel // Lcd_WriteData(0x50); // Lcd_WriteData(0x77); // Lcd_WriteData(0x40); // Lcd_WriteData(0x08); // Lcd_WriteData(0xBF); // Lcd_WriteData(0x00); // Lcd_WriteData(0x03); // Lcd_WriteData(0x0F); // Lcd_WriteData(0x00); // Lcd_WriteData(0x01); // Lcd_WriteData(0x73); // Lcd_WriteData(0x00); // Lcd_WriteData(0x72); // Lcd_WriteData(0x03); // Lcd_WriteData(0xB0); // Lcd_WriteData(0x0F); // Lcd_WriteData(0x08); // Lcd_WriteData(0x00); // Lcd_WriteData(0x0F); // // Lcd_WriteIndex(0x3A); // Lcd_WriteData(0x05); //05 // Lcd_WriteIndex(0x36); // Lcd_WriteData(0xC0); //83 //0B // // Lcd_WriteIndex(0x11); // SLPOUT // delay_ms(150); // Lcd_WriteIndex(0x29); // display on // delay_ms(150); // Lcd_WriteIndex(0x2D); //Look up table // for(i=0;i<32;i++) // {Lcd_WriteData(2*i);} //Red // for(i=0;i<64;i++) // {Lcd_WriteData(1*i);} //Green // for(i=0;i<32;i++) // {Lcd_WriteData(2*i);} //Blue // // Lcd_WriteIndex(0x2c); // delay_ms(150); //Lcd_WriteIndex(0x11);//Sleep out // delay_ms(120); //ST7735R Frame Rate // Lcd_WriteIndex(0xB1); // Lcd_WriteData(0x01); // Lcd_WriteData(0x2C); // Lcd_WriteData(0x2D); // Lcd_WriteIndex(0xB2); // Lcd_WriteData(0x01); // Lcd_WriteData(0x2C); // Lcd_WriteData(0x2D); // Lcd_WriteIndex(0xB3); // Lcd_WriteData(0x01); // Lcd_WriteData(0x2C); // Lcd_WriteData(0x2D); // Lcd_WriteData(0x01); // Lcd_WriteData(0x2C); // Lcd_WriteData(0x2D); // //------------------------------------End ST7735R Frame Rate-----------------------------------------// // Lcd_WriteIndex(0xB4);//Column inversion // Lcd_WriteData(0x07); // //------------------------------------ST7735R Power Sequence-----------------------------------------// // Lcd_WriteIndex(0xC0); // Lcd_WriteData(0xA2); // Lcd_WriteData(0x02); // Lcd_WriteData(0x84); // Lcd_WriteIndex(0xC1); // Lcd_WriteData(0xC5); // Lcd_WriteIndex(0xC2); // Lcd_WriteData(0x0A); // Lcd_WriteData(0x00); // Lcd_WriteIndex(0xC3); // Lcd_WriteData(0x8A); // Lcd_WriteData(0x2A); // Lcd_WriteIndex(0xC4); // Lcd_WriteData(0x8A); // Lcd_WriteData(0xEE); // //---------------------------------End ST7735R Power Sequence-------------------------------------// // Lcd_WriteIndex(0xC5);//VCOM // Lcd_WriteData(0x0E); // Lcd_WriteIndex(0x36);//MX, MY, RGB mode // Lcd_WriteData(0xC8); // //------------------------------------ST7735R Gamma Sequence-----------------------------------------// // Lcd_WriteIndex(0xe0); // Lcd_WriteData(0x02); // Lcd_WriteData(0x1c); // Lcd_WriteData(0x07); // Lcd_WriteData(0x12); // Lcd_WriteData(0x37); // Lcd_WriteData(0x32); // Lcd_WriteData(0x29); // Lcd_WriteData(0x2d); // Lcd_WriteData(0x29); // Lcd_WriteData(0x25); // Lcd_WriteData(0x2b); // Lcd_WriteData(0x39); // Lcd_WriteData(0x00); // Lcd_WriteData(0x01); // Lcd_WriteData(0x03); // Lcd_WriteData(0x10); // Lcd_WriteIndex(0xe1); // Lcd_WriteData(0x03); // Lcd_WriteData(0x1d); // Lcd_WriteData(0x07); // Lcd_WriteData(0x06); // Lcd_WriteData(0x2e); // Lcd_WriteData(0x2c); // Lcd_WriteData(0x29); // Lcd_WriteData(0x2d); // Lcd_WriteData(0x2e); // Lcd_WriteData(0x2e); // Lcd_WriteData(0x37); // Lcd_WriteData(0x3f); // Lcd_WriteData(0x00); // Lcd_WriteData(0x00); // Lcd_WriteData(0x02); // Lcd_WriteData(0x10); // Lcd_WriteIndex(0x2A); // Lcd_WriteData(0x00); // Lcd_WriteData(0x02); // Lcd_WriteData(0x00); // Lcd_WriteData(0x81); // Lcd_WriteIndex(0x2B); // Lcd_WriteData(0x00); // Lcd_WriteData(0x01); // Lcd_WriteData(0x00); // Lcd_WriteData(0xA0); // //------------------------------------End ST7735R Gamma Sequence-----------------------------------------// // Lcd_WriteIndex(0x3A); // Lcd_WriteData(0x05); // //Lcd_WriteIndex(0x3A);//65k mode // //Lcd_WriteData(0x05); // Lcd_WriteIndex(0x2C);//Display on //// LCD_Rectangle(0,0,128,160,0); // black it out // Lcd_WriteIndex(0x29);//Display on }