Include Extended Advertising Functionality of NimBLE
Posted: Wed Dec 18, 2019 12:00 pm
In the source code of NimBLE, there is a set of extended functionality for advertisement which is controlled by the MYNEWT_VAL_BLE_EXT_ADV preprocessor flag (including 'ble_gap_ext_adv_start()' and 'ble_gap_ext_adv_configure()' functions). However, this flag is turned off by default and there is no option in menuconfig to enable it.
I tried multiple ways to set this flag including adding the following line to my project's CMakeLists.txt:
But it didn't work.
The only way which worked is by including the above line in NimBLE components' CMakeLists.txt (bt). But this is not a good solution since I don't want to modify the IDF files.
Appreciate any help.
I tried multiple ways to set this flag including adding the following line to my project's CMakeLists.txt:
Code: Select all
target_compile_options(${COMPONENT_LIB} PUBLIC "-DMYNEWT_VAL_BLE_EXT_ADV=1")
The only way which worked is by including the above line in NimBLE components' CMakeLists.txt (bt). But this is not a good solution since I don't want to modify the IDF files.
Appreciate any help.