2011-03-30 13:49:47 +00:00
|
|
|
.TH TWSI 3
|
|
|
|
.SH NAME
|
2018-02-11 21:54:10 +00:00
|
|
|
twsi - two-wire serial interface (TWSI) and inter-integrated circuit (I²C) interface
|
2011-03-30 13:49:47 +00:00
|
|
|
.SH SYNOPSIS
|
2018-02-11 21:54:10 +00:00
|
|
|
.B bind -a #² /dev
|
2011-03-30 13:49:47 +00:00
|
|
|
.sp 0.3v
|
|
|
|
.B /dev/twsi*
|
|
|
|
.SH DESCRIPTION
|
|
|
|
The
|
|
|
|
.I twsi
|
2018-02-11 21:54:10 +00:00
|
|
|
device serves a one-level directory containing one file per TWSI or I²C bus.
|
2011-03-30 13:49:47 +00:00
|
|
|
Bytes written are transmitted on the bus;
|
|
|
|
bytes received from the bus are queued and delivered by reading.
|
|
|
|
Seeking to a given offset before reading or writing causes the
|
|
|
|
.I twsi
|
|
|
|
device to use that offset as a TWSI slave address for a subsequent
|
|
|
|
.IR read (2)
|
|
|
|
or
|
|
|
|
.IR write
|
|
|
|
call.
|
|
|
|
.SH FILES
|
2018-02-11 21:54:10 +00:00
|
|
|
.B #²/twsi*
|
2011-03-30 13:49:47 +00:00
|
|
|
.SH SOURCE
|
|
|
|
.B /sys/src/9/*/devtwsi.c
|
|
|
|
.SH BUGS
|
|
|
|
10-bit addressed devices are not supported.
|
|
|
|
.PP
|
|
|
|
No slave mode.
|
|
|
|
.PP
|
|
|
|
Setting the bus rate is not supported.
|