Closed deltaphi closed 1 year ago
Testing revealed that - at least for the tested case - the meter in question uses twos' complement and this change prints out the values directly.
Hi @deltaphi. Thanks for adding this PR. Your request should have been solved within #7.
When observing the current power value and running a energy production unit (e.g., solar power on your own roof), it appears that in at least some meters the current power value is provided as a two-byte value in twos' complement representation (to be fully verified).
This change lets SML Parser parse two-byte values. In addition, it performs sign extension in case of negative values.