Hi,
A couple of month agi I decided to create my own mini Airplay station based on a Raspberry Pi with an additional functionality . The RPi 2 B+ will also be able to control my amp Marantz through IR (ener314-ir)
I manage to build all in one piece and solder on the top of the Hifiberry Dac a support to plug the IR.
Before installing lirc it is important to update your linux distribution.
sudo apt-get update
sudo apt-get upgrade
Then I installed the lirc library
sudo apt-get install lirc
After having installed the lirc library I lost my time trying to setup and see if my IR was working but I found after that one file was missing and one way to solve that was to upgrade the RPI firmware.
I did it.
sudo apt-get install rpi-update
Once this last step is finished which could take a bit of time time you can easily setup your RPI.
Here is below my first configuration without the hifiberry DAC connected and it works. I manage to send some commands to my computer with success
I use the Apple remote configuration available here, Apple A1156
sudo irsend SEND_ONCE Apple_A1156 KEY_PLAY
As soon as I change the value of gpio_in_pin and gpio_out_pin it stops to work and I don’t understand why. Do you have an idea?
With the below configuration it worked but only once. I rebooted and then nothing.
gpio_in_pin=11
gpio_out_pin=8
File: /boot/config.txt
gpu_mem=16
hdmi_drive=2
dtoverlay=lirc-rpi,gpio_in_pull=up,gpio_in_pin=18,gpio_out_pin=17
dtoverlay=hifiberry-dacplus
File: /etc/modules
lirc_dev
lirc_rpi gpio_in_pin=18 gpio_out_pin=17
File: /etc/lirc/hardware.conf
[code]
/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=“default”
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=""[/code]
Quick test to check if your library is properly installed.
volumio@volumio:~$ dmesg | grep lirc_rpi
[ 4.755171] lirc_rpi: module is from the staging directory, the quality is unknown, you have been warned.
[ 4.915277] pinctrl-bcm2835 3f200000.gpio: pin gpio18 already requested by lirc_rpi; cannot claim for 3f203000.i2s
[ 5.764495] lirc_rpi: auto-detected active high receiver on GPIO pin 17
[ 5.773851] lirc_rpi lirc_rpi: lirc_dev: driver lirc_rpi registered at minor = 0
[ 5.785751] lirc_rpi: driver registered!
A youtube video which help me to get it done this fun project.
[youtube]https://www.youtube.com/watch?v=QV_QmDKx0kQ[/youtube]