Streaming audio from Plasma to a Chromecast

Chromecast devices in the sound settings

This morning, while browsing the web, I wanted to listen to a Podcast from my laptop, and thought “Hey, can I stream this to our stereo?”. As it turns out, that’s rather easy to achieve, so I thought I’d share it here.
The media devices in our home are connected using Chromecasts, which are small dongles that allow playing media on them, meaning you can play for example a video from your phone on the projector in the living room: very convenient.

I didn’t know if that was easily achievable with audio from my Plasma/Linux laptop and a quick search turned up “pulseaudio-dlna” which adds Chromecast devices on the local networks as output devices.

On my KDE Neon laptop, it’s as easy as installing pulseaudio-dlna from the standard repositories and then starting “pulseaudio-dlna” from the commandline. Then, I can pick an output device from the panel popup and the audio stream changed to my stereo.

$ sudo apt install pulseaudio-dlna
$ sudo pulseaudio-dlna
Added the device "Stereo (Chromecast)".

3 thoughts on “Streaming audio from Plasma to a Chromecast

  1. Wow you sure have a lot of Chromecasts in your home :)
    Nice trick, going to try it out.

  2. How do you fix the latency? pulseaudio-dlna encodes pieces of the audio and sends them to be played on the DLNA renderer. The latency is the size of the blocks sent. By default these are independent mp3 blocks, so in addition to the latency there the choppyness between the fragments of audio.

    1. I can live with it, it’s just podcasts or music, I don’t use the laptop or desktop for watching movies. (For that, I just send the whole movie to the media player, VLC can do that, even.)

Comments are closed.