weliem / blessed-bluez

BLE library using Java and Bluez
MIT License
76 stars 23 forks source link

How to get advertising package by bluez? #16

Closed zhuyuemings closed 1 year ago

zhuyuemings commented 1 year ago

i need to get advertising package to verify something, but i can only get manufacturer data from scan result,

weliem commented 1 year ago

Bluez doesn't provide access to the lowlevel advertisement (yet).

What do you need?

zhuyuemings commented 1 year ago

I tried to get the advertising package(broadcast message?) like this: image but only get manufacturer data from scan result, like this:

image
ranjitIN commented 1 year ago

if your device advertise this details you can get this advertisement data from scan result or from peripheral peripheral is an object of BluetoothPeripheral
peripheral.getDevice().getManufacturerData() it returns you a Map<Integer, byte[]>