Skip to main content
Vdand.11
Visitor II
December 9, 2022
Question

change screens from HAL_UART_Rxcpltcallback/ hardware button click

  • December 9, 2022
  • 1 reply
  • 715 views

i got STM32F401 and ST7735. 1.8inch TFT but NO touch, i am trying to setup two screens and switch between them. so i decided to used physical button over interrupt / UART. i made necessary callbacks and able to alter a flag. now the question is how to link it to touchgfx? where to edit the code.? i have alredy created hardware button clicked event but for some reason its not switching from home screan to screen 2. my call backs are working perfect toogling the LEDs . but the screan is not changing.

This topic has been closed for replies.

1 reply

Romain DIELEMAN
ST Employee
December 12, 2022

Hi,

I often recommend looking at this video from Gustavo explaining how to communicate between the hardware and TouchGFX with the Model-View-Presenter architecture. Instead of turning on and off a led you just call the change screen function. Or is this what you were referring to already by talking about the LED toggling ? Could you share the code in that case on how you call the change screen functions ? Does it work in the simulator ?

/Romain