• 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

IME these days the good way is to ask a good AI model (I have good experience with GPT 5.0) for explanation, adding "search online" to the prompt so that the model fetches relevant info.
 
i haven't dealt with rpi for a long time,

but im looking into a solution using a hat to get toslink-input(pcm) into->rpi4, my best find so far was this: https://www.hifiberry.com/docs/software/using-the-dac-dsp-to-record-audio-from-s-pdif/

it basically re-routes hifiberry dac+ toslink-input to rpi-input, i don't need the recording part, but my idea was, that this way i can use CamillaDSP and output the audio from rpi usb.

has someone done something like this, or is there some other options im not aware of, thx in advance!
 
Last edited:
or is there some other options im not aware of

I have a miniDSP MCHStreamer kit. It worked well for a while, then at some point I started getting issues when streaming at 192k from a WiiM Pro+, though it still worked fine at 44.1k and 48k (I don't remember about 96k). The issue was either the MCHStreamer or the WiiMPro+, but the WiiM Pro+ worked fine connecting straight to my active speakers, bypassing the MCHStreamer and Raspberry Pi. I tested them connecting to my Windows computer and got the same results. I tried re-flashing the MCHStreamer, but that didn't solve the issue. Eventually I changed my streamer to a WiiM Ultra which has USB output, and now run that directly to my Raspberry Pi.
 
but im looking into a solution using a hat to get toslink-input(pcm) into->rpi4
IMO any spdif I2S input board from aliexpress should do - just switch the I2S interface to slave (e.g. https://github.com/AkiyukiOkayasu/RaspberryPi_I2S_Slave/tree/master) , wire the I2S pins, and configure CDSP to read from the I2S audio device. CDSP will have to use rate adjust + async resampler if the output device will be USB. If it were I2S, the resampler could be avoided as input and output would run synchronously, clocked by the SPDIF receiver master.
 
i was more like thinking: hifiberry dac+ dsp|toslink-in -> rp4 -> camillavoodo -> (ideally back to) -> hifiberry|toslink-out -> dac (then dac on/off not important), but if no_can_do -> camillavoodo -> rpi4 usb-out -> dac..
 
i was more like thinking: hifiberry dac+ dsp|toslink-in -> rp4 -> camillavoodo -> (ideally back to) -> hifiberry|toslink-out -> dac (then dac on/off not important), but if no_can_do -> camillavoodo -> rpi4 usb-out -> dac..
Here is my old setup: Wiim Pro+ --> MCHStreamer Kit --> RPi --> MCHStreamer Kit --> Active Speakers

Here is my new setup: Wiim Ultra --> RPi --> SMSL PO100 --> Active Speakers
 
i
Here is my old setup: Wiim Pro+ --> MCHStreamer Kit --> RPi --> MCHStreamer Kit --> Active Speakers

Here is my new setup: Wiim Ultra --> RPi --> SMSL PO100 --> Active Speakers
actually i still have my Wiim Ultra, but im looking into dirac as well, ideally want to see an alternative route for it.

i think ill try out rp4 (hifiberry dac+dsp) approach
 
Brand new CDSP user here. I found the shortcuts 'Treble' & 'Bass' and I wonder if its possible to control these gain values with python? My end goal is to have 2 rotary controllers as 'tone controls' for my project.
 
i was more like thinking: hifiberry dac+ dsp|toslink-in -> rp4 -> camillavoodo -> (ideally back to) -> hifiberry|toslink-out -> dac (then dac on/off not important), but if no_can_do -> camillavoodo -> rpi4 usb-out -> dac..
IMO it should work OK, if the vendor description is correct. IIUC - the incoming SPDIF is async-resampled by the HW DSP to the RPi I2S clock and sent to RPi. RPi I2S runs as master, clocking the DAC + DSP.

If you do not like the async resampling, a chain SPDIF receiver master I2S -> RPi I2S slave -> DAC I2S slave would work too.
 
IMO it should work OK, if the vendor description is correct. IIUC - the incoming SPDIF is async-resampled by the HW DSP to the RPi I2S clock and sent to RPi. RPi I2S runs as master, clocking the DAC + DSP.

If you do not like the async resampling, a chain SPDIF receiver master I2S -> RPi I2S slave -> DAC I2S slave would work too.
i will have to def. look into that, ideally toslink-in/out is preferred, will see, thx!
 
Well then keeping RPi I2S as master and using async resampling to bridge the incoming SPDIF clock master and RPi I2S clock master is too complicated IMO. Just SPDIF receiver - master -> RPi slave -> SPDIF transmitter slave - any aliexpress board should do. Just SPDIF transmitters typically require also master clock which could be provided by the SPDIF receiver (RPi does not need the master clock).
 
Hi all, I’m currently using a DAC+ DSP with a RPi 5.

My intended signal chain is Toslink in (or airplay from Moode)-> RPi -> CamiliaDSP (Moode Audio) -> Toslink output as a means to EQ my TV signal to active speakers.

After some searching, I’ve managed to make it work with Moode audio and CamiliaDSP and got the above signal chain to work. I can see the input and SPL meters move in CamiliaDSP when using the Toslink input.

However, I’m also facing another issue where Toslink in -> Toslink out is active as well. Basically whatever is played via toslink in gets piped to the toslink output. I can set the volume to CamiliaDSP to be zero, and still get audio. And if I enable volume in CamiliaDSP, I basically get 2 outputs, one with EQ applied and one without.

Does anyone know how to stop the Toslink input from going directly to the toslink output? I asked on the hifiberry forums but they pointed me to use SigmaStudio for that. I tried opening a sample DSP project from hifiberry in SigmaStudio to take a look but I don’t really understand how any of it works.

Additional:
I’ve not tested the RCA outputs yet as I don’t have a device (and necessary cables), but I will be getting some soon. Ideally the analog outputs would take inputs from the Pi as well, essentially mirroring the toslink output. Does anyone know if that is already achieved or how I might be able to do that?
 
@Pow1, The Hifiberry DAC+DSP isn't the easiest thing to use in your case. I had one and replaced it with a USB sound card with Toslink inputs and outputs. If you absolutely want to use a DAC+DSP, HifiberryOS works perfectly.
 
Hi melomane13!

I agree with your sentiment! While trying to fiddle around with the dac+dsp last week, I also ordered an S2 Digi from Hifimediy. It arrived yesterday and I’m using as an optical input and piped to the output of the dac+dsp (as a sanity check) and it works perfectly.

In the meantime, I’ll likely work to have all digital I/o go through the S2 which pretty much makes the dac+dsp redundant on my side, which is such a pity cause imo the IO options that the DAC+DSP has is pretty good. Using the S2 frees up hat space so I’ll probably think about what to get next.
 
Hi

I'm just releasing the first 8xinput + 8xoutputs all in one board for raspberry PI5! I thought that it could be interesting for CamillaDSP user.

...

Let me know if you have any question.
I have a question about the GPIO usage for the 8+8 card, which GPIO pins are in use with this card?
 
Last edited:
i haven't dealt with rpi for a long time,

but im looking into a solution using a hat to get toslink-input(pcm) into->rpi4, my best find so far was this: https://www.hifiberry.com/docs/software/using-the-dac-dsp-to-record-audio-from-s-pdif/

it basically re-routes hifiberry dac+ toslink-input to rpi-input, i don't need the recording part, but my idea was, that this way i can use CamillaDSP and output the audio from rpi usb.

has someone done something like this, or is there some other options im not aware of, thx in advance!

I've been trying to work with something like this over the past week. So far I've managed to get the toslink input working in CamiliaDSP and sending it to the toslink output.

However the issue that I'm currently facing with the DAC+DSP is that somehow there seems to be a separate stream that routes the toslink input directly to the toslink output and I can't seem to remove that. Which means I have the following 2 streams playing simultaneously:

1) toslink input -> CamiliaDSP -> toslink output
2) toslink input -> toslink output

