• Welcome to ASR. There are many reviews of audio hardware and expert members to help answer your questions. Click here to have your audio equipment measured for free!

RPi + CamillaDSP Tutorial

How do you guys power off the RPi 4 running CamillaDSP? Will simply unplugging from power work over the long run? Or should the RPi be powered off with a clean shutdown?
I use gpio and J2 header to switch on and off. No issues at all, but I guess cutting power is also ok.

Note that soldering J2 pins is more difficult than it seems due to lack of good thermal relief.
 
I switch all my audio devices with the mains switch of a power strip. Doing the same with the RPi would be the preferred solution. I don't care about boot-up time which so far was quite short anyways. But I don't like to wait for power down. A copy of the SD card will help for quick recovery if needed.
 
Just got my Hifiberry Dac8x and just wanted to report briefly on noise levels. I have the Dac8x hooked up to my Bryston 3B-SST amp in single-ended mode with a mini-TRS to dual RCA cable. The amp gain is 29 dB. Speakers are Buchardt S400 (about 85 dB sensitivity).

If I put my ear right up to the speaker drivers I can hear a quiet hum. It's inaudible a foot away or so. I don't hear any noise out of my subwoofers (SVS SB-1000 Pro).

In other words, nothing to worry about.

Setup was otherwise very easy, and I have nothing exceptional to report about any sonic differences compared to my Motu M4. (I got this for another project, not to replace the M4).

It may be possible to get a balanced connection -- at the cost of one output channel per balanced connection -- by splitting a signal in camilladsp and inverting one of the outputs, but I don't have the cabling (mini-TRS to XLR) to try this right now.
Hum, as in low frequency 50-60 Hz noise, is usually generated by bad to power supplies or (more likely) a ground loop.
Hiss, as in high frequency noise or white noise, is usually result of SNR of the analog parts in the audio chain.

If you have ground loop based hum, it's usually fixable.
 
The system has glitches, like many it drops dead after some time and requires a boot. It sometimes won't play sound if output device is not connected when powering up. If you change anything, you need to check the GUI and if that doesn't, you need SSH and console. My Rasberry Pi 4B draws a lot of power and generates a lot of heat for it's function and requires an external power supply. Raspberry 5 is not any better in that regard. As it is now, it will not "simply work" and be "hassle free".

I wouldn't extrapolate your relatively atypical experience powering the RPi from a USB port (and attempting to further reduce power consumption by lowering clock speed) and using a DAC not recommended in this tutorial to a more typical setup. I've used CamillaDSP on a RPi4 with an Okto dac8 pro for 3 years now. I've never had any issues. I'll leave for a week at time for work and have no worries that something will go wrong while I am out of town, from my wife's perspective it just works.

Michael
 
Last edited:
Hum, as in low frequency 50-60 Hz noise, is usually generated by bad to power supplies or (more likely) a ground loop.
Hiss, as in high frequency noise or white noise, is usually result of SNR of the analog parts in the audio chain.

If you have ground loop based hum, it's usually fixable.

I should have checked the Bryston with nothing hooked up except power and speaker cables. There is some very slight residual noise with my ears very close to the drivers. I don't think it's a ground loop. @mdsimon2 's measurements of the Dac8x don't seem to show any significant noise.
 
Perhaps the Focusrite Scarlett 4i4 3rd Gen, which is 200 Euro.
Thanks for the suggestion. Took a closer look.

One interesting thing is that in the software you can change the volume knob to affect all line out and it would seem the setting is saved on the device.
 
How do you guys power off the RPi 4 running CamillaDSP? Will simply unplugging from power work over the long run? Or should the RPi be powered off with a clean shutdown?
It depends...
The general answer is that you should do a clean shutdown if possible. That makes sure everything that needs to be written to storage has been written and everything is consistent. There are reasons why just pulling the power may not be so bad though.

Modern filesystems are more resilient than some of the old ones, so filesystem corruption is less of a problem than it used to be if you just pull the power. Also for a Pi running CamillaDSP there probably isn't going to be much that needs to be written to storage except when you're doing updates or copying media, and you probably won't pull the power when doing either of these. Outside these times the chances of data loss are low, so if you do just pull the power it probably won't cause a problem. I'd still prefer to do a proper shutdown as the OS may be doing automatic updates, but many people don't bother and get away with it for years.

A few specialised linux varieties take it a step further, treating the main system storage as read-only except when doing manual updates or changing configuration. This means there's nothing critical to be lost if the power does just disappear for any reason. piCorePlayer does this, as does daphile on PC hardware. With piCorePlayer I just pull the power. With daphile the PC power button does the clean shutdown so it's not a problem.

Or you can get a case or module for the Pi that provides a PC-like power button that initiates a clean shutdown before the power is actually turned off. This usually needs a bit of configuration for the software to react to the signal. IIRC some of the Argon40 Pi cases come with this.
 
