[mythtv-users] ira-3 oem with knoppmyth

Alex VanDeusen alex.vandeusen at gmail.com
Fri Dec 29 01:11:14 UTC 2006

Hello I am trying to get a ira-3 oem serial device working. The
knoppmythwiki has a how to on setting up lirc with a section on setting
this device up but I cannot get it to work.  I also found a guide on
keeto.net and another person has a webpage but he didn't seem to get it
working either. 

This is really killing my WAF acceptance factor right now.  It is also
driving me quite batty.

I installed the hardware using the serial plug to com1 or /devttyS0.
The port is enabled in the bios.  irq4 0x3f8

The box is running as a frontend only with mysql and mythbackend

dmesg output shows the following:
Serial: 8250/16550 driver $Revision: 1.90 $ 4 ports, IRQ sharing
serial8250: ttyS0 at I/O 0x3f8 (irq = 4) is a 16550A
ACPI: PCI Interrupt Link [LNKB] enabled at IRQ 10
ACPI: PCI Interrupt 0000:00:14.5[B] -> Link [LNKB] -> GSI 10 (level,
low) -> IRQ

One thing that is interesting is that I also get a odd error message.
ttyS1: LSR safety check engaged!
ttyS1: LSR safety check engaged!

I dont have another com port physically so I am not sure about this one.

APIC is disabled and so is plug and play.  I am using a ATI IGP
motherboard RS480mil.  

So as I said I ran through these setup steps:

IRA-3 Universal Receiver HOWTO
I managed to get the IRA-3 Universal receiver up and running with a few
steps in R5A22 and R5A26. It tooks quite a bit of research and toying
around, so I figured I could write a quick summary of the final steps I
used to get things working.

1. apt-get remove lirc

2. wget

3. wget

4. tar -xvzpf libirman-0.4.3.tar.gz

5. tar -xvjpf lirc-0.8.0pre1.tar.bz2

6. cd libirman-0.4.3

7. edit irman.h and change the IR_HANDSHAKE_GAP? from 500 to 2000

"#define IR_HANDSHAKE_GAP? (2000 USEC)"

8. ./configure && make && make install

9. cd ../lirc-0.8.0pre1

10. ./setup.sh

11. Driver Configuration -> Other Serial Port Drivers -> IRMan/UIR

12. Save configuration and run configure

13. rm /dev/lirc

14. make && make install

15. edit /etc/init.d/bootmisc.sh and comment out the line (near the

setserial /dev/ttyS0 uart none
16. edit /etc/mythtv/modules/ivtv (assuming a pvr card ) and comment out
the line:

alias char-major-61lirc_i2c?
17. cd /etc/init.d

18. mv lirc lirc.default

19. update-rc.d lirc remove

20. cp reboot lirc

21. edit the new lirc startup script and change the line:

Rebooting... to Starting LIRC...
and the next line to:

/usr/local/sbin/lircd --device=/dev/ttyS0 --driver=irman

22. update-rc.d lirc defaults 20

23. I also changed some other things that shouldn't be nessesary, but
just in case they are...

I added alias char-major-61-0 lirc_serial to /etc/modutils/lirc

I the following constants in /etc/lirc/hardware.conf:



MODULES="lirc_dev lirc_serial"

24. Reboot

25. To check your ir codes, go into libirman-0.4.3 and run:

./test_io /dev/ttyS0
you can write down these codes and create your /etc/lirc/lircd.conf file
26. Set up your mythtv lirc commands by
editing /home/mythtv/.mythtv/lircrc

27. Reboot one more time and use your remote :)

So when the box boots I can see the red led flash so I know lirc is
doing something and the hardware seemingly works.

However the major issue I have is that when I try and do step 25.  

First of all I have to be root (not sure if this matters, I did the
install as root) I follow the step:

25. To check your ir codes, go into libirman-0.4.3 and run:

./test_io /dev/ttyS0

This is what I get:

root at mythtvfamilyfrontend:~/libirman-0.4.3# ./test_io /dev/ttyS0
error reading handshake (Connection timed out)
root at mythtvfamilyfrontend:~/libirman-0.4.3# 

If I press the remote when I do this the red led sees the keypresses
because it flashes but then it stops. 

I looked this up on the lirc mailing list and saw a post that means that
the its not receiving a reply and it could be the wrong port.  I think
its the right port and I tried to set it to the ttyS1 port but that
didnt matter. 

Looking into lircd I see the following:

Dec 28 13:43:54 mythtvfamilyfrontend lircd: lircd(irman) ready
Dec 28 13:44:12 mythtvfamilyfrontend lircd: accepted new client
on /dev/lircd
Dec 28 13:44:14 mythtvfamilyfrontend lircd: could not open /dev/ttyS0
Dec 28 13:44:14 mythtvfamilyfrontend lircd: irman_init(): Connection
timed out
Dec 28 13:44:14 mythtvfamilyfrontend lircd: caught signal

I am stuck at this point. I have some suspicions.  The default lircd
file is for the happauge grey remote.  I tried to use that but nothing
happens.  Lirc still cant communicate.  

When you compile lirc yourself it gets created
in /usr/local/sbin/lircd. 

I saw this post:

the startup script is different from the one I got here, but something
else is different as well.. 
by compiling it myself lirc has put its executables in /usr/local/sbin
instead of the regular /usr/sbin. weird, I specificly used --bindir. oh,
I see, should have used --sbindir... recompiling...

That file if I try to cat it has lots of garbled characters in it plus

I also have a lircd.conf file in /etc/lirc/ and one in /etc/ not sure if
this screws anything up.  I have the grey remote but I wanted to create
my own lirc.d file with my rca remote.

Also when I try to run the command

alexvd at mythtvfamilyfrontend:/etc$ /usr/local/sbin/lircd
--device=/dev/ttyS0 --driver=irman
lircd: can't open or create /var/run/lircd.pid
lircd: Permission denied. 

Running it from root seems to have no issues.

I am open for additional troubleshooting steps.  I think it is a serial
issue.  However I cannot figure out where to troubleshoot.

More information about the mythtv-users mailing list