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
Revision 38:02cf26a2a4db, committed 2014-05-22
- Comitter:
- Rohit Grover
- Date:
- Thu May 22 13:30:05 2014 +0100
- Parent:
- 37:7e8de07642e0
- Child:
- 39:a57137537521
- Commit message:
- add consts to the declaration of BLEDevice::setAddress()
Changed in this revision
| hw/BLEDevice.h | Show annotated file Show diff for this revision Revisions of this file |
| hw/Gap.h | Show annotated file Show diff for this revision Revisions of this file |
--- a/hw/BLEDevice.h Thu May 22 13:25:24 2014 +0100
+++ b/hw/BLEDevice.h Thu May 22 13:30:05 2014 +0100
@@ -41,7 +41,7 @@
* Set the BTLE MAC address and type.
* @return
*/
- ble_error_t setAddress(Gap::addr_type_t type, uint8_t address[6]);
+ ble_error_t setAddress(Gap::addr_type_t type, const uint8_t address[6]);
ble_error_t setAdvertisingData(GapAdvertisingData &ADStructures,
GapAdvertisingData &scanResponse);
@@ -55,7 +55,7 @@
virtual GattServer& getGattServer() = 0;
};
-inline ble_error_t BLEDevice::setAddress(Gap::addr_type_t type, uint8_t address[6]) {
+inline ble_error_t BLEDevice::setAddress(Gap::addr_type_t type, const uint8_t address[6]) {
return getGap().setAddress(type, address);
}
--- a/hw/Gap.h Thu May 22 13:25:24 2014 +0100
+++ b/hw/Gap.h Thu May 22 13:30:05 2014 +0100
@@ -44,7 +44,7 @@
} addr_type_t;
/* These functions must be defined in the sub-class */
- virtual ble_error_t setAddress(addr_type_t type, uint8_t address[6]) = 0;
+ virtual ble_error_t setAddress(addr_type_t type, const uint8_t address[6]) = 0;
virtual ble_error_t setAdvertisingData(GapAdvertisingData &,
GapAdvertisingData &) = 0;
virtual ble_error_t startAdvertising(GapAdvertisingParams &) = 0;
