Re: Anyone using FR as a phone? / Audio Codec meddling info

2008-07-21 Thread Al Johnson
On Monday 21 July 2008, Andy Green wrote:
> Somebody in the thread at some point said:
snip my comment about alsa settings bypassing the ALC

> I don't know why we go around it, but when I looked mic -> GSM routing
> some weeks ago I also found a very direct analogue path.  If you're
> interested to meddle with this, I have some meddling hints.  First, the
> datasheet is open:
>
> http://www.wolfsonmicro.com/uploads/documents/en/WM8753.pdf

I've been reading it already ;-) One area the wiki does well on is links to 
the hardware datasheets.

> We have fitted 100n in the external ALC path (between ACOP / ACIN)
> instead of 1uF recommended, I guess it will impact low end, but in
> telephony the low end as well as the high end are chopped out anyway.
> Soon, as steve told, you'll be able to see this stuff (and our mistakes)
> on the schematics for yourself.

I didn't notice a rolled off low end in cursory testing of the ALC, so you're 
probably right. It's good to know just in case though. Steve's announcement 
was a pleasant surprise, and I'm looking forward to it.

> You can dump the actual codec registers using
>
> # cat /sys/devices/platform/soc-audio/codec_reg
>
> and you can meddle with them like this
>
> # echo "3d 20" > /sys/devices/platform/soc-audio/codec_reg_write
>
> first one is the register address in hex, second is value to write in
> hex.  I don't really know what those dozens of alsamixer settings are
> doing either, I found it easier to read the datasheet and interpret /
> meddle with the codec registers directly.

That'll be handy. I'll check my mapping of the ALSA devices and settings 
against this. I don't want to stick it on the wiki before I know it's right.

___
Openmoko community mailing list
community@lists.openmoko.org
http://lists.openmoko.org/mailman/listinfo/community


Re: Anyone using FR as a phone? / Audio Codec meddling info

2008-07-21 Thread Andy Green
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Somebody in the thread at some point said:
| On Monday 21 July 2008, Cédric Berger wrote:
|> Sound quality during calls is indeed not that good.
|>
|> 1. Volume is usually too low, but I think it can be modified via
|> correct settings.
|> Seems like people not always hear me at the same level : sometimes
|> quite ok, often really too low.  I have yet to try more...
|
| Volume can be adjusted vi a alsamixer, and the mic can be routed via a
| compressor and noise gate. Audio routing is far from simple - see the
wiki:
|   http://wiki.openmoko.org/wiki/Neo_1973_audio_subsystem
| The route indicated for voice calls on the wiki is via the compressor
/ noise
| gate (ALC) but the state file (2007.2 after opkg upgrade) skips that
part.
|
| Assuming there is sufficient difference in level between voice level
and the
| level from the earpiece it should be possible to set the noise gate so
that
| it only triggers when you are actually speaking, stopping the echo. The
| compressor should even out the variations in level.
|
| I don't know yet whether the assumption is true; it maybe that the ALC is
| skipped from the state file because it was difficult or impossible to
find
| settings that reliably blocked echo, but passed voice.

I don't know why we go around it, but when I looked mic -> GSM routing
some weeks ago I also found a very direct analogue path.  If you're
interested to meddle with this, I have some meddling hints.  First, the
datasheet is open:

http://www.wolfsonmicro.com/uploads/documents/en/WM8753.pdf

We have fitted 100n in the external ALC path (between ACOP / ACIN)
instead of 1uF recommended, I guess it will impact low end, but in
telephony the low end as well as the high end are chopped out anyway.
Soon, as steve told, you'll be able to see this stuff (and our mistakes)
on the schematics for yourself.

You can dump the actual codec registers using

# cat /sys/devices/platform/soc-audio/codec_reg

and you can meddle with them like this

# echo "3d 20" > /sys/devices/platform/soc-audio/codec_reg_write

first one is the register address in hex, second is value to write in
hex.  I don't really know what those dozens of alsamixer settings are
doing either, I found it easier to read the datasheet and interpret /
meddle with the codec registers directly.

- -Andy
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.9 (GNU/Linux)
Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org

iEYEARECAAYFAkiEWNIACgkQOjLpvpq7dMrPUgCeKs86CiONfAJ3tVGwOdWXyib/
TcoAnib9G+BfEEOZxzZsS8vy7Vvr0aw3
=H3+x
-END PGP SIGNATURE-

___
Openmoko community mailing list
community@lists.openmoko.org
http://lists.openmoko.org/mailman/listinfo/community