Audio issue with a fresh installation of balenaOS with MS-B120

Hello,

I was testing the audio Analog & HDMI with 2 devices MS-B120 & RPI3 using the following instructions :

balena run --rm --device /dev/snd -it ubuntu:latest
apt update && apt install alsa-utils
speaker-test
exit

The audio works fine with RPI3, but it doesn’t with MS-B120. I’m aware that this device isn’t officially supported by balenaOS, but I’d like to get some hints about how to make the audio works (incompatible driver or something)

I have tried the intel-nuc development image & I have tried also to compile the generic balena-intel yocto-based project, but without a positive result

I appreciate your help and guidance.

@omarsastec assuming that the MS-B120 booted and you tried to run the balena run ... command you mentioned. Can you check if dmesg shows any sound device related errors? Also is there a /dev/snd device present and do you see any sound devices when you do aplay -L?

@mbalamat:

Yes, there’s a /dev/snd device present :

root@c0ca7a7640e3:/# ls /dev/snd/
controlC0  pcmC0D0c  pcmC0D0p  pcmC0D3p  pcmC0D7p  pcmC0D8p  timer

And these are the available sound devices (executed inside the ubuntu container, because the aplay binary doesn’t exist in the balenaOS host)

root@c0ca7a7640e3:/# aplay -L
null
    Discard all samples (playback) or generate zero samples (capture)
default:CARD=PCH
    HDA Intel PCH, ALC283 Analog
    Default Audio Device
sysdefault:CARD=PCH
    HDA Intel PCH, ALC283 Analog
    Default Audio Device
front:CARD=PCH,DEV=0
    HDA Intel PCH, ALC283 Analog
    Front speakers
surround21:CARD=PCH,DEV=0
    HDA Intel PCH, ALC283 Analog
    2.1 Surround output to Front and Subwoofer speakers
surround40:CARD=PCH,DEV=0
    HDA Intel PCH, ALC283 Analog
    4.0 Surround output to Front and Rear speakers
surround41:CARD=PCH,DEV=0
    HDA Intel PCH, ALC283 Analog
    4.1 Surround output to Front, Rear and Subwoofer speakers
surround50:CARD=PCH,DEV=0
    HDA Intel PCH, ALC283 Analog
    5.0 Surround output to Front, Center and Rear speakers
surround51:CARD=PCH,DEV=0
    HDA Intel PCH, ALC283 Analog
    5.1 Surround output to Front, Center, Rear and Subwoofer speakers
surround71:CARD=PCH,DEV=0
    HDA Intel PCH, ALC283 Analog
    7.1 Surround output to Front, Center, Side, Rear and Woofer speakers
hdmi:CARD=PCH,DEV=0
    HDA Intel PCH, HDMI 0
    HDMI Audio Output
hdmi:CARD=PCH,DEV=1
    HDA Intel PCH, HDMI 1
    HDMI Audio Output
hdmi:CARD=PCH,DEV=2
    HDA Intel PCH, HDMI 2
    HDMI Audio Output
dmix:CARD=PCH,DEV=0
    HDA Intel PCH, ALC283 Analog
    Direct sample mixing device
dmix:CARD=PCH,DEV=3
    HDA Intel PCH, HDMI 0
    Direct sample mixing device
dmix:CARD=PCH,DEV=7
    HDA Intel PCH, HDMI 1
    Direct sample mixing device
dmix:CARD=PCH,DEV=8
    HDA Intel PCH, HDMI 2
    Direct sample mixing device
dsnoop:CARD=PCH,DEV=0
    HDA Intel PCH, ALC283 Analog
    Direct sample snooping device
dsnoop:CARD=PCH,DEV=3
    HDA Intel PCH, HDMI 0
    Direct sample snooping device
dsnoop:CARD=PCH,DEV=7
    HDA Intel PCH, HDMI 1
    Direct sample snooping device
dsnoop:CARD=PCH,DEV=8
    HDA Intel PCH, HDMI 2
    Direct sample snooping device
hw:CARD=PCH,DEV=0
    HDA Intel PCH, ALC283 Analog
    Direct hardware device without any conversions
hw:CARD=PCH,DEV=3
    HDA Intel PCH, HDMI 0
    Direct hardware device without any conversions
hw:CARD=PCH,DEV=7
    HDA Intel PCH, HDMI 1
    Direct hardware device without any conversions
hw:CARD=PCH,DEV=8
    HDA Intel PCH, HDMI 2
    Direct hardware device without any conversions
plughw:CARD=PCH,DEV=0
    HDA Intel PCH, ALC283 Analog
    Hardware device with all software conversions
plughw:CARD=PCH,DEV=3
    HDA Intel PCH, HDMI 0
    Hardware device with all software conversions
plughw:CARD=PCH,DEV=7
    HDA Intel PCH, HDMI 1
    Hardware device with all software conversions
plughw:CARD=PCH,DEV=8
    HDA Intel PCH, HDMI 2
    Hardware device with all software conversions

And this is the dmesg output : https://pastebin.com/0vEbYAyB

When booting the MS-B120 with live ubuntu distribution, the audio works fine. I just wanted to mention that the hardware isn’t faulty.

Hey,

So I would suggest that you see which modules and sound devices are used in Ubuntu, then setup a container with the utils required to play a sound and configure the sound output, and try to match the setup. If there are that many sound devices shown then I suspect it’s probably a sound routing problem, rather than a driver/permission thing.