Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 30 Jan 2000 11:49:03 +0000
From:      Roger Hardiman <roger@cs.strath.ac.uk>
To:        Joachim =?iso-8859-1?Q?J=E4ckel?= <Joachim.Jaeckel@d.kamp.net>, freebsd-multimedia@FreeBSD.ORG
Subject:   Re: could need a little bit support with a device-driver
Message-ID:  <3894252F.F597ECDF@cs.strath.ac.uk>
References:  <38923745.8ADE97CC@d.kamp.net>

next in thread | previous in thread | raw e-mail | index | archive | help
Joachim,

> Because of that, I think I've to program it similiar to the
> i2c-interface of the bktr-device.

I'll explain bit-banging.

The i2c bus uses 2 wires, one for data, one for a clock pulse.

On the bt848 chip, you can write an i2c device address, and
some data to a single register and the bt848 handles the
i2c bus for you.

Alternativly, you can write your own software to drive
the data and clock lines (SDL and SCL) manually,
in which case you output each bit in turn, and handle the
full i2c protocol.
This manual control is called bit-banding.

in the bt848 driver, you can use the bt848 i2c control
for the tuner device, but you need to use bit banging
for the MSP34xx stereo audio decoder as it needs a
protocol unsupported by the bt848's easy i2c register.


Finally, the bktr driver used to do all the i2c control locally to the
driver.
Now it registers both as an i2c hardware provider and an
i2c bus user with the smbus and iicbus code.


Both the old code and the new code are in the driver
(as the driver still compiles on old FreeBSD versions and on NetBSD
and OpenBSD which do not have our smbus and iicbus code)


Good luck

Roger



To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-multimedia" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3894252F.F597ECDF>