Linux - [xbmcbuntu] [SOLVED] some buttons not working PHILIPS MCE USB IR Receiver-Spinel plus

  Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Post Reply
bennyp Offline
Junior Member
Posts: 7
Joined: Jun 2012
Reputation: 0
Post: #1
Hi,

I've just installed XBMCBuntu onto a new Zotac ZBOX nano AD10 and everything is good, apart from a couple of buttons don't seem to work.

The box comes with a built-in IR port (identifies as: ITE8704 CIR transceiver), an MCE remote and a USB IR extender (identifies as: PHILIPS MCE USB IR Receiver- Spinel plus)
(It seems that the remote only works when using the extender, which is fine as the box is mounted on the back of the TV.)

I've been monitoring the debug log when pressing all the buttons and it seems that I need to use lirc to get more of the buttons to work.
Using Windows Media Center Transceivers/Remotes (all) doesnt seem to do anything, but Linux input layer (/dev/input/eventX) does.

Using the remote without making any changes, the following buttons do not work:
Sleep
Wake
Teletext
Program
Windows button
Red
Blue
Green
Yellow

If I reconfigure lirc setting to Linux input layer (/dev/input/eventX) using the device 'usb-PHILIPS_MCE_USB_IR_Receiver-_Spinel_plus-event-ir', the following do not work:
Teletext
Windows button
Red
Blue
Green
Yellow

But for Sleep/Wake/Progam I get:
Code:
14:54:21 T:3491584   DEBUG: LIRC: Update - NEW at 57848:000000008001008e 00 KEY_SLEEP devinput (KEY_SLEEP)
14:54:22 T:3491584   DEBUG: LIRC: Update - NEW at 58737:000000008001008f 00 KEY_WAKEUP devinput (KEY_WAKEUP)
14:54:24 T:3491584   DEBUG: LIRC: Update - NEW at 61438:000000008001016a 00 KEY_PROGRAM devinput (KEY_PROGRAM)

I then installed evtest, selected event2 (The phillips USB) and pressed the Windows button/Teletext/Coloured buttons, nothing happens at all.

If I then change to use event3 with evtest (The internal IR receiever), pressing the buttons above produces:
Code:
Windows button:
Event: time 1338720362.553380, type 4 (Misc), code 4 (ScanCode), value 8034045d

Teletext
Event: time 1338720546.638290, type 4 (Misc), code 4 (ScanCode), value 8034042f

Red:
Event: time 1338720572.415481, type 4 (Misc), code 4 (ScanCode), value 8034046d

Green:
Event: time 1338720574.816499, type 4 (Misc), code 4 (ScanCode), value 8034046e

Yellow:
Event: time 1338720577.741352, type 4 (Misc), code 4 (ScanCode), value 8034046f

Blue:
Event: time 1338720578.930124, type 4 (Misc), code 4 (ScanCode), value 80340470

So it seems that the internal IR receiver can understand the remote, but the USB extender cannot?
Is there a way to somehow use the driver from the internal with the USB so that I can map the keys?

Or even any way to get those buttons to work so they can be mapped to xbmc?

I've seen this (from this post), but that relates to openELEC. Would it be a case of doing something similar, but for XBMCbuntu?

Some relevant bits and pieces:

xbmc@xbmc-lounge:~$ cat /proc/bus/input/devices
Code:
I: Bus=0003 Vendor=0471 Product=20cc Version=0100
N: Name="PHILIPS MCE USB IR Receiver- Spinel plus"
P: Phys=usb-0000:00:12.0-2/input0
S: Sysfs=/devices/pci0000:00/0000:00:12.0/usb4/4-2/4-2:1.0/input/input2
U: Uniq=
H: Handlers=sysrq kbd event2
B: PROP=0
B: EV=120013
B: KEY=c0000 400 0 0 0 0 58000 8001f8 4000c004 e0beffdf 1cfffff ffffffff fffffffe
B: MSC=10
B: LED=1f

