Hi
from what I could find, it seems that a function to set the scan response data is missing in the framework.
We do have the corresponding event:
ESP_GAP_BLE_SCAN_RSP_DATA_SET_COMPLETE_EVT
and we also have a member (set_scan_rsp) in the esp_ble_adv_data_t struct that it seems to suggest that you can create a struct for the scan response packet... but I couldn't find a way to use it.
Of course you can use the corresponding "raw" version: esp_ble_gap_config_scan_rsp_data_raw().
Am I missing something?
Thanks
No esp_ble_gap_config_scan_rsp_data() ?
Re: No esp_ble_gap_config_scan_rsp_data() ?
Hi,
to setup response advertising data its enough to set this value to true:
set_scan_rsp in the esp_ble_adv_data_t
If its set to false it will setup normal advertising data.
to setup response advertising data its enough to set this value to true:
set_scan_rsp in the esp_ble_adv_data_t
If its set to false it will setup normal advertising data.
-
- Posts: 64
- Joined: Tue Jan 10, 2017 1:09 pm
Re: No esp_ble_gap_config_scan_rsp_data() ?
Hi
thanks for your response.
How can I pass the two structs to the driver? I have to call the function esp_ble_gap_config_adv_data(&adv_data) twice?
thanks for your response.
How can I pass the two structs to the driver? I have to call the function esp_ble_gap_config_adv_data(&adv_data) twice?
Re: No esp_ble_gap_config_scan_rsp_data() ?
Yes, you need to call esp_ble_gap_config_adv_data twice. One time with adv_data as parameter and one time with scan_rsp_data.
https://github.com/espressif/esp-idf/bl ... emo.c#L327
https://github.com/espressif/esp-idf/bl ... emo.c#L333
And again, here is parameter that tells which one is scan response and which one is not:
https://github.com/espressif/esp-idf/bl ... emo.c#L100
https://github.com/espressif/esp-idf/bl ... emo.c#L116
All other parameters you can set as you wish.
https://github.com/espressif/esp-idf/bl ... emo.c#L327
https://github.com/espressif/esp-idf/bl ... emo.c#L333
And again, here is parameter that tells which one is scan response and which one is not:
https://github.com/espressif/esp-idf/bl ... emo.c#L100
https://github.com/espressif/esp-idf/bl ... emo.c#L116
All other parameters you can set as you wish.
-
- Posts: 64
- Joined: Tue Jan 10, 2017 1:09 pm
Re: No esp_ble_gap_config_scan_rsp_data() ?
thanks again, it works fine!
Who is online
Users browsing this forum: No registered users and 250 guests