]> git.ipfire.org Git - people/teissler/ipfire-2.x.git/blob - config/vdr/bin/runvdr
New Astra 19.2 Channellist, moved vdr config to /opt/vdr/etc
[people/teissler/ipfire-2.x.git] / config / vdr / bin / runvdr
1 #!/bin/sh
2
3 # runvdr: Loads the DVB driver and runs VDR
4 #
5 # If VDR exits abnormally, the driver will be reloaded
6 # and VDR restarted.
7 #
8 # Any command line parameters will be passed on to the
9 # actual 'vdr' program.
10 #
11
12 VDRPRG="./bin/vdr"
13 VDRCMD="$VDRPRG -w 60 -c /opt/vdr/etc -Pstreamdev-server $*"
14
15 KILL="killall -q -TERM"
16
17 mkdir -p /var/video
18 cd /opt/vdr
19 while (true) do
20 #
21 # If you have stability Problems at tuning or similar
22 # unload and reload the dvb-modules here ...
23 # Example is for Hauppauge Nexus 2.0
24 #
25 # rmmod dvb_ttpci
26 # rmmod stv0299
27 # rmmod dvb_core
28 # modprobe dvb_ttpci
29 #
30 sleep 1
31 eval "$VDRCMD"
32 if test $? -eq 0 -o $? -eq 2; then exit; fi
33 $KILL $VDRPRG
34 sleep 10
35 echo "`date` restarting VDR"
36 done