Created
September 18, 2017 01:07
-
-
Save kd8bxp/3af6508b72b2db83c2fe93228e2b6fa2 to your computer and use it in GitHub Desktop.
Create a Unique MQTT Client ID or SSID for your ESP8266 using part of the MAC address.
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); | |
Serial.println(""); | |
Serial.println(""); | |
Serial.println("Check ID in:"); | |
Serial.println("https://www.wemos.cc/verify_products"); | |
Serial.printf("Chip ID = %08X\n", ESP.getChipId()); | |
Serial.println(ESP.getChipId()); | |
Serial.println(""); | |
Serial.println(""); | |
uint32_t chipid=ESP.getChipId(); | |
char clientid[25]; | |
snprintf(clientid,25,"WIFI-Display-%08X",chipid); | |
Serial.print("Client ID: "); | |
Serial.println(clientid); | |
delay(5000); | |
} | |
void loop() { | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment