From 3596e4c77f531115133a64d55659469a6fa00893 Mon Sep 17 00:00:00 2001 From: hkrupp Date: Fri, 11 Oct 2019 07:40:55 +0200 Subject: [PATCH 1/4] Initial IPv6 support (SLAAC). Builds against 2.5.2 and 2.6.0 staging. iram1_0_seg problems with larger configurations. --- platformio.ini | 74 +++++++++++++++++++++++++++++++++++++++-- sonoff/language/bg-BG.h | 1 + sonoff/language/cs-CZ.h | 1 + sonoff/language/de-DE.h | 1 + sonoff/language/el-GR.h | 1 + sonoff/language/en-GB.h | 1 + sonoff/language/es-ES.h | 1 + sonoff/language/fr-FR.h | 1 + sonoff/language/he-HE.h | 1 + sonoff/language/hu-HU.h | 1 + sonoff/language/it-IT.h | 1 + sonoff/language/ko-KO.h | 1 + sonoff/language/nl-NL.h | 1 + sonoff/language/pl-PL.h | 1 + sonoff/language/pt-BR.h | 1 + sonoff/language/pt-PT.h | 1 + sonoff/language/ru-RU.h | 1 + sonoff/language/sk-SK.h | 1 + sonoff/language/sv-SE.h | 1 + sonoff/language/tr-TR.h | 1 + sonoff/language/uk-UK.h | 1 + sonoff/language/zh-CN.h | 1 + sonoff/language/zh-TW.h | 1 + sonoff/support_wifi.ino | 21 ++++++++++++ 24 files changed, 114 insertions(+), 3 deletions(-) diff --git a/platformio.ini b/platformio.ini index 48b23c8ef..bcde1d330 100755 --- a/platformio.ini +++ b/platformio.ini @@ -95,6 +95,32 @@ build_flags = ${esp82xx_defaults.build_flags} -fno-exceptions -lstdc++ +[core_2_5_2_ipv6] +; *** Esp8266 core for Arduino version 2.5.2 +platform = espressif8266@~2.2.2 +build_flags = ${esp82xx_defaults.build_flags} + -Wl,-Teagle.flash.1m.ld +; Code optimization see https://github.com/esp8266/Arduino/issues/5790#issuecomment-475672473 + -O2 + -DBEARSSL_SSL_BASIC +; nonos-sdk 22x + -DPIO_FRAMEWORK_ARDUINO_ESPRESSIF_SDK22x +; nonos-sdk-pre-v3 +; -DPIO_FRAMEWORK_ARDUINO_ESPRESSIF_SDK3 +; lwIP 1.4 +; -DPIO_FRAMEWORK_ARDUINO_LWIP_HIGHER_BANDWIDTH +; lwIP 2 - Low Memory +; -DPIO_FRAMEWORK_ARDUINO_LWIP2_LOW_MEMORY +; lwIP 2 - Higher Bandwidth +; -DPIO_FRAMEWORK_ARDUINO_LWIP2_HIGHER_BANDWIDTH +; lwIP 2 - Higher Bandwidth Low Memory no Features +; -DPIO_FRAMEWORK_ARDUINO_LWIP2_LOW_MEMORY_LOW_FLASH +; lwIP 2 - Higher Bandwidth IPv6 + -DPIO_FRAMEWORK_ARDUINO_LWIP2_IPV6_HIGHER_BANDWIDTH + -DVTABLES_IN_FLASH + -fno-exceptions + -lstdc++ + [core_stage] ; *** Esp8266 core for Arduino version latest beta platform = https://github.com/platformio/platform-espressif8266.git#feature/stage @@ -117,7 +143,7 @@ build_flags = ${esp82xx_defaults.build_flags} ; -DPIO_FRAMEWORK_ARDUINO_LWIP2_HIGHER_BANDWIDTH ; lwIP 2 - Higher Bandwitdh Low Memory no Features ; -DPIO_FRAMEWORK_ARDUINO_LWIP2_LOW_MEMORY_LOW_FLASH -; lwIP 2 - Higher Bandwitdh no Features +; lwIP 2 - Higher Bandwidth no Features (Tasmota default) -DPIO_FRAMEWORK_ARDUINO_LWIP2_HIGHER_BANDWIDTH_LOW_FLASH ; VTABLES in Flash (default) -DVTABLES_IN_FLASH @@ -133,6 +159,44 @@ build_flags = ${esp82xx_defaults.build_flags} ; -fexceptions ; -lstdc++-exc +[core_stage_ipv6] +; *** Esp8266 core for Arduino version latest beta +platform = https://github.com/platformio/platform-espressif8266.git#feature/stage +build_flags = ${esp82xx_defaults.build_flags} + -Wl,-Teagle.flash.1m.ld +; Code optimization see https://github.com/esp8266/Arduino/issues/5790#issuecomment-475672473 + -O2 + -DBEARSSL_SSL_BASIC +; nonos-sdk 22y + -DPIO_FRAMEWORK_ARDUINO_ESPRESSIF_SDK22y +; nonos-sdk 22x +; -DPIO_FRAMEWORK_ARDUINO_ESPRESSIF_SDK22x +; nonos-sdk-pre-v3 +; -DPIO_FRAMEWORK_ARDUINO_ESPRESSIF_SDK3 +; lwIP 1.4 +; -DPIO_FRAMEWORK_ARDUINO_LWIP_HIGHER_BANDWIDTH +; lwIP 2 - Low Memory +; -DPIO_FRAMEWORK_ARDUINO_LWIP2_LOW_MEMORY +; lwIP 2 - Higher Bandwidth +; -DPIO_FRAMEWORK_ARDUINO_LWIP2_HIGHER_BANDWIDTH +; lwIP 2 - Higher Bandwitdh Low Memory no Features +; -DPIO_FRAMEWORK_ARDUINO_LWIP2_LOW_MEMORY_LOW_FLASH +; lwIP 2 - Higher Bandwidth IPv6 + -DPIO_FRAMEWORK_ARDUINO_LWIP2_IPV6_HIGHER_BANDWIDTH +; VTABLES in Flash (default) + -DVTABLES_IN_FLASH +; VTABLES in Heap +; -DVTABLES_IN_DRAM +; VTABLES in IRAM +; -DVTABLES_IN_IRAM +; enable one option set -> No exception recommended +; No exception code in firmware + -fno-exceptions + -lstdc++ +; Exception code in firmware /needs much space! 90k +; -fexceptions +; -lstdc++-exc + [core_pre] ; *** Arduino Esp8266 core pre 2.6.x for Tasmota (mqtt reconnects fixed) platform = https://github.com/Jason2866/platform-espressif8266.git#Tasmota @@ -178,10 +242,14 @@ build_flags = ${esp82xx_defaults.build_flags} ;build_flags = ${core_2_4_2.build_flags} ;platform = ${core_2_5_2.platform} ;build_flags = ${core_2_5_2.build_flags} +;platform = ${core_2_5_2_ipv6.platform} +;build_flags = ${core_2_5_2_ipv6.build_flags} ;platform = ${core_stage.platform} ;build_flags = ${core_stage.build_flags} -platform = ${core_pre.platform} -build_flags = ${core_pre.build_flags} +platform = ${core_stage_ipv6.platform} +build_flags = ${core_stage_ipv6.build_flags} +;platform = ${core_pre.platform} +;build_flags = ${core_pre.build_flags} [common] framework = arduino diff --git a/sonoff/language/bg-BG.h b/sonoff/language/bg-BG.h index 609da691e..1139e468b 100644 --- a/sonoff/language/bg-BG.h +++ b/sonoff/language/bg-BG.h @@ -213,6 +213,7 @@ #define D_MQTT_SERVICE_FOUND "MQTT услуга е намерена на" #define D_FOUND_AT "намерена в" #define D_SYSLOG_HOST_NOT_FOUND "Хостът на системния лог не е намерен" +#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Запазено във флаш паметта на" diff --git a/sonoff/language/cs-CZ.h b/sonoff/language/cs-CZ.h index c0e3fefdf..4518cc8b1 100644 --- a/sonoff/language/cs-CZ.h +++ b/sonoff/language/cs-CZ.h @@ -213,6 +213,7 @@ #define D_MQTT_SERVICE_FOUND "Služba MQTT byla nalezena" #define D_FOUND_AT "znalezeno v" #define D_SYSLOG_HOST_NOT_FOUND "Syslog Host nebyl nalezen" +#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Uloženo do paměti flash v" diff --git a/sonoff/language/de-DE.h b/sonoff/language/de-DE.h index f92507180..5fcd94055 100644 --- a/sonoff/language/de-DE.h +++ b/sonoff/language/de-DE.h @@ -213,6 +213,7 @@ #define D_MQTT_SERVICE_FOUND "MQTT-Service gefunden bei" #define D_FOUND_AT "gefunden bei" #define D_SYSLOG_HOST_NOT_FOUND "Syslog-Host nicht gefunden" +#define D_CONNECT_V6_ADDR_INFO "IPv6 globale Adresse" // settings.ino #define D_SAVED_TO_FLASH_AT "in Flash gespeichert am" diff --git a/sonoff/language/el-GR.h b/sonoff/language/el-GR.h index e07d8811b..6a065a0a3 100644 --- a/sonoff/language/el-GR.h +++ b/sonoff/language/el-GR.h @@ -213,6 +213,7 @@ #define D_MQTT_SERVICE_FOUND "Βρέθηκε υπηρεσία MQTT στο" #define D_FOUND_AT "βρέθηκε στο" #define D_SYSLOG_HOST_NOT_FOUND "Δε βρέθηκε Syslog Host" +#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Αποθηκεύτηκε από τη Flash στο" diff --git a/sonoff/language/en-GB.h b/sonoff/language/en-GB.h index a18f2342e..ea4e40e61 100644 --- a/sonoff/language/en-GB.h +++ b/sonoff/language/en-GB.h @@ -213,6 +213,7 @@ #define D_MQTT_SERVICE_FOUND "MQTT service found on" #define D_FOUND_AT "found at" #define D_SYSLOG_HOST_NOT_FOUND "Syslog Host not found" +#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Saved to flash at" diff --git a/sonoff/language/es-ES.h b/sonoff/language/es-ES.h index 193cc57e7..5c4ade0b4 100644 --- a/sonoff/language/es-ES.h +++ b/sonoff/language/es-ES.h @@ -213,6 +213,7 @@ #define D_MQTT_SERVICE_FOUND "Servicio MQTT encontrado en" #define D_FOUND_AT "encontrado en" #define D_SYSLOG_HOST_NOT_FOUND "Syslog Host no encontrado" +#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Grabado a la flash en" diff --git a/sonoff/language/fr-FR.h b/sonoff/language/fr-FR.h index aefca66f4..afc99ba17 100644 --- a/sonoff/language/fr-FR.h +++ b/sonoff/language/fr-FR.h @@ -213,6 +213,7 @@ #define D_MQTT_SERVICE_FOUND "Service MQTT trouvé sur" #define D_FOUND_AT "trouvé à" #define D_SYSLOG_HOST_NOT_FOUND "Hôte SysLog introuvable" +#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Enregistré en flash à" diff --git a/sonoff/language/he-HE.h b/sonoff/language/he-HE.h index 5830b394f..d4be9ece4 100644 --- a/sonoff/language/he-HE.h +++ b/sonoff/language/he-HE.h @@ -213,6 +213,7 @@ #define D_MQTT_SERVICE_FOUND "MQTT נמצאו שירותי" #define D_FOUND_AT "נמצא ב" #define D_SYSLOG_HOST_NOT_FOUND "לא נמצא Syslog מארח" +#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "נשמר לפלאש ב" diff --git a/sonoff/language/hu-HU.h b/sonoff/language/hu-HU.h index dd4d5a645..4ae078e71 100644 --- a/sonoff/language/hu-HU.h +++ b/sonoff/language/hu-HU.h @@ -213,6 +213,7 @@ #define D_MQTT_SERVICE_FOUND "élő MQTT szolgáltatás a(z)" #define D_FOUND_AT "a(z)" #define D_SYSLOG_HOST_NOT_FOUND "Syslog hoszt nem található" +#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Flash-re mentve a(z)" diff --git a/sonoff/language/it-IT.h b/sonoff/language/it-IT.h index 4ec8728f2..f6ad2b779 100644 --- a/sonoff/language/it-IT.h +++ b/sonoff/language/it-IT.h @@ -213,6 +213,7 @@ #define D_MQTT_SERVICE_FOUND "Servizio MQTT trovato su" #define D_FOUND_AT "trovato a" #define D_SYSLOG_HOST_NOT_FOUND "Syslog Host non trovato" +#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Salvato nella flash in" diff --git a/sonoff/language/ko-KO.h b/sonoff/language/ko-KO.h index d1729fbce..8e190470c 100644 --- a/sonoff/language/ko-KO.h +++ b/sonoff/language/ko-KO.h @@ -213,6 +213,7 @@ #define D_MQTT_SERVICE_FOUND "MQTT 서비스 발견" #define D_FOUND_AT "다음에서 발견" #define D_SYSLOG_HOST_NOT_FOUND "Syslog 호스트가 발견되지 않았습니다" +#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "플래시에 저장" diff --git a/sonoff/language/nl-NL.h b/sonoff/language/nl-NL.h index 7be14d2b5..f20d745b1 100644 --- a/sonoff/language/nl-NL.h +++ b/sonoff/language/nl-NL.h @@ -213,6 +213,7 @@ #define D_MQTT_SERVICE_FOUND "MQTT dienst gevonden op" #define D_FOUND_AT "gevonden op" #define D_SYSLOG_HOST_NOT_FOUND "Syslog Host niet gevonden" +#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Opgeslagen in flash op" diff --git a/sonoff/language/pl-PL.h b/sonoff/language/pl-PL.h index 6d5767ed7..3e1fc2ef6 100644 --- a/sonoff/language/pl-PL.h +++ b/sonoff/language/pl-PL.h @@ -213,6 +213,7 @@ #define D_MQTT_SERVICE_FOUND "Usługa MQTT została znaleziona" #define D_FOUND_AT "znalezione w" #define D_SYSLOG_HOST_NOT_FOUND "Syslog Host nie znaleziony" +#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Zapisane do pamięci flash w" diff --git a/sonoff/language/pt-BR.h b/sonoff/language/pt-BR.h index 1b2aa0ef9..a57bc0056 100644 --- a/sonoff/language/pt-BR.h +++ b/sonoff/language/pt-BR.h @@ -213,6 +213,7 @@ #define D_MQTT_SERVICE_FOUND "Serviço MQTT encontrado em" #define D_FOUND_AT "encontrado em" #define D_SYSLOG_HOST_NOT_FOUND "Syslog anfitrião não encontrado" +#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Guardado na flash em" diff --git a/sonoff/language/pt-PT.h b/sonoff/language/pt-PT.h index 54cc61d87..f5397163b 100644 --- a/sonoff/language/pt-PT.h +++ b/sonoff/language/pt-PT.h @@ -213,6 +213,7 @@ #define D_MQTT_SERVICE_FOUND "Serviço MQTT encontrado em" #define D_FOUND_AT "encontrado em" #define D_SYSLOG_HOST_NOT_FOUND "Syslog anfitrião não encontrado" +#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Guardado na flash em" diff --git a/sonoff/language/ru-RU.h b/sonoff/language/ru-RU.h index fbf006e3d..2d3893e50 100644 --- a/sonoff/language/ru-RU.h +++ b/sonoff/language/ru-RU.h @@ -213,6 +213,7 @@ #define D_MQTT_SERVICE_FOUND "MQTT сервис service найдено" #define D_FOUND_AT "найдено в" #define D_SYSLOG_HOST_NOT_FOUND "System лог хост не найден" +#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Сохранено во флэш-память" diff --git a/sonoff/language/sk-SK.h b/sonoff/language/sk-SK.h index d26e418d0..fb089b345 100644 --- a/sonoff/language/sk-SK.h +++ b/sonoff/language/sk-SK.h @@ -213,6 +213,7 @@ #define D_MQTT_SERVICE_FOUND "Služba MQTT bola nájdená" #define D_FOUND_AT "nájdené v" #define D_SYSLOG_HOST_NOT_FOUND "Syslog Host nebol nájdený" +#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Uložené do flash pamäte v" diff --git a/sonoff/language/sv-SE.h b/sonoff/language/sv-SE.h index 72b977208..1f7e3dbce 100644 --- a/sonoff/language/sv-SE.h +++ b/sonoff/language/sv-SE.h @@ -213,6 +213,7 @@ #define D_MQTT_SERVICE_FOUND "MQTT-tjänst hittades på" #define D_FOUND_AT "hittades vid" #define D_SYSLOG_HOST_NOT_FOUND "Syslog-värd hittades inte" +#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Sparade till flash vid" diff --git a/sonoff/language/tr-TR.h b/sonoff/language/tr-TR.h index 4fae8e0cf..6a0959804 100755 --- a/sonoff/language/tr-TR.h +++ b/sonoff/language/tr-TR.h @@ -213,6 +213,7 @@ #define D_MQTT_SERVICE_FOUND "Üzerinden MQTT serivisi tespit edildi" #define D_FOUND_AT "(bulundu)" #define D_SYSLOG_HOST_NOT_FOUND "Syslog hostu bulunamadı" +#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Bellekten (Flash) kaydedidi:" diff --git a/sonoff/language/uk-UK.h b/sonoff/language/uk-UK.h index 2b046389d..67cbd6453 100644 --- a/sonoff/language/uk-UK.h +++ b/sonoff/language/uk-UK.h @@ -213,6 +213,7 @@ #define D_MQTT_SERVICE_FOUND "MQTT сервер знайдено" #define D_FOUND_AT "знайдено в" #define D_SYSLOG_HOST_NOT_FOUND "Сервер журналу не знайдено" +#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Збережено в флэш-пам'ять" diff --git a/sonoff/language/zh-CN.h b/sonoff/language/zh-CN.h index 8ca50943c..37f82a41d 100644 --- a/sonoff/language/zh-CN.h +++ b/sonoff/language/zh-CN.h @@ -213,6 +213,7 @@ #define D_MQTT_SERVICE_FOUND "发现 MQTT 服务:" #define D_FOUND_AT "发现:" #define D_SYSLOG_HOST_NOT_FOUND "Syslog 主机未找到" +#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "保存到 flash:" diff --git a/sonoff/language/zh-TW.h b/sonoff/language/zh-TW.h index bc535f70e..8a5b549ad 100644 --- a/sonoff/language/zh-TW.h +++ b/sonoff/language/zh-TW.h @@ -213,6 +213,7 @@ #define D_MQTT_SERVICE_FOUND "發現MQTT服務:" #define D_FOUND_AT "found at" #define D_SYSLOG_HOST_NOT_FOUND "Syslog主機未找到" +#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "保存到 flash:" diff --git a/sonoff/support_wifi.ino b/sonoff/support_wifi.ino index e528e51ea..21820f303 100644 --- a/sonoff/support_wifi.ino +++ b/sonoff/support_wifi.ino @@ -33,6 +33,9 @@ const uint8_t WIFI_CHECK_SEC = 20; // seconds const uint8_t WIFI_RETRY_OFFSET_SEC = 20; // seconds #include // Wifi, MQTT, Ota, WifiManager +#if LWIP_IPV6 +#include // IPv6 DualStack +#endif struct WIFI { uint32_t last_event = 0; // Last wifi connection event @@ -235,6 +238,24 @@ void WifiBegin(uint8_t flag, uint8_t channel) } AddLog_P2(LOG_LEVEL_INFO, PSTR(D_LOG_WIFI D_CONNECTING_TO_AP "%d %s " D_IN_MODE " 11%c " D_AS " %s..."), Settings.sta_active +1, Settings.sta_ssid[Settings.sta_active], kWifiPhyMode[WiFi.getPhyMode() & 0x3], my_hostname); + +#if LWIP_IPV6 + for (bool configured = false; !configured;) { + uint16_t cfgcnt=0; + for (auto addr : addrList) + { + if ((configured = !addr.isLocal() && addr.isV6()) || cfgcnt==30) break; // IPv6 is mandatory but stop after 15 seconds + delay(500); // Loop until real IPv6 address is aquired or too many tries failed + cfgcnt++; + } + } + for (auto a : addrList) { + if(!a.isLocal() && !a.isLegacy()) + { + AddLog_P2(LOG_LEVEL_INFO, PSTR(D_LOG_WIFI D_CONNECT_V6_ADDR_INFO " %s"),a.toString().c_str()); + } + } +#endif } void WifiBeginAfterScan() From b48c1a1c824c28ef6eb94ec4337f272f9a8fec94 Mon Sep 17 00:00:00 2001 From: hkrupp Date: Fri, 11 Oct 2019 12:50:45 +0200 Subject: [PATCH 2/4] Remove logging message translation and core 2.5.2 as future target is core 2.6 --- platformio.ini | 28 ---------------------------- sonoff/language/bg-BG.h | 1 - sonoff/language/cs-CZ.h | 1 - sonoff/language/de-DE.h | 1 - sonoff/language/el-GR.h | 1 - sonoff/language/en-GB.h | 1 - sonoff/language/es-ES.h | 1 - sonoff/language/fr-FR.h | 1 - sonoff/language/he-HE.h | 1 - sonoff/language/hu-HU.h | 1 - sonoff/language/it-IT.h | 1 - sonoff/language/ko-KO.h | 1 - sonoff/language/nl-NL.h | 1 - sonoff/language/pl-PL.h | 1 - sonoff/language/pt-BR.h | 1 - sonoff/language/pt-PT.h | 1 - sonoff/language/ru-RU.h | 1 - sonoff/language/sk-SK.h | 1 - sonoff/language/sv-SE.h | 1 - sonoff/language/tr-TR.h | 1 - sonoff/language/uk-UK.h | 1 - sonoff/language/zh-CN.h | 1 - sonoff/language/zh-TW.h | 1 - sonoff/support_wifi.ino | 2 +- 24 files changed, 1 insertion(+), 51 deletions(-) diff --git a/platformio.ini b/platformio.ini index bcde1d330..7c353d8fd 100755 --- a/platformio.ini +++ b/platformio.ini @@ -95,32 +95,6 @@ build_flags = ${esp82xx_defaults.build_flags} -fno-exceptions -lstdc++ -[core_2_5_2_ipv6] -; *** Esp8266 core for Arduino version 2.5.2 -platform = espressif8266@~2.2.2 -build_flags = ${esp82xx_defaults.build_flags} - -Wl,-Teagle.flash.1m.ld -; Code optimization see https://github.com/esp8266/Arduino/issues/5790#issuecomment-475672473 - -O2 - -DBEARSSL_SSL_BASIC -; nonos-sdk 22x - -DPIO_FRAMEWORK_ARDUINO_ESPRESSIF_SDK22x -; nonos-sdk-pre-v3 -; -DPIO_FRAMEWORK_ARDUINO_ESPRESSIF_SDK3 -; lwIP 1.4 -; -DPIO_FRAMEWORK_ARDUINO_LWIP_HIGHER_BANDWIDTH -; lwIP 2 - Low Memory -; -DPIO_FRAMEWORK_ARDUINO_LWIP2_LOW_MEMORY -; lwIP 2 - Higher Bandwidth -; -DPIO_FRAMEWORK_ARDUINO_LWIP2_HIGHER_BANDWIDTH -; lwIP 2 - Higher Bandwidth Low Memory no Features -; -DPIO_FRAMEWORK_ARDUINO_LWIP2_LOW_MEMORY_LOW_FLASH -; lwIP 2 - Higher Bandwidth IPv6 - -DPIO_FRAMEWORK_ARDUINO_LWIP2_IPV6_HIGHER_BANDWIDTH - -DVTABLES_IN_FLASH - -fno-exceptions - -lstdc++ - [core_stage] ; *** Esp8266 core for Arduino version latest beta platform = https://github.com/platformio/platform-espressif8266.git#feature/stage @@ -242,8 +216,6 @@ build_flags = ${esp82xx_defaults.build_flags} ;build_flags = ${core_2_4_2.build_flags} ;platform = ${core_2_5_2.platform} ;build_flags = ${core_2_5_2.build_flags} -;platform = ${core_2_5_2_ipv6.platform} -;build_flags = ${core_2_5_2_ipv6.build_flags} ;platform = ${core_stage.platform} ;build_flags = ${core_stage.build_flags} platform = ${core_stage_ipv6.platform} diff --git a/sonoff/language/bg-BG.h b/sonoff/language/bg-BG.h index 1139e468b..609da691e 100644 --- a/sonoff/language/bg-BG.h +++ b/sonoff/language/bg-BG.h @@ -213,7 +213,6 @@ #define D_MQTT_SERVICE_FOUND "MQTT услуга е намерена на" #define D_FOUND_AT "намерена в" #define D_SYSLOG_HOST_NOT_FOUND "Хостът на системния лог не е намерен" -#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Запазено във флаш паметта на" diff --git a/sonoff/language/cs-CZ.h b/sonoff/language/cs-CZ.h index 4518cc8b1..c0e3fefdf 100644 --- a/sonoff/language/cs-CZ.h +++ b/sonoff/language/cs-CZ.h @@ -213,7 +213,6 @@ #define D_MQTT_SERVICE_FOUND "Služba MQTT byla nalezena" #define D_FOUND_AT "znalezeno v" #define D_SYSLOG_HOST_NOT_FOUND "Syslog Host nebyl nalezen" -#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Uloženo do paměti flash v" diff --git a/sonoff/language/de-DE.h b/sonoff/language/de-DE.h index 5fcd94055..f92507180 100644 --- a/sonoff/language/de-DE.h +++ b/sonoff/language/de-DE.h @@ -213,7 +213,6 @@ #define D_MQTT_SERVICE_FOUND "MQTT-Service gefunden bei" #define D_FOUND_AT "gefunden bei" #define D_SYSLOG_HOST_NOT_FOUND "Syslog-Host nicht gefunden" -#define D_CONNECT_V6_ADDR_INFO "IPv6 globale Adresse" // settings.ino #define D_SAVED_TO_FLASH_AT "in Flash gespeichert am" diff --git a/sonoff/language/el-GR.h b/sonoff/language/el-GR.h index 6a065a0a3..e07d8811b 100644 --- a/sonoff/language/el-GR.h +++ b/sonoff/language/el-GR.h @@ -213,7 +213,6 @@ #define D_MQTT_SERVICE_FOUND "Βρέθηκε υπηρεσία MQTT στο" #define D_FOUND_AT "βρέθηκε στο" #define D_SYSLOG_HOST_NOT_FOUND "Δε βρέθηκε Syslog Host" -#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Αποθηκεύτηκε από τη Flash στο" diff --git a/sonoff/language/en-GB.h b/sonoff/language/en-GB.h index ea4e40e61..a18f2342e 100644 --- a/sonoff/language/en-GB.h +++ b/sonoff/language/en-GB.h @@ -213,7 +213,6 @@ #define D_MQTT_SERVICE_FOUND "MQTT service found on" #define D_FOUND_AT "found at" #define D_SYSLOG_HOST_NOT_FOUND "Syslog Host not found" -#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Saved to flash at" diff --git a/sonoff/language/es-ES.h b/sonoff/language/es-ES.h index 5c4ade0b4..193cc57e7 100644 --- a/sonoff/language/es-ES.h +++ b/sonoff/language/es-ES.h @@ -213,7 +213,6 @@ #define D_MQTT_SERVICE_FOUND "Servicio MQTT encontrado en" #define D_FOUND_AT "encontrado en" #define D_SYSLOG_HOST_NOT_FOUND "Syslog Host no encontrado" -#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Grabado a la flash en" diff --git a/sonoff/language/fr-FR.h b/sonoff/language/fr-FR.h index afc99ba17..aefca66f4 100644 --- a/sonoff/language/fr-FR.h +++ b/sonoff/language/fr-FR.h @@ -213,7 +213,6 @@ #define D_MQTT_SERVICE_FOUND "Service MQTT trouvé sur" #define D_FOUND_AT "trouvé à" #define D_SYSLOG_HOST_NOT_FOUND "Hôte SysLog introuvable" -#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Enregistré en flash à" diff --git a/sonoff/language/he-HE.h b/sonoff/language/he-HE.h index d4be9ece4..5830b394f 100644 --- a/sonoff/language/he-HE.h +++ b/sonoff/language/he-HE.h @@ -213,7 +213,6 @@ #define D_MQTT_SERVICE_FOUND "MQTT נמצאו שירותי" #define D_FOUND_AT "נמצא ב" #define D_SYSLOG_HOST_NOT_FOUND "לא נמצא Syslog מארח" -#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "נשמר לפלאש ב" diff --git a/sonoff/language/hu-HU.h b/sonoff/language/hu-HU.h index 4ae078e71..dd4d5a645 100644 --- a/sonoff/language/hu-HU.h +++ b/sonoff/language/hu-HU.h @@ -213,7 +213,6 @@ #define D_MQTT_SERVICE_FOUND "élő MQTT szolgáltatás a(z)" #define D_FOUND_AT "a(z)" #define D_SYSLOG_HOST_NOT_FOUND "Syslog hoszt nem található" -#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Flash-re mentve a(z)" diff --git a/sonoff/language/it-IT.h b/sonoff/language/it-IT.h index f6ad2b779..4ec8728f2 100644 --- a/sonoff/language/it-IT.h +++ b/sonoff/language/it-IT.h @@ -213,7 +213,6 @@ #define D_MQTT_SERVICE_FOUND "Servizio MQTT trovato su" #define D_FOUND_AT "trovato a" #define D_SYSLOG_HOST_NOT_FOUND "Syslog Host non trovato" -#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Salvato nella flash in" diff --git a/sonoff/language/ko-KO.h b/sonoff/language/ko-KO.h index 8e190470c..d1729fbce 100644 --- a/sonoff/language/ko-KO.h +++ b/sonoff/language/ko-KO.h @@ -213,7 +213,6 @@ #define D_MQTT_SERVICE_FOUND "MQTT 서비스 발견" #define D_FOUND_AT "다음에서 발견" #define D_SYSLOG_HOST_NOT_FOUND "Syslog 호스트가 발견되지 않았습니다" -#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "플래시에 저장" diff --git a/sonoff/language/nl-NL.h b/sonoff/language/nl-NL.h index f20d745b1..7be14d2b5 100644 --- a/sonoff/language/nl-NL.h +++ b/sonoff/language/nl-NL.h @@ -213,7 +213,6 @@ #define D_MQTT_SERVICE_FOUND "MQTT dienst gevonden op" #define D_FOUND_AT "gevonden op" #define D_SYSLOG_HOST_NOT_FOUND "Syslog Host niet gevonden" -#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Opgeslagen in flash op" diff --git a/sonoff/language/pl-PL.h b/sonoff/language/pl-PL.h index 3e1fc2ef6..6d5767ed7 100644 --- a/sonoff/language/pl-PL.h +++ b/sonoff/language/pl-PL.h @@ -213,7 +213,6 @@ #define D_MQTT_SERVICE_FOUND "Usługa MQTT została znaleziona" #define D_FOUND_AT "znalezione w" #define D_SYSLOG_HOST_NOT_FOUND "Syslog Host nie znaleziony" -#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Zapisane do pamięci flash w" diff --git a/sonoff/language/pt-BR.h b/sonoff/language/pt-BR.h index a57bc0056..1b2aa0ef9 100644 --- a/sonoff/language/pt-BR.h +++ b/sonoff/language/pt-BR.h @@ -213,7 +213,6 @@ #define D_MQTT_SERVICE_FOUND "Serviço MQTT encontrado em" #define D_FOUND_AT "encontrado em" #define D_SYSLOG_HOST_NOT_FOUND "Syslog anfitrião não encontrado" -#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Guardado na flash em" diff --git a/sonoff/language/pt-PT.h b/sonoff/language/pt-PT.h index f5397163b..54cc61d87 100644 --- a/sonoff/language/pt-PT.h +++ b/sonoff/language/pt-PT.h @@ -213,7 +213,6 @@ #define D_MQTT_SERVICE_FOUND "Serviço MQTT encontrado em" #define D_FOUND_AT "encontrado em" #define D_SYSLOG_HOST_NOT_FOUND "Syslog anfitrião não encontrado" -#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Guardado na flash em" diff --git a/sonoff/language/ru-RU.h b/sonoff/language/ru-RU.h index 2d3893e50..fbf006e3d 100644 --- a/sonoff/language/ru-RU.h +++ b/sonoff/language/ru-RU.h @@ -213,7 +213,6 @@ #define D_MQTT_SERVICE_FOUND "MQTT сервис service найдено" #define D_FOUND_AT "найдено в" #define D_SYSLOG_HOST_NOT_FOUND "System лог хост не найден" -#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Сохранено во флэш-память" diff --git a/sonoff/language/sk-SK.h b/sonoff/language/sk-SK.h index fb089b345..d26e418d0 100644 --- a/sonoff/language/sk-SK.h +++ b/sonoff/language/sk-SK.h @@ -213,7 +213,6 @@ #define D_MQTT_SERVICE_FOUND "Služba MQTT bola nájdená" #define D_FOUND_AT "nájdené v" #define D_SYSLOG_HOST_NOT_FOUND "Syslog Host nebol nájdený" -#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Uložené do flash pamäte v" diff --git a/sonoff/language/sv-SE.h b/sonoff/language/sv-SE.h index 1f7e3dbce..72b977208 100644 --- a/sonoff/language/sv-SE.h +++ b/sonoff/language/sv-SE.h @@ -213,7 +213,6 @@ #define D_MQTT_SERVICE_FOUND "MQTT-tjänst hittades på" #define D_FOUND_AT "hittades vid" #define D_SYSLOG_HOST_NOT_FOUND "Syslog-värd hittades inte" -#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Sparade till flash vid" diff --git a/sonoff/language/tr-TR.h b/sonoff/language/tr-TR.h index 6a0959804..4fae8e0cf 100755 --- a/sonoff/language/tr-TR.h +++ b/sonoff/language/tr-TR.h @@ -213,7 +213,6 @@ #define D_MQTT_SERVICE_FOUND "Üzerinden MQTT serivisi tespit edildi" #define D_FOUND_AT "(bulundu)" #define D_SYSLOG_HOST_NOT_FOUND "Syslog hostu bulunamadı" -#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Bellekten (Flash) kaydedidi:" diff --git a/sonoff/language/uk-UK.h b/sonoff/language/uk-UK.h index 67cbd6453..2b046389d 100644 --- a/sonoff/language/uk-UK.h +++ b/sonoff/language/uk-UK.h @@ -213,7 +213,6 @@ #define D_MQTT_SERVICE_FOUND "MQTT сервер знайдено" #define D_FOUND_AT "знайдено в" #define D_SYSLOG_HOST_NOT_FOUND "Сервер журналу не знайдено" -#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "Збережено в флэш-пам'ять" diff --git a/sonoff/language/zh-CN.h b/sonoff/language/zh-CN.h index 37f82a41d..8ca50943c 100644 --- a/sonoff/language/zh-CN.h +++ b/sonoff/language/zh-CN.h @@ -213,7 +213,6 @@ #define D_MQTT_SERVICE_FOUND "发现 MQTT 服务:" #define D_FOUND_AT "发现:" #define D_SYSLOG_HOST_NOT_FOUND "Syslog 主机未找到" -#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "保存到 flash:" diff --git a/sonoff/language/zh-TW.h b/sonoff/language/zh-TW.h index 8a5b549ad..bc535f70e 100644 --- a/sonoff/language/zh-TW.h +++ b/sonoff/language/zh-TW.h @@ -213,7 +213,6 @@ #define D_MQTT_SERVICE_FOUND "發現MQTT服務:" #define D_FOUND_AT "found at" #define D_SYSLOG_HOST_NOT_FOUND "Syslog主機未找到" -#define D_CONNECT_V6_ADDR_INFO "Got IPv6 global address" // settings.ino #define D_SAVED_TO_FLASH_AT "保存到 flash:" diff --git a/sonoff/support_wifi.ino b/sonoff/support_wifi.ino index 21820f303..fc2bc8056 100644 --- a/sonoff/support_wifi.ino +++ b/sonoff/support_wifi.ino @@ -252,7 +252,7 @@ void WifiBegin(uint8_t flag, uint8_t channel) for (auto a : addrList) { if(!a.isLocal() && !a.isLegacy()) { - AddLog_P2(LOG_LEVEL_INFO, PSTR(D_LOG_WIFI D_CONNECT_V6_ADDR_INFO " %s"),a.toString().c_str()); + AddLog_P2(LOG_LEVEL_INFO, PSTR("WIFi: Got IPv6 global address %s"),a.toString().c_str()); } } #endif From 7b1f9a533475daf9a2b08e783aee231f8e530e43 Mon Sep 17 00:00:00 2001 From: Theo Arends <11044339+arendst@users.noreply.github.com> Date: Fri, 11 Oct 2019 13:31:32 +0200 Subject: [PATCH 3/4] Fix future compiles --- platformio.ini | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/platformio.ini b/platformio.ini index 7c353d8fd..0340a7531 100755 --- a/platformio.ini +++ b/platformio.ini @@ -216,10 +216,10 @@ build_flags = ${esp82xx_defaults.build_flags} ;build_flags = ${core_2_4_2.build_flags} ;platform = ${core_2_5_2.platform} ;build_flags = ${core_2_5_2.build_flags} -;platform = ${core_stage.platform} -;build_flags = ${core_stage.build_flags} -platform = ${core_stage_ipv6.platform} -build_flags = ${core_stage_ipv6.build_flags} +platform = ${core_stage.platform} +build_flags = ${core_stage.build_flags} +;platform = ${core_stage_ipv6.platform} +;build_flags = ${core_stage_ipv6.build_flags} ;platform = ${core_pre.platform} ;build_flags = ${core_pre.build_flags} From 3ed790277e6cee8b14dfc7b969089d494eb91e3c Mon Sep 17 00:00:00 2001 From: Theo Arends <11044339+arendst@users.noreply.github.com> Date: Fri, 11 Oct 2019 13:32:25 +0200 Subject: [PATCH 4/4] Fix future compiles --- platformio.ini | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/platformio.ini b/platformio.ini index 0340a7531..00a5e7334 100755 --- a/platformio.ini +++ b/platformio.ini @@ -216,12 +216,12 @@ build_flags = ${esp82xx_defaults.build_flags} ;build_flags = ${core_2_4_2.build_flags} ;platform = ${core_2_5_2.platform} ;build_flags = ${core_2_5_2.build_flags} -platform = ${core_stage.platform} -build_flags = ${core_stage.build_flags} +;platform = ${core_stage.platform} +;build_flags = ${core_stage.build_flags} ;platform = ${core_stage_ipv6.platform} ;build_flags = ${core_stage_ipv6.build_flags} -;platform = ${core_pre.platform} -;build_flags = ${core_pre.build_flags} +platform = ${core_pre.platform} +build_flags = ${core_pre.build_flags} [common] framework = arduino