masmu / pulseaudio-dlna Goto Github PK
View Code? Open in Web Editor NEWA lightweight streaming server which brings DLNA / UPNP and Chromecast support to PulseAudio and Linux
License: GNU General Public License v3.0
A lightweight streaming server which brings DLNA / UPNP and Chromecast support to PulseAudio and Linux
License: GNU General Public License v3.0
Hello !
Thank you for this work, it's very usefull (the systray support by queeup is awesome too) !
My request is about the flac encoder. When I launch the server with this options, it doesn't work.
This is what I see when the stream begin :
INFO:root:starting sending stream to "Server PreAmpli"
flac 1.3.0, Copyright (C) 2000-2009, 2011-2013 Josh Coalson & Xiph.Org Foundation
flac comes with ABSOLUTELY NO WARRANTY. This is free software, and you are welcome to redistribute it under certain conditions. Type `flac' for details.(No runtime statistics possible; please wait for encoding to finish...)
INFO:root:PulseWatcher.on_new_playback_stream "/org/pulseaudio/core1/playback_stream176"
INFO:root:PulseWatcher.on_playback_stream_removed "/org/pulseaudio/core1/playback_stream176"
(The part where the encoder is launched appears just once ;) ). The stream is closed just after it is opened ...
Is there something I set wrong ?
Used to work before all of the streaming/etc rework ... now it just doesn't
Hello,
i have installed pulseaudio-dlna, but when i start BubbleUPPnP and want to connect, i am not getting the server. But on my Laptop i get this:
https://gist.github.com/w3stley/2e8980f00cc3f80f01d9
Can you help?
After a fresh install, using a vm, following the instructions, I get the following when running pulseaudio-dlna:
Traceback (most recent call last):
File "/usr/bin/pulseaudio-dlna", line 9, in
load_entry_point('pulseaudio-dlna==0.3.1', 'console_scripts', 'pulseaudio-dlna')()
File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 351, in load_entry_point
return get_distribution(dist).load_entry_point(group, name)
File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 2363, in load_entry_point
return ep.load()
File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 2088, in load
entry = import(self.module_name, globals(),globals(), ['name'])
File "/usr/lib/python2.7/dist-packages/pulseaudio_dlna/main.py", line 40, in
import gobject
ImportError: No module named gobject
Google did not help, so what to do to fix this?
Thanks!
Roelof
PS: Is this a base to send a music stream to my dlna compliant receiver (as is possible with media player in Windows). So no player function on the receiver (that is exactly what I want to replace), only receiving.
Appreciate your feedback, thanks!
Hello,
I'm using pulseaudio-dlna to stream audio from Ubuntu 14.04 to BubbleUPnP on Android phone. Works great, except there is audio lag about 5-15 seconds between sound was produced and moment when it reaches phone. By using fast forward button in BubbleUPnP I was able to minize lag to about 2 seconds, but 2 seconds is still too much (I would like to watch movie on TV connected to Ubuntu via HDMI cable, but stream audio to the phone). Is it possible to reach almost realtime delay or this is DLNA limitation and lag always will present?
Hello,
First of all: This is a great piece of software. I installed it on my Ubuntu 12.10 and it works like a charm, but I ran into trouble on Lubuntu ARM. I get an DBUS error which is very bad vor me as the target machine was the Lubuntu ARM and the Ubuntu 12.10 was just for testing :)
What I have tried so far is:
"pacmd list-modules" brings up:
index: 23
name:
argument: <>
used: -1
load once: yes
properties:
module.author = "Tanu Kaskinen"
module.description = "D-Bus interface"
module.version = "4.0"
-next I ran your script which seems to find all my dlna renderer:
./pulseaudio_dlna.py -p 1234 --debug
result:
...
Failure: Module initialization failed
ERROR:root:PulseAudio seems not to be running or pulseaudio dbus module could not be loaded.
I also started in parallel the dbus-monitor wondering if something happens there, but no message was received. I have no idea where to search for the issue. Any hint to solve to problem would be great. Thanks in advance. I would really like to get it up an running on my odroid. This was the only solution on the internet so far which totally met my needs :)
best
freggel
Hi,
Could you add some signal handler to pulseaudio_dlna.py?
I want this because I am using your code on cinnamon autostart and I can't send KeyboardInterrupt. Thats why if I kill process "pulse.cleanup()" & "dlna_server.server_close()" not working.
Hi Masmu,
thanks for your awsome work that you have done! I'm looking for precisely the solution that you started to implement! Maybe the pulseaudio-guys see this and will add this, because it looks to me, that with Rygel this cannot be achieved.
I have been following this issue here: "cant stream to hamemusic soundrouter" and have installed the latest developer-version, including your updates 7 days ago.
I try to play a wav-file to exclude any conversion issues, that does work when played through other apps.
The paplay-command starts to play and the speaker-status-light start to flash, as would be normal for playback. However, no music will be heard. Terminating pulse-dlna during playback reverts output to the default device and I can hear on local speakers.
I have attached all the information that you wanted to look into the other thread. I hopy you are able to help me.
Thanks Mario
I open pavucontrol to select the audio device for the application (e.g. Spotify client). When I close pavucontrol the stream immediately stops and is not coming back when reopening pavucontrol.
Hi there,
I've setup a fedora copr repo at https://copr.fedoraproject.org/coprs/cygn/pulseaudio-dlna/
It's built on refactor branch so the current version is 3.4.
As a side note, I had to include notify2.py with the sources as it's not available in fedora, and encoders except vorbis are optional dependencies. I also had to hack setup.py a bit and add a MANIFEST.in to build the src.rpm correctly.
Thx for your work!
Hello,
thanks a lot for this lovely app.
The old version (0.3.x) worked very nicely between ubuntu and kodi. Since i accidentially installed 0.4.1 the connection to the dlna renderer is closed some seconds after i do switch to the renderer.
07-30 12:13:05 pulseaudio_dlna.streamserver INFO Requested streaming URL was: /musicbuero_dlna.wav (HTTP/1.1)
07-30 12:13:05 pulseaudio_dlna.streamserver INFO Got request from 192.168.123.132 - GET /musicbuero_dlna.wav HTTP/1.1,200,-
07-30 12:13:05 pulseaudio_dlna.streamserver INFO Client 192.168.123.132 registered to stream /musicbuero_dlna.wav.
07-30 12:13:05 pulseaudio_dlna.streamserver INFO Processes of /musicbuero_dlna.wav initialized ...
sox WARN wav: Length in output .wav header will be wrong since can't seek to fix it
07-30 12:13:05 pulseaudio_dlna.streamserver INFO Requested streaming URL was: /musicbuero_dlna.wav (HTTP/1.1)
07-30 12:13:05 pulseaudio_dlna.streamserver INFO Client 192.168.123.132 unregistered stream /musicbuero_dlna.wav using method 2.
07-30 12:13:05 pulseaudio_dlna.streamserver INFO Got request from 192.168.123.132 - GET /musicbuero_dlna.wav HTTP/1.1,200,-
07-30 12:13:05 pulseaudio_dlna.streamserver INFO Client 192.168.123.132 registered to stream /musicbuero_dlna.wav.
07-30 12:13:12 pulseaudio_dlna.streamserver INFO Client 192.168.123.132 unregistered stream /musicbuero_dlna.wav using method 2.
07-30 12:13:14 pulseaudio_dlna.streamserver INFO Stream closed. Cleaning up remaining processes ...
07-30 12:13:14 pulseaudio_dlna.pulseaudio INFO on_device_updated "/org/pulseaudio/core1/sink1"
07-30 12:13:15 pulseaudio_dlna.pulseaudio INFO The device "MusicBuero (DLNA)" was stopped.
C07-30 12:13:34 pulseaudio_dlna.pulseaudio INFO Remove "musicbuero_dlna" sink ...
Application is shutting down.
07-30 12:13:34 pulseaudio_dlna.pulseaudio INFO Remove "musicbuero_dlna" sink ...
07-30 12:13:34 pulseaudio_dlna.pulseaudio ERROR Could not remove entity 43
Just for your info. Old version still works very nicely.
It's very uncommon to provide sources for a specific package manager within the main project as there are many different package managers out there. It's a common way to have a separate project for the packaging stuff.
If I remember correctly all of the documentations/tutorials I've seen about debian packaging say something similar. All of them describe how to build a debian package for a soures.tar.gz.
I am using a Hame UPNP/DLNA soundrouter (http://hamedata.com/hamemusic/hamemusic-help.html) to stream sound over wifi to a regular stereo amp. The device works just fine with my droid smartphone and tablet, using the bubbleupnp app. To stream audio from my ubuntu 14.04 laptop your solution would be perfect.
The discovery of the soundrouter works as long as I connect my laptop to the hame wifi network with its own IP range and SSID. This is different from the android devices that discover the soundrouter even if they are connected to the regular home wifi network.
Hi Masmu,
Now upnp renderer:2, renderer:3 are not supported.
Only renderer:1 is supported, in fromURL method from UpnpMediaRendererFactory in renderer.py I've replaced l284 with :
if re.match(r"^urn:schemas-upnp-org:device:MediaRenderer:[1,2,3]$", device.devicetype.text) is None:
and tested with my rygel, gmrender renderers. All was fine.
Renderer of type 2, 3 are backward compatible in upnp, but it must be tested on some other renderers (I have only rygel and gmrender installed on some raspberry).
It would be helpful if there was the ability to create a group of speakers that appeared as one device rather than each target having to be a separate device. It would also be cool if you could assign the to channels ie; LF, RF, RR, LR, Center.
I was able to do this manually by joining sinks and assigning channels to each through pulse audio but it was difficult to do.
This is a feature request:
I was wondering if Pulseaudio-dlna will ever act as a DLNA Media Renderer,
The scenario is:
Laptop or desktop computer (Pulseaudio-dlna) connected to a HiFi set with a good pair of speakers.
You and all of your house guests can reproduce the music that you have on the phones. Super!
No more usb cables copying files back and forth!
Thank you for sharing
Hello!
First thank you very much for pulseaudio-dlna! It works great with BubbleUPNP on my Android device!
But when I try to use it with my Sonos speakers I get the following error:
ERROR:dbus.connection:Exception in handler for D-Bus signal:
Traceback (most recent call last):
File "/usr/lib/python2.7/site-packages/dbus/connection.py", line 230, in maybe_handle_message
self._handler(_args, *_kwargs)
File "/usr/local/src/pulseaudio-dlna-master/pulseaudio_dlna/pulseaudio.py", line 259, in on_device_updated
self._handle_sink_update(sink_path)
File "/usr/local/src/pulseaudio-dlna-master/pulseaudio_dlna/pulseaudio.py", line 294, in _handle_sink_update
if bridge.upnp_device.register() == 200:
File "/usr/local/src/pulseaudio-dlna-master/pulseaudio_dlna/upnp/renderer.py", line 253, in register
return UpnpMediaRenderer.register(self, self.stream_url)
File "/usr/local/src/pulseaudio-dlna-master/pulseaudio_dlna/upnp/renderer.py", line 141, in register
url = self._get_av_transport_url()
File "/usr/local/src/pulseaudio-dlna-master/pulseaudio_dlna/upnp/renderer.py", line 118, in _get_av_transport_url
return self._get_url(av_transport['control_url'])
TypeError: 'NoneType' object has no attribute 'getitem'
Technically streaming to Sonos should work as I am able to stream to my Sonos devices when using BubbleUPNP. Are there any debugging infos I could additionally send to help to get pulseaudio-dlna work with Sonos?
Thanks a lot
Alois
hi
I am using a Hame UPNP/DLNA soundrouter (http://hamedata.com/hamemusic/hamemusic-help.html) to stream sound over wifi to a regular stereo amp. The device works just fine with my droid smartphone and tablet, using the bubbleupnp app. To stream audio from my ubuntu 14.04 laptop your solution would be perfect. But I cant get it to stream the audio.
The discovery of the soundrouter works as long as I connect my laptop to the hame wifi network with its own IP range and SSID. This is different from the android devices that discover the soundrouter even if they are connected to the regular home wifi network.
So here is what I do for discovery and what I get in return in the terminal
bb@dell6410:~$ pulseaudio-dlna
Using localhost: 192.168.169.2:8080
INFO:urllib3.connectionpool:Starting new HTTP connection (1): 192.168.169.1
INFO:urllib3.connectionpool:Starting new HTTP connection (1): 192.168.169.1
INFO:urllib3.connectionpool:Starting new HTTP connection (1): 192.168.169.1
INFO:urllib3.connectionpool:Starting new HTTP connection (1): 192.168.169.1
INFO:root:Discovery complete.
INFO:root:Found devices:
INFO:root:You can now use your upnp devices!
INFO:root:PulseWatcher.on_device_updated "/org/pulseaudio/core1/sink1"
INFO:urllib3.connectionpool:Starting new HTTP connection (1): 192.168.169.1
192.168.169.1 - - [16/Apr/2015 22:31:08] "GET /hamemusic517a.stream HTTP/1.0" 200 -
INFO:root:starting sending stream to "HameMusic_517a"
INFO:root:"HameMusic_517a" registered.
INFO:urllib3.connectionpool:Starting new HTTP connection (1): 192.168.169.1
INFO:root:"HameMusic_517a" is playing.
INFO:root:stream closed. cleaning up remaining procecces
INFO:root:PulseWatcher.on_new_playback_stream "/org/pulseaudio/core1/playback_stream26"
INFO:root:PulseWatcher.on_playback_stream_removed "/org/pulseaudio/core1/playback_stream26"
INFO:root:PulseWatcher.on_new_playback_stream "/org/pulseaudio/core1/playback_stream27"
INFO:root:PulseWatcher.on_playback_stream_removed "/org/pulseaudio/core1/playback_stream27"
As soon as I start playing I get
INFO:root:"HameMusic_517a" is playing.
INFO:root:stream closed. cleaning up remaining procecces
In soundsettings the device is visible, running test sounds gives me the same results.
All help would be very much appreciated. In Linux I have some experience but not all that much.
Hi,
first let me say thank you for that really useful and simple to use piece of software! You've got a few Euros yesterday, because I was totally excited about it after having no success with rygel for months.
One question though:
We have a Majik DSM and two Phillips NP2900 in our network.
After installing your package yesterday everything worked like a charme.
Today the Majik DSM refused to play anything from its pulseaudio output device - no sound, although the device existed and pavucontrol clearly showed, that the music was playing.
After fiddling around a bit the solution was simply to switch the output in the playback section of pavucontrol to a different renderer and switch it back to the Majik DSM.
Is there anything you can send the Majik DSM (for example some kind of start signal), so that it will start playing without that manual back and forth switching?
Thx a lot!
Bye.
Michael.
I own two Sonos:3 and a Sonos:Amp, which run fine and can be used with other DLNA apps like BubbleUPNP. PulseAudio-DLNA 0.3.5 found those devices, but wasn't able to stream sound to them -- the players stayed quiet. Newer versions of PulseAudio-DLNA, like the current 0.4.4, don't find the boxes anymore. Currently I'm not at home, but i guess the output of "pulseaudio -debug" might be interesting. Do you need something else?
It would be great to have a 'continious stream' option so that if playbackstreams are destroyed it would not stop the device from playing.
Some music players without gapless playback with recreate playback stream for each track. This will make pulseaudio-dlna to issue stop to device and then play again, which is undesired
Rather than exiting the application it would be nicer to load the missing module-dbus-protocol
at runtime. This module was not loaded in a default Ubuntu installation. Therefore before running pulseaudio-dlna
a manual loading of this pulseaudio module or editing of default.pa
is always required.
This may not be wanted later when users may be able to install e.g. by a DEB package.
Loading of this missing module can be done with the following lines in pulseaudio.py
def _get_bus(self):
try:
server_address = self._get_bus_address()
return dbus.connection.Connection(server_address)
except dbus.exceptions.DBusException:
subprocess.Popen(['pactl','load-module','module-dbus-protocol'])
try:
server_address = self._get_bus_address()
return dbus.connection.Connection(server_address)
except dbus.exceptions.DBusException:
logging.error('PulseAudio seems not to be running ')
sys.exit(1)
When starting pulseaudio-dlna
, I get the following error:
Traceback (most recent call last):
File "bin/pulseaudio-dlna", line 9, in <module>
load_entry_point('pulseaudio-dlna==0.3.4', 'console_scripts', 'pulseaudio-dlna')()
File ".../masmu/pulseaudio-dlna/pulseaudio_dlna/__main__.py", line 160, in main
pulseaudio_dlna.startup()
File ".../masmu/pulseaudio-dlna/pulseaudio_dlna/__main__.py", line 121, in startup
print(upnp_device)
UnicodeEncodeError: 'ascii' codec can't encode character u'\xfc' in position 32: ordinal not in range(128)
Hi there, similar to #32 I have a problem with my Sangean DLNA client when I assign an audio output to it.
INFO:root:Found devices:
<CoinedUpnpMediaRenderer name="DDR-63+ 002261a8ce7e" short_name="ddr63002261a8ce7e" state="idle">
INFO:root:You can now use your upnp devices!
INFO:root:PulseWatcher.on_device_updated "/org/pulseaudio/core1/sink5"
ERROR:dbus.connection:Exception in handler for D-Bus signal:
Traceback (most recent call last):
File "/usr/lib/python2.7/site-packages/dbus/connection.py", line 230, in maybe_handle_message
self._handler(*args, **kwargs)
File "/usr/lib/python2.7/site-packages/pulseaudio_dlna/pulseaudio.py", line 259, in on_device_updated
self._handle_sink_update(sink_path)
File "/usr/lib/python2.7/site-packages/pulseaudio_dlna/pulseaudio.py", line 294, in _handle_sink_update
if bridge.upnp_device.register() == 200:
File "/usr/lib/python2.7/site-packages/pulseaudio_dlna/upnp/renderer.py", line 253, in register
return UpnpMediaRenderer.register(self, self.stream_url)
File "/usr/lib/python2.7/site-packages/pulseaudio_dlna/upnp/renderer.py", line 141, in register
url = self._get_av_transport_url()
File "/usr/lib/python2.7/site-packages/pulseaudio_dlna/upnp/renderer.py", line 118, in _get_av_transport_url
return self._get_url(av_transport['control_url'])
TypeError: 'NoneType' object has no attribute '__getitem__'
Hey,
thanks for this extension, works perfectly for me in general!
However, I am observing a problem I cannot explain. Assume I choose the dlna device as default sound device. When I start streaming music, delay is fine at about 2 seconds. The problem occurs if a new local sound source starts (i.e. new Playback in PulseAudio Volume Control). This is e.g. when a new sound application starts or each time skype pops up a notification, each time you switch to another desktop.... This also occurs if I change the volume (either application or sound device). At this time, there is distortion created in the stream, that I hear after about 2 seconds.
I want to describe what I mean by distortion. I would expect the two sources to be mixed and to be sent onto the stream. But this has two side-effects:
For me, this does not really seem to be a core problem of your pulseaudio-dlna. Instead, it seems to be related to pulseaudio that mixes in the new sound. However, if I playback on a local device everything sounds seamlessly. Could there be a problem on the interface between pulseaudio and the dlna playback device?
Btw, if I feed the stream directly from the music application only, there is no stuttering when another sound is played on a local device or when I change the volume.
Are you aware of this or can you even verify this behaviour?
Thanks,
Steffen
hello,
here is what i have when i try to start pulseaudio-dlna
$ python pulseaudio_dlna
Traceback (most recent call last):
File "/usr/lib/python3.4/runpy.py", line 170, in _run_module_as_main
"__main__", mod_spec)
File "/usr/lib/python3.4/runpy.py", line 85, in _run_code
exec(code, run_globals)
File "pulseaudio_dlna/__main__.py", line 52, in <module>
import pulseaudio_dlna
ImportError: No module named 'pulseaudio_dlna'
i cloned the repos and cd pulseaudio-dlna
i checked/installed all dependencies
i tried to chmod +x all .py scripts
i am not a python ninja
any idea ?
i would love to run pusleaudio-dlna on my arch lap-top (combined with a rpi Musicbox)
if i succeed, it would be a great oportunity for me to learn how to build an arch package.
Hello,
I prepared PKGBUILD for Archlinux, it can be found here https://aur.archlinux.org/packages/pulseaudio-dlna/
It would be convenient if README includes this link for Archlinux users.
To further ease usage let me suggest we use localhost IP if no IP was given as an option.
This can e.g. be done by changing code in pulseaudio_dlna.py as below:
+ import subprocess
- if not options['--host']:
- print('You must specify host address!')
- sys.exit(1)
- else:
- host = str(options['--host'])
- port = int(options['--port'])
+ port = int(options['--port'])
+ if options['--host']:
+ host = str(options['--host'])
+ else:
+ retcode = subprocess.Popen(['hostname', '-I'], stderr=subprocess.PIPE, stdout=subprocess.PIPE)
+ host = retcode.communicate()[0].decode().strip('\n')
+ print ('Using localhost: ' + host)
We can smoothly switch our output stream from any sink to any DLNA sink created by pulseaudio-dlna and back by using the Ubuntu indicator sound applet. This is awesome!
But this will not work as expected if there was no stream present at the time we started pulseaudio-dlna.
pacmd list-sinks
, and pulseaudio-dlna PulseWatcher recognizes switching sinks. But a newly started stream will not be directed to the DLNA sink. There is no pulseaudio sink-input.I could trace this down to parec
which, while running pulseaudio-dlna, will only be loaded when a stream was present. It will then stay loaded (even after the stream had disappeared) to send its stream to a DLNA sink selected as output device.
It may be that this is more an issue on the pulseaudio side but still it is confusing, and it would be very nice to be able to define the DLNA device as output sink before we start audio output.
To overcome this issue I was wondering if starting parec
with e.g. a dummy stream on selecting a DLNA sink if there was no active stream present could be a solution. Alternatively it would be cool to find another way to switch to a DLNA sink when there are not yet any streams ready.
Hi,
I have a use case in which I would like to watch a movie in the Kodi (on Raspberry pi, running Archlinux Arm) and wish to stream the sound into my phone, so potentially I will hook headphones into the phone and will be able to listen to the movie without interupting anyone else
So far I think we are lacking dependencies, can you make sense for me if your project could do such a thing? and whether you will be able to help me getting my use case working?
At the moment the application looks at the startup for UPnP devices. If it has found devices it will continue otherwise it stops. If the application runs and some of the UPnP devices are gone in the meantime the application won't recognize this.
This make it impossible to run this cool application as a daemon. Therefore it would be nice if you could add another option that enables a periodic polling for UPnP devices instead of the one time search. A second option for the polling interval would be nice as well.
Hi,
is it possible to have gapless playback with pulseaudio-dlna?
If I don't get gapless playback, is it the application or is it pulseaudio or is it pulseaudio-dlna?
Renderer is my Linn MajiK-DSM, which definitely is capable of gapless playback.
TIA.
Bye.
Michael.
I made systray application for pulseaudio_dlna. I just test it on Linuxmint with Cinnamon.
Stop menu item need signal-handler support for working proper.
After running https://github.com/masmu/pulseaudio-dlna
Results in something like
INFO:root:You can now use your upnp devices! DEBUG:root:setting stream url for Upstairs to "http://192.168.1.65:8080/upstairs.stream" DEBUG:root:setting stream url for Kodi (Tardis) to "http://192.168.1.65:8080/koditardis.stream" DEBUG:root:setting stream url for Livingroom to "http://192.168.1.65:8080/livingroom.stream" Failure: Module initialization failed ERROR:root:PulseAudio seems not to be running or pulseaudio dbus module could not be loaded.pacmd list-modules | grep dbus
name:
Has this issue been seen ?
Thanks
Hi,
I'm starting pulseaudio-dlna using NetworkManager dispatcher : https://wiki.archlinux.org/index.php/NetworkManager#Network_services_with_NetworkManager_dispatcher
when connection is up / down it executes scripts in a given directory.
In order to connect to existing dbus session I launch pulseaudio-dlna with such commands (in a bash script):
pid=`pidof pulseaudio`
user=`ps -p $pid -o user=`
export `strings /proc/$pid/environ | grep DBUS_SESSION_BUS_ADDRESS`
sudo -E -u $user pulseaudio-dlna --debug
I get some errors :
pa_context_connect() has failed: Connection refused
It cannot connect to dbus session daemon. When I execute same script from a terminal pulseaudio-dlna starts gently.
I found some interesting posts about connection from root to user dbus session :
http://lists.freedesktop.org/archives/dbus/2010-May/012766.html
I checked uid and DBUS_SESSION_BUS_ADDRESS was correctly set when some pactl subrpocesses are spawn but it does not help.
Have I missed something? Have you got some suggestions?
lah
Hi! Not sure if this is a PulseAudio issue or it spplies to pulseaudio-dlna. When I attempt to play to the Libratone speaker at the office, pulseaudio-dlna throws an error but pavucontrol seems to indicate that it's playing. I hear nothing but silence though.
Output:
INFO:urllib3.connectionpool:Starting new HTTP connection (1): 192.168.0.65
INFO:root:found upnp_device ""
INFO:urllib3.connectionpool:Starting new HTTP connection (1): 192.168.0.65
ERROR:root:"Libratone 083100" registering failed!
INFO:urllib3.connectionpool:Starting new HTTP connection (1): 192.168.0.65
ERROR:root:"Libratone 083100" playing failed!
apt-add-repository ppa:qos/pulseaudio-dlna
You are about to add the following PPA to your system:
A small DLNA server which brings DLNA / UPNP support to PulseAudio and Linux.
It can stream your current PulseAudio playback to different UPNP devices (UPNP Media Renderers) in your network. It's main goals are: easy to use, no configuration hassle, no big dependencies.
https://github.com/masmu/pulseaudio-dlna
More info: https://launchpad.net/~qos/+archive/ubuntu/pulseaudio-dlna
Press [ENTER] to continue or ctrl-c to cancel adding it
Traceback (most recent call last):
File "/usr/bin/apt-add-repository", line 160, in
sp = SoftwareProperties(options=options)
File "/usr/lib/python2.7/dist-packages/softwareproperties/SoftwareProperties.py", line 96, in init
self.reload_sourceslist()
File "/usr/lib/python2.7/dist-packages/softwareproperties/SoftwareProperties.py", line 584, in reload_sourceslist
self.distro.get_sources(self.sourceslist)
File "/usr/lib/python2.7/dist-packages/aptsources/distro.py", line 87, in get_sources
raise NoDistroTemplateException("Error: could not find a "
aptsources.distro.NoDistroTemplateException: Error: could not find a distribution template
On your screenshot I see "Nexus 5" as a device. I haven't managed to make this work.
What are you using for this? BubbleUPnP? How is it set up?
With the possibility to give a single renderer URL we are able to connect to a single known DLNA renderer in our network.
It would be nice to then automatically move the audio stream to this device once we had started pulseaudio-dlna.
Hi,
is it possible to get a switch for this new behaviour:
"If a device stops playing, the streams currently playing on the corresponding sink are switched back to the default sink"
Using version 4.1 with my Majik DSM every so often for no apparent reason output is switched back to my hardware sound card. It is possible then to directly switch back to padlna, but if you are not sitting near your computer, this behaviour ist really annoying.
Thx and bye.
Michael.
Hey,
I tried to connect to an Onkyo TXNR509 reciever and get to following traceback.
System: Uptodate Archlinux, Kernel 4.1.5-1-ARCH
Build: aur-build
Thx for your help. :-)
Hi,
first, thanks for this fine extension!
I got the following error after starting the program width pulseaudio-dln --debug at discovering my devices.
My system: 3.18.3-031803-generic, Ubuntu 14.04.3 LTS
Does anyone have an idea how to fix this?
This was working perfectly with my AirMusic box up until commit
15e51f1
Since then it is not recognised at all. My Chromecast is recognised. There have been some pretty major changes since then, not sure what's broken it for me. I'm on Ubuntu Gnome 15.04.
Thanks
When I'm running pulseaudio-dlna and have my Sangean set to network player mode I encounter the following error twice:
Exception happened during processing of request from ('192.168.178.32', 52591)
Traceback (most recent call last):
File "/usr/lib/python2.7/SocketServer.py", line 599, in process_request_thread
self.finish_request(request, client_address)
File "/usr/lib/python2.7/SocketServer.py", line 334, in finish_request
self.RequestHandlerClass(request, client_address, self)
File "/usr/lib/python2.7/SocketServer.py", line 655, in init
self.handle()
File "/usr/lib/python2.7/site-packages/pulseaudio_dlna/listener.py", line 36, in handle
self.server.renderers_holder.process_notify_request(packet)
File "/usr/lib/python2.7/site-packages/pulseaudio_dlna/renderers.py", line 119, in process_notify_request
self._add_renderer_with_filter_check(device_id, device)
File "/usr/lib/python2.7/site-packages/pulseaudio_dlna/renderers.py", line 67, in _add_renderer_with_filter_check
self._add_renderer(device_id, device)
File "/usr/lib/python2.7/site-packages/pulseaudio_dlna/renderers.py", line 73, in _add_renderer
device.activate()
File "/usr/lib/python2.7/site-packages/pulseaudio_dlna/plugins/upnp/renderer.py", line 156, in activate
self.get_protocol_info()
File "/usr/lib/python2.7/site-packages/pulseaudio_dlna/plugins/upnp/renderer.py", line 250, in get_protocol_info
http_get, w1, mime_type, w2 = sink.strip().split(':')
ValueError: need more than 1 value to unpack
System info:
Linux version 3.18.20-1-MANJARO (builduser@manjaro) (gcc version 5.2.0 (GCC) )
pulseaudio-dlna 0.4.3-1 from AUR
I have a Raspberry Pi with Raspbian, with BubbleUPNP installed.
And when i try to connect. i get these errors:
pulseaudio-dlna
Using localhost: 192.168.1.30:8080
INFO:urllib3.connectionpool:Starting new HTTP connection (1): 192.168.1.44
INFO:root:found upnp_device ""
INFO:root:Discovery complete. You can now use your upnp devices!
Fehlgeschlagen: Modulinitialisierung fehlgeschlagen
Traceback (most recent call last):
File "/usr/bin/pulseaudio-dlna", line 9, in
load_entry_point('pulseaudio-dlna==0.3.1', 'console_scripts', 'pulseaudio-dlna')()
File "/usr/lib/python2.7/dist-packages/pulseaudio_dlna/main.py", line 147, in main
pulseaudio_dlna.startup()
File "/usr/lib/python2.7/dist-packages/pulseaudio_dlna/main.py", line 128, in startup
self.pulse.set_upnp_devices(upnp_devices)
File "/usr/lib/python2.7/dist-packages/pulseaudio_dlna/pulseaudio.py", line 242, in set_upnp_devices
self._ensure_bridge(upnp_device)
File "/usr/lib/python2.7/dist-packages/pulseaudio_dlna/pulseaudio.py", line 247, in _ensure_bridge
upnp_device.short_name, upnp_device.name)
File "/usr/lib/python2.7/dist-packages/pulseaudio_dlna/pulseaudio.py", line 121, in create_null_sink
entity_id = int(subprocess.check_output(cmd))
File "/usr/lib/python2.7/subprocess.py", line 573, in check_output
raise CalledProcessError(retcode, cmd, output=output)
subprocess.CalledProcessError: Command '[u'pactl', u'load-module', u'module-null-sink', u'sink_name=""', u'sink_properties=device.description=""']' returned non-zero exit status 1
Feature Request:
create an option to select multiple encoders.
Maybe something like this is appropriate:
--encoders wav,flac
It would be cool to set also the order. When I start pa-dlna without --encoder parameter every possible encoder is activated, but I want a selection out of that. The order would define the sequence of audio formats for streaming.
With "--encoders wav,flac,mp3" for example only the encoder wav, flac, and mp3 would be activated and wav is preferred over flac and flac over mp3.
Thanks for "pulseaudio-dlna", it is generally very usefull.
I was using "pulseaudio-dlna" on a Linux Mint 17.2 Cinnamon 64-bit computer to push the sound on my HiFi music player Sony:CMT-SBT300W. It worked fine with the 3.5 version.
After an update to 4.3 version, "pulseaudio-dlna" terminates with this message (whether the musicplayer is connected or not) :
"pulseaudio dlna.application ERROR The SSDP listener could not bind to the port 1900/UDP. Perhaps this is already in use? Application terminates"
I am back to 3.5 and it works again.
When starting to stream to a sink I get an exception
ERROR:dbus.connection:Exception in handler for D-Bus signal:
Traceback (most recent call last):
File "/usr/lib/python2.7/dist-packages/pulseaudio_dlna/upnp/renderer.py", line 113, in _get_av_transport_url
return self._get_url(av_transport['control_url'])
TypeError: 'NoneType' object has no attribute '__getitem__'
Looking at my server ( rygel ) it doesn't have any service with
urn:schemas-upnp-org:service:AVTransport:1 but with urn:schemas-upnp-org:service:AVTransport:2
so I tried change it and it worked.
I don't have a clue what that number means so without that knowledge I propose to change render.py accordingly:
def _get_av_transport(self):
for service in self.services:
if service['service_type'].startswith(
'urn:schemas-upnp-org:service:AVTransport:'):
return service
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.