EddyStone Beacon demo for the BLE API using the nRF51822 native mode drivers
Dependencies: BLE_API mbed nRF51822
Fork of BLE_iBeacon by
Diff: main.cpp
- Revision:
- 4:0ce8d2dd62f9
- Parent:
- 2:90b493cdcb1f
- Child:
- 5:97ce285ff00a
diff -r 9c175cc9752d -r 0ce8d2dd62f9 main.cpp --- a/main.cpp Thu Apr 03 01:10:59 2014 +0000 +++ b/main.cpp Fri Apr 04 09:51:19 2014 +0000 @@ -55,14 +55,14 @@ Major/Minor = 0000 / 0000 Tx Power = C8 */ - uint8_t iBeaconPayload[25] = { 0x4C, 0x00, 0x02, 0x15, 0xE2, 0x0A, 0x39, 0xF4, 0x73, 0xF5, 0x4B, 0xC4, 0xA1, 0x2F, 0x17, 0xD1, 0xAD, 0x07, 0xA9, 0x61, 0x00, 0x00, 0x00, 0x00, 0xC8 }; + uint8_t beaconPayload[25] = { 0x4C, 0x00, 0x02, 0x15, 0xE2, 0x0A, 0x39, 0xF4, 0x73, 0xF5, 0x4B, 0xC4, 0xA1, 0x2F, 0x17, 0xD1, 0xAD, 0x07, 0xA9, 0x61, 0x00, 0x00, 0x00, 0x00, 0xC8 }; /* Make sure we get a clean start */ nrf.reset(); /* Beacon includes the FLAG and MSD fields */ advData.addFlags(GapAdvertisingData::BREDR_NOT_SUPPORTED); - advData.addData(GapAdvertisingData::MANUFACTURER_SPECIFIC_DATA, iBeaconPayload, sizeof(iBeaconPayload)); + advData.addData(GapAdvertisingData::MANUFACTURER_SPECIFIC_DATA, beaconPayload, sizeof(beaconPayload)); /* Start advertising! */ nrf.getGap().setAdvertisingData(advData, scanResponse);