fix: send Position value correctly

This commit is contained in:
əlemi 2023-03-16 23:01:28 +01:00
parent eb934a5a06
commit e74da435ea
Signed by: alemi
GPG key ID: A4895B84D311642C

View file

@ -224,8 +224,8 @@ class PositionType(Type):
UnsignedLong.write(packed, buffer, ctx=ctx) UnsignedLong.write(packed, buffer, ctx=ctx)
else: else:
packed = ((0x3FFFFFF & data[0]) << 38) \ packed = ((0x3FFFFFF & data[0]) << 38) \
| ((0xFFF & data[2]) << 12) \ | ((0x3FFFFFF & data[2]) << 12) \
| (0x3FFFFFF & data[1]) | (0xFFF & data[1])
UnsignedLong.write(packed, buffer, ctx=ctx) UnsignedLong.write(packed, buffer, ctx=ctx)
pass pass