Raspberry with sound card, no audio output

Hello,

I am trying to use Ardour on a Raspberry Pi 3B+, with my Focusrite Scarlett 18i8.
I have some instruments connected to the soundcard and can capture them in Ardour fine. But somehow, even though the master channel shows some audio level, I have no audio coming out of the soundcard.

It is now few days that I am trying to solve this problem and I am very confused. I managed to make it work once or twice but it was just temporary and after the next reboot, the problem was back.

I am able to reproduce this problem from a fresh install of Raspberry OS, where I only install Ardour. I am using Ardour builtin ALSA driver and do not mess with anything else.

Screenshot 2021-11-24 103859

I check the audio connections inside Ardour and they should be fine:

  • Hardware inputs goes to Ardour tracks
  • Ardour tracks goes to Ardour master bus
  • Ardour master bus goes to hardware output

I tried to reproduce the same on my Windows computer and it works just fine.
Anyone has an idea what I could be doing wrong?

Cheers,

Hello, could you post a screenshot of your Audio Connection Manager on the Raspberry Pi (Alt+P or Window - Audio Connections)? And then with Ardour Busses on the y-axis and Hardware on the x-axis. And did you try different sample rates?

Best,

Jeremy

Sure, this is what I have. Right now I only setup one track, which is connected to the Input 5 of the soundcard.

I tried with both 44.1kHz and 48kHz and the result is the same.

Thanks! That looks like it should really work. Nothing in the system logs on the Raspberry Pi (/var/log/syslog)? And how are you powering the Raspberry Pi? Is the power adapter powerful enough? If not this could cause weird behavior.

I am not sure what to look for in the system logs.
Here is what happens when I power the sound card on:

Nov 24 14:13:54 raspberrypi kernel: [  513.786086] usb 1-1.5: new high-speed USB device number 4 using dwc_otg
Nov 24 14:13:54 raspberrypi kernel: [  513.917214] usb 1-1.5: New USB device found, idVendor=1235, idProduct=8014, bcdDevice= 2.60
Nov 24 14:13:54 raspberrypi kernel: [  513.917233] usb 1-1.5: New USB device strings: Mfr=1, Product=2, SerialNumber=3
Nov 24 14:13:54 raspberrypi kernel: [  513.917243] usb 1-1.5: Product: Scarlett 18i8 USB
Nov 24 14:13:54 raspberrypi kernel: [  513.917250] usb 1-1.5: Manufacturer: Focusrite
Nov 24 14:13:54 raspberrypi kernel: [  513.917257] usb 1-1.5: SerialNumber: 10018A17
Nov 24 14:13:54 raspberrypi mtp-probe: checking bus 1, device 4: "/sys/devices/platform/soc/3f980000.usb/usb1/1-1/1-1.5"
Nov 24 14:13:54 raspberrypi mtp-probe: bus: 1, device: 4 was not an MTP device
Nov 24 14:13:55 raspberrypi kernel: [  514.281569] usbcore: registered new interface driver snd-usb-audio
Nov 24 14:13:55 raspberrypi mtp-probe: checking bus 1, device 4: "/sys/devices/platform/soc/3f980000.usb/usb1/1-1/1-1.5"
Nov 24 14:13:55 raspberrypi mtp-probe: bus: 1, device: 4 was not an MTP device
Nov 24 14:13:55 raspberrypi systemd[552]: Reached target Sound Card.
Nov 24 14:13:56 raspberrypi rtkit-daemon[575]: Supervising 6 threads of 3 processes of 1 users.
Nov 24 14:13:56 raspberrypi rtkit-daemon[575]: Successfully made thread 1317 of process 573 owned by '1000' RT at priority 5.
Nov 24 14:13:56 raspberrypi rtkit-daemon[575]: Supervising 7 threads of 3 processes of 1 users.
Nov 24 14:13:56 raspberrypi rtkit-daemon[575]: Supervising 7 threads of 3 processes of 1 users.
Nov 24 14:13:56 raspberrypi rtkit-daemon[575]: Successfully made thread 1318 of process 573 owned by '1000' RT at priority 5.
Nov 24 14:13:56 raspberrypi rtkit-daemon[575]: Supervising 8 threads of 3 processes of 1 users.

