Skip to main content
February 15, 2020
Question

Image defect

  • February 15, 2020
  • 19 replies
  • 5786 views

Look at the project

0690X00000DBDE5QAP.png

and look at the display

0690X00000DBDEFQA5.jpg

You can see artefacts.

Why?

This topic has been closed for replies.

19 replies

February 16, 2020

Hm.... I can delete vertical lines near pictures if I use 32-bit SDRAM as 16-bit (I reconfigured FMC). But I want to use all 32 bit. Is it bug of your library?

And stripes on circle still present, even in 16 bit mode....

February 16, 2020

Stripes on circle disappeared, if I use RGB565...

But I want RGB888.

How?

Romain DIELEMAN
ST Employee
February 17, 2020

Just to be sure, could we see your code? It might be due to some missing invalidated widgets. If not, some more details on your project would be useful to have a better insight of this issue. Thanks,

/Romain

February 17, 2020

Thanks!​

I will upload code in the evening, since 7 hour after this post.

Look at this topic later, please.​

Martin KJELDSEN
Principal III
February 17, 2020

Please provide more details on which MCU you're working with, how you created the project, etc.

Thanks

/Martin

February 17, 2020

Stm32f746be, ​MT48LC4M32B2P-6A 

Project created with cumbeMX 5.5 and last version of touchgfxdesigner.

I'll upload project here later.​

February 17, 2020

YESS!

Half of problem solved!!!!!

CubeMX hasn't automatically generated MPU_Config for SDRAM! It generated it only for qSPI (address 0x90000000)

I added this code

