Mode S transponders and Extended Squitter
Mode S (Mode Select) is the underlying transponder standard that ADS-B builds upon. Mode S transponders do two things:- Reply to interrogations — ground radar interrogates individual aircraft using a 24-bit ICAO address, and the transponder replies with altitude, identity, or other data.
- Spontaneously broadcast — a subset of Mode S transmissions, called Extended Squitter (ES), are sent without interrogation. These are the ADS-B messages.
Message structure
Every Mode S message begins with a common header. The first 5 bits identify the Downlink Format (DF), which determines both the total message length and how the remaining bits are interpreted.Short messages — 56 bits
Used by DF 0, 4, 5, and 11. Contain a 32-bit data payload followed by a 24-bit parity/address field.
Long messages — 112 bits
Used by DF 16, 17, 18, 19, 20, and 21. Contain an 88-bit data payload followed by a 24-bit parity/address field.
CRC-24 parity
Each Mode S message ends with a 24-bit field used for error detection. Its role differs by message type:- DF 11, 17, 18, 19 — The final 24 bits are a Parity/Interrogator ID (PI) field. A valid message has PI equal to the CRC computed over the preceding bits. This is a straightforward CRC check.
- DF 0, 4, 5, 16, 20, 21 — The final 24 bits are an Address/Parity (AP) field. This field holds the CRC XOR’d with the transmitting aircraft’s ICAO address. A receiver can recover the ICAO address by computing
AP XOR CRC(message). A message is accepted only if the recovered address matches a previously seen aircraft in the receiver’s plane dictionary.
Because DF 0/4/5/16/20/21 require a known ICAO address to verify parity, gr-adsb will only accept these message types for aircraft it has already seen via a DF 11 or DF 17 message.
Compact Position Reporting (CPR)
ADS-B position messages (TC 9–18 for barometric altitude, TC 20–22 for GNSS height) do not transmit raw latitude and longitude. Instead, they use Compact Position Reporting (CPR), a scheme that encodes position at high resolution using only 17 bits per coordinate by taking advantage of the Earth’s geometry. CPR requires two consecutive messages — one even frame and one odd frame — to unambiguously resolve a global position. Each message carries a 1-bit frame flag indicating which type it is.Receive even frame
An airborne position message arrives with
frame_bit = 0. The receiver stores the 17-bit CPR latitude and longitude along with a timestamp.Receive odd frame
A subsequent airborne position message arrives with
frame_bit = 1. The receiver stores its CPR values.CPR timeout
CPR data becomes stale as the aircraft moves. gr-adsb uses a 30-second timeout (CPR_TIMEOUT_S = 30 in decoder.py): if the even and odd frame timestamps are more than 30 seconds apart, the stored CPR data is discarded and the position cannot be decoded until a fresh pair of frames is received.
Related systems
ADS-B at 1090 MHz operates alongside two related systems that gr-adsb may also encounter:TIS-B — Traffic Information Service Broadcast
TIS-B — Traffic Information Service Broadcast
TIS-B rebroadcasts radar-derived traffic information for aircraft that are not themselves ADS-B equipped. These messages are transmitted by ground stations on 1090 MHz using DF 18 with certain CF field values (CF = 2, 3, or 5 in the CF field lookup table). gr-adsb recognizes these messages but TIS-B payload decoding is noted as not yet fully implemented.
ACAS — Airborne Collision Avoidance System
ACAS — Airborne Collision Avoidance System
ACAS (also known as TCAS) uses Mode S interrogations and replies to detect and resolve potential mid-air conflicts. ACAS-related messages include DF 0 (Short Air-Air Surveillance) and DF 16 (Long Air-Air Surveillance). These are 56-bit and 112-bit messages respectively and are fully decoded by gr-adsb when the aircraft’s ICAO address is already known.