Announcement

Collapse
No announcement yet.

How to record BBC Radio streams from BBC I-Player for mp3 players Improved speed

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    #31
    Re: How to record BBC Radio streams from BBC I-Player for mp3 players Improved speed

    I've learned a bit about bash-scripting and returned to this old problem again coming with a script I found very useful: I called it bbc7rec.sh and it needs one parameter
    calling it with e.g.
    Code:
    bbc7rec.sh monday_2000
    will record whatever had been presented at that time at bbc7 into an mp3 file that is named according to the name of that "clip" and that one holds the name like it is presented in the schedule of bbc of that day.

    Code:
    #!/bin/bash
    
    if [ $# -lt 1 ]; then
    	echo sorry, but one parameter must be given
    	echo call ./bbc7rec.sh weekday_time
    	echo The filename will be extracted from the information given by the BBC
    	exit 
    fi
    
    TIME=$1
    mplayer -cache 2048 -bandwidth 9999999 "rtsp://rmv8.bbc.net.uk:554/bbc7coyopa/bbc7_-_$TIME.ra" -vc null -vo null -ao pcm:fast:waveheader:file=bbcFileTMP.wav|grep name: |sed "s/ name: //" |sed "s/[ |'|.]/_/g">bbcFileName.tmp
    RESFILE=`cat bbcFileName.tmp|awk '{print $1}'`
    echo "Now the mp3 file $RESFILE.mp3 will be generated"
    lame -b 160 bbcFileTMP.wav $RESFILE.mp3
    
    rm bbcFileName.tmp
    rm bbcFileTMP.wav
    Known Bugs:
    - I am not located in UK, so you must change the "rtsp..." prefix according to your needs
    - bbc7 may be changed accordingly,
    - I used lame with 160 bit - enough for every speech based programme, but you might change it for songs
    - it is a bit silent during the mplayer ripping - you simply must wait...

    hope someone will like it as I do

    cheers
    ragosti

    Comment

    Working...
    X