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.len = 1 + 1;
adv.val = ADV_FLAGS;
adv.data = LE_GENERAL_DISCOVERABLE /* LE_LIMITED_DISCOVERABLE */ | BR_EDR_NOT_SUPPORTED;
sprintf(ad_name_frame, "zz %d %3d %2d %4d"
adv.len = strlen(ad_name_frame) + 1;
adv.val = ADV_LOCAL_NAME_COMP;
Is this resolved? I spoke with the developers and they said that there are examples within the SDK which show how to format advertisements.