cancel
Showing results for 
Search instead for 
Did you mean: 

TouchGFX / Hardware integration tutorials

LAlna.1
Associate II

Hi there

I have been experimenting and creating simple TouchGFX GUI applications on STM32 touch screen dev kit.

Is there a simple start guide to creating as simple touchGFX GUI and controlling an LED on the STM32F429i Disco board? I tried some online examples/Youtube but they never seem to work properly.

TouchGFX websites contains good tutorials but they don't include HAL integration and control (as far as I have seen)

To keep it simple, I use ST32CubeMX, TouchGFX designer, and ST_link Utility to flash the board.

Any simple code would be a great help

Thanks

19 REPLIES 19
Alexandre RENOUX
Principal

Hello,

What's your current status ?

/Alexandre

LAlna.1
Associate II

Hi Alexandre

I gave up on the development to be honest, it wasn't as straight through process as I hoped it would be.

I loved the GFX interface, but the library and the examples were too vague to integrate the TouchGFX to the actual STM32 board. Unless you have a direct example I can follow to get a bearing on that process? I use the STM32F4 at work , so I am familiar with the IC

Regards

LAlna.1
Associate II

Follow up:

A simple example of a touch application that would turn on a LED would be perfect.

GAuye
Associate III

Totally agree.... I have spend 3 day looking for a simple but complete example, with no result. An it is very important to undersand how CubeMX could be integrated. The folder structure created by TouchGFX is completly different comparing with CubeMX and there is now way to integrate the three tools (TouchGFX, CubeMX and CubeIDE) CubeMX is very important if we need to use other perifericals in the same board (unless you do it by hand, witch means a lot of time an efford) Thanks for you help!!!!

RMega.1
Associate

hi i've same problem with u im beginner when first time using c# gui. but ithink u can keep learn on https://create.arduino.cc/projecthub/haoming-weng/c-arduino-gui-to-control-the-led-0877f8. how to configure c# gui to hardwere include STM32.....

I think u may try just STM32CUBEIDE ,because its include stm32cubemx inside.hopefully your pc can run easily.

MM..1
Chief III

LED is simple you can implement it as action on buttons on screen directly or as if gpio button in model tick example

if ((HAL_GPIO_ReadPin(SW3_GPIO_Port, SW3_Pin) == GPIO_PIN_RESET && filter == false && timeout1.t == 0) ) 

 {

  filter = true; //block hold gpio key down repeat

  static_cast<FrontendApplication*>(Application::getInstance())->handleKeyEvent(73); // call to action asigned to symbolic keyboard keycode event KEY 73

// gpio led directly here ...

 }

Project create steps:

  1. CubeIDE create new project with MX ioc
  2. inside IDE open ioc and in MX configure and generate code
  3. instal touchGFX module and app (manual install need) when dont installed
  4. repeat edit ioc and add touchGFX part config generate code
  5. open from IDE touchGFX part and create project ... design some ... generate code
  6. back in IDE edit main code add touch process ... build and test LCD
  7. when LCD dont work block RTOS start and in main before it test all parts ram ltdc ...
LAlna.1
Associate II

Thanks but I need a bit more detail, as I have tried that approach and I have apps running on the STM32 but no interaction between the HAL layer and app works.

GAuye
Associate III

Hello regarding the Project creation, here are my comments:

Project create steps:

  1. CubeIDE create new project with MX ioc--- OK
  2. inside IDE open ioc and in MX configure and generate code--- OK
  3. instal touchGFX module and app (manual install need) when dont installed---Ok
  4. repeat edit ioc and add touchGFX part config generate code--- Not clear what you mean in this step
  5. open from IDE touchGFX part and create project ... design some ... generate code--Ok
  6. back in IDE edit main code add touch process ... build and test LCD-- I have not added nothing just test it... and it is not working. BSP folder is missing (not generated) and this, I think, is the problem. This is also showed in MOOC part 3 from STM, but it is not clear how to solve it. (just to clarify, if I start from Touch GFX, I can compile and run it into the Discovery, but I want to use the ioc file in order to add some others periphericas and not do it by hand...)
  7. when LCD dont work block RTOS start and in main before it test all parts ram ltdc ... --- Could you please explain with more datails...

Thanks for you help, appreciated!!!!!