• 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

sarieri

Senior Member
Forum Donor
Joined
Mar 1, 2023
Messages
333
Likes
217
Assuming a stereo input signal, you can apply your EQ filters to left and rght inputs, or you can apply EQ after splitting up the input with a mixer. If you are using FIR filters for your crossover and for EQ, I would suggest convolving the full EQ with the crossover filters to create a single FIR filter for each output channel.
Suppose I want to apply EQ before sending the stereo signal to mixer, should I do that in pipeline?
 

Wirrunna

Member
Joined
May 27, 2021
Messages
94
Likes
45
Location
South Coast, NSW, Australia
Sareiri, I have zipped a couple of CamillaDSP configs and attached them below, unzip them and either look at them with an editor like notepad or put them into CamillaDSP and have a look at them in the GUI. The pipeline shows the filters on the input channels before the mixer.
This link - https://www.diyaudio.com/community/...m-correction-etc.349818/page-189#post-7213813 - describes the process I used to get to those configs.
 

Attachments

  • _T45_A67_Test.zip
    9.7 KB · Views: 18

sarieri

Senior Member
Forum Donor
Joined
Mar 1, 2023
Messages
333
Likes
217

dobrynin

Member
Joined
Dec 21, 2023
Messages
22
Likes
2
Hello everyone. The Infomaker HiFi DAC Audio Hat board has arrived. I connected it, registered it in the config:

sudo nano /boot/firmware/config.txt
dtoverlay=allo-boss-dac-pcm512x-audio

I rebooted the raspberry and saw the board in the output devices.
The problem is that the volume level is still low. For the test, I set the Volume and everything is fine with the volume level there. Please help me figure out what the problem is.
 

dobrynin

Member
Joined
Dec 21, 2023
Messages
22
Likes
2
I figured it out. I set the volume here to 100 and now it's right. Now the correction...
Once again, thank you all so much for your help!

1713382303985.jpeg
 

GNK

Member
Joined
Feb 9, 2022
Messages
50
Likes
78
Location
ROK
I think I've read this thread in its entirety, but can anyone guide me on how I can use this application without a Raspberry Pi, using only PC with Windows?
This thread is a very nice guide, but I think it's only useful for someone with a Raspberry Pi. It looks like a lot of syntax needs to be modified on Windows, for example using Alsa as a capture program. I looked at the official tutorial on GitHub, but I there's also lack of information based on Windows. There's a very high barrier to entry for normal people who are used to GUIs. :(
Maybe it's because Windows-only users can access to EQAPO, a much more user-friendly application, but I want to give this a try.
 

GNK

Member
Joined
Feb 9, 2022
Messages
50
Likes
78
Location
ROK
Go here: https://github.com/HEnquist/camilladsp

Under the Table of Contents, the Installing link provides directions for different OSs, including Windows.
Yes I read it thoroughly and manged to start the program. But it's just running.(as blank)
All the instructions for setting it seem to require at least intermediate level of programming or something.
For example, their step by step guide starts with
Here let's assume we already figured out all the Loopbacks etc and already know the devices to use.
I'm using ultralite mk5 as well, but the yaml from this thread doesn't work.
So I was wondering if there's a more kinder guidance like this thread, but for Windows-only users.
 
Last edited:

terryforsythe

Addicted to Fun and Learning
Forum Donor
Joined
May 4, 2022
Messages
507
Likes
557
So I was wondering if there's a more kinder guidance like this thread, but for Windows-only users.
Not that I have come across, but it is not something for which I have looked. You might search the diyAudio forum. There might be something there on it.

Sorry I can't be of further help.
 

terryforsythe

Addicted to Fun and Learning
Forum Donor
Joined
May 4, 2022
Messages
507
Likes
557
But it's just running.(as blank)
One thing that comes to mind. To access the CamillaDSP user interface I use a web browser. I enter the IP address of my Raspberry Pi followed by a colon and the port identifier, e.g.: 192.168.0.100:5005

You may need to use a web browser on your Windows machine to access the local port. I'm not sure whether it is 5005 in Windows though, but it is worth a shot. You may need to google how to use a web browser to access a local port in Windows - I have never tried it.

