Enabling IoT with Bluetooth Low Energy
Bluetooth Low Energy enables low-power, low-cost wireless connectivity that is interoperable with modern smartphones and their operating systems. This technical note provides an introduction to this exciting technology, its benefits, and limitations.
Bluetooth Low Energy (also known as Bluetooth LE, or just BLE, and the now-defunct marketing name of “Bluetooth Smart”) launched in 2010 as a hallmark feature within version 4.0 of the Bluetooth specification. Originally conceived as a Nokia-proprietary technology, Bluetooth Low Energy was designed to significantly reduce the cost and power consumption of transceivers, while still providing connectivity with a communications range similar to Bluetooth Classic.
Since the first Bluetooth Low Energy design was qualified this technology has experienced significant growth in shipments. Its feature set is compelling for a wide range of applications in health and fitness, security, location-based-services, automotive, and consumer markets, and rapid adoption by leading smartphone platforms and vendors has provided an instant critical mass of deployment within the ecosystem that sees it set for further growth.
This technical note provides an introduction to Bluetooth Low Energy and the key characteristics and limitations that together influence its suitability for use in a given connectivity application. The target audience is product architects and engineers who are specifying or developing wirelessly-connected products, and want to better understand the available connectivity options.
Bluetooth Low Energy uses 80 MHz of spectrum in the 2.4 GHz ISM band to provide low-power, low-rate wireless communications over a range of 10 to 1,000 metres (depending on environment/configuration). Gaussian frequency-shift keying (GFSK) modulation is used with a maximum transmit power of 20 dBm, and together the link and physical layers implement a frequency hopping scheme that provides spread spectrum resilience to narrow-band interferers by working over 40 channels that are each 2 MHz wide.
The Bluetooth Low Energy physical layer provides four transmission modes with bit rates ranging between 125 Kbps and 2 Mbps, although packet length limitations and protocol overheads mean that maximum application throughput will be lower than PHY bit rate by 20-60% depending on protocol features available/enabled.
Bluetooth Low Energy has network topologies that are geared toward ad hoc communication scenarios involving relatively-infrequent transfer of small quantities of data. The technology can also support connection-oriented use cases such as those involving virtual serial ports or human interface devices.
The Bluetooth specification defines four roles that a Bluetooth Low Energy device may take: broadcaster, observer, peripheral and central.
- Broadcaster devices are transmit-only, and periodically broadcast advertising packets that may be detected by devices acting in the observer role.
- Observer devices are the counterpart of broadcasters – they are receive-only and listen for advertisements from broadcaster devices.
- Peripheral devices initially act like broadcasters, but transmit connectable advertising packets and accept connections from central devices.
- Central devices initiate connections to peripherals by listening for connectable advertising packets and then exchanging packets with the peripheral device.
Bluetooth Low Energy peripheral devices may only be connected to a single central device at a time. Central devices, on the other hand, can have multiple connected peripherals if required. Many common Bluetooth Low Energy usage scenarios see a smartphone acting in the role of central, with sensors, wearables, and other “things” connected as peripherals.
Taken individually the four roles directly cater for the majority of Bluetooth Low Energy application scenarios, but many transceivers available provide further flexibility by implementing time-slicing mechanisms to allow simultaneous operation in more than one role.
Bluetooth Low Energy introduces a protocol and a profile that work hand-in-hand to provide the basis for all Bluetooth Low Energy applications. These are the Attribute Protocol and the Generic Attribute Profile, respectively, and together they allow applications to expose state variables to a peer, and query or manipulate state variables of a peer.
The Attribute Protocol (ATT) defines server and client roles, and the basic operations that can be performed on state in the attribute database of the server. For example:
- A client may discover the attributes available on the server.
- A client may read the value of an attribute from the server.
- A client may write a value to an attribute on the server (with variants requiring and not requiring ATT-layer acknowledgement from the server).
- A server may send the value of an attribute to the client (with variants requiring and not requiring ATT-layer acknowledgement from the client).
Building on the facilities provided by ATT, the Generic Attribute Profile (GATT) defines the structure of the attribute database. At the GATT layer (and thus from the point of view of the application) the database on the attribute server is made up of characteristics which are grouped to form services. These characteristics and services are each identified by universally unique identifiers (UUIDs), which are themselves stored as attributes in the database. This enables client applications to recognise and access services that they know how to make use of.
Above the GATT layer lie profiles that may either be vendor-specific or defined by the Bluetooth SIG. These profiles define the roles, services and characteristics that must be implemented by GATT and ATT layers to provide functionality for a particular application.
A number of standard profiles are available for a diverse range of applications including blood pressure monitoring, location and navigation, proximity detection, and time synchronisation. There is ongoing effort within the Bluetooth SIG to specify further GATT profiles so that a wider range of applications can enjoy the interoperability benefits that arise from a qualified device implementing a standard profile.
Bluetooth Low Energy has comprehensive security features that work across layers to address the privacy, authenticity, and integrity of user data.
At the link layer, Bluetooth Low Energy makes use of the AES-128 block cipher to encrypt data transmitted over the air. While near-universally supported by implementations, use of this encryption is at the discretion of the application. In cases where privacy is not essential, authenticity and integrity of data sent over unencrypted connections can still be protected through use of a cipher-based message authentication code (CMAC; again, based on AES-128).
With wearables and personal devices being a key application for Bluetooth Low Energy, it is important to limit the ability of unauthorised third parties to track individuals or assets. To address this aspect of privacy Bluetooth Low Energy includes a feature that allows devices to change their Bluetooth device address frequently. To a third-party device this “private” address is essentially random, but it can still be resolved by trusted peer devices that might wish to initiate or accept connections.
Bluetooth Low Energy allows (but does not require) the creation of trusted relationships between devices through a process known as “pairing”. During the pairing process the two devices exchange and store identity information, and securely establish cryptographic keys to enable future data exchange without additional user interaction. The user flow for this process typically involves one of the devices being configured (often through a button press or equivalent virtual trigger) into a mode where it advertises its availability, and the other device (e.g., a smartphone) being used to detect the first device and intiate pairing.
Bluetooth Low Energy supports several different pairing methods that are designed to cater for products that may have different user interface capabilities. The simplest of these methods is “Just Works”, which provides unauthenticated pairing when at least one of the devices involved has no ability to display or receive input of a passkey. Authenticated pairing with protection against man-in-the-middle (MITM) attacks can be achieved by using “Passkey Entry” or “Numeric Comparison” methods that require additional user interface capabilities.
Bluetooth Low Energy is well suited to relatively short-range communications scenarios that involve low-to-medium throughput. Telemetry, fitness and health, and human interface device (HID) applications are key targets for this technology, and it provides considerable scope to optimise for latency, QoS, and other requirements of the application.
In particular, with proper system design the power consumption of a Bluetooth Low Energy communications link can be made extremely low, enabling very long battery life for devices powered from coin cells or other constrained energy sources.
A key advantage of using Bluetooth Low Energy is that it enables direct interaction with a wide range of modern smartphones without need for any intermediary. All major smartphone platforms, including Android and Apple iOS, provide powerful and accessible APIs to enable development of Bluetooth Low Energy applications.
Bluetooth Low Energy transceivers are relatively low cost and are readily available from a wide range of vendors and in forms to suit all requirements. Highly integrated and small form-factor silicon solutions provide the lowest unit cost for high volume products but have increased design-in and certification/qualification complexities during product development. Certified modular transceivers enable a simpler path to market for low-to-moderate volume and niche products, but become less cost-effective as product volumes increase.
While there is no one-size-fits-all connectivity solution for Internet of Things, it is certainly clear that Bluetooth Low Energy has an important role to play in connecting “things” across a wide range of markets.
The technology allows highly-integrated, physically small, and low-cost silicon that can provide a communications data rate well-suited to many Internet of Things applications. Good implementations have a low power consumption that enables battery-powered sensors and use of Bluetooth Low Energy in other energy-constrained scenarios involving energy-harvesting or wearables.
The baseline communications range is sufficient for in-room, around-person, or long-range coverage, with mesh topologies (a recent development that will be the subject of a future Virscient technical note) able to extend this significantly for applications where that makes sense. Forthcoming enhancements to the specification will also bring dramatic extensions to the communications range.
Probably the biggest advantage that Bluetooth Low Energy has over other low-power, short-range wireless technologies is that it enables direct communication with the modern smartphone. Support for Bluetooth Low Energy (and accessibility of such support to developers) is strong in leading mobile operating systems such as Android and Apple iOS.
Finally, as for legacy Bluetooth systems, the rigorous specification and product qualification programmes administered by the Bluetooth SIG are fostering a diverse ecosystem of interoperable solutions from various component vendors.
Virscient helps innovative companies design, develop, and integrate secure wireless connectivity for “things”. Our expertise spans all layers of the network stack from physical to application, and a wide range of technologies including Bluetooth, Wi-Fi, LoRa, and many others. We can assist with technology selection/evaluation, system specification, hardware/software design, implementation, optimisation, and verification. We can provide expert advice to close knowledge gaps and train your teams, or can take full responsibility for subsystem development.
For more information on how we can help you accelerate development of secure connected products please review our capabilities, or get in touch. To hear about any new or updated technical notes on wireless technology then follow us on LinkedIn.