[mythtv-users] Import XMLTV data from local file

David Watkins watkinshome at gmail.com
Mon Oct 19 09:59:10 UTC 2020


On Mon, 19 Oct 2020 at 09:15, Peter Carlsson <maillist.peter at home.se> wrote:

> Hello!
>
> I have been using http://xmltv.xmltv.se/channels.xml.gz and the
> tv_grab_se_swedb grabber for a long time and it has been working great.
>
> Unfortunately, they have decided to only provide data for 3 days instead
> of 14 days.
>
> I have written a script that fetch the information from web pages and
> generates the channels.xml.gz with all necessary information.
>
> I would now like to make mythfilldatabase use my local files to update
> MythTV with EPG data.
>
> Is there a special grabber that I should use in this case?
>
> Best regards,
> Peter Carlsson
> _______________________________________________
>
> I use Schedules Direct which is bundled with xmltv I believe.  It's a
subscription service which I kicked back at a bit initially but it's been a
good for the UK and it's a fairly small amount.  It seems to cover Sweden.

I went to it when the free Radio Times feed was discontinued in the UK.
Fairly easy to set up (run it with the config option) - and this is the
command I use to generate an xml EPG data file.

tv_grab_zz_sdjson --config-file ~/.xmltv/tv_grab_zz_sdjson.conf --output
~/sd_listing.xml 2>/dev/null

I generate one file containing all channels and then I run the following
for each source.

/usr/local/bin/mythfilldatabase --only-update-guide --file --sourceid n
--xmlfile ~/sd_listing.xml 2>/dev/null  (where n= source id)

I get missing channel errors for sources that don't have all channels
available but that doesn't seem to cause a problem.

The hardest thing is looking up the channel xmltvids.  If there's an easy
way please let me know.

The way I do it is to initially accept all channels in the config setup and
run the grabber.  Then scan through the generated file to look up the ids
for the channels you want to include.  All the channel data is at the start
of the file.

Then I have an excel spreadsheet and a mysql script to manually update the
database.

Finally you can run the xmltv config again and select just the channels you
want or manually edit the file to change = to != for those you don't want.


HTH
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mythtv.org/pipermail/mythtv-users/attachments/20201019/e133bcf2/attachment.htm>


More information about the mythtv-users mailing list