• 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!

RPi4 + CamillaDSP Tutorial

OP
M

mdsimon2

Major Contributor
Forum Donor
Joined
Oct 20, 2020
Messages
2,515
Likes
3,371
Location
Detroit, MI
mdsimon2, what is the latency when you capture PCM through your hifiberry? I ask beacuse I would be capturing the analogue output from my preamp to do dsp on de PI while sending the rest of the signal straight to the amp. Another DSP would be processing the signal before the preamp thou, to accommodate for the delay to the subs, but still, this should be kept to a minimum and I find a delay annoying when changing tracks frequently.

Yo do flac streaming to minimize Wifi BW or what is the reason?

Are you talking about the HifiBerry ADC that I was discussing with @MarcosCh here -> https://www.audiosciencereview.com/.../rpi4-camilladsp-tutorial.29656/post-1094572? If so the 4-5 second delay is due to the WaveInput plugin in LMS not something inherent to the HifiBerry ADC. And yes, I use FLAC to minimize wifi bandwidth without losing any quality.

If you are talking about the Hifiberry Digi+ I/O I made some measurements here -> https://www.audiosciencereview.com/...tu-m4-phenomal-dsp-streamer.24493/post-930811, as mentioned above delay will depend on sample rate, chunk size and whether resampling is enabled.

I don't think what you describe will work well as there will be a 25+ ms delay between your DSP'd signal and the signal that goes straight to your amplifier.

Michael
 

348montesa

Member
Joined
Feb 24, 2022
Messages
5
Likes
0
Are you talking about the HifiBerry ADC that I was discussing with @MarcosCh here -> https://www.audiosciencereview.com/.../rpi4-camilladsp-tutorial.29656/post-1094572? If so the 4-5 second delay is due to the WaveInput plugin in LMS not something inherent to the HifiBerry ADC. And yes, I use FLAC to minimize wifi bandwidth without losing any quality.
Ok, now I understand why the large latency.

I don't think what you describe will work well as there will be a 25+ ms delay between your DSP'd signal and the signal that goes straight to your amplifier.
This is an experiment, the whole signal would be linearized with rephase, so this would compensate for that delay in that frecuency range.
 
OP
M

mdsimon2

Major Contributor
Forum Donor
Joined
Oct 20, 2020
Messages
2,515
Likes
3,371
Location
Detroit, MI
Interesting experiment, can you explain a bit more? I am assuming you are linearizing using the DSP upstream of your preamp? I can't quite wrap my head around how this will work with a crossover requiring some overlap and phase matching but maybe it would be OK if you used super steep slopes?

Michael
 

348montesa

Member
Joined
Feb 24, 2022
Messages
5
Likes
0
Interesting experiment, can you explain a bit more? I am assuming you are linearizing using the DSP upstream of your preamp? I can't quite wrap my head around how this will work with a crossover requiring some overlap and phase matching but maybe it would be OK if you used super steep slopes?

I really don't know how good it will turn out. Yes, the linearizing dsp will be upstream of my preamp. The crossover from mids to subs (which are three, distributed in the room, with their own DSP) is independent. I too assume that less overlap works better. The xo freq is 80 hz, and the mids have 3rd order acoustic HP. As there are several sources (even for subs alone) and because this is a region dominated by the room behaviour, I can try and run multiple sub optimizer software and linearization to see what works better. There is really quite a lot to vary and see if it works.

There are certainly much more simple/traditional ways to integrate the subs, but, at least for now, I want to try to keep my stereo preamp in the system.
 
Last edited:

MCH

Major Contributor
Joined
Apr 10, 2021
Messages
2,659
Likes
2,272
Hi. I am trying to setup camilladsp in a zero 2w following this terrific tutorial (with some tweaks).
I can make it to the end and everything seems in place... except alsamixer. Even after installing alsa-utils, aplay and record, for instance, work fine, but alsamixer is not there.
Any experience with this issue? I am struggling to find any related info online.... Is this a limitation of the zero 2 w? Should I be using something different to this version of ubuntu?
Any idea would be much appreciated
.
 
OP
M

mdsimon2

Major Contributor
Forum Donor
Joined
Oct 20, 2020
Messages
2,515
Likes
3,371
Location
Detroit, MI
Just dug out my pi 2 zero W running ubuntu server 21.10 64 bit and have the same issue. I get an error stating "cannot open mixer: No such file or directory".