I: Bus=0019 Vendor=1283 Product=0000 Version=0000
N: Name="ITE8704 CIR transceiver"
P: Phys=
S: Sysfs=/devices/virtual/rc/rc0/input3
U: Uniq=
H: Handlers=kbd event3
B: PROP=0
B: EV=100013
B: KEY=fff 0 0 200 108fc32e 2376051 0 0 0 7 158000 4192 4001 8e9680 0 0 10000000
B: MSC=10

Code:
xbmc@xbmc-lounge:~$ cat /etc/lirc/hardware.conf
# hardware.conf for eb1501
#
REMOTE="Linux input layer (/dev/input/eventX)"
REMOTE_MODULES=""
REMOTE_DRIVER="devinput"
REMOTE_DEVICE="/dev/input/by-id/usb-PHILIPS_MCE_USB_IR_Receiver-_Spinel_plus-event-ir"
REMOTE_SOCKET=""
REMOTE_LIRCD_CONF="devinput/lircd.conf.devinput"
REMOTE_LIRCD_ARGS=""
TRANSMITTER="None"
TRANSMITTER_MODULES=""
TRANSMITTER_DRIVER=""
TRANSMITTER_DEVICE=""
TRANSMITTER_SOCKET=""
TRANSMITTER_LIRCD_CONF=""
TRANSMITTER_LIRCD_ARGS=""
START_LIRCD="true"
LOAD_MODULES="true"
LIRCMD_CONF=""
FORCE_NONINTERACTIVE_RECONFIGURATION="false"
START_LIRCMD=""
REMOTE_MODULES=""
REMOTE_LIRCD_CONF="devinput/lircd.conf.devinput"

Code:
xbmc@xbmc-lounge:~$ cat /etc/lirc/lircd.conf
#This configuration has been automatically generated via
#the Ubuntu LIRC package maintainer scripts.
#
#It includes the default configuration for the remote and/or
#transmitter that you have selected during package installation.
#
#Feel free to add any custom remotes to the configuration
#via additional include directives or below the existing
#Ubuntu include directives from your selected remote and/or
#transmitter.

#Configuration for the Linux input layer (/dev/input/eventX) remote:
include "/usr/share/lirc/remotes/devinput/lircd.conf.devinput"
[/code]
(This post was last modified: 2012-06-04 01:31 by bennyp.)
find quote
FernetMenta Offline
Team-Kodi Developer
Posts: 3,424
Joined: Jul 2010
Reputation: 67
Location: Munich
Post: #2
You would need to compile the kernel to get the oe patches. I have created a hid driver for lirc and added a config for this remote control: https://github.com/FernetMenta/lirc
This makes all buttons work. The remote would still be recognized as a keyboard by X11. Make X11 ignore it:
Code:
Section "InputClass"
  Identifier "PHILIPS MCE USB IR Receiver- Spinel plus"
  MatchProduct "PHILIPS MCE USB IR Receiver- Spinel plus"
  MatchIsKeyboard "true"
  Option "Ignore" "true"
EndSection
find quote
bennyp Offline
Junior Member
Posts: 7
Joined: Jun 2012
Reputation: 0
Post: #3
Hi FernetMenta,

Are you saying I just need to use the config file, or do I need to remove lirc and compile from the one in your repo?

If I try and run ./setup.sh && make install from a clone of yours, I get "Can't open ./setup-driver.sh" ?
(This post was last modified: 2012-06-03 18:06 by bennyp.)
find quote
FernetMenta Offline
Team-Kodi Developer
Posts: 3,424
Joined: Jul 2010
Reputation: 67
Location: Munich
Post: #4
Yes, you need to compile lirc from my repo.

./autogen.sh
./setup.sh (requires package dialog, select driver zotac, save & configure)
make
sudo make install

I use this udev rule which crates a symlink for the receiver and fires an event to upstart. In this case the device lirc connects to will be
/dev/remote

