hardware.lirc

Re: Cyberlink USB Remote - lircd reading from multiple input devices

Subject: Re: Cyberlink USB Remote - lircd reading from multiple input devices
List-id: LIRC mailing list <lirc-list.lists.sourceforge.net>
(sorry for breaking the thread - has to do with home-email and work-email
separation)

Christoph Bartelmus wrote
>Hi!
>
>Hermans Erwin "erwin.hermans@wi..." wrote:
>[...]
>> Is it possible to tell lirc (via lircd.conf) that whenever a code A
>> immediately followed by a code B is received and decoded that is only should
>> be recognised as a POWER button and not as a TOOLS and POWER button press?
>
>No, and I don"t think it ever will. Only this is supported:
>
>TOOLS A
>POWER B A

This is exactly what I need (my remote sends codes for several buttons
like this), but onfortunately it doesn't work for me.
Setup:
- PII-450MHz with Fedora Core 1 (couldn't go with FC2 - dxr3 driver does
not yet support kernel 2.6 - FC1 ships with 2.4 kernel)
- Cyberlink USB PowerDVD Remote Control
- lirc0.7.0pre8 configured to use the linux input layer
(/dev/input/event0 for me) (see further down the mail why I am not using
lirc0.7.0)

Only yesterday I have tried the suggested solution. Here goes (part of) my
lircd.conf file:

==========
lircd.conf
==========
# brand:                       CyberLink
 # model no. of remote control: USB PowerDVD remote control
 # devices being controlled by this remote:
begin remote
        name    CyberLink

        begin codes
                POWER           0x00010058
                FULLSCREEN      0x0001002c
                UP              0x00010067
# problem with EJECT
                PREV            0x00010012
                EJECT           0x0001001d      0x00010012
                LEFT            0x00010069
                ENTER           0x0001001c
                RIGHT           0x0001006a
... snip ...
        end codes
end remote
==========
lircd.conf
==========

I recompiled lircd0.7.0pre8 with debug code enabled. Output when starting
lircd.

======
Output
======
[root@localhost root]# lircd -D3
lircd 0.7.0pre8: started server socket
lircd 0.7.0pre8: "#" "brand:"
lircd 0.7.0pre8: "#" "model"
lircd 0.7.0pre8: "#" "devices"
lircd 0.7.0pre8: "begin" "remote"
lircd 0.7.0pre8: parsing remote
lircd 0.7.0pre8: creating first remote
lircd 0.7.0pre8: "name" "CyberLink"
lircd 0.7.0pre8: parsing CyberLink remote
lircd 0.7.0pre8: "begin" "codes"
lircd 0.7.0pre8:     begin codes
lircd 0.7.0pre8: "POWER" "0x00010058"
lircd 0.7.0pre8:       POWER                0x0000000000010058
lircd 0.7.0pre8: "FULLSCREEN" "0x0001002c"
lircd 0.7.0pre8:       FULLSCREEN           0x000000000001002C
lircd 0.7.0pre8: "UP" "0x00010067"
lircd 0.7.0pre8:       UP                   0x0000000000010067
lircd 0.7.0pre8: "PREV" "0x00010012"
lircd 0.7.0pre8:       PREV                 0x0000000000010012
lircd 0.7.0pre8: "EJECT" "0x0001001d"
lircd 0.7.0pre8:       EJECT                0x000000000001001D
lircd 0.7.0pre8:                            0x0000000000010012
lircd 0.7.0pre8: "LEFT" "0x00010069"
lircd 0.7.0pre8:       LEFT                 0x0000000000010069
lircd 0.7.0pre8: "ENTER" "0x0001001c"
lircd 0.7.0pre8:       ENTER                0x000000000001001C
lircd 0.7.0pre8: "RIGHT" "0x0001006a"
lircd 0.7.0pre8:       RIGHT                0x000000000001006A
... snip ...
lircd 0.7.0pre8: "end" "codes"
lircd 0.7.0pre8:     end codes
lircd 0.7.0pre8: "end" "remote"
lircd 0.7.0pre8: end remote
lircd 0.7.0pre8: config file read
[root@localhost root]#
======
Output
======

So far so good I suppose ;)
I then run 'irw' to test this all, but the result is disappointing:
- all keys defined after the EJECT key in lircd.conf are not recognized
(or at least not sent to the client irw)
(so move this down to the last definition, I here you thinking, but there
are 5 keys that operate in this manner and I want them all to work)
- when pressing the PREV key on the remote, it is identified correctly
- when pressing the EJECT key, irw says that the PREV key has been pressed
(I will give the output of tail -f /var/log/lircd later on)

