HDMI audio works perfectly but I need USB audio out for my DAC to play music/watch films with my current hardware set up.
First issue:
It is difficult to get USB audio out. When I change the settings to my USB DAC in dietpi-config and reboot, there is no audio out and the HDMI still outputs audio. To fix this (https://www.raspberrypi.org/forums/viewtopic.php?t=175233), I altered /usr/share/alsa/alsa.conf with the lines:
defaults.pcm.card 1
defaults.pcm.device 0
defaults.ctl.card 1
This worked but led to my second issue.
Second issue:
Need to plug the USB out and then in to get USB working, then the audio crackles and pops.
To fix this I have tried:
Limiting output in Kodi to 44khz
Changing all Kodi audio settings as per
Playing audio out of Squeezelite (this only worked through HDMI and not USB, even when Kodi could output USB).
I get these kernel errors:
7.103112] usb 1-1.2: unable to read config index 0 descriptor/start: -110
[ 7.107457] usb 1-1.2: can't read configurations, error -110
[ 12.293067] usb 1-1.2: unable to read config index 0 descriptor/start: -110
[ 12.298313] usb 1-1.2: can't read configurations, error -110
[ 17.933073] usb 1-1.2: unable to read config index 0 descriptor/start: -110
[ 17.938258] usb 1-1.2: can't read configurations, error -110
[ 23.043165] usb 1-1.2: unable to read config index 0 descriptor/start: -110
[ 23.048184] usb 1-1.2: can't read configurations, error -110
[ 23.053595] usb 1-1-port2: unable to enumerate USB device