Irdroid-Rpi infrared transceiver for Raspberry Pi
LIRC is a package that allows you to decode and send infra-red signals of many commonly used remote controls.
1. Install:
sudo apt-get install lirc
2. Setting:
In example I use Irdroid – Rpi infrared transceiver for Raspberry Pi
from http://www.irdroid.com/irdroid-rpi-infrared-transceiver
Add this to your /etc/modules file:
sudo nano /etc/modules
lirc_dev lirc_rpi gpio_in_pin=18 gpio_out_pin=17
My file:
# /etc/modules: kernel modules to load at boot time. # # This file contains the names of kernel modules that should be loaded # at boot time, one per line. Lines beginning with "#" are ignored. # Parameters can be specified after the module name. snd-bcm2835 i2c-bcm2708 i2c-dev w1-gpio w1-therm lirc_dev lirc_rpi gpio_in_pin=18 gpio_out_pin=17

3. Change your /etc/lirc/hardware.conf file to:
######################################################## # /etc/lirc/hardware.conf # # Arguments which will be used when launching lircd LIRCD_ARGS="--uinput" # Don't start lircmd even if there seems to be a good config file # START_LIRCMD=false # Don't start irexec, even if a good config file seems to exist. # START_IREXEC=false # Try to load appropriate kernel modules LOAD_MODULES=true # Run "lircd --driver=help" for a list of supported drivers. DRIVER="devinput" # usually /dev/lirc0 is the correct setting for systems using udev DEVICE="/dev/lirc0" MODULES="lirc_rpi" # Default configuration files for your hardware if any LIRCD_CONF="" LIRCMD_CONF="" ########################################################
4. Start using:
sudo /etc/init.d/lirc start
sudo /etc/init.d/lirc stop
5. Read RAW remote codes:
sudo lircd -d /dev/lirc0
mode2 -d /dev/lirc0
6 . Press any button your remote
7. Result:
space 5514491 pulse 8888 space 4396 pulse 576 space 570 pulse 555 space 529 pulse 557 space 551 pulse 567 ... ... ...