Changed the default value of ARDUINOJSON_ENABLE_PROGMEM (fixes #1433)

It now checks that the pgm_read_XXX macros are defined before enabling PROGMEM.
This commit is contained in:
Benoit Blanchon committed 2020-11-10 14:58:31 +01:00
1 parent aa7cc5351c
commit 16e51b83ab
2 files changed
+4 -1

No files matched your search

+2 -1
View File
@@ -172,7 +172,8 @@
#endif // ARDUINO
#ifndef ARDUINOJSON_ENABLE_PROGMEM
#ifdef PROGMEM
#if defined(PROGMEM) && defined(pgm_read_byte) && defined(pgm_read_dword) && \
defined(pgm_read_ptr) && defined(pgm_read_float)
#define ARDUINOJSON_ENABLE_PROGMEM 1
#else
#define ARDUINOJSON_ENABLE_PROGMEM 0