Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't work with pipewire-pulseaudio #419

Open
liferooter opened this issue Apr 18, 2021 · 11 comments
Open

Don't work with pipewire-pulseaudio #419

liferooter opened this issue Apr 18, 2021 · 11 comments

Comments

@liferooter
Copy link

liferooter commented Apr 18, 2021

Versions

Distro: Fedora 34 Beta
Pulseaudio-dlna: 0.6.1 (from cygn/pulseaudio-dlna COPR)
Pipewire: 0.3.25

Steps to reproduce

  1. Run pulseaudio-dlna

What I expect

pulseaudio-dlna will work properly with pipewire-pulseaudio instead of pulseaudio.

What really happens

pulseaudio-dlna stucks with message: Could not connect to pulseaudio! Application terminates!

Logs

04-18 15:36:15 pulseaudio_dlna.application                    INFO     Using version: 0.6.1
04-18 15:36:15 pulseaudio_dlna.application                    INFO     Binding to *:8080
04-18 15:36:15 pulseaudio_dlna.application                    INFO     Encoder settings:
04-18 15:36:15 pulseaudio_dlna.application                    INFO       <AVConvAacEncoder available="False" bit-rate="192">
04-18 15:36:15 pulseaudio_dlna.application                    INFO       <AVConvFlacEncoder available="False">
04-18 15:36:15 pulseaudio_dlna.application                    INFO       <AVConvL16Encoder available="False" sample-rate="44100" channels="2">
04-18 15:36:15 pulseaudio_dlna.application                    INFO       <AVConvMp3Encoder available="False" bit-rate="192">
04-18 15:36:15 pulseaudio_dlna.application                    INFO       <AVConvOggEncoder available="False" bit-rate="192">
04-18 15:36:15 pulseaudio_dlna.application                    INFO       <AVConvOpusEncoder available="False" bit-rate="192">
04-18 15:36:15 pulseaudio_dlna.application                    INFO       <AVConvWavEncoder available="False">
04-18 15:36:15 pulseaudio_dlna.application                    INFO       <FFMpegAacEncoder available="False" bit-rate="192">
04-18 15:36:15 pulseaudio_dlna.application                    INFO       <FFMpegFlacEncoder available="False">
04-18 15:36:15 pulseaudio_dlna.application                    INFO       <FFMpegL16Encoder available="False" sample-rate="44100" channels="2">
04-18 15:36:15 pulseaudio_dlna.application                    INFO       <FFMpegMp3Encoder available="False" bit-rate="192">
04-18 15:36:15 pulseaudio_dlna.application                    INFO       <FFMpegOggEncoder available="False" bit-rate="192">
04-18 15:36:15 pulseaudio_dlna.application                    INFO       <FFMpegOpusEncoder available="False" bit-rate="192">
04-18 15:36:15 pulseaudio_dlna.application                    INFO       <FFMpegWavEncoder available="False">
04-18 15:36:15 pulseaudio_dlna.application                    INFO       <FaacAacEncoder available="False" bit-rate="192">
04-18 15:36:15 pulseaudio_dlna.application                    INFO       <FlacFlacEncoder available="False">
04-18 15:36:15 pulseaudio_dlna.application                    INFO       <LameMp3Encoder available="False" bit-rate="192">
04-18 15:36:15 pulseaudio_dlna.application                    INFO       <NullEncoder available="True">
04-18 15:36:15 pulseaudio_dlna.application                    INFO       <OggencOggEncoder available="True" bit-rate="192">
04-18 15:36:15 pulseaudio_dlna.application                    INFO       <OpusencOpusEncoder available="False" bit-rate="192">
04-18 15:36:15 pulseaudio_dlna.application                    INFO       <SoxL16Encoder available="True" sample-rate="44100" channels="2">
04-18 15:36:15 pulseaudio_dlna.application                    INFO       <SoxWavEncoder available="True">
04-18 15:36:15 pulseaudio_dlna.application                    INFO     Codec settings:
04-18 15:36:15 pulseaudio_dlna.application                    INFO       <AacCodec enabled="True" priority="12" mime_type="audio/aac" backend="generic">
04-18 15:36:15 pulseaudio_dlna.application                    INFO       <FlacCodec enabled="True" priority="9" mime_type="audio/flac" backend="generic">
04-18 15:36:15 pulseaudio_dlna.application                    INFO       <L16Codec enabled="True" priority="1" mime_type="audio/L16" backend="generic">
04-18 15:36:15 pulseaudio_dlna.application                    INFO       <Mp3Codec enabled="True" priority="18" mime_type="audio/mp3" backend="generic">
04-18 15:36:15 pulseaudio_dlna.application                    INFO       <OggCodec enabled="True" priority="6" mime_type="audio/ogg" backend="generic">
04-18 15:36:15 pulseaudio_dlna.application                    INFO       <OpusCodec enabled="True" priority="3" mime_type="audio/opus" backend="generic">
04-18 15:36:15 pulseaudio_dlna.application                    INFO       <WavCodec enabled="True" priority="15" mime_type="audio/wav" backend="generic">
04-18 15:36:15 pulseaudio_dlna.plugins.chromecast             INFO     ChromecastPlugin.discover()
Произошла ошибка: Нет такого объекта
04-18 15:36:15 pulseaudio_dlna.pulseaudio                     CRITICAL Failed to load module "module-dbus-protocol"!
04-18 15:36:15 pulseaudio_dlna.pulseaudio                     INFO     Probing for $PULSE_DBUS_SERVER unsuccessful.
04-18 15:36:15 pulseaudio_dlna.pulseaudio                     INFO     Probing for /run/pulse/dbus-socket unsuccessful.
04-18 15:36:15 pulseaudio_dlna.pulseaudio                     INFO     Probing for $XDG_RUNTIME_DIR unsuccessful.
04-18 15:36:15 pulseaudio_dlna.pulseaudio                     INFO     Probing for org.PulseAudio.ServerLookup1 unsuccessful.
04-18 15:36:15 pulseaudio_dlna.pulseaudio                     INFO     Found the following pulseaudio server addresses: 
04-18 15:36:15 pulseaudio_dlna.pulseaudio                     CRITICAL Could not connect to pulseaudio! Application terminates!
04-18 15:36:23 pulseaudio_dlna.discover                       INFO     SSDPDiscover.search()
@almereyda
Copy link

