(Linux) LIRC location Problems - Over My Head
#1
Hello again.

(Running Ubuntu 10.4 & xbmc 10.0 Beta2 r33778 Compiled Sep 14)


Little history: I've been working on my remote for 3 days. I couldn't get it to work in live or in ubuntu. After much reading I found this post http://www.mythtv.org/wiki/MCE_Remot...ding_using_CVS. I followed the directions and installed irc-0.8.7pre2 and got it working. Now when I use sudo irw i get back ...37ff07be9 00 Play mceusb. (and so on) Good news Right! I made sure I had Lircmap.xml in the userdata folder with mceusb as the remote name.

But, I still can't get it to work in XBMC. In the log I see...
LIRC Initialize: using /dev/lircd
LIRC Initialize: connection failed: No such File or directory

So my guess is I need to change the location xbmc is looking for Lircd (if available) I didn't see anything about it on the advancedsettings.xml page. Or, I need to redo my Lirc install to the location that matches XBMC.
After a seach I have two Lircd, one at /usr/local/sbin and one at /usr/src/lirc.0.8.7pre2/daemons.

Also, I double check the lircd.conf and it lists three remote types, one after the other, is that right or should I delete everything NOT under mceusb?

By the way I always have to use sudo before running irw, is that normal, right? I also need to autoload lirc_mceusb2 at startup. Can anyone tell me how to do that?

I know almost nothing about linux, so please go easy.
Reply
#2
lennon105 Wrote:But, I still can't get it to work in XBMC. In the log I see...
LIRC Initialize: using /dev/lircd
LIRC Initialize: connection failed: No such File or directory

So my guess is I need to change the location xbmc is looking for Lircd (if available) I didn't see anything about it on the advancedsettings.xml page. Or, I need to redo .

1. start xbmc with
Code:
/usr/lib/xbmc/xbmc.bin -l /var/run/lirc/lircd ...
or
2. start lirc with
Code:
lircd -o /dev/lircd ...
greetings, Stephan

Image

Image
Reply
#3
http://www.mythtv.org/wiki/MCE_Remote#Do..._using_CVS - Here it is, your link didnt work above

Does
Code:
ls /dev/
give anything lirc related?

Does
Code:
ls /var/run/
give anything lirc related?

Does
Code:
ls /var/run/lirc/
give anything lirc related?

What is in your /etc/lirc/hardware.conf?

Other than that try stopping lirc
Code:
sudo /etc/init.d/lirc stop

and running it with no daemon

Code:
sudo lircd --nodaemon
use lircd --help if you need


EDIT: openelec.tv beat me to it. I agree with him/her -> /var/run/lirc is probably where it is. You can also symlink the two with
Code:
sudo ln -s /var/run/lirc/lircd /dev/lircd
Reply
#4
Hi

1. start xbmc with
Code:

/usr/lib/xbmc/xbmc.bin -l /var/run/lirc/lircd ...

This did nothing.

2. start lirc with
Code:

lircd -o /dev/lircd ...

I had to add sudo to the front but got back this....
lircd: there seems to already be a lircd process with pid 5404
lircd: otherwise delete stale lockfile /var/run/lirc/lircd.pid


How do I stop lirc, should i just re-boot?

Thanks so much for helping.
Reply
#5
read above
Code:
sudo /etc/init.d/lirc stop
Reply
#6
Nick

I did this....

Code:

sudo ln -s /var/run/lirc/lircd /dev/lircd

Now I get a permission denied in the xbmc log. I was worried about that.

Also, I did see the stop command and tried it and got back
command not found
Reply
#7
sudo nautilus /var/run/lirc

sudo nautilus /dev/

right click > properties > make permissions same for both
Reply
#8
YOU THE BEST.... Thanks SO MUCH

It works now. i think I only need to autoload lirc_mceusb2 at startup. can you tell me how to do thatHuh Do I have to worry about loosing any other settings after a reboot?

THANKS AGAIN.
Reply
#9
I'm not sure about autoloading the modules. I believe it should be in your /etc/lirc/hardware.conf

/etc/init.d/lirc doesn't exist? you are just running lircd manually?

The symlink probably wont be there on startup. I only use it as a temporary fix for xbmc not using /var/run/lirc/lircd (even when specified with -l). I don't reboot very often so i haven't been worried about figuring out a proper solution. I made a bash script but couldn't get it to run as root on startup (with crontab or in /etc/rc.local) for some reason so I gave up.

Hopefully others will chime in with a better solution.
Reply
#10
I have no idea how I'm running lircd. I did reboot hopping to get it installed by the tv and now it doesn't work again. I'll have to see what steps I need to re-do to get everything running again.

As you can see I don't understand this 100%. I'm afread I
ll have to start back at http://www.mythtv.org/wiki/MCE_Remote#Do..._using_CVS with the build. I must be missing a step. I'll take any help you can give.
Reply
#11
try

Code:
modprobe lirc_mceusb2
lircd --nodaemon

if irw doesnt work, in the lirc terminal window press ctrl+c

lircd --help (will give you a list of options you can use when running lircd - READ ALL OF THIS and if there is an option your dont understand search for it lircs website)

complete the following command to suit your device
Code:
sudo lircd -n --driver=mceusb2 --device=/dev/ttyUSB1 --output=/var/run/lirc/lircd --pidfile=/var/run/lirc/lircd.pid

obviously once irw is working you just symlink again.

also check whats in here /etc/conf.d/

and finally, extra buttons in lircd.conf shouldnt matter but its handy to keep it clean with only buttons you need.

ALSO: According to this, the lirc device xbmc looks for can be configured at build time ie compiling from svn (I haven't tested to see if this method works.)

Revision 30976, 5.8 KB (checked in by anssih, 4 months ago)

added: configure option for specifying default LIRC device

The default LIRC device location was changed in LIRC 0.8.6 from
/dev/lircd to /var/run/lirc/lircd. Add --with-lirc-device=file
configure option to select the default device location at build time.
This can still be overridden at run time.

/dev/lircd is kept as the XBMC default for now.
Reply

Logout Mark Read Team Forum Stats Members Help
(Linux) LIRC location Problems - Over My Head0