Beacon demo for the BLE API using the nRF51822 native mode drivers

Dependencies:   BLE_API SDFileSystem mbed-rtos mbed nRF51822 X_NUCLEO_IDB0XA1

Fork of BLE_iBeacon by Bluetooth Low Energy

Files at this revision

API Documentation at this revision

Comitter:
rgrover1
Date:
Tue Aug 12 08:26:18 2014 +0000
Parent:
40:52e9de9e0186
Child:
42:bb46ad5c24dd
Commit message:
lower advertising frequency to 1hz

Changed in this revision

BLE_API.lib Show annotated file Show diff for this revision Revisions of this file
main.cpp Show annotated file Show diff for this revision Revisions of this file
--- a/BLE_API.lib	Fri Jul 25 16:27:01 2014 +0000
+++ b/BLE_API.lib	Tue Aug 12 08:26:18 2014 +0000
@@ -1,1 +1,1 @@
-http://mbed.org/teams/Bluetooth-Low-Energy/code/BLE_API/#8559a2da6f41
+http://mbed.org/teams/Bluetooth-Low-Energy/code/BLE_API/#189ff241dae1
--- a/main.cpp	Fri Jul 25 16:27:01 2014 +0000
+++ b/main.cpp	Tue Aug 12 08:26:18 2014 +0000
@@ -44,7 +44,7 @@
  * Major/Minor  = 0000 / 0000
  * Tx Power     = C8
  */
-const static uint8_t beaconPayload[] = {
+const uint8_t beaconPayload[] = {
     0x4C, 0x00, // Company identifier code (0x004C == Apple)
     0x02,       // ID
     0x15,       // length of the remaining payload
@@ -64,7 +64,7 @@
     ble.accumulateAdvertisingPayload(GapAdvertisingData::MANUFACTURER_SPECIFIC_DATA, beaconPayload, sizeof(beaconPayload));
 
     ble.setAdvertisingType(GapAdvertisingParams::ADV_NON_CONNECTABLE_UNDIRECTED);
-    ble.setAdvertisingInterval(160); /* 100ms; in multiples of 0.625ms. */
+    ble.setAdvertisingInterval(1600); /* 1s; in multiples of 0.625ms. */
     ble.startAdvertising();
 
     for (;;) {