[pulseaudio-commits] [Git][pulseaudio/pulseaudio][master] bluez5-device: use correct RTP payload type

Arun Raghavan gitlab at gitlab.freedesktop.org
Thu Jan 17 13:53:55 UTC 2019


Arun Raghavan pushed to branch master at PulseAudio / pulseaudio


Commits:
ff17374f by Tanu Kaskinen at 2019-01-17T12:43:39Z
bluez5-device: use correct RTP payload type

If one device tries to use PulseAudio to send audio over A2DP to another
device with bluez-alsa, that doesn't work because PulseAudio uses an
incorrect RTP payload type and bluez-alsa checks that the RTP payload
type is correct. According to the A2DP spec, the payload type should be
set to a number between 96 and 127.

Fixes: https://gitlab.freedesktop.org/pulseaudio/pulseaudio/issues/591

- - - - -


1 changed file:

- src/modules/bluetooth/module-bluez5-device.c


Changes:

=====================================
src/modules/bluetooth/module-bluez5-device.c
=====================================
@@ -505,7 +505,12 @@ static int a2dp_process_render(struct userdata *u) {
     /* write it to the fifo */
     memset(sbc_info->buffer, 0, sizeof(*header) + sizeof(*payload));
     header->v = 2;
-    header->pt = 1;
+
+    /* A2DP spec: "A payload type in the RTP dynamic range shall be chosen".
+     * RFC3551 defines the dynamic range to span from 96 to 127, and 96 appears
+     * to be the most common choice in A2DP implementations. */
+    header->pt = 96;
+
     header->sequence_number = htons(sbc_info->seq_num++);
     header->timestamp = htonl(u->write_index / pa_frame_size(&u->sample_spec));
     header->ssrc = htonl(1);



View it on GitLab: https://gitlab.freedesktop.org/pulseaudio/pulseaudio/commit/ff17374ffa9a8011236a5f7e0db74fddccbd19dc

-- 
View it on GitLab: https://gitlab.freedesktop.org/pulseaudio/pulseaudio/commit/ff17374ffa9a8011236a5f7e0db74fddccbd19dc
You're receiving this email because of your account on gitlab.freedesktop.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/pulseaudio-commits/attachments/20190117/faf7bf6a/attachment.html>


More information about the pulseaudio-commits mailing list