lircd - LIRC daemon decodes infrared signals and provides them on a Unix domain socket.  


lircd [options] [config file]  


The main task of lircd is to decode the infrared signals and provide an uniform interface for client applications. Clients can connect to lircd through a Unix domain socket which is located in /var/run/lirc/lircd. Using this socket they will get the infrared codes received by lircd and they can send commands to lircd.



Common options:
-d, --device
Select the character device which lircd should read from. The default is currently /dev/lirc0 on most systems.
If you're using the dev/input driver, you can use name=STRING or phys=STRING to select the device; lircd will look in /dev/input to find a device with a matching description. This is useful in case the device name isn't fixed. STRING may contain the '*' and '?' wildcards and '\' to mark them as literal. Use dmesg(1) to find the name and bus address (the names used under /dev/input/by-id are not always usable).
-H, --driver
The driver to use. Using --driver help lists all available drivers, see DRIVER LOAD PATH beelow.
-h, --help
Displays short thelp message.
Other options:
-a, --allow-simulate
Enable the SIMULATE command which can be issued using irsend(1). This will allow simulating arbitrary IR events from the command line. Use this option with caution because it will give all users with access to the lircd socket wide control over you system. E.g. if you have configured your system to shut down by a button press on your remote control, everybody will be able to shut down your system from the command line.
-c, --connect [host[:port]]
Allows you to connect to other lircd servers that provide a network socket at the given host and port number. The number of such connections is currently limited to 100. The connecting lircd instance will receive IR events from the lircd instance it connects to.
-l, --listen [[address:]port]]
Let lircd listen for network connections on the given address/port. The default address is, which means that connections on all network interfaces will be accepted. The default port is 8765. No security checks are currently implemented. The listening lircd instance will send all IR events to the connecting lircd instances.
-L, --logfile
Select the lircd daemon log file. The default currently is /var/log/lircd. Note that this option will only be available if you compiled lircd without syslog support.
-o, --output <output socket>
Select Unix domain socket, which lircd will write remote key codes to. The default currently is /var/run/lirc/lircd.
-p, --permission
Gives the file permission of /var/run/lirc/lircd if it has to be created in octal representation. See chmod(1). If no --permission option is given when the socket is initially created the default is to give all users read and write permissions (0666 in octal representation). If /var/run/lirc/lircd already exists this option has no effect.
-p, --pidfile <path>
Select the lircd daemon pid file, defaults to /var/run/lirc/
-r, --release [suffix]
Enables automatic generation of release events for each button press.
 lircd will append the given suffix to the button name for each release event. If no suffix is given the default suffix is '_UP'.
-R, --repeat-max <limit>
Sets an upper limit to the number of repeats when sending a signal. The current default is 600. A SEND_START request will repeat the signal this many times. Also, if the number of repeats in a SEND_ONCE request exceeds this number, it will be replaced by this number.
-u, --uinput
Enable automatic generation of Linux input events. lircd will open /dev/input/uinput and inject key events to the Linux kernel. The key code depends on the name that was given a button in the lircd config file, e.g. if the button is named KEY_1, the '1' key code will be generated. You will find a complete list of possible button names in /usr/include/linux/input.h.


The config file for lircd is located in /etc/lirc/lircd.conf. lircd has its own log file in /var/log/lircd (beginning with LIRC version 0.6.1 you can configure lircd to use syslogd for log messages; then it depends on your system configuration where log messages will show up). You can make lircd reread its config file and reopen its log file by sending the HUP signal to the program. That way you can rotate old log files.  


lircd and lircmd are daemons. You should start them in some init script depending on your system. There are some example scripts for different distributions in the contrib directory. lircmd has to be started after lircd as it connects to the socket lircd provides.

If you start lircd or lircmd from your shell prompt you will usually get back immediately to the prompt. Often people think that the program has died. But this is not an error. lircd and lircmd are daemons. Daemons always run in background.  

[LIRC homepage]
The LIRC Manual, last update: 10-June-2014