Finally figured out the audio streaming although the latency is still too long:
VLC is able to stream and play the audio from the radio over a network. It is open source and very powerful. It is available from http://www.videolan.org/vlc/. One glitch in the install is that the binary .rpms apparently require a bunch of failed dependencies. The better way to install is to "yum install videolan-client". The windows VLC install is uneventful. In order to stream audio data over the network three components are needed: 1. a fifo to write the raw audio data to 2. an mp3 encoder to compress the data stream 3. an audio server to stream the data over the network The first requirement is easily created with the command mkfifo. This creates a zero sized fifo file that will delay file reads when empty so that two programs can be linked and paced just using the fifo properties The second requirement is provided by lame, an open source mp3 encoder. Lame as installed by default with the fedora core 3 setup. The final requirement is the audio server provided by VLC. The following steps allow me to stream my USRP am radio across the network with a 24 kbps mp3 bitrate. The load on the CPU and network are pretty negligible. The one drawback is that there is a substantial latency introduced. 1. Create the input and output fifos a. mkfifo testfifo b. mkfifo testfifo.mp3 2. Start the mp3 encoder(it will block until input data is available) a. lame -m mono -f -r -x -s 16000 testfifo testfifo.mp3 A note on the options: -m is for a mono audio stream, -f is for fast encoding(less quality), -r for raw input data, -x to byte swap the input, and -s 16000 sets the input sample rate 3. Start the am radio(it will block if lame isn't running yet) a. usrp_am_radio_gui.py -s 680 -f testfifo 4. Start the VLC server a. Run vlc: vlc & b. Select File -> Wizard c. Check "Stream to Network", hit next d. Click "Choose…" and select file mode with testfifo.mp3 as the file, hit next e. Select HTTP stream mode f. Hit next for remaining panels The VLC server should be running now which can be confirmed by selecting View-> Stream and Media info from the menu. A 24 kbps stream of a 16000 Hz sample rate should be shown. 5. Listen to the audio a. On the client machine run VLC b. Select File->Open network stream c. Select HTTP and enter the IP address and port number of the server (e.g. 192.168.15.101:8080) d. Press play Should be hearing the audio on the client machine at this point. If its not working, go back and try to stream a recorded .mp3 file to verify that the network is fine, i.e. no firewalls in the way. -Clark ----- Original Message ----- From: "Clark Pope-TWC" <[EMAIL PROTECTED]> To: <[email protected]> Sent: Sunday, July 24, 2005 9:54 AM Subject: vlc stream from gnu radio > Has anybody successfully streamed audio from the gnuradio to another machine > using VLC? I can stream files I've recorded from gnuradio but not the actual > live stream. > > Thanks, > Clark > _______________________________________________ Discuss-gnuradio mailing list [email protected] http://lists.gnu.org/mailman/listinfo/discuss-gnuradio
