• WANTED: Happy members who like to discuss audio and other topics related to our interest. Desire to learn and share knowledge of science required. 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

I have set the sample rate to 192000,
What do you set exactly? Playback on host must be 192000, your gadget configured to support 192000, and CDSP config for this rate as called by setrate must set capture rate at 192000 too.
 
yes, and some time it will play about 5 seconds , but the distortion is very very large.
 
I do not think your chain is working correctly as you intend, if CDSP measures the incoming rate as 44.1kHz while it should be receiving 192kHz.
 
What do you set exactly? Playback on host must be 192000, your gadget configured to support 192000, and CDSP config for this rate as called by setrate must set capture rate at 192000 too.
At first , I plug the rpi 5 to pc just want to use REW to do some test, and the red line below is at 192000, green line is 48000, blue line bypass rpi5, directly to dac.(I direct plug the output of dac to my recorder)
1720375429834.png
 
1720375557280.png

And then, I try to play some music, I found I will stop after about 1-2 second at 192000
 
I am afraid this chart does not say much about your real chain configuration. REW is OK to use for testing, use just the generator and make CDSP working first.

Ad green - AFAIK REW cannot playback at 48kHz and capture at 192kHz.

Again - if CDSP says it captures at 44.1kHz, IMO you should investigate why it is not receiving 192kHz.
 
As of REW - what output do you use? Wasapi Exclusive is the only viable method here.
 
I am afraid this chart does not say much about your real chain configuration. REW is OK to use for testing, use just the generator and make CDSP working first.

Ad green - AFAIK REW cannot playback at 48kHz and capture at 192kHz.

Again - if CDSP says it captures at 44.1kHz, IMO you should investigate why it is not receiving 192kHz.
OK, Thanks, I will get some investigate. (for the green one, I use analog, my recorder only have XLR input)
 
Alsamixer as shown in post https://audiosciencereview.com/forum/index.php?threads/rpi-camilladsp-tutorial.29656/post-2020418 just splits the four-value control into two stereo sliders, i.e. keeping the 4 values controlable. Did you try manipulating just one channel in each of the stereo sliders? The page in the post above lists the respective keys.
Forgot to reply to this. Sorry and thanks for your help. Yes, I did try to adjust the channels separately but didn't manage to get any sound from output 3 and 4.

In the attached screenshot I was just experimenting with output 1 and 2. It played balanced stereo in this configuration despite the left channel being turned down to 1. And didn't play anything on the right channel unless it was maxed out.

I ran out of time to play around with it further and didn't think I would be able to solve the issue in a reasonable time frame (if at all), so I already sent it back before my return window would close.

The Scarlett works perfectly and I'll settle for that despite not have volume control on all 4 channels. The reason I would like volume control is that ordered Fosi v3 monoblock amps, and I would have liked to have the ability to set a max volume. This in purely because I still don't trust the Pi software volume and worry about sending 200 watt into the speakers. I can still limit output 1 and 2 with the Scarlett, and the subwoofer (SB-1000 Pro) has its own volume control.

So in the end, the Scarlett will do for now. And I suppose I just have to get past my fear of software volume control too.
 

Attachments

  • 1.jpg
    1.jpg
    130.5 KB · Views: 41
Hi here, I just registered as an ASR community member :) This topic has provided me with some pieces of info that helped solve the CamillaDSP implementation on my system (not RPi) and one thing that bugged me for years is my soundcard (Focusrite 4i4 g3) that got powered by the PC until it reaches Grub, power off, then on kernel load got powered back on again. Focusrite being so-so in terms of quality, this makes quite a big pop with 4x 250W NCore amps if you forgot to power them down or messed up with the order.
So I found the 12V trigger to be a great solution. The recommended system, the Bobwire DAT1, albeit quite expensive would have solved the situation but ... I don't have an SPDIF output here.
Which leads to what I developed using Tasmota controlled plug(s), a small piece of software running in the background as a service that monitors CamillaDSP status and sends messages to the plug(s). Each plug has a timer (Pulsetimer in Tasmota terminology) and if it hasn't been reset the plug will switch off. Basic idea is to set a Pulsetimer value and send a "Power on" command before it goes down, like 5 mns/4mns. When the PC is properly shutdown, the plug is switched off immediately. If you pause your audio, CamillaDSP will pause too and the tool won't resend a power on command, the amplifiers will shutdown.
Using this for a few weeks, everything is fine. That's compatible with any Tasmota plug and can be found here: https://github.com/Oubahoubah/camilladsp_tasmotaplugs

