- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
We want our central to advertise its ID all the time.
But it only sends the ad set at boot-time specified by .local_name in the BLE_PROFILE_CFG array.
When we change the ad, it still keeps sending the boot-time data.
We copied the method to set the ad from our peripheral, which updates its ad ok.
Here's how we set the ad:
char ad_name_frame[LOCAL_NAME_LEN_MAX + 1];
adv[0].len = 1 + 1;
adv[0].val = ADV_FLAGS;
adv[0].data[0] = LE_GENERAL_DISCOVERABLE /* LE_LIMITED_DISCOVERABLE */ | BR_EDR_NOT_SUPPORTED;
sprintf(ad_name_frame, "zz %d %3d %2d %4d"
adv[1].len = strlen(ad_name_frame) + 1;
adv[1].val = ADV_LOCAL_NAME_COMP;
strcpy(adv[1].data, ad_name_frame);
bleprofile_GenerateADVData(adv, BLE_ADV_FIELD_ELEMENTS);
Solved! Go to Solution.
- Labels:
-
MasterSlave
-
SDK 2.X
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Is this resolved? I spoke with the developers and they said that there are examples within the SDK which show how to format advertisements.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Is this resolved? I spoke with the developers and they said that there are examples within the SDK which show how to format advertisements.