almereyda commented Apr 24, 2021

After checking in https://github.com/masmu/pulseaudio-dlna/blob/master/pulseaudio_dlna/pulseaudio.py and finding https://gist.github.com/saivert/25bff8f1d63167c7880fff654a0f3e0e it was easy to retrieve the Pulseaudio socket from PipeWire with

$ systemctl --user status pipewire-pulse.socket
● pipewire-pulse.socket - PipeWire PulseAudio
     Loaded: loaded (/usr/lib/systemd/user/pipewire-pulse.socket; enabled; vendor preset: enabled)
     Active: active (running) since Sat 2021-04-24 19:21:34 CEST; 5h 2min ago
   Triggers: ● pipewire-pulse.service
     Listen: /run/user/1000/pulse/native (Stream)
     CGroup: /user.slice/user-1000.slice/user@1000.service/pipewire-pulse.socket

Apr 24 19:21:34 pons systemd[2375]: Listening on PipeWire PulseAudio.

and then injecting it into pulseaudio-dlna with monkey patching /usr/lib/python3.9/site-packages/pulseaudio_dlna/pulseaudio.py:

$ diff /usr/lib/python3.9/site-packages/pulseaudio_dlna/pulseaudio.py.before /usr/lib/python3.9/site-packages/pulseaudio_dlna/pulseaudio.py
101a102
>             '/run/user/1000/pulse/native',

et voilà, we're up and running:

