I used
this to upgrade in place.
Partially out of curiosity, partially out of boredom, I gave upgrading to Trixie a shot. CamillaDSP continued working as normal, which means it will be fine for most people.
However, the upgrade broke both USB Gadget and camilladsp-setrate. camilladsp-setrate was the easiest to fix. I made sure git, build-essential and libasound2-dev all were installed, and did a clean re-install/rebuild of camilladsp-setrate. Then I did a daemon-reload, and enabled and started the new installation of camilladsp-setrate.
USB Gadget was a little more involved.
Apparently Trixie handles USB Gadget a bit differently. (
EDIT: This only is an issue if upgrading, not with a fresh install.) Here is how I got it working:
1. In /boot/firmware/config.txt I changed the dr_mode to peripheral:
[cm5]
dtoverlay=dwc2,dr_mode=peripheral
2. In /boot/firmware/cmdline.txt I changed the "modules-load" statement after "rootwait" to be as follows:
modules-load=dwc2,libcomposite
3. I created a USB Audio Class gadget: /usr/local/sbin/usb-audio-gadget.sh:
#!/bin/bash
G=/sys/kernel/config/usb_gadget/audio
modprobe libcomposite
mkdir -p $G
cd $G
echo 0x1d6b > idVendor # Linux Foundation
echo 0x0104 > idProduct # Multifunction Composite Gadget
echo 0x0100 > bcdDevice
echo 0x0200 > bcdUSB
mkdir -p strings/0x409
echo "123456789" > strings/0x409/serialnumber
echo "Raspberry Pi" > strings/0x409/manufacturer
echo "USB Audio Device" > strings/0x409/product
mkdir -p configs/c.1
mkdir -p configs/c.1/strings/0x409
echo "USB Audio Config" > configs/c.1/strings/0x409/configuration
# Create USB Audio Class Function (UAC2)
mkdir -p functions/uac2.usb0
# Playback: WiiM → Pi
echo 2 > functions/uac2.usb0/c_chmask # 2 channels input to Pi
echo 48000 > functions/uac2.usb0/c_srate # 48 kHz
# If Pi also needs to OUTPUT audio, enable playback:
echo 2 > functions/uac2.usb0/p_chmask
echo 48000 > functions/uac2.usb0/p_srate
ln -s functions/uac2.usb0 configs/c.1/
# Bind to UDC controller
ls /sys/class/udc > UDC
4. I made the new gadget executable:
sudo chmod +x /usr/local/sbin/usb-audio-gadget.sh
5. I created a service for the new gadget as /etc/systemd/system/usb-audio-gadget.service:
[Unit]
Description=USB Audio Gadget
After=multi-user.target
[Service]
Type=oneshot
ExecStart=/usr/local/sbin/usb-audio-gadget.sh
RemainAfterExit=yes
[Install]
WantedBy=multi-user.target
6. I enabled the new service:
sudo systemctl enable usb-audio-gadget
7. I rebooted.
NOTE: I do not know whether creating a new gadget is the simplest, most straight forward way to get gadget mode working with Trixie. There may be a simpler solution. But, after running out of things to try to get it working, I worked with ChatGPT to help me solve the problem. That is the solution ChatGPT recommended that worked.