Using Bluetooth Low Energy (LE)

There's nothing special about beacons that makes them different from other Bluetooth LE devices. In fact, all other Bluetooth LE devices such as fitness trackers, smartphones, Bluetooth lights and single board computers can also act as beacons. The term 'beacon' is just a convenient name that signifies its normal use - repeatedly sending out data.

All Bluetooth LE devices can send out short advertising up to 37 bytes (in Bluetooth 4.x). This data can be formatted in different ways to produce iBeacon, Eddystone or proprietary sensor data formats.

All Bluetooth LE devices can listen, called scanning, for other Bluetooth devices. Beacons don't usually listen unless they are mesh beacons. The listening device software does something in response to seeing specific advertising. For example, if it's an app then it can trigger app actions. If it's a gateway or single board computer, it can send the advertising up to a server for further analysis.

After a Bluetooth device has seen another's advertising it can connect to it via what's called Bluetooth Generic Attributes (GATT). The interface has one or more Bluetooth Services, identified by unique ids, that contain Bluetooth Characteristics also identified by ids. The listening device discovers characteristics and then reads from, writes to or sets up a connection to receive notifications from the characteristic. Its rare to connect to beacons and this is usually only performed when setting up beacon parameters such as advertising type, signal strength and advertising period.

Bluetooth Advertising

Each respective type of device, for example, Android, iOS and Linux has operating system Bluetooth APIs that can be used for advertising, scanning and connection. 

Some device manufacturers provide thin SDKs on top of the operating system APIs. In most cases, we don't recommend using them as they quickly go out of date with the underlying system APIs and lock you into using just that manufacturer's devices.