No subject


Mon May 17 17:55:34 UTC 2010


Download the main driver package and the precompiled lirc.

Run sudo dpkg -i on both files.

Make sure that you've got libusb 1.0 installed.

The the various config files I have:


# cat /etc/default/iguanaIR
## The IguanaWorks daemon (igdaemon) as a few common-line options that
## are configured here.

## There are multiple logging levels for igdaemon
## 0 =3D normal
## 1 =3D log info
## 2 =3D log debug1
## 3 =3D log debug2 (excessive)
## 4 =3D log debug3 (excessively excessive)
LOGLEVEL=3D0

## Because of a bug in libusb, using threads when communicating with
## our device can cause the device to hang. As a work around, we have
## an option to disable using threads. This option may cause problems
## when sending long IR signals and will take a slightly larger amount
## of overhead on your computer. Unless you have problems with the
## threadless version, we recommend using it for increased stability.
## The option to disable threads is:
## "--no-threads"

## Uncomment the line below to disable threads
#OPTIONS=3D"--no-threads"

## If you enable threads, then you can decrease the receive timeout
## because it does not limit how quickly you can send. It does limit
## how quickly you can quit the daemon. With threads enabled, we set
## this timeout to 1000ms. With threads disabled, we put the timeout
## at 50ms. You can use a larger value if you want to save a little
## amount of cpu time, but it may cause problems with sends,
## particularly long send.

## With the --no-threads option used
#RECEIVETIMEOUT=3D50

## When threads are used (and not --no-threads)
RECEIVETIMEOUT=3D1000

## the igdaemon can use different backend USB drivers and should be
## told which to try first since we prefer the libusb driver to the
## libusbpre1.0
DRIVERS=3D--driver=3Dlibusb

## You can set the timeout value for sendings IR signals. This set how
## long to wait for send to successfully complete before assuming that
## the send failed and returning an error. Time is measured in ms and
## the default is 1000. Do not change this unless you have good
## reason.
SENDTIMEOUT=3D1000

## The init.d script for igdaemon auto detects what distro you are
## using (fedora, debian, ubuntu, gentoo). You can overwrite this
## detection by uncommenting one of the lines below. If your distro is
## not detected, please send a ticket to:
## http://iguanaworks.net/projects/IguanaIR/
## Including your distribution and the entire contents of /etc/issue.
## We will try to add support for your distro in the next release. In
## the meantime, maybe try some of the other distro overrides.
#DISTRO=3Dfedora
#DISTRO=3Ddebian
#DISTRO=3Dubuntu
#DISTRO=3Dgentoo


root at mbe:/etc/lirc# cat hardware.conf
# /etc/lirc/hardware.conf
#
#Chosen Remote Control
REMOTE=3D"None"
REMOTE_MODULES=3D""
REMOTE_DRIVER=3D""
REMOTE_DEVICE=3D""
REMOTE_LIRCD_CONF=3D""
REMOTE_LIRCD_ARGS=3D""

#Chosen IR Transmitter
TRANSMITTER=3D"None"
TRANSMITTER_MODULES=3D""
TRANSMITTER_DRIVER=3D"iguanaIR"
TRANSMITTER_DEVICE=3D"/dev/iguanaIR/0"
TRANSMITTER_LIRCD_CONF=3D""
TRANSMITTER_LIRCD_ARGS=3D""

#Enable lircd
START_LIRCD=3D"true"

#Don't start lircmd even if there seems to be a good config file
#START_LIRCMD=3D"false"

#Try to load appropriate kernel modules
LOAD_MODULES=3D"true"

# Default configuration files for your hardware if any
LIRCMD_CONF=3D""

#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=3D"true"
START_LIRCMD=3D""
REMOTE_SOCKET=3D""
TRANSMITTER_SOCKET=3D""


root at mbe:/etc/lirc# cat 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.

#
# To find out how to get a proper configuration file please read:
#
#       /usr/share/doc/lirc/README.Debian
#
# this config file was originally generated
# using lirc-0.6.6(serial) on Fri Mar 28 22:46:44 2003
# modified by hand on Sunday Jul 17 00:12:00 2005
#
# contributed by rob scullion
# based on the DCT2000 file contrib'd by shane bradley
#
# brand:                       Motorola
# model no. of remote control: ? - Comcast badged
# devices being controlled by this remote: DCT2524/1612
#
# Note: The "ON DEMAND" button on the Comcast
# badged remote just sends a "1" followed by
# an "ok/select" and is thus not included in
# this config file.