I haven't tried to make an automated install as it's just two Python scripts, two systemd scripts to install and you're done. You just need to set the plug(s) IP address(es) in the Python scripts and fix your username in the systemd scripts.
 
Sorry for the spam, didn't feel like this would require a new topic to be opened but rather to provide other angles in CamillaDSP capabilities :) This is another small tool that may help some: https://github.com/Oubahoubah/lyrion_preamp

This allows one to control the Lyrion server from a USB multimedia control keyboard with a rotary encoder for volume and push button to toggle mute, next/play-pause/prev.
Then the Lyrion server controls squeezelite and squeezelite sets the volume of the softvol output ALSA device (just before entering the soundcard).
With this setup, I can keep all controllers (Material skin clients) in sync re. volume/mute status. Interestingly, volume also works while playing my turntable with another CamillaDSP pipeline rather than "digital" squeezelite audio.

Absolutely not polished nor thoroughly tested but runs great and simple enough to be finetuned/adapted to anyone's needs.
 
And then, I try to play some music, I found I will stop after about 1-2 second at 192000
I don't know if my experience if relevant to your's, but I'll share it just in case it helps.

I set my Wiim and Tidal to stream at 192 kHz. It works fine so long as the songs being streamed from Tidal are actually recorded at 192 kHz. However, if a next song comes on that is recorded at a lower sample rate, Tidal will stream it at that lower sample rate, and WiiM will do the same. What comes out of CamillaDSP is a garbled mess.

I have added the package camilladsp-setrate: https://github.com/marcoevang/camilladsp-setrate. It automatically changes CamillaDSP's sample rate when the streaming sample rate changes. Have you tried that?

Side note: camilladsp-setrate does not work with my MCHStreamer Kit as a SPDIF input to my Raspberry Pi. I have confirmed that it does work, though, using my Raspberry Pi's USB-C input configured as a USB gadget. For this reason I have ordered a new WiiM Ultra. It provides a USB output (firmware currently in beta) I can connect to my Raspberry Pi's USB-C input, which my WiiM Pro Plus does not.
 
I've had the Hifiberry Dac8x for a few weeks now and have been using it for a 3-way active system. I'm also using Hifiberry's Pi5 case. In short, I do not like the mini-TRS connectors. I had the unpleasant experience of turning on the subwoofer only to hear a terrifyingly loud hum come out of it. I turned the sub off as fast as I could and it seems to be OK. I removed mini-TRS to RCA adapter I was using and reseated it, after which everything was fine. But I notice it doesn't take much to get the subs to hum by just wiggling the wires slightly. [EDIT: Looks like the subwoofer incident was something stupid I did, but I still stand by the hum when wiggling the wires comment.]

Also, there is a slight "tick tick" noise in between tracks, which I assume is RF noise leaking out of the RPi case.

So I'm looking for a new audio interface with at least 6 output channels. The ones I'm considering are

Behringer UMC1820, $300 (acceptable noise and distortion?)
Audient Evo 16, $580
Motu Ultralite Mk5, $650

Topping seems to have discontinued the DM7.
 
Last edited:
Inventory is drying up, but Apos has silver ones in stock, as well as some black refurbished units.

Also, the Okto Research DAC8 is nice and got a review from Amir, but it is more expensive.

Apos just says it's discontinued, and I don't see any refurbished units. Were you looking at the Topping D70 Octo stereo DAC?

I'm aware of the Okto DAC, but want to keep costs down.

There are some good reports about using the Evo 16 with Linux at


EDIT: mdsimon's guide does mention reports of success with the Focusrite 18i20 2nd gen; not sure if that's still the case with the 3rd gen, but adding it to the list.
 
Last edited:
Apos just says it's discontinued, and I don't see any refurbished units. Were you looking at the Topping D70 Octo stereo DAC?

I'm aware of the Okto DAC, but want to keep costs down.

There are some good reports about using the Evo 16 with Linux at


