pygatt icon indicating copy to clipboard operation
pygatt copied to clipboard

Unable to handle duplicate characteristic UUIDs

Open sVnsation opened this issue 6 years ago • 0 comments

The bgapi implementation can handle only one of duplicate/multiple IDs.

For example a BLE Smart Tracker device can have multiple "Alert Level" characteristics:

  • Service UUID 0X1802 "Immediate Alert" with characteristic 0x2A06 "Alert Level"
  • Service UUID 0X1803 "Link Loss" with characteristic 0x2A06 "Alert Level"

Screenshot_20190719-221036_nRF Connect

0x2a06 is found twice as approved characteristic, but only one handle is created.

INFO:pygatt.backends.bgapi.bgapi:Found approved characteristic 00002a00-0000-1000-8000-00805f9b34fb
INFO:pygatt.backends.bgapi.bgapi:Found approved characteristic 00002a01-0000-1000-8000-00805f9b34fb
INFO:pygatt.backends.bgapi.bgapi:Found approved characteristic 00002a04-0000-1000-8000-00805f9b34fb
INFO:pygatt.backends.bgapi.bgapi:Found approved characteristic 00002a05-0000-1000-8000-00805f9b34fb
INFO:pygatt.backends.bgapi.bgapi:Found approved characteristic 00002a07-0000-1000-8000-00805f9b34fb
INFO:pygatt.backends.bgapi.bgapi:Found approved characteristic **00002a06**-0000-1000-8000-00805f9b34fb
INFO:pygatt.backends.bgapi.bgapi:Found approved characteristic **00002a06**-0000-1000-8000-00805f9b34fb
INFO:pygatt.backends.bgapi.bgapi:Found approved characteristic 00002a19-0000-1000-8000-00805f9b34fb
INFO:pygatt.backends.bgapi.bgapi:Found approved characteristic 00002a29-0000-1000-8000-00805f9b34fb
INFO:pygatt.backends.bgapi.bgapi:Found approved characteristic 00002a27-0000-1000-8000-00805f9b34fb
INFO:pygatt.backends.bgapi.bgapi:Found approved characteristic 00002a26-0000-1000-8000-00805f9b34fb
INFO:pygatt.backends.bgapi.bgapi:Found approved characteristic 00002a23-0000-1000-8000-00805f9b34fb
INFO:pygatt.backends.bgapi.bgapi:Characteristic 0x00002a05-0000-1000-8000-00805f9b34fb is handle 0xa
INFO:pygatt.backends.bgapi.bgapi:Characteristic descriptor 0x00002902-0000-1000-8000-00805f9b34fb is handle 0xb
INFO:pygatt.backends.bgapi.bgapi:Characteristic **0x00002a06**-0000-1000-8000-00805f9b34fb is handle 0x14
INFO:pygatt.backends.bgapi.bgapi:Characteristic 0x00002a07-0000-1000-8000-00805f9b34fb is handle 0xe
INFO:pygatt.backends.bgapi.bgapi:Characteristic 0x00002a29-0000-1000-8000-00805f9b34fb is handle 0x1b
INFO:pygatt.backends.bgapi.bgapi:Characteristic 0x00002a26-0000-1000-8000-00805f9b34fb is handle 0x1f
INFO:pygatt.backends.bgapi.bgapi:Characteristic descriptor 0x00002902-0000-1000-8000-00805f9b34fb is handle 0x29
INFO:pygatt.backends.bgapi.bgapi:Characteristic 0x00002a27-0000-1000-8000-00805f9b34fb is handle 0x1d
INFO:pygatt.backends.bgapi.bgapi:Characteristic 0x00002a19-0000-1000-8000-00805f9b34fb is handle 0x17
INFO:pygatt.backends.bgapi.bgapi:Characteristic descriptor 0x00002902-0000-1000-8000-00805f9b34fb is handle 0x18
INFO:pygatt.backends.bgapi.bgapi:Characteristic descriptor 0x00002902-0000-1000-8000-00805f9b34fb is handle 0x2f
INFO:pygatt.backends.bgapi.bgapi:Characteristic 0x00002a00-0000-1000-8000-00805f9b34fb is handle 0x3
INFO:pygatt.backends.bgapi.bgapi:Characteristic 0x00002a01-0000-1000-8000-00805f9b34fb is handle 0x5
INFO:pygatt.backends.bgapi.bgapi:Characteristic 0x00002a23-0000-1000-8000-00805f9b34fb is handle 0x21
INFO:pygatt.backends.bgapi.bgapi:Characteristic 0x00002a04-0000-1000-8000-00805f9b34fb is handle 0x7

sVnsation avatar Jul 19 '19 20:07 sVnsation