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 210:0c14030d1bd0, committed 2014-12-01
- Comitter:
- rgrover1
- Date:
- Mon Dec 01 14:31:18 2014 +0000
- Parent:
- 209:c92872ad8935
- Child:
- 211:f181effe5de3
- Commit message:
- Synchronized with git rev 076ade55
Author: Rohit Grover
rename configure() to configureGAP(); and remove duplication of this call from resetDefaults().
Changed in this revision
| services/URIBeaconConfigService.h | Show annotated file Show diff for this revision Revisions of this file |
--- a/services/URIBeaconConfigService.h Mon Dec 01 14:31:18 2014 +0000
+++ b/services/URIBeaconConfigService.h Mon Dec 01 14:31:18 2014 +0000
@@ -89,7 +89,7 @@
}
strcpy(reinterpret_cast<char *>(uriData), uriDataIn);
- configure();
+ configureGAP();
if (initSucceeded) {
saveDefaults();
}
@@ -129,7 +129,7 @@
*/
void setFlags(uint8_t flagsIn) {
flags = flagsIn;
- configure();
+ configureGAP();
}
/**
@@ -144,7 +144,7 @@
*/
void useTxPowerMode(TXPowerModes_t mode) {
effectiveTxPower = powerLevels[mode];
- configure();
+ configureGAP();
}
/**
@@ -154,14 +154,14 @@
*/
void setBeaconPeriod(uint16_t beaconPeriodIn) {
beaconPeriod = beaconPeriodIn;
- configure();
+ configureGAP();
}
private:
/**
* Setup the advertisement payload and GAP settings.
*/
- void configure(void) {
+ void configureGAP(void) {
const uint8_t BEACON_UUID[] = {0xD8, 0xFE};
payloadIndex = 0;
@@ -302,7 +302,7 @@
} else if (params->charHandle == resetChar.getValueAttribute().getHandle()) {
resetDefaults();
}
- configure();
+ configureGAP();
ble.setAdvertisingPayload();
}
@@ -324,8 +324,6 @@
ble.updateCharacteristicValue(uriDataChar.getValueAttribute().getHandle(), uriData, uriDataLength);
ble.updateCharacteristicValue(flagsChar.getValueAttribute().getHandle(), &flags, 1 /* size */);
ble.updateCharacteristicValue(beaconPeriodChar.getValueAttribute().getHandle(), reinterpret_cast<uint8_t *>(&beaconPeriod), sizeof(uint16_t));
-
- configure();
}
private:
