[mythtv-users] UK: Sky channel number fixer?

Mike Perkins mikep at randomtraveller.org.uk
Wed Dec 3 15:14:01 UTC 2008

Nick Morrott wrote:
> I'm really hoping to look at this over my Christmas break for the
> XMLTV lineups project. I've been saying I'm going to do this for a
> while, but through illness, finishing the house, and University, I've
> not yet gotten around to it.
> The intention is to interface the lineups project so that it will work
> with XMLTV grabbers, allowing TV platform lineups to be imported into
> end-user applications with up-to-date channel numbering. It should
> allow matching against existing scanned channels based on DVB
> name/service ID, analog channel number, and URL in the case of IPTV,
> and allow the importing of channel lists for providers such as Sky and
> Virgin where a user cannot 'scan' for channels but must manually
> configure them.
> For MythTV it is possible simple scripts which scrape a site
> (Wikipedia for example) for the current channel lineup and update the
> database with updated channel numbering. I'm hoping that the XMLTV
> lineups project can allow this to happen automagically whenever the
> grabber is run.
One of the things that always catches me out, probably because I don't do it 
often enough, is that I go through the process others have described of scanning 
and editing the Freeview channels, and then discover that when I run 
Mythfilldatabase for the first time that it's chewed everything up.

This is because tv_grab_uk_rt amongst others relies on a file <sourcename>.xmltv 
to determine which channels to process. This text file *has* to be in step with 
information in the channels table. If it is not, i.e. because you have edited 
the channels table, random extra channels get created - which then results in 
another cycle of editing and deleting.

Since each line of <sourcename>.xmltv is a simple 'channel <xmltvid>' statement, 
it would be possible to have this file generated automatically as a temporary 
every time mfdb runs, using the data from the channels table. This would ensure 
that the grabber always pulls exactly the information required, and would take 
out the possibility of channel mismatch (at least in that respect).

I did look a long time ago about proposing (and coding) such a patch to the mfdb 
code, but (i) I got ill and (ii) my distro upgraded to 0.21, so I don't 
currently have any sources, and it never happened. But from what I remember the 
changes required would all be in one source file, and not very complex. Any 
possibility you could have a look, Nick?


Mike Perkins

More information about the mythtv-users mailing list