All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jaroslav Kysela <perex@perex.cz>
To: info <info@dressmaker.ca>, alsa-devel@alsa-project.org
Subject: Re: Discover a microphone device, to later discover if it is receiving input
Date: Fri, 9 Oct 2020 16:07:22 +0200	[thread overview]
Message-ID: <69ba716e-d576-088f-23e5-4462933e0159@perex.cz> (raw)
In-Reply-To: <5378606a-5b71-5d1b-f7f4-a6f33dce60b3@dressmaker.ca>

Dne 09. 10. 20 v 14:39 info napsal(a):
> Can maintainers of this list please give a straight answer: is asking 
> questions and leaving comments here a waste of time?

Unfortunately, the hint list does not give information about the connected
mixer outputs or inputs. It's just a list of available PCM devices in the system.

If the I/O type is (null) it means that both directions may be available.

We have better device enumeration in UCM (Use Case Manager) by the use, but
the configurations are not available for all hardware yet.

BTW: Your e-mail header (From:) and signature does not seem trustly.

						Jaroslav

> On 2020-10-04 12:22 PM, info wrote:
>> Hi all,
>>
>>
>> I am writing a program that aims to auto-discover the microphone 
>> device that the user is speaking into. I started off by querying 
>> device hints and collected all devices with the IO types of null, 
>> since I have not found any devices with the type of Input. I am 
>> puzzled how it is possible that there is no Input, where a microphone 
>> device should not be able to emit sound. This is the list on my 
>> particular machine:
>>
>> Name of device: sysdefault:CARD=SB
>> Description of device: HDA ATI SB, ALC892 Analog
>> Default Audio Device
>> I/O type of device: (null)
>>
>> Name of device: front:CARD=SB,DEV=0
>> Description of device: HDA ATI SB, ALC892 Analog
>> Front speakers
>> I/O type of device: (null)
>>
>> Name of device: surround21:CARD=SB,DEV=0
>> Description of device: HDA ATI SB, ALC892 Analog
>> 2.1 Surround output to Front and Subwoofer speakers
>> I/O type of device: Output
>>
>> Name of device: surround41:CARD=SB,DEV=0
>> Description of device: HDA ATI SB, ALC892 Analog
>> 4.1 Surround output to Front, Rear and Subwoofer speakers
>> I/O type of device: Output
>>
>> Name of device: surround50:CARD=SB,DEV=0
>> Description of device: HDA ATI SB, ALC892 Analog
>> 5.0 Surround output to Front, Center and Rear speakers
>> I/O type of device: Output
>>
>> Name of device: surround71:CARD=SB,DEV=0
>> Description of device: HDA ATI SB, ALC892 Analog
>> 7.1 Surround output to Front, Center, Side, Rear and Woofer speakers
>> I/O type of device: Output
>>
>> Name of device: sysdefault:CARD=SB
>> Description of device: HDA ATI SB, ALC892 Analog
>> Default Audio Device
>> I/O type of device: (null)
>>
>> Name of device: front:CARD=SB,DEV=0
>> Description of device: HDA ATI SB, ALC892 Analog
>> Front speakers
>> I/O type of device: (null)
>>
>> Now, I am more puzzled, because none of them is a microphone device 
>> explicitly. How can my program determine which of them is actually a 
>> microphone?
>>
>> Also, why are devices are duplicated in the output from 
>> snd_device_name_hint()? The very first device is also repeated as the 
>> 2nd last one...
>>
>>
>> Regards,
>> Alex
>>
>>
> 
> 


-- 
Jaroslav Kysela <perex@perex.cz>
Linux Sound Maintainer; ALSA Project; Red Hat, Inc.

  reply	other threads:[~2020-10-09 14:08 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-10-04 16:22 Discover a microphone device, to later discover if it is receiving input info
2020-10-04 21:17 ` Dead link in wiki under Tutorials info
2020-10-16 17:33   ` info
2020-10-09 12:39 ` Discover a microphone device, to later discover if it is receiving input info
2020-10-09 14:07   ` Jaroslav Kysela [this message]
2020-10-09 15:35 ` Takashi Iwai
2020-10-09 16:11   ` info

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=69ba716e-d576-088f-23e5-4462933e0159@perex.cz \
    --to=perex@perex.cz \
    --cc=alsa-devel@alsa-project.org \
    --cc=info@dressmaker.ca \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.