Page 1 of 2

Problem accessing the mic with 2.1.1 with Azalia sound card

Posted: Wed Mar 23, 2016 6:32 am
by tgf
I have used Audacity for many years successfully, almost always using Linux. I currently use OpenSuSE on my computers, and Audacity is playing up on one of the machines when I attempt to get input from its Mic connection. There is no problem with output; sound is produced without problem. There is also no problem with recording sound that is coming from other running programs like Firefox and web pages which are sound sources. It is only when I connect a cable to the Mic port that Audacity does not detect a signal.

I have two machines running Audacity 2.1.1 and OpenSuSE Leap 42.1. The other machine, the older one, is able to handle Mic input fine, so the problem is specific to the hardware on my newer machine. When I have pavucontrol running, I can see that signal is detected by it. I can also record Mic input using the Audio Recorder program on this machine. It is only Audacity that cannot detect Mic input.

I have done these tests in the hope that they will give you a bit more information about my hardware and setup:
The output from "arecord -l" is

Code: Select all

**** List of CAPTURE Hardware Devices ****
card 1: Generic [HD-Audio Generic], device 0: 92HD99BXX Analog [92HD99BXX Analog]
  Subdevices: 0/1
  Subdevice #0: subdevice #0
The output from "cat /etc/modprobe.d/50-sound.conf" is

Code: Select all

options snd slots=snd-hda-intel
# 5Dex.mtR84bFRyqF:FCH Azalia Controller
alias snd-card-0 snd-hda-intel
The output from /usr/sbin/alsa-info.sh can be seen at http://www.alsa-project.org/db/?f=9ac81 ... 00d2d132a6
The output from "lspci -vnn | grep -A 1 -i audio" is

Code: Select all

00:01.1 Audio device [0403]: Advanced Micro Devices, Inc. [AMD/ATI] Trinity HDMI Audio Controller [1002:9902]
        Subsystem: Advanced Micro Devices, Inc. [AMD/ATI] Trinity HDMI Audio Controller [1002:9902]
        Flags: bus master, fast devsel, latency 0, IRQ 32
--
00:14.2 Audio device [0403]: Advanced Micro Devices, Inc. [AMD] FCH Azalia Controller [1022:780d] (rev 01)
        Subsystem: Toshiba America Info Systems Device [1179:fa91]
The command "arecord -d 4 /tmp/test.wav" causes a good recording of the Mic input.
The problem is not urgent for me because I can use Audio Recorder instead of Audacity, but it would be able to use Audacity uniformly across the machines for audio work if you are able to identify the problem.
I have this software installed on the machine:

Code: Select all

> rpm -qa | grep alsa
alsa-oss-1.0.28-5.2.x86_64
alsa-1.0.29-10.1.x86_64
alsa-utils-1.0.29-9.1.x86_64
alsa-firmware-1.0.29-3.2.noarch
alsa-plugins-32bit-1.0.29-10.1.x86_64
alsa-plugins-pulse-1.0.29-10.1.x86_64
alsa-oss-32bit-1.0.28-5.2.x86_64
alsa-plugins-1.0.29-10.1.x86_64
alsa-plugins-pulse-32bit-1.0.29-10.1.x86_64
> rpm -qa | grep pulse
libpulse0-7.0-3.1.x86_64
pulseaudio-7.0-3.1.x86_64
libxine2-pulse-1.2.6-3.2.x86_64
pulseaudio-utils-7.0-3.1.x86_64
libpulse-mainloop-glib0-7.0-3.1.x86_64
pulseaudio-lang-7.0-3.1.noarch
alsa-plugins-pulse-1.0.29-10.1.x86_64
libpulse0-32bit-7.0-3.1.x86_64
pulseaudio-bash-completion-7.0-3.1.x86_64
alsa-plugins-pulse-32bit-1.0.29-10.1.x86_64
> rpm -q libasound2
libasound2-1.0.29-10.1.x86_64
The output of "uname -a" is

Code: Select all

Linux t2 4.1.15-8-default #1 SMP PREEMPT Wed Jan 20 16:41:00 UTC 2016 (0e3b3ab) x86_64 x86_64 x86_64 GNU/Linux

Re: Problem accessing the mic with 2.1.1 with Azalia sound c

