Mailing List archive

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

[linux-dvb] Re: ANN: scripts for updating channels.conf



Radovan Garabik wrote:
> http://kassiopeia.juls.savba.sk/~garabik/satscripts/

Below is a patch to make it work better for Astra 19.2E
(filter out Astra digital Radio / non-MPEG2).

Regards,
Johannes


--- ch2szap.py.orig	2003-12-18 17:11:49.000000000 +0100
+++ ch2szap.py	2003-12-18 17:16:15.000000000 +0100
@@ -1,10 +1,11 @@
 #!/usr/bin/python
-# convert SATCODX's files (such as http://www.satcodx1.com/_data/013.txt)
+# convert SATCODX's files (such as http://www.satcodx1.com/_data/0130.txt or
+# http://www.satcodx2.com/_data/0192.txt)
 # into (stdout) channels.conf format  suitable for szap
 #
 # radios are prefixed with R-
 #
-# usage: ch2szap.py 013.txt > channels.conf
+# usage: ch2szap.py 0130.txt > channels.conf
 
 
 import sys
@@ -18,6 +19,7 @@
     freq = freq.replace('.','')
     pol = fields[3].lower()
     chname = fields[4]
+    mode = fields[6]
     sr = fields[9]
     fec = fields[10]
     vpid = fields[11]
@@ -27,6 +29,9 @@
     
     if typ in ('TV-DIG-FTA', 'R-DIG-FTA'):
 	if typ=='R-DIG-FTA':
+            # skip "astra digital radio" which is not mpeg2
+            if mode == 'ADR_':
+                continue
 	    chname = 'R-'+chname
 	print "%s:%s:%s:%s:%s:%s:%s:%s:%s" % (
 	    chname, freq, pol, '0', sr, vpid, apid, nid, sid


-- 
Info:
To unsubscribe send a mail to ecartis@linuxtv.org with "unsubscribe linux-dvb" as subject.



Home | Main Index | Thread Index