Mailing List archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[vdr] channels.conf for new BBC services




The BBC has brought online some new services, and now I can't even
pickup the old BBC channels from the Sandy Heath transmitter using a
Hauppauge Nova-T and VDR (with a DVB-S being used for output).

Hauppague's Windoz software scans and finds the new services and
indicates that many existing services have not changed frequency, so
no hardware problems.  Transferring the scanned channel info, etc,
over to channels.conf doesn't allow me to tune in to new or old
channels.  Similarly, dvbtune doesn't find any channel information
though it does detect that there is some signal present.  On the other
hand, ITV feeds are still working just fine.

i.e.
  dvbtune -f 641833000 -x -i -c1
to tune into a BBC feed indicates some signal but no channel info
where as
  dvbtune -f 665033000 -x -i -c1
gives me all the ITV channel info without any difficulty.

I'm using VDR version 1.0.4 and dvbtune version 0.3

Any hints?

- Simon

P.S. I wrote the following script to scanning for channels (still
can't find any BBC feeds!):

-----snip-----

#!/usr/bin/perl
# crude script to scan for channels
# Simon Moore, Oct 2002
# currently uses Nova-T card as second DVB card in system

use POSIX ":sys_wait_h";

$freqoffset=0.1666666666;

# scan channel range 22 to 68 with offsets
for($chan=22; $chan<=68; $chan++) {
    for($offset=-2; $offset<=3; $offset++) {
	$freq=int( ($chan*8+306+$offset*$freqoffset)*1000000 );
        print $chan;
	if($offset<-0.1) { print "-:"; }
	elsif($offset>0.1) { print "+:"; }
	else { print " :"; }
	print &chaninfo($freq),"\n";
    }
}

exit;


sub chaninfo
{
    local($freq)=$_[0];
    local(@res);
    local($i)=0;
    local($line);
    local($bitErrorRate)=-1;
    local($signalStrength)=-1;
    local(@services);
    local($tmp);
    local($tmp2);
    @res=&runWithTimeout("/home/swm11/LinuxDVB/dvbtune-0.3/dvbtune -f $freq -i -c 1",15);
    foreach $line (@res) {
	$line=~s/\n//g;
#	printf("%-3d: %s\n",$i,$line);
	$i++;
	if(index($line,"Bit error rate:")>=0) {
	    ($tmp,$bitErrorRate)=split(/: /,$line);
	}
	if(index($line,"Signal strength:")>=0) {
	    ($tmp,$signalStrength)=split(/: /,$line);
	}
	if(index($line,"service_name")>=0) {
	    ($tmp,$tmp2)=split(/service_name=\"/,$line);
	    ($services[$#services+1])=split(/\"/,$tmp2);
	}
	if(index($line,"KILLED")>0) {
	    $services[$#services+1]=$line;
	}
	if(index($line,"Device or resource busy")>0) {
	    $services[$#services+1]="Device or resource busy";
	}
    }
    return "$freq:$bitErrorRate:$signalStrength:".join(",",@services);
}



sub runWithTimeout
{
    local($command)=$_[0];
    local($timeout)=$_[1];
    local($tmpfile)="/tmp/swmscan.commandinfo";
    local($pid);
    local($i);
    local(@res);
    local($killed)="";

    open(FOUT,">$tmpfile") or die "Failed to write to $tmpfile";
    close(FOUT);
    $pid=fork();
    if($pid==0) {
	exec("$command > $tmpfile 2>&1");
	die;
    } else {
	for($i=0; ($i<$timeout) && (waitpid($pid,&WNOHANG)>=0); $i++) {
	    sleep(1);
	}
	$level=9;
	while(waitpid($pid,&WNOHANG)>=0) {
	    kill($level,$pid);
	    kill($level,$pid+1);  # hack to kill both shell and dvbtune
	    if($level<9) { $level++ };
	    sleep(1);
	    $killed="PROCESS $pid KILLED after $i seconds (timeout=$timeout)\n";
	}
    }
    open(FIN,"<$tmpfile") or die "Failed to read from $tmpfile";
    @res=<FIN>;
    close(FIN);
    if(length($killed)>0) {
	@res[$#res]=$killed;
    }
    return @res;
}


-----snip-----


-- 
Info:
To unsubscribe send a mail to listar@linuxtv.org with "unsubscribe vdr" as subject.



Home | Main Index | Thread Index