Trying to fix mac problems

This commit is contained in:
Stefan Kremser
2018-05-09 19:07:03 +02:00
parent 2669cfa647
commit dc10c87c09
2 changed files with 5 additions and 0 deletions

View File

@@ -60,6 +60,10 @@ void Settings::load() {
prnt(S_SETTINGS_LOADED);
prntln(FILE_PATH);
// check and fix mac
if(!macValid(macSt)) getRandomMac(macSt);
if(!macValid(macAP)) getRandomMac(macAP);
save(true); // force saving
}

View File

@@ -22,6 +22,7 @@ extern bool strToMac(String macStr, uint8_t* mac);
extern void setWifiChannel(uint8_t ch);
extern String fixUtf8(String str);
extern void copyWebFiles(bool force);
extern bool macValid(uint8_t* mac);
class Settings {
public: