How Does Bluetooth Work? The Technical Aspects of Bluetooth Technology

Bluetooth wireless technology is a short-range communications technology designed to replace the cables connecting fixed or portable devices whilst still maintaining high levels of security. The Bluetooth core system offers services that enable the connection of devices and the exchange of a variety of data classes between these devices. One device provides the synchronisation reference and is known as the master, whilst all other devices are known as slaves. A group of devices synchronised in this fashion form a piconet. This is the fundamental form of communication for Bluetooth wireless technology.

Bluetooth Components

The Bluetooth system consists of an RF transceiver, baseband, and protocol stack.

Radio

The Bluetooth radio is built into a small microchip and operates in a globally available frequency band ensuring communication compatibility worldwide. Bluetooth works at two levels of power, a lower level of power that can cover a smaller area, such as that of a room, and a higher level of power, which covers a larger area, such as within a home.

During typical operation, a physical radio channel is shared by a group of devices that are synchronised to a common clock and frequency hopping pattern.

The Bluetooth RF (physical layer) operates in the unlicensed ISM band at 2.4 GHz. However, compared with other systems operating in the same frequency band, the Bluetooth radio typically hops faster and uses shorter packets, in order to limit the impact of microwave ovens, telephones and other sources of interference and fading. Apart from frequency-hopping, Bluetooth uses a fast acknowledgement to ensure a better communication link, and it avoids the interference caused by signals by simply moving on from one frequency to another. RF operation uses a shaped, binary frequency modulation to minimise transceiver complexity. The symbol rate is 1 Megasymbol per second (Msps) supporting the bit rate of 1 Megabit per second (Mbps) - known as Basic Mode - or, with Enhanced Data Rate, a gross air bit rate of 2 or 3Mb/s.

Use of Forward Error Correction (FEC) limits the impact of random noise on long-distance links.

Adaptive Frequency Hopping (AFH)

Devices in a piconet use a specific frequency hopping pattern that is algorithmically determined by certain fields in the Bluetooth specification address and clock of the master. The basic hopping pattern is a pseudo-random ordering of the 79 frequencies in the ISM band, but may be adapted to exclude a portion of the frequencies that are used by interfering devices. The adaptive hopping technique improves Bluetooth technology co-existence with static (non-hopping) ISM systems when these are co-located.

Time Slots and Packets

The physical channel is sub-divided into time units known as slots. Data is transmitted between Bluetooth enabled devices in packets that are positioned in these slots. When circumstances allow, a number of consecutive slots may be allocated to a single packet. Frequency hopping takes place between the reception or transmission of packets. Bluetooth technology provides the effect of full duplex transmission through the use of a time-division duplex (TDD) scheme.

Link and Channel Management Protocols

Physical Links

Within a physical channel, a physical link is formed between any two devices that transmit packets in either direction between them. In a piconet physical channel, there are restrictions on which devices may form a physical link. There is a physical link between the master and each slave. Physical links are not formed directly between the slaves in a piconet.

Logical Links

The physical link is used as a transport for one or more logical links that support unicast asynchronous, synchronous and isochronous traffic, along with broadcast traffic. Traffic on logical links is multiplexed onto the physical link by occupying slots assigned by a scheduling function in the resource manager.

Control Layers

Above the physical channel there is a layering of links and channels and associated control protocols. The hierarchy of channels and links from the physical channel upwards is physical channel, physical link, logical transport, logical link and L2CAP channel.

Bluetooth Protocol Stack

Bluetooth is as a layer protocol architecture consisting of core protocols, cable replacement protocols, telephony control protocols, and adopted protocols. Mandatory protocols for all Bluetooth stacks are: LMP (Link Management Protocol), L2CAP (Logical Link Control and Adaptation Protocol) and SDP (Service Discovery Protocol); in addition, HCI (Host/Controller Interface) and RFCOMM (Radio Frequency Communication) protocols are almost universally supported.

Link Management Protocol (LMP)

LMP is used for control of the radio link between two devices. It is used as a control protocol for the baseband and physical layers, and is carried over logical links in addition to user data. The link manager function uses LMP to control the operation of devices in the piconet and provide services to manage the lower architectural layers (baseband layer and radio layer).

Logical Link Control and Adaptation Protocol (L2CAP)

Above the baseband layer, the L2CAP layer provides a channel-based abstraction to services and applications. It is used to multiplex multiple logical connections between two devices using different higher level protocols, and provides segmentation and reassembly of on-air packets. Application data submitted to the L2CAP protocol may be carried on any logical link that supports the L2CAP protocol.

In basic mode, L2CAP provides reliable sequenced packets with a payload configurable up to 64kB, with 672 bytes as the minimum mandatory supported size. In retransmission and flow control modes, L2CAP can be configured for reliable or isochronous data per channel by configuring the number of retransmissions and flush timeout.

The EL2CAP specification adds an additional "enhanced mode" to the core specification, which is an improved version of retransmission & flow control modes.

Service Discovery Protocol (SDP)

SDP is used to allow devices to discover what services each other support, and what parameters to use to connect to them. For example, when connecting a mobile phone to a Bluetooth headset, SDP will be used to determine which Bluetooth profiles are supported by the headset (Headset Profile, Hands Free Profile, Advanced Audio Distribution Profile etc) and the protocol multiplexer settings needed to connect to each of them. Each service is identified by a Universally Unique Identifier (UUID), with official services (Bluetooth profiles) assigned a short form UUID (16 bits rather than the full 128).

Setting up Connections

Any Bluetooth device will transmit the following information on demand:

  • Device class
  • Device name
  • List of services

Technical information, for example, device features, manufacturer, Bluetooth specification used, clock offset

Any device may perform an inquiry to find other devices to connect to, and any device can be configured to respond to such inquiries. However, if the device trying to connect knows the address of the device, it always responds to direct connection requests and transmits the information shown in the list above if requested.

Use of a device's services may require pairing or acceptance by its owner, but the connection itself can be initiated by any device and held until it goes out of range. Some devices can be connected to only one device at a time, and connecting to them prevents them from connecting to other devices and appearing in enquiries until they disconnect from the other device.

Every device has a unique 48-bit address. However these addresses are generally not shown in enquiries. Instead, friendly Bluetooth names are used, which can be set by the user. This name appears when another user scans for devices and in lists of paired devices.

Pairing

Pairs of devices may establish a trusted relationship by learning (by user input) a shared secret known as a passkey. A device that wants to communicate only with a trusted device can cryptographically authenticate the identity of the other device. Trusted devices may also encrypt the data that they exchange over the airwaves so that no one can listen in. The encryption can, however, be turned off, and passkeys are stored on the device file system, not on the Bluetooth chip itself.

Bluetooth 2.1 has an optional "touch-to-pair" feature based on NFC. By simply bringing two devices into close range (around 10 cm), pairing can securely take place without entering a passkey or manual configuration.

Since the Bluetooth address is permanent, a pairing is preserved, even if the Bluetooth name is changed. Pairs can be deleted at any time by either device. Devices generally require pairing or prompt the owner before they allow a remote device to use any or most of their services. Some devices, such as mobile phones, usually accept OBEX business cards and notes without any pairing or prompts.

Certain printers and access points allow any device to use their services by default, much like unsecured Wi-Fi networks. Pairing algorithms are sometimes manufacturer-specific for transmitters and receivers used in applications such as music and entertainment.