Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
torvalds
GitHub Repository: torvalds/linux
Path: blob/master/Documentation/devicetree/bindings/iio/accel/adi,adxl313.yaml
29539 views
1
# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
2
%YAML 1.2
3
---
4
$id: http://devicetree.org/schemas/iio/accel/adi,adxl313.yaml#
5
$schema: http://devicetree.org/meta-schemas/core.yaml#
6
7
title: Analog Devices ADXL312, ADXL313, and ADXL314 3-Axis Digital Accelerometers
8
9
maintainers:
10
- Lucas Stankus <lucas.p.stankus@gmail.com>
11
12
description: |
13
Analog Devices ADXL312, ADXL313, and ADXL314 3-Axis Digital Accelerometer that
14
support both I2C & SPI interfaces.
15
https://www.analog.com/en/products/adxl312.html
16
https://www.analog.com/en/products/adxl313.html
17
https://www.analog.com/en/products/adxl314.html
18
19
properties:
20
compatible:
21
enum:
22
- adi,adxl312
23
- adi,adxl313
24
- adi,adxl314
25
26
reg:
27
maxItems: 1
28
29
spi-3wire: true
30
31
vs-supply:
32
description: Regulator that supplies power to the accelerometer
33
34
vdd-supply:
35
description: Regulator that supplies the digital interface supply voltage
36
37
interrupts:
38
minItems: 1
39
maxItems: 2
40
41
interrupt-names:
42
minItems: 1
43
maxItems: 2
44
items:
45
enum:
46
- INT1
47
- INT2
48
49
required:
50
- compatible
51
- reg
52
53
allOf:
54
- $ref: /schemas/spi/spi-peripheral-props.yaml#
55
56
unevaluatedProperties: false
57
58
examples:
59
- |
60
#include <dt-bindings/interrupt-controller/irq.h>
61
i2c {
62
#address-cells = <1>;
63
#size-cells = <0>;
64
65
/* Example for a I2C device node */
66
accelerometer@53 {
67
compatible = "adi,adxl313";
68
reg = <0x53>;
69
interrupt-parent = <&gpio0>;
70
interrupts = <0 IRQ_TYPE_LEVEL_HIGH>;
71
interrupt-names = "INT1";
72
};
73
};
74
- |
75
#include <dt-bindings/interrupt-controller/irq.h>
76
spi {
77
#address-cells = <1>;
78
#size-cells = <0>;
79
80
/* Example for a SPI device node */
81
accelerometer@0 {
82
compatible = "adi,adxl313";
83
reg = <0>;
84
spi-max-frequency = <5000000>;
85
interrupt-parent = <&gpio0>;
86
interrupts = <0 IRQ_TYPE_LEVEL_HIGH>;
87
interrupt-names = "INT1";
88
};
89
};
90
91