JonathanSagnella wrote: ....................
I leave it on all day and when I come back I close get-iplayer and am left with a very long recording of all the days tv, which I can't convert without losing quality. Any tips for clean converting or better recording?
Here is my set-up-up for recording selected radio programs (Linux), firstly the crontab for timed recoding start:-
- Code: Select all
SHELL=/bin/sh
PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
# m h dom mon dow command
59 18 * * mon recrad.sh 2 Paul_Jones 3720
59 18 * * wed recrad.sh 2 Mike_Harding 3720
14 23 * * tue-thu recrad.sh 3 Late_Junction 6420
59 22 * * sat recrad.sh 2 Bob_Harris 10920
Note the three parameters passed to recrad.sh are
firstly the BBC radio channel, then the program name (for naming locally) and then the
program length (in seconds).
Now the recrad.sh shell script that calls get_iplayer :-
- Code: Select all
#Record BBC Radios 1-4 + World Service International
case "$1" in
"")
# set channel to Radio 4 if blank
dvb_channel="39"
get_stream="35"
channel_text="BBC_Radio_4_FM_"
;;
1)
# set channel to radio 1
dvb_channel="36"
get_stream="32"
channel_text="BBC_Radio_1_live_"
;;
2)
# set channel to radio 2
dvb_channel="37"
get_stream="33"
channel_text="BBC_Radio_2_live_"
;;
3)
# set channel to radio 3
dvb_channel="38"
get_stream="34"
channel_text="BBC_Radio_3_live_"
;;
4)
# set channel to radio 4
dvb_channel="39"
get_stream="35"
channel_text="BBC_Radio_4_FM_"
;;
w)
# set channel to world service international
dvb_channel="40"
get_stream="56"
channel_text="BBC_World_Service_Intl_live_"
;;
*)
echo "usage: recrad.sh [1|2|3|4|w -(radio channel)] [program_name] [program length in seconds]" >&2
exit 8
;;
esac
case "$2" in
"")
# set program to ad_hoc if blank
program="ad_hoc"
;;
*)
# set program to value of $2 if non-blank
program="$2"
;;
esac
case "$3" in
"")
# set program_length to 1 hour 2 mins if blank
program_length="3720"
;;
*)
#set program_length to value of $3 if non-blank
program_length="$3"
;;
esac
mkdir $HOME/radio/$program/ >/dev/null 2>&1
echo "recording "$channel_text" into "$HOME/radio/$program" for "$program_length" seconds"
#Try tuner first
if dvbstream -n $program_length -f 714166670 0 4$dvb_channel >$HOME/Desktop/$channel_text-$program-from-tuner-report_`date +%Y-%m-%d@%H-%M-%S`.txt 2>&1 -o >$HOME/radio/$program/$channel_text`date +%Y-%m-%d_%H%M%S`.mpeg
then exit 0
else
#Use internet if tuner fails
if get_iplayer 801$get_stream --get --preset=liveradio --outputliveradio=$HOME/radio/$program/ --stop=$program_length >$HOME/Desktop/$channel_text-$program-from-internet-report_`date +%Y-%m-%d@%H-%M-%S`.txt 2>&1
then exit 2
fi
exit 4
fi
Note that the script tries my tuner first and then tries the internet.
The above is easily adaptable for TV.