Script to record internet radio
Posted: 19 Feb 2010 18:19
My first "project" with vlc was to create a script that can be started at a particular time of the day to record a radio show (talk radio). Finding the right syntax was a little tricky, so I thought I would post my results for anyone looking for such an application. VLC will record for 176 seconds before exiting.
Code: Select all
#/bin/bash
date=`date +"%a_%b_%I%M"`
newFile=radio_$date
ext=m4a
rm -f $newFile.$ext
/c/Program\ Files/VideoLAN/VLC/vlc.exe \
'mms://citadelcc-wjr-am.wm.llnwd.net/citadelcc_wjr_am' \
-I no_gui \
--run-time=176 \
vlc://quit \
--sout='#'transcode'{'acodec=mp4a,ab=128,channels=2,samplerate=44100'}':duplicate'{'dst=std'{'access=file,mux=mp4,dst=C:/A_Mike/vlc_record/$newFile.$ext'}}'