Also known as: extended colour code, TETRA scrambling code, ECC
The TETRA extended colour code is the 30-bit value that uniquely identifies a cell’s scrambling context and seeds the TETRA scrambler for every logical channel except the BSCH.1 It is built from three fields, MSB-first: the 10-bit mobile country code (MCC), the 14-bit mobile network code (MNC), and the 6-bit colour code that distinguishes neighbouring cells of the same network.2 Because the scrambler is seeded from it, a receiver cannot decode any traffic or signalling channel until it has learned the extended colour code — which it does by decoding the one channel that is not scrambled with it.
Cold-start learning
At cold start a TETRA receiver has no configured colour code, so it hunts the
synchronisation burst, whose BSCH is scrambled with colour code zero
— a value any receiver can undo. The BSCH carries a MAC-SYNC broadcast PDU whose
60 decoded bits contain the three components: the 6-bit colour code, plus (further along) the 10-bit MCC and
14-bit MNC. GopherTrunk’s ParseSyncPDU reads those fields, and ExtendedColourCode assembles them:
(MCC & 0x3FF) << 20 | (MNC & 0x3FFF) << 6 | (colour & 0x3F).
Once that value is in hand, every other channel — BNCH SYSINFO, SCH/HD, SCH/F, the AACH, and the traffic channels — becomes decodable without any operator configuration. This is why the BSCH is the linchpin of TETRA cold acquisition: it is the bootstrap that turns a locked-but-opaque carrier into a fully readable cell.
Seeding the scrambler
The packed value carries e(1) in bit 29 (the MCC’s most-significant bit) down to e(30) in bit 0 (the colour code’s least-significant bit). The scrambler, however, wants e(i+1) in state bit i, so the value’s low 30 bits are bit-reversed on the way into the LFSR — a detail that, when wrong, is invisible to any round-trip test because both encode and decode share the reversed seed (see TETRA scrambler). Keeping the packing order fixed here — MCC, then MNC, then colour, MSB-first — is what makes the reversed seed land the colour-code bits where §8.2.5.2’s initialisation equation expects them.
Relevance to SDR
internal/radio/tetra/sync_pdu.go implements the whole path: SyncPDU holds the parsed MAC-SYNC fields,
ParseSyncPDU extracts them from the BSCH bit vector, and both the method form SyncPDU.ExtendedColourCode
and the package function ExtendedColourCode(mcc, mnc, colour) produce the 30-bit seed. The scanner passes
that seed into framing.NewScramblerTetra and the traffic extractor, so the learned identity flows straight
into descrambling. An operator who already knows the cell’s MCC/MNC/colour can supply the three components
directly, skipping cold-start learning — but on an unknown system the BSCH decode is what makes everything
else possible.
Sources
-
Terrestrial Trunked Radio — Wikipedia, on the TETRA standard and its cell-identity broadcast. ↩
-
Mobile country code — Wikipedia, on the MCC/MNC pair that identifies a mobile network. ↩