Please help learn the NimBLE stack

listout
Posts: 31
Joined: Wed Mar 16, 2022 10:54 am

Please help learn the NimBLE stack

Postby listout » Sun Mar 20, 2022 7:22 pm

I want to learn the NimBLE stack of the ESP-IDF. I've been learning about BLE lately but I want to use the NimBLE. Basically I want to implement a NimBLE GATT client and server scenario where the client and server would exchange date (integer numbers).

I was looking at the examples (central and peripheral), I can't understand a single thing. Please share if you have any code references or documentation from where I can learn, I'm also looking at the official espressif nimble documentation but there isn't much. The bluedroid ble has an excellent example/walkthrough.

Thanks
listout


Zeni241
Posts: 86
Joined: Tue Nov 20, 2018 4:28 am

Re: Please help learn the NimBLE stack

Postby Zeni241 » Sat Dec 17, 2022 2:17 pm

I was looking at the examples (central and peripheral), I can't understand a single thing
It was the same for me :lol: :roll:

Then I consulted many resources and finally I got there!
I have uploaded the code with explanations on GitHub for my future reference. ( https://github.com/Zeni241/ESP32-NimbleBLE-For-Dummies ) .
But it would be my pleasure if anybody benefit from it. You can also comment and suggest improvements.

oni_01
Posts: 1
Joined: Mon Nov 20, 2023 9:45 am

Re: Please help learn the NimBLE stack

Postby oni_01 » Thu Dec 14, 2023 4:33 pm

Man thanks for your repo, I'm looking on nimBLE for ESP-IDF but is really hard to find specific documentation about right now!

irahul
Posts: 46
Joined: Fri Jun 18, 2021 10:07 am

Re: Please help learn the NimBLE stack

Postby irahul » Fri Dec 15, 2023 6:58 am

Since ESP-IDF clones the upstream Apache mynewt-nimble codebase, all documentation provided by mynewt-nimble is applicable.

The examples in the IDF ( under examples/bluetooth/nimble/..) path have their READMEs and tutorials for walkthrough. Is there anything else you looking for which is not covered in this documentation ?

devlat
Posts: 15
Joined: Thu Oct 29, 2020 9:33 am

Re: Please help learn the NimBLE stack

Postby devlat » Sun Feb 25, 2024 4:23 pm

What is really lacking is example how to write BLE HID central or peripheral in NimBLE which is rather popular demand. ESP-IDF has blecent and bleprph examples, but it does not help much if you are new to the concept of characteristics, services etc.
You have to learn a lot. But once you do, you will probably start using another stack, which is better written and more clean.
This is how i came to Bluekitchen Btstack and will never change it to anything else ...

irahul
Posts: 46
Joined: Fri Jun 18, 2021 10:07 am

Re: Please help learn the NimBLE stack

Postby irahul » Mon Feb 26, 2024 4:26 am

Hi devlat, there is example for hid under examples/bluetooth/esp_hid_device and examples/bluetooth/esp_host. This is targetted for both bluedroid and nimble. Does this not help your cause ?

devlat
Posts: 15
Joined: Thu Oct 29, 2020 9:33 am

Re: Please help learn the NimBLE stack

Postby devlat » Wed Feb 28, 2024 11:29 am

The bluetooth/esp_hid_host is pure Bluedroid example and is not related to NimBLE (it needs CONFIG_BT_BLUEDROID_ENABLED=y).
Do i miss something?
Oh, i see CONFIG_BT_NIMBLE_ENABLED was added to the sample not long ago! I guess you mean this. Thanks for informaton!

irahul
Posts: 46
Joined: Fri Jun 18, 2021 10:07 am

Re: Please help learn the NimBLE stack

Postby irahul » Wed Feb 28, 2024 2:38 pm

Yes .. the example was recently updated to support both stacks .

devlat
Posts: 15
Joined: Thu Oct 29, 2020 9:33 am

Re: Please help learn the NimBLE stack

Postby devlat » Wed Feb 28, 2024 2:55 pm

Good job! Thank you!

Who is online

Users browsing this forum: Baidu [Spider], Bing [Bot] and 157 guests