• 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

MCH

Major Contributor
Joined
Apr 10, 2021
Messages
2,652
Likes
2,261
This is great news. Could you please post your capture settings? I can't get it to work yet...
Sure. I am not home but will do. But have you first connected the minidsp to a pc and selected toslink as the input? Just in case. I think otherwise the default is line in.
 

jbjbjbjbjb

Member
Joined
Feb 12, 2022
Messages
24
Likes
12
Sure. I am not home but will do. But have you first connected the minidsp to a pc and selected toslink as the input? Just in case. I think otherwise the default is line in.
Thanks. Yes, I got that far, mindsp can see audio in from toslink.
 
  • Like
Reactions: MCH

MCH

Major Contributor
Joined
Apr 10, 2021
Messages
2,652
Likes
2,261
This is great news. Could you please post your capture settings? I can't get it to work yet...
there you go.
Dont know if they are the best settings possible, but for me they work great: no noticeable delay, no buffer problems... pi is a 4b 2gb RAM.

devices:
adjust_period: 1
capture:
avoid_blocking_read: false
channels: 4
device: hw:m2x4HD
format: S32LE
retry_on_error: false
type: Alsa
capture_samplerate: 96000
chunksize: 2048
enable_rate_adjust: true
enable_resampling: true
playback:
channels: 4
device: hw:M4,0
format: S32LE
type: Alsa
queuelimit: 4
rate_measure_interval: 1
resampler_type: BalancedAsync
samplerate: 96000
silence_threshold: -90
silence_timeout: 600
stop_on_rate_change: false
target_level: 2048
 

Wirrunna

Member
Joined
May 27, 2021
Messages
93
Likes
45
Location
South Coast, NSW, Australia
Michael,
CamillaDSP and the Motu UL Mk5 are going well. Still have a bit to do with REW. Meanwhile I am really appreciating what you did in your tutorial for HenrikEnquist's brilliant system.

1. Input clicks on analog in to the UL Mk5 due to suspected DC from my preamp.
I tried a 1uf cap in the line in and that stopped the clicks when changeing inputs in the preamp. However, the cap rolled the deep bass off. Changed to a 33uf Solen polypropylene from the parts box and the deep bass was restored.

2. Streamer in using Squeezelite.
I loaded Squeezelite into my Motu M4 and configured it according to your instructions and it immediately appeared as a player on my Squeezebox server. One question, why do you get Squeezelite to convert everything to 44100 when the analog is set to 96000 in the UL Mk5 ?
Another thing I noticed is that there is no input VU display on the M4 when the stream is selected compared to analog. Is there a routing that could show stream input on the VU level meter ?

I have ordered a FLIRC and a BobWire DAT1 and started reading about your display, the FLIRC arrived this morning.
 
OP
M

mdsimon2

Major Contributor
Forum Donor
Joined
Oct 20, 2020
Messages
2,515
Likes
3,369
Location
Detroit, MI
Michael,
CamillaDSP and the Motu UL Mk5 are going well. Still have a bit to do with REW. Meanwhile I am really appreciating what you did in your tutorial for HenrikEnquist's brilliant system.

1. Input clicks on analog in to the UL Mk5 due to suspected DC from my preamp.
I tried a 1uf cap in the line in and that stopped the clicks when changeing inputs in the preamp. However, the cap rolled the deep bass off. Changed to a 33uf Solen polypropylene from the parts box and the deep bass was restored.

2. Streamer in using Squeezelite.
I loaded Squeezelite into my Motu M4 and configured it according to your instructions and it immediately appeared as a player on my Squeezebox server. One question, why do you get Squeezelite to convert everything to 44100 when the analog is set to 96000 in the UL Mk5 ?
Another thing I noticed is that there is no input VU display on the M4 when the stream is selected compared to analog. Is there a routing that could show stream input on the VU level meter ?

I have ordered a FLIRC and a BobWire DAT1 and started reading about your display, the FLIRC arrived this morning.

I resample to 44.1 kHz as my main source is airplay which always runs at 44.1 kHz so resampling squeezelite to 44.1 kHz means that I can leave my capture rate at 44.1 kHz. There is probably a better way to do this, maybe there is a way to resample the output of shairport-sync (airplay) to 96 kHz prior to the loopback? If so I could just resample once.

Michael
 

jbjbjbjbjb

Member
Joined
Feb 12, 2022
Messages
24
Likes
12
there you go.
Dont know if they are the best settings possible, but for me they work great: no noticeable delay, no buffer problems... pi is a 4b 2gb RAM.

Thanks, that's great, all working.
(my mistake was setting the number of input channels to 2 instead of 4)

It's good isn't it? I only wish there was a a way to physically change and view the input of the minidsp rather than using the remote 'in the dark'. It would then make an all purpose capture card for the rpi/camilla.
 

