[mythtv] Patch to accept remote buttons as logical identifiers

Daniel Kristjansson danielk at cuymedia.net
Thu Aug 24 14:45:12 UTC 2006

On Thu, 2006-08-24 at 15:12 +0100, Stuart Morgan wrote:
> On Thursday 24 August 2006 14:22, Petr Stehlik wrote:
> > My myth-users-like comment to #2239: I believe that this is the right
> > way of defining remote buttons and I hope it will get accepted sooner
> > than later. If there was a voting system to trac items (:-) I'd vote for
> > this one.
> I certainly plan on adding something like this to 0.21.
> I've yet to review Navaho Gunleg's current patches. They'll either be used as 
> they currently stand, or they may be adapted.

I don't think direct remote button to action mappings
are a good idea. MythTV redefines the meaning of keyboard
keys depending on the context for a good reason. Look
at teletext for an example, while in the "Teletext Menu"
context we remap F7 to TOGGLEBACKGROUND, when we are
in the the "ITV Menu" context this is mapped to MENUTEXT,
and when we are in the "TV Playback" context F7 is
mapped to SIGNALMON. If there were a direct mapping
from the remote keys to action, each one of actions
would require it's own key on the remote.

Consider also the color keys on a Hauppauge remote,
if I were in a teletext country I would map these
to F2-F5 for teletext, and also map F2-F5 to other
actions when not in teletext. I could use the
red button for DELETE, the green for ADJUSTSTRETCH,
blue for CUSTOMEDIT, and yellow for CLEAROSD.

Now it is possible to create a separate hierarchy for
remote mappings to action based on the context, but
this requires a lot of code duplication. It makes
more sense to me to create a remote configuration
plugin or to extend mythcontrols to make programming
remotes simpler. For example, you could create an
interface that displays a picture of the remote and
allows you to change the mapping of each remote key
to a keyboard key, and also allows you to change the
mapping of that keyboard key to actions in the various

-- Daniel

More information about the mythtv-dev mailing list