Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: MythTV: Dev

[Q]: how to hook a proprietary eit parser correctly

 

 

MythTV dev RSS feed   Index | Next | Previous | View Threaded


eallaud at yahoo

Jun 2, 2008, 6:57 PM

Post #1 of 5 (1214 views)
Permalink
[Q]: how to hook a proprietary eit parser correctly

Hi all,
a fast summary: I know how to decode a proprietary EPG for my Sat
provider (canal sat Caraibes, probably works for canal sat france
though I have no way to confirm this).
I would like to code a good parser for mythtv. I already read the code
quite a bit and here are the big questions I would like to get an
answer for to be sure I am properly following the way it has to be
coded.
First the EPG is sent on several PIDs (2 or 3 IIRC); then several
tables are needed (they have different table ids), some of which are
just given in one section, some are split between several section.
They do not follow the mpeg descriptors standards; eg the schedule
(that is title+some fields with duration, showings...) is setup this
way: length of the title+title+several bytes holding info on duration/
show times, then next schedule using the same format. So there is no
tag descriptor as in MPEG standard.
So my question: what should I do? From which classes should I derive
mines. For the short tables (only on section) isn't it easier to just
have a class for the table?
Moreover hiw everything is in place? Which class is responsible for
choosing the different PIDs and gathering the tables?
In brief any help will be much appreciated!
Thx
Bye
Manu

_______________________________________________
mythtv-dev mailing list
mythtv-dev [at] mythtv
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-dev


danielk at cuymedia

Jun 8, 2008, 3:03 AM

Post #2 of 5 (1070 views)
Permalink
Re: [Q]: how to hook a proprietary eit parser correctly [In reply to]

On Mon, 2008-06-02 at 21:57 -0400, manu wrote:
> So my question: what should I do? From which classes should I derive
> mines. For the short tables (only on section) isn't it easier to just
> have a class for the table?

If these are very similar to the DVB tables derive from those, otherwise
from the raw PSIPTable or even TSTable if it is always in a single TS
packet.

> Moreover hiw everything is in place? Which class is responsible for
> choosing the different PIDs and gathering the tables?
> In brief any help will be much appreciated!

The [MPEG|DVB|ATSC]StreamHandler classes are responsible for this,
except
during channel scanning when ScanStreamHandler handles this task (using
the DVB and ATSC stream handler classes.) If your provider essentially
provides a DVB service, inherit from the DVBStreamHandler if you need
to extend this. Otherwise the MPEGStreamHandler class. If it is only
one or two small extensions to DVB then implement it in DVBStreamHandler
so you don't need to change the tuning code in TVRec other than to
specify
the special EIT handling.

-- Daniel

_______________________________________________
mythtv-dev mailing list
mythtv-dev [at] mythtv
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-dev


eallaud at yahoo

Jun 12, 2008, 12:31 PM

Post #3 of 5 (1010 views)
Permalink
Re : [Q]: how to hook a proprietary eit parser correctly [In reply to]

Le 08.06.2008 06:03:16, Daniel Kristjansson a écrit :
> On Mon, 2008-06-02 at 21:57 -0400, manu wrote:
> > So my question: what should I do? From which classes should I
> derive
>
> > mines. For the short tables (only on section) isn't it easier to
> just
> > have a class for the table?
>
> If these are very similar to the DVB tables derive from those,
> otherwise
> from the raw PSIPTable or even TSTable if it is always in a single TS
> packet.

There is one table that is very long and then it is spread across
several section (with the same table ID obviously). If I understand
things correctly one PSIPTable contains only one section right?
Also how do I provide a method to "emit" the DB events to fill the
database. Moreover the summaries are in different tables than the
titles/showings, so is it possible to submit them later on?

Thx for your help,
Bye
Manu

_______________________________________________
mythtv-dev mailing list
mythtv-dev [at] mythtv
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-dev


danielk at cuymedia

Jun 13, 2008, 10:04 AM

Post #4 of 5 (1003 views)
Permalink
Re: Re : [Q]: how to hook a proprietary eit parser correctly [In reply to]

On Thu, 2008-06-12 at 15:31 -0400, manu wrote:
> Le 08.06.2008 06:03:16, Daniel Kristjansson a écrit :
> > On Mon, 2008-06-02 at 21:57 -0400, manu wrote:
> > > So my question: what should I do? From which classes should I
> > derive
> >
> > > mines. For the short tables (only on section) isn't it easier to
> > just
> > > have a class for the table?
> >
> > If these are very similar to the DVB tables derive from those,
> > otherwise
> > from the raw PSIPTable or even TSTable if it is always in a single TS
> > packet.
>
> There is one table that is very long and then it is spread across
> several section (with the same table ID obviously). If I understand
> things correctly one PSIPTable contains only one section right?

Yes

> Also how do I provide a method to "emit" the DB events to fill the
> database. Moreover the summaries are in different tables than the
> titles/showings, so is it possible to submit them later on?

The {ATSC,DVB}StreamData classes currently call EITHelper::AddEIT()
functions whenever they have a complete section assembled. But, if
you need to, you can wait until you have all the sections cached
before calling an AddEIT() function, there are conventions for caching
sections which you can see by looking at the ProgramMapTable handling.
"Table" is in fact a misnomer, each "Table" is in fact just a section,
but we have a pmt_cache in MPEGStreamData which contains all the
sections seen so far. The key for the table is program_number * 256 +
section_number, there is also a HasCachedAllPMT(program_number) function
which tells you if the entire table is cached, where each section
pointer maps to a "ProgramMapTable" type.

-- Daniel

_______________________________________________
mythtv-dev mailing list
mythtv-dev [at] mythtv
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-dev


eallaud at yahoo

Jun 13, 2008, 3:57 PM

Post #5 of 5 (984 views)
Permalink
Re : Re : [Q]: how to hook a proprietary eit parser correctly [In reply to]

Le 13.06.2008 13:04:52, Daniel Kristjansson a écrit :
> >
> > There is one table that is very long and then it is spread across
> > several section (with the same table ID obviously). If I understand
> > things correctly one PSIPTable contains only one section right?
>
> Yes
>
> > Also how do I provide a method to "emit" the DB events to fill the
> > database. Moreover the summaries are in different tables than the
> > titles/showings, so is it possible to submit them later on?
>
> The {ATSC,DVB}StreamData classes currently call EITHelper::AddEIT()
> functions whenever they have a complete section assembled. But, if
> you need to, you can wait until you have all the sections cached
> before calling an AddEIT() function, there are conventions for
> caching

OK I saw this function and I begin to see how I can do it, probably by
adding my special AddEIT as it is different enough that I cant reuse
what is already done for "normal" EIT.

> sections which you can see by looking at the ProgramMapTable
> handling.
> "Table" is in fact a misnomer, each "Table" is in fact just a
> section,
> but we have a pmt_cache in MPEGStreamData which contains all the
> sections seen so far. The key for the table is program_number * 256 +
> section_number, there is also a HasCachedAllPMT(program_number)
> function
> which tells you if the entire table is cached, where each section
> pointer maps to a "ProgramMapTable" type.

I can do it section by section. But as there are different tables for
the titles/times and the summaries, I would need to be able to submit
the title/showing times/duration and then later on the corresponding
summaries. Is that possible?
Thx for all your help.
I will try to open a ticket with some code, for review, ASAP.
Bye
Manu

_______________________________________________
mythtv-dev mailing list
mythtv-dev [at] mythtv
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-dev

MythTV dev RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.