cancel
Showing results for 
Search instead for 
Did you mean: 

TouchGFX RGB Color Output Problem Questions.

ybyeo.1
Associate

Hello, I'm asking you this question because there is a problem that I couldn't solve during the Touch GFX test.

First, let me tell you about the current environment.

1. Evaluation board: NUCLEO-L4P5ZG

2. IPS TFT-LCD

1) Resolution: 320 × 240, 16-bit color

2) Interface: 8080-parallel (using FMC)

3) Driver: ILI9341V

3. CubeMX Settings

1) Interface: Custom

2) Framebuffer Pixel Format: RGB565

3) Width: 320, Height: 240

4) Framebuffer Strategy: Partial Buffer

5) Number of Blocks: 3

6) Block Size: 15,360 bytes

7) Application Tick Source: Custom

8) Graphics Accelerator: None

9) Real-Time Operating System: No OS

TE pin on LCD was received as external input and called

"touchgfx::HAL::getInstance()->vSync();" and "touchgfx::OSWrappers::signalVSync();".

Inserted a user function that sends the ILI9341 driver's cursor and frambuffer data within the function

"void touchgfxDisplayDriverTransmitBlock(uint8_t* pixels, uint16_t x, uint16_t y, uint16_t w, uint16_t h)".

* Problems

We used TouchGFX designer to draw red, green, and blue boxes and print them out to LCD.

The problem is that it changes to Red -> Blue, Green -> Red, Blue -> Green. (I have attached an image for the problem situation.) If you set the BGR setting to 'RESET' in ILI9341 driver settings, it changes to Red -> Red, Green -> Blue, Blue -> Green.

I wonder if the problem is caused by the lack of sync between the rendering of TouchGFX engine and the transmission of LCD, or if it can be solved by setting on TouchGFX or LCD driver. I know you are busy, but please reply. Thank you.

0693W00000BbAcSQAV.jpg0693W00000BbAahQAF.jpg 

0693W00000BbAcwQAF.jpg 

0693W00000BbAd6QAF.jpg

4 REPLIES 4
MM..1
Chief II

Search mistake in Inserted a user function that sends the ILI9341 driver's cursor and frambuffer data within the function

"void touchgfxDisplayDriverTransmitBlock(uint8_t* pixels, uint16_t x, uint16_t y, uint16_t w, uint16_t h)"

Alexandre RENOUX
Principal

Hello ybyeo.1,

With SPI displays, you can have a similar behavior if your polarity and phase are not set correctly.

Also by default, TouchGFX generates BGR tables for the images, see this post.

So it's extremely likely an issue with your driver. Make sure you send the data correctly to your display. How is your display understanding the data you send ? There must be an option to specify RGB or BGR.

Also make sure your FMC parameters are correctly set.

/Alexandre

margce
Associate III

Were you able to fix this issue? I'm having the same problem with my ST7789 SPI display. I know the driver implementation is correct because when I use the driver itself without TouchGFX I get the right colours but when using TouchGFX i get the same issue as you explained.

margce
Associate III

Not sure if you found the solution to your problem but when using the ST7789 i had the same issue and resolved using 16bit SPI communication to send the RGB display data as explained here in the Display section.