I then upgraded to lirc0.7.0 only to find out that, when testing with
irw, nothing was recognized any more. Not even when commenting the
definition of the EJECT key and restarting lircd. I then downgraded back
to lirc0.7.0pre8 to regain at least some functionality.

As you can see from the following log, lirc0.7.0pre8 does the recognition
up to some level, but does not send anything defined after the EJECT key
to a client. lirc0.7.0 does not even recognize the button presses, it only
reports failures, in spite the fact that the codes are received correctly
with lirc0.7.0 (the codes show up correctly in the logs - I haven't pasted
the log here to make the mail not too long ;) - but lirc0.7.0 is
apparently not able to make them correspond to a definition in the
lircd.conf file)

I also noticed from the log-file that lircd does recognise the most keys
correctly (except from the EJECT-key and the likes which it only partly
recognizes) but doesn't send it to the client.

================================
Output of tail -f /var/log/lircd
================================
[root@localhost root]# tail -f /var/log/lircd
Nov 27 15:47:31 localhost.localdomain lircd 0.7.0pre8:       VOL_UP
0x000000000001004E
Nov 27 15:47:31 localhost.localdomain lircd 0.7.0pre8: "end" "codes"
Nov 27 15:47:31 localhost.localdomain lircd 0.7.0pre8:     end codes
Nov 27 15:47:31 localhost.localdomain lircd 0.7.0pre8: "end" "remote"
Nov 27 15:47:31 localhost.localdomain lircd 0.7.0pre8: end remote
Nov 27 15:47:31 localhost.localdomain lircd 0.7.0pre8: config file read
Nov 27 15:47:31 localhost.localdomain lircd 0.7.0pre8: lircd(devinput)
ready
Nov 27 15:55:34 localhost.localdomain lircd 0.7.0pre8: registering local
client
Nov 27 15:55:34 localhost.localdomain lircd 0.7.0pre8: accepted new client
on /dev/lircd
Nov 27 15:55:34 localhost.localdomain lircd 0.7.0pre8: initializing
'/dev/input/event0'

==================
Pressing EJECT key
==================
Nov 27 15:56:40 localhost.localdomain lircd 0.7.0pre8: devinput_rec
Nov 27 15:56:40 localhost.localdomain lircd 0.7.0pre8: time
1101567400.498777  type 1  code 29  value 1
Nov 27 15:56:40 localhost.localdomain lircd 0.7.0pre8: code 8001001d
Nov 27 15:56:40 localhost.localdomain lircd 0.7.0pre8: trying "CyberLink"
remote
Nov 27 15:56:40 localhost.localdomain lircd 0.7.0pre8: devinput_decode
Nov 27 15:56:40 localhost.localdomain lircd 0.7.0pre8: failed "CyberLink"
remote
Nov 27 15:56:40 localhost.localdomain lircd 0.7.0pre8: decoding failed for
all remotes
Nov 27 15:56:40 localhost.localdomain lircd 0.7.0pre8: devinput_rec
Nov 27 15:56:40 localhost.localdomain lircd 0.7.0pre8: time
1101567400.506769  type 1  code 18  value 1
Nov 27 15:56:40 localhost.localdomain lircd 0.7.0pre8: code 80010012
Nov 27 15:56:40 localhost.localdomain lircd 0.7.0pre8: trying "CyberLink"
remote
Nov 27 15:56:40 localhost.localdomain lircd 0.7.0pre8: devinput_decode
Nov 27 15:56:40 localhost.localdomain lircd 0.7.0pre8: failed "CyberLink"
remote
Nov 27 15:56:40 localhost.localdomain lircd 0.7.0pre8: decoding failed for
all remotes
Nov 27 15:56:40 localhost.localdomain lircd 0.7.0pre8: devinput_rec
Nov 27 15:56:40 localhost.localdomain lircd 0.7.0pre8: time
1101567400.514764  type 1  code 29  value 0
Nov 27 15:56:40 localhost.localdomain lircd 0.7.0pre8: code 0001001d
Nov 27 15:56:40 localhost.localdomain lircd 0.7.0pre8: trying "CyberLink"
remote
Nov 27 15:56:40 localhost.localdomain lircd 0.7.0pre8: devinput_decode
Nov 27 15:56:40 localhost.localdomain lircd 0.7.0pre8: found: EJECT
Nov 27 15:56:40 localhost.localdomain lircd 0.7.0pre8: devinput_rec
Nov 27 15:56:40 localhost.localdomain lircd 0.7.0pre8: time
1101567400.514770  type 1  code 18  value 0
Nov 27 15:56:40 localhost.localdomain lircd 0.7.0pre8: code 00010012
Nov 27 15:56:40 localhost.localdomain lircd 0.7.0pre8: trying "CyberLink"
remote
Nov 27 15:56:40 localhost.localdomain lircd 0.7.0pre8: devinput_decode
Nov 27 15:56:40 localhost.localdomain lircd 0.7.0pre8: found: PREV
Nov 27 15:56:40 localhost.localdomain lircd 0.7.0pre8: writing to client 0

