Skip to main content
PPate.1
Associate III
April 2, 2025
Solved

Function HAL_PWREx_EnableVddUSB() for STM32C0 series MCU

  • April 2, 2025
  • 1 reply
  • 568 views

Hi,

I am implementing USB CDC ACM on my custom board using STM32C071x series of microcontroller. It is currently not working and looking at other post on community I observed that one of the problem is of missing call to function - HAL_PWREx_EnableVddUSB(). is this function call necessary for all series of STM32 microcontrollers?

If that is the case then it is missing in my auto generated code from CubeMX. I also tried manually adding it but it is giving me compilation error - 'undefined reference to `HAL_PWREx_EnableVddUSB'

Thanks,

Pradeep

This topic has been closed for replies.
Best answer by AScha.3

Hi,

so for the ..PWREx... look in the HAL driver, what functions are there - for your chip !

Maybe it has other name or this chip dont have it at all...

here, you can see, whats in the driver:

AScha3_0-1743578237251.png

 

+

To know, whether USB is "ON" , look in debug at the "SFR" , then registers for USB , and see, what is there .

So you can find out, whats wrong; just read in rm, what should be in registers / their meaning.

1 reply

AScha.3
AScha.3Best answer
Super User
April 2, 2025

Hi,

so for the ..PWREx... look in the HAL driver, what functions are there - for your chip !

Maybe it has other name or this chip dont have it at all...

here, you can see, whats in the driver:

AScha3_0-1743578237251.png

 

+

To know, whether USB is "ON" , look in debug at the "SFR" , then registers for USB , and see, what is there .

So you can find out, whats wrong; just read in rm, what should be in registers / their meaning.

If you feel a post has answered your question, please click on " Best Answer ".