void MPU_Config(void)
{
 MPU_Region_InitTypeDef MPU_InitStruct = {0};
 
 /* Disables the MPU */
 HAL_MPU_Disable();
 /** Initializes and configures the Region and the memory to be protected 
 */
 MPU_InitStruct.Enable = MPU_REGION_ENABLE;
 MPU_InitStruct.Number = MPU_REGION_NUMBER0;
 MPU_InitStruct.BaseAddress = 0xD0000000;
 MPU_InitStruct.Size = MPU_REGION_SIZE_16MB;
 MPU_InitStruct.SubRegionDisable = 0x0;
 MPU_InitStruct.TypeExtField = MPU_TEX_LEVEL1;
 MPU_InitStruct.AccessPermission = MPU_REGION_FULL_ACCESS;
 MPU_InitStruct.DisableExec = MPU_INSTRUCTION_ACCESS_ENABLE;
 MPU_InitStruct.IsShareable = MPU_ACCESS_NOT_SHAREABLE;
 MPU_InitStruct.IsCacheable = MPU_ACCESS_CACHEABLE;
 MPU_InitStruct.IsBufferable = MPU_ACCESS_BUFFERABLE;
 
 HAL_MPU_ConfigRegion(&MPU_InitStruct);
 /** Initializes and configures the Region and the memory to be protected 
 */
 MPU_InitStruct.Enable = MPU_REGION_ENABLE;
 MPU_InitStruct.Number = MPU_REGION_NUMBER1;
 MPU_InitStruct.BaseAddress = 0xD0000000;
 MPU_InitStruct.Size = MPU_REGION_SIZE_2MB;
 MPU_InitStruct.SubRegionDisable = 0x0;
 MPU_InitStruct.TypeExtField = MPU_TEX_LEVEL1;
 MPU_InitStruct.AccessPermission = MPU_REGION_FULL_ACCESS;
 MPU_InitStruct.DisableExec = MPU_INSTRUCTION_ACCESS_DISABLE;
 MPU_InitStruct.IsShareable = MPU_ACCESS_NOT_SHAREABLE;
 MPU_InitStruct.IsCacheable = MPU_ACCESS_CACHEABLE;
 MPU_InitStruct.IsBufferable = MPU_ACCESS_BUFFERABLE;
 
 HAL_MPU_ConfigRegion(&MPU_InitStruct);
 /** Initializes and configures the Region and the memory to be protected 
 */
 MPU_InitStruct.Enable = MPU_REGION_ENABLE;
 MPU_InitStruct.Number = MPU_REGION_NUMBER2;
 MPU_InitStruct.BaseAddress = 0xD0200000;
 MPU_InitStruct.Size = MPU_REGION_SIZE_2MB;
 MPU_InitStruct.SubRegionDisable = 0x0;
 MPU_InitStruct.TypeExtField = MPU_TEX_LEVEL1;
 MPU_InitStruct.AccessPermission = MPU_REGION_FULL_ACCESS;
 MPU_InitStruct.DisableExec = MPU_INSTRUCTION_ACCESS_DISABLE;
 MPU_InitStruct.IsShareable = MPU_ACCESS_NOT_SHAREABLE;
 MPU_InitStruct.IsCacheable = MPU_ACCESS_CACHEABLE;
 MPU_InitStruct.IsBufferable = MPU_ACCESS_BUFFERABLE;
 
 HAL_MPU_ConfigRegion(&MPU_InitStruct);
 /** Initializes and configures the Region and the memory to be protected 
 */
 MPU_InitStruct.Enable = MPU_REGION_ENABLE;
 MPU_InitStruct.Number = MPU_REGION_NUMBER3;
 MPU_InitStruct.BaseAddress = 0x90000000;
 MPU_InitStruct.Size = MPU_REGION_SIZE_256MB;
 MPU_InitStruct.SubRegionDisable = 0x0;
 MPU_InitStruct.TypeExtField = MPU_TEX_LEVEL0;
 MPU_InitStruct.AccessPermission = MPU_REGION_NO_ACCESS;
 MPU_InitStruct.DisableExec = MPU_INSTRUCTION_ACCESS_DISABLE;
 MPU_InitStruct.IsShareable = MPU_ACCESS_NOT_SHAREABLE;
 MPU_InitStruct.IsCacheable = MPU_ACCESS_NOT_CACHEABLE;
 MPU_InitStruct.IsBufferable = MPU_ACCESS_NOT_BUFFERABLE;
 
 HAL_MPU_ConfigRegion(&MPU_InitStruct);
 /** Initializes and configures the Region and the memory to be protected 
 */
 MPU_InitStruct.Enable = MPU_REGION_ENABLE;
 MPU_InitStruct.Number = MPU_REGION_NUMBER4;
 MPU_InitStruct.BaseAddress = 0x90000000;
 MPU_InitStruct.Size = MPU_REGION_SIZE_16MB;
 MPU_InitStruct.SubRegionDisable = 0x0;
 MPU_InitStruct.TypeExtField = MPU_TEX_LEVEL0;
 MPU_InitStruct.AccessPermission = MPU_REGION_PRIV_RO;
 MPU_InitStruct.DisableExec = MPU_INSTRUCTION_ACCESS_DISABLE;
 MPU_InitStruct.IsShareable = MPU_ACCESS_NOT_SHAREABLE;
 MPU_InitStruct.IsCacheable = MPU_ACCESS_CACHEABLE;
 MPU_InitStruct.IsBufferable = MPU_ACCESS_NOT_BUFFERABLE;
 
 HAL_MPU_ConfigRegion(&MPU_InitStruct);
 /* Enables the MPU */
 HAL_MPU_Enable(MPU_PRIVILEGED_DEFAULT);
 
}

And stripes on circle disappears! And other widgets looks very well.

But stripes near widgets still present.

Look to the code, that i posted (MPU_Config) May be something still wrong?

February 18, 2020

I disabled ChromeART (DMA2D) in CubeMX options - artifacts disappeared.

Tell me, what's may be wrong with ChromeART (DMA2D) ???? How to fix?

February 18, 2020

Here is my DMA2D options

0690X00000DBl6oQAD.png

February 18, 2020

Anybody help me!!!

ATara.3
Associate
April 10, 2020

I have the same problem. Moreover, once out of ten when loading these strips do not occur, and then the entire interface works normally. I use STM32F769 Disco + STM32CubeIDE + TouchGFX 4.13. At first I thought the board was defective and bought another one. The result is the same.

Martin KJELDSEN
Principal III
April 30, 2020

The DMA2D configuration will be "overwritten" by the TouchGFX HAL when doing DMA2D transfers because it knows the pixel formats of whats coming in and whats going out. I haven't seen this issue but i'll try your concrete project.