Hi all,
I have faced with issue that using NimBle it is not possible to connect more than one client to GATT Server !!
Test was done based on esp_idf/examples/bluetooth/nimble/bleprph
I have not found how to configure NimBle stack to have multiple connections (:
Have anyone faced with the same issue ? Any help would be appreciated ...
ESP32-WROOM NimBle cannot connect multiple clients to GATT server
-
- Posts: 45
- Joined: Thu Aug 22, 2019 3:48 am
Re: ESP32-WROOM NimBle cannot connect multiple clients to GATT server
I believe there is a parameter in the menuconfig settings for the number of connections - have you checked that?
(I say 'believe' because I've not needed to change it but I do recall seeing it there - I'm not able to check right now.)
Susan
(I say 'believe' because I've not needed to change it but I do recall seeing it there - I'm not able to check right now.)
Susan
Re: ESP32-WROOM NimBle cannot connect multiple clients to GATT server
Thank you for relay, but I have already figured out the issue !!Aussie Susan wrote: ↑Mon Apr 13, 2020 4:36 amI believe there is a parameter in the menuconfig settings for the number of connections - have you checked that?
(I say 'believe' because I've not needed to change it but I do recall seeing it there - I'm not able to check right now.)
Susan
It was due to this implementation:
Code: Select all
case BLE_GAP_EVENT_CONNECT:
/* A new connection was established or a connection attempt failed. */
MODLOG_DFLT(INFO, "connection %s; status=%d ",
event->connect.status == 0 ? "established" : "failed",
event->connect.status);
if (event->connect.status == 0) {
rc = ble_gap_conn_find(event->connect.conn_handle, &desc);
assert(rc == 0);
bleprph_print_conn_desc(&desc);
}
MODLOG_DFLT(INFO, "\n"); if (event->connect.status != 0) {
/* Connection failed; resume advertising. */
bleprph_advertise();
}
return 0;
Proper code should be as following:
Code: Select all
case BLE_GAP_EVENT_CONNECT:
/* A new connection was established or a connection attempt failed. */
MODLOG_DFLT(INFO, "connection %s; status=%d ",
event->connect.status == 0 ? "established" : "failed",
event->connect.status);
if (event->connect.status == 0) {
rc = ble_gap_conn_find(event->connect.conn_handle, &desc);
assert(rc == 0);
bleprph_print_conn_desc(&desc);
}
MODLOG_DFLT(INFO, "\n");
bleprph_advertise();
return 0;
Who is online
Users browsing this forum: Google [Bot] and 82 guests