1# SPDX-License-Identifier: GPL-2.0 2%YAML 1.2 3--- 4$id: http://devicetree.org/schemas/iio/adc/adi,ad7606.yaml# 5$schema: http://devicetree.org/meta-schemas/core.yaml# 6 7title: Analog Devices AD7606 Simultaneous Sampling ADC 8 9maintainers: 10 - Beniamin Bia <beniamin.bia@analog.com> 11 - Stefan Popa <stefan.popa@analog.com> 12 13description: | 14 Analog Devices AD7606 Simultaneous Sampling ADC 15 https://www.analog.com/media/en/technical-documentation/data-sheets/ad7606_7606-6_7606-4.pdf 16 https://www.analog.com/media/en/technical-documentation/data-sheets/AD7606B.pdf 17 https://www.analog.com/media/en/technical-documentation/data-sheets/AD7616.pdf 18 19properties: 20 compatible: 21 enum: 22 - adi,ad7605-4 23 - adi,ad7606-8 24 - adi,ad7606-6 25 - adi,ad7606-4 26 - adi,ad7606b 27 - adi,ad7616 28 29 reg: 30 maxItems: 1 31 32 spi-cpha: true 33 34 avcc-supply: 35 description: 36 Phandle to the Avcc power supply 37 maxItems: 1 38 39 interrupts: 40 maxItems: 1 41 42 adi,conversion-start-gpios: 43 description: 44 Must be the device tree identifier of the CONVST pin. 45 This logic input is used to initiate conversions on the analog 46 input channels. As the line is active high, it should be marked 47 GPIO_ACTIVE_HIGH. 48 maxItems: 1 49 50 reset-gpios: 51 description: 52 Must be the device tree identifier of the RESET pin. If specified, 53 it will be asserted during driver probe. As the line is active high, 54 it should be marked GPIO_ACTIVE_HIGH. 55 maxItems: 1 56 57 standby-gpios: 58 description: 59 Must be the device tree identifier of the STBY pin. This pin is used 60 to place the AD7606 into one of two power-down modes, Standby mode or 61 Shutdown mode. As the line is active low, it should be marked 62 GPIO_ACTIVE_LOW. 63 maxItems: 1 64 65 adi,first-data-gpios: 66 description: 67 Must be the device tree identifier of the FRSTDATA pin. 68 The FRSTDATA output indicates when the first channel, V1, is 69 being read back on either the parallel, byte or serial interface. 70 As the line is active high, it should be marked GPIO_ACTIVE_HIGH. 71 maxItems: 1 72 73 adi,range-gpios: 74 description: 75 Must be the device tree identifier of the RANGE pin. The polarity on 76 this pin determines the input range of the analog input channels. If 77 this pin is tied to a logic high, the analog input range is ±10V for 78 all channels. If this pin is tied to a logic low, the analog input range 79 is ±5V for all channels. As the line is active high, it should be marked 80 GPIO_ACTIVE_HIGH. 81 maxItems: 1 82 83 adi,oversampling-ratio-gpios: 84 description: 85 Must be the device tree identifier of the over-sampling 86 mode pins. As the line is active high, it should be marked 87 GPIO_ACTIVE_HIGH. 88 maxItems: 1 89 90 adi,sw-mode: 91 description: 92 Software mode of operation, so far available only for ad7616 and ad7606b. 93 It is enabled when all three oversampling mode pins are connected to 94 high level. The device is configured by the corresponding registers. If the 95 adi,oversampling-ratio-gpios property is defined, then the driver will set the 96 oversampling gpios to high. Otherwise, it is assumed that the pins are hardwired 97 to VDD. 98 type: boolean 99 100required: 101 - compatible 102 - reg 103 - spi-cpha 104 - avcc-supply 105 - interrupts 106 - adi,conversion-start-gpios 107 108examples: 109 - | 110 #include <dt-bindings/gpio/gpio.h> 111 #include <dt-bindings/interrupt-controller/irq.h> 112 spi0 { 113 #address-cells = <1>; 114 #size-cells = <0>; 115 116 adc@0 { 117 compatible = "adi,ad7606-8"; 118 reg = <0>; 119 spi-max-frequency = <1000000>; 120 spi-cpol; 121 spi-cpha; 122 123 avcc-supply = <&adc_vref>; 124 125 interrupts = <25 IRQ_TYPE_EDGE_FALLING>; 126 interrupt-parent = <&gpio>; 127 128 adi,conversion-start-gpios = <&gpio 17 GPIO_ACTIVE_HIGH>; 129 reset-gpios = <&gpio 27 GPIO_ACTIVE_HIGH>; 130 adi,first-data-gpios = <&gpio 22 GPIO_ACTIVE_HIGH>; 131 adi,oversampling-ratio-gpios = <&gpio 18 GPIO_ACTIVE_HIGH 132 &gpio 23 GPIO_ACTIVE_HIGH 133 &gpio 26 GPIO_ACTIVE_HIGH>; 134 standby-gpios = <&gpio 24 GPIO_ACTIVE_LOW>; 135 adi,sw-mode; 136 }; 137 }; 138... 139