I'm writing a BLE central/client app that performs an active scan to discover devices.
The peripheral device I'm interested in sends some of its advertisement data in the ADV_IND message and some in the SCAN_RSP message.
My app gets the BLE_GAP_EVENT_DISC callback events for the ADV_IND messages but NOT for the SCAN_RSP.
I tried a few different variations in the struct ble_gap_disc_params, but none has worked. I just don't get callbacks for the SCAN_RSP messages.
And I know for sure the peripheral device is sending the SCAN_RSP messages, because I can see them with a BLE sniffer.
I'm using ESP-IDF 5.1.4.
Any ideas?
BLE central app doesn't get SCAN_RSP callback events during an active scan
Re: BLE central app doesn't get SCAN_RSP callback events during an active scan
Never mind folks... I figured out the issue.
The reason my app was not getting the SCAN_RSP callbacks was that I had the BT_NIMBLE_ROLE_OBSERVER feature disabled in the sdkconfig.
Once I enabled it and rebuilt, the app started getting the SCAN_RSP callbacks.
It may be worth adding a comment about this to the pop-up help for this config option. At the moment it doesn't say much about it...
The reason my app was not getting the SCAN_RSP callbacks was that I had the BT_NIMBLE_ROLE_OBSERVER feature disabled in the sdkconfig.
Once I enabled it and rebuilt, the app started getting the SCAN_RSP callbacks.
It may be worth adding a comment about this to the pop-up help for this config option. At the moment it doesn't say much about it...
Who is online
Users browsing this forum: Google [Bot] and 190 guests