Field Guide · technology

Also known as: vocoder

A vocoder (voice coder) is a speech codec that compresses voice into a few kilobits per second by modelling how speech is produced — pitch, voicing, and spectral shape — rather than recording the waveform.1 It is what makes digital voice radio possible: a raw pulse-code-modulation audio stream of 64–128 kbps is far too wide for a narrowband land-mobile channel, so the vocoder throws away the waveform and keeps only the parameters needed to rebuild an intelligible voice.

speech analysepitch · spectrum ~2–4 kbps frame synthesisere-create voice audio
A vocoder models how speech is produced and sends only parameters, so a voice fits in a few kbps.

How it works

Almost every modern vocoder rests on the source–filter model of human speech: the lungs and vocal folds are a source (a periodic buzz at the pitch frequency for voiced sounds like vowels, or turbulent noise for unvoiced sounds like “s” and “f”), and the throat, mouth, and nasal cavity form a slowly varying filter that shapes that source into recognizable phonemes.2 If you can measure the source (pitch, voiced/unvoiced decision, energy) and the filter (the spectral envelope) a few dozen times a second, you can transmit just those numbers and let the receiver drive a matching synthesizer.

Concretely, the encoder slices audio into short frames (typically 20 ms) and, for each frame, estimates:

  • Pitch / fundamental frequency — how fast the vocal folds vibrate.
  • Voicing — whether the frame (or each sub-band of it) is periodic or noise-like.
  • Spectral envelope — the resonances (formants) of the vocal tract, coded either as linear-predictive-coding coefficients or, in the MBE family, as a set of harmonic magnitudes.
  • Gain / energy — the loudness of the frame.

The decoder feeds a pitched pulse train or noise through the reconstructed spectral filter to synthesize output. Because only parameters cross the channel, a corrupted parameter is much more damaging than a corrupted audio sample would be — which is why vocoded speech on a weak signal sounds warbly or “R2-D2” robotic rather than merely noisy, and why the bit stream is wrapped in heavy forward error correction.

Variants

Vocoders split into two broad lineages. Parametric / sinusoidal coders (the Multi-Band Excitation family — IMBE, AMBE, AMBE+2, and TWELP) model speech as a sum of harmonics with per-band voicing decisions; they excel at very low rates and are dominant in land-mobile radio. CELP coders (ACELP and its descendants like AMR) instead search a codebook of excitation vectors that, run through an LPC filter, best match the original — this “analysis by synthesis” approach powers cellular telephony (GSM, UMTS, LTE). The open-source Codec 2 is parametric like MBE but royalty-free.

In practice

Vocoder choice is a trade between bit rate, audio quality, robustness, and licensing. Land-mobile systems run 2.4–4.4 kbps of net voice so two conversations fit a 12.5 kHz channel; cellular systems can afford 5–13 kbps for near-toll quality. The MBE/AMBE codecs are proprietary (licensed by DVSI), which is precisely why the amateur M17 project chose the open Codec 2 instead.

Relevance to SDR

Decoding digital voice requires running the matching vocoder — IMBE for P25 Phase 1, AMBE+2 for DMR and P25 Phase 2, AMBE for D-STAR, or Codec 2 for M17. GopherTrunk implements the land-mobile vocoders in pure Go so it can render clear (unencrypted) voice without the DVSI hardware dongle that older scanners required.

Sources

  1. Vocoder — Wikipedia, on speech coding that models how voice is produced. 

  2. Speech coding — Wikipedia, on the source–filter model and the parametric vs. CELP families of low-rate codecs. 

See also

Related links