diff --git a/arduino/KmanSonoff_v1.00mc/KmanSonoff_v1.00mc.ino b/arduino/KmanSonoff_v1.00mc/KmanSonoff_v1.00mc.ino index da91d96..1b39644 100755 --- a/arduino/KmanSonoff_v1.00mc/KmanSonoff_v1.00mc.ino +++ b/arduino/KmanSonoff_v1.00mc/KmanSonoff_v1.00mc.ino @@ -187,6 +187,9 @@ void setup() { WiFi.hostname(UID); WiFi.begin(WIFI_SSID, WIFI_PASS); ArduinoOTA.setHostname(UID); + #ifdef OTA_PASS + ArduinoOTA.setPassword(OTA_PASS); + #endif ArduinoOTA.onStart([]() { OTAupdate = true; blinkLED(LED, 400, 2); diff --git a/arduino/KmanSonoff_v1.00mc/config_mc.h b/arduino/KmanSonoff_v1.00mc/config_mc.h index a1b5a03..833aa50 100755 --- a/arduino/KmanSonoff_v1.00mc/config_mc.h +++ b/arduino/KmanSonoff_v1.00mc/config_mc.h @@ -27,6 +27,7 @@ int QOS = 0; // QOS level for a #define WIFI_SSID "wifissid" // Your WiFi ssid #define WIFI_PASS "wifipass" // Your WiFi password +#define OTA_PASS 0 // OTA Password for reflashing - if 0 disabled /* ====================================================================================================================================== */ diff --git a/arduino/KmanSonoff_v1.00sc/KmanSonoff_v1.00sc.ino b/arduino/KmanSonoff_v1.00sc/KmanSonoff_v1.00sc.ino index ed9afbc..ed502f3 100755 --- a/arduino/KmanSonoff_v1.00sc/KmanSonoff_v1.00sc.ino +++ b/arduino/KmanSonoff_v1.00sc/KmanSonoff_v1.00sc.ino @@ -119,6 +119,9 @@ void setup() { WiFi.hostname(UID); WiFi.begin(WIFI_SSID, WIFI_PASS); ArduinoOTA.setHostname(UID); + #ifdef OTA_PASS + ArduinoOTA.setPassword(OTA_PASS); + #endif ArduinoOTA.onStart([]() { OTAupdate = true; blinkLED(LED, 400, 2); diff --git a/arduino/KmanSonoff_v1.00sc/config_sc.h b/arduino/KmanSonoff_v1.00sc/config_sc.h index 557ec11..d619bd4 100755 --- a/arduino/KmanSonoff_v1.00sc/config_sc.h +++ b/arduino/KmanSonoff_v1.00sc/config_sc.h @@ -30,6 +30,7 @@ int QOS = 0; // QOS level for a #define WIFI_SSID "wifissid" // Your WiFi ssid #define WIFI_PASS "wifipass" // Your WiFi password +#define OTA_PASS 0 // OTA Password for reflashing - if 0 disabled /* =========================================================================================================================================== */