mirror of
https://github.com/wled/WLED.git
synced 2025-07-11 12:56:32 +00:00
Merge pull request #4222 from Aircoookie/esp8266-oappend-fix
Esp8266 oappend fix
This commit is contained in:
commit
19d837c222
@ -197,6 +197,7 @@ build_flags =
|
|||||||
; decrease code cache size and increase IRAM to fit all pixel functions
|
; decrease code cache size and increase IRAM to fit all pixel functions
|
||||||
-D PIO_FRAMEWORK_ARDUINO_MMU_CACHE16_IRAM48 ;; in case of linker errors like "section `.text1' will not fit in region `iram1_0_seg'"
|
-D PIO_FRAMEWORK_ARDUINO_MMU_CACHE16_IRAM48 ;; in case of linker errors like "section `.text1' will not fit in region `iram1_0_seg'"
|
||||||
; -D PIO_FRAMEWORK_ARDUINO_MMU_CACHE16_IRAM48_SECHEAP_SHARED ;; (experimental) adds some extra heap, but may cause slowdown
|
; -D PIO_FRAMEWORK_ARDUINO_MMU_CACHE16_IRAM48_SECHEAP_SHARED ;; (experimental) adds some extra heap, but may cause slowdown
|
||||||
|
-D NON32XFER_HANDLER ;; ask forgiveness for PROGMEM misuse
|
||||||
|
|
||||||
lib_deps =
|
lib_deps =
|
||||||
#https://github.com/lorol/LITTLEFS.git
|
#https://github.com/lorol/LITTLEFS.git
|
||||||
|
@ -324,6 +324,10 @@ class Usermod {
|
|||||||
protected:
|
protected:
|
||||||
// Shim for oappend(), which used to exist in utils.cpp
|
// Shim for oappend(), which used to exist in utils.cpp
|
||||||
template<typename T> static inline void oappend(const T& t) { oappend_shim->print(t); };
|
template<typename T> static inline void oappend(const T& t) { oappend_shim->print(t); };
|
||||||
|
#ifdef ESP8266
|
||||||
|
// Handle print(PSTR()) without crashing by detecting PROGMEM strings
|
||||||
|
static void oappend(const char* c) { if ((intptr_t) c >= 0x40000000) oappend_shim->print(FPSTR(c)); else oappend_shim->print(c); };
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
class UsermodManager {
|
class UsermodManager {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user