このような特定の ScanResult に接続した後
bluetoothGatt = scanResult.getDevice().connectGatt(getActivity(), false, new MyBluetoothGattCallback());
私は AndroidsBluetoothGatt.discoverServices()
メソッドを呼び出し、BluetoothGattCallback.onServicesDiscovered()
私は を呼び出しgetServices()
ますBluetoothGatt
。
サービスと関連する特性を一覧表示すると、期待どおりの結果が得られます。iPad の LightBlue でシミュレートされたこの Peripheral で 1 つの特性を持つ 1 つのサービスである必要がありますが、さらに多くのサービスがあります..私のログを見てください:
MyBluetoothGattCallback﹕ service: 00001800-0000-1000-8000-00805f9b34fb MyBluetoothGattCallback﹕ characteristic: 00002a00-0000-1000-8000-00805f9b34fb MyBluetoothGattCallback﹕ characteristic: 00002a01-0000-1000-8000-00805f9b34fb MyBluetoothGattCallback﹕ service: 00001801-0000-1000-8000 -00805f9b34fb MyBluetoothGattCallback﹕ characteristic: 00002a05-0000-1000-8000-00805f9b34fb MyBluetoothGattCallback﹕ service: d0611e78-bbb4-4591-a5f8-487910ae4366 MyBluetoothGattCallback﹕ characteristic: 8667556c-9a37-4c91-84ed-54ee27d90049 MyBluetoothGattCallback﹕ service: 7905f431-b5ce-4e99 -a40f-4b1e122d00d0 MyBluetoothGattCallback﹕ 特性: 69d1d8f3-45e1-49a8-9821-9bbdfdaad9d9 MyBluetoothGattCallback﹕ 特性: 9fbf120d-6301-42d9-8c58-25e699a21dbd MyBluetoothGattCallback﹕ 特性:22eac6e9-24d6-4bb5-be44-b36ace7c7bfb MyBluetoothGattCallback﹕ service: 0000180f-0000-1000-8000-00805f9b34fb MyBluetoothGattCallback﹕ characteristic: 00002a19-0000-1000-8000-00805f9b34fb MyBluetoothGattCallback﹕ service: 00001805-0000-1000-8000-00805f9b34fb MyBluetoothGattCallback﹕ characteristic: 00002a2b-0000-1000-8000-00805f9b34fb MyBluetoothGattCallback﹕ characteristic: 00002a0f-0000-1000-8000-00805f9b34fb MyBluetoothGattCallback﹕ service: 89d3502b-0f36-433a-8ef4-c502ad55f8dc MyBluetoothGattCallback﹕ characteristic: 9b3c81d8-57b1-4a8a-b8df-0e56f7ca51c2 MyBluetoothGattCallback﹕ 特性: 2f7cabce-808d-411f-9a0c-bb92ba96c102 MyBluetoothGattCallback﹕ 特性: c6b2f38c-23ab-46d8-a6ab-a3a870bbd5d7 MyBluetoothGattCallback﹕ サービス: 00001111-0000-1000-8000-903Bluetooth00002222-0000-1000-8000-00805f9b34fb
なぜ私がそこで多くのサービスを受けられるのか、誰か説明してもらえますか? キャッシングで何かありますか?