Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Fork of BLE_API by
Diff: hw/BLEDevice.h
- Revision:
- 48:ec0c28e62abf
- Parent:
- 46:33d87f468a0d
- Child:
- 49:03a51f0006f8
--- a/hw/BLEDevice.h Fri May 23 17:05:53 2014 +0100
+++ b/hw/BLEDevice.h Fri May 23 17:28:44 2014 +0100
@@ -52,10 +52,6 @@
*/
ble_error_t setAddress(Gap::addr_type_t type, const uint8_t address[6]);
- ble_error_t setAdvertisingData(const GapAdvertisingData &ADStructures,
- const GapAdvertisingData &scanResponse);
- ble_error_t setAdvertisingData(const GapAdvertisingData &ADStructures);
-
/**
* @param[in] advType
* The GAP advertising mode to use for this device. Valid
@@ -139,6 +135,10 @@
* DEPRECATED
*/
public:
+ ble_error_t setAdvertisingData(const GapAdvertisingData &ADStructures,
+ const GapAdvertisingData &scanResponse);
+ ble_error_t setAdvertisingData(const GapAdvertisingData &ADStructures);
+
ble_error_t startAdvertising(const GapAdvertisingParams &advParams);
};
@@ -174,18 +174,6 @@
return transport->getGap().setAddress(type, address);
}
-inline ble_error_t
-BLEDevice::setAdvertisingData(const GapAdvertisingData &ADStructures,
- const GapAdvertisingData &scanResponse) {
- return transport->getGap().setAdvertisingData(ADStructures, scanResponse);
-}
-
-inline ble_error_t
-BLEDevice::setAdvertisingData(const GapAdvertisingData &ADStructures) {
- GapAdvertisingData scanResponse;
- return transport->getGap().setAdvertisingData(ADStructures, scanResponse);
-}
-
inline void
BLEDevice::setAdvertisingType(GapAdvertisingParams::AdvertisingType advType) {
advParams.setAdvertisingType(advType);
@@ -221,7 +209,22 @@
return transport->getGap().disconnect();
}
-/* DEPRECATED */
+/*
+ * ALL OF THE FOLLOWING METHODS ARE DEPRECATED
+ */
+
+inline ble_error_t
+BLEDevice::setAdvertisingData(const GapAdvertisingData &ADStructures,
+ const GapAdvertisingData &scanResponse) {
+ return transport->getGap().setAdvertisingData(ADStructures, scanResponse);
+}
+
+inline ble_error_t
+BLEDevice::setAdvertisingData(const GapAdvertisingData &ADStructures) {
+ GapAdvertisingData scanResponse;
+ return transport->getGap().setAdvertisingData(ADStructures, scanResponse);
+}
+
inline ble_error_t
BLEDevice::startAdvertising(const GapAdvertisingParams &_advParams) {
return transport->getGap().startAdvertising(_advParams);
