chris319
Joined: 05 Oct 2008 Posts: 2
|
Posted: Sun Oct 05, 2008 2:21 am Post subject: Beginner's Tutorial -- Icecast + Simplecast |
|
|
Yet another beginner's tutorial.
Here is a step-by-step account of how I got streaming audio to work using Icecast and Simplecast under Windows Vista. Hopefully it will simplify the process and get you up and running for those new to these programs. I followed these steps to stream audio from my laptop to my desktop computer over my local area network. I have yet to stream out to the Internet.
This procedure worked for me. Corrections are welcome. Moderator, feel free to make this post or a corrected version sticky.
- You will need two computers connected by means of a TCP/IP network (the usual Ethernet LAN). One computer will act as the server or "transmitter", and the other will act as the client or "receiver".
- You will need a streaming media player. Winamp works well for this purpose. Install Winamp on the client (receiver) computer AND on the server (transmitter) computer.
- Download and install Simplecast and the Windows version of Icecast on the server (transmitter) computer.
- Launch Icecast. Clicking on the Configuration -> Edit configuration menu opens the icecast.xml file with Notepad. There is not much to see here except to note that the default password is "hackme" (without the quotation marks). There are three places the password appears in this file: source-password, relay-password and admin-password. For now we will leave the password alone but you know where to change it if you wish to. Don't forget to save this file if you change anything. Otherwise, exit Notepad.
- Launch Simplecast. Here is where the action is. First we will set up the audio encoder. Click the Encoders button and a second window will open. At this point no encoders are selected. Click on the "+" sign and a requester will appear listing the available encoders. Personally, I found the Ogg encoder not to be very reliable in several respects and I felt the audio quality lacking. I have had much better results with the MP# and mp3PRO encoder. Click the radio button beside this entry and click OK.
- Configure your encoder. There will now be a one-line entry for the selected encoder in the Encoders window. Double-click this entry and a configurator will appear. Select the appropriate parameters. I have had good luck in monaural with 40 kb/s. 22.1 kHz. It sounds OK on voice and music, and the 40 kb/s means it should work on both dial-up and cable/DSL connections. It is not pristine audiophile quality, but if you want that and want to expend the bandwidth you can select higher-quality settings. I set the quality to High.
- Configure the server. Click the Server Details tab. You can leave everything alone here except to change the password to the Icecast default password "hackme". Also click the Icecast radio button at the top under Server Type. Also note the entry under Mount. It should say "/live" (without the quotation marks). This will be appended to the URL you enter to receive your netcase, and note server port number of 8000 (this is a commonly-used IP port for Shoutcast).
- Click the Stream Archive tab and uncheck "Save stream to file" unless you want to do just that. Click OK to exit the configurator.
- On the Simplecast main window click the Config button. We will come back to General Options later. For now go to Event Adaptors, select HTTP as the metadata adaptor and enter 8000 as the HTTP Adaptor port. Click OK to exit this configurator.
- Now the fun begins. The idea is to get audio routed into Simplecast. You would think this would be straightforward but it is actually tricky business
due to the diversity of audio hardware, mixers, drivers, etc. Every setup is a little different. The basic idea is to see activity on the Simplecast audio
level meters. Play any audio using Winamp and set Winamp to loop your playback because this could take a while. If you have a Sound Blaster card the process SHOULD be simple. Under Config->General options->Capture sound from device select "What U Hear" if present. As far as other configurations, you're left to your own ingenuity to get those meters moving on Simplecast. On my Macbook which dual boots Windows Vista I used a short loopback cable with 1/8" mini plugs on each end to route the headphone output into the line input. I set Speakers as the default playback device and Line In as the default recording device, then judiciously set the levels of the speakers and Line In. In Simplecast I then selected Line In under the Capture Sound From Device setting. Keep fiddling with it until you see the audio being played by Winamp appear on the level meters of Simplecast. NOTE: If you think you're going to get fancy and loop digital SPDIF into itself as I did using an optical cable,
forget it. It won't work unless your computer has a special chip which provides the clock pulses required for it to both send and recieve SPDIF. If you try this and find that the audio quality is garbage, that is the likely
reason.
- Next we will poke a hole in Windows Firewall so the sound can escape. Go to Settings->Control Panel and double click Windows Firewall. Of course you have the firewall running, so click on Change Settings and the Windows Firewall Settings configurator will appear. Click the Exceptions tab and wait a second. Click the Add Port... button toward the bottom. Under Name enter Port 8000 or any other name you wish. In Port Number enter 8000 and select TCP as the protocol. Click OK and make sure Port 8000 or whatever name you selected appears in the list of exceptions and that its box is checked. Click OK and close the firewall and control panel windows.
- We're not done yet. It's time to discover the IP address of the server (transmitter) computer on the local network. Open a Command Prompt (DOS box) which I believe is under Programs->Accessories (I have moved mine so I forget where it originally was). At the prompt type "ipconfig" (omitting the quotation marks). Look under Ethernet Adapter Local Area Connection. The third line, which on my computer says "IPv4 Address", contains the address we are after. It should be a series of four numbers separated by periods and (usually) beginning with 192.168. Copy this address down as it will be entered into the client's (receiver's) copy of Winamp.
- You should now be ready to go. On Icecast click Start Server. On Simplecast open the Encoders window and click the right-pointing arrow to start the encoder. If there are no errors the word "Encoding" should appear under Status. Start audio playback on Winamp.
- On the client or "receiver" machine, start Winamp and press control-L. This brings up a box into which you will enter the URL of the server/transmitter using the previously-obtained IP address of the server. If that address were 192.168.0.2, for example, you would enter the following into the URL box:
http://192.168.0.2:8000/live
The server's IP address goes between the double slashes and the colon. Between the colon and the single slash goes the port number, which we have set to 8000. The /live part tells the server we are looking for the live audio stream. After some buffering by Winamp you should hear audio on the client/receiver machine.
Wasn't that simple? |
|