Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input
[sfrench/cifs-2.6.git] / Documentation / devicetree / bindings / iio / accel / adxl345.txt
1 Analog Devices ADXL345/ADXL375 3-Axis Digital Accelerometers
2
3 http://www.analog.com/en/products/mems/accelerometers/adxl345.html
4 http://www.analog.com/en/products/sensors-mems/accelerometers/adxl375.html
5
6 Required properties:
7  - compatible : should be one of
8                 "adi,adxl345"
9                 "adi,adxl375"
10  - reg : the I2C address or SPI chip select number of the sensor
11
12 Required properties for SPI bus usage:
13  - spi-max-frequency : set maximum clock frequency, must be 5000000
14  - spi-cpol and spi-cpha : must be defined for adxl345 to enable SPI mode 3
15
16 Optional properties:
17  - interrupts: interrupt mapping for IRQ as documented in
18    Documentation/devicetree/bindings/interrupt-controller/interrupts.txt
19
20 Example for a I2C device node:
21
22         accelerometer@2a {
23                 compatible = "adi,adxl345";
24                 reg = <0x53>;
25                 interrupt-parent = <&gpio1>;
26                 interrupts = <0 IRQ_TYPE_LEVEL_HIGH>;
27         };
28
29 Example for a SPI device node:
30
31         accelerometer@0 {
32                 compatible = "adi,adxl345";
33                 reg = <0>;
34                 spi-max-frequency = <5000000>;
35                 spi-cpol;
36                 spi-cpha;
37                 interrupt-parent = <&gpio1>;
38                 interrupts = <0 IRQ_TYPE_LEVEL_HIGH>;
39         };