[alsa-devel] [RFC PATCH] ucm: Add support for device positions

Pierre-Louis Bossart pierre-louis.bossart at linux.intel.com
Tue Jan 3 15:50:54 CET 2017



On 01/03/2017 04:09 AM, Mengdong Lin wrote:
>
>
> On 01/03/2017 04:21 PM, Vinod Koul wrote:
>> On Tue, Jan 03, 2017 at 02:09:18PM +0800, 
>> mengdong.lin at linux.intel.com wrote:
>>> From: Mengdong Lin <mengdong.lin at linux.intel.com>
>>>
>>> Users can provide prosition info of audio devices as a device value. 
>>> This
>>> will help the sound server to choose an audio devices from some 
>>> candidates
>>> based on the their locations and the status of the machine.
>>
>> This is good thing to have but some bits are bit unclear to me atm. 
>> When you
>> say device, do you mean sound card?
>
> No, the device here does not mean a sound card, but mean an I/O device 
> like speaker or dmic, defined by 'SectionDevice'.
>
>> For me, position makes sense for dmics and speakers. So can you help 
>> me out
>> by understanding how we can describe these...
>>
>
> For example, if there are two DMICs, one is in the front and one on 
> the back, we can define their positions as below:
>
> SectionDevice."MainMIC" {
>
>        ...
>
>         EnableSequence [
>                ...
>         ]
>
>         DisableSequence [
>                 ...
>         ]
>
>         Value {
>                 Position "Front"
>         }
> }
>
> SectionDevice."SecondaryMIC" {
>
>     ...
>
>     EnableSequence [
>     ...
>     ]
>
>     DisableSequence [
>     ...
>     ]
>
>     Value {
>         Position "Back"
>     }
> }

What is the entity that will make use of the position information? For 
what purpose? This type of information needs to be known at a lower 
level (typically a DSP), I wonder what UCM would do with it?
Also it can be tricky to define left and right for a tablet which works 
in all possible orientations, you'd need sensor information to refine 
the position. And last if you have a mic or speaker array you'd need to 
provide geometrical information?


More information about the Alsa-devel mailing list