2011-12-29, 21:38
So for the last few days i've been trying to configure my Logitech Harmony One Universal Remote to work with every aspect of my XBMC-PVR system.
First a few things you'll have to know:
1. I use a Hauppauge WinTV Nova-S2 DVB-S2 tv-card for live TV, which comes with an IR-Receiver, so the hardware.conf for LIRC is pretty specific.
2. According to 1. I've setup my harmony one remote via the harmony remote software to Media-Center-PC > Hauppauge > WinTV Nova S2.
3. if you can already see output via irw (google it if you don't know what it is - i can't go into every detail, since i'm assuming you've been trying to get it to work for a while) these config files should be easy to adjust according to your needs
4. I use my A/V-Receiver for Volume control, so you won't find Volume buttons in this little HowTo
5. I just assume you have root privileges or know how to use sudo
So let's start:
First off, if you are using the same IR-Receiver as me you can use these config files (you probably still have to change REMOTE_DEVICE="/dev/input/event3" according to your needs. see below for instructions) :
/etc/lirc/hardware.conf
/etc/lirc/lircd.conf
if you are using a different Remote and a different IR Receiver you have to change the hardware.conf and you'll have make your own lircd.conf by recording every button on your remote via irrecord:
Setting up /etc/lirc/hardware.conf for your hardware IR receiver:
First you have to find out which /dev/input/event# handles your remote. you can find that information by using cat:
your output should look something like:
As you'll see my IR-Receiver uses /dev/input/event3 as his input device, so coming from the standard hardware.conf you should have after installing lirc (or after reconfiguring lirc with dpkg-reconfigure lirc and choosing none for both) you just have to make sure your input driver is set to "devinput" and your remote device is set to the /dev/input/event# device you got from cat /proc/bus/input/devices.
Now you should see input when using irw. you do? NICE!
Recording your remote buttons:
you can simply create your own /etc/lirc/lircd.conf by recordign every button on your remote and writing the recorded buttons into your /etc/lirc/lircd.conf. but who's got the time to write sooooooo much?
so we're going to fire up irrecord to do the job for us:
where event# is - of course - the event device you found out about earlier.
you should name the buttons according to your remote, makes the last steps much much easier.
First a few things you'll have to know:
1. I use a Hauppauge WinTV Nova-S2 DVB-S2 tv-card for live TV, which comes with an IR-Receiver, so the hardware.conf for LIRC is pretty specific.
2. According to 1. I've setup my harmony one remote via the harmony remote software to Media-Center-PC > Hauppauge > WinTV Nova S2.
3. if you can already see output via irw (google it if you don't know what it is - i can't go into every detail, since i'm assuming you've been trying to get it to work for a while) these config files should be easy to adjust according to your needs
4. I use my A/V-Receiver for Volume control, so you won't find Volume buttons in this little HowTo
5. I just assume you have root privileges or know how to use sudo
So let's start:
First off, if you are using the same IR-Receiver as me you can use these config files (you probably still have to change REMOTE_DEVICE="/dev/input/event3" according to your needs. see below for instructions) :
/etc/lirc/hardware.conf
Code:
#/etc/lirc/hardware.conf
#
#Chosen Remote Control
REMOTE="Hauppauge DVB-s card (ver. 2.1)"
REMOTE_MODULES="lirc_dev"
REMOTE_DRIVER="devinput"
REMOTE_DEVICE="/dev/input/event3"
REMOTE_SOCKET=""
REMOTE_LIRCD_CONF="hauppauge/lircd.conf.hauppauge"
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"
START_LIRCMD=""
/etc/lirc/lircd.conf
Code:
# Please make this file available to others
# by sending it to <[email protected]>
#
# this config file was automatically generated
# using lirc-0.8.6(devinput) on Wed Dec 28 23:31:32 2011
#
# contributed by
#
# brand: lircd.conf
# model no. of remote control:
# devices being controlled by this remote:
#
begin remote
name harmonyone
bits 16
eps 30
aeps 100
one 0 0
zero 0 0
pre_data_bits 16
pre_data 0x8001
gap 35995
toggle_bit_mask 0x0
begin codes
menu 0x008B
info 0x0184
exit 0x00AE
guide 0x016D
up1 0x0192
up2 0x0067
down1 0x0193
down2 0x006C
chanplus 0x0192
chanminus 0x0193
left 0x0069
right 0x006A
ok 0x001C
rewind 0x00A8
play 0x00CF
ffwd 0x00D0
skipminus 0x00A5
skipplus 0x0190
back 0x019C
record 0x00A7
pause 0x0077
stop 0x0080
1 0x0002
2 0x0003
3 0x0004
4 0x0005
5 0x0006
6 0x0007
7 0x0008
8 0x0009
9 0x000A
0 0x000B
plus 0x018E
e 0x0172
end codes
end remote
if you are using a different Remote and a different IR Receiver you have to change the hardware.conf and you'll have make your own lircd.conf by recording every button on your remote via irrecord:
Setting up /etc/lirc/hardware.conf for your hardware IR receiver:
First you have to find out which /dev/input/event# handles your remote. you can find that information by using cat:
Code:
cat /proc/bus/input/devices
your output should look something like:
Code:
I: Bus=0019 Vendor=0000 Product=0001 Version=0000
N: Name="Power Button"
P: Phys=PNP0C0C/button/input0
S: Sysfs=/devices/LNXSYSTM:00/LNXSYBUS:00/PNP0C0C:00/input/input0
U: Uniq=
H: Handlers=kbd event0
B: EV=3
B: KEY=100000 0 0 0
I: Bus=0019 Vendor=0000 Product=0001 Version=0000
N: Name="Power Button"
P: Phys=LNXPWRBN/button/input0
S: Sysfs=/devices/LNXSYSTM:00/LNXPWRBN:00/input/input1
U: Uniq=
H: Handlers=kbd event1
B: EV=3
B: KEY=100000 0 0 0
I: Bus=0017 Vendor=0001 Product=0001 Version=0100
N: Name="Macintosh mouse button emulation"
P: Phys=
S: Sysfs=/devices/virtual/input/input2
U: Uniq=
H: Handlers=mouse0 event2
B: EV=7
B: KEY=70000 0 0 0 0 0 0 0 0
B: REL=3
I: Bus=0001 Vendor=0070 Product=6906 Version=0001
N: Name="cx88 IR (Hauppauge WinTV-HVR400"
P: Phys=pci-0000:03:09.0/ir0
S: Sysfs=/devices/pci0000:00/0000:00:10.0/0000:03:09.0/input/input3
U: Uniq=
H: Handlers=kbd event3
B: EV=100003
B: KEY=100fc312 214a802 0 0 0 0 18000 41a8 4801 9e1680 0 0 10000ffc
I: Bus=0001 Vendor=10ec Product=0888 Version=0001
N: Name="HDA Digital PCBeep"
P: Phys=card0/codec#0/beep0
S: Sysfs=/devices/pci0000:00/0000:00:10.1/input/input4
U: Uniq=
H: Handlers=kbd event4
B: EV=40001
B: SND=6
As you'll see my IR-Receiver uses /dev/input/event3 as his input device, so coming from the standard hardware.conf you should have after installing lirc (or after reconfiguring lirc with dpkg-reconfigure lirc and choosing none for both) you just have to make sure your input driver is set to "devinput" and your remote device is set to the /dev/input/event# device you got from cat /proc/bus/input/devices.
Now you should see input when using irw. you do? NICE!
Recording your remote buttons:
you can simply create your own /etc/lirc/lircd.conf by recordign every button on your remote and writing the recorded buttons into your /etc/lirc/lircd.conf. but who's got the time to write sooooooo much?
so we're going to fire up irrecord to do the job for us:
Code:
irrecord -H devinput -d /dev/input/event# /etc/lirc/lircd.conf
where event# is - of course - the event device you found out about earlier.
you should name the buttons according to your remote, makes the last steps much much easier.