Posted: Wed Mar 23, 2016 9:13 am
by steve
tgf wrote:The command "arecord -d 4 /tmp/test.wav" causes a good recording of the Mic input.
That's a good sign. We should be able to get Audacity recording from the Mic input.
tgf wrote:When I have pavucontrol running, I can see that signal is detected by it.
That "should" give use two ways to record from the Mic input with Audacity.
Let's try the Pulse Audio route first.

1) Starting from a fresh log-in to your computer and assuming that you don't have any audio apps starting up automatically on log-in.
2) Connect your microphone.
3) Open pavucontrol and check in the "Input Devices" tab that you are getting a signal from the mic. and turn the input level up so that you are getting a good strong signal (you may need to turn this down later, but set it high for this test).
4) Close pavucontrol (this "should" not make a difference, but I've seen occasions when it does, so close pavucontrol, but leave PulseAudio running).
5) Launch Audacity
6) Ensure that "ALSA" is the only available "host" option in the device toolbar.
7) Ensure that "Pulse" is selected in the device toolbar as the recording device.
8) Open pavucontrol. Check that you are still getting a signal on the "Input Devices" tab, then switch to the "Recording" tab. The Recording tab should be empty ("No applications currently recording audio")
9) Arrange the Audacity window and the pavucontrol window so that you can see both side by side.
10) Click on the Recording Meter in Audacity ("Click to start monitoring"). You should immediately see Audacity appear in the "Recording" tab of pavucontrol, and the meters in both applications should be responding to input from the mic.

What happened?

Re: Problem accessing the mic with 2.1.1 with Azalia sound c

Posted: Thu Mar 24, 2016 5:06 am
by tgf
Steve wrote:
...
7) Ensure that "Pulse" is selected in the device toolbar as the recording device.
"Pulse" is not a listed option. The choice is between "default" and "HD-Audio Generic: 92HD99BXX Analog (hw:1,0)"
...
10) Click on the Recording Meter in Audacity ("Click to start monitoring"). You should immediately see Audacity appear in the "Recording" tab of pavucontrol, and the meters in both applications should be responding to input from the mic.
With "default" selected, the recording meter is dead when it is clicked. With "HD-Audio..." selected, I now see a signal from the source. Recording works perfectly.

I thought that I tried that before but I may not have. Thanks for the help. I really appreciate it.

Re: Problem accessing the mic with 2.1.1 with Azalia sound c

Posted: Thu Mar 24, 2016 1:16 pm
by steve
tgf wrote:"Pulse" is not a listed option.
Is PulseAudio still running?
Where did you get Audacity from and how did you install it?
How are you launching Audacity?

Re: Problem accessing the mic with 2.1.1 with Azalia sound c

Posted: Thu Mar 24, 2016 8:55 pm
by tgf
Steve wrote:
Is PulseAudio still running?
Well, when I run pavucontrol it detects the hardware and state of the machine accurately. The only other way I can tell is with the command "ps -eaf | grep pulse" which reports

Code: Select all

gfreeman  1842     1  0 Mar24 ?        00:00:06 /usr/bin/pulseaudio --start --log-target=syslog
Where did you get Audacity from and how did you install it?
I downloaded it from the packman.links2linux.de (packman-multimedia) repository with the command

Code: Select all

zypper in audacity
The RPM is audacity-2.1.1-94.6.x86_64. I am using OpenSuSE Leap 42.1
How are you launching Audacity?
The Multimedia menu has Audacity listed.

Re: Problem accessing the mic with 2.1.1 with Azalia sound c

Posted: Fri Mar 25, 2016 12:13 pm
by steve
Try this to see what happens:

1) Open pavucontrol,
(a) Check in the "Input Devices" tab that there is a meter responding to input from the microphone.
(b) Go to the "Recoding" tab, and set the bottom "show" control to "All streams". The tab should be empty (no active streams). Leave this open.

2) Open a Terminal window and type:

Code: Select all

audacity
then press Enter.
You should see a load of messages as Audacity scans the sound system, probably including a load of "warning" messages (that's normal as Audacity scans for things that may not exist on your system). Then Audacity should launch. Watch pavucontrol as much as possible while this goes on.

3) Assuming that Audacity launches and pavucontrol remains open:
(a) Did you notice anything happen in the Recording tab while Audacity was launching (probably not, but if you did then it's probably relevant).
(b) Switch to the "Input Devices" tab. Do you still see a meter responding to input from the microphone?

4) Switch back to Audacity and from the "Help" menu select "Audio Device Info". Wait for the info to be populated, then copy the entire contents and paste that into your reply.

