Back to home page

OSCL-LXR

 
 

    


0001 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
0002 %YAML 1.2
0003 ---
0004 $id: http://devicetree.org/schemas/hwmon/adi,adm1177.yaml#
0005 $schema: http://devicetree.org/meta-schemas/core.yaml#
0006 
0007 title: Analog Devices ADM1177 Hot Swap Controller and Digital Power Monitor
0008 
0009 maintainers:
0010   - Michael Hennerich <michael.hennerich@analog.com>
0011 
0012 description: |
0013   Analog Devices ADM1177 Hot Swap Controller and Digital Power Monitor
0014   https://www.analog.com/media/en/technical-documentation/data-sheets/ADM1177.pdf
0015 
0016 properties:
0017   compatible:
0018     enum:
0019       - adi,adm1177
0020 
0021   reg:
0022     maxItems: 1
0023 
0024   avcc-supply:
0025     description:
0026       Phandle to the Avcc power supply
0027 
0028   shunt-resistor-micro-ohms:
0029     description:
0030       The value of curent sense resistor in microohms. If not provided,
0031       the current reading and overcurrent alert is disabled.
0032 
0033   adi,shutdown-threshold-microamp:
0034     description:
0035       Specifies the current level at which an over current alert occurs.
0036       If not provided, the overcurrent alert is configured to max ADC range
0037       based on shunt-resistor-micro-ohms.
0038 
0039   adi,vrange-high-enable:
0040     description:
0041       Specifies which internal voltage divider to be used. A 1 selects
0042       a 7:2 voltage divider while a 0 selects a 14:1 voltage divider.
0043     type: boolean
0044 
0045 required:
0046   - compatible
0047   - reg
0048 
0049 additionalProperties: false
0050 
0051 examples:
0052   - |
0053     #include <dt-bindings/gpio/gpio.h>
0054     #include <dt-bindings/interrupt-controller/irq.h>
0055     i2c0 {
0056         #address-cells = <1>;
0057         #size-cells = <0>;
0058 
0059         pwmon@5a {
0060                 compatible = "adi,adm1177";
0061                 reg = <0x5a>;
0062                 shunt-resistor-micro-ohms = <50000>; /* 50 mOhm */
0063                 adi,shutdown-threshold-microamp = <1059000>; /* 1.059 A */
0064                 adi,vrange-high-enable;
0065         };
0066     };
0067 ...