summaryrefslogtreecommitdiffstats
path: root/dts/Bindings/power/supply/lltc,ltc294x.yaml
diff options
context:
space:
mode:
authorSascha Hauer <s.hauer@pengutronix.de>2021-05-17 13:27:45 +0200
committerSascha Hauer <s.hauer@pengutronix.de>2021-05-17 16:23:06 +0200
commita5a4c1d5a3c4f89059fb612b5786ec8b61b959f1 (patch)
treefe87198c6cc02e54d3131d087d2b9f7c3e96c689 /dts/Bindings/power/supply/lltc,ltc294x.yaml
parentba9de18c5f211678f5d0f67a0758c632ab774cca (diff)
downloadbarebox-a5a4c1d5a3c4f89059fb612b5786ec8b61b959f1.tar.gz
barebox-a5a4c1d5a3c4f89059fb612b5786ec8b61b959f1.tar.xz
dts: update to v5.13-rc1
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'dts/Bindings/power/supply/lltc,ltc294x.yaml')
-rw-r--r--dts/Bindings/power/supply/lltc,ltc294x.yaml66
1 files changed, 66 insertions, 0 deletions
diff --git a/dts/Bindings/power/supply/lltc,ltc294x.yaml b/dts/Bindings/power/supply/lltc,ltc294x.yaml
new file mode 100644
index 0000000000..043bf37804
--- /dev/null
+++ b/dts/Bindings/power/supply/lltc,ltc294x.yaml
@@ -0,0 +1,66 @@
+# SPDX-License-Identifier: GPL-2.0
+%YAML 1.2
+---
+$id: "http://devicetree.org/schemas/power/supply/lltc,ltc294x.yaml#"
+$schema: "http://devicetree.org/meta-schemas/core.yaml#"
+
+title: Binding for LTC2941, LTC2942, LTC2943 and LTC2944 battery fuel gauges
+
+description: |
+ All chips measure battery capacity.
+ The LTC2942 is pin compatible with the LTC2941, it adds voltage and
+ temperature monitoring, and is runtime detected. LTC2943 and LTC2944
+ are software compatible, uses a slightly different conversion formula
+ for the charge counter and adds voltage, current and temperature monitoring.
+
+maintainers:
+ - Sebastian Reichel <sre@kernel.org>
+
+allOf:
+ - $ref: power-supply.yaml#
+
+properties:
+ compatible:
+ enum:
+ - lltc,ltc2941
+ - lltc,ltc2942
+ - lltc,ltc2943
+ - lltc,ltc2944
+
+ reg:
+ maxItems: 1
+
+ lltc,resistor-sense:
+ $ref: /schemas/types.yaml#/definitions/int32
+ description: |
+ Sense resistor value in milli-ohms.
+ Can be negative value when the battery has been connected to the wrong end of the resistor.
+
+ lltc,prescaler-exponent:
+ $ref: /schemas/types.yaml#/definitions/uint32
+ description: |
+ The prescaler exponent as explained in the datasheet.
+ This determines the range and accuracy of the gauge.
+ The value is programmed into the chip only if it differs from the current setting.
+ The setting is lost when the battery is disconnected.
+
+required:
+ - compatible
+ - reg
+ - lltc,resistor-sense
+ - lltc,prescaler-exponent
+
+additionalProperties: false
+
+examples:
+ - |
+ i2c0 {
+ #address-cells = <1>;
+ #size-cells = <0>;
+ battery@64 {
+ compatible = "lltc,ltc2943";
+ reg = <0x64>;
+ lltc,resistor-sense = <15>;
+ lltc,prescaler-exponent = <5>; /* 2^(2*5) = 1024 */
+ };
+ };