Bluetooth technology has become an integral part of our daily lives, enabling wireless communication between various devices. Understanding the basics of Bluetooth, especially the pairing and handshaking processes, is crucial for ensuring secure and efficient connections. In this blog post, we will delve into the fundamental aspects of Bluetooth technology, focusing on how devices pair and establish secure connections through the handshaking process.
1. What is Bluetooth?
1.1. Overview of Bluetooth Technology
Bluetooth is a wireless communication technology that allows devices to exchange data over short distances using radio waves. It was developed to replace cables and provide a standard protocol for wireless communication between devices such as smartphones, laptops, headphones, and more.
1.2. Bluetooth Versions
Over the years, Bluetooth technology has evolved, with several versions being released, each offering improvements in speed, range, and security. The most common versions include Bluetooth 4.0, Bluetooth 4.2, Bluetooth 5.0, and the latest Bluetooth 5.2.
2. How Bluetooth Works ?
The Bluetooth protocol operates at 2.4GHz in the same unlicensed ISM frequency band where RF protocols like ZigBee and WiFi also exist. There is a standardized set of rules and specifications that differentiates it from other protocols.
3. Where is Bluetooth Specification available ?
Download from https://www.bluetooth.org/en-us/specification/adopted-specifications
4. How Bluetooth devices communicates ?
Bluetooth networks (commonly referred to as piconets) use a master/slave model to control when and where devices can send data. In this model, a single master device can be connected to up to seven different slave devices. Any slave device in the piconet can only be connected to a single master.
Bluetooth Addresses and Names
Every single Bluetooth device has a unique 48-bit address, commonly abbreviated BD_ADDR. This will usually be presented in the form of a 12-digit hexadecimal value. The most-significant half (24 bits) of the address is an organization unique identifier (OUI), which identifies the manufacturer. The lower 24-bits are the more unique part of the address. This address should be visible on most Bluetooth devices.
Connection Process
Creating a Bluetooth connection between two devices is a multi-step process involving three progressive states:
- Inquiry – If two Bluetooth devices know absolutely nothing about each other, one must run an inquiry to try to discover the other. One device sends out the inquiry request, and any device listening for such a request will respond with its address, and possibly its name and other information.
- Paging (Connecting) – Paging is the process of forming a connection between two Bluetooth devices. Before this connection can be initiated, each device needs to know the address of the other (found in the inquiry process).
- Connection – After a device has completed the paging process, it enters the connection state. While connected, a device can either be actively participating or it can be put into a low power sleep mode.
- Active Mode – This is the regular connected mode, where the device is actively transmitting or receiving data.
- Sniff Mode – This is a power-saving mode, where the device is less active. It’ll sleep and only listen for transmissions at a set interval (e.g. every 100ms).
- Hold Mode – Hold mode is a temporary, power-saving mode where a device sleeps for a defined period and then returns back to active mode when that interval has passed. The master can command a slave device to hold.
- Park Mode – Park is the deepest of sleep modes. A master can command a slave to “park”, and that slave will become inactive until the master tells it to wake back up.
Reference : https://learn.sparkfun.com/tutorials/bluetooth-basics
Very good stuff!
/Oliver Gunerhed