From: Stuart Longland <redhatter@gentoo.org>
To: linux-mips@linux-mips.org
Subject: The puzzle that is IP32 audio
Date: Sat, 01 Jul 2006 23:45:40 +1000 [thread overview]
Message-ID: <44A67C84.5050702@gentoo.org> (raw)
[-- Attachment #1: Type: text/plain, Size: 2235 bytes --]
Hi All...
I've just been tinkering with my O2's audio... and whilst looking
around at OpenBSD... it seems I might have some pieces to the puzzle
which may explain the rather poor audio quality one gets under Linux.
The sound board is based around an Analogue Devices AD1843 codec
(datasheet here[1]), which is a 16-bit device. The interesting note,
was in the OpenBSD source code for their mavb[2] driver... The mabv.c
file[3] contains this comment:
> /*
> * For some reason SGI has decided to standardize their sound hardware
> * interfaces on 24-bit PCM even though the AD1843 codec used in the
> * Moosehead A/V Board only supports 16-bit and 8-bit formats.
> * Therefore we must convert everything to 24-bit samples only to have
> * the MACE hardware convert them back into 16-bit samples again. To
> * complicate matters further, the 24-bit samples are embedded 32-bit
> * integers. The 8-bit and 16-bit samples are first converted into
> * 24-bit samples by padding them to the right with zeroes. Then they
> * are sign-extended into 32-bit integers. This conversion is
> * conveniently done through the software encoding layer of the high
> * level audio driver by using the functions below. Conversion of
> * mu-law and A-law formats is done by the hardware.
> */
I'm wondering... I don't see any logic that does this in the ALSA
code... Could this be the reason we get such craptastic audio from this
device?
I'll have a tinker, and see if I can use my limited coding skills to
fix up the current IP32 driver to the point the sound at least works...
without sounding terrible. :-)
Regards,
--
Stuart Longland (aka Redhatter) .'''.
Gentoo Linux/MIPS Cobalt and Docs Developer '.'` :
. . . . . . . . . . . . . . . . . . . . . . .'.'
http://dev.gentoo.org/~redhatter :.'
International Asperger's Year (1906 ~ 2006)
http://dev.gentoo.org/~redhatter/iay
Footnotes:
1. http://www.analog.com/UploadedFiles/Data_Sheets/314303384ad1843.pdf
2. http://www.openbsd.org/cgi-bin/man.cgi?query=mavb&sektion=4&arch=sgi
3.
http://www.openbsd.org/cgi-bin/cvsweb/~checkout~/src/sys/arch/sgi/dev/mavb.c?rev=1.6&content-type=text/plain
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 263 bytes --]
reply other threads:[~2006-07-01 13:45 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=44A67C84.5050702@gentoo.org \
--to=redhatter@gentoo.org \
--cc=linux-mips@linux-mips.org \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox