[mythtv] Input switching question

Daniel Kristjansson danielk at cuymedia.net
Wed Feb 15 19:20:34 UTC 2006

On Tue, 2006-02-14 at 00:34 -0500, Jerry Rubinow wrote:
> If I wanted to prevent myth from switching to an input that was
> connected to the same external tuner that was in use by another input,
> would the MainServer::Handle...() functions related to free recorders
> be a workable place to put code for this?  Does all the tuner
> switching code go through there?
> For example, if I had a firewire input for HD channels, and an PVR
> input for svideo from the same cable box for non-HD channels, I'd want
> both inputs to look like they were busy if either one was being
> recorded from, since both depend on the same cable box tuner.
> I realize that I also need to put in checks, probably in schedule.cpp,
> to prevent a show being scheduled on both connected inputs as well. 
> But as a first step, I'm thinking the first change should prevent
> channel changes in live tv from ruining in-progress recordings on the
> other input.
> Anything else I need to take into account?

I think the scheduler might be the biggest difficulty, though David
Engel or Bruce Markley may disagree. You need to introduce into it
the concept that two inputs can conflict even if they are on separate

On the TVRec side (for LiveTV) I think you just need to remove that
particular input from the available inputs while a recording is in
progress on the conflicting input. For the Firewire recorder that
would mean it is "busy" when the PVR-x50 is using the shared input,
while for the PVR-x50 it just means one of the multiple inputs is
not available. If there are other connected inputs on the PVR-x50,
then they can still be used for LiveTV while the Firewire recorder
is recording.

I'll leave the passing of the information about in-use inputs to
you. Make sure you consider that the Firewire recorder might be
on a different backend than the PVR-x50 (and someone might want
to use a different card than a PVR-x50), and multiple frontends
may be in watching LiveTV at once.

-- Daniel

More information about the mythtv-dev mailing list