diff options
author | Christophe Fergeau <cfergeau@mandriva.com> | 2010-08-02 11:49:14 +0200 |
---|---|---|
committer | Christophe Fergeau <cfergeau@mandriva.com> | 2010-08-02 12:08:02 +0200 |
commit | 436a9c4219c234f07f6ae7fe1a37714ac764a492 (patch) | |
tree | c16bd3e11d053005a64f33883d962a69fdf33157 /airtunes2.rst | |
parent | Slight improvement in "Connection" description (diff) | |
download | Airtunes2-436a9c4219c234f07f6ae7fe1a37714ac764a492.tar.xz Airtunes2-436a9c4219c234f07f6ae7fe1a37714ac764a492.zip |
Add details about audio packet transmission
Diffstat (limited to '')
-rw-r--r-- | airtunes2.rst | 26 |
1 files changed, 21 insertions, 5 deletions
diff --git a/airtunes2.rst b/airtunes2.rst index 599e0ae..29779ca 100644 --- a/airtunes2.rst +++ b/airtunes2.rst @@ -61,6 +61,27 @@ Connect #. Prepare RTP connection for audio packets +Transmitting Audio +~~~~~~~~~~~~~~~~~~ + +The audio data is encapsulated in an RTP packet (see RFC3550 Section 5.1) + +#. Bytes 0-1 of the RTP Header are 0x80, 0x60 +#. Bytes 2-3 store the current sequence number (whose initial value was set + in the RECORD RTSP request) +#. Bytes 4-7 store the current RTP timestamp (initial value was transmitted + to the Airtunes device in the RECORD RTSP request) +#. Bytes 8-11 store the SSRC (random number which will be the same in all + audio packets, see RFC3550 Section 5.1 for more details) (TODO: is the + SSRC the same as the RTSP client session ID ?) +#. Starting at byte 12 comes the audio data (see `Packetizing audio`_ for + its format) +#. Send this RTP packet as UDP on the audio data port +#. Increase sequence number by one for next audio packet +#. Increase timestamp by number of frames in this audio packet + + + Disconnect ~~~~~~~~~~ @@ -520,11 +541,6 @@ Packetizing audio the rest stays unencrypted) #. Copy audio header to buffer #. Append encrypted audio data to buffer - -#. Set bytes 2-4 to sequence number in big endian -#. Set bytes 4-8 to timestamp in big endian -#. Increase sequence number by one for next packet -#. Increase timestamp by number of frames in this packet Metadata |