Skip to content
This repository has been archived by the owner on Feb 9, 2022. It is now read-only.

Commit

Permalink
v1.0.4
Browse files Browse the repository at this point in the history
### New Releases v1.0.4

1. Add support to SAM DUE
2. Reduce html and code size for faster Config Portal response. 
3. Enhance GUI.
4. Config Portal AP SSID and Password will use 4 bytes of hardware unique macAddress, only for Teensy.
  • Loading branch information
khoih-prog authored Mar 15, 2020
1 parent a7b172c commit 8e30d59
Showing 1 changed file with 21 additions and 5 deletions.
26 changes: 21 additions & 5 deletions src/BlynkSimpleShieldEsp8266_Teensy_WM.h
Original file line number Diff line number Diff line change
Expand Up @@ -935,6 +935,22 @@ class BlynkWifi
} // if (server)
}

#if 0
uint8_t macTeensy[6];

static void teensyMAC(uint8_t *mac)
{
uint32_t m1 = HW_OCOTP_MAC1;
uint32_t m2 = HW_OCOTP_MAC0;
mac[0] = m1 >> 8;
mac[1] = m1 >> 0;
mac[2] = m2 >> 24;
mac[3] = m2 >> 16;
mac[4] = m2 >> 8;
mac[5] = m2 >> 0;
}
#endif

void startConfigurationMode()
{
#define CONFIG_TIMEOUT 60000L
Expand All @@ -945,11 +961,11 @@ class BlynkWifi

if ( (portal_ssid == "") || portal_pass == "" )
{
String randomNum = String(random(0xFFFFFF), HEX);
randomNum.toUpperCase();

portal_ssid = "Teensy4_" + randomNum;
portal_pass = "MyTeensy4_" + randomNum;
String hardwareID = String(HW_OCOTP_MAC0, HEX);
hardwareID.toUpperCase();
portal_ssid = "ESP_AT_" + hardwareID;
portal_pass = "MyESP_AT_" + hardwareID;
}

BLYNK_LOG6(BLYNK_F("stConf:SSID="), portal_ssid, BLYNK_F(",PW="), portal_pass, BLYNK_F(",IP="), portal_apIP);
Expand Down

0 comments on commit 8e30d59

Please sign in to comment.