mirror of
https://github.com/kawasaki/pyscrlink.git
synced 2026-01-06 11:40:16 +01:00
It turned out that bluepy Peripheral's getCharacteristics() and getServiceByUUID() accesses shared resource with other bluepy APIs. Then it needs guard with lock in same manner as other bluepy API calls. Guard them with the lock of the session. Introduce _get_characteristic() and _get_service() helper functions to wrap the API calls with lock guard, and replace API calls with them. Also remove unnecessary getCharacteristics() calls. Signed-off-by: Shin'ichiro Kawasaki <kawasaki@juno.dti.ne.jp>
24 KiB
Executable File
24 KiB
Executable File