Moving from lirc tools to rc-core tooling

The lirc project comes with a set of cli tools which have been used for years. rc-core has replacements for them. Here is a cheat-sheet to see how to use the rc-core tooling.

You’ll need the ir-ctl and ir-keytable tools. Both are in the v4l-utils package, except for debian and derivates, where you will also need the ir-keytable package as well as v4l-utils.

In a lirc world, you need to set up the lirc daemon to do almost anything. This is not true in the modern rc-core world; there is no daemon and the lirc daemon is not required. Do not install lirc-disable-kernel-rc.noarch on Fedora.

mode2

Simply run ir-ctl -r. From v4l-utils 1.18.0 onwards, this will give you a more concise output. If you do not like this run ir-ctl -r --mode2.

xmode2

There is no equivalent other than running ir-ctl -r on the command line. Having said that, xmode2 is totally broken anyway.

irxevent

With rc-core, there no reason to map from IR events to X events. rc-core events are regular input events already.

irsend

You can send IR using:

  • ir-ctl -s file
  • ir-ctl -S protocol:scancode, e.g. ir-ctl -S rc5:0x1e01
  • ir-ctl -K KEY_VOLUMEUP -k /lib/udev/rc_keymaps/hauppauge.toml

irrecord

Run ir-keytable -c -p all -t to see what your remote is sending will need to assembly the rc keymap by hand. There are various blog posts on this.

irexec

Since rc-core events are regular input events, a tool for executing commands on IR events should listen to regular linux input events. Shortcuts can be set up in your gnome environment, for example. Another example for headless execution is inputexec.

irw

You can test your setup with ir-keytable -t.

ircat

Either use ir-keytable -t or evtest.

irpty, lirc-make-devinput

Since rc-core events are regular input events, this is not needed at all in the new order.

irpipe, irtext2udp, lirc-init-db

lirc specific tools which make no sense in rc-core.

lirc-lsremotes

ls /lib/udev/rc_keymaps/

irsimreceive, irsimsend

rc-core does not have an explicit simulated code path, however there is an rc loopback device which you can load using modprobe rc-loopback. You can use this to test IR decoding and sending.