Audio goes through HDMI instead of AUX cable.

Ok, thanks.

(post withdrawn by author, will be automatically deleted in 24 hours unless flagged)

Wait, so HDMI and Headphones are enabled due to snd_bcm2835.enable_hdmi=1 snd_bcm2835.enable_headphones=1 but the balenaOS version’s default audio is HDMI?

Hi Jose, the audio chip on the Pi boards basically has two modes of operation.

In one mode (snd_bcm2835.enable_hdmi=0 snd_bcm2835.enable_headphones=0), the one that’s traditionally been the default, you get 1 “virtual” sound card reported by ALSA. This soundcard is shared for both HDMI and headphones output with a parameter that allows switching from one to the other with a command such as amixer --quiet cset numid=3 1. The entryscript runs this command to select the desired output when it runs.

Setting snd_bcm2835.enable_hdmi=1 snd_bcm2835.enable_headphones=1 instructs ALSA to create separate sound cards for HDMI and headphones jack so there is no need of running a command that switches to either. This is the reason for the bug here, when the entryscript runs the command it fails because the existing sound cards in this case don’t have the “switch output parameter”.

I’m working on a fix in this moment, should be ready in a few moments. I’ll let you know.

I understand.

Still working on it, taking a bit more than expected :smiley:

Oh.

Why is it taking longer though?

So I’ve got the fix almost figured out but I’ll need a bit more time to test it properly. I’ll work on it a bit more later today, but this might very well slip into tomorrow as it’s getting late here. I’ll keep you posted.

Hi Jose, I just merged https://github.com/balenablocks/audio/pull/40 which should fix the problem you were having. You will need to re-deploy balenaSound to your devices, no need to re-pull the code though, following the same deploy alternative you used in the first place. Let me know if you are still having problems with this but in my testing it seems to run fine now.

Ok, I will test it.

It doesn’t work. It stays at Applied configuration change {"SUPERVISOR_DELTA":"1"} and doesn’t continue, I was waiting 1 hour for a change and nothing.

Oh, now it says its starting after changing AUDIO_OUTPUT to AUTO.

Now it just freezes there.

Hi Jose, did you get it to work? Feel free to share logs if the Pi is still freezing for you.

nope

Hey Jose, could you please share the logs of the Pi? Thanks!

There aren’t.

It’s just stuck on development mode.

Hello Jose,

Would you be able to flash a fresh balenaSound image to the Raspberry Pi and try to run it to see how it goes? It would also help if we can get support access to the device once it’s running to see if we can spot what the problem is.

Cheers,
Nico.