Snakeoil Forums

Full Version: CamillaDSP for Room Correction
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3
(09-Sep-2023, 01:00 PM)Snoopy8 Wrote: [ -> ]
(24-Aug-2023, 10:09 PM)hkphantomgtr Wrote: [ -> ]
(24-Aug-2023, 07:12 PM)Snoopy8 Wrote: [ -> ]
(24-Aug-2023, 01:14 PM)hkphantomgtr Wrote: [ -> ]Would you please advise or share your experience more about installing and running CamillaDSP in SO?  Much appreciated.
Please have a look at post #9 in this thread. It contains all my notes from my original install.

Alright, Thanks a lot, Snoopy8!
Did you manage to get CamillaDSP working?

My NUC failed and I had to build a new box using Ubuntu 22.04. I followed the instructions on post #9 and it worked. Also, no need to install Pulse Audio. However, I have the advantage that I had a working config file doing convolution.

I'm sorry that I didn't try.  Now I'm testing another OS with build in convolution dsp filter.
Recommend rebooting after enabling or disabling CPUsets within SnakeOil. Just realised that the maximum latency goes crazy after the change.
Notes for AK for 1.3.1 implementation of CamillaDSP.

Been using this webpage to routinely reinstall CamillaDSP for 1.3 testing.  Have not done the web gui.
https://github.com/HEnquist/camilladsp-config

There is a good long tutorial on ASR to install CamillaDSP ​on a Pi. Has links to other web resources as well.
https://www.audiosciencereview.com/forum...ial.29656/

Some things that require attention:
  • config.yaml is the critical configuration file.  Suggest providing several standard ones like what Moode does.  Users can, of course create their own config files but put warning that debugging can be painful.  
  • While config file has rate and format settings, need to ensure that asound.conf has matching settings
  • Set priority of CamillaDSP.service to less than 50.  Otherwise, it could interfere with IRQ of USB, causing huge latency problems.
  • Suggest setting aside a CPU for DSP using cpuset. And a separate CPU for player.  LMS has a much higher max latency than Mpd 
Happy to assist with getting CamillaDSP into SnakeOil. AK, please let me know what you need.
(23-Dec-2023, 06:58 AM)Snoopy8 Wrote: [ -> ]Happy to assist with getting CamillaDSP into SnakeOil. AK, please let me know what you need.
Need help testing everything is working is a good start, more importantly not break as an on-going concern. As I'm unlikely going to use DSP in my home rig. 

But before that, just aiming to get the 1.3.0 out this weekend, and focus on 1.3.1 immediately after.
(23-Dec-2023, 07:12 AM)agent_kith Wrote: [ -> ]Need help testing everything is working is a good start, more importantly not break as an on-going concern.
Have both my NUC and Mercury (CM4) running CamillaDSP as system service. The use of loopback to capture and process the signal may throw users off.  And it did interfere with the 1.3 firmware upgrade, with the Music Player stuck until I stopped CamillaDSP.  

