[mythtv] Re: [mythtv-commits] Re: Ticket #339: Simplify Tuning
process
Daniel Kristjansson
danielk at cuymedia.net
Thu Sep 22 21:26:13 UTC 2005
On Thu, 2005-09-22 at 09:12 -0400, Isaac Richards wrote:
> On Thursday 22 September 2005 02:21 am, Daniel Kristjansson wrote:
> Yeah, stuff like IsCardType. I don't think that's any different than old
> comparison. If anything, it's less obvious since I had to go check
> IsCardType to see if it was doing anything non-obvious.
consider it gone :)
> > Some of the functions, like in the whole TuningState thing, are
> > for debugging purposes only. Basically they make it easy for me
> > to add a verbose macro to print out the value when it is examined
> > or changed. I'm planning to collapse TuningState into TVRec when
> > I'm further along. I don't need half those variables except for
> > preliminary debugging.
> >
> > TVRec is in a rough state right now.
> Yeah, just making sure now so it's ok later on, since I'm going to be in there
> for other stuff soon. =)
Sure, I guess I should have expected someone to look at that code when
I posted it. A lot of that stuff like the "WAIT_FOR_STATE" macro is
pure cruft, it just makes it easy for me to test new stuff like
triggered waits.
> > I didn't like them much when I first saw Jacob using them in his code,
> > but it is almost impossible to figure out what is going wrong with
> > multiple recorders without some kind marker indicating which recorder
> > is spitting out which info. In this case I made it spit out the
> > cardid.
> Yeah, but that could be added in a different way, though that doesn't use
> custom macros for every different file.
How about something like VERBOSE(VB_IMPORTANT, TVREC "Error message");
The second would prepend something like "TVRec("<<cardid<<")"<<
with a class specific macro, in this case "TVREC". This could also
be a separate verbose macro, something like:
LOCVERBOSE(VB_IMPORTANT, TVREC, "Error Message");
If I need add a verbose macro I'd also like to add: ENOVERBOSE
Which would standardize our errno error messages, by appending
the string from strerror_r(errno..).
> > The whole tuning in RunTV is just busy waiting at the moment, but
> > I'm planning to use things like the signals from the SignalMonitor
> > to trigger trips through HandleTuning().
> Excellent.
Yep, I think it might even get rid of the glitches you sometimes get
when a second recording begins while a first is in progress...
-- Daniel
More information about the mythtv-dev
mailing list