I recently re-discovered my ATI Remote Wonder and decided to get it working under my Ubuntu Linux XBMC install.
First, install lirc. I selected the option to use the “ATI/NVidia/X10 I II RF Remote” with the kernel (Not userspace) driver, with no transmitter.
sudo apt-get install lirc
My /etc/lirc/lirc.conf file looks like:
My /etc/lirc/hardware.conf was generated automatically by debconf during the lirc install. However, for reference it is:
# /etc/lirc/hardware.conf # #Chosen Remote Control REMOTE="ATI/NVidia/X10 I REMOTE="None" II RF Remote" REMOTE_MODULES="lirc_dev lirc_atiusb" REMOTE_DRIVER="" REMOTE_DEVICE="/dev/lirc0" REMOTE_SOCKET="" REMOTE_LIRCD_CONF="atiusb/lircd.conf.atiusb" REMOTE_LIRCD_ARGS="" #Chosen IR Transmitter TRANSMITTER="None" TRANSMITTER_MODULES="" TRANSMITTER_DRIVER="" TRANSMITTER_DEVICE="" TRANSMITTER_SOCKET="" TRANSMITTER_LIRCD_CONF="" TRANSMITTER_LIRCD_ARGS="" #Enable lircd START_LIRCD="true" #Don't start lircmd even if there seems to be a good config file START_LIRCMD="false" #Try to load appropriate kernel modules LOAD_MODULES="true" # Default configuration files for your hardware if any LIRCMD_CONF="" #Forcing noninteractive reconfiguration #If lirc is to be reconfigured by an external application #that doesn't have a debconf frontend available, the noninteractive #frontend can be invoked and set to parse REMOTE and TRANSMITTER #It will then populate all other variables without any user input #If you would like to configure lirc via standard methods, be sure #to leave this set to "false" FORCE_NONINTERACTIVE_RECONFIGURATION="false"
Restart the lirc daemon and run irw and ensure there is output produced:
sudo /etc/init.d/lirc restart # * Starting remote control daemon(s) : LIRC irw # 000000144b760000 00 mouse-right_down SAPPHIRE_ATIUSB_5000023600 # 0000001446710000 00 mouse-right SAPPHIRE_ATIUSB_5000023600
Copy lirc & keymap configuration files into the user XBMC folder (If they do not exist).
#copy Lirc configuration file cd ~/.xbmc/userdata cp cp /usr/share/xbmc/system/Lircmap.xml . #copy remote.xml keymap cd ~/.xbmc/userdata/keymaps/ cp /usr/share/xbmc/system/keymaps/remote.xml .
Edit the XBMC LIRC Configuration File (Lircmap.xml) to contain the following key mappings, ensuring that the device matches the device output by irw.
<lircmap> <remote device="SAPPHIRE_ATIUSB_5000023600"> <play>play</play> <pause>pause</pause> <stop>stop</stop> <forward>forward</forward> <reverse>rewind</reverse> <left>left</left> <left>mouse-left</left> <right>right</right> <right>mouse-right</right> <up>up</up> <up>mouse-up</up> <down>down</down> <down>mouse-down</down> <select>ok</select> <select>mouse_button_left</select> <pageplus>chan-up</pageplus> <pageminus>chan-down</pageminus> <back>mouse_button_right</back> <menu>dvd-root_menu</menu> <title>a</title> <info>launch_setup</info> <skipplus>Skip</skipplus> <skipminus>Replay</skipminus> <display>max-window</display> <start>Start</start> <record>record</record> <volumeplus>vol-up</volumeplus> <volumeminus>vol-down</volumeminus> <mute>mute</mute> <power>power</power> <myvideo>dvd</myvideo> <mymusic>media_library</mymusic> <mypictures>Pictures</mypictures> <mytv>tv</mytv> <one>1</one> <two>2</two> <three>3</three> <four>4</four> <five>5</five> <six>6</six> <seven>7</seven> <eight>8</eight> <nine>9</nine> <zero></zero> <star>Star</star> <hash>Hash</hash> <clear>Clear</clear> <enter>Enter</enter> <red>Red</red> <green>Green</green> <yellow>Yellow</yellow> <blue>Blue</blue> <teletext>c</teletext> </remote> </lircmap>
Restart XBMC and you should now have ATI Remote support.
I spent considerable effort attempting to get The Lirc Mouse support working. However, I had no success. I found that X would recognize the LIRC mouse, but wouldn’t find an appropriate driver for it. In the end, I assigned the mouse buttons to the navigation keys via Lircmap.xml.
For the curious I will post the process that I used to get X to the point where it would detect the remote (according to the Xorg log).
The default settings for the lircm daemon wern’t creating the appropriate /dev/lircm which, I believe, prevents X from locating the mouse, so I had to take an alternative approach using the uinput module. It seems that this method has had limited success with others so perhaps it is a system configuration issue with me.
First I configured my
/etc/lirc/lircm.conf file with the following contents (the button presses determined from examining the output of irw):
# To find out how to get a proper configuration file please read: # # /usr/share/doc/lirc/README.Debian PROTOCOL IntelliMouse ACCELERATOR 2 30 5 ACTIVATE * ATI MOVE_N * mouse-up MOVE_S * mouse-down MOVE_W * mouse-left MOVE_E * mouse-right MOVE_NW * mouse-up-left MOVE_NE * mouse-up-right MOVE_SW * mouse-down-left MOVE_SE * mouse-down-right
Next I ensured that the START_LIRCMD value is FALSE in /etc/lirc/hardware.conf:
START_LIRCMD="false" #Make sure there isn't a trailing START_LIRCMD in your hardware.conf as there was in mine.
While experimenting I would load the uinput module manually, then start lircmd by hand – however, a working implementation would have uinput in /etc/modprobe.d so it loads automatically, and lircmd in something like rc.conf so it runs automatically.
#Make sure lircd is already running (see above) #load the module and start lircmd for testing: sudo modprobe uinput sudo lircmd --uinput
At this point you’re able to restart X and have it detect the lircm mouse. However, I never got it to properly load the drivers.