- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Do any of the examples support a central that advertises while its also communicating to slaves?
Central should never connect to another central; it's just advertising as a way to broadcast its ID and status.
Solved! Go to Solution.
- Labels:
-
MasterSlave
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
A BLE connection is always between a central (master) and a peripheral (slave). Meanwhile a device can support 2 or more connections performing as a master in some and as a slave in others. Hello_client sample app shows how to create 2 simultaneous connections. It stops advertisements when it connects to the master and stops scanning when it connects to a slave, so it is 2 connections. But if you need to support more it should be straight forward. For example your application can continue scanning and when correct advertisement is detected, connect another slave. 20736/20737 supports up to 8 connected slaves, or 1 connected master and 7 connected slaves, or 1 connected master and doing advertisements and 6 connected slaves, or 2 connected masters and 6 connected slaves.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
A BLE connection is always between a central (master) and a peripheral (slave). Meanwhile a device can support 2 or more connections performing as a master in some and as a slave in others. Hello_client sample app shows how to create 2 simultaneous connections. It stops advertisements when it connects to the master and stops scanning when it connects to a slave, so it is 2 connections. But if you need to support more it should be straight forward. For example your application can continue scanning and when correct advertisement is detected, connect another slave. 20736/20737 supports up to 8 connected slaves, or 1 connected master and 7 connected slaves, or 1 connected master and doing advertisements and 6 connected slaves, or 2 connected masters and 6 connected slaves.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I don't think this answered my question.
Can a central advertise while also, at the same time, scanning, connecting, communicating, disconnecting with multiple peripherals?
At boot, we want central to start advertising indefinitely while it also scans, connects, communicates, disconnects, and then scans/connects/communicates/disconnects to other peripherals, up to 6 simultaneously, again and again.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
dbell, the answer is yes. Please check hello_client app. It performs as a central in a connection to a hello_sensor app. It also advertises and allows connection from other devices (for example an iPhone).
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Centrals typically do not advertise. I'm not sure how this works when devices can act as both central and peripheral (20736 supports this).