Wang Xinglu / BLE_API

Dependencies:   nRF51822

Dependents:   LinkNode_LIS3DH

Fork of BLE_API by Bluetooth Low Energy

Files at this revision

API Documentation at this revision

Comitter:
rgrover1
Date:
Fri Jun 19 15:52:53 2015 +0100
Parent:
601:78b51e441825
Child:
603:efa5a21436c1
Commit message:
Synchronized with git rev 1ca94c94
Author: Rohit Grover
enhance ServiceDiscovery with isActive() and onTermination()

Changed in this revision

public/ServiceDiscovery.h Show annotated file Show diff for this revision Revisions of this file
--- a/public/ServiceDiscovery.h	Fri Jun 19 15:52:53 2015 +0100
+++ b/public/ServiceDiscovery.h	Fri Jun 19 15:52:53 2015 +0100
@@ -136,6 +136,7 @@
 public:
     typedef void (*ServiceCallback_t)(const DiscoveredService &);
     typedef void (*CharacteristicCallback_t)(const DiscoveredCharacteristic &);
+    typedef void (*TerminationCallback_t)(Gap::Handle_t connectionHandle);
 
 public:
     static ble_error_t launch(Gap::Handle_t             connectionHandle,
@@ -146,6 +147,9 @@
 
     static void        terminate(void);
 
+    static bool        isActive(void);
+    static void        onTermination(TerminationCallback_t callback);
+
 protected:
     Gap::Handle_t            connHandle; /**< Connection handle as provided by the SoftDevice. */
     UUID                     matchingServiceUUID;