Recording from azalia does not work

classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

Recording from azalia does not work

Gregor Best
Hi people,

I'm trying to get recording from the mic input of my laptop working, but have
not have success so far. I'm using a thinkpad laptop
with an azalia device and a pretty run of the mill headset, attached to
headphone out and microphone in. The headset itself works
fine on other machines and the microphone input and headphone output of the
laptop work fine hardware-wise (i.e. tested with another
operating system). On OpenBSD however, the mic input remains silent. Files
recorded with aucat -o foo.wav remain silent for the
entire recording duration, as if the mic was somehow muted. Below is the
output of mixerctl:

        outputs.spkr_source=dac-0:1
        outputs.spkr_mute=on
        outputs.spkr=125,125
        outputs.spkr_eapd=on
        outputs.hp_source=dac-0:1
        outputs.hp_mute=off
        outputs.hp=155,155
        outputs.hp_dir=output
        outputs.hp_boost=off
        outputs.mic_dir=input-vr80
        inputs.beep_mute=off
        inputs.beep=108
        inputs.mix_source=dac-0:1,mic,hp
        inputs.mix_dac-0:1=125,125
        inputs.mix_mic=215,215
        inputs.mix_hp=125,125
        record.adc-0:1_source=mic
        record.adc-0:1_mute=off
        record.adc-0:1=253,253
        outputs.hp_sense=plugged
        outputs.mic_sense=plugged
        outputs.spkr_muters=hp
        outputs.master=157,157
        outputs.master.mute=off
        outputs.master.slaves=spkr,hp
        record.volume=255,255
        record.volume.mute=off
        record.volume.slaves=adc-0:1

As you can see, all recording related devices are at full volume and no device
is muted except for the built-in speakers. Is
recording on azalia devices simply not supported or am I missing something
really obvious here?

--
    Gregor Best

[demime 1.01d removed an attachment of type application/pgp-signature]

Reply | Threaded
Open this post in threaded view
|

Re: Recording from azalia does not work

Alexandre Ratchov-2
On Mon, Jun 25, 2012 at 10:53:34AM +0200, Gregor Best wrote:

> Hi people,
>
> I'm trying to get recording from the mic input of my laptop working, but have
> not have success so far. I'm using a thinkpad laptop
> with an azalia device and a pretty run of the mill headset, attached to
> headphone out and microphone in. The headset itself works
> fine on other machines and the microphone input and headphone output of the
> laptop work fine hardware-wise (i.e. tested with another
> operating system). On OpenBSD however, the mic input remains silent. Files
> recorded with aucat -o foo.wav remain silent for the
> entire recording duration, as if the mic was somehow muted. Below is the
> output of mixerctl:>
> outputs.spkr_source=dac-0:1
> outputs.spkr_mute=on
> outputs.spkr=125,125
> outputs.spkr_eapd=on
> outputs.hp_source=dac-0:1
> outputs.hp_mute=off
> outputs.hp=155,155
> outputs.hp_dir=output
> outputs.hp_boost=off
> outputs.mic_dir=input-vr80
> inputs.beep_mute=off
> inputs.beep=108
> inputs.mix_source=dac-0:1,mic,hp
> inputs.mix_dac-0:1=125,125
> inputs.mix_mic=215,215
> inputs.mix_hp=125,125
> record.adc-0:1_source=mic
> record.adc-0:1_mute=off
> record.adc-0:1=253,253
> outputs.hp_sense=plugged
> outputs.mic_sense=plugged
> outputs.spkr_muters=hp
> outputs.master=157,157
> outputs.master.mute=off
> outputs.master.slaves=spkr,hp
> record.volume=255,255
> record.volume.mute=off
> record.volume.slaves=adc-0:1
>

this seems correct at first glance; could you see whether the
recorded file is full of silence (zeros) or noise (numbers close to
zero)?

aucat -o /tmp/foo

and then:

hexdump /tmp/foo |less

noise would mean that there's a level knob to crank, while zeros
would suggest that something in the recording chain is disabled.

> As you can see, all recording related devices are at full volume and no device
> is muted except for the built-in speakers. Is
> recording on azalia devices simply not supported or am I missing something
> really obvious here?

recording is supposed to work. I don't have azalia, so both of us
might be missing something obvious :)

-- Alexandre