Try using "alsamixer -c 1" where 1 is the number of the card you want to use. This worked for me.

Michael
 
  • Like
Reactions: MCH

igfarm

Member
Joined
Jan 16, 2021
Messages
36
Likes
28
I have set up and RPi4 and Motu M4 as described here to implement a simple crossover for a sub. It's all working as expected with one small issue: the volume knob on the Motu M4 only seems to affect channels 1-2 (mains) and not channels 3-4 (sub). Is this the expected behavior for this device?
 
OP
M

mdsimon2

Major Contributor
Forum Donor
Joined
Oct 20, 2020
Messages
2,515
Likes
3,371
Location
Detroit, MI
I have set up and RPi4 and Motu M4 as described here to implement a simple crossover for a sub. It's all working as expected with one small issue: the volume knob on the Motu M4 only seems to affect channels 1-2 (mains) and not channels 3-4 (sub). Is this the expected behavior for this device?

Yes, unfortunately that is the expected behavior. This is an advantage to using CamillaDSP for volume control as it can control all output channels.

Michael
 

threni

Major Contributor
Joined
Oct 18, 2019
Messages
1,281
Likes
1,532
Location
/dev/null
Thanks for giving it a try! Good to know it's best -- for now -- to stick with Ubuntu.
Does this help?

https://github.com/moode-player/moode/releases

moOde audio player 8.0.0
This release is based on RaspiOS Bullseye Lite (2022-01-28) and Linux kernel 5.15.y branch.

I think they've been working on allowing moOde to work on systems other than their own "never apt-get upgrade" .ISOs.
 

RickSanchez

Major Contributor
Cartographer
Joined
Sep 4, 2019
Messages
1,168
Likes
2,492
Location
Austin, TX
Does this help?

https://github.com/moode-player/moode/releases

moOde audio player 8.0.0
This release is based on RaspiOS Bullseye Lite (2022-01-28) and Linux kernel 5.15.y branch.

I think they've been working on allowing moOde to work on systems other than their own "never apt-get upgrade" .ISOs.
Thanks for the info! I think I'll give that a try later this week and see what it's like.
 
OP
M

mdsimon2

Major Contributor
Forum Donor
Joined
Oct 20, 2020
Messages
2,515
Likes
3,371
Location
Detroit, MI
Does this help?

https://github.com/moode-player/moode/releases

moOde audio player 8.0.0
This release is based on RaspiOS Bullseye Lite (2022-01-28) and Linux kernel 5.15.y branch.

I think they've been working on allowing moOde to work on systems other than their own "never apt-get upgrade" .ISOs.

Thanks for the heads up, gave this a try this afternoon on a CM4. The updated kernel means that I now get sound using the MOTU Ultralite Mk5 and I was able to setup a basic CamillaDSP configuration to route 2 channel input to 10 channel output! Unfortunately there are still some hang ups.

1) Will not make a network connection if the Ultralite Mk5 is connected on start up. After start up the Mk5 can be connected without issue. Don't know the reason for this but it seems like something inherent in Raspberry Pi OS as I also experienced this on previous versions.
2) Cannot install python3-lgpio so the display is not an option without compiling lgpio from source but I believe that there are other display options for Moode so probably not a huge loss.
3) I haven't checked this but on previous versions of Moode you cannot use external inputs (SPDIF, analog, etc) and I see nothing in the release notes indicating this has changed. Not a big deal if you are only using this as a streamer.

Michael
 

MCH

Major Contributor
Joined
Apr 10, 2021
Messages
2,659
Likes
2,272

georgew2

Member
Joined
Jan 21, 2022
Messages
24
Likes
10
I wonder if a solution like this:


could be easily implented to moode for popular usb interfaces like these are suggested to this tutorial (motu etc) to have the possibily to use external input.

*** I note also that moode has expert mode for camilla dsp in which we can change capture device etc
 
Last edited:

MCH

Major Contributor
Joined
Apr 10, 2021
Messages
2,659
Likes
2,272
I wonder if a solution like this:


could be easily implented to moode for popular usb interfaces like these are suggested to this tutorial (motu etc) to have the possibily to use external input.

*** I note also that moode has expert mode for camilla dsp in which we can change capture device etc
You can find the answer at the beginning of the tutorial you linked (amazing piece of work btw! :D) and in the two links in the post above yours.
In brief: at least until a few months ago, only two devices can input sound through spdif to moode. Maybe things have changed since then, it would be good to ask in moodeaudio forum for an update.
 

