Nordic stack and drivers for the mbed BLE API

Fork of nRF51822 by Nordic Semiconductor

Revision:
66:b3680699d9a4
Parent:
59:2819e564b613
Child:
82:6c51cbe4bc12
--- a/btle/custom/custom_helper.cpp	Mon Sep 08 17:21:46 2014 +0100
+++ b/btle/custom/custom_helper.cpp	Mon Sep 22 11:19:51 2014 +0100
@@ -26,16 +26,14 @@
     LongUUIDBytes_t uuid;
     uint8_t         type;
 } converted_uuid_table_entry_t;
-static const unsigned UUID_TABLE_MAX_ENTRIES = 8; /* This is the maximum number
-                                    * of 128-bit UUIDs with distinct bases that
-                                    * we expect to be in use; increase this
-                                    * limit if needed. */
+static const unsigned UUID_TABLE_MAX_ENTRIES = 8; /* This is the maximum number of 128-bit UUIDs with distinct bases that
+                                                   * we expect to be in use; increase this limit if needed. */
 static unsigned uuidTableEntries = 0; /* current usage of the table */
 converted_uuid_table_entry_t convertedUUIDTable[UUID_TABLE_MAX_ENTRIES];
 
 /**
  * lookup the cache of previously converted 128-bit UUIDs to find a type value.
- * @param  uuid          long UUID
+ * @param  uuid          base 128-bit UUID
  * @param  recoveredType the type field of the 3-byte nRF's uuid.
  * @return               true if a match is found.
  */
@@ -44,9 +42,7 @@
 {
     unsigned i;
     for (i = 0; i < uuidTableEntries; i++) {
-        if (memcmp(convertedUUIDTable[i].uuid,
-                   uuid,
-                   LENGTH_OF_LONG_UUID) == 0) {
+        if (memcmp(convertedUUIDTable[i].uuid, uuid, LENGTH_OF_LONG_UUID) == 0) {
             *recoveredType = convertedUUIDTable[i].type;
             return true;
         }
@@ -59,8 +55,7 @@
 addToConvertedUUIDTable(const LongUUIDBytes_t uuid, uint8_t type)
 {
     if (uuidTableEntries == UUID_TABLE_MAX_ENTRIES) {
-        return; /* recovery needed; or at least the user should be
-                 * warned about this fact.*/
+        return; /* recovery needed; or at least the user should be warned about this fact.*/
     }
 
     memcpy(convertedUUIDTable[uuidTableEntries].uuid, uuid,LENGTH_OF_LONG_UUID);