Code:
SUBSYSTEM=="usb" , ATTRS{idVendor}=="0471", ATTRS{idProduct}=="20cc", SYMLINK+="remote", ACTION=="add", RUN+="/sbin/initctl --quiet emit --no-wait ir-ready"
find quote
bennyp Offline
Junior Member
Posts: 7
Joined: Jun 2012
Reputation: 0
Post: #5
Ah, I missed the ./autogen.sh previously, but I still get an error:

Code:
xbmc@xbmc-lounge:~/tmp/FernetMenta-lirc-c336b00$ ./autogen.sh
./autogen.sh: 4: autoreconf: not found
./autogen.sh: 7: automake: not found
cat: configure: No such file or directory
Creating setup-driver.sh ...

Code:
./setup.sh
[[ Choose Zotac in dialog ]]

Configuration: .setup.config, executable shell script: configure.sh
Starting the generated shell script which will call configure with the right
parameters...

Code:
xbmc@xbmc-lounge:~/tmp/FernetMenta-lirc-c336b00$ make
make: *** No targets specified and no makefile found.  Stop.

Thanks for the help!
find quote
FernetMenta Offline
Team-Kodi Developer
Posts: 3,424
Joined: Jul 2010
Reputation: 67
Location: Munich
Post: #6
Don't continue if one of the steps fails.
Check the output, it tells you what's missing. Install required packages for build. In this case automake
find quote
bennyp Offline
Junior Member
Posts: 7
Joined: Jun 2012
Reputation: 0
Post: #7
Thanks FernetMenta,

I installed automake, and libtool and now it compiles just fine, although the buttons still don't work Sad

I also edited /usr/share/X11/xorg.conf.d/10-evdev.conf so that it contains:
Code:
Section "InputClass"
  Identifier "PHILIPS MCE USB IR Receiver- Spinel plus"
  MatchProduct "PHILIPS MCE USB IR Receiver- Spinel plus"
  MatchIsKeyboard "true"
  Option "Ignore" "true"
EndSection

and added to /etc/udev/rules.d/10-local.rules:
Code:
SUBSYSTEM=="usb" , ATTRS{idVendor}=="0471", ATTRS{idProduct}=="20cc", SYMLINK+="remote", ACTION=="add", RUN+="/sbin/initctl --quiet emit --no-wait ir-ready"

xbmc@xbmc-lounge:~$ cat /etc/lirc/lircd.conf
Code:
# Please make this file available to others
# by sending it to <lirc@bartelmus.de>
#
# this config file was automatically generated
# using lirc-0.9.1-git(zotac) on Mon Apr  2 14:10:29 2012
#
# contributed by
#
# brand:                       zotac.conf
# model no. of remote control:
# devices being controlled by this remote:
#

begin remote

  name  zotac.conf
  bits           32
  eps            30
  aeps          100

  one             0     0
  zero            0     0
  gap          100123
  min_repeat      9
#  suppress_repeat 9
#  uncomment to suppress unwanted repeats
#  toggle_bit_mask 0x7004F

      begin codes
          KEY_SLEEP                0x00010082
          KEY_WAKEUP               0x00010083
          KEY_RECORD               0x000C00B2
          KEY_PAUSE                0x000C00B1
          KEY_STOP                 0x000C00B7
          KEY_REWIND               0x000C00B4
          KEY_PLAY                 0x000C00B0
          KEY_FORWARD              0x000C00B3
          KEY_LEFTSHIFT            0x000C00B6
          KEY_RIGHTSHIFT           0x000C00B5
          KEY_BACK                 0x000C0224
          KEY_INFO                 0x000C0209
          KEY_MENU                 0xFFBC000D
          KEY_UP                   0x00070052
          KEY_LEFT                 0x00070050
          KEY_RIGHT                0x0007004F
          KEY_DOWN                 0x00070051
          KEY_OK                   0x00070028
          KEY_VOLUMEUP             0x000C00E9
          KEY_VOLUMEDOWN           0x000C00EA
          KEY_MUTE                 0x000C00E2
          KEY_CHANNELUP            0x000C009C
          KEY_CHANNELDOWN          0x000C009D
          KEY_1                    0x0007001E
          KEY_2                    0x0007001F
          KEY_3                    0x00070020
          KEY_4                    0x00070021
          KEY_5                    0x00070022
          KEY_6                    0x00070023
          KEY_7                    0x00070024
          KEY_8                    0x00070025
          KEY_9                    0x00070026
          KEY_0                    0x00070027
          KEY_NUMERIC_STAR         0x10070025
          KEY_NUMERIC_POUND        0x10070020
          KEY_CLEAR                0x00070029
          KEY_TEXT                 0xFFBC005A
          KEY_TITLE                0x000C008D
          KEY_ENTER                0x00070028
          KEY_RED                  0xFFBC005B
          KEY_GREEN                0xFFBC005C
          KEY_YELLOW               0xFFBC005D
          KEY_BLUE                 0xFFBC005E
      end codes

