Hacking a Raspberry Pi into a wireless airplay speaker #piday #raspberrypi @Raspberry_Pi

Handy overview for how to fake airplay speakers using a Raspberry Pi. While the latest state of this project is probably better for an installation audio project than an ideal way to listen to your music, the leap from these instructions to one using an outboard USB DAC is not far — and I look forward to trying this out in my apartment!.

From Jordan Burgess:

I’ve had mine for a few months now but I hadn’t got around to using it yet. So I’ve now decided to try to make something that I’ve wanted for a while: a product to bring my good but dated speaker system into the 21st century by enabling wireless streaming of music to it.

A possible way to do this would be to buy an Airport Express or an Apple TV and connect the audio out to the stereo. But then I would feel like overpaying for features like video streaming or wireless routing that wouldn’t be used. Besides, those products cost around £80. Airplay enabled speakers cost £200 at the low end. This raspberry pi creation should easily come in under £30.

How to fake airplay compataility

To get a Raspberry Pi looking like an airplay receiver I made use of Shairport. This opensource software was created by James Laird after literally tearing open an airport express, dumping the ROM and reverse engineering out the private cryptographic key that airplay uses to identity of legitimate apple products. The github repo has the Perl source code that can be compiled for simple audio receiving only. For this project we essentially need to get this code running on a networked raspberry pi.

I’ll condense this down to the bare instructions for a working outcome. On the way here I had attempted many other ways to do it. I flirted with XBMC, creating a reasonably ok Apple TV-like system in the process.  But frequent crashes caused me to divert my attention to this simpler, audio-only solution.

As a word of warning, one of the common pitfalls I encountered was with the very narrow acceptable power range of the RPi. The computer is powered by usb cable and any additional loads such as a wifi adapter or a budget usb keyboard can strain this power supply past it’s limits. I had several instances of odd performance or non-responsiveness due to this….

Read more.


998Each Friday is PiDay here at Adafruit, be sure to check out our posts, tutorials and new Raspberry Pi related products. Have you tried the new “Adafruit Raspberry Pi Educational Linux Distro” ? It’s our tweaked distribution for teaching electronics using the Raspberry Pi. But wait, there’s more! Try our new Raspberry Pi WebIDE! The easiest way to learn programming on a Raspberry Pi.

Want a FREE RASPBERRY PI? All orders over $350 get a FREE Raspberry Pi Model B with 512MB RAM!

Adafruit publishes a wide range of writing and video content, including interviews and reporting on the maker market and the wider technology world. Our standards page is intended as a guide to best practices that Adafruit uses, as well as an outline of the ethical standards Adafruit aspires to. While Adafruit is not an independent journalistic institution, Adafruit strives to be a fair, informative, and positive voice within the community – check it out here: adafruit.com/editorialstandards

Join Adafruit on Mastodon

Adafruit is on Mastodon, join in! adafruit.com/mastodon

Stop breadboarding and soldering – start making immediately! Adafruit’s Circuit Playground is jam-packed with LEDs, sensors, buttons, alligator clip pads and more. Build projects with Circuit Playground in a few minutes with the drag-and-drop MakeCode programming site, learn computer science using the CS Discoveries class on code.org, jump into CircuitPython to learn Python and hardware together, TinyGO, or even use the Arduino IDE. Circuit Playground Express is the newest and best Circuit Playground board, with support for CircuitPython, MakeCode, and Arduino. It has a powerful processor, 10 NeoPixels, mini speaker, InfraRed receive and transmit, two buttons, a switch, 14 alligator clip pads, and lots of sensors: capacitive touch, IR proximity, temperature, light, motion and sound. A whole wide world of electronics and coding is waiting for you, and it fits in the palm of your hand.

Have an amazing project to share? The Electronics Show and Tell is every Wednesday at 7pm ET! To join, head over to YouTube and check out the show’s live chat – we’ll post the link there.

Join us every Wednesday night at 8pm ET for Ask an Engineer!

Join over 36,000+ makers on Adafruit’s Discord channels and be part of the community! http://adafru.it/discord

CircuitPython – The easiest way to program microcontrollers – CircuitPython.org

Maker Business — “Packaging” chips in the US

Wearables — Enclosures help fight body humidity in costumes

Electronics — Transformers: More than meets the eye!

Python for Microcontrollers — Python on Microcontrollers Newsletter: Silicon Labs introduces CircuitPython support, and more! #CircuitPython #Python #micropython @ThePSF @Raspberry_Pi

Adafruit IoT Monthly — Guardian Robot, Weather-wise Umbrella Stand, and more!

Microsoft MakeCode — MakeCode Thank You!

EYE on NPI — Maxim’s Himalaya uSLIC Step-Down Power Module #EyeOnNPI @maximintegrated @digikey

New Products – Adafruit Industries – Makers, hackers, artists, designers and engineers! — #NewProds 7/19/23 Feat. Adafruit Matrix Portal S3 CircuitPython Powered Internet Display!

Get the only spam-free daily newsletter about wearables, running a "maker business", electronic tips and more! Subscribe at AdafruitDaily.com !

1 Comment

  1. "This opensource software was created by James Laird after literally tearing open an airport express, dumping the ROM and reverse engineering out the private cryptographic key that airplay uses to identity of legitimate apple products."

    This sounds scary. At the very least it sounds like it’s bordering on violating the DCMA. While I love DIY, and hacking things to make them do something they shouldn’t, I don’t think we should advocate breaking the law here.

    If it doesn’t violate and DCMA laws then I will get off my soap box. The reverse engineering part is particular scary since there is specific verbiage in the act to criminalize reverse engineering of protected ip.

Sorry, the comment form is closed at this time.