cancel
Showing results for 
Search instead for 
Did you mean: 

MX_TouchGFX_Init(); call and implementation are not the same type.

SMalo.1
Associate II

I have a build error where the call to MX_TouchGFX_Init(); in main.c (generated by Cube MX) is different than the one in app_touchgfx.h  UINT MX_TouchGFX_Init(VOID *memory_ptr);, also generated by CubeMX

I am using TouchGFX 4.19.1 in Stm32CubeIDE 1.9

Did anybody ran into that? Any suggestion?

build console output:

../Core/Src/main.c: In function 'main':

../Core/Src/main.c:135:3: error: too few arguments to function 'MX_TouchGFX_Init'

 135 |  MX_TouchGFX_Init();

   |  ^~~~~~~~~~~~~~~~

In file included from ../Core/Src/main.c:29:

../TouchGFX/App/app_touchgfx.h:45:6: note: declared here

  45 | UINT MX_TouchGFX_Init(VOID *memory_ptr);

   |   ^~~~~~~~~~~~~~~~

make[1]: *** [Core/Src/subdir.mk:59: Core/Src/main.o] Error 1

4 REPLIES 4
Yoann KLEIN
ST Employee

Hello @SMalo.1​ ,

Can you please provide more information ?

  • Which version of CubeMX are you using ?
  • Are you using ThreadX OS in your project ?
  • Have you already generated code both in CubeMX and TouchGFXDesigner ?

Thanks,

/Yoann

Yoann KLEIN
ST Software Developer | TouchGFX
SMalo.1
Associate II

Hello Yoan,

I am using stm32CubeIDE 1.9.0 with Cube MX 6.5.0.20220251

We do indeed use ThreadX in our project (AzureRTOS H7.2.0.0_M7)

No, I have never got CubeMX and TouchGFX Designer to work, we did use TouchGFX Designer to generate some code last year (without STM32CubeIDE) but this was using a Disco (STM32H747) as a target. What I am trying to do now is to use the same STM32H747 as a target, but I tell Cube MX that this is a generic STM32H747 board (I wanted to get that to work before I start on our own hardware, to validate the tools).

SMalo.1
Associate II

Adding some information that I think might be relevant:0693W00000LyKl1QAF.png0693W00000LyKlaQAF.png0693W00000LyKmdQAF.png0693W00000LyKn2QAF.png 

Any new on this.

We have the same error

MX - 6.5.0.2022.2251913

Using ThreadX OS

Have generated code from Designer and MX

Stefan