Skip to content
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

No advertising on multiple services? #1058

Closed
notanios opened this issue Mar 23, 2021 · 3 comments
Closed

No advertising on multiple services? #1058

notanios opened this issue Mar 23, 2021 · 3 comments

Comments

@notanios
Copy link

Just tried to follow example from BLE_server.ino. Added one more service by pAdvertising->addServiceUUID(MY_SERVICE);.

As I can see only first service is advertised and I'm not sure how to dig into the problem as I can't see latest code (idk why, the master is 2 years old).

I use lib directly from Arduino, 1.0.1 version.

What I did wrong?

@chegewara
Copy link
Collaborator

  1. i think you ar using arduino 1.0.4, since in 1.0.1 there is no ble integrated yet
  2. what UUIDs you are trying to advertise, there is length limit, 31 bytes, in advertising packet and some bytes are used to advertise TX power for example
  3. The future of this repo ... #813

@notanios
Copy link
Author

First of all BIG THANK YOU for the quick response and the response fact at all! 👍
I understand now that this repo has no clear future and code is shared across multiple vendors' libs.

Now to the question (if I may use some more of you attention :) ):

  1. I was talking about ESP32ble-arduino lib, not Arduino IDE. The version of the lib is 1.0.1 which seems to be the latest on Arduino from libs manager.
  2. Yes, I was unaware of this adv package size limit. I quickly read this issue and got wrong impression that there is no such limit.

Now, with your help, I figured it out. Thank you!

BTW, on #3. I'm learning how BLE stack works and would like to help if there is anything on table now. I mean related to this project/repo. Would be great though to have all code in one place considering majority of issue/request/questions coming here. Is there plan to update this repo (I see some closed pull requests but code apparently is not in master. Am I wrong?).

@chegewara
Copy link
Collaborator

  1. Latest arduino lib, arduino-esp32, is v1.0.5, soon v1.0.6
  2. you may want to use NimBLE instead, which has lower ram and flash requirements and is also available in arduino as library
    https://github.com/h2zero/NimBLE-Arduino

Both libraries are almost 100% compatible in API meaning.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants