MagicPlay is an open cross-platform audio streaming standard (think “HTTP for music”) that supports synchronized streaming to multiple speakers (like Sonos). For more details, see this Verge story. In the near future you’ll be able to buy WiFi speakers, TVs and other products that come with MagicPlay support out of the box. If you want to try MagicPlay right now, you can turn an existing device such as the Raspberry Pi into a MagicPlay device and stream music to it using doubleTwist Music Player for Android.
- Raspberry Pi ($43) running Raspbian Linux
- Optional: USB sound card for better quality (the integrated sound card on the Raspberry Pi has an annoying crackle bug)
- Android phone or tablet running Android 4.1 or higher
If you would like to skip building the source code, you can download a binary package instead.
1. Download the AllJoyn source code (AllJoyn is a P2P framework developed by Qualcomm to power the Internet of Things).
2. Unzip the AllJoyn code: tar -zxvf alljoyn-3.3.0-src.tgz; cd alljoyn-3.3.0-src
3. Clone the following two repositories:
- git clone https://github.com/alljoyn/audio services/audio
- git clone https://github.com/alljoyn/about_config services/about_config
4. Apply this patch: zcat magicplayd.diff.gz | patch -p0
5. Build AllJoyn library: make OS=linux CPU=armhf VARIANT=release
6. Build and install audio service: cd services/audio; make CPU=armhf; sudo make CPU=armhf install
The MagicPlay service (/etc/init.d/magicplayd) has now been installed and will automatically start on boot.
Note that if you want to use a USB sound card with MagicPlay on the Raspberry Pi, you will need to modify services/audio/src/posix/ALSADevice.cc prior to step #7 and replace “plughw:0,0″ with “plughw:1,0″ and “hw:0″ with “hw:1″ (since the USB sound card would be sound card #2).