drappleton
Posts: 10
Joined: Thu Sep 26, 2013 2:46 am

Infrared and irexec

Thu Sep 26, 2013 2:58 am

I've downloads LIRC and setup my remote. I do not have the file (irexec)needed to convert IR codes into "file calls".
I am running Raspbian. The directory etc/lirc/ does not have this file (irexec). Did I download it incorrectly?

Many thanks

ghans
Posts: 7882
Joined: Mon Dec 12, 2011 8:30 pm
Location: Germany

Re: Infrared and irexec

Thu Sep 26, 2013 8:35 am

What happens if you type irexec at the command-line ?
irexec is a executable program AFAIK.

ghans
• Don't like the board ? Missing features ? Change to the prosilver theme ! You can find it in your settings.
• Don't like to search the forum BEFORE posting 'cos it's useless ? Try googling : yoursearchtermshere site:raspberrypi.org

mba
Posts: 110
Joined: Fri Jun 08, 2012 7:05 pm
Location: Denmark

Re: Infrared and irexec

Thu Sep 26, 2013 7:23 pm

Hi,

irexec is part of the LIRC package. Did you install it by calling:
sudo apt-get install lirc
Using irexec you need to create an .lircrc file and place it in your home folder like ~/.lircrc. Or you can create a lircrc and put it in /etc/lirc/

You should take a look at the fileformat of lircrc here http://www.lirc.org/html/configure.html

Br.
Martin
AMOTE - a LIRC client for Android. Build your own Android-based universal remote.

User avatar
FTrevorGowen
Forum Moderator
Forum Moderator
Posts: 5590
Joined: Mon Mar 04, 2013 6:12 pm
Location: Bristol, U.K.
Contact: Website

Re: Infrared and irexec

Thu Sep 26, 2013 8:12 pm

FWIW, Notes on my, somewhat brief, foray into "IR Remote Control" can be found at: http://www.cpmspectrepi.webspace.virgin ... board.html
They include links to the "setup guide" I followed/adapted and some example lircd????.conf files I was able to generate.
Trev.
Still running Raspbian Jessie or Stretch on some older Pi's (an A, B1, 2xB2, B+, P2B, 3xP0, P0W, 2xP3A+, P3B+, P3B, B+, and a A+) but Buster on the P4B's. See: https://www.cpmspectrepi.uk/raspberry_pi/raspiidx.htm

drappleton
Posts: 10
Joined: Thu Sep 26, 2013 2:46 am

Re: Infrared and irexec

Thu Sep 26, 2013 11:26 pm

ghans wrote:What happens if you type irexec at the command-line ?
irexec is a executable program AFAIK.

ghans

Interesting that it does know the directory where the file should be located (when I try to run the *.exe)

pi@raspberrypi ~ $ sudo irexec
irexec: could not open config files /root/.lircrc and /etc/lirc/lirc/lircrc
irexec: No such file or directory

drappleton
Posts: 10
Joined: Thu Sep 26, 2013 2:46 am

Re: Infrared and irexec

Fri Sep 27, 2013 1:35 am

mba wrote:Hi,

irexec is part of the LIRC package. Did you install it by calling:
sudo apt-get install lirc
Using irexec you need to create an .lircrc file and place it in your home folder like ~/.lircrc. Or you can create a lircrc and put it in /etc/lirc/

You should take a look at the fileformat of lircrc here http://www.lirc.org/html/configure.html

Br.
Martin

I did do this and when I do it again, it states that LIRC is already newest version:

sudo apt-get install lirc
Reading package lists... Done
Building dependency tree
Reading state information... Done
lirc is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 23 not upgraded.

Maybe I should uninstall then re-install it? Is irexec out there as an application that I can just put on my board?

drappleton
Posts: 10
Joined: Thu Sep 26, 2013 2:46 am

Re: Infrared and irexec

Fri Sep 27, 2013 2:44 am

FTrevorGowen wrote:FWIW, Notes on my, somewhat brief, foray into "IR Remote Control" can be found at: http://www.cpmspectrepi.webspace.virgin ... board.html
They include links to the "setup guide" I followed/adapted and some example lircd????.conf files I was able to generate.
Trev.

This is getting interesting. I've put a new SD card in an attempt to redo everything including installing LIRC.

After this new install (on a clean SD card) the directory:
etc\lirc\
Still does not contain the executable: irexec
I am running the raspbian OS. Should I run a different OS to get this EXE file?

drappleton
Posts: 10
Joined: Thu Sep 26, 2013 2:46 am

Re: Infrared and irexec

Fri Sep 27, 2013 3:21 am

Shouldn't the application called be in \root\etc\lirc\

drappleton
Posts: 10
Joined: Thu Sep 26, 2013 2:46 am

Re: Infrared and irexec

Fri Sep 27, 2013 3:53 am

I've had the IR interface working. I've recorded codes for my remote. If I am unable to find the application irexec is there a different way that I can have button presses trigger an event?

Dilligaf
Posts: 283
Joined: Wed May 23, 2012 6:48 pm

Re: Infrared and irexec

Fri Sep 27, 2013 4:58 am

You have irexec on your system, you need to add the config files to /etc/lirc, run the command

Code: Select all

which irexec
and it will tell you where it is, if it doesn't then run the command with sudo

drappleton
Posts: 10
Joined: Thu Sep 26, 2013 2:46 am

Re: Infrared and irexec

Fri Sep 27, 2013 5:30 am

ednl wrote:
drappleton wrote:pi@raspberrypi ~ $ sudo irexec
irexec: could not open config files /root/.lircrc and /etc/lirc/lirc/lircrc
irexec: No such file or directory
Read what it says: irexec runs but can't open the config files. You need to create one or both. Any reason you're using sudo?

Thank you! "Read what it says"
:)
I was looking for the actual application, but it is in fact running (from somewhere).

I need to see what's on with my config file (I have set them up but not in this directory).

I don't remember why I ran as Superuser.

Many thanks again.

ghans
Posts: 7882
Joined: Mon Dec 12, 2011 8:30 pm
Location: Germany

Re: Infrared and irexec

Fri Sep 27, 2013 6:49 am

I agree with ednl.

By the way:
The reason that you can execute most commands from anywhere
without specifying the full path is that there are common
directories for programs under Linux just as under Windows
("C:\Program Files" vs /usr/bin , /usr/local/bin etc.) and that
they are searched for matching executables.

You can decide which directories are searched for commands
via manipulating the PATH variable (the so-called search path).

/usr/bin and /usr/local/bin should already be included in that
variable , along with other directories.

Long-standing DOS users might remember this , too ...
http://en.m.wikipedia.org/wiki/PATH_(variable)


ghans
• Don't like the board ? Missing features ? Change to the prosilver theme ! You can find it in your settings.
• Don't like to search the forum BEFORE posting 'cos it's useless ? Try googling : yoursearchtermshere site:raspberrypi.org

Return to “Interfacing (DSI, CSI, I2C, etc.)”