As I explained above, I looked at the hw_params
in procfs
after verifying with speaker-test
. None of these are Roon tools–I’m investigating using the normal ALSA tooling + data exposed by the kernel.
Notice that speaker-test
says that it is sending S32_LE
to the kernel:
speaker-test 1.0.28
Playback device is default
Stream parameters are 192000Hz, S32_LE, 1 channels
Using 16 octaves of pink noise
Rate set to 192000Hz (requested 192000Hz)
Buffer size range from 512 to 32768
Period size range from 512 to 32768
Using max buffer size 32768
Periods = 4
was set period_size = 8192
was set buffer_size = 32768
0 - Front Left
Time per period = 2.831619
0 - Front Left
This is what the kernel is reporting in the hw_params
for the device while that is going on. This says that the kernel is sending a 16bit stream to the hardware:
access: MMAP_INTERLEAVED
format: S16_LE
subformat: STD
channels: 1
rate: 192000 (192000/1)
period_size: 8192
buffer_size: 32768
@RBM’s alsacap
output is consistent with my findings:
Device 1, ID 'bcm2835 ALSA', name 'bcm2835 IEC958/HDMI', 1 subdevices (1 available)
2..8 channels, sampling rate 44100..192000 Hz
Sample formats: S16_LE
Subdevice 0, name `subdevice #0'
Drivers that support 24 or 32 bit output report more sample formats than S16_LE
–things like S32_LE
, S24_LE
, S24_3LE
, etc.
What that tells me is: even if Roon sent 32bit audio to this driver, it would be truncated to 16. So there’s no point. There is nothing that we could change in our ALSA implementation to make this work because this limitation is in the driver, not in RoonBridge.
I’m going to keep poking my head in because I’m interested in how this turns out. If it starts to look like this is a problem with RoonBridge, we are interested in fixing it. Right now, it looks like the next step here is to get the driver advertising support for a 24 or 32bit sample format. If that’s fixed and it’s still not working, we’ll certainly have another look.