EDIT: Maybe try entering the following in the address bar of your web browser: 127.0.0.1:5005
 

Lukas Fischer

New Member
Joined
Feb 20, 2023
Messages
3
Likes
2
Everytime camill DSP goes into state "paused" i get a loud deep pop noise as if you would unplugg something from a running sound system. Played over AppleAirplay to an hifiberry dac+dsp card.

I already tried switching sample rates, buffer - the system log says:

"2024-04-22 09:51:27.235478 WARN [src/alsadevice.rs:138] PB: Prepare playback after buffer underrun"
 

Attachments

  • Screenshot 2024-04-22 100203.png
    Screenshot 2024-04-22 100203.png
    359 KB · Views: 12

dobrynin

Member
Joined
Dec 21, 2023
Messages
22
Likes
2
Everytime camill DSP goes into state "paused" i get a loud deep pop noise as if you would unplugg something from a running sound system. Played over AppleAirplay to an hifiberry dac+dsp card.

I already tried switching sample rates, buffer - the system log says:

"2024-04-22 09:51:27.235478 WARN [src/alsadevice.rs:138] PB: Prepare playback after buffer underrun"
Hi.
I can't tell you about your loud click question, but I have another question about Airplay – do you have a delay when starting playback or switching tracks for 1-2 seconds?
 

Lukas Fischer

New Member
Joined
Feb 20, 2023
Messages
3
Likes
2
I wish I knew how to get rid of this delay, I really don't like it ((
i'm not really a linux audio guy - but a windows, & i guess its pretty much the same:
i know that delay depends on the buffer. the better your system is the smaller you can set your buffer to reduce that (processing) delay. (dependend on driver, your system per se the system ( live audio processing capability) and the interface you use)
i guess its the same with camilla dsp.

On windows i use the software latencymon https://www.resplendence.com/latencymon to find processes that interrupt that live audio playback capabilities...
 

phofman

Addicted to Fun and Learning
Joined
Apr 13, 2021
Messages
507
Likes
332
I wish I knew how to get rid of this delay, I really don't like it ((
Is it actually possible? https://github.com/mikebrady/shairport-sync?tab=readme-ov-file#latency-stuffing-timing :

AirPlay protocols use an agreed latency – a time lag or delay – between the time represented by a sound sample's timestamp and the time it is actually played by the audio output device, typically a Digital to Audio Converter (DAC). Latency gives players time to compensate for network delays, processing time variations and so on. The latency is specified by the audio source when it negotiates with Shairport Sync. AirPlay sources set a latency of around 2.0 to 2.25 seconds. AirPlay 2 can use shorter latencies, around half a second.
 
OP
M

mdsimon2

Major Contributor
Forum Donor
Joined
Oct 20, 2020
Messages
2,524
Likes
3,399
Location
Detroit, MI
Everytime camill DSP goes into state "paused" i get a loud deep pop noise as if you would unplugg something from a running sound system. Played over AppleAirplay to an hifiberry dac+dsp card.

I already tried switching sample rates, buffer - the system log says:

"2024-04-22 09:51:27.235478 WARN [src/alsadevice.rs:138] PB: Prepare playback after buffer underrun"

If you delete the entries in silence_treshold and silence_timeout CamillaDSP will never pause and stay in the running state. Might be a way to solve it.

Michael
 

kerwin

New Member
Joined
Apr 27, 2024
Messages
3
Likes
0
I've spend a little more time i'd be willing to admit trying to get Camilladsp setup on my RPi and believe to be stuck.
Followed the installation guide, but i think there's either a problem with my config file or the way my Octa Capture is handled by ubuntu?
This is as far as i'm getting trying to boot camilla:

I'm getting the error
2024-04-27 14:08:19.958993 ERROR [src/bin.rs:307] Capture error: ALSA function 'snd_pcm_hw_params_set_channels' failed with error 'EINVAL: Invalid argument'

I've attached the log and config file, i really hope there is somebody able to get me going; i'dd really love to get this working!
Thanks in advance

