Hi,
I met some problem when trying to use multi layer feature on my LPC1788 board.
Basically I used three layers and I tested in the Simulator project (PC environment), it went on well
When I try to port it to the board, only the first layer was displayed, upper ones are gone.
I used GUIDRV_Lin_32_API for all layers.
Following are some piece of config code
Any help will be appreciated, thanks!
zhiying
Display All
Display All
I met some problem when trying to use multi layer feature on my LPC1788 board.
Basically I used three layers and I tested in the Simulator project (PC environment), it went on well
When I try to port it to the board, only the first layer was displayed, upper ones are gone.
I used GUIDRV_Lin_32_API for all layers.
Following are some piece of config code
Any help will be appreciated, thanks!
zhiying
C Source Code
C Source Code
- void LCD_X_Config(void) {
- const GUI_DEVICE_API * pDriver;
- int i, BitsPerPixel;
- U32 Addr;
- //
- // Check framebuffer size
- //
- #ifndef _WINDOWS
- if ((FB_XSIZE * FB_YSIZE) < (VXSIZE_PHYS * VYSIZE_PHYS)) {
- while (1); // Error, framebuffer too small
- }
- #endif
- // Video RAM start address.
- //
- // This address is only required for display drivers with memory
- // mapped video RAM like the LIN_xxx driver. It does not need to
- // be adapted for display controllers with a simple bus interface.
- //
- Addr = VRAM_ADDR_PHYS;
- //
- // Display driver configuration
- //
- for (i = 0; i < GUI_COUNTOF(_aConfigPara); i++) {
- //
- // Set display driver and color conversion for ith layer
- //
- GUI_DEVICE_CreateAndLink(_aConfigPara.pDisplayDriver, _aConfigPara.pColorConv, 0, i);
- //
- // Display driver configuration, required for Lin-driver
- //
- LCD_SetPosEx (i, _aConfigPara.xPos, _aConfigPara.yPos);
- LCD_SetSizeEx (i, _aConfigPara.xSize, _aConfigPara.ySize);
- LCD_SetVSizeEx (i, _aConfigPara.vxSize, _aConfigPara.vySize);
- LCD_SetVRAMAddrEx(i, (void *)Addr);
- LCD_SetVisEx (i, 1);
- //
- // Set user palette data (only required if no fixed palette is used)
- //
- if (_aConfigPara.pPalette) {
- LCD_SetLUTEx(i, _aConfigPara.pPalette);
- }
- //
- // Calculate video RAM address for the following layer
- //
- BitsPerPixel = LCD_GetBitsPerPixelEx(i);
- Addr += ((_aConfigPara.vxSize * BitsPerPixel) * _aConfigPara.vySize) / 8;
- }
- }
The post was edited 3 times, last by Zhiying ().