[alsa-devel] When select 2.1 profile in pulseaudio, how do pulseaudio select notebook 's internal subwoofer or 5.1 external speaker ?

Raymond Yau superquad.vortex2 at gmail.com
Wed Aug 5 04:51:22 CEST 2015


>
> +static const struct snd_pcm_chmap_elem acer_pcm_chmaps[] = {
>
> + { .channels = 2, + .map = { SNDRV_CHMAP_FL, SNDRV_CHMAP_FR } }, + {
.channels = 4, + .map = { SNDRV_CHMAP_FL, SNDRV_CHMAP_FR,
>
> + SNDRV_CHMAP_LFE, SNDRV_CHMAP_NA } }, /* LFE only on left */
>
> + { .channels = 4, + .map = { SNDRV_CHMAP_FL, SNDRV_CHMAP_FR,
>
> + SNDRV_CHMAP_RL, SNDRV_CHMAP_RR } },
>
> + { .channels = 6,
>
> + .map = { SNDRV_CHMAP_FL, SNDRV_CHMAP_FR,
>
> + SNDRV_CHMAP_RL, SNDRV_CHMAP_RR,
>
> + SNDRV_CHMAP_FC, SNDRV_CHMAP_LFE } },
>
> + { }
>
> +};

After testing with ubuntu 15.10 alpha and modified snd-dummy

alsa-lib seem using the first channel map which has FL, FR and LFE , this
mean that 2.1 profile always use your notebook internal speaker/subwoofer
even when your notebook support 5.1 external speakers

this behaviour is different from those desktop with external 5.1 speakers
using 2.1 profile


you may need to implement dynamic channel map which change when line out
jack is plugged if you want to use 2.1 profile with external 5.1 speakers


More information about the Alsa-devel mailing list