Is it possible to be BLE master and slave at the same time?

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Anonymous
Not applicable

Hi all,

I'm wondering if it is possible for a BCM20737 chip to behave as a BLE master and slave at the same time.

I have done the following tests so far:

1. First of all I have created two applications, APP_X is BLE master and APP_Y is BLE slave.

APP_X (BLE master): contains GATT database, send advertisement, discoverable

APP_Y (BLE slave): no GATT database, non-discoverable, only scan for advertisement.

They can pair with each other and communicate successfully.

2. Then I want to let APP_Y(BLE slave) work as a master, and connect it with my phone (like a slave). 

So I add another GATT database into APP_Y, make it discoverable and send its own advertisement.

if APP_Y is not connected to APP_X, I can successfully connect APP_Y using my phone, so it means APP_Y can work like a BLE master.

3. Here comes the problem:

(1) If I make APP_Y discoverable then start APP_X, even though APP_Y can receive APP_X's advertisement, the connection up event never occurs. So the BLE connection between APP_X and APP_Y can never be established.

Only when I make APP_Y non-discoverable, it can connect with APP_X successfully.

(2) If APP_Y is already connected with my phone, APP_Y can receive APP_X's advertisement, but connection up even never occurs as well.

This time even if I make APP_Y non-discoverable, it cannot connect with APP_X anyway.

From my test result, it seems that it is possible for a BCM20737 chip to be BLE master and slave at the same time, because the advertisement can be received without problem, but somehow the API blecen_Conn(HIGH_CONN, evt->wd_addr, evt->addressType); doesn't trigger the connection up event.

Could anyone tell me how to let BCM20737 chip to connect both a BLE master and a BLE slave at the same time?

Thanks

Jingdong

0 Likes
1 Solution

This thread summarizes the Simultaneous Master/Slave feature: Additional master/slave questions on BCM20736/7 family

To investigate our support for Simultaneous Master/Slave, take a look at the hello_client and hello_sensor applications within the SDK.

View solution in original post

4 Replies
BoonT_56
Employee
Employee
500 likes received 250 likes received 100 likes received

Have you got a chance to review this blog?

Testing Master and Slave Roles

0 Likes
Anonymous
Not applicable

Yes, I have read that blog. But it doesn't answer my question.

Basically I know how to establish BLE connection between a master device and a slave device. And I have no problems to connect two slaves using one master.

However, the question is: Can a device be master and slave at the same time?

0 Likes

This thread summarizes the Simultaneous Master/Slave feature: Additional master/slave questions on BCM20736/7 family

To investigate our support for Simultaneous Master/Slave, take a look at the hello_client and hello_sensor applications within the SDK.

Anonymous
Not applicable

Thanks mwf_mmafe,

It is really nice to see BCM20737 can support simultaneous master/slave.

I will learn from the hello_client and hello_sensor applications in SDK and provide more reply later.

0 Likes