You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Unable to Read BLE Characteristic using QuecPython #131
I am using the QuecPython library to connect to a Bluetooth Low Energy (BLE) device (NRF51822) and read its characteristics. However, I am encountering an issue where I am unable to successfully read a characteristic after discovering it.
The specific problem occurs when I attempt to read the Battery Level characteristic (UUID: 0x2a19). While I can successfully discover the services and characteristics, reading the characteristic using the UUID or handle results in failure or errors.
Steps to Reproduce
Scan for devices using ble.scan_start().
Connect to the target device using ble.client_connect() with the correct address.
Discover all services using ble.client_discover_services().
Discover characteristics using ble.client_discover_characteristics().
Read a characteristic (e.g., Battery Level 0x2a19) using ble.read_characteristic_by_uuid(0x2a19).
Logs/Output
Here’s the relevant portion of the log that I’ve observed:
event_id : BLE_GATT_DISCOVER_CHARACTERISTIC_DATA_IND, status = 0
pair_len=7, len=8, data: b'\x07\x13\x00\x02\x14\x00\x19*'
handle=0x0013, properties=0x2, value_handle=0x0014
short_uuid: 0x2a19
characteristic_list len = 1
event_id : BLE_GATT_ATT_ERROR_IND, status = 0
errcode = 0x000a
event_id : BLE_GATT_ATT_ERROR_IND, status = 0
errcode = 0x000a
The characteristic with short_uuid: 0x2a19 is discovered successfully.
When I attempt to read the characteristic, I receive an ATT_ERROR_IND with error code 0x000a.
Expected Behavior
I expect that the read_characteristic_by_uuid(0x2a19) method should successfully read the Battery Level characteristic value from the device.
Actual Behavior
The characteristic is discovered, but when I attempt to read it, I get the error ATT_ERROR_IND with error code 0x000a.
The read operation does not return the expected characteristic value.
Activity