What I couldn't figure out yet with the raspberry pi is how to avoid that it boots after a power cut. Does anyone know?
 
What I couldn't figure out yet with the raspberry pi is how to avoid that it boots after a power cut. Does anyone know?
I do not think this is possible as the only way to boot it up is to plug it in.
As a workaround, you could use a smart power plug whose 'power-on' setting is OFF, most are configurable.

This for example is a reliable one (and exists in EU form) but you could probably find cheaper ones, just make sure that you can set the power-on behaviour.
 
What I couldn't figure out yet with the raspberry pi is how to avoid that it boots after a power cut. Does anyone know?
You use a power switching board that has that as an option, like the Witty Pi.
 
  • Like
Reactions: MCH
Or you can get a case or module for the Pi that provides a PC-like power button that initiates a clean shutdown before the power is actually turned off. This usually needs a bit of configuration for the software to react to the signal. IIRC some of the Argon40 Pi cases come with this.
The Raspberry Pi 5 has an onboard power button that can be depressed to initiate a clean shutdown. The button extends out through a hole in the side of the case (assuming you use a case specifically designed for the Pi 5). With Raspberry Pi OS Lite you push the button once to initiate shutdown. With some other OS's you press the button twice.
 
I wouldn't extrapolate your relatively atypical experience powering the RPi from a USB port (and attempting to further reduce power consumption by lowering clock speed) and using a DAC not recommended in this tutorial to a more typical setup. I've used CamillaDSP on a RPi4 with an Okto dac8 pro for 3 years now. I've never had any issues. I'll leave for a week at time for work and have no worries that something will go wrong while I am out of town, from my wife's perspective it just works.

Michael
And this is by far the best metric in terms of reliability :)
 
I managed to get Camilla up and running over Airplay with the github guide from this thread (thanks to @mdsimon2 ) using a $9 soundcard like this:

It plays individually over all 6 channels and after fiddling around with Camilla for a little while, it was no issue to set up pipelines, and get a basic room mode EQ running (I didn't bother to hook up a sub, but could confirm with headphones that that I could get a lowpass filter going on one of the channels). This has greatly increased my confidence in my ability to get this working.

However, the sound is horrible. The soundcard is only 16 bit on paper, but has the sound quality of 1980's tape cassette. It sounds flat without dynamic range, noisy, lacks clarity, and like running a compressor. Further more, when rebooting the Pi, my loudspeakers would make uncomfortable pops. Now the plan was just to use the soundcard as proof of concept before spending more money.

How much of this can be attributed to the soundcard and how much (if any) is the Raspberry Pi? What issues could I expect to persist (e.g. the popping) if I upgraded to a proper audio interface? Do I need a better power supply for the Pi to reduce noise (using the official Pi USB-C psu)?

Thanks.
 

Attachments

  • Screenshot 2024-06-18 at 16.09.13.jpg
    Screenshot 2024-06-18 at 16.09.13.jpg
    54.1 KB · Views: 77
How much of this can be attributed to the soundcard and how much (if any) is the Raspberry Pi?

I'm running Camilla as loudspeaker crossover and room correction on a Pi4 using the default Pi power supply and a Motu M4 as Dac/soundcard. No pops, clicks or audible noise whatsoever. I also have another Pi4 running Moode with Camilla into a Topping E30/L30 as a headphone rig. Again, no audible noise or pops ...
 
@AncientMariner Difficult to say as I don't have experience with that particular sound card. It is certainly possible that it is a bad implementation. Measurements here might help understand the issue. When you say it is noisy, like hiss? A lower pitch ground loop? Something else?

None of the cards I recommend in my tutorial have significant on / off pops while connected to a RPi. I have experienced that with poor quality designs like the DIYINHK boards, I also use DC coupled amplifiers which means pops can be particularly nasty if they exist.

I doubt the RPi power supply has much of an impact.

Michael
 
None of the cards I recommend in my tutorial have significant on / off pops while connected to a RPi. I have experienced that with poor quality designs like the DIYINHK boards, I also use DC coupled amplifiers which means pops can be particularly nasty if they exist.
Dont you have off pop with the motu UL mk5? interesting. I do have, and quite loud. @levimax reported the same in the ultralite thread (see below). I thought it was normal. I do a 10 minutes hold power off sequence so that my amp goes to sleep before on purpose to avoid this. My amp is also DC coupled. Note I am referring to turning off the Motu, not the raspberry pi.

 
Last edited:
Thanks @mdsimon2 @bluefuzz

I think I will try to buy the Focusrite Scarlett 4i4 3rd generation. It's only around $170 here and supposedly it's possible to change the main volume, in the included software, to include all 4 output channels on the rear. It would be nice with a working physical volume knob since the plan is to use it with Fosi Monoblocks.

I guess I could take advantage of Amazon return policies if I can't get it to work.
 
Back
Top Bottom