diff --git a/include/hasp_conf.h b/include/hasp_conf.h
index 8d9aabbc..6a226ff8 100644
--- a/include/hasp_conf.h
+++ b/include/hasp_conf.h
@@ -235,13 +235,6 @@ static WiFiSpiClass WiFi;
#if HASP_USE_OTA > 0
#include "sys/svc/hasp_ota.h"
-#ifndef HASP_OTA_PORT
-#if defined(ARDUINO_ARCH_ESP32)
-#define HASP_OTA_PORT 3232
-#elif defined(ARDUINO_ARCH_ESP8266)
-#define HASP_OTA_PORT 8266
-#endif
-#endif
#endif
#if HASP_USE_TASMOTA_CLIENT > 0
diff --git a/include/lv_conf_v7.h b/include/lv_conf_v7.h
index cc19efbb..2d5f3017 100644
--- a/include/lv_conf_v7.h
+++ b/include/lv_conf_v7.h
@@ -349,35 +349,35 @@ typedef void* lv_indev_drv_user_data_t; /*Type of user data in the in
#if TFT_WIDTH>=320 || TFT_WIDTH>=480
-#ifdef WT32SC01
+// #ifdef WT32SC01
-#ifndef HASP_FONT_1
-#define HASP_FONT_1 robotocondensed_regular_16_ascii /* 5% Width */
-#endif
-#ifndef HASP_FONT_2
-#define HASP_FONT_2 robotocondensed_regular_24_ascii /* 5% Width */
-#endif
-#ifndef HASP_FONT_3
-#define HASP_FONT_3 robotocondensed_regular_32_ascii /* 10% Width */
-#endif
-#ifndef HASP_FONT_4
-#define HASP_FONT_4 robotocondensed_regular_48_ascii /* 10% Height */
-#endif
+// #ifndef HASP_FONT_1
+// #define HASP_FONT_1 robotocondensed_regular_16_ascii /* 5% Width */
+// #endif
+// #ifndef HASP_FONT_2
+// #define HASP_FONT_2 robotocondensed_regular_24_ascii /* 5% Width */
+// #endif
+// #ifndef HASP_FONT_3
+// #define HASP_FONT_3 robotocondensed_regular_32_ascii /* 10% Width */
+// #endif
+// #ifndef HASP_FONT_4
+// #define HASP_FONT_4 robotocondensed_regular_48_ascii /* 10% Height */
+// #endif
-#ifndef ROBOTOCONDENSED_REGULAR_16_ASCII
-#define ROBOTOCONDENSED_REGULAR_16_ASCII 1
-#endif
-#ifndef ROBOTOCONDENSED_REGULAR_24_ASCII
-#define ROBOTOCONDENSED_REGULAR_24_ASCII 1
-#endif
-#ifndef ROBOTOCONDENSED_REGULAR_32_ASCII
-#define ROBOTOCONDENSED_REGULAR_32_ASCII 1
-#endif
-#ifndef ROBOTOCONDENSED_REGULAR_48_ASCII
-#define ROBOTOCONDENSED_REGULAR_48_ASCII 1
-#endif
+// #ifndef ROBOTOCONDENSED_REGULAR_16_ASCII
+// #define ROBOTOCONDENSED_REGULAR_16_ASCII 1
+// #endif
+// #ifndef ROBOTOCONDENSED_REGULAR_24_ASCII
+// #define ROBOTOCONDENSED_REGULAR_24_ASCII 1
+// #endif
+// #ifndef ROBOTOCONDENSED_REGULAR_32_ASCII
+// #define ROBOTOCONDENSED_REGULAR_32_ASCII 1
+// #endif
+// #ifndef ROBOTOCONDENSED_REGULAR_48_ASCII
+// #define ROBOTOCONDENSED_REGULAR_48_ASCII 1
+// #endif
-#else // not WT32SC01
+// #else // not WT32SC01
#ifndef HASP_FONT_1
#define HASP_FONT_1 robotocondensed_regular_16_latin1 /* 5% Width */
@@ -405,7 +405,7 @@ typedef void* lv_indev_drv_user_data_t; /*Type of user data in the in
#define ROBOTOCONDENSED_REGULAR_48_LATIN1 1
#endif
-#endif // WT32SC01
+//#endif // WT32SC01
#ifndef HASP_FONT_SIZE_1
#define HASP_FONT_SIZE_1 16
diff --git a/platformio.ini b/platformio.ini
index 34fd4d57..040e1977 100644
--- a/platformio.ini
+++ b/platformio.ini
@@ -91,7 +91,7 @@ src_filter = +<*> -<.git/> - - - - - 0
mdnsStart();
+#endif // HASP_USE_MDNS
}
void networkStop(void)
diff --git a/src/sys/net/hasp_wifi.h b/src/sys/net/hasp_wifi.h
index 7abba5bf..2e07d892 100644
--- a/src/sys/net/hasp_wifi.h
+++ b/src/sys/net/hasp_wifi.h
@@ -6,6 +6,12 @@
#include "ArduinoJson.h"
+#if defined(ARDUINO_ARCH_ESP32)
+#include
+#elif defined(ARDUINO_ARCH_ESP8266)
+#include
+#endif
+
void wifiSetup();
bool wifiShowAP();
bool wifiShowAP(char* ssid, char* pass);
diff --git a/src/sys/svc/hasp_ota.cpp b/src/sys/svc/hasp_ota.cpp
index 42bee68c..a9ccf829 100644
--- a/src/sys/svc/hasp_ota.cpp
+++ b/src/sys/svc/hasp_ota.cpp
@@ -16,6 +16,9 @@
#include
#include
#include
+#ifndef HASP_OTA_PORT
+#define HASP_OTA_PORT 3232
+#endif
#endif
#if defined(ARDUINO_ARCH_ESP32)
@@ -23,6 +26,9 @@
#include
#include
#include
+#ifndef HASP_OTA_PORT
+#define HASP_OTA_PORT 8266
+#endif
/**
* This is lets-encrypt-x3-cross-signed.pem
@@ -118,6 +124,7 @@ void otaOnProgress(unsigned int progress, unsigned int total)
}
}
+#if HASP_USE_OTA > 0
void otaSetup(void)
{
if(strlen(otaUrl.c_str())) {
@@ -209,6 +216,7 @@ void otaEverySecond(void)
{
if(otaPrecentageComplete >= 0) otaProgress();
}
+#endif
void otaHttpUpdate(const char* espOtaUrl)
{ // Update ESP firmware from HTTP
diff --git a/src/sys/svc/hasp_ota.h b/src/sys/svc/hasp_ota.h
index 0dad8f5c..d782114e 100644
--- a/src/sys/svc/hasp_ota.h
+++ b/src/sys/svc/hasp_ota.h
@@ -10,9 +10,11 @@
#include
/* ===== Default Event Processors ===== */
+#if HASP_USE_OTA > 0
void otaSetup(void);
IRAM_ATTR void otaLoop(void);
void otaEverySecond(void);
+#endif
/* ===== Special Event Processors ===== */
void otaHttpUpdate(const char* espOtaUrl);
diff --git a/user_setups/esp32/wt32-sc01.ini b/user_setups/esp32/wt32-sc01.ini
index 7b489c3f..1721fa2e 100644
--- a/user_setups/esp32/wt32-sc01.ini
+++ b/user_setups/esp32/wt32-sc01.ini
@@ -14,6 +14,9 @@ build_flags =
${esp32.build_flags}
${esp32.ps_ram}
+ -D HASP_USE_MDNS=1 ; saves 32 KiB flash
+ -D HASP_USE_OTA=0 ; No ArduinoOTA on port 3232
+
;region -- TFT_eSPI build options ------------------------
${lcd.wt32-sc01}
-D WT32SC01