EDIT: mdsimon's guide does mention reports of success with the Focusrite 18i20 2nd gen; not sure if that's still the case with the 3rd gen, but adding it to the list.
If you go 2-3 pages back, I posted my experience with the Audient ID14 Mk2. I couldn't get it to work with Alsa. In the link you posted:
Alsamixer shows a ton of controls, with various volume faders for analogue ins and outs. Sadly the controls didnt really work for me
Mirrored my experience.

I'm no Linux expert and running Pipewire on headless system is a hassle that is not well documented, so you will probably be pretty much on your own.

I'm using a 3rd Gen Focusrite 4i4 without issues. It would seem Focusrite has a loyal Linux fanbase that makes drivers for them that are integrated into the Linux releases so Alsa support is just plug and play. I would go with Focusrite for that reason.
 
@Daverz Interesting comment about the DAC8x as I had a similar experience recently. I was testing out some clock related stuff and couldn't find the cable I was previously using. I dug out a different 1/8" TRS cable that didn't seem to fit tight in the DAC8x and I got hum, it was alarming. Eventually I found the old cable and everything was fine. I still dislike the 1/8" TRS table because it seems like a lot of weight hanging off a fragile connector, especially if using RCA-to-XLR cables on the back end.

In terms of interfaces, I'd personally avoid the Behringer and the Focusrite Scarlett as they are pretty high noise. The Audient Evo 16 is interesting, it looks to have good noise performance and has a nice consumer friendly display, I just wish you could control the volume of all channels from the main knob.

I am a big fan of the MOTU Ultralite Mk5 and the Okto. I think the Okto is worth the price if you don't need the extra I/O functionality as it is much more consumer friendly (IR volume control, big display, trigger output) and the new DSP firmware gives it some very interesting capabilities.

Michael
 
@Daverz Interesting comment about the DAC8x as I had a similar experience recently. I was testing out some clock related stuff and couldn't find the cable I was previously using. I dug out a different 1/8" TRS cable that didn't seem to fit tight in the DAC8x and I got hum, it was alarming. Eventually I found the old cable and everything was fine. I still dislike the 1/8" TRS table because it seems like a lot of weight hanging off a fragile connector, especially if using RCA-to-XLR cables on the back end.

In terms of interfaces, I'd personally avoid the Behringer and the Focusrite Scarlett as they are pretty high noise. The Audient Evo 16 is interesting, it looks to have good noise performance and has a nice consumer friendly display, I just wish you could control the volume of all channels from the main knob.

I am a big fan of the MOTU Ultralite Mk5 and the Okto. I think the Okto is worth the price if you don't need the extra I/O functionality as it is much more consumer friendly (IR volume control, big display, trigger output) and the new DSP firmware gives it some very interesting capabilities.

Michael

I was also looking at the MiniDSP Flex Eight, if that can be used as an external 8 channel DAC. Unbalanced only, though.

Are there any measurements of the Focusrite?

It would be convenient to have mic inputs as it would make it much easier to do 3-way measurements with Acourate than with my Motu M4.
 
I don't think the Flex Eight can be used as an 8 channel USB DAC, however the Flex HT/HTx can. Unfortunately, the HT/HTx lack bi-directional USB audio so if you want to use them with software DSP you can only use them with the USB input.

In general, I trust pro audio company specs. The Focusrite 18i20 2nd gen DAC section is spec'd at 108 dB(A) and 0.001% THD+N (-100 dB) at +16 dBu (4.89 V). A-weighted dynamic range is usually 2-3 dB better than unweighted so I would expect unweighted residual noise somewhere between 24 uV and 28 uV. I got 24.3 uV unweighted, I also got -101.9 dB THD+N but only measured at 4 V rather than full output.

Noise - 2 mV - 1 kHz - 20-22K unweighted - measured by Cosmos ADC grade B at 1.7 V input sensitivity (stereo)
18i20_2mvout_1.7vadc_stereo.png


THD+N - 4 V - 1 kHz - 20-22K unweighted - measured by Cosmos ADC grade B at 10 V input sensitivity (stereo)
18i20_4vout_10vadc_stereo.png


The 18i20 3rd gen has very similar specs so I would expect similar performance. It isn't terrible but I would find it too noisy with a typical gain amplifier and relatively sensitive tweeter.

Michael
 
Last edited:
Back
Top Bottom