Skip to content

Commit

Permalink
chore: UniqueDeviceId to support any st mcu (#378)
Browse files Browse the repository at this point in the history
  • Loading branch information
andjordan authored Aug 14, 2024
1 parent 2835144 commit ea45ec8
Showing 1 changed file with 0 additions and 34 deletions.
34 changes: 0 additions & 34 deletions hal_st/stm32fxxx/UniqueDeviceId.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,43 +3,9 @@

namespace hal
{
#if defined(STM32F373xC)
infra::ConstByteRange UniqueDeviceId()
{
const uint8_t* base = reinterpret_cast<const uint8_t*>(0x1FFFF7AC);
return infra::ConstByteRange(base, base + 12);
}
#endif

#if defined(STM32F407xx)
infra::ConstByteRange UniqueDeviceId()
{
const uint8_t* base = reinterpret_cast<const uint8_t*>(0x1FFF7A10);
return infra::ConstByteRange(base, base + 12);
}
#endif

#if defined(STM32F7)
infra::ConstByteRange UniqueDeviceId()
{
const uint8_t* base = reinterpret_cast<const uint8_t*>(0x1FF0F420);
return infra::ConstByteRange(base, base + 12);
}
#endif

#if defined(STM32WB55xx)
infra::ConstByteRange UniqueDeviceId()
{
const uint8_t* base = reinterpret_cast<const uint8_t*>(0x1FFF7590);
return infra::ConstByteRange(base, base + 12);
}
#endif

#if defined(STM32WBA52xx)
infra::ConstByteRange UniqueDeviceId()
{
const uint8_t* base = reinterpret_cast<const uint8_t*>(UID_BASE);
return infra::ConstByteRange(base, base + 12);
}
#endif
}

0 comments on commit ea45ec8

Please sign in to comment.