$ pulseaudio-dlna       
04-25 00:24:18 pulseaudio_dlna.application                    INFO     Using version: 0.6.1
04-25 00:24:18 pulseaudio_dlna.application                    INFO     Binding to *:8080
04-25 00:24:18 pulseaudio_dlna.application                    INFO     Encoder settings:
04-25 00:24:18 pulseaudio_dlna.application                    INFO       <AVConvAacEncoder available="False" bit-rate="192">
04-25 00:24:18 pulseaudio_dlna.application                    INFO       <AVConvFlacEncoder available="False">
04-25 00:24:18 pulseaudio_dlna.application                    INFO       <AVConvL16Encoder available="False" sample-rate="44100" channels="2">
04-25 00:24:18 pulseaudio_dlna.application                    INFO       <AVConvMp3Encoder available="False" bit-rate="192">
04-25 00:24:18 pulseaudio_dlna.application                    INFO       <AVConvOggEncoder available="False" bit-rate="192">
04-25 00:24:18 pulseaudio_dlna.application                    INFO       <AVConvOpusEncoder available="False" bit-rate="192">
04-25 00:24:18 pulseaudio_dlna.application                    INFO       <AVConvWavEncoder available="False">
04-25 00:24:18 pulseaudio_dlna.application                    INFO       <FFMpegAacEncoder available="True" bit-rate="192">
04-25 00:24:18 pulseaudio_dlna.application                    INFO       <FFMpegFlacEncoder available="True">
04-25 00:24:18 pulseaudio_dlna.application                    INFO       <FFMpegL16Encoder available="True" sample-rate="44100" channels="2">
04-25 00:24:18 pulseaudio_dlna.application                    INFO       <FFMpegMp3Encoder available="True" bit-rate="192">
04-25 00:24:18 pulseaudio_dlna.application                    INFO       <FFMpegOggEncoder available="True" bit-rate="192">
04-25 00:24:18 pulseaudio_dlna.application                    INFO       <FFMpegOpusEncoder available="True" bit-rate="192">
04-25 00:24:18 pulseaudio_dlna.application                    INFO       <FFMpegWavEncoder available="True">
04-25 00:24:18 pulseaudio_dlna.application                    INFO       <FaacAacEncoder available="True" bit-rate="192">
04-25 00:24:18 pulseaudio_dlna.application                    INFO       <FlacFlacEncoder available="True">
04-25 00:24:18 pulseaudio_dlna.application                    INFO       <LameMp3Encoder available="True" bit-rate="192">
04-25 00:24:18 pulseaudio_dlna.application                    INFO       <NullEncoder available="True">
04-25 00:24:18 pulseaudio_dlna.application                    INFO       <OggencOggEncoder available="True" bit-rate="192">
04-25 00:24:18 pulseaudio_dlna.application                    INFO       <OpusencOpusEncoder available="True" bit-rate="192">
04-25 00:24:18 pulseaudio_dlna.application                    INFO       <SoxL16Encoder available="True" sample-rate="44100" channels="2">
04-25 00:24:18 pulseaudio_dlna.application                    INFO       <SoxWavEncoder available="True">
04-25 00:24:18 pulseaudio_dlna.application                    INFO     Codec settings:
04-25 00:24:18 pulseaudio_dlna.application                    INFO       <AacCodec enabled="True" priority="12" mime_type="audio/aac" backend="generic">
04-25 00:24:18 pulseaudio_dlna.application                    INFO       <FlacCodec enabled="True" priority="9" mime_type="audio/flac" backend="generic">
04-25 00:24:18 pulseaudio_dlna.application                    INFO       <L16Codec enabled="True" priority="1" mime_type="audio/L16" backend="generic">
04-25 00:24:18 pulseaudio_dlna.application                    INFO       <Mp3Codec enabled="True" priority="18" mime_type="audio/mp3" backend="generic">
04-25 00:24:18 pulseaudio_dlna.application                    INFO       <OggCodec enabled="True" priority="6" mime_type="audio/ogg" backend="generic">
04-25 00:24:18 pulseaudio_dlna.application                    INFO       <OpusCodec enabled="True" priority="3" mime_type="audio/opus" backend="generic">
04-25 00:24:18 pulseaudio_dlna.application                    INFO       <WavCodec enabled="True" priority="15" mime_type="audio/wav" backend="generic">
04-25 00:24:18 pulseaudio_dlna.plugins.chromecast             INFO     ChromecastPlugin.discover()
Fehlgeschlagen: Entität nicht vorhanden
04-25 00:24:18 pulseaudio_dlna.pulseaudio                     CRITICAL Failed to load module "module-dbus-protocol"!
04-25 00:24:18 pulseaudio_dlna.pulseaudio                     INFO     Probing for $PULSE_DBUS_SERVER unsuccessful.
04-25 00:24:18 pulseaudio_dlna.pulseaudio                     INFO     Probing for /run/pulse/dbus-socket unsuccessful.
04-25 00:24:18 pulseaudio_dlna.pulseaudio                     INFO     Probing for /run/user/1000/pulse/native successful (unix:path=/run/user/1000/pulse/native).
04-25 00:24:18 pulseaudio_dlna.pulseaudio                     INFO     Probing for $XDG_RUNTIME_DIR unsuccessful.
04-25 00:24:18 pulseaudio_dlna.pulseaudio                     INFO     Probing for org.PulseAudio.ServerLookup1 unsuccessful.
04-25 00:24:18 pulseaudio_dlna.pulseaudio                     INFO     Found the following pulseaudio server addresses: unix:path=/run/user/1000/pulse/native
04-25 00:24:18 pulseaudio_dlna.pulseaudio                     INFO     Connecting to pulseaudio on "unix:path=/run/user/1000/pulse/native" ...
04-25 00:24:24 pulseaudio_dlna.discover                       INFO     SSDPDiscover.search()

