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

Switching from Peripheral to Central nrf52

Our current project (custom nrf52 board SDK12.2) is set up as a peripheral device with the phone being the central device. This nrf52 device is plugged in and power consumption is not an issue. We would like to have more than 1 phone be able to be connected to the nrf52 device at one time and make settings changes. Am I correct in my assumption that the nrf52 set up as a central device can handle multiple connections? What changes in my program will need to be made when changing an existing project from peripheral to central. I assume the phone app will have lots of changes since it will be the one advertising. I also assume I should still need peer manager running to handle bonding with the phone (peripheral).

Thanks in advance,

Bryan

  • Hi Bryan,

    First of all you can run S132 Soft Device on nRF52 with multiple concurrent connections and with the latest SD version V4.x these can be any type. So you can port your project to S132 V3 and run one GAP Peripheral + one (or more) GAP Central connections or port it to V4 and run multiple GAP Peripheral connections at the same time. In every case there will be certain work (firstly with pure 1:1 porting and then with adding all structures and calls to handle separate GAP and GATT roles - where applicable) and it can be pretty extensive to debug such system to certain productivity level. Similar on mobile side. Luckily for both nRF52 and Android/iOS GAP and GATT roles there are many examples (in nRF5 SDK, Nordic mobile apps on GitHub and all over the internet). And finally yes, if you use peer manager module from nRF5 SDK and you like it then you can use it to manage bonds on all connections regardless GAP or GATT role used.

    Cheers Jan

Related