uhppoted / uhppoted-python

PyPI package for the UHPPOTED Python API
MIT License
5 stars 0 forks source link

Fix event decoding #3

Closed twystd closed 8 months ago

twystd commented 9 months ago

Events from event listener are incorrectly decoded:

return Event(
        unpack_uint32(packet, 4),
        unpack_uint32(packet, 8),
        unpack_uint8(packet, 12),
        unpack_bool(packet, 13),
        unpack_uint8(packet, 14),
        unpack_uint8(packet, 15),
        unpack_uint32(packet, 16),
        unpack_datetime(packet, 20),
        unpack_uint8(packet, 27),
        unpack_shortdate(packet, 51),
        unpack_time(packet, 37),
        unpack_uint8(packet, 36),     <<<< 28
        unpack_bool(packet, 28),      <<<< 29
        unpack_bool(packet, 29),      <<<< 30
        unpack_bool(packet, 30),      <<<< 31
        unpack_bool(packet, 31),      <<<< 32
        unpack_bool(packet, 32),      <<<< 33
        unpack_bool(packet, 33),      <<<< 34
        unpack_bool(packet, 34),      <<<< 35
        unpack_bool(packet, 35),      <<<<< 49
        unpack_uint8(packet, 49),     <<<<< 50
        unpack_uint8(packet, 50),     <<<<< 36
        unpack_uint8(packet, 48),
        unpack_uint32(packet, 40),
    )
uhppoted commented 8 months ago

Released as uhppoted-v0.8.7.1