georgew2

Member
Joined
Jan 21, 2022
Messages
24
Likes
10
I read the above links and I saw that it isn't availabe in stock rom for most devices (except the two mentioned)

But I think (with my little knowledge) that the solution which is suggest on the link that I quoted could work with moode 8 and the updated kernel (in few words to change camilla dsp settings of capture device in expert mode, choosing the external input of the motu audio interface).

Unfortunately, I don't have a usb audio interface to try this (I am just consider this option and check If it could work with moode and an external input)
 
  • Like
Reactions: MCH

jdubs

Member
Forum Donor
Joined
Mar 12, 2018
Messages
97
Likes
19
I'd love to have the ability to switch between 2 sources! I've got a pair of JBL 708Ps en route to me and they have an AES input. I already have a Motu M4 and Pi4 and was hoping for a solution that allows me to switch between streaming Spotify or Tidal at their respective native resolution AND be able to switch to the analog inputs of my M4 which I'll be feeding from my phonostage at 24bit/ 192khz. Would use CamillaDSP for its volume control and a bunch of PEQs filters for both inputs.

Output would be AUDIOPHONICS Digipi+AES TOSLINK TCXO Digital Interface hat.

-Jim

 
OP
M

mdsimon2

Major Contributor
Forum Donor
Joined
Oct 20, 2020
Messages
2,515
Likes
3,371
Location
Detroit, MI
I'd love to have the ability to switch between 2 sources! I've got a pair of JBL 708Ps en route to me and they have an AES input. I already have a Motu M4 and Pi4 and was hoping for a solution that allows me to switch between streaming Spotify or Tidal at their respective native resolution AND be able to switch to the analog inputs of my M4 which I'll be feeding from my phonostage at 24bit/ 192khz. Would use CamillaDSP for its volume control and a bunch of PEQs filters for both inputs.

Output would be AUDIOPHONICS Digipi+AES TOSLINK TCXO Digital Interface hat.

-Jim


As mentioned above switching between sources is as easy as switching between a configuration using the M4 as input (for analog input from the turntable) and an ALSA loopback (for streaming), very easy to do in the CamillaDSP GUI. If you end up implementing a display it would also be very easy to add source indication to the display and the ability to change sources via an IR remote.

I do not personally use Spotify or Tidal but it seems that they work on LMS 8 -> https://forums.slimdevices.com/showthread.php?112130-How-do-i-use-Tidal-on-LMS-8 which means you can use squeezelite as player as mentioned in the tutorial. I personally wouldn't worry about running CamillaDSP at native resolution as the resampler is excellent and your JBL 708Ps are going to resample all inputs to 192 kHz anyways. If you did want to retain full frequency response of hi-res files just change the 44100-44100 in SB_EXTRA_ARGS to 192000-192000 which will convert all files that are not natively 192 kHz to 192 kHz. Of course if you did want to run CamillaDSP at the native sample rate you could use the ALSA CDSP plugin -> https://github.com/scripple/alsa_cdsp although that would require quite a few setup differences than what is currently shown in the tutorial.

Michael
 

bitlab

Member
Joined
Mar 20, 2021
Messages
7
Likes
11
You can find the answer at the beginning of the tutorial you linked (amazing piece of work btw! :D) and in the two links in the post above yours.
In brief: at least until a few months ago, only two devices can input sound through spdif to moode. Maybe things have changed since then, it would be good to ask in moodeaudio forum for an update.

The moOde upgrade from a kernel 5.4 .x to 5.15.x enables a lot more USB multi output channel device and also input devices. Still waiting for 5.18.x kernel to fully support USB gadget mode.
Indeed moOde has current no facilities in the graphical user interface for selecting the input.

Fortunately, you can manually make a configuration for the input. For example, as mentioned a few posts above, if the expert mode for camilladsp is enabled the input device can be specified. Only then you will loose the alsa-cdsp functionality for rate switching, normally used by moOde.

I think they've been working on allowing moOde to work on systems other than their own "never apt-get upgrade" .ISOs.
Your are correct. One of the big changes is that all moOde used software pieces are now build and installed as deb files. But it is still intendent as dedicated moOde image/system.
See https://github.com/moode-player/pkgbuild for an overview of all used software packages and versions.
 
Top Bottom