cancel
Showing results for 
Search instead for 
Did you mean: 

STM32H7B0 - Identifying cause of display artifact - black lines when invalidating.

Tycho94
Associate

Hi everyone, I have an display driving issue causing some unwanted artifacts. 

 

Some context information about my platform. I'm running an STM32H7B0. My binary is stored on an external octospi (quad mode) memory (not just the resources of TouchGFX). My frame buffer is entirely in internal RAM. I have configured the LTDC to drive a 480x800 display at 16bpp.  I have also enabled DMA2D with a M2M configuration. Finally, my system is running FreeRTOS as an OS. This all is set up with the CubeMX generator. 

 

The issue I am facing is that some image elements on my display seem to sometime flicker when invalidated. These elements will have some black lines through them. See attached image for the black lines though the round image objects on my display. 

Some points I have looked at so far: I am invalidating my cache after the generated hal performs the flushFrameBuffer. I have my MPU setup to avoid speculative accesses on my OSPI memory range. 

 

Any suggestions to help me identify what the cause could be of this issue?

3 REPLIES 3
PeterVang
ST Employee

Hi,

From the photo you have shared, it looks errors when reading assets from the flash when writing the frame buffers.

Do the glitches only appear on the image assets? Or can they also occur on e.g. simple box widgets?

Do the glitches appear in the same locations? Or do they change when the same widgets are re-rendered?

Best regards,

Peter

Hi Peter,

Thanks for the response. To answer your questions: 

  • The glitches seem to appear only on image assets.
  • The lines inside of the images are not in the same location and constantly move around  when redrawn/invalidated. When not invalidated they remain the same. 

After some playing around, moving my system to L8 compression for images as default removes the artifact. 

 

This did introduced a new artifact when changing views with equivalent content, or invalidating a larger part of the screen content. 

Elements that are invalidated, even though the content is the same or similar seem to flicker a bit. There is a short time where the pixels go black before redrawing the same content. It is noticeable by eye as if the display is 'flickering' on just those pixels. Is this something that is more common to your knowledge?

PeterVang
ST Employee

Based on your two answers, it sounds like there is a problem with reading data correctly from your external flash. Are you able to test this outside TouchGFX? You say that your binary also is in the external flash and not just your assets. Does this mean that you are executing directly from the same external flash or do you do some sort of Load-and-RUN?

I do not fully understand your description of the new glitches you see when switching to compressed L8 image format. Does this mean that the glitches only occur while the display is updated (invalidated) and then always ends on a glitch free image?

Are you using single or double framebuffer strategy?