Issue with multilayer on STM32F746

This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

  • Issue with multilayer on STM32F746

    Hello. I use STM32F746 Discovery with STemWin last version. When I start a project STM32746G-Discovery\Applications\STemWin\STemWin_HelloWorld\EWARM\Project.eww it works well. But after changing GUI_NUM_LAYERS value to 2 I see following
    : [img]http://s009.radikal.ru/i307/1610/31/2431b93f7e6e.jpg[/img]

    Could you please tell me how to configure multiplayer correctly??(
  • Hi!
    try following:
    1. File GUIConf.c - change

    C Source Code

    1. static __no_init U32 aMemory[GUI_NUMBYTES / 4];

    to

    C Source Code

    1. #pragma location=0xC0500000
    2. static __no_init U32 aMemory[GUI_NUMBYTES / 4];

    as well increase GUI_NUMBYTES in

    C Source Code

    1. #define GUI_NUMBYTES (1024) * 1024*5

    2. lcdconf.c - in LCD_X_DisplayDriver find in case LCD_X_SETSIZE: statement

    C Source Code

    1. layer_prop[LayerIndex].xSize = ((LCD_X_SETSIZE_INFO *)pData)->ySize;
    2. layer_prop[LayerIndex].ySize = ((LCD_X_SETSIZE_INFO *)pData)->xSize;

    and change it to

    C Source Code

    1. if( LCD_GetSwapXYEx(LayerIndex) )
    2. {
    3. layer_prop[LayerIndex].xSize = ((LCD_X_SETSIZE_INFO *)pData)->ySize;
    4. layer_prop[LayerIndex].ySize = ((LCD_X_SETSIZE_INFO *)pData)->xSize;
    5. }
    6. else
    7. {
    8. layer_prop[LayerIndex].xSize = ((LCD_X_SETSIZE_INFO *)pData)->xSize;
    9. layer_prop[LayerIndex].ySize = ((LCD_X_SETSIZE_INFO *)pData)->ySize;
    10. }

    this is if you want to swap/rotate your display.

    ... and in function LCD_LL_LayerInit(U32 LayerIndex) change

    C Source Code

    1. layer_cfg.FBStartAdress = ((uint32_t)0xC0000000);

    to

    C Source Code

    1. layer_cfg.FBStartAdress = layer_prop[LayerIndex].address;


    probably you have to change

    C Source Code

    1. #if (GUI_NUM_LAYERS > 1)
    2. #define COLOR_CONVERSION_1 GUICC_M1555I
    3. #define DISPLAY_DRIVER_1 GUIDRV_LIN_16

    to the same as for layer_0 and

    C Source Code

    1. return LTDC_PIXEL_FORMAT_ARGB1555;

    to

    C Source Code

    1. return LTDC_PIXEL_FORMAT_ARGB8888;

    in the static inline U32 LCD_LL_GetPixelformat(U32 LayerIndex)

    you can find these files from my working example in attachment
    Files
    • Src.7z

      (7.82 kB, downloaded 320 times, last: )