cancel
Showing results for 
Search instead for 
Did you mean: 

how to do an operation on specific BLE link

DS.4
Senior II

ACI_HAL_GET_LINK_STATUS will give an Array of link status (eight links).

My question is how do I do operations on specific links of my choice?

e.g., start an advertisement on a specific link.

 

reference AN5270 - 

DS4_0-1705176521476.png

 

2 REPLIES 2
_Joe_
ST Employee

Hi DS.4,
You can look at the p2pRouter example, which allows you to control multiple device servers via a client device.
The idea is to use the Connection Handle to perform specific operations on the different links.
BLE_p2pRouteur 

I hope it will help you. If you have any other questions later, don't hesitate to come back to me.

Joé, BR.

Ok, I think I understand.

When connected - I need to search the connection-handle-array. My specific handle will be in the index of the link.

 

But what if I am not connected yet?

On advertising start, one of the links will turn to 'Advertising' status,  what link will it be? Is there a rule? Should I sample it after advertising starts? What if that link gets connected and I start advertising again, what link will turn 'Advertising' now?  I mean you should probably have a clearer answer on how this works!