Log
Code:
024-04-27 14:08:19.728271 INFO [src/bin.rs:683] CamillaDSP version 2.0.3
2024-04-27 14:08:19.728381 INFO [src/bin.rs:684] Running on linux, aarch64
2024-04-27 14:08:19.728464 DEBUG [src/bin.rs:728] Loaded state: None
2024-04-27 14:08:19.728485 DEBUG [src/bin.rs:732] Using command line argument for initial volume
2024-04-27 14:08:19.728499 DEBUG [src/bin.rs:755] Using default initial mute
2024-04-27 14:08:19.728512 DEBUG [src/bin.rs:765] Initial mute: [false, false, false, false, false]
2024-04-27 14:08:19.728528 DEBUG [src/bin.rs:766] Initial volume: [-40.0, -40.0, -40.0, -40.0, -40.0]
2024-04-27 14:08:19.728551 DEBUG [src/bin.rs:768] Read config file Some("/home/kerwin/camilladsp/configs/octacapture.yml")
2024-04-27 14:08:19.730326 DEBUG [src/bin.rs:808] Config is valid
2024-04-27 14:08:19.730967 DEBUG [src/socketserver.rs:432] Start websocket server on 127.0.0.1:1234
2024-04-27 14:08:19.731320 DEBUG [src/bin.rs:994] Wait for config
2024-04-27 14:08:19.731357 DEBUG [src/bin.rs:1010] Waiting to receive a command
2024-04-27 14:08:19.731374 DEBUG [src/bin.rs:1013] Config change command received
2024-04-27 14:08:19.731390 DEBUG [src/bin.rs:999] New config is available and there are no queued commands, continuing
2024-04-27 14:08:19.731403 DEBUG [src/bin.rs:1036] Config ready, start processing
2024-04-27 14:08:19.732087 DEBUG [src/bin.rs:157] Using channels [false, false, true, true]
2024-04-27 14:08:19.732013 DEBUG [src/filters.rs:488] Build new pipeline
2024-04-27 14:08:19.732505 DEBUG [src/processing.rs:19] build filters, waiting to start processing loop
2024-04-27 14:08:19.954234 DEBUG [src/alsadevice.rs:334] Available Capture devices: [("hw:Loopback,0,0", "Loopback, Loopback PCM, subdevice #0"), ("hw:Loopback,0,1", "Loopback, Loopback PCM, subdevice #1"), ("hw:Loopback,0,2", "Loopback, Loopback PCM, subdevice #2"), ("hw:Loopback,0,3", "Loopback, Loopback PCM, subdevice #3"), ("hw:Loopback,0,4", "Loopback, Loopback PCM, subdevice #4"), ("hw:Loopback,0,5", "Loopback, Loopback PCM, subdevice #5"), ("hw:Loopback,0,6", "Loopback, Loopback PCM, subdevice #6"), ("hw:Loopback,0,7", "Loopback, Loopback PCM, subdevice #7"), ("hw:Loopback,1,0", "Loopback, Loopback PCM, subdevice #0"), ("hw:Loopback,1,1", "Loopback, Loopback PCM, subdevice #1"), ("hw:Loopback,1,2", "Loopback, Loopback PCM, subdevice #2"), ("hw:Loopback,1,3", "Loopback, Loopback PCM, subdevice #3"), ("hw:Loopback,1,4", "Loopback, Loopback PCM, subdevice #4"), ("hw:Loopback,1,5", "Loopback, Loopback PCM, subdevice #5"), ("hw:Loopback,1,6", "Loopback, Loopback PCM, subdevice #6"), ("hw:Loopback,1,7", "Loopback, Loopback PCM, subdevice #7"), ("hw:OCTACAPTURE,0,0", "OCTA-CAPTURE, USB Audio, subdevice #0"), ("null", "Discard all samples (playback) or generate zero samples (capture)"), ("hw:CARD=Loopback,DEV=0", "Loopback, Loopback PCM\nDirect hardware device without any conversions"), ("hw:CARD=Loopback,DEV=1", "Loopback, Loopback PCM\nDirect hardware device without any conversions"), ("plughw:CARD=Loopback,DEV=0", "Loopback, Loopback PCM\nHardware device with all software conversions"), ("plughw:CARD=Loopback,DEV=1", "Loopback, Loopback PCM\nHardware device with all software conversions"), ("default:CARD=Loopback", "Loopback, Loopback PCM\nDefault Audio Device"), ("sysdefault:CARD=Loopback", "Loopback, Loopback PCM\nDefault Audio Device"), ("front:CARD=Loopback,DEV=0", "Loopback, Loopback PCM\nFront output / input"), ("dsnoop:CARD=Loopback,DEV=0", "Loopback, Loopback PCM\nDirect sample snooping device"), ("dsnoop:CARD=Loopback,DEV=1", "Loopback, Loopback PCM\nDirect sample snooping device"), ("hw:CARD=OCTACAPTURE,DEV=0", "OCTA-CAPTURE, USB Audio\nDirect hardware device without any conversions"), ("plughw:CARD=OCTACAPTURE,DEV=0", "OCTA-CAPTURE, USB Audio\nHardware device with all software conversions"), ("default:CARD=OCTACAPTURE", "OCTA-CAPTURE, USB Audio\nDefault Audio Device"), ("sysdefault:CARD=OCTACAPTURE", "OCTA-CAPTURE, USB Audio\nDefault Audio Device"), ("front:CARD=OCTACAPTURE,DEV=0", "OCTA-CAPTURE, USB Audio\nFront output / input"), ("dsnoop:CARD=OCTACAPTURE,DEV=0", "OCTA-CAPTURE, USB Audio\nDirect sample snooping device")]
2024-04-27 14:08:19.958625 DEBUG [src/alsadevice.rs:352] Capture: supported channels, min: 12, max: 12, list: [12]
2024-04-27 14:08:19.958696 DEBUG [src/alsadevice.rs:353] Capture: setting channels to 4
2024-04-27 14:08:19.958993 ERROR [src/bin.rs:307] Capture error: ALSA function 'snd_pcm_hw_params_set_channels' failed with error 'EINVAL: Invalid argument'
2024-04-27 14:08:19.959036 DEBUG [src/bin.rs:309] Error while starting, release barrier
2024-04-27 14:08:19.977977 DEBUG [src/alsadevice.rs:334] Available Playback devices: [("hw:Loopback,0,0", "Loopback, Loopback PCM, subdevice #0"), ("hw:Loopback,0,1", "Loopback, Loopback PCM, subdevice #1"), ("hw:Loopback,0,2", "Loopback, Loopback PCM, subdevice #2"), ("hw:Loopback,0,3", "Loopback, Loopback PCM, subdevice #3"), ("hw:Loopback,0,4", "Loopback, Loopback PCM, subdevice #4"), ("hw:Loopback,0,5", "Loopback, Loopback PCM, subdevice #5"), ("hw:Loopback,0,6", "Loopback, Loopback PCM, subdevice #6"), ("hw:Loopback,0,7", "Loopback, Loopback PCM, subdevice #7"), ("hw:Loopback,1,0", "Loopback, Loopback PCM, subdevice #0"), ("hw:Loopback,1,1", "Loopback, Loopback PCM, subdevice #1"), ("hw:Loopback,1,2", "Loopback, Loopback PCM, subdevice #2"), ("hw:Loopback,1,3", "Loopback, Loopback PCM, subdevice #3"), ("hw:Loopback,1,4", "Loopback, Loopback PCM, subdevice #4"), ("hw:Loopback,1,5", "Loopback, Loopback PCM, subdevice #5"), ("hw:Loopback,1,6", "Loopback, Loopback PCM, subdevice #6"), ("hw:Loopback,1,7", "Loopback, Loopback PCM, subdevice #7"), ("hw:b1,0,0", "bcm2835 HDMI 1, bcm2835 HDMI 1, subdevice #0"), ("hw:b1,0,1", "bcm2835 HDMI 1, bcm2835 HDMI 1, subdevice #1"), ("hw:b1,0,2", "bcm2835 HDMI 1, bcm2835 HDMI 1, subdevice #2"), ("hw:b1,0,3", "bcm2835 HDMI 1, bcm2835 HDMI 1, subdevice #3"), ("hw:Headphones,0,0", "bcm2835 Headphones, bcm2835 Headphones, subdevice #0"), ("hw:Headphones,0,1", "bcm2835 Headphones, bcm2835 Headphones, subdevice #1"), ("hw:Headphones,0,2", "bcm2835 Headphones, bcm2835 Headphones, subdevice #2"), ("hw:Headphones,0,3", "bcm2835 Headphones, bcm2835 Headphones, subdevice #3"), ("hw:OCTACAPTURE,0,0", "OCTA-CAPTURE, USB Audio, subdevice #0"), ("null", "Discard all samples (playback) or generate zero samples (capture)"), ("hw:CARD=Loopback,DEV=0", "Loopback, Loopback PCM\nDirect hardware device without any conversions"), ("hw:CARD=Loopback,DEV=1", "Loopback, Loopback PCM\nDirect hardware device without any conversions"), ("plughw:CARD=Loopback,DEV=0", "Loopback, Loopback PCM\nHardware device with all software conversions"), ("plughw:CARD=Loopback,DEV=1", "Loopback, Loopback PCM\nHardware device with all software conversions"), ("default:CARD=Loopback", "Loopback, Loopback PCM\nDefault Audio Device"), ("sysdefault:CARD=Loopback", "Loopback, Loopback PCM\nDefault Audio Device"), ("front:CARD=Loopback,DEV=0", "Loopback, Loopback PCM\nFront output / input"), ("surround21:CARD=Loopback,DEV=0", "Loopback, Loopback PCM\n2.1 Surround output to Front and Subwoofer speakers"), ("surround40:CARD=Loopback,DEV=0", "Loopback, Loopback PCM\n4.0 Surround output to Front and Rear speakers"), ("surround41:CARD=Loopback,DEV=0", "Loopback, Loopback PCM\n4.1 Surround output to Front, Rear and Subwoofer speakers"), ("surround50:CARD=Loopback,DEV=0", "Loopback, Loopback PCM\n5.0 Surround output to Front, Center and Rear speakers"), ("surround51:CARD=Loopback,DEV=0", "Loopback, Loopback PCM\n5.1 Surround output to Front, Center, Rear and Subwoofer speakers"), ("surround71:CARD=Loopback,DEV=0", "Loopback, Loopback PCM\n7.1 Surround output to Front, Center, Side, Rear and Woofer speakers"), ("dmix:CARD=Loopback,DEV=0", "Loopback, Loopback PCM\nDirect sample mixing device"), ("dmix:CARD=Loopback,DEV=1", "Loopback, Loopback PCM\nDirect sample mixing device"), ("hw:CARD=b1,DEV=0", "bcm2835 HDMI 1, bcm2835 HDMI 1\nDirect hardware device without any conversions"), ("plughw:CARD=b1,DEV=0", "bcm2835 HDMI 1, bcm2835 HDMI 1\nHardware device with all software conversions"), ("default:CARD=b1", "bcm2835 HDMI 1, bcm2835 HDMI 1\nDefault Audio Device"), ("sysdefault:CARD=b1", "bcm2835 HDMI 1, bcm2835 HDMI 1\nDefault Audio Device"), ("dmix:CARD=b1,DEV=0", "bcm2835 HDMI 1, bcm2835 HDMI 1\nDirect sample mixing device"), ("hw:CARD=Headphones,DEV=0", "bcm2835 Headphones, bcm2835 Headphones\nDirect hardware device without any conversions"), ("plughw:CARD=Headphones,DEV=0", "bcm2835 Headphones, bcm2835 Headphones\nHardware device with all software conversions"), ("default:CARD=Headphones", "bcm2835 Headphones, bcm2835 Headphones\nDefault Audio Device"), ("sysdefault:CARD=Headphones", "bcm2835 Headphones, bcm2835 Headphones\nDefault Audio Device"), ("dmix:CARD=Headphones,DEV=0", "bcm2835 Headphones, bcm2835 Headphones\nDirect sample mixing device"), ("hw:CARD=OCTACAPTURE,DEV=0", "OCTA-CAPTURE, USB Audio\nDirect hardware device without any conversions"), ("plughw:CARD=OCTACAPTURE,DEV=0", "OCTA-CAPTURE, USB Audio\nHardware device with all software conversions"), ("default:CARD=OCTACAPTURE", "OCTA-CAPTURE, USB Audio\nDefault Audio Device"), ("sysdefault:CARD=OCTACAPTURE", "OCTA-CAPTURE, USB Audio\nDefault Audio Device"), ("front:CARD=OCTACAPTURE,DEV=0", "OCTA-CAPTURE, USB Audio\nFront output / input"), ("surround21:CARD=OCTACAPTURE,DEV=0", "OCTA-CAPTURE, USB Audio\n2.1 Surround output to Front and Subwoofer speakers"), ("surround40:CARD=OCTACAPTURE,DEV=0", "OCTA-CAPTURE, USB Audio\n4.0 Surround output to Front and Rear speakers"), ("surround41:CARD=OCTACAPTURE,DEV=0", "OCTA-CAPTURE, USB Audio\n4.1 Surround output to Front, Rear and Subwoofer speakers"), ("surround50:CARD=OCTACAPTURE,DEV=0", "OCTA-CAPTURE, USB Audio\n5.0 Surround output to Front, Center and Rear speakers"), ("surround51:CARD=OCTACAPTURE,DEV=0", "OCTA-CAPTURE, USB Audio\n5.1 Surround output to Front, Center, Rear and Subwoofer speakers"), ("surround71:CARD=OCTACAPTURE,DEV=0", "OCTA-CAPTURE, USB Audio\n7.1 Surround output to Front, Center, Side, Rear and Woofer speakers"), ("iec958:CARD=OCTACAPTURE,DEV=0", "OCTA-CAPTURE, USB Audio\nIEC958 (S/PDIF) Digital Audio Output"), ("dmix:CARD=OCTACAPTURE,DEV=0", "OCTA-CAPTURE, USB Audio\nDirect sample mixing device")]
2024-04-27 14:08:19.981141 DEBUG [src/alsadevice.rs:352] Playback: supported channels, min: 10, max: 10, list: [10]
2024-04-27 14:08:19.981210 DEBUG [src/alsadevice.rs:353] Playback: setting channels to 4
2024-04-27 14:08:19.981385 DEBUG [src/bin.rs:312] Wait for playback thread to exit..
2024-04-27 14:08:19.981586 DEBUG [src/processing.rs:21] Processing loop starts now!
2024-04-27 14:08:19.981743 DEBUG [src/bin.rs:1038] Processing ended with status Ok(Restart)
2024-04-27 14:08:19.981778 DEBUG [src/bin.rs:1052] Restarting with new config
2024-04-27 14:08:19.981791 DEBUG [src/bin.rs:994] Wait for config

