Patched version of nrf51822 FOTA compatible driver, with GPTIO disabled, as it clashed with the mbed definitions...

Fork of nRF51822 by Nordic Semiconductor

Files at this revision

API Documentation at this revision

Comitter:
rgrover1
Date:
Wed May 13 08:49:35 2015 +0100
Parent:
174:555dc8af9269
Child:
176:03a9fc49c21e
Commit message:
Synchronized with git rev be6166ee
Author: Rohit Grover
white space diffs.

Changed in this revision

nRF51GattServer.cpp Show annotated file Show diff for this revision Revisions of this file
--- a/nRF51GattServer.cpp	Wed May 13 08:49:35 2015 +0100
+++ b/nRF51GattServer.cpp	Wed May 13 08:49:35 2015 +0100
@@ -271,12 +271,10 @@
 
             /* 1.) Handle CCCD changes */
             handle_value = gattsEventP->params.write.handle;
-            for (uint8_t i = 0; i<characteristicCount; i++) {
+            for (uint8_t i = 0; i < characteristicCount; i++) {
                 if ((p_characteristics[i]->getProperties() & (GattCharacteristic::BLE_GATT_CHAR_PROPERTIES_INDICATE | GattCharacteristic::BLE_GATT_CHAR_PROPERTIES_NOTIFY)) &&
                     (nrfCharacteristicHandles[i].cccd_handle == handle_value)) {
-                    uint16_t cccd_value =
-                        (gattsEventP->params.write.data[1] << 8) |
-                        gattsEventP->params.write.data[0]; /* Little Endian but M0 may be mis-aligned */
+                    uint16_t cccd_value = (gattsEventP->params.write.data[1] << 8) | gattsEventP->params.write.data[0]; /* Little Endian but M0 may be mis-aligned */
 
                     if (((p_characteristics[i]->getProperties() & GattCharacteristic::BLE_GATT_CHAR_PROPERTIES_INDICATE) && (cccd_value & BLE_GATT_HVX_INDICATION)) ||
                         ((p_characteristics[i]->getProperties() & GattCharacteristic::BLE_GATT_CHAR_PROPERTIES_NOTIFY) && (cccd_value & BLE_GATT_HVX_NOTIFICATION))) {