1# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause) 2%YAML 1.2 3--- 4$id: http://devicetree.org/schemas/iio/dac/adi,ad5758.yaml# 5$schema: http://devicetree.org/meta-schemas/core.yaml# 6 7title: Analog Devices AD5758 DAC 8 9maintainers: 10 - Michael Hennerich <Michael.Hennerich@analog.com> 11 12properties: 13 compatible: 14 const: adi,ad5758 15 16 reg: 17 maxItems: 1 18 19 spi-cpha: true 20 21 adi,dc-dc-mode: 22 $ref: /schemas/types.yaml#/definitions/uint32 23 enum: [1, 2, 3] 24 description: | 25 Mode of operation of the dc-to-dc converter 26 Dynamic Power Control (DPC) 27 In this mode, the AD5758 circuitry senses the output voltage and 28 dynamically regulates the supply voltage, VDPC+, to meet compliance 29 requirements plus an optimized headroom voltage for the output buffer. 30 31 Programmable Power Control (PPC) 32 In this mode, the VDPC+ voltage is user-programmable to a fixed level 33 that needs to accommodate the maximum output load required. 34 35 The output of the DAC core is either converted to a current or 36 voltage output at the VIOUT pin. Only one mode can be enabled at 37 any one time. 38 39 The following values are currently supported: 40 * 1: DPC current mode 41 * 2: DPC voltage mode 42 * 3: PPC current mode 43 44 Depending on the selected output mode (voltage or current) one of the 45 two properties must be present: 46 47 adi,range-microvolt: 48 description: | 49 Voltage output range specified as <minimum, maximum> 50 oneOf: 51 - items: 52 - const: 0 53 - enum: [5000000, 10000000] 54 - items: 55 - const: -5000000 56 - const: 5000000 57 - items: 58 - const: -10000000 59 - const: 10000000 60 61 adi,range-microamp: 62 description: | 63 Current output range specified as <minimum, maximum> 64 oneOf: 65 - items: 66 - const: 0 67 - enum: [20000, 24000] 68 - items: 69 - const: 4 70 - const: 24000 71 - items: 72 - const: -20000 73 - const: 20000 74 - items: 75 - const: -24000 76 - const: 24000 77 - items: 78 - const: -1000 79 - const: 22000 80 81 reset-gpios: 82 maxItems: 1 83 84 adi,dc-dc-ilim-microamp: 85 enum: [150000, 200000, 250000, 300000, 350000, 400000] 86 description: | 87 The dc-to-dc converter current limit. 88 89 adi,slew-time-us: 90 description: | 91 The time it takes for the output to reach the full scale [uS] 92 minimum: 133 93 maximum: 1023984375 94 95required: 96 - compatible 97 - reg 98 - spi-cpha 99 - adi,dc-dc-mode 100 101allOf: 102 - $ref: /schemas/spi/spi-peripheral-props.yaml# 103 - if: 104 properties: 105 adi,dc-dc-mode: 106 enum: [1, 3] 107 then: 108 properties: 109 adi,range-microvolt: false 110 required: 111 - adi,range-microamp 112 else: 113 properties: 114 adi,range-microamp: false 115 required: 116 - adi,range-microvolt 117 118unevaluatedProperties: false 119 120examples: 121 - | 122 spi { 123 #address-cells = <1>; 124 #size-cells = <0>; 125 126 dac@0 { 127 compatible = "adi,ad5758"; 128 reg = <0>; 129 spi-max-frequency = <1000000>; 130 spi-cpha; 131 132 reset-gpios = <&gpio 22 0>; 133 134 adi,dc-dc-mode = <2>; 135 adi,range-microvolt = <0 10000000>; 136 adi,dc-dc-ilim-microamp = <200000>; 137 adi,slew-time-us = <125000>; 138 }; 139 }; 140... 141