cancel
Showing results for 
Search instead for 
Did you mean: 

Video decoding for STM32H7B3L.

ABURM
Associate III

Hi.

I am using SDRAM, OctoSPI and 24bit RGB888 TFT screen. Project is working normally with another widgets (button, shape, text area, image etc.). Now i want to use video decoding and video widget. I made the necessary cubemx settings by reading the Video decoding. application steps. As a trial, I prepared a project consisting of 4 images and one video (sample video in touchgfx) in touchgfx. There are 5 screens in the project. Screen1, screen2, screen3, screen4 and screen5. I play the video after showing the images at 2-second intervals. The video widget is in the 5th screen. The program works properly until the 4th screen. But when it comes to the part of playing the video, it going to the "hardfault" procedure. I think I'm making a mistake with the memory settings. Cubemx settings are as follows;

DMA2DDMA2DJPEGJPEGJPEG-MDMAJPEG-MDMAJPEG-MDMAJPEG-MDMALIBJPEGLIBJPEGRTOS-TASKRTOS-TASKRTOS-HEAPRTOS-HEAPTouchGfxTouchGfx

I added the following code in STM32H7B3LIHXQ_FLASH.ld.

MEMORY
{
  ...
  SDRAM      (xrw)    : ORIGIN = 0xD0200000,   LENGTH = 8M
}

BufferSection (NOLOAD) :
{
  *(Video_RGB_Buffer Video_RGB_Buffer.*)
  *(.gnu.linkonce.r.*)
  . = ALIGN(0x4);
} >SDRAM

Where am i making a mistake?

1 REPLY 1
ABURM
Associate III

Hi.

After many tries I finally got it to work. But there are a few problems.  I made the necessary rtos settings but video decoding strategy does not work in single or double buffer mode. Also, I cannot use video decoding type as hardware. It only works in "software - direct to framebuffer" mode.

I want to use "hardware - double buffer" for better performance but not working. When I select hardware mode, no image appears on the screen (white screen). Program is not working. I am using "double buffer" for frame buffer strategy in display configuration. Start address ==> 0xD0000000000 and Start address 2 => 0xD0119400. How do single and double buffer modes work for video decoding? How do I use video decoding in hardware mode? I read the application notes and training documents, but I did not fully understand it. 

Does anyone have information on this subject?