xref: /freebsd/sys/contrib/device-tree/Bindings/iio/dac/adi,ad5758.yaml (revision aa1a8ff2d6dbc51ef058f46f3db5a8bb77967145)
15def4c47SEmmanuel Vadot# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
25def4c47SEmmanuel Vadot%YAML 1.2
35def4c47SEmmanuel Vadot---
45def4c47SEmmanuel Vadot$id: http://devicetree.org/schemas/iio/dac/adi,ad5758.yaml#
55def4c47SEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml#
65def4c47SEmmanuel Vadot
75def4c47SEmmanuel Vadottitle: Analog Devices AD5758 DAC
85def4c47SEmmanuel Vadot
95def4c47SEmmanuel Vadotmaintainers:
105def4c47SEmmanuel Vadot  - Michael Hennerich <Michael.Hennerich@analog.com>
115def4c47SEmmanuel Vadot
125def4c47SEmmanuel Vadotproperties:
135def4c47SEmmanuel Vadot  compatible:
145def4c47SEmmanuel Vadot    const: adi,ad5758
155def4c47SEmmanuel Vadot
165def4c47SEmmanuel Vadot  reg:
175def4c47SEmmanuel Vadot    maxItems: 1
185def4c47SEmmanuel Vadot
195def4c47SEmmanuel Vadot  spi-cpha: true
205def4c47SEmmanuel Vadot
215def4c47SEmmanuel Vadot  adi,dc-dc-mode:
225def4c47SEmmanuel Vadot    $ref: /schemas/types.yaml#/definitions/uint32
235def4c47SEmmanuel Vadot    enum: [1, 2, 3]
245def4c47SEmmanuel Vadot    description: |
255def4c47SEmmanuel Vadot      Mode of operation of the dc-to-dc converter
265def4c47SEmmanuel Vadot      Dynamic Power Control (DPC)
275def4c47SEmmanuel Vadot      In this mode, the AD5758 circuitry senses the output voltage and
285def4c47SEmmanuel Vadot      dynamically regulates the supply voltage, VDPC+, to meet compliance
295def4c47SEmmanuel Vadot      requirements plus an optimized headroom voltage for the output buffer.
305def4c47SEmmanuel Vadot
315def4c47SEmmanuel Vadot      Programmable Power Control (PPC)
325def4c47SEmmanuel Vadot      In this mode, the VDPC+ voltage is user-programmable to a fixed level
335def4c47SEmmanuel Vadot      that needs to accommodate the maximum output load required.
345def4c47SEmmanuel Vadot
355def4c47SEmmanuel Vadot      The output of the DAC core is either converted to a current or
365def4c47SEmmanuel Vadot      voltage output at the VIOUT pin. Only one mode can be enabled at
375def4c47SEmmanuel Vadot      any one time.
385def4c47SEmmanuel Vadot
395def4c47SEmmanuel Vadot      The following values are currently supported:
405def4c47SEmmanuel Vadot      * 1: DPC current mode
415def4c47SEmmanuel Vadot      * 2: DPC voltage mode
425def4c47SEmmanuel Vadot      * 3: PPC current mode
435def4c47SEmmanuel Vadot
445def4c47SEmmanuel Vadot      Depending on the selected output mode (voltage or current) one of the
455def4c47SEmmanuel Vadot      two properties must be present:
465def4c47SEmmanuel Vadot
475def4c47SEmmanuel Vadot  adi,range-microvolt:
485def4c47SEmmanuel Vadot    description: |
495def4c47SEmmanuel Vadot      Voltage output range specified as <minimum, maximum>
505def4c47SEmmanuel Vadot    oneOf:
515def4c47SEmmanuel Vadot      - items:
525def4c47SEmmanuel Vadot          - const: 0
535def4c47SEmmanuel Vadot          - enum: [5000000, 10000000]
545def4c47SEmmanuel Vadot      - items:
555def4c47SEmmanuel Vadot          - const: -5000000
565def4c47SEmmanuel Vadot          - const: 5000000
575def4c47SEmmanuel Vadot      - items:
585def4c47SEmmanuel Vadot          - const: -10000000
595def4c47SEmmanuel Vadot          - const: 10000000
605def4c47SEmmanuel Vadot
615def4c47SEmmanuel Vadot  adi,range-microamp:
625def4c47SEmmanuel Vadot    description: |
635def4c47SEmmanuel Vadot      Current output range specified as <minimum, maximum>
645def4c47SEmmanuel Vadot    oneOf:
655def4c47SEmmanuel Vadot      - items:
665def4c47SEmmanuel Vadot          - const: 0
675def4c47SEmmanuel Vadot          - enum: [20000, 24000]
685def4c47SEmmanuel Vadot      - items:
695def4c47SEmmanuel Vadot          - const: 4
705def4c47SEmmanuel Vadot          - const: 24000
715def4c47SEmmanuel Vadot      - items:
725def4c47SEmmanuel Vadot          - const: -20000
735def4c47SEmmanuel Vadot          - const: 20000
745def4c47SEmmanuel Vadot      - items:
755def4c47SEmmanuel Vadot          - const: -24000
765def4c47SEmmanuel Vadot          - const: 24000
775def4c47SEmmanuel Vadot      - items:
785def4c47SEmmanuel Vadot          - const: -1000
795def4c47SEmmanuel Vadot          - const: 22000
805def4c47SEmmanuel Vadot
81*aa1a8ff2SEmmanuel Vadot  reset-gpios:
82*aa1a8ff2SEmmanuel Vadot    maxItems: 1
835def4c47SEmmanuel Vadot
845def4c47SEmmanuel Vadot  adi,dc-dc-ilim-microamp:
855def4c47SEmmanuel Vadot    enum: [150000, 200000, 250000, 300000, 350000, 400000]
865def4c47SEmmanuel Vadot    description: |
875def4c47SEmmanuel Vadot      The dc-to-dc converter current limit.
885def4c47SEmmanuel Vadot
895def4c47SEmmanuel Vadot  adi,slew-time-us:
905def4c47SEmmanuel Vadot    description: |
915def4c47SEmmanuel Vadot      The time it takes for the output to reach the full scale [uS]
925def4c47SEmmanuel Vadot    minimum: 133
935def4c47SEmmanuel Vadot    maximum: 1023984375
945def4c47SEmmanuel Vadot
955def4c47SEmmanuel Vadotrequired:
965def4c47SEmmanuel Vadot  - compatible
975def4c47SEmmanuel Vadot  - reg
985def4c47SEmmanuel Vadot  - spi-cpha
995def4c47SEmmanuel Vadot  - adi,dc-dc-mode
1005def4c47SEmmanuel Vadot
1015def4c47SEmmanuel VadotallOf:
1027ef62cebSEmmanuel Vadot  - $ref: /schemas/spi/spi-peripheral-props.yaml#
1035def4c47SEmmanuel Vadot  - if:
1045def4c47SEmmanuel Vadot      properties:
1055def4c47SEmmanuel Vadot        adi,dc-dc-mode:
1065def4c47SEmmanuel Vadot          enum: [1, 3]
1075def4c47SEmmanuel Vadot    then:
1085def4c47SEmmanuel Vadot      properties:
1095def4c47SEmmanuel Vadot        adi,range-microvolt: false
1105def4c47SEmmanuel Vadot      required:
1115def4c47SEmmanuel Vadot        - adi,range-microamp
1125def4c47SEmmanuel Vadot    else:
1135def4c47SEmmanuel Vadot      properties:
1145def4c47SEmmanuel Vadot        adi,range-microamp: false
1155def4c47SEmmanuel Vadot      required:
1165def4c47SEmmanuel Vadot        - adi,range-microvolt
1175def4c47SEmmanuel Vadot
1187ef62cebSEmmanuel VadotunevaluatedProperties: false
1195def4c47SEmmanuel Vadot
1205def4c47SEmmanuel Vadotexamples:
1215def4c47SEmmanuel Vadot  - |
1225def4c47SEmmanuel Vadot    spi {
1235def4c47SEmmanuel Vadot        #address-cells = <1>;
1245def4c47SEmmanuel Vadot        #size-cells = <0>;
1255def4c47SEmmanuel Vadot
1265def4c47SEmmanuel Vadot        dac@0 {
1275def4c47SEmmanuel Vadot            compatible = "adi,ad5758";
1285def4c47SEmmanuel Vadot            reg = <0>;
1295def4c47SEmmanuel Vadot            spi-max-frequency = <1000000>;
1305def4c47SEmmanuel Vadot            spi-cpha;
1315def4c47SEmmanuel Vadot
1325def4c47SEmmanuel Vadot            reset-gpios = <&gpio 22 0>;
1335def4c47SEmmanuel Vadot
1345def4c47SEmmanuel Vadot            adi,dc-dc-mode = <2>;
1355def4c47SEmmanuel Vadot            adi,range-microvolt = <0 10000000>;
1365def4c47SEmmanuel Vadot            adi,dc-dc-ilim-microamp = <200000>;
1375def4c47SEmmanuel Vadot            adi,slew-time-us = <125000>;
1385def4c47SEmmanuel Vadot        };
1395def4c47SEmmanuel Vadot    };
1405def4c47SEmmanuel Vadot...
141