cancel
Showing results for 
Search instead for 
Did you mean: 

How to read UID in STM32L476

mangesh1
Associate II

Hi,

How to set UID using CubeMX and read in STM32L476 and use it for device commissioning process?

1 ACCEPTED SOLUTION

Accepted Solutions
MHoll.2
Senior III

The UID is not handle by CubeMX, you have to access the 3 registers by yourself. Se Chapter 49.1 in the Reference Manual RM0351

View solution in original post

4 REPLIES 4

Hi NHoLL.2,

I read that post but CubeMX options are not available in my STM32L476(Nucleo-L476R) series.

MHoll.2
Senior III

The UID is not handle by CubeMX, you have to access the 3 registers by yourself. Se Chapter 49.1 in the Reference Manual RM0351

TDK
Super User

UID cannot be set. It can only be read. The STM32L476 does have a UID.

HAL_GetUIDw0/HAL_GetUIDw1/HAL_GetUIDw2 will read the three 32-bit parts of it.

If you feel a post has answered your question, please click "Accept as Solution".