Why does not the LCD update in STM32H747I-DISCO board?
Hi,
I made a STemWin based application for the STM32H747I-DISCO board. The app is a modified version of the STemWin_HelloWorld and GPIO_EXTI examples. The modification is simple. When the user presses the user button then the next LED is turned on and it prints the "Hello World! LEDx turned on�? message. If all the LEDs are on and the user presses the user button then all LEDs will be turned off and the LCD should show “Hello World! All LEDs turned off�? with white color. The color of the "Hello World! LEDx turned on�? message should be identical with the color of the turned on LED.
Now the problem is: when I launch the app then all the LEDs are turned off and the LCD shows the “Hello World! All LEDs turned off�? with white color. This is the default state. This is good. But if I press the user button then the next LED is turned on but the message on the LCD screen stays unchanged even the LCD screen update code runs fine, it generates the proper message, with the right color.
When the user presses a button then (See the attached picture with the main loop)
- The colorChangeRequest variable is set to -1 in the GPIO interrupt handler
- The ledStateCounter contains the ID of the turned on LED: 1 to 4 or 0 if all the LEDs are turned off.
- The ledColor variable is set to the color of the turned on LED.
- Finally, the little update code runs (once) and it should print the actual message with the right color.
- I Added GUI_Excec() after GUI_DispStringAt() function. It did not help.
The whole thing works fine but only one time, during the startup. The LCD always shows the “Hello World! All LEDs turned off�? with white color and it never changes. It does not matter how many times I press the button.
So can anybody help? What I did wrong?
Many thanks for your help. Best regards,
Louis