BLE Beacon Example¶
The Beacon Example implements a transmitter beacon that broadcasts information to all compatible devices in its range as Manufacturer Specific Data in the advertisement packets.
This information includes:
- A 128-bit UUID to identify the beacon's provider.
- An arbitrary Major value for coarse differentiation between beacons.
- An arbitrary Minor value for fine differentiation between beacons.
- The RSSI value of the beacon measured at 1 meter distance, which can be used for estimating the distance from the beacon.
Before you start building, remember to set up the nRF5 SDK development environment first. See Setup the nRF5 SDK for details.
Building the example¶
You can find the source code and the project file of the example in the following folder: pitaya-go/examples/ble/ble_app_beacon.
Open terminal and navigate to the directory with the example Makefile:
make to build the example:
Programming the firmware¶
If compiled successfully, the firmware is located in
ble_app_beacon/armgcc/_build with the name
While pushing the USER button, press the RESET button to enter the DFU mode. Then program the firmware using the nRF Connect for Desktop tool.
If the SoftDevice is not programmed before, remember to add the SoftDevice. The SoftDevice is located in
See Programming section for details about how to program your Pitaya Go.
Test the Beacon Example with nRF Connect by performing the following steps:
After application starts, observe that GREEN LED is blinking. This indicates that the beacon is advertising.
After starting discovery in nRF Connect, observe that the beacon is advertising with its Bluetooth device address without a Device Name.
Tap the device to view the full advertisement data.
Create an Issue¶
Interested in contributing to this project? Want to report a bug? Feel free to click here: