cancel
Showing results for 
Search instead for 
Did you mean: 

Read 96 bit UDID through serial bootloader or SWD

machinist
Associate III

Hello,

I am working on the STM32F103xx. I need to read out the 96 bit UDID (unique device ID) of the devices during production. Is there any way of reading this out from the serial bootloader on UART1 or through the SWD interface?

I searched the AN3155 and AN2606 but could not find any details.

I do not want to flash a temporary firmware just to read it out and then overwrite it again. Nontheless it no other solution is possible I guess its an ugly workaround. It needs to be automated. So using CubIDE is not possible.

Thanks

1 ACCEPTED SOLUTION

Accepted Solutions
TDK
Guru

SWD can also do it easily.

STM32_Programmer_CLI.exe -c port=swd --upload 0x1FFFF7E8 12 uid.bin

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

View solution in original post

5 REPLIES 5
TDK
Guru

The Read Memory command in the bootloader can read this.

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

SWD can also do it easily.

STM32_Programmer_CLI.exe -c port=swd --upload 0x1FFFF7E8 12 uid.bin

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

Perfect, thank you!

Hello,

in which document is this address actually described/noted?

For the F1 RM0008  "Unique device ID register (96 bits)"

https://www.st.com/resource/en/reference_manual/rm0008-stm32f101xx-stm32f102xx-stm32f103xx-stm32f105xx-and-stm32f107xx-advanced-armbased-32bit-mcus-stmicroelectronics.pdf

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..