Skip to content

Commit f160b71

Browse files
committed
drivers: iio: adc: AD7768 Driver support
Add support for AD7768 4/8 channel,simultaneous sampling Sigma-Delta ADC Signed-off-by: Janani Sunil <janani.sunil@analog.com>
1 parent 2bbdba6 commit f160b71

7 files changed

Lines changed: 1350 additions & 7 deletions

File tree

Documentation/devicetree/bindings/iio/adc/adi,ad7768.yaml

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ $schema: http://devicetree.org/meta-schemas/core.yaml#
77
title: Analog Devices AD7768 and AD7768-4 ADC device driver
88

99
maintainers:
10-
- Michael Hennerich <michael.hennerich@analog.com>
10+
- Janani Sunil <janani.sunil@analog.com>
1111

1212
description: |
1313
The AD7768 is a 8-channel, 24-bit simultaneous sampling ADC with configurable
@@ -114,8 +114,8 @@ patternProperties:
114114
maximum: 1
115115
description: |
116116
Channel mode selection:
117-
0 - Channel uses global mode settings
118-
1 - Channel uses individual mode settings
117+
0 - Channel uses Mode A settings
118+
1 - Channel uses Mode B settings
119119
120120
adi,prebuf-pos-en:
121121
type: boolean
@@ -223,7 +223,6 @@ examples:
223223
#include <dt-bindings/iio/adc/adi,ad7768.h>
224224
#include <dt-bindings/gpio/gpio.h>
225225
226-
// AD7768-4 example
227226
spi {
228227
#address-cells = <1>;
229228
#size-cells = <0>;
@@ -241,7 +240,7 @@ examples:
241240
clock-names = "mclk";
242241
243242
adi,data-lines-number = <4>;
244-
adi,common-mode-output-v = <AD7768_2P05_V>;
243+
adi,common-mode-output-v = <AD7768_2P14_V>;
245244
adi,power-mode = <AD7768_POWER_MODE_FAST>;
246245
247246
io-backends = <&iio_backend>;
@@ -264,4 +263,4 @@ examples:
264263
};
265264
};
266265
};
267-
...
266+
...

drivers/iio/adc/Kconfig

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -382,6 +382,20 @@ config AD7766
382382
To compile this driver as a module, choose M here: the module will be
383383
called ad7766.
384384

385+
config AD7768
386+
tristate "Analog Devices AD7768 ADC driver"
387+
depends on SPI_MASTER
388+
depends on ADI_AXI_ADC
389+
select IIO_BUFFER
390+
select IIO_TRIGGERED_BUFFER
391+
select REGMAP_SPI
392+
help
393+
Say yes here to build support for Analog Devices AD7768 and AD7768-4
394+
SPI analog to digital converters.
395+
396+
To compile this driver as a module, choose M here: the module will be
397+
called ad7768.
398+
385399
config AD7768_1
386400
tristate "Analog Devices AD7768-1 ADC driver"
387401
depends on SPI
@@ -547,6 +561,7 @@ config ADI_AXI_ADC
547561
select IIO_BUFFER_HW_CONSUMER
548562
select IIO_BUFFER_DMAENGINE
549563
select REGMAP_MMIO
564+
select REGMAP_SPI
550565
select IIO_BACKEND
551566
help
552567
Say yes here to build support for Analog Devices Generic

drivers/iio/adc/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ obj-$(CONFIG_AD7606_IFACE_SPI) += ad7606_spi.o
3636
obj-$(CONFIG_AD7606) += ad7606.o
3737
obj-$(CONFIG_AD7625) += ad7625.o
3838
obj-$(CONFIG_AD7766) += ad7766.o
39+
obj-$(CONFIG_AD7768) += ad7768.o
3940
obj-$(CONFIG_AD7768_1) += ad7768-1.o
4041
obj-$(CONFIG_AD7779) += ad7779.o
4142
obj-$(CONFIG_AD7780) += ad7780.o

0 commit comments

Comments
 (0)