This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

pc_ble_driver_py takes a lot of time to discover services, characteristics, and descriptors

Hi everyone.

I'm using pc_ble_driver_py with nRF52840 USB dongle with burned connectivity_4.1.1_usb_with_s140_6.1.1.hex.

pc_ble_driver_py is modified by me to support BLE5.0 features.

It looks like everything works well, but timings spent on the discovering services, characteristics, and descriptors are too long (up to 25-30 seconds) and depend on PC used.

I have localized the place where most of the time spent, it is between sending the command via UART (ASIO library) to BLE dongle and waiting for the response.

I was trying to decrease connection interval, but discovery timings stay the same.

Also, I have tried to use pc_ble_driver DLL in bare C, but here timings are well.

Does this issue is known? Or do you have any suggestions on how to decrease discovery timings?

Thanks.

Parents Reply Children
  • Hi,

    Looking at the sniffer trace  I see that the connection interval is 80 ms, but you are probably right that it doe snot have a large effect. There is a significant overhead using serialization. Also, I see a  there is a lot of Find Information Requests and responses back and forth, so you are trying to discover all services. That takes a long time. You could speed it ut by looking for specific services, as suggested here.

  • Also, I see a  there is a lot of Find Information Requests and responses back and forth, so you are trying to discover all services. That takes a long time.

    Yes, we are discovering all services, characteristics, and descriptors, but the main issue here is that when we using DLL in C code the timing is OK. We have a timing issue only when we use wrapped DLL with Python.

  • Hi,

    I see. I do not see any reason why there is a significant difference between pc-ble-driver and pc-ble-driver-py. Let me loo into it and get back to you.

  • Hi Einar, 

    Do you have any progress with my case?

  • Hi,

    I bumped the issue now and talked to the developer. He is looking into it and hopefully, we will have some updates soon.