end remote

xbmc@xbmc-lounge:~$ cat /etc/lirc/hardware.conf
Code:
# hardware.conf for eb1501
#
REMOTE="Zortac MCE Remote"
REMOTE_MODULES=""
REMOTE_DRIVER="zortac"
REMOTE_DEVICE="/dev/remote"
REMOTE_SOCKET=""
REMOTE_LIRCD_CONF="zortac/lircd.conf.zortac"
REMOTE_LIRCD_ARGS=""
TRANSMITTER="None"
TRANSMITTER_MODULES=""
TRANSMITTER_DRIVER=""
TRANSMITTER_DEVICE=""
TRANSMITTER_SOCKET=""
TRANSMITTER_LIRCD_CONF=""
TRANSMITTER_LIRCD_ARGS=""
START_LIRCD="true"
LOAD_MODULES="true"
LIRCMD_CONF=""
FORCE_NONINTERACTIVE_RECONFIGURATION="false"
START_LIRCMD=""

There are some errors in /var/lib/lircd as well:
Code:
Jun  3 20:26:18 xbmc-lounge lircd: lircd(zotac) ready, using /var/run/lirc/lircd
Jun  3 20:26:45 xbmc-lounge lircd: accepted new client on /var/run/lirc/lircd
Jun  3 20:26:45 xbmc-lounge lircd: zotac initializing '/dev/input/event2'
Jun  3 20:26:45 xbmc-lounge lircd: WARNING: Failed to initialize hardware
Jun  3 20:26:52 xbmc-lounge lircd: caught signal
Jun  3 20:26:52 xbmc-lounge lircd: closing '/dev/input/event2'
(This post was last modified: 2012-06-03 21:47 by bennyp.)
find quote
FernetMenta Offline
Team-Kodi Developer
Posts: 3,424
Joined: Jul 2010
Reputation: 67
Location: Munich
Post: #8
looks like lirc does not work at all and you still get keyboard events. Make X11 ignore the ir receiver. Test lirc with irw

zortac -> zotac

REMOTE="Zortac MCE Remote"
REMOTE_DRIVER="zortac"
REMOTE_LIRCD_CONF="zortac/lircd.conf.zortac"
find quote
bennyp Offline
Junior Member
Posts: 7
Joined: Jun 2012
Reputation: 0
Post: #9
Ah, good spot! Smile I totally didn't see that! Thanks!

Ok, so if I run sudo /usr/local/sbin/lircd -H zotac -d /dev/remote -n in one console and then sudo irw in another, I can see all the buttons working, result!

As an aside, it seems that whenever I run the above the first time I get this, so I just make the folder and it works fine.
Code:
lircd: can't open or create /var/run/lirc/lircd.pid
lircd: No such file or directory

So now, how do I make this load on start and I guess work with xbmc?

Thanks for your help so far, you've got me much further than I was! Smile

Edit:
Ok, so the init.d script was failing because /usr/sbin/lircd was missing so after doing the below, it starts putting things in the log file.
Code:
xbmc@xbmc-lounge:/usr/sbin# sudo ln -s ../local/sbin/lircd lircd
xbmc@xbmc-lounge:/usr/sbin# sudo ln -s ../local/sbin/lircmd lircmd

