(gdb) break *0x972

Debugging, GNU± Linux and WebHosting and ... and ...

Linux Infrared Remote Control (LIRC) architecture

A couple of years ago, I brought a USB remote control. Today, I would like to use it to control my Raspberry Pi, so that’s the occasion to explain LIRC architecture. It’s quite well organized, but not so easy to understand and get it working at the first try.

First of all, a quick overview of what we have to do:

(put a picture here)

  1. plug the receiver in a USB port (so far, so good :). Then, in the OS kernel:
  2. interface the USB port to talk with the device. Linux provides this service through linux/usb.h
  3. communicate with the receiver through its hardware (specific) protocol. LIRC lirc_atiusb kernel module does that.
  4. get the information from this driver and provide it to userland. LIRC lirc_dev kernel module does that.
  5. interpret this low level signals and execute user-defined commands. That the job of lircd and its configuration file .lircrc.

And there we are!