Config File:
Code:
description: null
devices:
  adjust_period: 10
  capture:
    channels: 4
    device: hw:OCTACAPTURE
    format: S32LE
    type: Alsa
  capture_samplerate: 41000
  chunksize: 1024
  enable_rate_adjust: false
  playback:
    channels: 4
    device: hw:OCTACAPTURE
    format: S32LE
    type: Alsa
  queuelimit: 4
  rate_measure_interval: 1
  samplerate: 41000
  silence_threshold: -100
  silence_timeout: 5
  stop_on_rate_change: false
  target_level: 1024
  volume_ramp_time: null
filters: null
mixers:
  4x4:
    channels:
      in: 4
      out: 4
    description: null
    mapping:
    - dest: 0
      mute: false
      sources:
      - channel: 2
        gain: 0
        inverted: false
        mute: false
        scale: null
    - dest: 1
      mute: false
      sources:
      - channel: 3
        gain: 0
        inverted: false
        mute: false
        scale: null
    - dest: 2
      mute: false
      sources:
      - channel: 2
        gain: 0
        inverted: false
        mute: false
        scale: null
    - dest: 3
      mute: false
      sources:
      - channel: 3
        gain: 0
        inverted: false
        mute: false
        scale: null
pipeline:
- bypassed: null
  description: null
  name: 4x4
  type: Mixer
processors: null
title: Analog
 
Top Bottom