Does not support signed integers
pwood opened this issue · comments
Peter Wood commented
Bytecodec needs to support marshalling signed integers, this is currently done in shimmeringbee/zcl
so some knowledge can be transfered.
Peter Wood commented
Correction, the code that's has support for signed ints is the bitbuffer in bytecodec.
https://github.com/shimmeringbee/bytecodec/blob/master/bitbuffer/int.go#L17
This might just be a case of adding catches for the reflection types in marshalValue/unmarshalValue, and calling the right bitbuffer function.
Needs tests, and beer after dealing with 2's complement negative numbers in tests.