Can I make DA14580 to switch between Central and Peripheral

7 posts / 0 new
Last post
sabasit
Offline
Last seen:11 months 6 days ago
Expert
Joined:2014-10-14 14:20
Can I make DA14580 to switch between Central and Peripheral

Hi,

I am using DA14580 in peripheral mode with SPS profile in FE mode. I however have previously run it in Central role in FH mode as well. Now i need to extend the functionality of the same device to act as Central device for some peripheral devices and on other times use SPS profile to make it act as peripheral. Besides loading two different firmware is it possible to swap the role from peripheral to central and vice a versa in the same firmware? Any examples or guideline available for that.

Thanks,
Basit

Device:
MT_dialog
Offline
Last seen:3 weeks 18 hours ago
Staff
Joined:2015-06-08 11:34
Hi sabasit,

Hi sabasit,

There is no available example for this but you can swicth roles between central and peripheral by reseting the stack in every change, the steps you must follow are:

- send a GAPM_RESET_CMD to the stack.

- GAPM_SET_DEV_CONFIG in order to set the role as central or peripheral.

- start advertising or scanning.

Thanks MT_dialog

YuanhangWu
Offline
Last seen:4 years 9 months ago
Expert
Joined:2015-03-25 08:19
Hi,all.

Hi,all.
I search this switch between Central and Peripheral too.
In Central mode: I want to know where handler(collecter) scan result;when connect command with a address (select a Peripheral 's from collecter) is send,how to increase the rate of connected.

Yes,the rate of connected is low,how to handler with Central and Peripheral.

thanks.

MT_dialog
Offline
Last seen:3 weeks 18 hours ago
Staff
Joined:2015-06-08 11:34
Hi YuanhangWu,

Hi YuanhangWu,

I am not sure i understand the question, when scanning for peripherals you should have a GAPM_ADV_REPORT_IND event for every located device and handle it in the app_on_adv_report_ind (in SDK5). What do you mean how to increase the rate of connected ? At the moment the peripherals can support only one connection. From centrals side the maximum connections is 6 on the 580 and 8 on the 581.

Thanks MT_dialog

sabasit
Offline
Last seen:11 months 6 days ago
Expert
Joined:2014-10-14 14:20
Thank MT_dialog,

Thank MT_dialog,
我要一些天尝试的角色转换的s. I am using Serial Port Profile for this.

One more basic question. The actual data rate of BLE module depends upon SPI bus/UART speed, is it right understanding?. For example using a serial port profile in FH configuration and UART interface, RS232 baudrate will define the actual data rate? If right, how much maximum BLE controller usually support knowing External Processor have other things to do as well normally.?

Thanks,

MT_dialog
Offline
Last seen:3 weeks 18 hours ago
Staff
Joined:2015-06-08 11:34
Hi sabasit,

Hi sabasit,

Since the application reads the uart port at a specific speed it isn't possible for the ble data to exceed the data rate of the uart. In general the maximum throughput is determimed by the selected baud rate. I dont get your other question though, can you please elaborate a bit.

Thanks MT_dialog

sabasit
Offline
Last seen:11 months 6 days ago
Expert
Joined:2014-10-14 14:20
Hi MT_dialog,

Hi MT_dialog,

I have made role switching between peripheral and central role based on your suggestion about commands GAPM_RESET_CMD and GAPM_SET_DEV_CONFIG. Thank you for help.

thanks,
sabasit

Topic locked