Showing posts with label cirruslogic. Show all posts
Showing posts with label cirruslogic. Show all posts

Thursday, April 7, 2016

Cirrus Logic driver

Building the raspberry pi code is documented at Kernel Building.  I wanted to start with stable linux 4.5 from git.kernel.org because the Cirrus Logic driver is in the mainline starting with v4.5.  But wanting quick results sent me to use a precompiled 4.1.19 kernel from Matthias "Hias" Reichl.
  There are lots of issues with getting the Cirrus Logic Audio Card working.  Hias has a version at RPi Linux driver for Wolfson / Cirrus Logic Audio Card

I used the precompiled version found there.

wget http://www.horus.com/~hias/tmp/cirrus/cirrus-linux-4.1.19.tgz
sudo tar zxf cirrus-linux-4.1.18.tgz -C /

Add the following lines to /boot/config.txt

dtoverlay=rpi-cirrus-wm5102
dtoverlay=i2s-mmap 
 
And add the following lines to /etc/modprobe.d/cirrus.conf

softdep arizona-spi pre: arizona-ldo1 
softdep spi-bcm2708 pre: fixed 
softdep spi-bcm2835 pre: fixed 


Rebooting and note this works.
dmesg | grep arizona
[    7.722414] arizona spi0.1: WM5102 revision C
 

aplay -l
**** List of PLAYBACK Hardware Devices ****
card 0: sndrpiwsp [snd_rpi_wsp], device 0: WM5102 AiFi wm5102-aif1-0 []
  Subdevices: 1/1
  Subdevice #0: subdevice #0
 

Thanks Hias!