From: Bruno M. A. <br...@pi...> - 2010-07-19 18:01:30
|
Hi... recently I'm working with one of these... [URL="http://www.liming-electronics.com/productview.asp?id=2458"]LM-PC001[/URL] it works via /dev/input/event4, so I'm using devinput driver for lirc, the thing is, it works flawlessy when lirc is not running, (via linux-input-layer) but I do need to make it work with lirc... I can make work almost everything using this lircd.conf (incomplete here) # Please make this file available to others # by sending it to <li...@ba...> # # this config file was automatically generated # using lirc-0.8.6(devinput) on Fri Jul 16 12:20:55 2010 # # contributed by # # brand: lm.conf # model no. of remote control: # devices being controlled by this remote: # begin remote name lm.conf bits 32 eps 30 aeps 100 one 0 0 zero 0 0 gap 47988 toggle_bit_mask 0x0 begin codes BTN_6 0x00020000 # BTN_4 0x00020000 # Using BTN_2,4,6 and 8 for mouse directions... BTN_8 0x00020001 # BTN_2 0x00020001 # KEY_1 0x00010002 KEY_2 0x00010003 KEY_3 0x00010004 KEY_4 0x00010005 KEY_5 0x00010006 KEY_6 0x00010007 KEY_7 0x00010008 KEY_8 0x00010009 KEY_9 0x0001000A KEY_STOPCD 0x000100A6 end codes end remote the problem is with the mouse (the blue circle in the center of the remote) that's what I got from hexdump /dev/input/event4 | keycode | 0000060 8cbf 4c44 c4f0 0004 0004 0004 001f 0007 0000070 8cbf 4c44 c50e 0004 0001 0003 0001 0000 0000080 8cbf 4c44 c516 0004 0000 0000 0000 0000 0000090 8cbf 4c44 90d5 0008 0001 0003 0002 0000 00000a0 8cbf 4c44 90ed 0008 0000 0000 0001 0000 The first line is some kind of header, that appears when i press the button but not when i repeat the command (hold the button pressed) in the second line (repeated on fourth) i can see the keycode itself 0x10003, the code for KEY_2 so far so good, the problem is with the mouse buttons... here is the hexdump for +X and -X | keycode | 0000280 8dc1 4c44 82b5 0008 0002 0000 0007 0000 \ 0000290 8dc1 4c44 82d2 0008 0000 0000 0000 0000 \ +X 00002a0 8dc2 4c44 b43e 0005 0002 0001 0001 0000 / 00002b0 8dc2 4c44 b45b 0005 0000 0000 0000 0000 / 00002c0 8dc2 4c44 6fbd 0006 0002 0000 fff9 ffff \ 00002d0 8dc2 4c44 6fdc 0006 0000 0000 0000 0000 \ -X 00002e0 8dc2 4c44 4a81 0007 0002 0000 fff9 ffff / 00002f0 8dc2 4c44 4a9b 0007 0002 0001 0007 0000 / First thing, it doesn't show the header (not a problem really) but as you can see the bits that differ the direction on the axis is the latter ones, and lirc is not taking them into account so both buttons result in the same direction... Is there a way that i can make lirc take them into account? also irrecord doesn't work because of the "0x40004" header, all comands, are detected as "0x400004"... and since it uses devinput driver, mode2 says "This program doesn't work for this hardware yet." |