# AirPlay v0.5.1 - Table of Contents

> A pure-Elixir AirPlay (RAOP) audio sender: discover receivers and stream lossless ALAC audio to them — no native dependencies.

## Pages

- [AirPlay](readme.md)

## Modules

- [AirPlay.Decoder](AirPlay.Decoder.md): Stream-decode an audio file to AirPlay frames with bounded memory.
- [AirPlay.V2.GroupPlayer](AirPlay.V2.GroupPlayer.md): Minimal AirPlay 2 multi-room group player.
- [AirPlay.V2.GroupSession](AirPlay.V2.GroupSession.md): Persistent AirPlay 2 multi-room group session.
- [AirPlay.V2.Session](AirPlay.V2.Session.md): Persistent AirPlay 2 session for a single receiver.

- AirPlay 1 (RAOP)
  - [AirPlay](AirPlay.md): A pure-Elixir **AirPlay (RAOP) audio sender** — discover receivers on the LAN and
stream lossless audio to them, with no native dependencies (just `:crypto`,
`:gen_udp` and `:gen_tcp`).
  - [AirPlay.Alac](AirPlay.Alac.md): Pack PCM into **uncompressed** ALAC frames for AirPlay/RAOP.
  - [AirPlay.Cast](AirPlay.Cast.md): Play a PCM buffer to an AirPlay/RAOP receiver, end to end — a small session
GenServer exposing `play/3`, `stop/1`, `set_volume/2`.
  - [AirPlay.Discovery](AirPlay.Discovery.md): Discover AirPlay/RAOP receivers on the LAN via **mDNS** (multicast DNS,
`224.0.0.251:5353`) — the Bonjour service browse Apple devices use. Queries the
`_raop._tcp.local` service and resolves each instance's SRV (host/port) + A
(address) from the responses.
  - [AirPlay.Ntp](AirPlay.Ntp.md): NTP 64-bit timestamps for the AirPlay/RAOP timing channel.
  - [AirPlay.Player](AirPlay.Player.md): Streams ALAC-over-RTP audio to an AirPlay/RAOP receiver after the RTSP
handshake. Owns three UDP sockets
  - [AirPlay.Rtp](AirPlay.Rtp.md): RAOP packet builders: audio (PT 0x60), control `sync` (0xd4), and timing
response (0xd3). All multi-byte fields are big-endian.

  - [AirPlay.Rtsp](AirPlay.Rtsp.md): Minimal RTSP/1.0 client for the AirPlay/RAOP control plane.
  - [AirPlay.Session](AirPlay.Session.md): Drives the AirPlay/RAOP control handshake against a receiver.
  - [AirPlay.Source](AirPlay.Source.md): Decode a library track to the PCM format AirPlay/RAOP wants: 44.1 kHz, 16-bit,
stereo, little-endian, via `ffmpeg`. Returns the raw interleaved s16le bytes,
which `AirPlay.Alac` chops into 352-sample frames.

- AirPlay 2 (experimental)
  - [AirPlay.V2.Crypto](AirPlay.V2.Crypto.md): AirPlay 2 cryptographic helpers.
  - [AirPlay.V2.Pairing](AirPlay.V2.Pairing.md): AirPlay 2 transient pairing.
  - [AirPlay.V2.Player](AirPlay.V2.Player.md): Minimal AirPlay 2 file player.
  - [AirPlay.V2.Plist](AirPlay.V2.Plist.md): Minimal binary plist writer for AirPlay 2 SETUP bodies.
  - [AirPlay.V2.Ptp](AirPlay.V2.Ptp.md): AirPlay 2 gPTP packet and clock helpers.
  - [AirPlay.V2.PtpBmca](AirPlay.V2.PtpBmca.md): AirPlay 2 gPTP BMCA-yield worker.
  - [AirPlay.V2.Rtsp2](AirPlay.V2.Rtsp2.md): RTSP client for AirPlay 2.
  - [AirPlay.V2.SecureChannel](AirPlay.V2.SecureChannel.md): AirPlay 2 encrypted RTSP control/event channel framing.
  - [AirPlay.V2.Setup](AirPlay.V2.Setup.md): AirPlay 2 SETUP request helpers.
  - [AirPlay.V2.Srp](AirPlay.V2.Srp.md): AirPlay 2 SRP-6a client proof generation.
  - [AirPlay.V2.TLV](AirPlay.V2.TLV.md): AirPlay 2 TLV8 encoder/decoder.