Reply | Threaded
Open this post in threaded view
|

Re: Recording from azalia does not work

Gregor Best
On Tue, Jun 26, 2012 at 09:16:38AM +0200, Alexandre Ratchov wrote:

> [...]
> this seems correct at first glance; could you see whether the
> recorded file is full of silence (zeros) or noise (numbers close to
> zero)?
>
> aucat -o /tmp/foo
>
> and then:
>
> hexdump /tmp/foo |less
>
> noise would mean that there's a level knob to crank, while zeros
> would suggest that something in the recording chain is disabled.
> [...]

Hmm... I may be losing my mind... I just rebooted and tried it again and
it worked. The mixer settings are the same... looks like this was just some
sort of glitch. I'll do some more checking if it stops working again.

--
    Gregor Best

[demime 1.01d removed an attachment of type application/pgp-signature]

Reply | Threaded
Open this post in threaded view
|

Re: Recording from azalia does not work

patrick keshishian
On Tue, Jun 26, 2012 at 7:23 AM, Gregor Best <[hidden email]> wrote:

> On Tue, Jun 26, 2012 at 09:16:38AM +0200, Alexandre Ratchov wrote:
>> [...]
>> this seems correct at first glance; could you see whether the
>> recorded file is full of silence (zeros) or noise (numbers close to
>> zero)?
>>
>> aucat -o /tmp/foo
>>
>> and then:
>>
>> hexdump /tmp/foo |less
>>
>> noise would mean that there's a level knob to crank, while zeros
>> would suggest that something in the recording chain is disabled.
>> [...]
>
> Hmm... I may be losing my mind... I just rebooted and tried it again and
> it worked. The mixer settings are the same... looks like this was just some
> sort of glitch. I'll do some more checking if it stops working again.

sleep-wake cycle test?

Reply | Threaded
Open this post in threaded view
|

Re: Recording from azalia does not work

Gregor Best
On Tue, Jun 26, 2012 at 09:46:23PM -0700, patrick keshishian wrote:
> [...]
> sleep-wake cycle test?
>

I had the problem again, and indeed, suspending the machine with zzz and
resuming it fixes audio input. Is there anything I can do to investigate
this? Dump some hardware registers before and after sleeping maybe (and
which registers would be interesting?)

--
    Gregor Best

Reply | Threaded
Open this post in threaded view
|

Re: Recording from azalia does not work

quisquous
In reply to this post by Alexandre Ratchov-2
On Tue, Jun 26, 2012 at 09:16:38AM +0200, Alexandre Ratchov wrote:

> On Mon, Jun 25, 2012 at 10:53:34AM +0200, Gregor Best wrote:
> > I'm trying to get recording from the mic input of my laptop working, but have
> > not have success so far. I'm using a thinkpad laptop
> > with an azalia device and a pretty run of the mill headset, attached to
> > headphone out and microphone in. The headset itself works
> > fine on other machines and the microphone input and headphone output of the
> > laptop work fine hardware-wise (i.e. tested with another
> > operating system). On OpenBSD however, the mic input remains silent. Files
> > recorded with aucat -o foo.wav remain silent for the
> > entire recording duration, as if the mic was somehow muted.

Same here. My azalia connected mic works under OSX but not under
OpenBSD. Did you ever figure out a solution?

> > Below is the
> > output of mixerctl:>
> > outputs.spkr_source=dac-0:1
> > outputs.spkr_mute=on
> > outputs.spkr=125,125
> > outputs.spkr_eapd=on
> > outputs.hp_source=dac-0:1
> > outputs.hp_mute=off
> > outputs.hp=155,155
> > outputs.hp_dir=output
> > outputs.hp_boost=off
> > outputs.mic_dir=input-vr80
> > inputs.beep_mute=off
> > inputs.beep=108
> > inputs.mix_source=dac-0:1,mic,hp
> > inputs.mix_dac-0:1=125,125
> > inputs.mix_mic=215,215
> > inputs.mix_hp=125,125
> > record.adc-0:1_source=mic
> > record.adc-0:1_mute=off
> > record.adc-0:1=253,253
> > outputs.hp_sense=plugged
> > outputs.mic_sense=plugged
> > outputs.spkr_muters=hp
> > outputs.master=157,157
> > outputs.master.mute=off
> > outputs.master.slaves=spkr,hp
> > record.volume=255,255
> > record.volume.mute=off
> > record.volume.slaves=adc-0:1

