BLE test

Fork of X_NUCLEO_IDB0XA1 by ST

Revision:
223:36df860f7ffc
Parent:
222:37a7e289ee3d
Child:
224:d8669b6b3175
--- a/source/BlueNRGGap.cpp	Wed Apr 06 18:06:07 2016 +0200
+++ b/source/BlueNRGGap.cpp	Fri Apr 08 17:42:38 2016 +0200
@@ -419,7 +419,7 @@
     }
 
     advtInterval = params.getIntervalInADVUnits();
-    PRINTF("advtInterval=%ld\n\r", advtInterval);
+    printf("advtInterval=%ld advType=%d\n\r", advtInterval, params.getAdvertisingType());
 
     ret = aci_gap_set_discoverable(params.getAdvertisingType(), // AdvType
                                    advtInterval,                // AdvIntervMin
@@ -434,9 +434,9 @@
                                    0);                          // SlaveConnIntervMax
 
     
-    PRINTF("!!!setting discoverable (servUuidlength=0x%x)\n\r", servUuidlength);
+    printf("!!!setting discoverable (servUuidlength=0x%x)\n\r", servUuidlength);
     if(BLE_STATUS_SUCCESS!=ret) {
-       PRINTF("error occurred while setting discoverable (ret=0x%x)\n\r", ret);
+       printf("error occurred while setting discoverable (ret=0x%x)\n\r", ret);
        switch (ret) {
          case BLE_STATUS_INVALID_PARAMS:
            return BLE_ERROR_INVALID_PARAM;
@@ -1156,9 +1156,11 @@
   tBleStatus ret = BLE_STATUS_SUCCESS;
 
   // Stop ADV before scanning
+  /*
   if (state.advertising == 1) {
     stopAdvertising();
   }
+  */
 
   PRINTF("Scanning...\n\r");
   ret = btleStartRadioScan(scanningParams.getActiveScanning(),