cancel
Showing results for 
Search instead for 
Did you mean: 

STM32U5 ADC VREFINT_CAL_ADDR

cpegeo
Associate

The #define value for VREFINT_CAL_ADDR in the stm32u5xx_ll_adc.h HAL file has an odd value address (0x0BFA 07A5). This causes attempts to access the value to fault with an unaligned access. I have checked for other devices (STM32F4, STM32L0, Etc.) and these all have even values for the address. Can we please update to the correct address. Thanks.

2 REPLIES 2
STTwo-32
ST Employee

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

According to the RM0456, the Memory address of the VREFINT_CAL is 0x0BFA 07A5 which makes the value mentioned in the stm32u5xx_ll_adc.h is right.

STTwo32_0-1702624819386.png

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.

I agree with you that this is the correct value. But that isn't the issue. The issue is that this causes attempts to access the value to fault with an unaligned access.

E.g.
uint16_t calValue = *VREFINT_CAL;  //< FAILS WITH UNALIGNED ACCESS.

What is the correct way to access this value then?