Can ble_app_multilink_central example connect to more than 8 peripheral devices?

Hi,

I trying to adapt the ble_app_multilink_central example to allow more than 8 peripheral connections to the central device. However, when I change NRF_SDH_BLE_TOTAL_LINK_COUNT in sdk_config.h to be any value greater than 8 the LED on my board does not light up. I am using a nrf52840DK and plan to flash it onto custom boards with the same chip. 

(this part in the config file)

// <o> NRF_SDH_BLE_CENTRAL_LINK_COUNT - Maximum number of central links. 
#ifndef NRF_SDH_BLE_CENTRAL_LINK_COUNT
#define NRF_SDH_BLE_CENTRAL_LINK_COUNT 8
#endif

// <o> NRF_SDH_BLE_TOTAL_LINK_COUNT - Total link count. 
// <i> Maximum number of total concurrent connections using the default configuration.

#ifndef NRF_SDH_BLE_TOTAL_LINK_COUNT
#define NRF_SDH_BLE_TOTAL_LINK_COUNT 8
#endif


Does anyone know how I can enable the program to allow more than 8 connections?

Thanks.

Parents
  • Hi

    Does the DK not work or light up at all if you increase the TOTAL LINK COUNT of your project? What are you trying to set it to exactly? The maximum number of links will be 20, and the TOTAL_LINK_COUNT must be => BLE_CENTRAL_LINK_COUNT + BLE_PERIPHERAL_LINK_COUNT.

    You should do some debugging to see what exactly is happening. Enable debug logging and see what return values are returned by I.E. the SoftDevice or BLE stack init function if setting this higher than 8.

    Best regards,

    Simon

  • Hi Simon,

    Thanks for the reply. I am using the nrf5 sdk and altering the ble_app_multilink_central example. How do I enable debug logging in Segger IDE? 

    Does the DK not work or light up at all if you increase the TOTAL LINK COUNT of your project?

    Yes, the DK does not work or light up after I increase BLE_CENTRAL_LINK_COUNT and TOTAL_LINK_COUNT to 9. I pressed the BOOT/RESET button after I built and downloaded the solution onto the DK as well.

    Best Regards,

    Glen

  • I figured out how to view the debug messages and here's what I got:

    <info> app_timer: RTC: initialized.
    <debug> app: nrf_sdh_enable_request() returned: 0x0
    <debug> app: nrf_sdh_ble_default_cfg_set() returned: 0x0
    <warning> nrf_sdh_ble: Insufficient RAM allocated for the SoftDevice.
    <warning> nrf_sdh_ble: Change the RAM start location from 0x200043A8 to 0x20004880.
    <warning> nrf_sdh_ble: Maximum RAM size for application is 0x3B780.
    <error> nrf_sdh_ble: sd_ble_enable() returned NRF_ERROR_NO_MEM.
    <debug> app: nrf_sdh_ble_enable() returned: 0x4
    <error> app: ERROR 4 [NRF_ERROR_NO_MEM] at ...


    It looks like I need to allocate more memory for the RAM, but I'm not should how I should configure my RAM so that the solution does fit. Additionally, I hope to get up to 20 total devices connected, would that be feasible with the nrf52840 chip?

    Best Regards,

    Glen

Reply
  • I figured out how to view the debug messages and here's what I got:

    <info> app_timer: RTC: initialized.
    <debug> app: nrf_sdh_enable_request() returned: 0x0
    <debug> app: nrf_sdh_ble_default_cfg_set() returned: 0x0
    <warning> nrf_sdh_ble: Insufficient RAM allocated for the SoftDevice.
    <warning> nrf_sdh_ble: Change the RAM start location from 0x200043A8 to 0x20004880.
    <warning> nrf_sdh_ble: Maximum RAM size for application is 0x3B780.
    <error> nrf_sdh_ble: sd_ble_enable() returned NRF_ERROR_NO_MEM.
    <debug> app: nrf_sdh_ble_enable() returned: 0x4
    <error> app: ERROR 4 [NRF_ERROR_NO_MEM] at ...


    It looks like I need to allocate more memory for the RAM, but I'm not should how I should configure my RAM so that the solution does fit. Additionally, I hope to get up to 20 total devices connected, would that be feasible with the nrf52840 chip?

    Best Regards,

    Glen

Children
No Data
Related