-
-
Save eggfly/4b08dbe239e71fabae1ed23f8398b10d to your computer and use it in GitHub Desktop.
Read GUID of LGT8F328P
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void setup() { | |
Serial.begin(9600); | |
delay(1000); | |
// read GUID of LGT8F328P | |
// https://www.avrfreaks.net/sites/default/files/forum_attachments/LGT8F88P%20LGT8F168P%20LGT8F328P%20translated.pdf | |
// if you want to read other device's unique id, use ArduinoUniqueID | |
// https://www.arduinolibraries.info/libraries/arduino-unique-id | |
#ifdef _LGT8F328P_SPEC_H_ | |
char buf[10]; | |
sprintf(buf,"%02X%02X%02X%02X",GUID3,GUID2,GUID1,GUID0); | |
Serial.print("device_id "); | |
Serial.print(buf); | |
Serial.print("\n"); | |
#endif | |
Serial.println("initialized."); | |
} | |
void loop() { | |
delay(1000); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment