D-STAR data communications

The DDT2 protocol

This page describes the protocol D-RATS uses for communication over the wire.

Introduction

D-RATS uses a single frame type for all communication, similar in spirit to an Ethernet frame: source/destination, checksum, length, plus multiplexing and type fields. Independent streams use a session number (like a TCP/UDP port). Some sessions are reserved; others are negotiated dynamically.

Frame fields

  • Magic (1) — frame versioning / compression (0x22 uncompressed, 0xDD zlib-compressed)
  • Sequence (2) — ordering for reassembly
  • Session (1) — demultiplexing
  • Type (1) — content/control type within a session
  • Checksum (2) — CRC-16 (XMODEM/KERMIT variant) over the frame with checksum field zeroed
  • Length (2) — bytes in data field
  • Source (8) — uppercase ASCII callsign, tilde-padded (example KK7DS~~~)
  • Destination (8) — same format; CQCQCQ means broadcast
  • Data — variable payload

Frames are wrapped with [SOB] header and [EOB] trailer for resynchronization.

Compulsory sessions at startup

  • Control session 0 — negotiation and ping
  • Chat session 1 — multicast unreliable text / GPS beacons

Chat payload is intentionally left readable so GPS beacons remain compatible with Icom radios and simple listeners.