Defined BLE setAdvertisementType (#3535)

Currently we have no way to set BLE Advertisement Type.
We have an initial value of ADV_TYPE_IND and the member is private.

iBeacon should advertise with ADV_TYPE_NONCONN_IND.
esp-idf's example code specifies this value.

93a8603c54/examples/bluetooth/bluedroid/ble/ble_ibeacon/main/ibeacon_demo.c (L57)
This commit is contained in:
syonbori
2020-01-20 22:42:38 +09:00
committed by Me No Dev
parent c2b37d95e0
commit 915d45de7d
3 changed files with 7 additions and 1 deletions

View File

@ -65,6 +65,7 @@ void setBeacon() {
pAdvertising->setAdvertisementData(oAdvertisementData);
pAdvertising->setScanResponseData(oScanResponseData);
pAdvertising->setAdvertisementType(ADV_TYPE_NONCONN_IND);
}