Hi,
I'm playing with beacon_3.40.4 reference project.
I'm trying to make it send just one advertising packed when button is pressed instead of continiously advertising.
I configured button and callback functions.
Please help me with following questions:
1.Which line to remove to avoid advertising after startup?
2. which function is used to modify advertising data
3. which function to call in button callback to start advertising - i tried app_adv_start() but it is now starting??
Thank you!
Device:
Hi hssmltd,
1. Remove the app_adv_start located in function app_db_init_complete_func().
2. There is no implemented function for changing advertising data. If you configure your app to use dynamic data (CFG_DYNAMIC_BEACON_DATA) then the application will change the major and the minor fields of the advertising string with the values from P01 channel. There are a lot of posts in the forum indicating how to change the data in the advertising string dynamically please check other forum posts.
3. To start advertising you can call app_adv_start(), check with a ble application or with smart snippets to confirm that your device is advertising.
Thanks MT_dialog
它与你的帮助工作正常。谢谢! !