The Raspberry is powered with official supply, it is powerful enough. Also the soundcard has its own supply.

Thanks again, looks ok to me. If you’re using the official supply and the soundcard’s own supply then that shouldn’t be the issue. Did you try other ports on the Pi? And maybe a different USB cable? Just to rule those things out.

Chances are that the Scarlett’s hardware mixer is muted, or not setup correctly

Check with alsamixer (then <F6> to select device).

When connecting a soundcard, most GNU/Linux distributions (incl. Raspian) restore previous mixer settings. But if the device was never connected before mixer-settings are often zeroed.

I had a look at alsamixer and all outputs are at 0 dB. I will make some research about using alsamixer and this type of soundcard.
Too bad, there is no nice piece of software that Focusrite provides to access the hardware mixer, like on Windows.

0dB (no change), or zero (silent)?

A few years ago I hacked up a rather technical tool to access the vast amount of controls. It is however a rather technical tool: GitHub - x42/scarlett-mixer: Quickly hacked scarlett-mixer GUI for Linux/ALSA

I meant 0dB (no change).
I found your repository few days ago and tried to compile it on the Raspberry without success. I think I am better off trying to understand how to use alsamixer with this soundcard if that is the most likely reason of my problem.

I had a slightly similar problem with the RME 802 recently. AvLinux MXE and RME 802. I didn’t get the sound out. I had to temporarily connect the device to a WIndows machine and reset the mixer. After that, everything works normally.

p.s.
One wonderful morning everything changes and we get support for Linux. Until then, all we have to do is make music with what we have and welcome more music makers into the Linux world, where all colors are brighter.

I managed to compile x42’s scarlett interface tool so it gives me a nicer interface than using alsamixer. For those interested, the list of dependencies are: lv2-dev libasound2-dev libcairo2-dev libpango1.0-dev libgl1-mesa-dev libglu1-mesa-dev

I also tried to setup my soundcard on Windows in a configuration that works well, then plug it to the Raspberry and see if it stays that way but it doesn’t work for me.
Now thanks to this scarlett interface, I can now see that everytime the soundcard settings are reset to default when I want to use it.

Also I couldn’t have any audio output when routing directly one of my analog input to the headphones output. This is something weird.

I will dig deeper on the audio routing of the soundcard, manage to find a way so it works on the Raspberry and then I think I will need to make some script to setup alsamixer the way I want it on boot so I don’t have to re-do the configuration again and again.

The OS already takes care of this when a device is connected (which is likely why everything gets muted by default).

Have a look at /var/lib/alsa/asound.state. After changing the mixer settings, you can explicitly save the state sudo alsactl store.

Usually the state is saved automatically when the system shuts down. But for USB devices that can be a problem. They must remain connected and powered while the system shuts down.

Alternatively you can use a custom file. e.g

alsactl --file ~/.config/asound.state store
alsactl --file ~/.config/asound.state restore

After lots of struggling I found this other post and installing qasmixer solved my problem.

In there I can access buttons to switch on/off the monitor & headphones outputs.

The same is possible with alsamixer, and any other tool that directly exposes the alsa-mixer interface as-is: qasmixer, alsamixergui, kmix, aumix,…

alsamixer and amixer come with ALSA (libasound) and are usually always installed by default. But yes, I can see some may prefer a graphical tool to a terminal application.

Somehow with alsamixer I could not access those switch, they were not listed. Only with qasmixer I could access them.

Do you use Linux audio before Raspberry?. Your comparison is more precise if you try to setup your config in Linux (in live mode is possible!), maybe using jack in the middle. Manjaro is nice for this, because has a x86 and raspberry versions.