I've been trying to disable #2, but according to the hifiberry team on their forum, it seems like this is not possible without SigmaStudio. I took a look at SigmaStudio and tbh everything just flies over my head and I'm not sure how to use it at all.

I also got myself a hifime S2 Digi and managed to implement #1 as intended. It doesn't have the chain in #2 which is great. The only issue is that there is a ~1s delay in the audio and so not very suitable for TV. I'm currently using CamiliaDSP as part of Moode audio. I can't confirm but I suspect the delay is from me using mpd to select ASLA inputs as Moode audio doesn't support input selection for the S2 Digi (and the DAC+DSP, which also has a delay when implementing #1).

Currently, my remaining options are to either move away from Moode audio, or use Toslink input without DSP (i.e. listen to music via airplay to the RPi and skip EQ for TV), or to move away from CamiliaDSP and use the dsp in the DAC+DSP.
 
I've been trying to work with something like this over the past week. So far I've managed to get the toslink input working in CamiliaDSP and sending it to the toslink output.

However the issue that I'm currently facing with the DAC+DSP is that somehow there seems to be a separate stream that routes the toslink input directly to the toslink output and I can't seem to remove that. Which means I have the following 2 streams playing simultaneously:

1) toslink input -> CamiliaDSP -> toslink output
2) toslink input -> toslink output

