Stream music to your Airport Express with Ruby!

Posted by – 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
[/sourcecode]

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
[/sourcecode]

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.

0 Comments on Stream music to your Airport Express with Ruby!

Respond

Respond

Comments

Comments