[mythtv-users] feedback for feature request: ability to define input connections as inactive

Joe Harvell jharvell+lists.mythtv-users at dogpad.net
Sun Mar 11 15:09:17 UTC 2007

R. G. Newbury wrote:
> ryan patterson wrote:
>> On 3/8/07, Joe Harvell <jharvell+lists.mythtv-users at dogpad.net> wrote:
>>> I recently filed a bug report (http://svn.mythtv.org/trac/ticket/3093)
>>> having to do with input connections with no video sources.  The bug is
>>> that the frontend crashes when you try to access the program guide if
>>> there are no input connections associated to video sources.  The
>>> response I got was that the frontend should not crash, but instead, the
>>> program guide should show nothing.  I argue that as long as you have
>>> channels defined you should be able to look in the program guide and
>>> make schedules.
>>> Another problem associated with input connections is that if you have a
>>> capture card defined, but none of that specific capture card's input
>>> connections is associated with a video source, the backend complains
>>> that init of that card failed.  Then later, the backend crashes if you
>>> look at "Tuner Status" from "System Status" in mythfrontend.  I think
>>> this is a big problem when you have a capture card whose inputs are all
>>> temporarily unusable (e.g., disconnected).  You have to delete the
>>> capture card and restart the backend if you don't want the scheduler to
>>> try to use it to make recordings.
>>> An easy way to address both above problems is to allow input connections
>>> to be put in an "inactive" state.  Inactive in this context means that
>>> they are not eligible for watching LiveTV or making recordings.  This
>>> inactive state is what you would put the input connections in when
>>> nothing is connected to them.  This can be implemented by adding a
>>> boolean column to table cardinput with a default value of TRUE.  It
>>> should not be allowed to assign active=TRUE and have no video source.
>>> Currently, you can't even define an input connection without assigning a
>>> video source to it.  Table cardinput does not get populated at all if
>>> you don't assign a video source.  Similarly, rows are deleted from
>>> cardinput if you delete the video source from them.  This means the
>>> system throws away all the configuration data associated with the input
>>> connection if you want to temporarily delete the association to the
>>> video source.  This would no longer be necessary if the active/inactive
>>> flag were there to tell you whether to use the input connection or not.
>>> The reason the program guide doesn't show anything if you have no card
>>> inputs with video sources is because the program guide needs to know
>>> which channels have video sources.  But it shouldn't matter whether they
>>> are currently usable (e.g. physically connected) to be able to look at
>>> the listings.  If we no longer make input connections existence
>>> dependent on their associated video sources, the system has all the data
>>> it needs to be able to build the program guide and make schedules.
>>> It seems like most of the code that would need to change would be
>>> limited to code specifically involved in selecting input connections for
>>> Live TV and making recordings.
>>> I would be willing to implement and test this.
>> I agree that a user should be able to define a capture card with no video
>> sources on its inputs without the backend crashing.  I had this problem
>> while I was trouble shooting my irblaster.  I didn't want MythTV to use 
>> that
>> capture card for recordings (yet) but I didn't want to have to redefine the
>> card every time I wanted to work on getting the irblaster working.
>> But I have to disagree with your idea that all defined channels should be
>> shown in the listing even if they are not assigned to a card's input.  That
>> sounds like a troubleshooting nightmare.  Plus why would I want to see a
>> listing for something I can't watch/record?
> I think it is a great idea. It will also mean that it is easy to define 
> and have independent systems using myth for viewing, where there are no 
> tuners attached. At present, I can't figure out how to do that on my 
> laptop, although its suppose to be possible.
> As to the channels being shown, I think it would be nice to be able to 
> use, for example, this machine, to see what is 'on' tonight, even if I 
> cannot record it *here*.
> And even on the same machine, you may want to see a listing to check if 
> a particular program is on when and where you think it is supposed to 
> be, even if you cannot *at this instant* record it. You may be testing 
> your antenna setup, and want to check if a program is on which uses your 
> HD3000 card. In which case, you can set the antenna inactive and 
> re-activate the QAM setup.
> Great idea.
> Can I help?
> Geoff
So the question is whether or how to display channels in the program 
guide whose video source is not associated with any active input.  Here 
are some options:

1. Allow Program Guide settings (per frontend config) to determine 
whether or not to display such channels.  The default could be "don't 
display", since that is how Myth currently behaves.
2. Display such channels, but in a format (color, font, etc.) indicating 
they are not available on any active input connection.
3. Always display them.

I think a combination of 1 and 2 is probably the best.  I don't like the 
idea of using a different color, because that is already being used for 
program category.


I'm an experienced software developer, but I've never looked at the Myth 
code.  So I don't yet have an idea of the amount of work for the feature 
I'm proposing.  Once I get enough feedback and suggestions, I can make a 
*detailed* functional description of the feature and some use cases.  At 
that point, I could probably use some help determining the amount of 
work required and what components of the software need to be changed.

More information about the mythtv-users mailing list