OK, this is going to be a strange request, but I want to check if it's possible.
Thegapm_start_advertise_cmd
struct contains agapm_adv_host
struct, which contains theadv_data_len
and theadv_data
:
/// Advertising data length - maximum 28 bytes, 3 bytes are reserved to set
/// Advertising AD type flags, shall not be set in advertising data
uint8_t adv_data_len;
/// Advertising data
uint8_t adv_data[ADV_DATA_LEN-3];
As stated in the comment, 3 more bytes are sent in addition to theadv_data
- an ad-structure of: 0x02, 0x01, flags-byte (length, ad-type of "flags", value).
Is it possible to remove this ad-structure and control the whole 31 bytes directly?
The reason I'm requesting this feature is that I want to advertise an iBeacon packet, similar to:http://stackoverflow.com/questions/18906988/what-is-the-ibeacon-bluetoot...
(the first 3-bytes ad-structure 0x02, 0x01, 0x1A is not really necessary - iOS detects the iBeacon even without it).
The 27 bytes that the iBeacon format requires leaves me exactly 4 bytes to send additional data: 2 bytes for the ad-structure header (0x03, 0x08 for "shortened local name") and 2 bytes of value.
Obviously, I can send the additional information in the scan-response packet, but this reduces the probability that the additional information is received.
I know that I may not be following the BLE\GAP\GATT standards...
Hi Oren,
Our stack on DA14580 follows the standard BLE stack and can not compose and sending out illegal packet, which will be prohibit by our kernel. So please use the scan response to carry out more information you hope to deliver.
Regards!
Percy Yu
hi,PY_Dialog
BLUETOOTH SPECIFICATION permit no flag AD,please reconsider the unneccesary limit.
“ The Flags AD type shall be included in the advertising data if any of the bits are non-zero. The Flags AD type may be omitted from the advertising data if all of the bits are zero.”
so is there a way i can remove the ad flag?