我正在使用WiPy 2.0 Pycom板。
当试图解析可用设备的名称时,名称不能正确解析。
bluetooth.resolve_adv_data(adv.data,Bluetooth.ADV_NAME_CMPL)这一行打印以下数据。
None
HE<�@?�'�?打印短名时
bluetooth.resolve_adv_data(adv.data,Bluetooth.ADV_NAME_SHORT)它打印出“零”
如何获得扫描设备的正确名称。我对此很陌生
谢谢!
发布于 2018-01-19 12:22:34
利用制造商的数据,我们可以从传感器获得适当的数据。
mfg_data = bluetooth.resolve_adv_data(adv.data, Bluetooth.ADV_MANUFACTURER_DATA)
advData = binascii.hexlify(mfg_data)https://stackoverflow.com/questions/47279274
复制相似问题