Fundamentals 9 min read

Principles and Process of the SBC Audio Codec in Bluetooth Systems

The SBC (Subband Codec) used in Bluetooth headsets compresses PCM audio by splitting the signal into 4 or 8 sub‑bands, allocating bits according to perceptual importance, and encoding with analysis filters, scale factors, APCM and bit‑packing, then decoding reverses the process to reconstruct audio, providing lossy compression across supported sample rates and channel modes.

Tencent Music Tech Team
Tencent Music Tech Team
Tencent Music Tech Team
Principles and Process of the SBC Audio Codec in Bluetooth Systems

1. Starting from Information Transmission

The picture shows a typical Bluetooth headset scenario. Audio data on the phone is encoded, transmitted via the Bluetooth protocol, received and decoded by the headset, and finally converted into vibrations that the ear perceives. This illustrates a digital communication system composed of several parts, prompting the question of which part SBC encoding belongs to and what role it plays.

In a generic digital communication model: • Source: the information to be transmitted. • Source coding: reduces redundancy (e.g., Huffman, H.264). • Channel coding: adds redundancy to combat noise (e.g., LDPC, convolutional codes). • Channel: the physical medium (optical fiber, electromagnetic space). • Channel decoding and source decoding: inverse processes of the respective encodings. • Destination: the receiver of the message.

Bluetooth Headset Signal Transmission Process

For a typical Bluetooth headset, the source is PCM audio data. The Bluetooth protocol defines the channel coding/decoding method, and the channel is the electromagnetic space between phone and headset. SBC (and optionally AAC) are the mandatory codecs defined by the Bluetooth specification, serving the purpose of data compression.

2. Principle of SBC

SBC stands for Subband Codec (次频带编码). Its core idea is to split the signal spectrum into several sub‑bands, encode each sub‑band separately, and allocate different numbers of bits (sampling depth) according to the perceptual importance of each band. For example, because human hearing is more sensitive to certain frequencies, finer quantization (more bits) can be used for those bands, while coarser quantization (fewer bits) suffices for less‑sensitive bands, achieving compression without noticeable quality loss.

The Discrete Cosine Transform (DCT) is often used to concentrate signal energy into low‑order coefficients. High‑order coefficients can then be encoded with fewer bits, further reducing data size.

3. SBC Encoding Process

The input to SBC encoding is PCM audio (time‑domain samples); the output is a binary stream. The process consists of:

Analysis Filter Transforms the time‑domain signal into the frequency domain using a polyphase filter bank. The number of sub‑bands can be 4 or 8.

Scale Factor Calculation For each sub‑band, the maximum amplitude is taken as its scale factor (e.g., sub‑band 1: 0‑128, sub‑band 2: 0‑32).

Bit Allocation Assigns a uniform number of bits to all samples within a sub‑band; different sub‑bands receive different bit counts based on their scale factors.

APCM (Adaptive Pulse Code Modulation) Quantizes each sub‑band using its scale factor and allocated bits, producing Quantized Subband data.

Bitstream Packing Combines the encoded sub‑bands, adds frame headers, checksums, etc., and outputs the final binary frame.

4. SBC Decoding Process

Decoding is the inverse of encoding. The binary stream is unpacked into frames, each containing the number of sub‑bands (4 or 8), scale factors, and bit allocation information. Using this metadata, the decoder reconstructs each sub‑band, applies the inverse polyphase filter bank, and finally merges all sub‑bands to obtain the PCM audio.

5. Characteristics of SBC

SBC is a lossy codec . To meet wireless bandwidth constraints, it discards some information, which leads to audible differences compared with the original PCM.

Supported sampling rates: 44.1 kHz, 48 kHz, 32 kHz, 16 kHz.

Supported channel modes: Mono, Dual‑Channel, Stereo, Joint Stereo.

References

de Bont F, Groenewegen M, Oomen W. A high-quality audio coding system at 128 kb/s[C]//Audio Engineering Society Convention 98. Audio Engineering Society, 1995.

奥本海姆, 谢弗, 巴克, 等. 离散时间信号处理: Discrete‑time signal processing[M]. 西安交通大学出版社, 2001.

A2DP - Advanced Audio Distribution Profile - Bluetooth: https://www.bluetooth.org/docman/handlers/DownloadDoc.ashx?doc_id=66605

顾学迈, 石硕, 贾敏. 信息与编码理论 : Information and coding theory[M]. 哈尔滨工业大学出版社, 2014.

Bluetoothaudio compressiondigital signal processingSBC codecsubband coding
Tencent Music Tech Team
Written by

Tencent Music Tech Team

Public account of Tencent Music's development team, focusing on technology sharing and communication.

0 followers
Reader feedback

How this landed with the community

login Sign in to like

Rate this article

Was this worth your time?

Sign in to rate
Discussion

0 Comments

Thoughtful readers leave field notes, pushback, and hard-won operational detail here.