Re: Problem accessing the mic with 2.1.1 with Azalia sound c

Posted: Sun Mar 27, 2016 10:36 pm
by tgf
Steve wrote
...
1(b) Go to the "Recoding" tab, and set the bottom "show" control to "All streams". The tab should be empty (no active streams).
When I click on All Streams, it comes up with two options: Applications, and Virtual streams. There is a message in the middle of the window saying "No application is currently recording audio".
...
type audacity
I get

Code: Select all

> audacity
ALSA lib pcm_dsnoop.c:615:(snd_pcm_dsnoop_open) unable to open slave
ALSA lib pcm_dmix.c:1039:(snd_pcm_dmix_open) unable to open slave
ALSA lib pcm.c:2267:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.rear
ALSA lib pcm.c:2267:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.center_lfe
ALSA lib pcm.c:2267:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.side
ALSA lib pcm_dmix.c:1039:(snd_pcm_dmix_open) unable to open slave
Cannot connect to server socket err = No such file or directory
Cannot connect to server request channel
jack server is not running or cannot be started
Expression 'stream->playback.pcm' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 4607
...
3(a) Did you notice anything happen in the Recording tab while Audacity was launching
No, there was no change.
...
3(b) Switch to the "Input Devices" tab. Do you still see a meter responding to input from the microphone?
Yes. pavucontrol still detects the signal.
...
4) Switch back to Audacity and from the "Help" menu select "Audio Device Info". Wait for the info to be populated, then copy the entire contents and paste that into your reply.
The only message there is

Code: Select all

Stream is active ... unable to gather information.
Note that I have done these tests with Audacity input set to "default", the state it starts in.

Re: Problem accessing the mic with 2.1.1 with Azalia sound c

Posted: Mon Mar 28, 2016 9:50 am
by steve
tgf wrote:The only message there is

Code: Select all

Stream is active ... unable to gather information.
That could be that you've put Audacity into record mode, or you've activated the recording meter.

Click the "Stop" button to ensure that Audacity is in "stop mode". (http://manual.audacityteam.org/o/man/tr ... .html#stop)

Click the Cancel button to close the "Audio device info" window.

Does the recording meter in Audacity show the text "Click to Start Monitoring"?

Image

If it doesn't then the meter is active. Clicking on the recording meter toggles it on / off, so click on it so that it does show the text (as in the image above), then run "Audio Device Info" again.

Re: Problem accessing the mic with 2.1.1 with Azalia sound c

Posted: Mon Mar 28, 2016 8:21 pm
by tgf
Steve wrote
...That could be that you've put Audacity into record mode, or you've activated the recording meter.
OK. I understand. This is what I get when it is not in recording mode:

Code: Select all

==============================
Default recording device number: 0
Default playback device number: 0
==============================
Device ID: 0
Device name: default
Host name: ALSA
Recording channels: 32
Playback channels: 32
Low Recording Latency: 0.008707
Low Playback Latency: 0.008707
High Recording Latency: 0.034830
High Playback Latency: 0.034830
Supported Rates:
    8000
    9600
    11025
    12000
    15000
    16000
    22050
    24000
    32000
    44100
    48000
    88200
    96000
    176400
    192000
==============================
Selected recording device: 0 - default
Selected playback device: 0 - default
Supported Rates:
    8000
    9600
    11025
    12000
    15000
    16000
    22050
    24000
    32000
    44100
    48000
    88200
    96000
    176400
    192000
==============================
Available mixers:
==============================
Available recording sources:
==============================
Available playback volumes:
==============================
Recording volume is emulated
Playback volume is emulated

Re: Problem accessing the mic with 2.1.1 with Azalia sound c

Posted: Mon Mar 28, 2016 9:15 pm
by steve
I don't understand why Audacity is not seeing PulseAudio. That should happen automatically if PulseAudio is running, and you tell me that PulseAudio is running.

Let's try from a different angle:
tgf wrote:The command "arecord -d 4 /tmp/test.wav" causes a good recording of the Mic input.
Check that again and write down precise step by step instructions for how you make that work.