Adding Alsa Loopback Interface before build

  • Hello,

    I tried to compile LE 12.2.1 with the option to use an Alsa loopback Interface.

    I changed the Kernel config file (CONFIG_SND_ALOOP=m) first before the make image process.

    But the modul has not been build, when compiling finished.

    How is it possible, to build LE with the apropriate aloop modul? Either fixed in kernel or as a modul?

    FYI; I want to use camilladsp with my LE Box (PI4b) and therefore I need a loopback interface.

    Thanks in advance.

    Best regards

    Olaf

  • Nevermind,

    I've read the GIT Wiki and will try that way (cloning, forking, editing and commiting...).

    Is this the right way:

    In my forked Git clone; edit /projects/RPi/devices/RPi4/linux/linux.aarch64.conf (add CONFIG_SND_ALOOP=m)

    Add the changed file to the forked repo:

    git add projects/RPi/devices/RPi4/linux/linux.aarch64.conf

    Download sources:

    PROJECT=RPi ARCH=aarch64 DEVICE=RPi4 tools/download-tool

    Start build process:

    PROJECT=RPi ARCH=aarch64 DEVICE=RPi4 make image

    Test the new image. Check if the loopback module exists and loads (modprobe snd-aloop)

    If succesfull:

    git commit -m "linux: enable Alsa Loopback Interface"

    ???

  • If you have a working default image building, edit projects/RPi/devices/RPi4/linux/linux.aarch64.conf to enable the module then rebuild the image and it will rebuild the kernel and update the image.

    At least that's the theory. It doesn't work for me on an Amlogic image with linux-7.3-rc2 kernel either, and diff comparing the edited conf and .config file from the kernel build folder shows the kernel has unset CONFIG_SND_ALOOP=m when processing the config; hence nothing gets built.

    I will task Claude to investigate the problem once I take a break from some other debugging. I suspect some kind of upstream kernel issue and not something on our side.

  • No mention of SND_DRIVERS there ^ so looks like a kernel bug to report and submit a fix for :)

  • Cool, it works..

    Now I need to start 2 applications (camillagui and camilladsp) as a service and load snd-aloop bofore this services.

    Therefor I have to define 3 new services under /storage/.config/system.d/, correct?

    Thanks for your support.

  • I’d build the module with =y so it’s always present and doesn’t need to be loaded. Use two services for the apps if you need to manage start order. Or do in one if they can start more in parallel. Or use one and put whatever sequence you need in a script and execute that from a service. Lots of options; probably no wrong or right and to the question :)

  • Unfortunately I did a make clean ... Oh, and recompiling takes ONLY several hours on the PI4 .

    But no Problem, I created the relevant services. It runs like a charm now.

    The loop module is loaded by a service and then Camilladsp (CDSP) and camillagui.

    Next step is remote control of volume for CDSP. CDSP is controlled over Python Websocket.

    It means, I have to put the relevant Python modules into the build tree... Duh..

    Let's see

  • Haha someone else...

    The thing is, there's a complete separate python environment with all the needed modules within camillagui_backend. If only I could use them and control parts with flirc events...

    I'll ask in the diyaudio forum.

    So for here; case closed.

    Merci bien.