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 788:2a6a8313f393, committed 2015-08-11
- Comitter:
- rgrover1
- Date:
- Tue Aug 11 15:13:13 2015 +0100
- Parent:
- 787:d6d7087d8377
- Child:
- 789:89433790768b
- Commit message:
- Synchronized with git rev eec3f351
Author: Rohit Grover
URIBeaconConfigService: move declarations of some local variables closer to their use.
Changed in this revision
| ble/services/URIBeaconConfigService.h | Show annotated file Show diff for this revision Revisions of this file |
--- a/ble/services/URIBeaconConfigService.h Tue Aug 11 15:13:13 2015 +0100
+++ b/ble/services/URIBeaconConfigService.h Tue Aug 11 15:13:13 2015 +0100
@@ -184,9 +184,6 @@
/* Helper function to switch to the non-connectible normal mode for URIBeacon. This gets called after a timeout. */
void setupURIBeaconAdvertisements()
{
- uint8_t serviceData[SERVICE_DATA_MAX];
- unsigned serviceDataLen = 0;
-
/* Reinitialize the BLE stack. This will clear away the existing services and advertising state. */
ble.shutdown();
ble.init();
@@ -209,6 +206,8 @@
ble.gap().accumulateAdvertisingPayload(GapAdvertisingData::BREDR_NOT_SUPPORTED | GapAdvertisingData::LE_GENERAL_DISCOVERABLE);
ble.gap().accumulateAdvertisingPayload(GapAdvertisingData::COMPLETE_LIST_16BIT_SERVICE_IDS, BEACON_UUID, sizeof(BEACON_UUID));
+ uint8_t serviceData[SERVICE_DATA_MAX];
+ unsigned serviceDataLen = 0;
serviceData[serviceDataLen++] = BEACON_UUID[0];
serviceData[serviceDataLen++] = BEACON_UUID[1];
serviceData[serviceDataLen++] = flags;
