Skip to main content
kk2
Associate II
October 10, 2019
Question

FrameBuffer no data

  • October 10, 2019
  • 8 replies
  • 4499 views

Hello,

i try to start application on STM32F7 with external RAM.

I setup frame buffer and cache in external RAM, but touchgfx not loading screen to FrameBuffer, Cache is loading.

I check if image will render when a set start address of cache and FrameBuffer the same and it worked.

What may be source of the problem?

This topic has been closed for replies.

8 replies

Martin KJELDSEN
Principal III
October 10, 2019

Hi,

What cache? Bitmap cache?

/Martin

kk2
kk2Author
Associate II
October 10, 2019

Yes, Bitmap cache.

Martin KJELDSEN
Principal III
October 10, 2019

By LTDC configuration i also mean timings / porch settings - Do you have that right as per the display datasheet? is 0xc0000000 also set as the start address for touchgfx in the generated code? Is touchgfx configured to use LCD24 as its display driver? (given the RGB888 configuration ?

Your blending factors should be Alpha constant x Pixel Alpha, but that's not the cause of your issues.

/Martin

kk2
kk2Author
Associate II
October 10, 2019
  • By LTDC configuration i also mean timings / porch settings - Do you have that right as per the display datasheet?

YES

  • is 0xc0000000 also set as the start address for touchgfx in the generated code?

YES

  • Is touchgfx configured to use LCD24 as its display driver? (given the RGB888 configuration ?

0690X00000ApO5WQAV.jpg

HP_it
Senior II
October 10, 2019

HAH! that looks exactly like what I was having a few days ago!

have you checked that your 'defaultTask' have a heap size that is big enough? CubeMX sets the size to 128 (words) by default. try to change this to 4096 - maybe that is the only thins you need.

My process was first to check the SDRAM using one of the example projects - there's an example that loads the external ram with the values from 0-4095 (starting at 0xC00000800 - there's an offset). If that works, then check the RTOS task settings :)

HP_it
Senior II
October 10, 2019

I will be making a video on this very soon!

kk2
kk2Author
Associate II
October 10, 2019

Unfortunately changing stack size of 'defaultTask' didn't help. It looks like SDRAM is working.

HP_it
Senior II
October 10, 2019

Could be your refresh count then. From your previous images it is set to 1752 - This value is greyed out so it's set somewhere else.

I recall that I ended up changing this manually. If you got the SDRAM example running then check the SDRAM settings up against the ones you're using on your touchGFX implementation.

Do you know that the display is working? Ie. did you try to load a static image up from the internal memory first? if not it could be the display timings. App not 4861 is a good place to start for this if you need more info.

Getting the display/SDRAM/framebuffer combo to run is a bit finicky and I just spend the better part of a week making my concoction work as I wanted.

HP_it
Senior II
October 10, 2019

I have made a video with a walkthrough on how I set up the Display to test that out. It's a bit long (and a bit of a ramble I think) but It should cover the display basics.

I have also made another video on how to test the SDRAM and set it up.

I would suggest that you try out the method of setting an image (not the layer background color) in the internal flash memory and load that up (see the first video and/or app note 4861 on that).

when you have verified that, go on to the SDRAM. Again, I suggest that you test it with the F7 repository example for the FMC interface.

I have found that you would need to change the following to get the SDRAM working (not in that order)

  1. check that the appropriate interrups are enabled
  2. check the REFRESH_COUNT (mine magically 1292 - I'm not sure about that calculation though)
  3. set the 'defaultTask' stack size to 4096
  4. IMPORTANT: Increase the minimal heap size to something bigger than 4096*4 - I set mine to 32768 just to be sure.

My videos on the subject are available here:

Hardware setup and configuring the LTDC interface - https://youtu.be/GxUpMrnIwpo

Setting up the SDRAM interface and testing it out - https://youtu.be/DNujNps9BWo

I hope this will help you out!

kk2
kk2Author
Associate II
October 11, 2019

Thank you for help �?��?

I will look at yours videos.

kk2
kk2Author
Associate II
October 11, 2019

It looks like the main problem was poorly soldered uP and SDRAM. Because of it data was corrupted.

Thank you @HP​ so much for the help you gave me this week. I greatly appreciate the assistance you have provided me. It was very useful.

GMano.1
Associate III
June 20, 2021

Hai...,

I am also facing same problem.

STM32F746IG (waveshare Development board) with 7 inch display.

I done every thing @HP​ (Community Member)​ but still have a same problem.

pLayerCfg.FBStartAdress = (uint32_t) & Image_data_image_Text; it work fine.

But if i change bellow address.

pLayerCfg.FBStartAdress = 0xD0000000; not working display image below (i am using bank2 so that use this Frame Buffer Start Address).

0693W00000BbSdsQAF.jpg

What are cause of this issuse?

Martin KJELDSEN
Principal III
June 21, 2021

Can you inspect that memory? Is anything actually being drawn? Maybe the display is showing the correct content (garbage).

TouchGFX HAL will set up the start address of the LTDC layer automatically based on what you set up TouchGFX with, so you shouldn't need to do this.

Can you show me your TouchGFX Configuration? If TouchGFX does not know about this address as the framebuffer address it won't render anything to it.

Let me know-.

/Martin