I've been trying to disable #2, but according to the hifiberry team on their forum, it seems like this is not possible without SigmaStudio. I took a look at SigmaStudio and tbh everything just flies over my head and I'm not sure how to use it at all.

I also got myself a hifime S2 Digi and managed to implement #1 as intended. It doesn't have the chain in #2 which is great. The only issue is that there is a ~1s delay in the audio and so not very suitable for TV. I'm currently using CamiliaDSP as part of Moode audio. I can't confirm but I suspect the delay is from me using mpd to select ASLA inputs as Moode audio doesn't support input selection for the S2 Digi (and the DAC+DSP, which also has a delay when implementing #1).

Currently, my remaining options are to either move away from Moode audio, or use Toslink input without DSP (i.e. listen to music via airplay to the RPi and skip EQ for TV), or to move away from CamiliaDSP and use the dsp in the DAC+DSP.
i thought about this as well (2 outputs sent to toslink_out, if not controlled somehow), im kinda busy right now, but planning on getting into it end of next month. it looks to me, it is doable but yeah from berry dsp. haven't looked into SigmaStudio yet, but i imagine its about loading your dsp preset/program, finding the register to disable and saving a new dsp preset/program with the configuration.
 
I've managed to install CamillaDSP on PiCorePlayer using the code from https://github.com/JWahle/piCoreCDSP?tab=readme-ov-file#picorecdsp-installation-script. I've done it several times and always had to run the script more than once so don't give up if nothing happens the first time. I've only had luck with a fresh install of PCP. In my case I run Lyrion server on another Pi and use others as clients. The github site has some good troubleshooting info for failed installs. The thing that's worked best for me is brute force, reboot and run the install again. You will know you have a successful install when the script tells you that it's done and going to reboot. The CamillaDSP interface is accessible through port 5000 so you just need to put the url of your Pi followed by ":5000" in the go box of your browser, e. g. xxx.xxx.xxx.xxx:5000. There's one more step. In the Devices section of CamillaDSP you have to choose your output device from a pick list. Be sure to have configured it in the Squeezelite section of PCP. The UI is a bit less user friendly than the Bitlab mods in Moode, but if you've created a config before you'll be familiar with all the necessary components. I'm using a saved config for my main listening room that I've used with Moode so all I had to do is upload the yml file. Caveat: You have to be familiar with ssh and have a tiny bit of Linux command line experience.
 
I'm running 3.x on an RPi5. I want to send out a 96Khz 2ch PCM signal.
For this purpose I need to set sample-rate to 96Khz. There will need to be resampling because my captured sample-rate is 44.1-96Khz (from an app that will play music files).
So in theory Synchronous resampler sounds ideal here. However it seems to need more than 1024 in chunksize "to be happy".
It would seem that AsyncSincBalanced needs a lower chunksize to work without "[src/alsadevice.rs:344] Capture: read overrun, trying to recover. Error: ALSA function 'snd_pcm_readi' failed with error 'Broken pipe (32)'"
Is this how it's supposed to be?
 
Back
Top Bottom