From 20de294a8cc5aa0e0ff10617416c1980dc1c3b44 Mon Sep 17 00:00:00 2001 From: Gunnar Skjold Date: Sun, 12 Jan 2025 18:21:40 +0100 Subject: [PATCH] Updated build --- .../src/PassiveMeterCommunicator.cpp | 4 ++++ platformio.ini | 20 ++++++++++++++++--- 2 files changed, 21 insertions(+), 3 deletions(-) diff --git a/lib/MeterCommunicators/src/PassiveMeterCommunicator.cpp b/lib/MeterCommunicators/src/PassiveMeterCommunicator.cpp index f00ac922..fac47446 100644 --- a/lib/MeterCommunicators/src/PassiveMeterCommunicator.cpp +++ b/lib/MeterCommunicators/src/PassiveMeterCommunicator.cpp @@ -366,7 +366,11 @@ int16_t PassiveMeterCommunicator::unwrapData(uint8_t *buf, DataParserContext &co break; case DATA_TAG_DSMR: if(dsmrParser == NULL) dsmrParser = new DSMRParser(gcmParser); + #if defined(AMS_REMOTE_DEBUG) res = dsmrParser->parse(buf, context, lastTag != DATA_TAG_NONE, debugger->isActive(RemoteDebug::VERBOSE) ? debugger : NULL); + #else + res = dsmrParser->parse(buf, context, lastTag != DATA_TAG_NONE, debugger); + #endif if(res >= 0) doRet = true; break; case DATA_TAG_SNRM: diff --git a/platformio.ini b/platformio.ini index 362e9177..46ae8f03 100755 --- a/platformio.ini +++ b/platformio.ini @@ -29,7 +29,7 @@ board_build.ldscript = eagle.flash.4m2m.ld build_flags = ${common.build_flags} -D AMS_REMOTE_DEBUG=1 lib_ldf_mode = off lib_compat_mode = off -lib_deps = ESP8266WiFi, ESP8266mDNS, ESP8266WebServer, ESP8266HTTPClient, ESP8266SSDP, EspSoftwareSerial@6.14.1, ${common.lib_deps}, SvelteUi +lib_deps = ESP8266WiFi, ESP8266mDNS, ESP8266WebServer, ESP8266HTTPClient, ESP8266httpUpdate, ESP8266SSDP, EspSoftwareSerial@6.14.1, ${common.lib_deps}, SvelteUi lib_ignore = ${common.lib_ignore} extra_scripts = ${common.extra_scripts} @@ -39,7 +39,12 @@ framework = arduino board = esp32dev board_build.f_cpu = 160000000L board_build.partitions = custom_partition.csv -build_flags = ${common.build_flags} +build_flags = + ${common.build_flags} + -D AMS_REMOTE_DEBUG=1 + -D AMS_KMP=1 + -L precompiled/esp32 + -lKmpTalker lib_ldf_mode = off lib_compat_mode = off lib_deps = ${esp32.lib_deps} @@ -80,6 +85,10 @@ board_build.partitions = custom_partition.csv build_flags = ${common.build_flags} -DFRAMEWORK_ARDUINO_SOLO1 + -D AMS_REMOTE_DEBUG=1 + -D AMS_KMP=1 + -L precompiled/esp32 + -lKmpTalker lib_ldf_mode = off lib_compat_mode = off lib_deps = ${esp32.lib_deps} @@ -92,7 +101,12 @@ framework = arduino board = esp32-c3-devkitm-1 board_build.mcu = esp32c3 board_build.partitions = custom_partition.csv -build_flags = ${common.build_flags} +build_flags = + ${common.build_flags} + -D AMS_REMOTE_DEBUG=1 + -D AMS_KMP=1 + -L precompiled/esp32c3 + -lKmpTalker lib_ldf_mode = off lib_compat_mode = off lib_deps = ${esp32.lib_deps}