-
Couldn't load subscription status.
- Fork 330
Closed
Labels
Backend: Core BluetoothIssues and PRs relating to the Core Bluetooth backendIssues and PRs relating to the Core Bluetooth backend
Description
- bleak version: 0.6.1
- Python version:3.6.3
- Operating System: macOS 10.15.4
Was connected to "lego control plus"
Description
inside of BleakClientCoreBluetooth.write_gatt_char
line:
success = await cbapp.central_manager_delegate.connected_peripheral_delegate.writeCharacteristic_value_type_(
characteristic.obj,
value,
CBCharacteristicWriteWithResponse if response else CBCharacteristicWriteWithoutResponse
)
where
CBCharacteristicWriteWithResponse equal 0
CBCharacteristicWriteWithoutResponse equal 1
and inside of writeCharacteristic_value_type_
if response:
await event.wait()
So when write_gatt_char called with response=False inside of writeCharacteristic_value_type_ it will wait forever.
It looks like doing this conversion value right on the call of writeValue_forCharacteristic_type_ will fix it.
amacf
Metadata
Metadata
Assignees
Labels
Backend: Core BluetoothIssues and PRs relating to the Core Bluetooth backendIssues and PRs relating to the Core Bluetooth backend