[mythtv-users] DVB re-scan and XMLTV EPG?

Hika van den Hoven hikavdh at gmail.com
Thu Jan 29 03:18:53 UTC 2015


Hoi Michael,

Wednesday, January 28, 2015, 9:19:50 PM, you wrote:

> On 28/01/2015 11:07 PM, Alistair Grant wrote:
>> On Wed, Jan 28, 2015 at 10:40 AM, Simon Hobson <linux at thehobsons.co.uk> wrote:
>>> Philipp Hahn <pmhahn+mythtv at pmhahn.de> wrote:
>>>
>>>> I recently relocated and finally had to reset the DVB scan and channel
>>>> setup. I dreaded that moment, because in the past I always lost the
>>>> information about xmltv IDs and channel icons - This time I lost them
>>>> again, so I'd like to ask what I'm doing wrong or where I didn't grasp
>>>> a concept yet:
>>> Well MythTV doesn't know what these are when it does a channel scan - that's something you have to supply later. I just wrote a SQL script that rearranges my channels and fills in the missing data - so I can just "delete all channels -> scan -> run script" and have my channels back as they were. I just have to update the script from time to time as the channels available change.
>>> http://www.mythtv.org/wiki/Database_editing_script
>>>
>>> Put another way, Myth doesn't link channels, icons, or guide sources - that's the job of the user and/or external programs. From following this list, it would appear that some of the guide sources will automatically update the channels if properly configured.
>> What do people think of having a script that will read in the
>> tv_grab_xxx file, (typically /home/user/.mythtv/tv_grab.xmltv, I
>> think), scan the database and produce a human friendly configuration
>> file that links channel number, callsign and xmltvid and updates the
>> database using one of the supported APIs?  I'd make this a two step
>> process allowing the configuration file to be manually reviewed.
>>
>> This would deal with most of the concerns listed above, i.e. fear of
>> re-scanning, dealing with SQL and unsupported interfaces, etc.
>>
>> I'm thinking out loud here, so would welcome feedback.
>>
>> Thanks,
>> Alistair
> This is how the "shepherd" grabber that we use in Australia handles it,
> although I am pretty sure it accesses the DB directly (hence frowned 
> upon by the developers).  It can also search/download the channel Icon
> files for most channels/stations/sub channels.

> _______________________________________________

I've been thinking a bit about this thing. As you might have seen I am
currently developing on the Dutch XMLTV grabber.

There are several identifiers for a channel. Of which several in
essence are free for the user to choose/define. What such a script
should do is save the linking between the three identifiers BEFORE you
delete the old lineup and then afterwards restore on the basis of the
saved info. So you need a two step script. (three if you include the
scan)

You have
- chanid    Internal MythTV identifier, which you on first setup are
            free to choose and which links to all kind of other
            tables.
- sourceid  The MythTV internal ID of the source of your EPG-data
            (confusingly called video-source)
- xmltvid   EPG-id defined by the XMLTV grabber/EPG-source.
- channum   Is the identifier from your provider/cable company, but I
            think only relevant during a scan and afterwards free to
            choose/change. Unless you use Schedules Direct, where it
            doubles as EPG-id.

- callsign  Is I think the naming of the channel by your provider/cable
            company, but again I think in essence free to choose/change
            afterwards.
- name      Is your name of choice

- freqid    On analog the frequency in kHz or the channel-number
- mplexid   and
- serviceid The identifiers of the actual digital channel
- iptvid    The identifier of an iptv channel

What the script needs to do is to relink chanid, xmltvid, name and
maybe sourceid back to the found channels as identified by channum. A
problem comes if your provider changes channums, so you always will
need a personal check afterwards.

Tot mails,
  Hika                            mailto:hikavdh at gmail.com

"Zonder hoop kun je niet leven
Zonder leven is er geen hoop
Het eeuwige dilemma
Zeker als je hoop moet vernietigen om te kunnen overleven!"

De lerende Mens



More information about the mythtv-users mailing list