Having CamillaDSP in the chain can also cause latency problems.  Add in CPUsets and it can be a headache.  I have gone back to using standard SO CPUsets and minimum change in process priority to reduce the number of variables to manage. As an aside, my latency problems were caused by using too large a convolution filter (lesson learnt: don't be greedy!)

The biggest danger is users being too ambitious with the custom use of DSP and we may end up spending too much time solving these. Note that my use is limited to convolution.  Any other use case will be new for me.
​​​​​​
Having said all that, the documentation is much better than I first started. And I have both X86 and Pi versions running which will make testing easier.
 
(23-Dec-2023, 07:12 AM)agent_kith Wrote: [ -> ]As I'm unlikely going to use DSP in my home rig. 
You should give convolution room correction a go. I see it as having more of an impact than real time kernels.
(31-Dec-2023, 11:37 AM)Snoopy8 Wrote: [ -> ]Have both my NUC and Mercury (CM4) running CamillaDSP as system service. The use of loopback to capture and process the signal may throw users off.  And it did interfere with the 1.3 firmware upgrade, with the Music Player stuck until I stopped CamillaDSP.  

Having CamillaDSP in the chain can also cause latency problems.  Add in CPUsets and it can be a headache.  I have gone back to using standard SO CPUsets and minimum change in process priority to reduce the number of variables to manage. As an aside, my latency problems were caused by using too large a convolution filter (lesson learnt: don't be greedy!)

The biggest danger is users being too ambitious with the custom use of DSP and we may end up spending too much time solving these. Note that my use is limited to convolution.  Any other use case will be new for me.
​​​​​​
Having said all that, the documentation is much better than I first started. And I have both X86 and Pi versions running which will make testing easier.
Thanks for that. I am/was a bit too ambitious thinking I can release 1.3.1 in 10 days time with Convo added to the WebApp. Unfortunately in 10 days I only managed to add the page, and not actually populate the contents.

Ten days sound like a long time, but it's gone just like that. Confused 2

Did get a lot of things done though, just don't feel like it's enough. Maybe it's because I'm getting older, things just can't get finished quickly.

(31-Dec-2023, 11:37 AM)Snoopy8 Wrote: [ -> ]You should give convolution room correction a go. I see it as having more of an impact than real time kernels.
My worry is my computer are so low powered I'm not confident any advantage it brings will be offset by the additional power it consumes. Tongue
CamillaDSP has come a long way since I first started using it.  For Pi users, there is now a good installation guide which has a GUI to make things a lot simpler to use.
https://github.com/mdsimon2/RPi-CamillaDSP
(21-May-2021, 08:38 PM)Snoopy8 Wrote: [ -> ]CamiilaDSP works by intercepting the audio signal played to a "Loopback" device, applying DSP and then sending to an Alsa hardware port e.g. hw:1,0.

[Image: Initial-camilladsp.jpg]

The CamiilaDSP documentation is excellent and extensive but it does take a while to go through. Not sure how many people want to install CamillaDSP but here are some tips.
  1. Download the pre-built Linux versions, either amd64 or armv7 (for pi)
  2. Use WinSCP to transfer files to the SnakeOil home folder and use its editor to modify files; the home folder is a useful location to store all the files
  3. Use either a monitor attached to SnakeOil machine or PuTTY to execute commands; remember to use sudo
  4. The steps to configure are largely correct. Follow the commands in each step, using the information in the following steps.
  5. Pre-built Linux version needs a PulseAudio library (sudo apt-get install -y libpulse0)
  6. Load loopback driver using aloop.conf
  7. Edit asound.conf format and sampling rate; if possible, use playback device values
  8. Use this simple config.yaml as a start
    Code:
    devices:
      samplerate: 44100
      chunksize: 1024
      enable_rate_adjust: true
      capture_samplerate: 44100
      capture:
        type: Alsa
        channels: 2
        device: "hw:Loopback,1"
        format: S16LE
      playback:
        type: Alsa
        channels: 2
        device: "hw:Control,0"
        format: S16LE
  9. If you do not know the details of devices, use this.  Remember to use sudo with aplay.
  10. Check config file formatting by running command: camilladsp -c config.yaml
  11. Run CamillaDSP without the "-c" and play music to the first "Loopback" device in SnakeOil.  It may take time to get a working config.yaml (easy to make typo errors!). But if music plays through first "Loopback" device, you have CamillaDSP running. You can then add filters etc.
  12. To setup a service use this camilladsp.service file.  Please remember to change "/path/to" in file.
    Code:
    [Unit]
    Description=CamillaDSP Daemon
    After=syslog.target
    StartLimitIntervalSec=10
    StartLimitBurst=10

    [Service]
    Type=simple
    ExecStart=/usr/local/bin/camilladsp /path/to/config.yaml
    Restart=always
    RestartSec=1
    StandardOutput=syslog
    StandardError=syslog
    SyslogIdentifier=camilladsp
    User=root
    Group=root
    CPUSchedulingPolicy=fifo
    CPUSchedulingPriority=10

    [Install]
    WantedBy=multi-user.target
Please note that this install works with 20.04/1.2.0.  It does not work with 16.04/1.1.x because the kernel does not include Snd-aloop module; the kernel needs to be rebuilt with that module.
Hi, I would like to get Camilla dsp working on SO (1.4 beta Intel CPU, Ubuntu 24.04) with LMS + UPnP Plugin, since my player works over UPnP. I read all the explanations how to install, but nowhere it is expained for UPnP - I guess it then is not via alsa or alsa-loop? STDIn/Out...?
(7 hours ago)skel Wrote: [ -> ]Hi, I would like to get Camilla dsp working on SO (1.4 beta Intel CPU, Ubuntu 24.04) with LMS + UPnP Plugin, since my player works over UPnP. I read all the explanations how to install, but nowhere it is expained for UPnP - I guess it then is not via alsa or alsa-loop? STDIn/Out...?
CamillaDSP needs to work with an ALSA output. Hence not possible to use CamillaDSP on LMS (with UPnP plugin). Perhaps try the LMS DSP plugin?
(23-Dec-2023, 06:58 AM)Snoopy8 Wrote: [ -> ]Happy to assist with getting CamillaDSP into SnakeOil. AK, please let me know what you need.
Just the usual testing and suggestions for improvements and implementations will do. This will come in 1.4.1 (with 1.4.0 as the "bsaeline")
Pages: 1 2 3