https://github.com/pilotak/stm32-uid
Mbed helper to get UID as base64
https://github.com/pilotak/stm32-uid
mbed mbed-os stm32 uid
Last synced: 8 months ago
JSON representation
Mbed helper to get UID as base64
- Host: GitHub
- URL: https://github.com/pilotak/stm32-uid
- Owner: pilotak
- License: mit
- Created: 2018-04-17T14:06:49.000Z (about 8 years ago)
- Default Branch: master
- Last Pushed: 2018-07-24T10:49:11.000Z (almost 8 years ago)
- Last Synced: 2025-08-02T01:24:34.289Z (10 months ago)
- Topics: mbed, mbed-os, stm32, uid
- Language: C++
- Size: 2.93 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# stm32-uid
Mbed helper to get UID as base64
# Example
```cpp
#include "mbed.h"
#include "stm32-uid.h"
STM32uid uid;
int main() {
char id[12], base[16];
uid.get(id);
uid.get_base64(base);
printf("uid: ");
for (int i = 0; i < 12; ++i) {
printf("%02X", id[i]);
}
printf("\n base64: ");
for (int i = 0; i < 16; ++i) {
printf("%c", base[i]);
}
printf("\n");
}
```