Skip to main content
Feb 15, 2020 4:44 PM UTC
Question

Image defect

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

Feb 16, 2020 11:25 AM UTC

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....

Feb 16, 2020 1:23 PM UTC

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

But I want RGB888.

How?

Romain DIELEMAN
ST Employee
Feb 17, 2020 7:32 AM UTC

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

Feb 17, 2020 7:51 AM UTC

Thanks!​

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

Look at this topic later, please.​

Martin KJELDSEN
Principal III
Feb 17, 2020 9:01 AM UTC

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

Thanks

/Martin

Feb 17, 2020 9:25 AM UTC

Stm32f746be, ​MT48LC4M32B2P-6A 

Project created with cumbeMX 5.5 and last version of touchgfxdesigner.

I'll upload project here later.​

Feb 17, 2020 3:48 PM UTC

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?

Feb 18, 2020 4:57 AM UTC

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

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

Feb 18, 2020 5:01 AM UTC

Here is my DMA2D options

0690X00000DBl6oQAD.png

Feb 18, 2020 7:49 PM UTC

Anybody help me!!!

ATara.3
Associate
Apr 10, 2020 9:15 PM UTC

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
Apr 30, 2020 10:18 AM UTC

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.