PDA

View Full Version : Streaming Last.FM, Pandora etc. to XBMC using VLC (on Windows)


Verso
2007-07-23, 22:56
I've read a lot of articles about streaming Last.FM, Pandora etc. to XBMC. Most of them are vague, links are broken, info is outdated, etc. etc. So I thought I'd post how to do it here. Maybe someone will find this information useful.

What this does and what it doesn't do:


Allows you to stream whatever is going through your sound card to XBMC over your LAN, including Last.FM.
Useful only for listening to Last.FM remotely, not for controlling Last.FM in any way.
Does not involve recording the stream.
Does not allow you to view track or artist info in XBMC.
Does not allow you to skip tracks, fast forward, rewind, etc.


VLC, or VideoLAN, is a free cross-platform (Windows, Mac OS X, Linux) media player that can also act as a streaming server. It is available from here: http://www.videolan.org/


Here is what you (minimally) need to do:


Start VLC

Select File...Open Network Stream...

Go to the DirectShow tab.

Set "Video device name" to None.

Hit Refresh next to "Audio device name" and then select your sound card from the list.

Check the Stream/Save box and hit Settings.

Change the settings as follows.

Under "Outputs", check "http" and enter the local IP address of the server, i.e., the machine that will be doing the streaming. (We'll use 10.100.100.100 in this example.). Leave the port as is, i.e., 1234.

Set "Encapsulation method" to Ogg.

Check "Audio codec" under "Transcoding options" and set it to MP3, 256 kbps, 2 channels.

Hit OK twice and VLC should launch and start streaming whatever is coming out of your sound card.



In XBMC, you'll need to manually receive the stream. Here's how:


On your computer, create a text file called "VideoLAN.strm". (N.B., the extension has to be .strm, not .txt or anything else. Windows users beware if your system hides the extension from view.). This file has to contain a single line:
http://10.100.100.100:1234
(In other words, the text file has to reference the IP address and port of the streaming server on the LAN, as specified in step 8, above.)

On your XBOX, copy this text file to XBMC/UserData/playlists/music. (Alternatively, you could keep the text file in a shared folder on your network and access it via Samba from the XBOX, but personally, I prefer to have the file in my playlists directory.)

Open this file in XBMC. It will take maybe 30 seconds to cache the stream before you hear anything.



Other notes:


I seem to get better results when I set the volume in VLC to 50%.

Windows users: I actually run VLC from a shortcut on my desktop using the following command line (which also sets the volume to 50%):
"C:\Program Files\VideoLAN\VLC\vlc.exe" dshow:// :dshow-vdev="none" :dshow-adev="Realtek AC97 Audio" :dshow-size="" :sout=#transcode{acodec=mp3,ab=256,channels=2}:dup licate{dst=std{access=http,mux=ogg,dst=10.100.100. 100:1234}} --volume 128
(Obviously, you will have to edit this command to match your system. Change the program path, IP address and audio card name as required. You can get the name of your audio card by following the directions above for starting VLC manually.)

I have only been able to get this to work using Ogg encapsulation and MP3 audio encoding. Others have reported success using other methods, but I haven't been able to duplicate that success.

VideoLAN (VLC) is a very powerful player/streamer. You can stream unsupported audio/video codecs to XBMC using it. However, these applications are beyond the scope of this how-to.

Bigfoot87
2007-07-29, 02:36
Thanks for the tutorial! I'm gonna use it in combination with a microphone. :grin:

QuickJolt
2007-08-21, 15:21
ok hopefully the answer slaps me in the face right after this but there is no "DirectShow" tab in linux. Let me give you a list of the tabs available "File, Disc, Network, Video4Linux, PVR, DVB" Thank you for your tutorial now im going to blindly test settings out and hop for the best ill let you know what happens. I am using Kubuntu(KDE) if that matters at all and its version 0.8.6

Verso
2007-09-16, 08:41
Hmm, good point. DirectShow is for Windows machines, obviously. I don't have a Linux machine here so I can't test anything myself. It'd be good to hear whether you got it working, though.

stacked
2008-08-08, 05:22
It works! Great tutorial thanks! :grin:

rwparris2
2008-08-08, 08:10
last.fm is already integrated quiet nicely into xbmc :) http://xbmc.org/wiki/?title=LastFM

good tut though. You may want to ask for ninja status and update this page http://xbmc.org/wiki/?title=HOW-TO:_Stream_video_using_VLC_(VideoLAN-Client) in the wiki.


maybe we can get pandora going as a plugin? idk because its all flash... I'll look at it and see if I can figure anything out ???

kemik
2008-10-28, 14:44
I've setup LastFM on my XBMC so entered the username/password. Which is correct as when I go into the Music section I can see my fav artists, etc

However, if I choose to play anything I get no sound :sad:

Shoutcast works btw

scheu001
2008-11-26, 17:00
Anyone else out there using Orb to stream media? I can watch TV from my home PC's TV tuner, watch any movie or TV show I've recorded, and listen to all my MP3s from a Windows Mobile device (or any PC). I can even monitor a webcam attached to my PC. If I could somehow incorporate streaming a Pandora feed through Orb, my conquest of the galaxy would be nearly complete!