Now if I run irw, in /var/log/lirc I get
Code:
Jun  3 21:48:30 xbmc-lounge lircd: lircd(zotac) ready, using /var/run/lirc/lircd
Jun  3 21:48:57 xbmc-lounge lircd: accepted new client on /var/run/lirc/lircd
Jun  3 21:48:57 xbmc-lounge lircd: zotac initializing '/dev/remote'
Jun  3 21:48:57 xbmc-lounge lircd: unable to open '/dev/remote'
Jun  3 21:48:57 xbmc-lounge lircd: WARNING: Failed to initialize hardware
Jun  3 21:49:00 xbmc-lounge lircd: removed client

Looking in /dev it seems that /dev/remote has changed the location of where it was pointing now that lirc is loading up on startup
Code:
lrwxrwxrwx  1 root root          19 2012-06-03 21:48 remote -> /var/run/lirc/lircd=

Edit 2:
That was my mistake, I was playing about with the init.d script, put it back and it now loads up properly, and I can see the commands in the xmbc log! Big Grin
Code:
22:18:16 T:6522624   DEBUG: LIRC: Update - NEW at 193993:00000000ffbc005b 00 KEY_RED zotac.conf (KEY_RED)
22:18:17 T:6522624   DEBUG: LIRC: Update - NEW at 194618:00000000ffbc005c 00 KEY_GREEN zotac.conf (KEY_GREEN)
22:18:17 T:6522624   DEBUG: LIRC: Update - NEW at 195080:00000000ffbc005d 00 KEY_YELLOW zotac.conf (KEY_YELLOW)
22:18:18 T:6522624   DEBUG: LIRC: Update - NEW at 195622:00000000ffbc005e 00 KEY_BLUE zotac.conf (KEY_BLUE)
22:18:26 T:6522624   DEBUG: LIRC: Update - NEW at 204040:00000000000c008d 00 KEY_TITLE zotac.conf (KEY_TITLE)
22:18:27 T:6522624   DEBUG: LIRC: Update - NEW at 204907:00000000ffbc005a 00 KEY_TEXT zotac.conf (KEY_TEXT)
22:18:30 T:6522624   DEBUG: LIRC: Update - NEW at 207341:00000000ffbc000d 00 KEY_MENU zotac.conf (KEY_MENU)

Big thanks, FernetMenta!

Now to figure out why the remote isnt actually moving anything on the screen...

Edit 3:
Its because I was missing a Lircmap.xml file
(This post was last modified: 2012-06-04 00:05 by bennyp.)
find quote
bennyp Offline
Junior Member
Posts: 7
Joined: Jun 2012
Reputation: 0
Post: #10
BIG thanks to FernetMenta!

I ended up playing around a bit with various bits, but basically I did the following to get all the buttons working.

1. Remove lirc
Code:
> sudo apt-get remove lirc

2. Install some extra packages
Code:
> sudo apt-get install automake dialog libtool

3. Download the version from FernetMenta (In case it ever moves, I've forked it over at my account)
Code:
> wget https://github.com/FernetMenta/lirc/tarball/master -O lirc.tar.gz
> tar -xf lirc.tar.gz

4a. Configure and install the new lirc, when running setup.sh, select driver zotac under usb, save & configure
Code:
> ./autogen.sh
> ./setup.sh
> make
> sudo make install

4b. If missing, create links in /usr/sbin
Code:
> cd /usr/sbin
> sudo ln -s ../local/sbin/lircd lircd
> sudo ln -s ../local/sbin/lircmd lircmd

5. Stop X11 from registering device as keyboard by putting the following at the bottom of /usr/share/X11/xorg.conf.d/10-evdev.conf
Code:
Section "InputClass"
  Identifier "PHILIPS MCE USB IR Receiver- Spinel plus"
  MatchProduct "PHILIPS MCE USB IR Receiver- Spinel plus"
  MatchIsKeyboard "true"
  Option "Ignore" "true"
EndSection

6. Add a alias in udev to /dev/remote by creating a new file at /etc/udev/rules.d/10-local.rules with the following:
Code:
SUBSYSTEM=="usb" , ATTRS{idVendor}=="0471", ATTRS{idProduct}=="20cc", SYMLINK+="remote", ACTION=="add", RUN+="/sbin/initctl --quiet emit --no-wait ir-ready"

6. Create config files - see below

7. Reboot and hopefully it should all work

/etc/lirc/hardware.conf
Code:
# hardware.conf for Zotac
#
REMOTE="Zotac MCE Remote"
REMOTE_MODULES=""
REMOTE_DRIVER="zotac"
REMOTE_DEVICE="/dev/remote"
REMOTE_SOCKET=""
REMOTE_LIRCD_CONF="zotac/lircd.conf.zotac"
REMOTE_LIRCD_ARGS=""
TRANSMITTER="None"
TRANSMITTER_MODULES=""
TRANSMITTER_DRIVER=""
TRANSMITTER_DEVICE=""
TRANSMITTER_SOCKET=""
TRANSMITTER_LIRCD_CONF=""
TRANSMITTER_LIRCD_ARGS=""
START_LIRCD="true"
LOAD_MODULES="true"
LIRCMD_CONF=""
FORCE_NONINTERACTIVE_RECONFIGURATION="false"
START_LIRCMD=""


/etc/lirc/lircd.conf
Code:
# Please make this file available to others
# by sending it to <lirc@bartelmus.de>
#
# this config file was automatically generated
# using lirc-0.9.1-git(zotac) on Mon Apr  2 14:10:29 2012
#
# contributed by
#
# brand:                       zotac.conf
# model no. of remote control:
# devices being controlled by this remote:
#

begin remote

  name  zotac.conf
  bits           32
  eps            30
  aeps          100

  one             0     0
  zero            0     0
  gap          100123
  min_repeat      9
#  suppress_repeat 9
#  uncomment to suppress unwanted repeats
#  toggle_bit_mask 0x7004F

      begin codes
          KEY_SLEEP                0x00010082
          KEY_WAKEUP               0x00010083
          KEY_RECORD               0x000C00B2
          KEY_PAUSE                0x000C00B1
          KEY_STOP                 0x000C00B7
          KEY_REWIND               0x000C00B4
          KEY_PLAY                 0x000C00B0
          KEY_FORWARD              0x000C00B3
          KEY_LEFTSHIFT            0x000C00B6
          KEY_RIGHTSHIFT           0x000C00B5
          KEY_BACK                 0x000C0224
          KEY_INFO                 0x000C0209
          KEY_MENU                 0xFFBC000D
          KEY_UP                   0x00070052
          KEY_LEFT                 0x00070050
          KEY_RIGHT                0x0007004F
          KEY_DOWN                 0x00070051
          KEY_OK                   0x00070028
          KEY_VOLUMEUP             0x000C00E9
          KEY_VOLUMEDOWN           0x000C00EA
          KEY_MUTE                 0x000C00E2
          KEY_CHANNELUP            0x000C009C
          KEY_CHANNELDOWN          0x000C009D
          KEY_1                    0x0007001E
          KEY_2                    0x0007001F
          KEY_3                    0x00070020
          KEY_4                    0x00070021
          KEY_5                    0x00070022
          KEY_6                    0x00070023
          KEY_7                    0x00070024
          KEY_8                    0x00070025
          KEY_9                    0x00070026
          KEY_0                    0x00070027
          KEY_NUMERIC_STAR         0x10070025
          KEY_NUMERIC_POUND        0x10070020
          KEY_CLEAR                0x00070029
          KEY_TEXT                 0xFFBC005A
          KEY_TITLE                0x000C008D
          KEY_ENTER                0x00070028
          KEY_RED                  0xFFBC005B
          KEY_GREEN                0xFFBC005C
          KEY_YELLOW               0xFFBC005D
          KEY_BLUE                 0xFFBC005E
      end codes

end remote


~/.xbmc/userdata/Lircmap.xml
Code:
<lircmap>
    <remote device="zotac.conf">
        <power>KEY_SLEEP</power>
        <wake>KEY_WAKEUP</wake>
        <record>KEY_RECORD</record>
        <pause>KEY_PAUSE</pause>
        <stop>KEY_STOP</stop>
        <reverse>KEY_REWIND</reverse>
        <play>KEY_PLAY</play>
        <forward>KEY_FORWARD</forward>
        <skipminus>KEY_LEFTSHIFT</skipminus>
        <skipplus>KEY_RIGHTSHIFT</skipplus>
        <back>KEY_BACK</back>
        <info>KEY_INFO</info>
        <display>KEY_MENU</display>
        <up>KEY_UP</up>
        <left>KEY_LEFT</left>
        <right>KEY_RIGHT</right>
        <down>KEY_DOWN</down>
        <select>KEY_OK</select>
        <volumeplus>KEY_VOLUMEUP</volumeplus>
        <volumeminus>KEY_VOLUMEDOWN</volumeminus>
        <mute>KEY_MUTE</mute>
        <up>KEY_CHANNELUP</up>
        <down>KEY_CHANNELDOWN</down>
        <zero>KEY_0</zero>
        <one>KEY_1</one>
        <two>KEY_2</two>
        <three>KEY_3</three>
        <four>KEY_4</four>
        <five>KEY_5</five>
        <six>KEY_6</six>
        <seven>KEY_7</seven>
        <eight>KEY_8</eight>
        <nine>KEY_9</nine>
        <red>KEY_RED</red>
            <green>KEY_GREEN</green>
            <yellow>KEY_YELLOW</yellow>
            <blue>KEY_BLUE</blue>
        <star>KEY_NUMERIC_STAR</star>
        <hash>KEY_NUMERIC_POUND</hash>
        <subtitle>KEY_TEXT</subtitle>
        <title>KEY_TITLE</title>
        <clear>KEY_CLEAR</clear>
    </remote>
</lircmap>
(This post was last modified: 2012-06-04 00:49 by bennyp.)
find quote
spocky184 Offline
Junior Member
Posts: 17
Joined: Jan 2010
Reputation: 0
Post: #11
Hi,
that is great ! I`ve investigated many hours to get the Zotac Remote running, without any success. Now your descriptions seems to be the way to get it running.
But i have a problem compiling lirc. After running make i get the following error:

Quote:Making all in tools
make[2]: Betrete Verzeichnis '/home/xbmc/zotac/FernetMenta-lirc-c336b00/tools'
/bin/bash ../libtool --tag=CC --mode=compile gcc -DHAVE_CONFIG_H -I. -I.. -I.. -O2 -g -Wall -MT lirc_client.lo -MD -MP -MF .deps/lirc_client.Tpo -c -o lirc_client.lo lirc_client.c
mv -f .deps/lirc_client.Tpo .deps/lirc_client.Plo
mv: Aufruf von stat für ».deps/lirc_client.Tpoâ nicht möglich: Datei oder Verzeichnis nicht gefunden
make[2]: *** [lirc_client.lo] Fehler 1
make[2]: Verlasse Verzeichnis '/home/xbmc/zotac/FernetMenta-lirc-c336b00/tools'
make[1]: *** [all-recursive] Fehler 1
make[1]: Verlasse Verzeichnis '/home/xbmc/zotac/FernetMenta-lirc-c336b00'
make: *** [all] Fehler 2
sorry, error message is in german. after the command 'mv -f .deps/lirc_client.Tpo .deps/lirc_client.Plo' the mv stats that .deps/lirc_client.Tpo can not be found
and then make ends.

Any ideas ?

Thank you very much for your help.

spocky184

PS: I would love to get that to run ;-)
find quote
bennyp Offline
Junior Member
Posts: 7
Joined: Jun 2012
Reputation: 0
Post: #12
I didn't have to install anything else to get it to compile on mine.

Although, I've just realised I installed autoconf, not automake - might make a difference?
find quote
schmick Offline
Junior Member
Posts: 1
Joined: Jun 2012
Reputation: 0
Post: #13
(2012-06-03 16:59)FernetMenta Wrote:  You would need to compile the kernel to get the oe patches. I have created a hid driver for lirc and added a config for this remote control: https://github.com/FernetMenta/lirc
This makes all buttons work. The remote would still be recognized as a keyboard by X11. Make X11 ignore it:
Code:
Section "InputClass"
  Identifier "PHILIPS MCE USB IR Receiver- Spinel plus"
  MatchProduct "PHILIPS MCE USB IR Receiver- Spinel plus"
  MatchIsKeyboard "true"
  Option "Ignore" "true"
EndSection

Fernet! great job on the zotac remote! Compiled like a charm.
I'm using Ubuntu 12.04 32bit on a zotac zboxnano a10 with the internal IR disabled and the external USB IR receiver.

I followed bennyp's minihow-to post.
Just some issues.
- I have to sudo mkdir /var/run/lirc every time I boot.
- sudo make install didn't create a startup (init.d) script. (any example on how to make one?)
- Running sudo lircd -H zotac --device=/dev/remote -n, irw shows connecting and all buttons work. But running XBMC, I see no connections being made to lirc. BTW, I can't seem to see /dev/lircd or lirc0. Should it exist?

I'll go back and reinstall your fork from the begining to see if I missed something, but I'd like to know if I'm expecting somethin your pakage does not do (init script or so).
THX!
find quote
FernetMenta Offline
Team-Kodi Developer
Posts: 3,424
Joined: Jul 2010
Reputation: 67
Location: Munich
Post: #14
I forked the lirc source project but did not create a package. You can use udev and upstart for starting lirc.

/etc/udev/rules.d/85-xbmc.rules
Code:
#Remote Control
SUBSYSTEM=="usb" , ATTRS{idVendor}=="0471", ATTRS{idProduct}=="20cc", SYMLINK+="remote", ACTION=="add", RUN+="/sbin/initctl --quiet emit --no-wait ir-ready"

/etc/init/lirc.conf
Code:
description "lirc"
emits "lirc-ready"
expect fork
start on (remote-filesystems
          and local-filesystems
      and started rsyslog
      and ir-ready)
stop on runlevel [!2345]

pre-start script
  while [ ! -e /dev/remote ]
  do
    sleep 1
  done
  mkdir /var/run/lirc
end script

exec /usr/local/sbin/lircd --driver=zotac --device=/dev/remote

post-start script
  ln -s /var/run/lirc/lircd /dev/lircd
end script

post-stop script
  rm /dev/lircd
  rm -rf /var/run/lirc
end script

lirc will automatically start at system boot. Use sudo start/stop lirc for manually start/stop lirc
find quote
guilmxm Offline
Member
Posts: 78
Joined: Jul 2012
Reputation: 1
Location: France
Post: #15
Hi,

I have somes troubles with the zotac remote control using Fermenta's lirc built, the remote control works but i always have some latency or key repeating, i would say it works more or less...

I tested it on fresh install on Ubuntu minimal and desktop versions, i'm sure the install is very clean, and also X11 does not register the device as a keyboard, X11 message logs:

[ 12.164] (II) config/udev: Adding input device PHILIPS MCE USB IR Receiver- Spinel plus (/dev/input/event2)
[ 12.164] (**) PHILIPS MCE USB IR Receiver- Spinel plus: Ignoring device from InputClass "PHILIPS MCE USB IR Receiver- Spinel plus"

I can even see using irw (with X11 stopped) that latency or key repeat, i also tried to uncomment suppress key in lircd.conf
min_repeat 9
suppress_repeat 9

With this setting i have less repeating key but always latency, as far an example one key sometimes works, sometimes you have to re-press the key wich will proceed in 2 keys pressed...

A little bit frustrating :-(

Thanks for your help!!!

Please support my Blog, XBMC and Linux related :-)
http://youresuchageek.blogspot.com
find quote
Post Reply