Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Implement functions to retrieve multiple connected devices #105

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
polldo wants to merge 6 commits into arduino-libraries:master
base: master
Choose a base branch
Loading
from polldo:multi-connection

Conversation

Copy link
Contributor

@polldo polldo commented Aug 11, 2020

These functions can be used to loop the connected devices, centrals or peripherals, through an index that can go from 0 to the maximum number of connected devices allowed.
Example:

for (int periphIdx = 0; periphIdx < BLE.peripheralCount(); periphIdx++) {
 BLEDevice peripheral = BLE.peripheral(periphIdx);
 if (peripheral) {
 BLECharacteristic batteryLevelChar = peripheral.characteristic("2A19");
 if (!batteryLevelChar) {
 Serial.println("Peripheral does not have battery level characteristic!");
 peripheral.disconnect();
 }
 }
}

tomaculum reacted with thumbs up emoji
Copy link

CLAassistant commented Apr 9, 2021
edited
Loading

CLA assistant check
All committers have signed the CLA.

alranel added a commit to rduino-libraries/rduinoBLE that referenced this pull request May 7, 2022
Copy link

phyxl commented Jul 28, 2022

I need this functionality for my project. Has this library lost support?

@per1234 per1234 added type: enhancement Proposed improvement topic: code Related to content of the project itself labels Aug 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Reviewers

@facchinm facchinm Awaiting requested review from facchinm

Assignees
No one assigned
Labels
topic: code Related to content of the project itself type: enhancement Proposed improvement
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

AltStyle によって変換されたページ (->オリジナル) /