MCH

Major Contributor
Joined
Apr 10, 2021
Messages
2,652
Likes
2,261
Glad to see you got it working,
Yes, i am very happy with it, the overall system is very stable as commented before, and the minidsp only uses 2.5W. At first i was concerned about how hot it gets, but it seems to be normal...
I only wish there was a a way to physically change and view the input of the minidsp rather than using the remote 'in the dark'. It would then make an all purpose capture card for the rpi/camilla.
Ah, you are using it as analog input as well. Hm, i guess you are right, i can't think on a way to see what input you are using at a given time. I don't have that problem because i can use the motu for analog input (i don't actually use it) and in this case, you could build the display michael describes in post 3 or 4.
 
OP
M

mdsimon2

Major Contributor
Forum Donor
Joined
Oct 20, 2020
Messages
2,515
Likes
3,369
Location
Detroit, MI
Thanks, that's great, all working.
(my mistake was setting the number of input channels to 2 instead of 4)

It's good isn't it? I only wish there was a a way to physically change and view the input of the minidsp rather than using the remote 'in the dark'. It would then make an all purpose capture card for the rpi/camilla.

@MarcosCh has some good suggestions about using CamillaDSP volume control and switching between a miniDSP 2x4HD capture device configuration and an M4 capture device configuration. If you want to stick with miniDSP volume control and source selection you can add a display and use minidsp-rs to control the miniDSP. I posted a rough proof of concept here -> https://www.audiosciencereview.com/...-x-4-hds-usb-port-as-output.19976/post-880660, it is quite easy to use and it would be very easy to modify the display script to use minidsp-rs.

Also have had some discussions recently with @Wirrunna about alternative displays / enclosures. There are a lot of other options that may be cheaper and/or more readily available for you than what I used. Character displays are especially easy to use. The problem of course with adding an enclosure / display to a 4 channel setup is you very quickly get close to the cost of miniDSP Flex with a miniDSP 2X4 + MOTU M4 + display + enclosure.

Michael
 

Peafowl

Member
Joined
Sep 24, 2021
Messages
20
Likes
22
Location
Germany
Will CamillaDSP run on an ASUS Tinker Board or is this to different?
Just want to know, because i already have this as an volumio Streamer and may can use it .

Looking for input solution for an stereo 3 way system
DAC at the moment is an RME Fireface UFX. what can work hopefully similar than Motu M4 / Mk5
 

HenrikEnquist

Member
Joined
Jul 1, 2021
Messages
82
Likes
110
Will CamillaDSP run on an ASUS Tinker Board or is this to different?
It can definitely run on the tinkerboard. Which Linux distribution is it running? There is a good chance that you can use the prebuilt 32-bit binary. If not, it's quite easy to compile your own.
 

juliangst

Addicted to Fun and Learning
Joined
Dec 11, 2021
Messages
976
Likes
1,000
Location
Germany
Does anyone here have experience with Audient Evo interfaces?
They now have an 8 channel in/out version (Evo 16) for 460€ which is significantly cheaper than both Topping and Motu.
I'm mainly looking for an interface with volume control for all channels to easily control volume with a 2.1 or 2.2 setup
 
OP
M

mdsimon2

Major Contributor
Forum Donor
Joined
Oct 20, 2020
Messages
2,515
Likes
3,369
Location
Detroit, MI
Does anyone here have experience with Audient Evo interfaces?
They now have an 8 channel in/out version (Evo 16) for 460€ which is significantly cheaper than both Topping and Motu.
I'm mainly looking for an interface with volume control for all channels to easily control volume with a 2.1 or 2.2 setup

The Evo 16 looks interesting, I posted some thoughts about it here -> https://www.audiosciencereview.com/...annel-dac-recommendations.34969/#post-1219543.

Based on specs compared to the UL Mk5 it has lower noise, higher distortion and lower output voltage. When it was released it could only control the volume of two channels with the front panel knob but Audient has indicated they are considering allowing the knob to control volume of all channels like the UL Mk5 or Focusrite 18i20.

If volume control from the DAC is a requirement the UL Mk5 (front panel knob), DM7 (IR) or Okto (front panel knob and IR) seem like better options.

Michael
 
OP
M

mdsimon2

Major Contributor
Forum Donor
Joined
Oct 20, 2020
Messages
2,515
Likes
3,369
Location
Detroit, MI
One option is running REW on RPi. I would not be surprised if it fared quite well. Certainly I would recommend latest java instead of the default java8. Also it's likely 64-bit distribution + java would perform better on RPi4.

Another option is using the UAC2 gadget on RPi4 and have camillaDSP with fiters -> MOTU in one direction and MOTU -> camillaDSP as plain loopback in the other direction.

Conversation in another thread reminded me to revisit this. It would be really cool if REW could be run on the RPi4 while also running CamillaDSP but so far I have not been successful with doing this.

I have REW 5.20.9 installed on my RPi4, I am using a loopback input CamillaDSP configuration with a MOTU UL Mk5. I can use REW to send a signal to the loopback and this is recognized by CamillaDSP as you expect, however when I attempt to use the UL Mk5 as an input device in REW I receive an error as shown in the screenshot below.

However if I stop CamillaDSP and use the Mk5 as a REW input device it works fine. I imagine this might be some hardware specific thing with the MOTU UL Mk5 but was curious if you had any troubleshooting ideas.

Michael
 
OP
M

mdsimon2

Major Contributor
Forum Donor
Joined
Oct 20, 2020
Messages
2,515
Likes
3,369
Location
Detroit, MI
@mdsimon2 I don't see any screenshot?

Doh! Hit send before I attached, see below.

REW Error.png


Michael
 

phofman

Addicted to Fun and Learning
Joined
Apr 13, 2021
Messages
502
Likes
326
Michael: I would recommend to start troubleshooting with 2 sox instances (capture, playback) instead of the very complex REW.

Or even better arecord/aplay in verbose mode.
 
OP
M

mdsimon2

Major Contributor
Forum Donor
Joined
Oct 20, 2020
Messages
2,515
Likes
3,369
Location
Detroit, MI
OK, also get an error using arecord if CamillaDSP is running.

Code:
michael6@raspberrypi6:~$ arecord -d 10 -t wav -c2 -r 88200 -f S24_3LE -D plughw:UltraLitemk5 record.wav -v
Recording WAVE 'record.wav' : Signed 24 bit Little Endian in 3bytes, Rate 88200 Hz, Stereo
Plug PCM: Route conversion PCM (sformat=S24_3LE)
  Transformation table:
    0 <- 0
    1 <- 1
Its setup is:
  stream       : CAPTURE
  access       : RW_INTERLEAVED
  format       : S24_3LE
  subformat    : STD
  channels     : 2
  rate         : 88200
  exact rate   : 88200 (88200/1)
  msbits       : 24
  buffer_size  : 4096
  period_size  : 512
  period_time  : 5804
  tstamp_mode  : NONE
  tstamp_type  : MONOTONIC
  period_step  : 1
  avail_min    : 512
  period_event : 0
  start_threshold  : 1
  stop_threshold   : 4096
  silence_threshold: 0
  silence_size : 0
  boundary     : 4611686018427387904
Slave: Hardware PCM card 2 'UltraLite-mk5' device 0 subdevice 0
Its setup is:
  stream       : CAPTURE
  access       : MMAP_INTERLEAVED
  format       : S24_3LE
  subformat    : STD
  channels     : 16
  rate         : 88200
  exact rate   : 88200 (88200/1)
  msbits       : 24
  buffer_size  : 4096
  period_size  : 512
  period_time  : 5804
  tstamp_mode  : NONE
  tstamp_type  : MONOTONIC
  period_step  : 1
  avail_min    : 512
  period_event : 0
  start_threshold  : 1
  stop_threshold   : 4096
  silence_threshold: 0
  silence_size : 0
  boundary     : 4611686018427387904
  appl_ptr     : 0
  hw_ptr       : 0
Status(R/W):
  state       : PREPARED
  trigger_time: 0.000000
  tstamp      : 0.000000
  delay       : 0
  avail       : 0
  avail_max   : 0
arecord: xrun:1695: read/write error, state = PREPARED

Michael
 

HenrikEnquist

Member
Joined
Jul 1, 2021
Messages
82
Likes
110
Are you running playback at 88.2kHz too? And what happens if you start recording first, and then playback? Might be easier to use aplay than camilladsp while experimenting.
 
OP
M

mdsimon2

Major Contributor
Forum Donor
Joined
Oct 20, 2020
Messages
2,515
Likes
3,369
Location
Detroit, MI
Yes, interface is set at 88.2 kHz (cannot have different capture and playback rates).

I should also say I wasn't actually using aplay, I just had the CamillaDSP service running with CamillaDSP in the PAUSED state while attempting to use arecord.

If I stop my CamillaDSP service then I am able to successfully use arecord. It also seems like I can use arecord and aplay at the same time (directly using the UltraLitemk5 as my device in arecord / aplay) if the CamillaDSP service is not running and the recording / playback order does not matter.

Michael
 

phofman

Addicted to Fun and Learning
Joined
Apr 13, 2021
Messages
502
Likes
326
I agree, start from the most simple chain (arecord + aplay) and introduce the planned components step by step.

16ch at 3 bytes at 88200 samples takes half the available UAC2 bandwidth.
 
Top Bottom