cancel
Showing results for 
Search instead for 
Did you mean: 

L8_RGB565 images issue

TDele.1
Associate III

Hello,

To save space on the section "ExtFlashSection" with the dev board STM32F469I-DISCO, I'm trying to use the L8_RGB565 format for my backgrounds. I'm doing this by changing the "Image Format" of all background on the "Images" section of TouchGFX Designer. This is working when I launch the Simulator but when I try actually seeing it on the board, the colors are weird like so:

Simulator:

0693W00000ANZGtQAP.pngSTM32F469I-DISCO:

0693W00000ANZHwQAP.pngHow can I solve the issue ?

Thanks in advance,

DELETRAZ Tristan

10 REPLIES 10
Romain DIELEMAN
ST Employee

Hi,

Do you wish to only use the L8_RGB565 format ? It has been a while since I worked with it 😅 but could you share your images so that I / other users can try to replicate it ? Have you gone through the relevant articles in the online documentation ?

/Romain

TDele.1
Associate III

Hello,

If possible, I wish to use both L8_RGB565 and RGB565 as I would prefere to not lose colors on some other pictures.

I've read the article you're mentioning and I did the modifications explained there over on TouchGFX Designer as well as modified the pictures with paint.net so that they have less than 256 colors.

To reproduce this issue I performed the following actions:

  • Create a new project by choosing "STM32F469I Discovery Kit" and "Blank UI"
  • On the first screen, add the wigdet "Image"
  • Add the attached image to the project's assets with TouchGFX Designer
  • Make the "Image" widget show that particular image
  • Switch that image format to "L8_RGB565" with TouchGFX Designer
  • Generate the code from the designer
  • If launched there, the image will look alright on the board
  • Instead, launch the ioc file to open CubeMX
  • Generate the code from there
  • Reload the project in the designer
  • Generate the code from the designer
  • Now if you launch the project, the image's color will now be all wrong on the board

I still have no clue on what's causing this. I've attached to this anwser the project after all those steps (you can also find the image I used in there).

Tristan

MM..1
Chief II

I write this here more time, that target folder generated with touchgfx is different as generated with cubemx, and too cubemx overwrite target files usw.

Example stesp for reproduce i have project 4.13 and upgrade step by step to 4.16 without use cubemx in upgrade steps. I check target folder and files between version stay ok. After this i open cubeMX and reconfigure touchgfx too to 4.16 and generate. Now files in terget folder is changed and for me dont work ok. I use RGB888 , but i mean this is maybe source with colour 565 troubles.

Too every version with combination MX IDE Touch have more bugs and troubles. When your project work ok before MX then create backup and after MX compare repair. This ST combined sw never will work 100%.

Hi,

If you use a textureMapper widget instead of an Image widget the colors will be properly displayed. I will further investigate but my first guess is that this could be related to the DMA2D and ChromART. I know there has been a lot of work in the coming version 4.17 to stabilise ChromART to fix this kind of bugs.

For now I can recommend to use textureMapper widgets for the L8 images if relevant in your project.

/Romain

Ok so I just tried disabling ChromART in STM32CubeMX and the L8 images are properly displayed even when using an Image widget.

So either use TextureMapper widgets or disable ChromART (which will lower the performances, but this could be acceptable depending on what you aim to do)

/Romain

TDele.1
Associate III

Hello,

I've tried changing the background image from an image widget to a texture mapper and although the colors are now correct, the slide screen transitions are now slowing down a lot which makes this solution not ideal for my application. I would also wish to use L8_RGB565 format for animated images where the workaround you have given me is not usable. I've also tried disable ChromART in CUBE MX and, while the images are now displayed properly, the slide screen transitions are now not working as expected ....

Tristan

Last resort could be to try using TouchGFX 4.15 instead, since the ChromART changes were made in TouchGFX 4.16.

/Romain

TDele.1
Associate III

I'v tried doing the steps explained before to test the L8_RGB565 format image color and altough the colors are correct, when I try to add a slide screen transition, It's also very slow just like before. I've also made my main project on version 4.16.1 meaning I cannot open it with version 4.15 so do I have to remake my project from the start over on version 4.15 ? Is'nt there any other better alternative to have both the L8_RGB565 image format and slide screen transition working properly ?

Tristan

From what you are describing there must be ways to optimize your UI in itself as well to improve the performances. Do you really need to do a slide transition of the background ? It is very slow because of the load on the MCU of this type of animation with a texture mapper. A cover transition would improve the performances. Is the screen you are going to using the same background image ? You could fake the slide animation by just sliding in and out widgets instead and having the background not move.