begin remote
 name  DCT2524
  bits             16
  flags SPACE_ENC|CONST_LENGTH
  eps              30
  aeps            100

  header         9036  4424
  one             556  2185
  zero            556  4424
  ptrail          556
  gap          100025
  toggle_bit        0


      begin codes
          power                    0x000000000000AFF9
          rew                      0x00000000000087F7
          play                     0x00000000000027FD
          ffwd                     0x00000000000047FB
          stop                     0x000000000000C7F3
          pause                    0x00000000000007FF
          rec                      0x00000000000073FC
          skipback                 0x000000000000C3F7
          mydvr                    0x00000000000043FF
          live                     0x00000000000083F0
          pageup                   0x000000000000A3F3
          pagedown                 0x00000000000023FB
          a_lock                   0x00000000000097F6
          b_day-                   0x00000000000063FD
          c_day+                   0x000000000000E3F5
          up                       0x000000000000D3F6
          down                     0x00000000000053FE
          left                     0x00000000000093F1
          right                    0x00000000000013F9
          ok/select                0x00000000000077F8
          guide                    0x000000000000F3F4
          info                     0x00000000000033FA
          menu                     0x00000000000067F9
          exit                     0x000000000000B7F4
          help                     0x000000000000B3F2
          last                     0x00000000000037FC
          vol+                     0x0000000000004FF3
          vol-                     0x0000000000008FFB
          mute                     0x0000000000000FF7
          fav                      0x00000000000057FA
          ch+                      0x0000000000002FF5
          ch-                      0x000000000000CFFD
          1                        0x0000000000007FF0
          2                        0x000000000000BFF8
          3                        0x0000000000003FF4
          4                        0x000000000000DFFC
          5                        0x0000000000005FF2
          6                        0x0000000000009FFA
          7                        0x0000000000001FF6
          8                        0x000000000000EFFE
          9                        0x0000000000006FF1
          0                        0x000000000000FFFF
          tv/vcr_input             0x000000000000D7F2
          hdzoom_enter             0x000000000000FDFC
          pnp-swap                 0x0000000000003BF2
      end codes

# cd /etc/rc2.d
root at mbe:/etc/rc2.d# ls -l
total 4
-rw-r--r-- 1 root root 677 2010-03-30 02:17 README
lrwxrwxrwx 1 root root  18 2010-04-19 00:45 S20iguanaIR -> ../init.d/iguana=
IR
lrwxrwxrwx 1 root root  27 2010-04-18 22:47 S20nfs-kernel-server ->
../init.d/nfs-kernel-server
lrwxrwxrwx 1 root root  15 2010-04-18 22:37 S21aumix -> ../init.d/aumix
lrwxrwxrwx 1 root root  14 2010-04-18 22:37 S22lirc -> ../init.d/lirc
lrwxrwxrwx 1 root root  13 2010-04-18 22:37 S23ntp -> ../init.d/ntp
lrwxrwxrwx 1 root root  19 2010-04-18 22:37 S25bluetooth -> ../init.d/bluet=
ooth
lrwxrwxrwx 1 root root  22 2010-04-19 00:15 S40dhcp3-server ->
../init.d/dhcp3-server
lrwxrwxrwx 1 root root  15 2010-04-18 22:37 S50rsync -> ../init.d/rsync
lrwxrwxrwx 1 root root  19 2010-04-18 22:37 S70dns-clean -> ../init.d/dns-c=
lean
lrwxrwxrwx 1 root root  18 2010-04-18 22:37 S70pppd-dns -> ../init.d/pppd-d=
ns
lrwxrwxrwx 1 root root  17 2010-04-18 22:37 S91apache2 -> ../init.d/apache2
lrwxrwxrwx 1 root root  22 2010-04-18 22:37 S99acpi-support ->
../init.d/acpi-support
lrwxrwxrwx 1 root root  21 2010-04-18 22:37 S99grub-common ->
../init.d/grub-common
lrwxrwxrwx 1 root root  18 2010-04-18 22:37 S99ondemand -> ../init.d/ondema=
nd
lrwxrwxrwx 1 root root  18 2010-04-18 22:37 S99rc.local -> ../init.d/rc.loc=
al
root at mbe:/etc/rc2.d#

end remote
root at mbe:/etc/lirc#

#cd /usr/local/bin
root at mbe:/usr/local/bin# cat change-channel-lirc.pl
#!/usr/bin/perl

# make sure to set this string to
# the corresponding remote in /etc/lircd.conf
$remote_name =3D "DCT2524";

sub change_channel {
        my($channel_digit) =3D @_;
        system ("/usr/bin/irsend SEND_ONCE $remote_name $channel_digit");
print "Transmitted digit " . $channel_digit . "\n";
        sleep 1;
}

$channel=3D$ARGV[0];
print "Channel is " . $channel . "\n";
print "Sending exit\n";
system ("/usr/bin/irsend SEND_ONCE $remote_name exit");
sleep 1;
if (length($channel) > 2) {
        change_channel(substr($channel,0,1));
        change_channel(substr($channel,1,1));
        change_channel(substr($channel,2,1));
} elsif (length($channel) > 1) {
        change_channel(substr($channel,0,1));
        change_channel(substr($channel,1,1));
} else {
        change_channel(substr($channel,0,1));
}
print "Transmitting select\n";
system ("/usr/bin/irsend SEND_ONCE $remote_name ok/select");
print "Done\n";


I use the above change_channel script to verify that the IR is being pulsed=
.

Anyway, it works for me, without needing to compile.

I've also pretty much pasted the above as a bug against Ubuntu lirc

https://bugs.launchpad.net/ubuntu/+source/lirc/+bug/153457


More information about the mythtv-users mailing list