[mythtv] loading lirc kernel modules

D. Hugh Redelmeier hugh at mimosa.com
Sat Oct 7 19:14:24 UTC 2006


| From: D. Hugh Redelmeier <hugh at mimosa.com>

| Here are my proposed changes to /etc/rc.d/init.d/lircd (relative to
| the atrpms version for Fedora Core 5).  I've explained the changes
| that remove "daemon" in a message to the atrpms list (summary: they
| are redundant).

I was wrong about "daemon".  Axel straightened me out.  See
http://lists.atrpms.net/pipermail/atrpms-devel/2006-October/001259.html


| Have I got this right?  Is there a better way?

Here's a new stab at it.  But there may be a better way (see my next
message).  I'm not totally confident of the
echo/success/failure/RETVAL stuff, but it seems to match what other
things do.

===================================================================
RCS file: /etc/rc.d/init.d/RCS/lircd,v
retrieving revision 1.1
diff -u -r1.1 /etc/rc.d/init.d/lircd
--- /etc/rc.d/init.d/lircd	2006/10/07 00:36:33	1.1
+++ /etc/rc.d/init.d/lircd	2006/10/07 19:00:43
@@ -20,6 +20,16 @@
 RETVAL=0
 
 start(){
+	if [ ! -f /dev/lirc ] ; then
+		echo -n $"Installing lirc kernel modules: "
+		if modprobe char-major-61 ; then
+			success $"$base startup"
+		else
+                	failure $"$base startup"
+		fi
+		RETVAL=$?
+		echo
+	fi
 	if [ -f /etc/lircd.conf ]; then
 		echo -n $"Starting infrared remote control daemon: "
 		daemon lircd $LIRCD_OPTIONS
================ end of diffs ================

Here's what showed up on my console at boot time (note that I have
four tuner cards in this box):

Starting crond:                                            [  OK  ]
Installing lirc kernel modules: lirc_dev: IR Remote Control driver registered, at major 61
lirc_i2c: chip found @ 0x18 (Hauppauge IR)
lirc_dev: lirc_register_plugin: sample_rate: 10
lirc_i2c: chip found @ 0x71 (Hauppauge IR (PVR150))
lirc_dev: lirc_register_plugin: sample_rate: 10
lirc_i2c: chip found @ 0x6b (Adaptec IR)
lirc_dev: lirc_register_plugin: sample_rate: 10
lirc_i2c: chip found @ 0x6b (Adaptec IR)
lirc_dev: lirc_register_plugin: sample_rate: 10
                                                           [  OK  ]
Starting infrared remote control daemon:                   [  OK  ]

It seems to do what I needed to have done.  The remote works with
Myth.


More information about the mythtv-dev mailing list