extmod/modbluetooth: Replace def_handle with end_handle in char IRQ.
This is technically a breaking change, but: a) We need the end handle to do descriptor discovery properly. b) We have no possible use for the existing definition handle in the characteristic result IRQ. None of the methods can use it, and therefore no existing code should be using it in a way that changing it to a different integer value should break. Unfortunately NimBLE doesn't make it easy to get the end handle, so also implement a mechanism to use the following characteristic to calculate the previous characteristic's end handle. Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
This commit is contained in:
committed by
Damien George
parent
82fc16f298
commit
cacc96d98c
@@ -166,7 +166,7 @@ Event Handling
|
||||
conn_handle, status = data
|
||||
elif event == _IRQ_GATTC_CHARACTERISTIC_RESULT:
|
||||
# Called for each characteristic found by gattc_discover_services().
|
||||
conn_handle, def_handle, value_handle, properties, uuid = data
|
||||
conn_handle, end_handle, value_handle, properties, uuid = data
|
||||
elif event == _IRQ_GATTC_CHARACTERISTIC_DONE:
|
||||
# Called once service discovery is complete.
|
||||
# Note: Status will be zero on success, implementation-specific value otherwise.
|
||||
|
||||
Reference in New Issue
Block a user