Skip to main content
Graduate
February 7, 2024
Solved

What is VDDA_Charac on the STM32F072?

  • February 7, 2024
  • 1 reply
  • 2761 views

Apologies if I've missed something simple (and I probably have!), but I'm trying to convert ADC readings on the STM32F072 into actual millivolts and I cannot seem to put all the pieces together.

Where I am currently stuck is the formula at the top of page 260 in the reference manual RM0091 Rev 10:

VDDA = VDDA_Charac x VREFINT_CAL / VREFINT_DATA

According to the note just under that formula, "VDDA_Charac is the value of VDDA voltage characterized at VREFINT during the manufacturing process. It is specified in the device datasheet."

I've been all over the STM32F072xB (DS9826 Rev 6) datasheet and I cannot find any reference to such a thing as VDDA_Charac or the voltage at which the VREFINT_CAL is characterized at. Am I supposed to assume it is 3.3V? Is there some constant in the HAL that I should be referencing? I found a "VDD_VALUE" in stm32f0xx_hal_conf.h, but I don't think that's it.

Thank you for any guidance you can provide.

 

    This topic has been closed for replies.
    Best answer by TDK

    The VREFINT_CAL value is taken when VDDA = 3.3V. This is the voltage it's referring to.

    TDK_0-1707322224258.png

     

    1 reply

    TDKAnswer
    Super User
    February 7, 2024

    The VREFINT_CAL value is taken when VDDA = 3.3V. This is the voltage it's referring to.

    TDK_0-1707322224258.png

     

    BWKiddAuthor
    Graduate
    February 7, 2024

    Thank you TDK! I knew it was simple/*** on my part.

    Visitor II
    February 10, 2024

    Check, if you have already the macros provided to do all this calibration and conversion, e.g. on my STM32U5xx with ADC I use this:

    VRefInt 	= __HAL_ADC_CALC_VREFANALOG_VOLTAGE(hadc, ADC_Val[0], hadc.Init.Resolution);
    	VBat 		= __HAL_ADC_CALC_DATA_TO_VOLTAGE(hadc, VRefInt, ADC_Val[1], hadc.Init.Resolution);
    	TSensor	 = __HAL_ADC_CALC_TEMPERATURE(hadc, VRefInt, ADC_Val[2], hadc.Init.Resolution);

    This should take already the formula and the CALibration into account.