2019-12-04 01:20 AM
To eliminate the bad effect at the power-on with TouchGFX applications make these modifications.
1) locate the main.cpp and add these two HAL_CPIO_WritePin() call.
/* Initialise the graphical hardware */
GRAPHICS_HW_Init();
/* Assert display enable LCD_DISP pin */
HAL_GPIO_WritePin(GPIOI, GPIO_PIN_12, GPIO_PIN_RESET);
/* Assert backlight LCD_BL_CTRL pin */
HAL_GPIO_WritePin(GPIOK, GPIO_PIN_3, GPIO_PIN_RESET);
/* Initialise the graphical stack engine */
GRAPHICS_Init();
2) in the file relative to the main screen, in my case is Screen1View.cpp add these two lines
void Screen1View::setupScreen()
{
/* Assert display enable LCD_DISP pin */
HAL_GPIO_WritePin(GPIOI, GPIO_PIN_12, GPIO_PIN_SET);
/* Assert backlight LCD_BL_CTRL pin */
HAL_GPIO_WritePin(GPIOK, GPIO_PIN_3, GPIO_PIN_SET);
Screen1ViewBase::setupScreen();
}
2020-01-09 12:28 AM
All application templates (some already do) will be updated to have something like what you're describing. The change to the framework was made to not have to render unnecessarily, but it is not described clearly anywhere when it is the best to turn on the display.
/Martin