[mythtvnz] Serial IR reciever Skystar 2 - lirc compatable

Nick Rout mythtvnz@lists.linuxnut.co.nz
Wed, 27 Jun 2007 12:10:50 +1200 (NZST)


On Wed, June 27, 2007 11:30 am, David Shepherd wrote:
>         Phil Bertram wrote:    On Wednesday 27 June 2007 9:25 am, Steve=
n
> Ellis wrote:           Phil Bertram wrote:                 Hi all,
>  I have  just purchased a Skystar 2 DVB-S card. The card comes
> with a remote and serial IR reciever.  The remote has a valid
> lircd.conf but I can not seem to get lirc working. I'm sure I have
> set all the permissions correctly. Following the instructions in
> the docs carefully. I have also compiled and tried many the other
> drivers that talk directly to /dev/ttyS0 with no luck.  $ irw Jun
> 15 11:32:28 pb lircd: lircd(serial) ready Jun 15 11:32:32 pb
> lircd: accepted new client on /dev/lircd Jun 15 11:32:32 pb lircd:
> could not open /dev/lirc Jun 15 11:32:32 pb lircd: default_init():
> No such device Jun 15 11:32:32 pb lircd: caught signal   Has
> anyone on the list got this reciever working with lirc ? Or, are
> my problems related to simple lack of support for this device in
> lirc.                 What distro are you using?           Debian
> (Etch)           I've played with this and not had an issue
> getting them going. I'll see if I can dig out a config.
> OK. The serial reciever that came with my Skystar2 card is purple
> in colour.  I'll assume it's the same one that you have played
> with and had success. I'll have another go, starting at the
> beginning.      I've just set up my 2 frontend boxes with purple
> serial receivers and Techisat remotes (kindly supplied by Steve).
>  I'm also running Debian Etch and managed to get them working.  They ar=
e
> switched off at the moment so I can't retrieve the /etc/lirc folder for
> you.
>  I recall that when installing the lirc-modules-source package it asks =
if
> you want it to try and build the modules for you.  This was a wrong tur=
n
> for me.  It build the modules OK and installed them but they weren't
> configured with the right build options so they didn't work.
>  I ran dpkg-reconfigure lirc-modules-source and set the correct options=
,
> cleaned up the build area, rebuilt and reinstalled (using m-a). Then I
> could at least check using irw that the hardware and drivers were
> working.  I'm happy to send you my conf files if you need them.
>
>  Dave

A common (and incidentally well documented) problem with any serial lirc
device is that you have to make sure that the kernel hasn't nabbed the
serial port.

Most kernel's have the normal serial driver built in so the serial port i=
s
automatically detected on boot and then lirc cannot use it. You can solve
this by either:

1. recompile your kernel either leaving the serial driver out at all, or
making it a module (as opposed to built in) and then setting up the syste=
m
to NOT load the module on boot; OR

2. hacking your startup scripts to run

setserial /dev/ttySx uart none (where ttySx is the port you are using)

before it loads the lirc serial driver.

Now this may not be your problem, but it may be too. Someone else
mentioned it in the thread and I thought I would expand a little. First
step might be to use dmesg to find out if the port has been nabbed by the
kernel.

dmesg |grep ttyS

should tell you, and

setserial /dev/ttySx (as root)

will tell you if that port is set up or not. Further reference may be mad=
e
here http://www.lirc.org/html/install.html - its a long page, searching i=
t
for setserial helps find the relevant material.

On the question of this particular remote, I have one, but have never use=
d
it. I do know however from something I saw recently that it may be
necessary to load lirc_serial with the parameter "type=3D3". as in:

modprobe lirc_serial type=3D3

I don't have the foggiest what this does, bet here is a list of the
possible parameters:

nick@media:~$ modinfo lirc_serial
filename:       /lib/modules/2.6.18-chw-13/misc/lirc_serial.ko
description:    Infra-red receiver driver for serial ports.
author:         Ralph Metzler, Trent Piepho, Ben Pfaff, Christoph Bartelm=
us
license:        GPL
vermagic:       2.6.18-chw-13 SMP preempt mod_unload 586 gcc-4.1
depends:
parm:           debug:Enable debugging messages (bool)
parm:           softcarrier:Software carrier (0 =3D off, 1 =3D on) (bool)
parm:           txsense:Sense of transmitter circuit (0 =3D active high, =
1 =3D
active low ) (bool)
parm:           sense:Override autodetection of IR receiver circuit (0 =3D
active high, 1 =3D active low ) (bool)
parm:           share_irq:Share interrupts (0 =3D off, 1 =3D on) (bool)
parm:           irq:Interrupt (4 or 3) (int)
parm:           io:I/O address base (0x3f8 or 0x2f8) (int)
parm:           type:Hardware type (0 =3D home-brew, 1 =3D IRdeo, 2 =3D I=
Rdeo
Remote, 3 =3D AnimaX, 4 =3D IgorPlug (int)




--=20
Nick Rout