micropython-lib
micropython-lib copied to clipboard
The order of bt_addr passed up in the ScanResult
In the aioble code there is a line like this:
self.addr: bytes = addr if len(addr) == 6 else binascii.unhexlify(addr.replace(":", ""))
The unhexify part with the colons suggests the bt address is passed up to the application in big endian. You don't see BT addresses expressed in little endian with colons.
The normal way one would write the BT address on a device is ae:f4:27:9F:d2:ee
. In BLE this would be transmitted as ee d2 9f 27 f4 ae
.
It's not clear what I get in ScanResult.device.addr
is it ee d2 9f 27 f4 ae
or ae f4 27 9F d2 ee
?