dmazzella / uble

Lightweight Bluetooth Low Energy driver written in pure python for micropython

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Suspected incorrect usage of uctypes offset

pfalcon opened this issue · comments

"length": uctypes.UINT8 | 1,
this defines a structure where UINT16 "opcode" field as at offset 0, then UINT8 "length" field is at offset 1, i.e. overlaps "opcode" field.

There're similar cases below that line too. Are these structure definitions actually used/tested?

No one of the structures defined in uble/bluetooth_low_energy/protocols/hci/init.py are used.
Now fixed, thanks for the segnalation.