espressif / arduino-esp32

Arduino core for the ESP32
GNU Lesser General Public License v2.1
13.2k stars 7.34k forks source link

Could you add an example of BLE mesh to the Arduino #5539

Closed anshilike closed 8 months ago

anshilike commented 3 years ago

I strongly recommend adding BLE mesh, which is found in ESP-IDF, but it is troublesome to install this software. As a novice, I use arduino a lot, but there are no ble mesh examples in The Arduino. Could you please add BLE mesh to the Arduino?

chegewara commented 3 years ago

You cant use BLE mesh with arduino-ide: https://github.com/espressif/arduino-esp32/blob/master/tools/sdk/esp32/sdkconfig#L405

Maybe you can do it using nimBLE, but im not sure.

lybgo commented 2 years ago

need an example of BLE mesh too

GodayMax commented 2 years ago

mark, wait for progress

arihantdaga commented 2 years ago

Is it available now ? How can we use some code examples shown in esp idf in our arduino projects. I tried to include these files into my Arduino projects-

#include "esp_ble_mesh_defs.h"
#include "esp_ble_mesh_common_api.h"

But it throws error saying cant find these libraries. :(

stale[bot] commented 2 years ago

Is this still relevant? If so, what is blocking it? Is there anything you can do to help move it forward?

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

arihantdaga commented 2 years ago

It's relavant. We need to implement BLE Mesh example for Arduino.

VojtechBartoska commented 2 years ago

Adding this to Documentation Roadmap.

mnour94 commented 1 year ago

Are there any updates on this? A BLE mesh implementation in Arduino would be greatly appreciated

VojtechBartoska commented 12 months ago

Can you take a look on this @lucasssvaz?

Current list of BLE examples is here: https://github.com/espressif/arduino-esp32/tree/master/libraries/BLE/examples

IDF examples: https://docs.espressif.com/projects/esp-idf/en/latest/esp32/api-guides/esp-ble-mesh/ble-mesh-index.html#esp-ble-mesh-examples

lucasssvaz commented 11 months ago

There's no BLE mesh library for now. A makeshift solution is required for the time being.

I modified some files to be able to properly compile and run the ESP-IDF example. Note that it requires to manually recompile the libraries to add support for specific BLE Mesh functions (this isn't trivial if you haven't done it before).

https://gist.github.com/lucasssvaz/bd105988aaf72ec291ecf94ecc2c692d

skyfly200 commented 11 months ago

Thanks for your help on this @lucasssvaz! I too am looking to use this functionality in Arduino

VojtechBartoska commented 8 months ago

Closing this as solved for now as @lucasssvaz provided workaround for IDF examples. For now, this is a first step, should be later on replaced by proper BLE Mesh library.

verdiluca commented 4 months ago

hi, @lucasssvaz @skyfly200 @VojtechBartoska I'm trying to compile the project of @lucasssvaz, but I saw that you have to modify the libraries but I didn't understand how to do it, would you be able to explain it to me? Thank you

lucasssvaz commented 4 months ago

@verdiluca Check https://github.com/espressif/esp32-arduino-lib-builder. You can edit the config files to suit your needs.

dtsitses commented 4 months ago

Hi @lucasssvaz @skyfly200 @VojtechBartoska. I'm trying to compile the project of @lucasssvaz but I'm getting multiple compilation errors. Checking the recommended lib builder here does not help as it's unclear what configuration changes are required, and also how the recompiled lib is referenced from the ino project which seems to still want to use the standard one installed in Arduino IDE via the board manager.

Would it be possible to make a step-by-step guide so that we can get this to work? Many thanks!

lucasssvaz commented 4 months ago

@dtsitses Sorry about that, I've updated the links in the gist to use the 5.1 tag of IDF. You should be able to find the options needed now. Also, we just added an UI to the lib builder. Feel free to try that (although it is probably still harder than just using Arduino as a component and changing the IDF settings).