diff --git a/examples/completeExample/completeExample.cpp b/examples/completeExample/completeExample.cpp index 364a4f9..7617e94 100644 --- a/examples/completeExample/completeExample.cpp +++ b/examples/completeExample/completeExample.cpp @@ -35,7 +35,7 @@ #warning use decorators: { HeapSelectIram doAllocationsInIRAM; ESPUI.addControl(...) ... } (cf. https://arduino-esp8266.readthedocs.io/en/latest/mmu.html#how-to-select-heap) #warning then check http:///heap #endif // MMU_IRAM_HEAP -#ifndef DEBUG_ESP_OOM +#if !defined(DEBUG_ESP_OOM) && !defined(CORE_MOCK) #error on ESP8266 and ESPUI, you must define OOM debug option when developping #endif #endif @@ -396,7 +396,8 @@ void extendedCallback(Control* sender, int type, void* param) Serial.print(sender->label); Serial.print("' = "); Serial.println(sender->value); - Serial.println(String("param = ") + String((int)param)); + Serial.print("param = "); + Serial.println((long)param); } void setup() { @@ -443,6 +444,7 @@ void loop() { #if !defined(ESP32) ((void (*)())0xf00fdead)(); #endif + break; default: Serial.print('#'); break; diff --git a/examples/completeExample/completeExample.ino b/examples/completeExample/completeExample.ino index ff7bd09..a4db808 100644 --- a/examples/completeExample/completeExample.ino +++ b/examples/completeExample/completeExample.ino @@ -1 +1,4 @@ // placeholder +#if CORE_MOCK +#include "completeExample.cpp" +#endif diff --git a/examples/gui-generic-api/gui-generic-api.ino b/examples/gui-generic-api/gui-generic-api.ino index 815e66d..54f003b 100644 --- a/examples/gui-generic-api/gui-generic-api.ino +++ b/examples/gui-generic-api/gui-generic-api.ino @@ -16,7 +16,7 @@ DNSServer dnsServer; #warning use decorators: { HeapSelectIram doAllocationsInIRAM; ESPUI.addControl(...) ... } (cf. https://arduino-esp8266.readthedocs.io/en/latest/mmu.html#how-to-select-heap) #warning then check http:///heap #endif // MMU_IRAM_HEAP -#ifndef DEBUG_ESP_OOM +#if !defined(DEBUG_ESP_OOM) && !defined(CORE_MOCK) #error on ESP8266 and ESPUI, you must define OOM debug option when developping #endif #endif @@ -67,7 +67,8 @@ void buttonCallback(Control* sender, int type) void buttonExample(Control* sender, int type, void* param) { - Serial.println(String("param: ") + String(long(param))); + Serial.print("param: "); + Serial.println(long(param)); switch (type) { case B_DOWN: diff --git a/examples/gui/gui.ino b/examples/gui/gui.ino index 1aca2f1..759ed07 100644 --- a/examples/gui/gui.ino +++ b/examples/gui/gui.ino @@ -16,7 +16,7 @@ DNSServer dnsServer; #warning use decorators: { HeapSelectIram doAllocationsInIRAM; ESPUI.addControl(...) ... } (cf. https://arduino-esp8266.readthedocs.io/en/latest/mmu.html#how-to-select-heap) #warning then check http:///heap #endif // MMU_IRAM_HEAP -#ifndef DEBUG_ESP_OOM +#if !defined(DEBUG_ESP_OOM) && !defined(CORE_MOCK) #error on ESP8266 and ESPUI, you must define OOM debug option when developping #endif #endif @@ -72,7 +72,8 @@ void buttonCallback(Control* sender, int type) void buttonExample(Control* sender, int type, void* param) { - Serial.println(String("param: ") + String(long(param))); + Serial.print("param: "); + Serial.println(long(param)); switch (type) { case B_DOWN: diff --git a/examples/tabbedGui/tabbedGui.ino b/examples/tabbedGui/tabbedGui.ino index 7aa0b2f..a862aa9 100644 --- a/examples/tabbedGui/tabbedGui.ino +++ b/examples/tabbedGui/tabbedGui.ino @@ -16,7 +16,7 @@ DNSServer dnsServer; #warning use decorators: { HeapSelectIram doAllocationsInIRAM; ESPUI.addControl(...) ... } (cf. https://arduino-esp8266.readthedocs.io/en/latest/mmu.html#how-to-select-heap) #warning then check http:///heap #endif // MMU_IRAM_HEAP -#ifndef DEBUG_ESP_OOM +#if !defined(DEBUG_ESP_OOM) && !defined(CORE_MOCK) #error on ESP8266 and ESPUI, you must define OOM debug option when developping #endif #endif @@ -66,7 +66,8 @@ void buttonCallback(Control* sender, int type) void buttonExample(Control* sender, int type, void* param) { - Serial.println(String("param: ") + String(long(param))); + Serial.print("param: "); + Serial.println(long(param)); switch (type) { case B_DOWN: