Can the original (previously Wolfson) Cirrus Logic audio card be made to work with Volumio 3.449?

I’ve read through the V 3 Issues post and searched on Cirrus Logic, but found nothing recent. Don’t want to waste anyone’s time, not least my own, so just a simple “yes” or “no” to my subject question would be very helpful.

My zillion dollar AV receiver just blew up and while waiting to see if it can be repaired I hooked up an old marantz amp (no digital input) and got an old RPi3B+ out the loft. The Rpi has the Cirrus Logic audio card, but to my disappointment I find it isn’t recognised by Volumio. Since the CL card is pretty old now, I imagine if there was a way of using it it would have been found; or perhaps because it’s so old there’s been no demand. Hence my question as a starting point.

the Cirrus Logic Audio Card is not currently supported on Volumio, there is no entry for this HAT in the dacs.json file

if you’re willing to help providing the required information, I can help to add this HAT to the list

1 Like

in the meanwhile, you can have a look here

Thanks for such a speedy response, Darmur. Yes, I’d be very happy to help. Before I posted, while checking for relevant threads, I found a link to instructions for providing just this information - now I can’t find it again! I’ll wait on your guidance.

IIRC the Woflson card that I have could not be connected to a Pi3 without some soldering, it was for this reason I used a Pi1, where it plugs in simply. I even found a nice case on eBay to house the combined unit.
I should probably tidy up my guide because I started with mods to the json file but ended up not using them. I haven’t powered the unit up recently, I found the Pi1 too slow to be usable for Volumio, especially as I have a couple of x64 NUCs and Pi3s lying around.

I don’t recall having to do any soldering. Maybe it’s not a Pi3! I do know it’s a B+; was that a version of the 1 or 2 rather than the 3?

there are two versions of the Wolfson/Cirrus Audio card, one is for Raspberry Pi B+ (with 26-pin + 8-pin connectors), one is for newer RPis (with 40-pin connector)

image

1 Like

I’ll write you tomorrow with the instructions

  1. connect the SD-card to the PC
  2. open the file “userconfig.txt” with Notepad++ (under Windows) or with any text editor (under macOS or Linux)
  3. add the string “dtoverlay=cirrus-wm5102” on a new line and save
  4. insert the card on the Raspberry Pi, power it up and then follow the instructions from the initial post of this thread
  5. type the command “amixer controls” and paste the output (text or screenshot)

Hi,

From the images you posted yesterday I’m sure mine is the one in the bottom picture.

Here’s the info requested:

RaspberryPi B+

I2S DAC: Off

Welcome to Volumio for Raspberry Pi (5.10.92+ armv6l)
volumio@volumio-rpb:~$ aplay -l
**** List of PLAYBACK Hardware Devices ****
card 0: b1 [bcm2835 HDMI 1], device 0: bcm2835 HDMI 1 [bcm2835 HDMI 1]
  Subdevices: 4/4
  Subdevice #0: subdevice #0
  Subdevice #1: subdevice #1
  Subdevice #2: subdevice #2
  Subdevice #3: subdevice #3
card 1: Headphones [bcm2835 Headphones], device 0: bcm2835 Headphones [bcm2835 Headphones]
  Subdevices: 4/4
  Subdevice #0: subdevice #0
  Subdevice #1: subdevice #1
  Subdevice #2: subdevice #2
  Subdevice #3: subdevice #3
volumio@volumio-rpb:~$ amixer controls
numid=4,iface=MIXER,name='Master Playback Switch'
numid=3,iface=MIXER,name='Master Playback Volume'
numid=2,iface=MIXER,name='Capture Switch'
numid=1,iface=MIXER,name='Capture Volume'
volumio@volumio-rpb:~$ 

Looking at that output, I suspect I shouldn’t have run with I2S DAC = Off. But when I set up the Pi, having nothing in the presented list that corresponded to the Cirrus Logic card, I assumed I’d have to run without a DAC. Should I just choose the first one in the list and run the commands again?

the DAC must be connected to the Raspberry Pi to obtain the required information.

please run with I2S DAC set as OFF, but with the added line in userconfig.txt

I did add that line, and I’ve just checked that t was saved. BTW, I assume this is the file in the boot partition: /boot/userconfig.txt? It was an empty file when I opened it and now has just that one line in it.
I’m now wondering if the audio card has come loose inside the case. I’ll open it up and take a look.

with what program did you edit the /boot/userconfig.txt file?

gedit on a linux desktop (Manjaro Gnome)

I edited the file as you suggested from the desktop, but when I checked it I used ssh from the desktop into the pi.

I’ve checked the card is firmly attached, run the commands again, but got the same result.

editing from a linux system is fine, it’s not the problem

please make sure the connections are good

Yes, seems firmly attached. I’ve run the commands again, but same result.

Is there another command to check it’s seen by the OS?

PS When last used (years ago) it was definitely working. At that time I used Max2play as the OS and it recognised and deployed the card.

I think I’ve found the problem.

the dt-overlay has been renamed in the most recent kernels, for the kernel 5.10.x we use on Volumio, the name is the old one.

please edit the string on /boot/userconfig.txt as following

dtoverlay=rpi-cirrus-wm5102

and do again the procedure

Here we go:

volumio@volumio-rpb:~$ aplay -l
**** List of PLAYBACK Hardware Devices ****
card 0: b1 [bcm2835 HDMI 1], device 0: bcm2835 HDMI 1 [bcm2835 HDMI 1]
  Subdevices: 4/4
  Subdevice #0: subdevice #0
  Subdevice #1: subdevice #1
  Subdevice #2: subdevice #2
  Subdevice #3: subdevice #3
card 1: Headphones [bcm2835 Headphones], device 0: bcm2835 Headphones [bcm2835 Headphones]
  Subdevices: 4/4
  Subdevice #0: subdevice #0
  Subdevice #1: subdevice #1
  Subdevice #2: subdevice #2
  Subdevice #3: subdevice #3
card 2: RPiCirrus [RPi-Cirrus], device 0: WM5102 AiFi wm5102-aif1-0 [WM5102 AiFi wm5102-aif1-0]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
volumio@volumio-rpb:~$ amixer controls
numid=4,iface=MIXER,name='Master Playback Switch'
numid=3,iface=MIXER,name='Master Playback Volume'
numid=2,iface=MIXER,name='Capture Switch'
numid=1,iface=MIXER,name='Capture Volume'
volumio@volumio-rpb:~$ 

That seems to have got a result at last. Though no change from the amixer controls command - were you expecting something related to the audio card?

the amixer request was an attempt, not 100% required to have this HAT in the DAC list.

you should be able to use the HAT right now, keeping I2S DAC OFF and selecting the new entry from the drop-down selection.

Maybe you have to change the default control for volume or change something from Alasamixer to enable the SPDIF output. Please let me know, so I can move forward with creating a pull-request