Back to home page

OSCL-LXR

 
 

    


0001 # SPDX-License-Identifier: GPL-2.0
0002 %YAML 1.2
0003 ---
0004 $id: http://devicetree.org/schemas/iio/accel/adi,adxl372.yaml#
0005 $schema: http://devicetree.org/meta-schemas/core.yaml#
0006 
0007 title: Analog Devices ADXL372 3-Axis, +/-(200g) Digital Accelerometer
0008 
0009 maintainers:
0010   - Stefan Popa <stefan.popa@analog.com>
0011 
0012 description: |
0013   Analog Devices ADXL372 3-Axis, +/-(200g) Digital Accelerometer that supports
0014   both I2C & SPI interfaces
0015     https://www.analog.com/en/products/adxl372.html
0016 
0017 properties:
0018   compatible:
0019     enum:
0020       - adi,adxl372
0021 
0022   reg:
0023     maxItems: 1
0024 
0025   interrupts:
0026     maxItems: 1
0027 
0028   spi-max-frequency: true
0029 
0030 required:
0031   - compatible
0032   - reg
0033   - interrupts
0034 
0035 additionalProperties: false
0036 
0037 examples:
0038   - |
0039         #include <dt-bindings/gpio/gpio.h>
0040         #include <dt-bindings/interrupt-controller/irq.h>
0041         i2c0 {
0042                 #address-cells = <1>;
0043                 #size-cells = <0>;
0044 
0045                 /* Example for a I2C device node */
0046                 accelerometer@53 {
0047                         compatible = "adi,adxl372";
0048                         reg = <0x53>;
0049                         interrupt-parent = <&gpio>;
0050                         interrupts = <25 IRQ_TYPE_EDGE_FALLING>;
0051                 };
0052         };
0053   - |
0054         #include <dt-bindings/gpio/gpio.h>
0055         #include <dt-bindings/interrupt-controller/irq.h>
0056         spi0 {
0057                 #address-cells = <1>;
0058                 #size-cells = <0>;
0059 
0060                 accelerometer@0 {
0061                         compatible = "adi,adxl372";
0062                         reg = <0>;
0063                         spi-max-frequency = <1000000>;
0064                         interrupt-parent = <&gpio>;
0065                         interrupts = <25 IRQ_TYPE_EDGE_FALLING>;
0066                 };
0067         };