blob: ba6850ab1f90cc7beb6f33fc75b98fde4e9e4420 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
|
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
%YAML 1.2
---
$id: http://devicetree.org/schemas/iio/adc/ti,ads1119.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#
title: Texas Instruments ADS1119 ADC
maintainers:
- João Paulo Gonçalves <jpaulo.silvagoncalves@gmail.com>
description:
The TI ADS1119 is a precision 16-bit ADC over I2C that offers single-ended and
differential measurements using a multiplexed input. It features a programmable
gain, a programmable sample rate, an internal oscillator and voltage reference,
and a 50/60Hz rejection filter.
properties:
compatible:
const: ti,ads1119
reg:
maxItems: 1
interrupts:
maxItems: 1
reset-gpios:
maxItems: 1
avdd-supply: true
dvdd-supply: true
vref-supply:
description:
ADC external reference voltage (VREF).
"#address-cells":
const: 1
"#size-cells":
const: 0
"#io-channel-cells":
const: 1
required:
- compatible
- reg
- "#address-cells"
- "#size-cells"
- avdd-supply
- dvdd-supply
patternProperties:
"^channel@([0-6])$":
$ref: adc.yaml
type: object
properties:
reg:
minimum: 0
maximum: 6
diff-channels:
description:
Differential input channels AIN0-AIN1, AIN2-AIN3 and AIN1-AIN2.
oneOf:
- items:
- const: 0
- const: 1
- items:
- const: 2
- const: 3
- items:
- const: 1
- const: 2
single-channel:
description:
Single-ended input channels AIN0, AIN1, AIN2 and AIN3.
minimum: 0
maximum: 3
oneOf:
- required:
- diff-channels
- required:
- single-channel
required:
- reg
unevaluatedProperties: false
additionalProperties: false
examples:
- |
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/interrupt-controller/irq.h>
i2c {
#address-cells = <1>;
#size-cells = <0>;
adc@40 {
compatible = "ti,ads1119";
reg = <0x40>;
interrupt-parent = <&gpio1>;
interrupts = <25 IRQ_TYPE_EDGE_FALLING>;
reset-gpios = <&gpio1 10 GPIO_ACTIVE_LOW>;
avdd-supply = <®_avdd_ads1119>;
dvdd-supply = <®_dvdd_ads1119>;
vref-supply = <®_vref_ads1119>;
#address-cells = <1>;
#size-cells = <0>;
#io-channel-cells = <1>;
channel@0 {
reg = <0>;
single-channel = <0>;
};
channel@1 {
reg = <1>;
diff-channels = <0 1>;
};
channel@2 {
reg = <2>;
single-channel = <3>;
};
channel@3 {
reg = <3>;
single-channel = <1>;
};
channel@4 {
reg = <4>;
single-channel = <2>;
};
channel@5 {
reg = <5>;
diff-channels = <1 2>;
};
channel@6 {
reg = <6>;
diff-channels = <2 3>;
};
};
};
|