1 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
4 $id: http://devicetree.org/schemas/hwmon/adi,ltc2947.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
7 title: Analog Devices LTC2947 high precision power and energy monitor
10 - Nuno Sá <nuno.sa@analog.com>
13 Analog Devices LTC2947 high precision power and energy monitor over SPI or I2C.
15 https://www.analog.com/media/en/technical-documentation/data-sheets/LTC2947.pdf
27 The LTC2947 uses either a trimmed internal oscillator or an external clock
28 as the time base for determining the integration period to represent time,
29 charge and energy. When an external clock is used, this property must be
33 adi,accumulator-ctl-pol:
35 This property controls the polarity of current that is accumulated to
36 calculate charge and energy so that, they can be only accumulated for
37 positive current for example. Since there are two sets of registers for
38 the accumulated values, this entry can also have two items which sets
39 energy1/charge1 and energy2/charger2 respectively. Check table 12 of the
40 datasheet for more information on the supported options.
42 - $ref: /schemas/types.yaml#/definitions/uint32-array
49 adi,accumulation-deadband-microamp:
51 This property controls the Accumulation Dead band which allows to set the
52 level of current below which no accumulation takes place.
54 - $ref: /schemas/types.yaml#/definitions/uint32
60 This property controls the GPIO polarity. Setting it to one makes the GPIO
61 active high, setting it to zero makets it active low. When this property
62 is present, the GPIO is automatically configured as output and set to
63 control a fan as a function of measured temperature.
65 - $ref: /schemas/types.yaml#/definitions/uint32
71 When set, this property sets the GPIO as input. It is then used to control
72 the accumulation of charge, energy and time. This function can be
73 enabled/configured separately for each of the two sets of accumulation
74 registers. Check table 13 of the datasheet for more information on the
75 supported options. This property cannot be used together with
78 - $ref: /schemas/types.yaml#/definitions/uint32-array
90 additionalProperties: false
98 ltc2947_spi: ltc2947@0 {
99 compatible = "adi,ltc2947";
101 /* accumulation takes place always for energ1/charge1. */
102 /* accumulation only on positive current for energy2/charge2. */
103 adi,accumulator-ctl-pol = <0 1>;