I have a similar problem. I've got a Macbook Air 5.1 running OpenBSD
5.5-stable. The microphone seems to be there, but I'm not able to get it
to record anything (aucat -o produces a silent file). The speakers and
headset work fine. Also, I noticed that Gnome 3 sound settings list no
input devices.

$ dmesg | grep azalia
azalia0 at pci0 dev 27 function 0 "Intel 7 Series HD Audio" rev 0x04: msi
azalia0: codecs: Cirrus Logic CS4206, Intel/0x2806, using Cirrus Logic CS4206
audio0 at azalia0

$ mixerctl -v
inputs.dac-0:1_mute=off  [ off on ]
inputs.dac-0:1=86,86
inputs.dac-2:3_mute=on  [ off on ]
inputs.dac-2:3=62,62
record.adc-0:1_source=mic  [ mic ]
record.adc-0:1_mute=off  [ off on ]
record.adc-0:1=124,124
outputs.hp_source=dac-0:1  [ dac-0:1 ]
outputs.hp_boost=off  [ off on ]
outputs.spkr_source=dac-2:3  [ dac-2:3 ]
inputs.mic=85,85
outputs.mic_dir=input-vr80  [ none input input-vr0 input-vr50 input-vr80 ]
outputs.hp_sense=plugged  [ unplugged plugged ]
outputs.spkr_muters=hp  { hp }
outputs.master=86,86
outputs.master.mute=off  [ off on ]
outputs.master.slaves=dac-0:1,dac-2:3  { dac-0:1 dac-2:3 }
record.volume=124,124
record.volume.mute=off  [ off on ]
record.volume.slaves=adc-0:1  { adc-0:1 mic }

> this seems correct at first glance; could you see whether the
> recorded file is full of silence (zeros) or noise (numbers close to
> zero)?
>
> aucat -o /tmp/foo
>
> and then:
>
> hexdump /tmp/foo |less
>
> noise would mean that there's a level knob to crank, while zeros
> would suggest that something in the recording chain is disabled.

Here's the first page of output:

0000000    4952    4646    5b38    000e    4157    4556    6d66    2074
0000010    0028    0000    0001    0002    bb80    0000    ee00    0002
0000020    0004    0010    0000    0000    0000    0000    0000    0000
0000030    0000    0000    0000    0000    3080    4ae1    6164    6174
0000040    5b00    000e    ffff    ffff    ffff    ffff    0000    0000
0000050    ffff    ffff    ffff    ffff    0000    ffff    ffff    ffff
0000060    ffff    ffff    ffff    0000    ffff    ffff    ffff    0000
0000070    0000    ffff    0000    0000    ffff    ffff    ffff    ffff
0000080    ffff    ffff    ffff    ffff    ffff    0000    ffff    0000
0000090    ffff    0000    ffff    0000    ffff    0000    ffff    0000
00000a0    ffff    ffff    ffff    ffff    ffff    ffff    ffff    ffff
00000b0    0000    ffff    ffff    ffff    0000    ffff    0000    ffff
00000c0    0000    ffff    ffff    ffff    0000    ffff    ffff    ffff
00000d0    0000    ffff    ffff    ffff    0000    ffff    0000    ffff
00000e0    0000    ffff    0000    ffff    0000    ffff    0000    ffff
00000f0    0000    0000    0000    0000    0000    0000    0000    0000
0000100    0000    ffff    0000    ffff    0000    ffff    0000    ffff
0000110    0000    ffff    0000    ffff    0000    ffff    0000    0000
0000120    ffff    ffff    ffff    ffff    0000    0000    0000    0000
0000130    0000    ffff    0000    ffff    ffff    ffff    ffff    ffff
0000140    0000    ffff    0000    0000    ffff    0000    0000    ffff
0000150    0000    ffff    0000    ffff    0000    ffff    0000    ffff
0000160    0000    ffff    0000    ffff    0000    ffff    ffff    ffff

> > As you can see, all recording related devices are at full volume and no device
> > is muted except for the built-in speakers. Is
> > recording on azalia devices simply not supported or am I missing something
> > really obvious here?
>
> recording is supposed to work. I don't have azalia, so both of us
> might be missing something obvious :)