Stream music to your Airport Express with Ruby!

Posted by Aaron Patterson on June 14, 2007

I just released raop-client which lets you stream music to your Airport Express with ruby.

Just install the gem:

gem install raop-client

Here is a sample program which takes decoded input from stdin:

require 'raop-client'

raop = Net::RAOP::Client.new(ARGV[0])
raop.connect
raop.play $stdin
raop.disconnect

Just use the program like this:

% lame --decode -q some_song.mp3 - | ruby streamer.rb 192.168.1.173

You'll have to supply your own mp3 and Airport Express IP address. Also, raop-client currently doesn't decode music, so you'll have to decode the music yourself.

Trackbacks

Use this link to trackback from your own site.

Comments

Leave a response

Comments

Check Spelling
Activate Spell Check while Typing