Author Topic: NHD-2.4-240320sf-ctxi#t1 reveresed colors  (Read 663 times)

dfansler

  • Jr. Member
  • **
  • Posts: 26
  • Karma: 0
    • View Profile
NHD-2.4-240320sf-ctxi#t1 reveresed colors
« on: December 21, 2016, 09:49:01 AM »
just got the above 2.4" LCD working, but have a strange problem - at least I think it is a problem.  When I send 0xffff to the display it is black, but sending 0x0000 it goes white!  Other NHD TFTs I have used go black with 0x0000 and white with 0xffff. 

Is this normal, or do I have something set wrong?
Thanks,
David

void LCD_INIT(void)
{
   gpio_set_pin_low(LCD_nWR);
   gpio_set_pin_low(LCD_nRESET);//        gpio_local_clr_gpio_pin(LCD_nRESET);         //cycle the reset line
   delay_ms(250);
   gpio_set_pin_high(LCD_nRESET);//   gpio_local_set_gpio_pin(LCD_nRESET);         //cycle the reset line
   delay_ms(250);
   TFT_24S_Write_Command(0x0028);//display OFF
   TFT_24S_Write_Command(0x0011);TFT_24S_Write_Data(0x0000);            //exit SLEEP mode
   TFT_24S_Write_Command(0x00C0);TFT_24S_Write_Data(0x0026);TFT_24S_Write_Data(0x0004);   //power control 1
   TFT_24S_Write_Command(0x00C1);TFT_24S_Write_Data(0x0004);            //power control 2
   TFT_24S_Write_Command(0x00C5);TFT_24S_Write_Data(0x0034);TFT_24S_Write_Data(0x0040);   //VCOM control 1
   TFT_24S_Write_Command(0x0036);TFT_24S_Write_Data(0x0088);            //memory access control = BGR
   TFT_24S_Write_Command(0x00B1);TFT_24S_Write_Data(0x0000);TFT_24S_Write_Data(0x0018);   //frame rate control
   TFT_24S_Write_Command(0x00B6);TFT_24S_Write_Data(0x000A);TFT_24S_Write_Data(0x00A2);   //display function control
   TFT_24S_Write_Command(0x00C7);TFT_24S_Write_Data(0x00C0);            //VCOM control 2
   TFT_24S_Write_Command(0x003A);TFT_24S_Write_Data(0x0055);            //pixel format = 16 bit per pixel
   TFT_24S_Write_Command(0x002A);TFT_24S_Write_Data(0x0000);            //column address set
   TFT_24S_Write_Data(0x0000);            //start 0x0000
   TFT_24S_Write_Data(0x0000);
   TFT_24S_Write_Data(0x00EF);            //end 0x00EF
TFT_24S_Write_Command(0x002B);TFT_24S_Write_Data(0x0000);            //page address set
      TFT_24S_Write_Data(0x0000);            //start 0x0000
   TFT_24S_Write_Data(0x0001);
   TFT_24S_Write_Data(0x003F);   
   TFT_24S_Write_Command(0x0020);
   delay_ms(100);
   TFT_24S_Write_Command(0x0029);//display ON
   delay_ms(10);
        return;
}

 

NHD‐2.4‐240320SF‐CTXL#‐FTN1 touch-screen problem

Started by hbcelebiBoard TFTs

Replies: 5
Views: 4162
Last post December 10, 2014, 11:19:05 AM
by Michael_L
Working on NHD‐2.4‐240320SF‐CTXL#‐FTN1, have problem in initialization

Started by sli25Board TFTs

Replies: 6
Views: 3773
Last post June 04, 2015, 09:52:25 PM
by sli25
NHD-2.4-240320CF-CTXI#-FT (ST7789S controller) and STM32F4 FSMC LCD Interface

Started by deshayesBoard TFTs

Replies: 1
Views: 2656
Last post March 17, 2016, 06:25:18 PM
by fahad
NHDEV firmware to support NHD-2.4-240320CF-CTXI#-FT (ST7889S controller)

Started by deshayesBoard Evaluation Tools

Replies: 1
Views: 2614
Last post December 17, 2015, 09:52:29 AM
by Saurabh_B
Problem in bringing up NHD‐2.4‐240320SF‐CTXL#‐FTN1 on Renesas RL78/G14

Started by sli25Board TFTs

Replies: 3
Views: 3044
Last post May 28, 2015, 02:59:03 PM
by Michael_L