Skip to main content
Topic: Stream ALAC, M4A , MP3 over network with RAOP to Airplay device (Read 234 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

Stream ALAC, M4A , MP3 over network with RAOP to Airplay device

My project
Migrating my 500GB music, most lossless from Mac to Artix Linux.

Initial situation
  • had used iTunes with many formats, prefers ALAC, M4A, MP3
  • stream music with RAOP over network to an Airport Express 1
  • connect the digital optical output to high quality da-converter and this to my amplifier

Now this works for me on Linux. Streaming to Airplay Speaker we can release with pulseaudio. For music player I prefer Rhythmbox with codecs from gstreamer.

Important
It only works with AirPlay 1 –  RAOP1 devices (as of feb 2020). For many newer devices we need raop2. You can use for example the Apple Airport Express first Generation. It looks like an MacBook  power adapter and costs used less than 20 $. Unfortunately we need mac, windows or iOS to configure the Airport Express – but it is a really cheap network music receiver. It has an optical output in the center of the audio plug. There are adapters to normal toslink.

Step by step
Use a root shell. Open terminal:
Code: [Select]
su
[give your password]
The row now starts with: #

Install Codecs and RhythmBox
Code: [Select]
pacman -S gstreamer gst-gst-plugins-bad gst-plugins-base gst-plugins-good gst-plugins-ugly libav
pacman -S rhythmbox
Now start Rhythmbox and add music files. Test it, if it plays correct using your intern sound.

Install pulseaudio with network support
Code: [Select]
pacman -S pulseaudio pulseaudio-zeroconf libcanberra-pulse libpulse paprefs pavucontrol libao

Edit file /etc/pulse/default.pa and append this row to enable raop Support:
Code: [Select]
load-module module-raop-discover

Activate avahi
To discover airplay devices on the local network, you need to activate  avahi. Here the commands for OpenRC:
Code: [Select]
rc-update add avahi-daemon default
If it's not installed, you need to install it as following:
Code: [Select]
pacman -S avahi avahi-openrc

Play music over network
1. Reboot system.
2. Start paprefs (as normal user, not root).
- Under "Network Access" choose "Make discoverable PulseAudio …" and "Make discoverable Apple AirTunes …"
- If you want stream simultan to several AirPlay devices same time enable it on "Simultaneous Output".
3. You need to choose your output device in pavucontrol . On my mate desktop I can also choose it on mate-volume-control.
4. Start Rhytmbox – and stream music to your airplay devices.

I'm a newbie. Hope nevertheless I can help someone. I hope, thats all. On my laptop it works with Artix Linux OpenRC and Mate Desktop. Please improve me, if there are errors.