I have checked in Nordic Devzone for this query but no luck in finding solution for my query.
I am using nrf52832 and configured as central and peripheral.
my device will scan and store peer address in flash and then connect to stored address later.
when i connect to peer address using sd_ble_gap_connect it returns NRF_SUUCESS but BLE_GAP_EVT_CONNECTED is not triggered.
this issue occurs only for some peripherals and some peripheral i can able to connect and it triggers event as well.
tested with one of the example code: when i try to connect peripheral device programmed with ble_app_uart code this issue occurs where BLE_GAP_EVT_CONNECTED is not triggered.
but the same peripheral connects successfully through my Android phone.
i am unable understand what is the issue.
Maybe you're getting BLE_GAP_EVT_TIMEOUT. Are you checking for that event?
Hi i checked for timeout conditions. but no luck.
I am still facing the same issue.
You should always get either BLE_GAP_EVT_CONNECTED or BLE_GAP_EVT_TIMEOUT unless you cancel the connection by a call to sd_ble_gap_connect_cancel(), as you can see from this MSC. Can you share your code so that we can check to see if there is any possibility of you canceling the connection or missing an event?
Hi i changed scan parameter timeout = 0x01 instead of 0. now i am getting ble gap event timeout error in BLE_GAP_EVT_TIMEOUT event.
How to solve
I think you should get the connected event even if the connection hasn't been established yet, so I agree that you must be missing the event somehow.