Back to home page

OSCL-LXR

 
 

    


0001 # SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
0002 %YAML 1.2
0003 ---
0004 $id: http://devicetree.org/schemas/iio/dac/microchip,mcp4725.yaml#
0005 $schema: http://devicetree.org/meta-schemas/core.yaml#
0006 
0007 title: Microchip mcp4725 and mcp4726 DAC
0008 
0009 maintainers:
0010   - Tomas Novotny <tomas@novotny.cz>
0011 
0012 properties:
0013   compatible:
0014     enum:
0015       - microchip,mcp4725
0016       - microchip,mcp4726
0017 
0018   reg:
0019     maxItems: 1
0020 
0021   vdd-supply:
0022     description: |
0023       Provides both power and acts as the reference supply on the mcp4725.
0024       For the mcp4726 it will be used as the reference voltage if vref-supply
0025       is not provided.
0026 
0027   vref-supply:
0028     description:
0029       Vref pin is used as a voltage reference when this supply is specified.
0030 
0031   microchip,vref-buffered:
0032     type: boolean
0033     description: |
0034       Enable buffering of the external Vref pin. This boolean is not valid
0035       without the vref-supply. Quoting the datasheet: This is offered in
0036       cases where the reference voltage does not have the current
0037       capability not to drop its voltage when connected to the internal
0038       resistor ladder circuit.
0039 
0040 allOf:
0041   - if:
0042       properties:
0043         compatible:
0044           contains:
0045             const: microchip,mcp4725
0046     then:
0047       properties:
0048         vref-supply: false
0049       required:
0050         - vdd-supply
0051 
0052   - if:
0053       properties:
0054         compatible:
0055           contains:
0056             const: microchip,mcp4726
0057     then:
0058       anyOf:
0059         - required:
0060             - vdd-supply
0061         - required:
0062             - vref-supply
0063 
0064   - if:
0065       not:
0066         required:
0067           - vref-supply
0068     then:
0069       properties:
0070         microchip,vref-buffered: false
0071 
0072 required:
0073   - compatible
0074   - reg
0075 
0076 additionalProperties: false
0077 
0078 examples:
0079   - |
0080     i2c {
0081         #address-cells = <1>;
0082         #size-cells = <0>;
0083 
0084         mcp4725@60 {
0085             compatible = "microchip,mcp4725";
0086             reg = <0x60>;
0087             vdd-supply = <&vdac_vdd>;
0088         };
0089     };
0090 ...