XO-1.5 microphone testing
dsd at laptop.org
Fri Jul 3 14:33:01 EDT 2009
As you pointed out, my board has incorrect microphone wiring. When you
have time, I need you to run some tests on a correctly-wired board.
Here's a kernel:
Please configure modules.conf to pass the model=olpc-xo-1_5 option to
snd_hda_intel, or load the module manually with that parameter. THen
confirm that it took effect by looking for the following in dmesg:
> ALSA sound/pci/hda/hda_codec.c:2975: hda_codec: model 'olpc-xo-1_5' is selected
After that, run alsamixer. You'll see a lot of controls.
The plan is for you to find the 2 working configurations (internal mic,
external mic) and then we'll hide all the fine-grained controls and
automate the switching between those 2 configurations.
(in this kernel, I've already done that for speakers vs headphones)
My suggestions on how to do this:
1. Plug headphones in and run:
arecord -f S16_LE -c1 -r44100 | aplay
2. In alsamixer, under Playback leave all "PortX Jack" controls as their
defaults. Turn Master all the way up.
Under Capture, you'll see a choice of 8 inputs. Go through them one by
one while making some noise. Which one represents the internal
3. Once you know which of the 8 inputs represents the internal
microphone, select it and experiment with the "Analog Mic Boost"/"DMIC
Mic Boost" controls. Which one has effect? Of the one that has effect,
which gain values are sensible?
4. Pick a sensible gain value and go back to Playback. Set the jack
options for PortD and PortE to off. Make some noise, can you still hear
it? I think PortD and PortE do absolutely nothing on our hardware so I
want to harcode them to be permanently off.
5. Experiment with PortB and PortC. Which one affects the internal
microphone? Does 50% or 80% bias sound better?
At this point you can hopefully reach a configuration where one port is
set to Mic with a certain bias level, and the other 3 ports are Off, and
you can still record and play audio, right?
6. Select a good bias level and go back to capture. Experiment with the
Digital volume control, what effect does this have?
7. Close alsamixer and start watching kernel debug messages. Plug in
external microphone. Which new kernel messages appear?
8. Open alsamixer again and repeat the above experiment. Note that when
you plugged in the microphone, some settings may have been automatically
changed. (it may have changed the PortX settings, and it will certainly
have selected a microphone input under Capture although possibly the
Please also blow lightly into the internal microphone once you've found
a good configuration for the external microphone, confirming that the
internal one is muted.
9. please send full kernel logs of the whole session
Basically, for each configuration (external microphone plugged in, and
external microphone not plugged in), I'd like to know the following:
- which of the 8 microphones is the one to use
- which ports we can turn off
- the % bias that sounds good
- the mic boost gain level that sounds good
- which values of Digital are reasonable
Once we know that, I plan to hide all the PortX controls and all 8
microphone selectors. The port configuration and microphone selection
will be handled automatically. I'll leave Mic Boost and Digital
configurable through alsamixer, but will apply reasonable defaults from
More information about the Devel