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 nRF51822 by
Revision 296:8d25fe68d731, committed 2015-06-19
- Comitter:
- rgrover1
- Date:
- Fri Jun 19 15:55:28 2015 +0100
- Parent:
- 295:5566c7b83bb5
- Child:
- 297:6c432ef3892a
- Commit message:
- Synchronized with git rev 2d83d6b8
Author: Rohit Grover
setup longUUIDs for services.
Changed in this revision
| btle/btle_discovery.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/btle/btle_discovery.cpp Fri Jun 19 15:55:28 2015 +0100
+++ b/btle/btle_discovery.cpp Fri Jun 19 15:55:28 2015 +0100
@@ -145,6 +145,17 @@
}
printf("\r\n");
+ if ((response->count == 1) && (response->value_len == UUID::LENGTH_OF_LONG_UUID)) {
+ UUID::LongUUIDBytes_t uuid;
+ /* Switch longUUID bytes to MSB */
+ for (unsigned i = 0; i < UUID::LENGTH_OF_LONG_UUID; i++) {
+ uuid[i] = response->handle_value[0].p_value[UUID::LENGTH_OF_LONG_UUID - 1 - i];
+ }
+
+ unsigned serviceIndex = serviceIndicesNeedingUUIDDiscovery.getFirst();
+ services[serviceIndex].setupLongUUID(uuid);
+ }
+
serviceIndicesNeedingUUIDDiscovery.removeFirst();
serviceIndicesNeedingUUIDDiscovery.triggerFirst();
}
