Skip to main content
Visitor II
October 18, 2024
Solved

Code Generation Bug STM32U5 with VDDA

Hello! I believe I found a code generation bug. I am currently using IDE version 1.16.1.

By default, when enabling ADC with an STM32U5, HAL_MSPInit() has the line: HAL_PWREx_EnableVddA() which is necessary to have a positive reference for the ADCs (the U5 series has some internal switch to enable VDDA)

However, when enabling the feature "Generate peripheral initialization as a pair of '.c/.h' files per peripheral", the generated code removes the VDDA Enable line from HAL_MSPInit(). This makes the same ADC code fail to start (and lead to many hours of debugging).

Hoping someone at ST can confirm this (and push a fix) to confirm the root cause!

 

 

This topic has been closed for replies.
STTwo-32
STTwo-32Best answer
ST Technical Moderator
October 19, 2024

Hello @rgangwan and welcome to the ST Community :smiling_face_with_smiling_eyes:.

I confirm this code generation error, and I've escalated for correction on the future (under internal ticket number 186561). 

PS: Issue solved on the last release of the STM32CubeMX

Best Regards.

STTwo-32 

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.

2 replies

STTwo-32
STTwo-32Best answer
ST Technical Moderator
October 19, 2024

Hello @rgangwan and welcome to the ST Community :smiling_face_with_smiling_eyes:.

I confirm this code generation error, and I've escalated for correction on the future (under internal ticket number 186561). 

PS: Issue solved on the last release of the STM32CubeMX

Best Regards.

STTwo-32 

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
Ghofrane GSOURI
ST Technical Moderator
October 21, 2024

Hello @rgangwan @STTwo-32 

Thank you for having reported.
I assume this is the exact same issue already reported to the development team and tracked by the Ticket 186561 and that will be fixed as soon as possible.

THX

Ghofrane

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.