High level Bluetooth Low Energy API and radio abstraction layer

Dependents:   BLE_ANCS_SDAPI BLE_temperature BLE_HeartRate BLE_ANCS_SDAPI_IRC ... more

Overview

The BLE_API is a high level abstraction for using Bluetooth Low Energy on multiple platforms. For details and examples using the BLE_API please see the BLE_API Summary Page. Or click on the API Documentation tab above.

Supported Services

Supported services can be found in the BLE_API/services folder.

Files at this revision

API Documentation at this revision

Comitter:
vcoubard
Date:
Wed Apr 06 19:15:45 2016 +0100
Parent:
1190:38d206267ad3
Child:
1192:718787de23b7
Commit message:
Synchronized with git rev d84f93f4
Author: Andres Amaya Garcia
Merge branch 'develop' into fix_adv_payload

Changed in this revision

ble/Gap.h Show annotated file Show diff for this revision Revisions of this file
--- a/ble/Gap.h	Wed Apr 06 19:15:44 2016 +0100
+++ b/ble/Gap.h	Wed Apr 06 19:15:45 2016 +0100
@@ -938,7 +938,11 @@
      * @return BLE_ERROR_NONE if the device started advertising successfully.
      */
     ble_error_t startAdvertising(void) {
-        return startAdvertising(_advParams);
+        ble_error_t rc;
+        if ((rc = startAdvertising(_advParams)) == BLE_ERROR_NONE) {
+            state.advertising = 1;
+        }
+        return rc;
     }
 
     /**
@@ -1117,7 +1121,7 @@
      *         set.
      */
     ble_error_t setAdvertisingPayload(const GapAdvertisingData &payload) {
-        ble_error_t rc = setAdvertisingData(_advPayload, _scanResponse);
+        ble_error_t rc = setAdvertisingData(payload, _scanResponse);
         if (rc == BLE_ERROR_NONE) {
             _advPayload = payload;
         }