From: Takashi Iwai <tiwai@suse.de>
To: "Gupta, Kshitij" <kshitij@ti.com>
Cc: "'alsa-devel@lists.sourceforge.net'" <alsa-devel@lists.sourceforge.net>
Subject: Re: new alsa driver for ti omap chip
Date: Thu, 12 Feb 2004 11:58:11 +0100 [thread overview]
Message-ID: <s5h65eca7jw.wl@alsa2.suse.de> (raw)
In-Reply-To: <F509E6111989D311B63700805FA761DA09F28EC1@DBDE01>
At Thu, 12 Feb 2004 12:56:04 +0530,
Gupta, Kshitij wrote:
>
> hi,
>
> I am trying to write an alsa driver for a tsc2101 codec on a arm
> based SOC. The control interface between the SOC and the tsc2101 codec is
> via SPI.
> And the data interface is a I2S interface. Can some one suggest a good
> starting point to start such a driver.
some ALSA drivers use their own i2c functions, although there is a
generic i2c layer on linux kernel. for example, delta.c or ews.c of
ice1712 driver use i2c (SPI) transfer (which calls ak4xxx-adda.c).
but it's rather complex to refer...
the i2c transfer is really easy to implement. do just like the spec
says. a pseudo code is like below.
chip_select_low();
udelay(1);
for (i = 15; i >= 0; i--) {
set_bit_clock(0);
udelay(1);
if (value_to_send & (1 << i))
set_bit_data(1);
else
set_bit_data(0);
udelay(1);
set_bit_clock(0);
udelay(1);
}
chip_select_high();
> does sound/drivers/dummy.c makes sense for such a driver ???
the dummy driver is irrelevant to the BUS type, so it makes some sense
to read the code :)
Takashi
-------------------------------------------------------
SF.Net is sponsored by: Speed Start Your Linux Apps Now.
Build and deploy apps & Web services for Linux with
a free DVD software kit from IBM. Click Now!
http://ads.osdn.com/?ad_id=1356&alloc_id=3438&op=click
next prev parent reply other threads:[~2004-02-12 10:58 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-02-12 7:26 new alsa driver for ti omap chip Gupta, Kshitij
2004-02-12 10:58 ` Takashi Iwai [this message]
2004-02-12 11:22 ` Jaroslav Kysela
2004-02-12 11:31 ` Takashi Iwai
-- strict thread matches above, loose matches on Subject: below --
2004-02-12 11:54 Gupta, Kshitij
2004-02-12 12:00 ` Jaroslav Kysela
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=s5h65eca7jw.wl@alsa2.suse.de \
--to=tiwai@suse.de \
--cc=alsa-devel@lists.sourceforge.net \
--cc=kshitij@ti.com \
/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