There is an issue with 'dmix' when using rpi3 soundcard that make impossible to mix sound. Furthermore, it is impossible to use 4a-softmixer for this soundcard.
Instruction to reproduce the issue (trying to use dmix with rpi3 soundcard) :
Replace your board's '/etc/asound.rc' file by the attached 'asound.rc' file.
Run an 'aplay -l | grep -i bcm2835' to get rpi3 soundcard alsa device id (a number between 0 and 31).
Modify the freshly replaced '/etc/asound.rc' to replace the '1' in the line 'slave {pcm "hw:1"}' (l. 10) by rpi3 soundcard alsa device id.
Copy attached 'tone-440-stereo-48000-16bits.wav' sound file to you board '/home/0' directory.
Open two terminals on your platform :
In the first one, run : aplay -D Emergency_Main /home/0/tone-440-stereo-48000-16bits.wav
In the second one, run : aplay -D Warning_Main /home/0/tone-440-stereo-48000-16bits.wav
On the second terminal, an error will be returned :
ALSA lib ../../../alsa-lib-1.1.6/src/pcm/pcm_dmix.c:1156:(snd_pcm_dmix_open) unable to open slave aplay: main:828: audio open error: Invalid argument
In attached files, you can find outputs of the error using rpi3 soundcard and the expected behaviour using a csl-cm106 soundcard.
I tried different versions of meta-raspberrypi. Although, I didn't make any progress with 4a audio today, I submitted a patch to update meta-raspberrypi to the latest version of rocko. I still have to try with different device tree overlays.
Next week I will be in vacation. I plan to continue investigating this task after that.
Thanks, Leon
Jan-Simon Moeller
July 25, 2018 at 8:11 PM
Did you try with
Stephane Desneux
July 25, 2018 at 7:52 PM
@Jan-Simon Moeller, @Walt Miner: who to assign to this one ?
There is an issue with 'dmix' when using rpi3 soundcard that make impossible to mix sound. Furthermore, it is impossible to use 4a-softmixer for this soundcard.
Instruction to reproduce the issue (trying to use dmix with rpi3 soundcard) :
Replace your board's '/etc/asound.rc' file by the attached 'asound.rc' file.
Run an 'aplay -l | grep -i bcm2835' to get rpi3 soundcard alsa device id (a number between 0 and 31).
Modify the freshly replaced '/etc/asound.rc' to replace the '1' in the line 'slave {pcm "hw:1"}' (l. 10) by rpi3 soundcard alsa device id.
Copy attached 'tone-440-stereo-48000-16bits.wav' sound file to you board '/home/0' directory.
Open two terminals on your platform :
In the first one, run : aplay -D Emergency_Main /home/0/tone-440-stereo-48000-16bits.wav
In the second one, run : aplay -D Warning_Main /home/0/tone-440-stereo-48000-16bits.wav
On the second terminal, an error will be returned :
ALSA lib ../../../alsa-lib-1.1.6/src/pcm/pcm_dmix.c:1156:(snd_pcm_dmix_open) unable to open slave
aplay: main:828: audio open error: Invalid argument
In attached files, you can find outputs of the error using rpi3 soundcard and the expected behaviour using a csl-cm106 soundcard.