[mythtv-users] MythTV Raspberry Pi2 - GPIO IR - Multiple Key-presses from remote control
Kingsley Turner
krt at krt.com.au
Wed Jan 13 22:26:41 UTC 2016
On 14/01/16 06:46, Alec Leamas wrote:
> On 13/01/16 20:06, Kingsley Turner wrote:
>> On 13/01/16 14:22, Larry Kennedy wrote:
>>>
>>> On Thu, Jan 7, 2016 at 4:41 AM, Joseph Fry <joe at thefrys.com
>>> <mailto:joe at thefrys.com>> wrote:
>>> On Wed, Jan 6, 2016 at 6:22 PM, Kingsley Turner
>>> <<mailto:krt at krt.com.au>krt at krt.com.au> wrote:
>>>
>>> Greetings,
>>>
>>> So I have my Raspberry PI GPIO Infra-Red remote mostly working
>>> fine.
>>>
>>> I can see messages debugging with 'irw', all the codes are
>>> correct, etc.
>>>
>>> However in mythfrontend (and irw) I quite clearly get multiple
>>> keypresses; 99% double, sometimes single, sometimes triple.
>>> e.g.:
>>> pi at raspberrypi:~ $ irw
>>> 00000000807f9867 00 KEY_ENTER noontec_a6
>>> 00000000807f9867 01 KEY_ENTER noontec_a6
>
> This is by design. Most remotes sends several signal for each keypress
> (hopefully, at least one is delivered OK). The important thing is that the
> second number is increased for each signal as it indeed looks here (00,
> 01, ...).
>
>>> Reading many of the various posts for MythTV (and XBMC, etc.)
>>> the proposed solutions are not applicable to RPi.
>>>
>>> One thing I have tried, is creating an /etc/lirc/lircrc file
>>> which specifies button handling:
>>>
>>> begin
>>> button = KEY_ENTER
>>> delay = 5
>>> repeat = 3
>>> #prog = irexec
>>> #config = echo KEY_ENTER
>>> end
>>>
>>> I added a clause like this for every key.
>>>
>>> If I run 'irexec' with those two commented-out lines back in,
>>> and press keys, the remote does behave as-if the lircrc file
>>> has made a difference. Indeed, changing the delay & repeat
>>> allowed me to tune button pushing so there was no unwanted
>>> repeats - but only for irexec.
>>> Should I expect 'irw' and MytvTV to respect this lircrc file ?
>>>
>>> Is there something I'm missing?
>>>
>>>
>>> First of all... IRW doesn't really use your lircrc, so those
>>> options will have no effect.... it is showing every signal the
>>> receiver gets.
>
> To test the lircrc configuration you should use ircat(1). Also, note that
> the 'config' value is a string returned to the application, not a command
> like in irexec. RTFM: [1]
>
>
>> Hi Larry,
>>
>> I did read all this (and other) help pages, but the first problem you
>> encounter on the RPi, is that stuff like:
>> /sys/class/rc/rc0/protocols
>>
>> don't exist. IIRC, this directory only exists up to /sys/class/rc and
>> then it's empty.
>
> It is created when the kernel loads a (lirc-based) driver for a device. In
> this case, I *guess* it's about the lirc_rpi driver. Is it loaded? Or are
> you using another driver?
>
> Note, I just presume that lirc_rpi sets up the rc device...
>
Yeah the lirc_rpi driver is loaded.
I'll give ircat a try next time I'm on it.
cheers,
-kt
More information about the mythtv-users
mailing list