Implement per-field matching of ScanRecord.
As part of building out support for robustly matching Bluetooth LE devices in the wild, this change checks all "fields" contained in a ScanRecord against a given BytesMatcher. To support matching variable-length Eddystone beacons, this change also expands BytesMatcher to support both exact length and prefix based rules, which are then used with rules that verify that example Eddystone and iBeacon values can be detected with these rules: Eddystone: ⊆0016AAFE/00FFFFFF iBeacon: ⊆00FF4C0002/00FFFFFFFF Expands testing to confirm all newly added capabilities are working. Bug: 181812624 Test: atest BluetoothTests:android.bluetooth.le Test: atest FrameworksCoreTests:android.os.BytesMatcherTest Change-Id: I1cff8e08604436f4bba6f55aad64c3ce5969bf56
Loading
Please register or sign in to comment