Unfortunately the device will not show up in pavucontrol as of now, which may need further investigation.


Fedora 33
PipeWire 0.3.24
copr:copr.fedorainfracloud.org:cygn/pulseaudio-dlna 0.6.1

@Cygn
Copy link

Cygn commented Apr 25, 2021

It's something that should be resolved at pipewire level - They do promise 100% pulse compatibility, but it isn't there yet. There is
still some missing module equivalents etc - see here https://gitlab.freedesktop.org/pipewire/pipewire/-/issues/543
(F33 here, I haven't made to switch to pipewire-pulse yet, so thx for early testing !)

@almereyda
Copy link

almereyda commented Apr 26, 2021

Now that this has been merged upstream, I'll just need to wait for a PipeWire version with module-loopback present to be downstreamed by my distribution, and I should be ready to go with pulseaudio-dlna again?

Then we have a quick and dirty test for compatibility:

$ pactl load-module module-loopback
Fehlgeschlagen: Entität nicht vorhanden

The same command could also help to identify the PipeWire Pulseaudio socket in another way:

$ pactl info | head -n 1
Server-Zeichenkette: /run/user/1000/pulse/native

Is this deterministic, do they retrieve this information from DBUS? How could pulseaudio-dlna leverage a similar discovery mechanism to also find Pulseaudio sockets in other locations, other than currently expected?

@almereyda
Copy link

almereyda commented May 1, 2021

There's another regression on early testing this a pre-1.0.0 pipewire release. When running pulseaudio-dlna there is also 100% CPU usage on pipewire-pulse and journald, since there are more than 10.000 events per second logged, which makes it kind of hard to debug by manually checking the log. First we get this line, and then the one below just repeats over and over again, until the unit is restarted:

Mai 01 18:24:56 pons pipewire-pulse[2610]: pulse-server 0x555a3fb3efc0: client:0x555a40b22f90 [(null)] error -95 (Operation not supported)
Mai 01 18:24:56 pons pipewire-pulse[2610]: pulse-server 0x555a3fb3efc0: client:0x555a40b22f90 [(null)] error -5 (Input/output error)

Seems this is also asking for an issue upstream, since behaviour can be reproduced with:

$ systemctl restart --user pipewire-pulse
$ id=$(systemctl show -p InvocationID --user --value pipewire-pulse); journalctl INVOCATION_ID=${id} + _SYSTEMD_INVOCATION_ID=${id} -f

and in another terminal

$ pulseaudio-dlna (--debug)

Here's their homework:

@almereyda
Copy link

An update from Fedora 33, where pipewire version 0.3.25 recently landed.

As of https://gitlab.freedesktop.org/pipewire/pipewire/-/commit/e7b04bca2c7f22b2db9f8c3c6da48bd724c38c31 the patch is available in that version. Click the three little dots next to parent ... master and 0.3.25 shows up.

I can also verify that the loopback module is working with

$ pactl load-module module-loopback
262144

which has the loopback appear in the Playback tab of pavucontrol, and generates a fancy feedback loop on the speakers, if the microphone is unmuted.

$ pactl unload-module module-loopback

then helps to get silence again. So off we go to test the interface with pulseaudio-dlna again:

05-01 18:48:08 urllib3.connectionpool                         DEBUG    Starting new HTTP connection (1): 10.10.10.200:49494
05-01 18:48:08 urllib3.connectionpool                         DEBUG    http://10.10.10.200:49494 "GET /description.xml HTTP/1.1" 200 2070
05-01 18:48:08 pyupnpv2                                       DEBUG    Response from UPNP device (http://10.10.10.200:49494/description.xml)
<?xml version="1.0"?>
<root xmlns="urn:schemas-upnp-org:device-1-0">
<specVersion>
<major>1</major>
<minor>0</minor>
</specVersion>
<device>
<deviceType>urn:schemas-upnp-org:device:MediaRenderer:1</deviceType>
<presentationURL></presentationURL>
<friendlyName>ex</friendlyName>
<manufacturer>Ivo Clarysse, Henner Zeller</manufacturer>
<manufacturerURL>http://github.com/hzeller/gmrender-resurrect</manufacturerURL>
<modelDescription>gmediarender 0.0.9</modelDescription>
<modelName>gmediarender</modelName>
<modelNumber>0.0.9_git2021-03-14_4ac7d89</modelNumber>
<modelURL>http://github.com/hzeller/gmrender-resurrect</modelURL>
<UDN>uuid:374580b279c7f5edec7a8a0805d6d041</UDN>
<iconList>
<icon>
<mimetype>image/png</mimetype>
<width>64</width>
<height>64</height>
<depth>24</depth>
<url>/upnp/grender-64x64.png</url>
</icon>
<icon>
<mimetype>image/png</mimetype>
<width>128</width>
<height>128</height>
<depth>24</depth>
<url>/upnp/grender-128x128.png</url>
</icon>
</iconList>
<serviceList>
<service>
<serviceType>urn:schemas-upnp-org:service:AVTransport:1</serviceType>
<serviceId>urn:upnp-org:serviceId:AVTransport</serviceId>
<SCPDURL>/upnp/rendertransportSCPD.xml</SCPDURL>
<controlURL>/upnp/control/rendertransport1</controlURL>
<eventSubURL>/upnp/event/rendertransport1</eventSubURL>
</service>
<service>
<serviceType>urn:schemas-upnp-org:service:ConnectionManager:1</serviceType>
<serviceId>urn:upnp-org:serviceId:ConnectionManager</serviceId>
<SCPDURL>/upnp/renderconnmgrSCPD.xml</SCPDURL>
<controlURL>/upnp/control/renderconnmgr1</controlURL>
<eventSubURL>/upnp/event/renderconnmgr1</eventSubURL>
</service>
<service>
<serviceType>urn:schemas-upnp-org:service:RenderingControl:1</serviceType>
<serviceId>urn:upnp-org:serviceId:RenderingControl</serviceId>
<SCPDURL>/upnp/rendercontrolSCPD.xml</SCPDURL>
<controlURL>/upnp/control/rendercontrol1</controlURL>
<eventSubURL>/upnp/event/rendercontrol1</eventSubURL>
</service>
</serviceList>
</device>
<URLBase>http://10.10.10.200:49494/</URLBase>
</root>

05-01 18:48:08 urllib3.connectionpool                         DEBUG    Starting new HTTP connection (1): 10.10.10.200:49494
05-01 18:48:08 urllib3.connectionpool                         DEBUG    http://10.10.10.200:49494 "GET /upnp/rendertransportSCPD.xml HTTP/1.1" 200 15697
05-01 18:48:08 urllib3.connectionpool                         DEBUG    Resetting dropped connection: 10.10.10.200
05-01 18:48:08 urllib3.connectionpool                         DEBUG    http://10.10.10.200:49494 "GET /upnp/renderconnmgrSCPD.xml HTTP/1.1" 200 4783
05-01 18:48:08 urllib3.connectionpool                         DEBUG    Resetting dropped connection: 10.10.10.200
05-01 18:48:08 urllib3.connectionpool                         DEBUG    http://10.10.10.200:49494 "GET /upnp/rendercontrolSCPD.xml HTTP/1.1" 200 13317

This cycle repeats four times. After the first time, it also outputs:

05-01 18:48:07 urllib3.connectionpool                         DEBUG    http://10.10.10.200:49494 "POST /upnp/control/renderconnmgr1 HTTP/1.1" 200 6675
05-01 18:48:07 pyupnpv2                                       DEBUG    SENT {'Content-Type': 'text/xml; charset="utf-8"', 'SOAPAction': '"urn:schemas-upnp-org:service:ConnectionManager:1#GetProtocolInfo"'}:
URL: http://10.10.10.200:49494/upnp/control/renderconnmgr1
b'<?xml version=\'1.0\' encoding=\'utf-8\'?>\n<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/" s:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"><s:Body><u:GetProtocolInfo xmlns:u="urn:schemas-upnp-org:service:ConnectionManager:1"/></s:Body></s:Envelope>'
05-01 18:48:07 pyupnpv2                                       DEBUG    RECEIVED [200] - {'CONTENT-LENGTH': '6675', 'Accept-Ranges': 'bytes', 'CONTENT-TYPE': 'text/xml; charset="utf-8"', 'DATE': 'Sat, 01 May 2021 16:48:07 GMT', 'EXT': '', 'SERVER': 'Linux/5.4.0-1034-raspi, UPnP/1.0, Portable SDK for UPnP devices/1.8.4', 'X-User-Agent': 'redsonic'}:
b'<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/" s:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"><s:Body>\n<u:GetProtocolInfoResponse xmlns:u="urn:schemas-upnp-org:service:ConnectionManager:1">\r\n<Source></Source>\r\n<Sink>http-get:*:application/dash+xml:*,http-get:*:application/kate:*,http-get:*:application/mxf:*,http-get:*:application/ogg:*,http-get:*:application/sdp:*,http-get:*:application/ttml+xml:*,http-get:*:application/vnd.ms-sstr+xml:*,http-get:*:application/vnd.rn-realmedia:*,http-get:*:application/x-3gp:*,http-get:*:application/x-apetag:*,http-get:*:application/x-ass:*,http-get:*:application/x-bzip:*,http-get:*:application/x-dtls:*,http-get:*:application/x-gdp:*,http-get:*:application/x-hls:*,http-get:*:application/x-icy:*,http-get:*:application/x-id3:*,http-get:*:application/x-kate:*,http-get:*:application/x-navi-animation:*,http-get:*:application/x-ogg-avi:*,http-get:*:application/x-ogm-audio:*,http-get:*:application/x-ogm-text:*,http-get:*:application/x-ogm-video:*,http-get:*:application/x-pn-realaudio:*,http-get:*:application/x-rdt:*,http-get:*:application/x-rtcp:*,http-get:*:application/x-rtcp-stream:*,http-get:*:application/x-rtp:*,http-get:*:application/x-rtp-stream:*,http-get:*:application/x-sctp:*,http-get:*:application/x-srtcp:*,http-get:*:application/x-srtcp-stream:*,http-get:*:application/x-srtp:*,http-get:*:application/x-srtp-stream:*,http-get:*:application/x-ssa:*,http-get:*:application/x-subtitle:*,http-get:*:application/x-subtitle-avi:*,http-get:*:application/x-subtitle-dks:*,http-get:*:application/x-subtitle-lrc:*,http-get:*:application/x-subtitle-mpl2:*,http-get:*:application/x-subtitle-qttext:*,http-get:*:application/x-subtitle-sami:*,http-get:*:application/x-subtitle-tmplayer:*,http-get:*:application/x-subtitle-unknown:*,http-get:*:application/x-subtitle-vtt:*,http-get:*:application/x-teletext:*,http-get:*:application/x-usf:*,http-get:*:application/x-yuv4mpeg:*,http-get:*:audio/*:*,http-get:*:audio/AMR:*,http-get:*:audio/AMR-WB:*,http-get:*:audio/G722:*,http-get:*:audio/G723:*,http-get:*:audio/G729:*,http-get:*:audio/L16;rate=44100;channels=2:*,http-get:*:audio/ac3:*,http-get:*:audio/aiff:*,http-get:*:audio/alac:*,http-get:*:audio/m4a:*,http-get:*:audio/midi:*,http-get:*:audio/mp4:*,http-get:*:audio/mpeg:*,http-get:*:audio/ms-gsm:*,http-get:*:audio/ogg:*,http-get:*:audio/riff-midi:*,http-get:*:audio/webm:*,http-get:*:audio/x-ac3:*,http-get:*:audio/x-adpcm:*,http-get:*:audio/x-aiff:*,http-get:*:audio/x-alac:*,http-get:*:audio/x-alaw:*,http-get:*:audio/x-amr-nb-sh:*,http-get:*:audio/x-amr-wb-sh:*,http-get:*:audio/x-au:*,http-get:*:audio/x-ay:*,http-get:*:audio/x-bv:*,http-get:*:audio/x-celt:*,http-get:*:audio/x-dts:*,http-get:*:audio/x-eac3:*,http-get:*:audio/x-flac:*,http-get:*:audio/x-gbs:*,http-get:*:audio/x-gsm:*,http-get:*:audio/x-gym:*,http-get:*:audio/x-hes:*,http-get:*:audio/x-iLBC:*,http-get:*:audio/x-ircam:*,http-get:*:audio/x-it:*,http-get:*:audio/x-kss:*,http-get:*:audio/x-lpcm:*,http-get:*:audio/x-m4a:*,http-get:*:audio/x-matroska:*,http-get:*:audio/x-midi-event:*,http-get:*:audio/x-mod:*,http-get:*:audio/x-mpeg:*,http-get:*:audio/x-mulaw:*,http-get:*:audio/x-musepack:*,http-get:*:audio/x-nellymoser:*,http-get:*:audio/x-nist:*,http-get:*:audio/x-nsf:*,http-get:*:audio/x-opus:*,http-get:*:audio/x-paris:*,http-get:*:audio/x-pn-realaudio:*,http-get:*:audio/x-private-ts-lpcm:*,http-get:*:audio/x-private1-ac3:*,http-get:*:audio/x-private1-dts:*,http-get:*:audio/x-private1-lpcm:*,http-get:*:audio/x-private2-lpcm:*,http-get:*:audio/x-raw:*,http-get:*:audio/x-rf64:*,http-get:*:audio/x-s3m:*,http-get:*:audio/x-sap:*,http-get:*:audio/x-sbc:*,http-get:*:audio/x-scpls:*,http-get:*:audio/x-sds:*,http-get:*:audio/x-sid:*,http-get:*:audio/x-siren:*,http-get:*:audio/x-spc:*,http-get:*:audio/x-speex:*,http-get:*:audio/x-stm:*,http-get:*:audio/x-svx:*,http-get:*:audio/x-tta:*,http-get:*:audio/x-unaligned-raw:*,http-get:*:audio/x-vgm:*,http-get:*:audio/x-voc:*,http-get:*:audio/x-vorbis:*,http-get:*:audio/x-w64:*,http-get:*:audio/x-wav:*,http-get:*:audio/x-wavpack:*,http-get:*:audio/x-wavpack-correction:*,http-get:*:audio/x-wma:*,http-get:*:audio/x-xi:*,http-get:*:audio/x-xm:*,http-get:*:closedcaption/x-cea-608:*,http-get:*:closedcaption/x-cea-708:*,http-get:*:image/bmp:*,http-get:*:image/jp2:*,http-get:*:image/jpeg:*,http-get:*:image/png:*,http-get:*:image/svg:*,http-get:*:image/svg+xml:*,http-get:*:image/tiff:*,http-get:*:image/vnd.wap.wbmp:*,http-get:*:image/webp:*,http-get:*:image/x-MS-bmp:*,http-get:*:image/x-bitmap:*,http-get:*:image/x-bmp:*,http-get:*:image/x-cmu-raster:*,http-get:*:image/x-exr:*,http-get:*:image/x-icon:*,http-get:*:image/x-j2c:*,http-get:*:image/x-jpc:*,http-get:*:image/x-pcx:*,http-get:*:image/x-pixmap:*,http-get:*:image/x-portable-anymap:*,http-get:*:image/x-portable-bitmap:*,http-get:*:image/x-portable-graymap:*,http-get:*:image/x-portable-pixmap:*,http-get:*:image/x-sun-raster:*,http-get:*:image/x-tga:*,http-get:*:meta/x-klv:*,http-get:*:multipart/x-mixed-replace:*,http-get:*:raw/x-pcap:*,http-get:*:subpicture/x-dvb:*,http-get:*:subpicture/x-dvd:*,http-get:*:subpicture/x-pgs:*,http-get:*:subtitle/x-kate:*,http-get:*:text/plain:*,http-get:*:text/x-cmml:*,http-get:*:text/x-raw:*,http-get:*:video/mj2:*,http-get:*:video/mpeg:*,http-get:*:video/mpegts:*,http-get:*:video/ogg:*,http-get:*:video/quicktime:*,http-get:*:video/webm:*,http-get:*:video/x-av1:*,http-get:*:video/x-bayer:*,http-get:*:video/x-cdxa:*,http-get:*:video/x-cineform:*,http-get:*:video/x-daala:*,http-get:*:video/x-dirac:*,http-get:*:video/x-divx:*,http-get:*:video/x-dnxhd:*,http-get:*:video/x-dv:*,http-get:*:video/x-flash-screen:*,http-get:*:video/x-flash-video:*,http-get:*:video/x-fli:*,http-get:*:video/x-flv:*,http-get:*:video/x-fwht:*,http-get:*:video/x-h261:*,http-get:*:video/x-h263:*,http-get:*:video/x-h264:*,http-get:*:video/x-h265:*,http-get:*:video/x-huffyuv:*,http-get:*:video/x-ivf:*,http-get:*:video/x-jpeg:*,http-get:*:video/x-matroska:*,http-get:*:video/x-matroska-3d:*,http-get:*:video/x-mp4-part:*,http-get:*:video/x-ms-asf:*,http-get:*:video/x-msmpeg:*,http-get:*:video/x-msvideo:*,http-get:*:video/x-pn-realvideo:*,http-get:*:video/x-prores:*,http-get:*:video/x-pwc1:*,http-get:*:video/x-pwc2:*,http-get:*:video/x-qt-part:*,http-get:*:video/x-raw:*,http-get:*:video/x-smoke:*,http-get:*:video/x-sonix:*,http-get:*:video/x-svq:*,http-get:*:video/x-theora:*,http-get:*:video/x-unaligned-raw:*,http-get:*:video/x-vmnc:*,http-get:*:video/x-vp6-alpha:*,http-get:*:video/x-vp6-flash:*,http-get:*:video/x-vp8:*,http-get:*:video/x-vp9:*,http-get:*:video/x-wmv:*</Sink>\r\n</u:GetProtocolInfoResponse>\r\n</s:Body> </s:Envelope>'

This does not lead to the device appearing in pavucontrol to be selectable as sink.

After these four cycles, pulseaudio-dlna returns to discovering devices:

05-01 18:48:13 pulseaudio_dlna.discover                       INFO     SSDPDiscover.search()

What is interesting here, is that the three endpoints that drop their connection, are equally accessible with curl:

$ curl -I http://10.10.10.200:49494/upnp/rendertransportSCPD.xml
HTTP/1.1 200 OK
CONTENT-LENGTH: 15697
Accept-Ranges: bytes
CONTENT-TYPE: text/xml
DATE: Sat, 01 May 2021 16:54:35 GMT
LAST-MODIFIED: Thu, 01 Jan 1970 00:00:00 GMT
SERVER: Linux/5.4.0-1034-raspi, UPnP/1.0, Portable SDK for UPnP devices/1.8.4
X-User-Agent: redsonic
CONNECTION: close

$ curl -I http://10.10.10.200:49494/upnp/renderconnmgrSCPD.xml
HTTP/1.1 200 OK
CONTENT-LENGTH: 4783
Accept-Ranges: bytes
CONTENT-TYPE: text/xml
DATE: Sat, 01 May 2021 16:54:46 GMT
LAST-MODIFIED: Thu, 01 Jan 1970 00:00:00 GMT
SERVER: Linux/5.4.0-1034-raspi, UPnP/1.0, Portable SDK for UPnP devices/1.8.4
X-User-Agent: redsonic
CONNECTION: close

$ curl -I http://10.10.10.200:49494/upnp/rendercontrolSCPD.xml  
HTTP/1.1 200 OK
CONTENT-LENGTH: 13317
Accept-Ranges: bytes
CONTENT-TYPE: text/xml
DATE: Sat, 01 May 2021 16:54:51 GMT
LAST-MODIFIED: Thu, 01 Jan 1970 00:00:00 GMT
SERVER: Linux/5.4.0-1034-raspi, UPnP/1.0, Portable SDK for UPnP devices/1.8.4
X-User-Agent: redsonic
CONNECTION: close

and that description.xml is retrieved successfully multiple times.

The DLNA media renderer is a Raspberry Pi 4 on Ubuntu 20.04 with a self-compiled gmrender-resurrect.

@almereyda
Copy link

We have a response from upstream about:

When running pulseaudio-dlna there is also 100% CPU usage on pipewire-pulse and journald

that reads as follows:

seems to fail gracefully with master. It tries to load module-dbus-protocol, which is not implemented.

Seems we're getting there, eventually.

@pizzadude
Copy link

pizzadude commented May 2, 2021

As a temporary alternative (for chromecast), mkchromecast works with pipewire. I only got it to work with python3.8 tho.

https://github.com/muammar/mkchromecast

@Cygn
Copy link

Cygn commented Jun 10, 2021

In the meantime, to switch back to regular pulseaudio in fedora 34:

dnf swap --allowerasing pipewire-pulseaudio pulseaudio

@liferooter
Copy link
Author

In the meantime, to switch back to regular pulseaudio in fedora 34:

dnf swap --allowerasing pipewire-pulseaudio pulseaudio

I know, thank you

@j1warren
Copy link

what's the current status?

@Cygn
Copy link

Cygn commented May 30, 2022

Cygn#41

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants