Kodi Community Forum

Full Version: Apple remote
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
I'm running Kubuntu 8.04 on a Mac Mini (Intel) and have everything xbmc-related working except the Apple IR remote. It's being recognized :
Quote:/dev/input/event5
bustype : BUS_USB
vendor : 0x5ac
product : 0x8240
version : 272
name : "Apple Mac mini infrared remote c"
phys : "/input0"
bits ev : EV_SYN EV_KEY EV_REP

But I'm stuck here. Does anyone have this remote working?
I'm not to read up on the configuration but I suspect LIRC will be your best bet.
here's conf for macmini which I think should work for Apple Remote
http://lirc.sourceforge.net/remotes/appl...nf.macmini
Do make sure you have lirc installed aswell.
Quote:sudo apt-get install lirc
After this you've changed your /etc/lirc/lircd.conf to this:
Quote:#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 Windows Media Center Remotes (new version Philips et al.) remote:
include /usr/share/lirc/remotes/apple/lircd.conf.macmini

Then restart and try to run the command
Quote:irw
int the terminal. if it is registering the button presses we can move on to configure XBMC according to this

Hope you get it working
/topfs2
Thanks, Topfs2. And congrats to you and your fellow team members for your work on this wonderful program.

I have lirc installed, but I'm deep in the weeds Smile

The remote seems to work (sorta) when the appleir module is loaded. At any rate when the remote's +/- keys are pressed an on-screen display for volume control appears and increments/decrements. This is _without_ lircd running.

Lircd starts but doesn't appear to be active. Irw returns nothing and seems to kill lircd as well!

Jeff
Then I suspect that appleir module is sending it's command as keyboard events.

Could you press all the buttons in a certain order and post your xbmc.log.
JeffElkins Wrote:I'm running Kubuntu 8.04 on a Mac Mini (Intel) and have everything xbmc-related working except the Apple IR remote. It's being recognized :


But I'm stuck here. Does anyone have this remote working?

The Apple IR Remote on the MacMini is similar to the IR on the AppleTV. for a Ubuntu 8.04 derivative (Kubuntu), it's pretty easy. See this page but ignore the steps for getting usbhid to see the device, the MacMini is already in usbhid.

http://code.google.com/p/atv-bootloader/...buntuHardy
keypresses
-----------
menu
play
back
forward
up
down

logfile: http://www.elkins.org/xbmc.log
davilla Wrote:The Apple IR Remote on the MacMini is similar to the IR on the AppleTV. for a Ubuntu 8.04 derivative (Kubuntu), it's pretty easy. See this page but ignore the steps for getting usbhid to see the device, the MacMini is already in subhid.

http://code.google.com/p/atv-bootloader/...buntuHardy

Thanks for the reply! I'm starting to feel pretty stupid, because I'm finding this anything but easy Sad

I read the instructions at the link:
Quote:Edit "/etc/modprobe.d/options" and add

options usbhid quirks=0x05ac:0x8241:0x10

Rebuild the initramfs so that the usbhid module options get propagated to the initramfs

sudo update-initramfs -u

Did that, then continued on to the link http://code.google.com/p/atv-bootloader/...teIRDriver and read the instructions there. Since 8.04 uses lirc .0.8.3, not 0.8.02, I didn't attempt any patching, I just rebooted with suggested lircd.conf files and tried irw again. I did try irw outside of X and then it does react to remote keypresses: returning "@^" and "[[^26", not any intelligible codes. Run during an xterm irw is silent.
Like I mentioned
Code:
options usbhid quirks=0x05ac:0x8241:0x10
it not needed, usbhid already knows about the MacMini device ID.

check for "/dev/usb/usbhid0", it that's present, the kernel sees your IR controller.

Next check "hardware.conf" and make the settings match the ones on the AppleTV page.

This tells lircd how to talk to your IR device.

Then "sudo /etc/init.d/lircd restart"

if lircd see the device and can talk with it then "ps -aux | grep lircd" should return an instance of the running lircd process.

sounds like lircd.conf is not correct. This tells Lircd how to decode your IR device.
davilla Wrote:Like I mentioned
Code:
options usbhid quirks=0x05ac:0x8241:0x10
it not needed, usbhid already knows about the MacMini device ID.

check for "/dev/usb/usbhid0", it that's present, the kernel sees your IR controller.

Next check "hardware.conf" and make the settings match the ones on the AppleTV page.

This tells lircd how to talk to your IR device.

Then "sudo /etc/init.d/lircd restart"

if lircd see the device and can talk with it then "ps -aux | grep lircd" should return an instance of the running lircd process.

sounds like lircd.conf is not correct. This tells Lircd how to decode your IR device.

Thank you for your patience. I rebuild my initrd.img, removing the option line that is not required. After a reboot, I have no /dev/usb/ subdir - find /dev/ -name "*hid0*" doesn't reveal anything either. However, ps does show an instance of lircd running.

Jeff
This is 8.04 Ubuntu variant with a 2.6.24 kernel? MacMini support should be present. The tip off is "/dev/usb/usbhid0", it that's present, the kernel knows and see the IR device. If absent, then the kernel usbhid device does not see it.

check dmesg and see what is says about IR or usbhid.


The correct device id should be "0x8240" for the MacMini and a correct modprobe option would be
Code:
options usbhid quirks=0x05ac:0x8240:0x10
davilla Wrote:This is 8.04 Ubuntu variant with a 2.6.24 kernel? MacMini support should be present. The tip off is "/dev/usb/usbhid0", it that's present, the kernel knows and see the IR device. If absent, then the kernel usbhid device does not see it.

check dmesg and see what is says about IR or usbhid.


The correct device id should be "0x8240" for the MacMini and a correct modprobe option would be
Code:
options usbhid quirks=0x05ac:0x8240:0x10

Success! I was running 2.6.22 until I worked out some vmware problems, but after
switching back to 2.6.24-17-generic I now have a /dev/usb/usbhid0. I used irrecord to create my own lircd.conf replacing the stock ubuntu file and the remote is now working with irw.
Ahh, that's why 2.6.22 does not have the modprobe usbhid quirks option.
Anyone have a pre-made Lircmap.xml for the apple remote?
Quote:<remote device="AppleRemote">
<select>play-pause</select>
<play>play-pause</play>
<pause>play-pause</pause>
<stop>play-pause</stop>
<forward>forward</forward>
<reverse>back</reverse>
<left>back</left>
<right>forward</right>
<up>plus</up>
<down>minus</down>
<menu>menu</menu>
</remote>

More progress. I have a partially working Lircmap.xml - as listed above I can scroll around the main screen options, but pressing the play-pause key when over a selection does not mimic the keyboard enter key or a mousepress.
Just as a side note, I remembered that I had an mceusb remote packed away in a closet. I hooked that up and had total support under XBMC on my intel mac mini. I'm going to use that in the living room where wife-friendliness is paramount. I'm still working on the apple remote for my home office machine (also a mac mini).
Pages: 1 2