You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
|`DN`| descend into nested structure | control token |
95
92
|`UP`| return from nested structure | control token |
96
93
97
-
## API Reference
98
-
99
-
### `DlmsParser` Core Methods
100
-
101
-
> **⚠️ Warning:** If you intend to use encryption, you **must** provide a concrete `Aes128GcmDecryptor` backend to the constructor before calling `set_decryption_key` or `set_authentication_key`. Calling these methods on a parser initialized with the default `nullptr` decryptor will cause a null pointer dereference.
|`DlmsParser(Aes128GcmDecryptor* = nullptr)`| Constructor accepting an optional pointer to an AES-128-GCM decryptor backend. |
106
-
|`set_skip_crc_check(bool)`| Skip CRC/checksum validation for HDLC and M-Bus. |
107
-
|`set_decryption_key(const Aes128GcmDecryptionKey&)`| Set AES-128-GCM decryption key (GUEK). **Requires a non-null decryptor.**|
108
-
|`set_authentication_key(const Aes128GcmAuthenticationKey&)`| Set AES-128-GCM authentication key (GAK) for GCM tag verification. **Requires a non-null decryptor.**|
|`ParseResult parse(std::span<uint8_t> buf, const DlmsDataCallback&)`| Parse a complete frame; modifies the buffer in-place and triggers the callback. |
`dlms_parser` includes a built-in logging system that is useful for debugging frame parsing and pattern matching. You can hook into it by providing a custom log function:
Copy file name to clipboardExpand all lines: library.json
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
{
2
2
"name": "dlms_parser",
3
-
"version": "1.3.0",
3
+
"version": "2.0.0",
4
4
"description": "A C++20 library for parsing DLMS/COSEM push telegrams from electricity meters. It is designed for embedded and integration-heavy environments such as ESPHome",
0 commit comments