diff --git a/bricknil/sensor/peripheral.py b/bricknil/sensor/peripheral.py index 9ba0dc5..a767956 100644 --- a/bricknil/sensor/peripheral.py +++ b/bricknil/sensor/peripheral.py @@ -130,12 +130,12 @@ def _convert_bytes(self, msg_bytes:bytearray, byte_count): If multiple values, then a list of those values Value can be either uint8, uint16, or uint32 depending on value of `byte_count` """ - if byte_count == 1: # just a uint8 - val = msg_bytes[0] - elif byte_count == 2: # uint16 little-endian - val = struct.unpack('