Bluetooth radio operates at 2-4 GHz ISM band (2400-2483.5 MHz) with a channel interval of 1 MHz.
Frequency Hopping Technology
In the connection status, synchronization train and synchronization scan substates are at least 1600 times per second.
At least 3200 times per second in inquiry and page sub-States/s
1. Overview
Bluetooth has the following Connection Methods:
Bluetooth transmits data through air and defines two modes
~ Basic rate (forced mode): 1 Mbps
~ Enhanced basic rate (optional): 2 Mbps and 3 Mbps
1.1 clock (clock)
There are four clock types in Bluetooth
? Clkr reference clock (driven by the running system clock )? Clkn native clock (the offset of clkr )? Clke estimated clock (the offset of clkn, used in page scan )? CLK master clock (piconet master clock)
The clock determines the trigger event and key cycle. The Bluetooth system has four important cycles.
312.5 μs, 625 μs, 1.25 MS, and 1.28 s
The bits 0, 1, 2, and 12 corresponding to the time of these cycles respectively
1.2 addressing mode
Each bluetooth device must have a unique 48-bit device address (bd_addr). The structure is shown in figure
Lap: lower address part
UAP: Upper address part
NAP: non-significant address part
Lap has 64 reserved addresses (0x9e8b00-0x9e8b3f)
0x9e8b33 is generally used for query.
2. Physical channels (physical channels)
Physical channels are the bottom layer of the Bluetooth system.
Two communication devices share the physical channel by tuning the transceiver (transceivers) to the same rf frequency.
The Bluetooth device supports multiple operations at the same time through time division multiplexing.
Bluetooth defines five physical Channels
? basic piconet physical channel? adapted piconet physical channel? page scan physical channel? inquiry scan physical channel? synchronization scan physical channel
The first two are used for communication between two connected devices in a specific piconet.
Inquiry scan channel is used to discover remote devices.
The page scan channel is used to connect devices.
Synchronization scan channel is used to obtain the time and frequency information of the physical link of a non-connected sub-broadcast.
3. physical link (physical links)
A physical link represents a baseband connection between two devices. It is always associated with a specific physical channel.
4. Logical transports)
Different types of logical transport layers may be created between the master and slave.
There are six logical transport layers
? SCO: Synchronous Connection-Oriented logical transport? eSCO: Extended Synchronous Connection-Oriented logical transport ? ACL: Asynchronous Connection-Oriented logical transport? ASB: Active Slave Broadcast logical transport? PSB: Parked Slave Broadcast logical transport? CSB: Connectionless Slave Broadcast logical transport.
SCO is used for point-to-point transmission between the master and slave. It is usually used for time-limited data (such as voice and synchronous data)
The master maintains SCO through regular reserved slots (Reserved slots ).
Esco adds a retransmission Window Based on SCO.
The ACL is also used for point-to-point transmission between the master and slave, but there is no reserved time interval.
The master can establish a connection with the slave on any slot.
ASB is used for Master and active slaves Communication
PSB is used for communication between master and parked slaves
CSB is used by the master to send profile broadcasts.
5. Logical links)
There are six logical links
? LC: Link Control? ACL-C: ACL Control? ACL-U: User Asynchronous/Isochronous? SCO-S: User Synchronous? eSCO-S: User Extended Synchronous? PBD: Profile Broadcast Data
Lc and ACL-C for link control level and link manager level)
The ACL-U is used to carry user asynchronous Information
SCO-S/ESCO-S for carrying user sync Information
PBD is used to carry profile Broadcast Data
LC is in the header part of packet; others are in the payload part.
ACL-C/ACL-U is indicated by the Logical Link ID (llid) of the payload Header
SCO-S/ESCO-S is only carried by synchronous logical transports
The ACL-U is typically carried by the ACL logical transport or by the data of the DV packet of the SCO logical transport
ACL-C can be carried by SCO/ACL logical transport
PBD is carried by CSB logical transport
5.1 LC
LC carries the underlying control information, such as ARQ, flow control, and payload characterization.
Each packet contains LC information except the id packet without a header.
5.2 ACL-C
The ACL-C carries control information exchanged by the link manger layer, using DM1/DV packets
5.3 ACL-U
The ACL-U carries L2CAP-layer user data that may be transmitted by one or more baseband packets
5.4 SCO-S/ESCO-S
SCO-S/ESCO-S carrying synchronized user data
5.5 PDB
PBD carries profile broadcast data, and the data should be complete and cannot be transmitted in parts.
5.6 priorities
ALC-C has the highest priority than other logical links
PBD has the lowest priority
6. Packet (packets) 6.1 General Format
For basic rate, the general format is as follows:
The general format of enhanced data rate is as follows:
Packet usually contains three parts.
-Access Code: 72/68 bits
-Header: 54 BITs
-Payload: 0 ~ 2790 bits
6.2 bit Ordering
Baseband uses the little endian format during transmission
The following rules are available:
-Least significant bit (LSB) corresponds to B0
-LSB first transmission
-LSB is displayed on the left.
For example, if the 3-bit parameter x = 3 (b0b1b2 = 110), 1 is first transmitted, and 0 is last transmitted.
6.3 access code
Each packet starts with access code.
The access code identifies a physical channel, and the packet in the same physical channel has the same access code
There are 72 and 68 bits access codes.
68 bits access code (the shortened access code) does not contain Trailer
There is no header behind it for synchronization (paging, inquiry, and Park)
The access code format is as follows:
There are three different access codes
? DAC: device access code ? CAC: channel access code ? IAC: inquiry access code
The access code is derived from the lap of bd_addr.
DAC is used for page, page scan, and page respponse substates.
CAC is used for connection status, synchronization train sub-status, and synchronization scan sub-status.
IAC is used for inquiry sub-states, including one Giac (General IAC) and 63 DIAC (dedicated IAC)
Premble has two types of 1010/0101, which are determined by the sync word LSB.
The sync word is calculated by lap.
The master lap is used for calculating the CAC sync word.
IAC uses Reserved/dedicated laps
DAC uses slave's lap
Trailer is also two types of 1010/0101, determined by the MSB of sync word
6.4 packet header
The header containing LC has 6 fields, 18 bits
? LT_ADDR: 3-bit logical transport address ? TYPE: 4-bit type code ? FLOW: 1-bit flow control ? ARQN: 1-bit acknowledge indication ? SEQN: 1-bit sequence number ? HEC: 8-bit header error check
The format is as follows:
6.4.1 lt_addr
Logical Transport Address (lt_addr)
Used to identify the source slave in the master-to-slave target slave or slave-to-Master
Each active slave has a primary 3-bit lt_addr
Zero lt_addr is used to broadcast messages to ASB/PSB. CSB uses a single non-zero lt_addr.
The master does not have lt_addr, and timing relative is used to distinguish slaves.
For the ESCO transmission mode, each slave has a secondary lt_addr
Slave only receives packets and broadcast packets that match the primary/secondary lt_addr.
6.4.2 type
Differentiate six different packages
There are three main functions
-Determine the logical transport (SCO/ESCO, ACL, CSB) to use)
-Enhanced Data Rate enabled?
-Identify the packet type (SCO/ESCO, ACL)
6.4.3 Flow
Used for throttling in ACL logical transport
The corresponding value is
-0: Stop indication
-1: Go indication
The flow bit is ignored in SCO/ESCO (set to 1) and CSB (set to 0) logical transport
6.4.4 arqn
Automatic Repeat request number
Determines whether the data source has successfully transmitted payload data with CRC.
Ignored in CSB logical transport (set to 0)
6.4.5 seqn
Sequence Number
Used to ensure orderly transmission of data streams
Ignored in CSB logical transport (set to 0)
6.4.6 HEC
Header error check
Used to check the integrity of the header
6.5 packet types
The packet type is associated with the logic transport layer used (mainly for SCO/ESCO, ACL, and CSB ).
It is specified by the Type field and can be divided into 4 segments (for example)
-1th segment: Control Packet
-2th segment: occupying a single time slot
-3th segment: occupying three time slots
-4th segment: occupying five time slots
6.5.1 common packet types
There are five common packet types
ID packet: 68 bits, only access code (DAC or IAC), used for paging, inquiry, and response
Null packet: no payload, only access code (CAC) and header, with a fixed length of 126 bits
It is used to return link information to the sender through fields such as arqn and flow. null packet does not need to be confirmed.
Poll packet: similar to null packet, there is no payload, but the receiver needs to confirm
FHS packet: frequency hopping synchronization, a special control group
It declares the device address and clock information of the sender to achieve frequency-hopping synchronization.
Payload contains 144 bits and 16 bits CRC verification codes, which are then protected with FEC with a rate of 2/3. The final length is 240 bits.
For details, see [6.5.1.4 FHS packet].
DM1 packet: DM stands for data medium rate, a type of 1th segment, which can be transmitted on any logic transmission layer to support control information
It can also be used to carry user data
6.5.2 SCO packets
There are four types: hv1, HV2, hv3, and DV packet.
DV packet contains data and voice in the following format:
6.5.3 ESCO packets
Ev packets
Basic rate: ev3, ev4, and ev5
Enhanced Data Rate: 2-ev3, 3-ev3, 2-ev5, and 3-ev5
6.5.4 ACL packets
Transmitted on Asynchronous/CSB logical transport
Basic rate: DM1, dh1, dm3, DH3, dm5, DH5, and aux1
Enhanced Data Rate: 2-dh1, 3-dh1, 2-dh3, 3-dh3, 2-dh5, and 3-dh5
6.6 payload format
Payload has two types of fields: synchronous data field and asynchronous data field)
ACL packet only contains asynchronous data fields; SCO/ESCO only contains synchronous data fields (except DV packet contains both)
6.6.1 synchronous data field
SCO only supports the basic rate mode, and its synchronized data fields are fixed in length and only contain the synchronized data subject.
For ESCO
Basic rate: consists of the synchronization data subject and CRC.
Enhanced Data Rate: consists of five parts: Guard Time, synchronization sequence, synchronous data body, CRC code, and Trailer
6.6.2 asynchronous data field
Basic rate: there are 2, 3, or 4 parts, payload header, payload body, possibly a mic, and possibly a CRC code
Enhanced Data Rate: there are 6 or 7 parts, Guard Time, synchronization sequence, payload header, payload body, possibly a mic, a CRC and a trailer
The format of payload header is as follows:
The llid field is defined as follows:
7. Link controller operation)
Several statuses are defined in link controller.
Three major statuses: standby, connection and Park
9 sub-states: Page, page scan, inquiry, inquiry SACN, synchronous train, Synchronous Scan
Master response, slave response and inquiry respneuron
The sub-status is the temporary status for establishing connections and discovering devices.
Standby is the default status of the device.
There are four modes for a bluetooth device in connection status.
Hold mode, sniff mode, Park mode, and activemode)
Shows the transition diagrams of these States (three response substates are not displayed)