Skip to main content
kamin
Associate
February 13, 2022
Question

Configuring a project (generated by TouchGFX) using CubeMX leads to linker errors like " undefined reference to `HAL_ADC_Init' "

  • February 13, 2022
  • 3 replies
  • 1760 views

I have an STM32H745I-disco board. I created a TouchGFX project for it (with some simple graphical objects). Then I imported it to CubeIDE. At first, the project could be built without error. But after enabling an ADC module I got a linker error undefined reference to `HAL_ADC_Init'.

TouchGFX version: 4.18.1

STM32CubeIDE version : 1.8

The project is attached.

This topic has been closed for replies.

3 replies

Osman SOYKURT
ST Technical Moderator
February 17, 2022

Hello kamin,

Unfortunately I can't help much with your issue, it's more related to STM32CubeMX and STM32CubeIDE. I invite you to add more tags (like ADC, STM32H745I-disco or STM32CubeMX), to your post to make it more visible and hopefully someone on the community can help on that.

By the way, have you tried to see examples using ADC ? When you download STM32CubeMX, you've been given multiple examples of board usage. For your STM32H745I-disco board, I think you can found them at the path :

C:\Users\YOUR_USER_NAME\STM32Cube\Repository\STM32Cube_FW_H7_V1.9.1\Projects\STM32H745I-DISCO\Examples\ADC

Hope this help :)

/Osman

ST Software Developer | TouchGFX
kamin
kaminAuthor
Associate
February 23, 2022

Hello Osman,

Thanks for your reply and for adding tags.

I don't have any problem using ADCs, I mean I can use them in a usual project. But, as I said enabling ADC when the project is generated by TouchGFX Designer causes some errors.

I think it's a bug related to TouchGFX Designer.

Zu_it
Associate II
April 22, 2022

I have the same problem, even using the last version of stm32ide and touchgfx I get this issue