]>
Commit | Line | Data |
---|---|---|
6259551c LW |
1 | # SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause) |
2 | %YAML 1.2 | |
3 | --- | |
4 | $id: http://devicetree.org/schemas/iio/accel/bosch,bma255.yaml# | |
5 | $schema: http://devicetree.org/meta-schemas/core.yaml# | |
6 | ||
7 | title: Bosch BMA255 and Similar Accelerometers | |
8 | ||
9 | maintainers: | |
10 | - Linus Walleij <linus.walleij@linaro.org> | |
7e6b7866 | 11 | - Stephan Gerhold <stephan@gerhold.net> |
6259551c LW |
12 | |
13 | description: | |
14 | 3 axis accelerometers with varying range and I2C or SPI | |
15 | 4-wire interface. | |
16 | ||
17 | properties: | |
18 | compatible: | |
19 | enum: | |
7e6b7866 | 20 | # bmc150-accel driver in Linux |
562442d5 SG |
21 | - bosch,bma222 |
22 | - bosch,bma222e | |
23 | - bosch,bma250e | |
c3a16200 | 24 | - bosch,bma253 |
5640fed3 | 25 | - bosch,bma254 |
6259551c | 26 | - bosch,bma255 |
6259551c | 27 | - bosch,bma280 |
562442d5 | 28 | - bosch,bmc150_accel |
02104141 | 29 | - bosch,bmc156_accel |
562442d5 | 30 | - bosch,bmi055_accel |
6259551c | 31 | |
7e6b7866 SG |
32 | # bma180 driver in Linux |
33 | - bosch,bma023 | |
34 | - bosch,bma150 | |
35 | - bosch,bma180 | |
36 | - bosch,bma250 | |
37 | - bosch,smb380 | |
38 | ||
6259551c LW |
39 | reg: |
40 | maxItems: 1 | |
41 | ||
42 | vdd-supply: true | |
43 | vddio-supply: true | |
44 | ||
45 | interrupts: | |
d1e7ff89 SG |
46 | minItems: 1 |
47 | maxItems: 2 | |
48 | description: | | |
84c31a04 SG |
49 | Without interrupt-names, the first interrupt listed must be the one |
50 | connected to the INT1 pin, the second (optional) interrupt listed must be | |
51 | the one connected to the INT2 pin (if available). The type should be | |
52 | IRQ_TYPE_EDGE_RISING. | |
53 | ||
02104141 SG |
54 | BMC156 does not have an INT1 pin, therefore the first interrupt pin is |
55 | always treated as INT2. | |
56 | ||
84c31a04 SG |
57 | interrupt-names: |
58 | minItems: 1 | |
59 | maxItems: 2 | |
60 | items: | |
61 | enum: | |
62 | - INT1 | |
63 | - INT2 | |
6259551c LW |
64 | |
65 | mount-matrix: | |
66 | description: an optional 3x3 mounting rotation matrix. | |
67 | ||
68 | spi-max-frequency: | |
69 | maximum: 10000000 | |
70 | ||
71 | required: | |
72 | - compatible | |
73 | - reg | |
74 | ||
75 | additionalProperties: false | |
76 | ||
77 | examples: | |
78 | - | | |
79 | #include <dt-bindings/interrupt-controller/irq.h> | |
80 | i2c { | |
81 | #address-cells = <1>; | |
82 | #size-cells = <0>; | |
83 | accelerometer@8 { | |
84 | compatible = "bosch,bma222"; | |
85 | reg = <0x08>; | |
86 | vddio-supply = <&vddio>; | |
87 | vdd-supply = <&vdd>; | |
39361c99 | 88 | interrupts = <57 IRQ_TYPE_EDGE_RISING>; |
84c31a04 | 89 | interrupt-names = "INT1"; |
6259551c LW |
90 | }; |
91 | }; | |
02104141 SG |
92 | - | |
93 | #include <dt-bindings/interrupt-controller/irq.h> | |
94 | i2c { | |
95 | #address-cells = <1>; | |
96 | #size-cells = <0>; | |
97 | accelerometer@10 { | |
98 | compatible = "bosch,bmc156_accel"; | |
99 | reg = <0x10>; | |
100 | vddio-supply = <&vddio>; | |
101 | vdd-supply = <&vdd>; | |
102 | interrupts = <116 IRQ_TYPE_EDGE_RISING>; | |
103 | interrupt-names = "INT2"; | |
104 | }; | |
105 | }; | |
6259551c LW |
106 | - | |
107 | # include <dt-bindings/interrupt-controller/irq.h> | |
108 | spi { | |
109 | #address-cells = <1>; | |
110 | #size-cells = <0>; | |
111 | accel@0 { | |
112 | compatible = "bosch,bma222"; | |
113 | reg = <0>; | |
114 | spi-max-frequency = <10000000>; | |
115 | }; | |
116 | }; | |
117 | ... |