Staging: DST: extend thread pool exit conditions.
[pohmelfs.git] / Documentation / i2c / chips / pca9539
blob6aff890088b15d74d08119ecf97f8e250fac9605
1 Kernel driver pca9539
2 =====================
4 NOTE: this driver is deprecated and will be dropped soon, use
5 drivers/gpio/pca9539.c instead.
7 Supported chips:
8   * Philips PCA9539
9     Prefix: 'pca9539'
10     Addresses scanned: none
11     Datasheet:
12         http://www.semiconductors.philips.com/acrobat/datasheets/PCA9539_2.pdf
14 Author: Ben Gardner <bgardner@wabtec.com>
17 Description
18 -----------
20 The Philips PCA9539 is a 16 bit low power I/O device.
21 All 16 lines can be individually configured as an input or output.
22 The input sense can also be inverted.
23 The 16 lines are split between two bytes.
26 Detection
27 ---------
29 The PCA9539 is difficult to detect and not commonly found in PC machines,
30 so you have to pass the I2C bus and address of the installed PCA9539
31 devices explicitly to the driver at load time via the force=... parameter.
34 Sysfs entries
35 -------------
37 Each is a byte that maps to the 8 I/O bits.
38 A '0' suffix is for bits 0-7, while '1' is for bits 8-15.
40 input[01]     - read the current value
41 output[01]    - sets the output value
42 direction[01] - direction of each bit: 1=input, 0=output
43 invert[01]    - toggle the input bit sense
45 input reads the actual state of the line and is always available.
46 The direction defaults to input for all channels.
49 General Remarks
50 ---------------
52 Note that each output, direction, and invert entry controls 8 lines.
53 You should use the read, modify, write sequence.
54 For example. to set output bit 0 of 1.
55   val=$(cat output0)
56   val=$(( $val | 1 ))
57   echo $val > output0