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

How to connect multiple peripherals to one central by using pc-ble-driver-py binding?

Hi, all,

I am working on nRF52832 using pc-ble-driver-py bindings to interface my BLE peripheral. Now I want to build the BLE communication between one central to multi-peripherals, but I don't know how to do this. Did anyone already manage to use pc-ble-driver-py to connect multiple devices or have some examples which explain how to do it?

Any help or suggestions would be appreciated.

Parents
  • Hi,

    The heart_rate_collector example is almost there: It has a define CONNECTIONS that you can increase in order to get several connections.

    Depending on your use case you might want to keep track of the connection handles. (In the HRC example this is not needed as everything is handled in the HRCollector event handlers. See the HRCollector implementation, and conn_handle in main())

    Regards,
    Terje

  • Hi Terje,

    Could you explain it more in detail? Im currently trying to connect multiple peripherals to the dongle with heart_rate_collector example, but once i connected with one of the peripheral, there are no more adv_report and i could not connect with other peripherals. Could you explain it more in detail?

    Moreover, i do found there is a BLEEnableParams, which has peripherals count, but thats for Sofedevice ver 2 right? I'm using nrf_sd_ble_api_ver == 5,  and what should i change to make it work?

    Regards,

    ZIJI

Reply
  • Hi Terje,

    Could you explain it more in detail? Im currently trying to connect multiple peripherals to the dongle with heart_rate_collector example, but once i connected with one of the peripheral, there are no more adv_report and i could not connect with other peripherals. Could you explain it more in detail?

    Moreover, i do found there is a BLEEnableParams, which has peripherals count, but thats for Sofedevice ver 2 right? I'm using nrf_sd_ble_api_ver == 5,  and what should i change to make it work?

    Regards,

    ZIJI

Children
No Data
Related