esphome_elektromer_han/components/dlms_push
Tomer27cz a9e13b6e8c Optimize DlmsParser allocations and types
Use stack buffers and C-strings to avoid heap allocations, and modernize token handling and ownership.

- Replace heap-allocated std::string temporaries in dlms_parser.cpp with stack buffers and pass const char* to callbacks/logs to reduce allocations and copying.
- Change DlmsDataCallback signature to accept const char* for obis and string values; update DlmsPushComponent to match.
- Switch DlmsParser ownership to std::unique_ptr in DlmsPushComponent and add <memory> include.
- Replace std::list with std::vector for DSL token parsing, update iteration/insertion logic accordingly.
- Remove unused <list> include and adjust related function signatures/whitespace.

These changes improve performance and memory usage; note the callback/API signature change may require updating any external callers.
2026-03-07 20:58:19 +01:00
..
__init__.py new dlms_push component 2026-03-07 13:06:16 +01:00
binary_sensor.py new dlms_push component 2026-03-07 13:06:16 +01:00
dlms_parser.cpp Optimize DlmsParser allocations and types 2026-03-07 20:58:19 +01:00
dlms_parser.h Optimize DlmsParser allocations and types 2026-03-07 20:58:19 +01:00
dlms_push.cpp Optimize DlmsParser allocations and types 2026-03-07 20:58:19 +01:00
dlms_push.h Optimize DlmsParser allocations and types 2026-03-07 20:58:19 +01:00
sensor.py new dlms_push component 2026-03-07 13:06:16 +01:00
text_sensor.py new dlms_push component 2026-03-07 13:06:16 +01:00