==============
Note from me: In my opinion lircd should recognise the combination of
these two codes as a single keypress on the EJECT button, certainly since
it appears to me that these codes are received at the same moment.
==============

=================
Pressing PREV key
=================
Nov 27 16:00:02 localhost.localdomain lircd 0.7.0pre8: devinput_rec
Nov 27 16:00:02 localhost.localdomain lircd 0.7.0pre8: time
1101567602.925866  type 1  code 18  value 1
Nov 27 16:00:02 localhost.localdomain lircd 0.7.0pre8: code 80010012
Nov 27 16:00:02 localhost.localdomain lircd 0.7.0pre8: trying "CyberLink"
remote
Nov 27 16:00:02 localhost.localdomain lircd 0.7.0pre8: devinput_decode
Nov 27 16:00:02 localhost.localdomain lircd 0.7.0pre8: failed "CyberLink"
remote
Nov 27 16:00:02 localhost.localdomain lircd 0.7.0pre8: decoding failed for
all remotes
Nov 27 16:00:03 localhost.localdomain lircd 0.7.0pre8: devinput_rec
Nov 27 16:00:03 localhost.localdomain lircd 0.7.0pre8: time
1101567603.077829  type 1  code 18  value 0
Nov 27 16:00:03 localhost.localdomain lircd 0.7.0pre8: code 00010012
Nov 27 16:00:03 localhost.localdomain lircd 0.7.0pre8: trying "CyberLink"
remote
Nov 27 16:00:03 localhost.localdomain lircd 0.7.0pre8: devinput_decode
Nov 27 16:00:03 localhost.localdomain lircd 0.7.0pre8: found: PREV
Nov 27 16:00:03 localhost.localdomain lircd 0.7.0pre8: writing to client 0

=================
Pressing LEFT key
=================
Nov 27 16:00:43 localhost.localdomain lircd 0.7.0pre8: devinput_rec
Nov 27 16:00:43 localhost.localdomain lircd 0.7.0pre8: time
1101567643.094543  type 1  code 105  value 1
Nov 27 16:00:43 localhost.localdomain lircd 0.7.0pre8: code 80010069
Nov 27 16:00:43 localhost.localdomain lircd 0.7.0pre8: trying "CyberLink"
remote
Nov 27 16:00:43 localhost.localdomain lircd 0.7.0pre8: devinput_decode
Nov 27 16:00:43 localhost.localdomain lircd 0.7.0pre8: failed "CyberLink"
remote
Nov 27 16:00:43 localhost.localdomain lircd 0.7.0pre8: decoding failed for
all remotes
Nov 27 16:00:43 localhost.localdomain lircd 0.7.0pre8: devinput_rec
Nov 27 16:00:43 localhost.localdomain lircd 0.7.0pre8: time
1101567643.246505  type 1  code 105  value 0
Nov 27 16:00:43 localhost.localdomain lircd 0.7.0pre8: code 00010069
Nov 27 16:00:43 localhost.localdomain lircd 0.7.0pre8: trying "CyberLink"
remote
Nov 27 16:00:43 localhost.localdomain lircd 0.7.0pre8: devinput_decode
Nov 27 16:00:43 localhost.localdomain lircd 0.7.0pre8: found: LEFT
================================
Output of tail -f /var/log/lircd
================================

- irw does not get the LEFT key press

=============
Output of irw
=============
[root@localhost root]# irw
0000000000010012 00 PREV CyberLink
0000000000010012 00 PREV CyberLink
=============
Output of irw
=============


Now my question is:
- what am I doing wrong? (or how should I solve this if I am doing nothing
wrong?)

Thanks in advance

PS: creating a lircd.conf file via irrecord does not succeed (gap not
found, can't continue - error), maybe this is logical since the input
arrives via the event device interface?


-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now. 
http://productguide.itmanagersjournal.com/



<Prev in Thread] Current Thread [Next in Thread>