[mythtv-users] PVR250 and static buildup on cable input?

Dave Alden alden at math.ohio-state.edu
Sun Mar 21 13:01:26 EST 2004


Hi,

On Fri, Mar 19, 2004 at 07:44:52AM -1000, James L. Paul wrote:
> Yes, I tried it once many weeks ago, perhaps I misremember what I did. I'm 
> adding an experiment now to see if I can prevent the problem by adding to my 
> crontab:
> 
> 59 6 * * * /sbin/modprobe -r ivtv ; /sbin/modprobe ivtv
> 
> Thanks for the suggestion, I'll try anything and don't see how this is likely 
> to hurt. ;)

You might want to use the attached program (you'll need to modify it slightly
for the video device (I have 2, so you'll probably just need to remove one).
This script determines the input and frequency for each card, removes and
adds the ivtv module and resets the input and frequency.

...dave
-------------- next part --------------
#!/bin/sh
PATH=/usr/local/sbin:/sbin:$PATH

#
devices=( "/dev/video0" "/dev/video1" )

#
program=`basename $0`
i=0

#
for (( i=0 ; $i < ${#devices[*]} ; i++ ))
do
  input[$i]=`test_ioctl -o -d ${devices[$i]} | tail -1 | awk 'BEGIN {FS=" "}{print $3}'`
  frequency[$i]=`test_ioctl -q=0 -d ${devices[$i]} | tail -1 | awk 'BEGIN {FS=" "}{print $3}'`
done

rmmod ivtv 

if [ $? -ne 0 ]
then
  exit 1
fi

insmod ivtv > /tmp/$program.$$

if [ $? -ne 0 ]
then
  cat /tmp/$program.$$
  rm /tmp/$program.$$
  exit 1
fi

rm /tmp/$program.$$

for (( i=0 ; $i < ${#devices[*]} ; i++ ))
do
  test_ioctl -d ${devices[$i]} -p ${input[$i]} -r tuner=0,freq=${frequency[$i]} > /dev/null
done


More information about the mythtv-users mailing list