Single core Rasberry Pi boards probably work as well, but I don’t have any RPi A+ or B+ boards and the DAC board doesn’t fit the old header layout.
All that was needed was
- A few lines to the config.txt
- Turning ON
gpio22to disable mute
- A simple
alsa.confmodification to disable a warning.
- Small tweaks to the pianobar recipe from github.com/strassek/meta-aura
The gpio mute and alsa.conf changes are included in the
I didn’t use the meta-aura layer, but just added my own customized pianobar recipe to
For a quick-start on the
config.txt, rename or copy the sample
copy_boot.sh script used for SD card preparation will install the
config.txt if it finds one in the directory where it is run.
For speakers I’m using a pair of old Pioneer 8-ohm speakers from a broken CD player I had laying around. For a non-audiophile like me they are plenty good enough.
I’m sure the DAC board supports better speakers then these.
After boot, you should see this list of kernel modules loaded
root@rpi2:~# lsmod Module Size Used by nfc 56961 0 bluetooth 317426 2 rfkill 16877 2 nfc,bluetooth ipv6 340552 30 snd_soc_pcm512x_i2c 2091 1 evdev 10250 0 snd_soc_pcm512x 15525 1 snd_soc_pcm512x_i2c regmap_i2c 2668 1 snd_soc_pcm512x_i2c snd_soc_iqaudio_dac 2453 0 snd_soc_bcm2708_i2s 6584 2 regmap_mmio 3270 1 snd_soc_bcm2708_i2s i2c_bcm2708 4928 0 snd_soc_core 127441 3 snd_soc_pcm512x,snd_soc_iqaudio_dac,snd_soc_bcm2708_i2s snd_compress 7547 1 snd_soc_core bcm2835_gpiomem 2852 0 snd_pcm_dmaengine 3227 1 snd_soc_core snd_pcm 73316 4 snd_soc_pcm512x,snd_soc_core,snd_soc_iqaudio_dac,snd_pcm_dmaengine snd_timer 18168 1 snd_pcm snd 50967 4 snd_soc_core,snd_timer,snd_pcm,snd_compress uio_pdrv_genirq 2944 0 uio 8032 1 uio_pdrv_genirq
And you should see
gpio22 exported as an output with the value high to disable mute.
root@rpi2:~# ls /sys/class/gpio export gpio22 gpiochip0 unexport root@rpi2:~# cat /sys/class/gpio/gpio22/direction out root@rpi2:~# cat /sys/class/gpio/gpio22/value 1
Here are the devices
root@rpi2:~# aplay -l **** List of PLAYBACK Hardware Devices **** card 0: IQaudIODAC [IQaudIODAC], device 0: IQaudIO DAC HiFi pcm512x-hifi-0  Subdevices: 1/1 Subdevice #0: subdevice #0 root@rpi2:~# aplay -L null Discard all samples (playback) or generate zero samples (capture) default:CARD=IQaudIODAC IQaudIODAC, Default Audio Device sysdefault:CARD=IQaudIODAC IQaudIODAC, Default Audio Device front:CARD=IQaudIODAC IQaudIODAC, Default Audio Device
Make sure to run alsamixer once after start-up to enable the analog and digital outputs as described in the IQaudIO User Guide. If you don’t the digital output will default to the the maximum level which is too much for my speakers.
You can set your Pandora username and password in
/home/root/.config/pianobar/config to avoid having to enter them every time.
Make sure there is one space before and after the = and there are no spaces at the end of the lines. pianobar is picky about this.
pianobar from a console without any arguments.
It should just work.
I have the RPi audio system running headless in a corner of my office. I control pianobar (which also has volume controls) over an ssh session. This works for me since I spend most of my day in front of ssh terminal sessions.