18c2ecf20Sopenharmony_ciTexas Instruments INA3221 Device Tree Bindings
28c2ecf20Sopenharmony_ci
38c2ecf20Sopenharmony_ci1) ina3221 node
48c2ecf20Sopenharmony_ci  Required properties:
58c2ecf20Sopenharmony_ci  - compatible: Must be "ti,ina3221"
68c2ecf20Sopenharmony_ci  - reg: I2C address
78c2ecf20Sopenharmony_ci
88c2ecf20Sopenharmony_ci  Optional properties:
98c2ecf20Sopenharmony_ci  - ti,single-shot: This chip has two power modes: single-shot (chip takes one
108c2ecf20Sopenharmony_ci                    measurement and then shuts itself down) and continuous (
118c2ecf20Sopenharmony_ci                    chip takes continuous measurements). The continuous mode is
128c2ecf20Sopenharmony_ci                    more reliable and suitable for hardware monitor type device,
138c2ecf20Sopenharmony_ci                    but the single-shot mode is more power-friendly and useful
148c2ecf20Sopenharmony_ci                    for battery-powered device which cares power consumptions
158c2ecf20Sopenharmony_ci                    while still needs some measurements occasionally.
168c2ecf20Sopenharmony_ci                    If this property is present, the single-shot mode will be
178c2ecf20Sopenharmony_ci                    used, instead of the default continuous one for monitoring.
188c2ecf20Sopenharmony_ci
198c2ecf20Sopenharmony_ci  = The node contains optional child nodes for three channels =
208c2ecf20Sopenharmony_ci  = Each child node describes the information of input source =
218c2ecf20Sopenharmony_ci
228c2ecf20Sopenharmony_ci  - #address-cells: Required only if a child node is present. Must be 1.
238c2ecf20Sopenharmony_ci  - #size-cells: Required only if a child node is present. Must be 0.
248c2ecf20Sopenharmony_ci
258c2ecf20Sopenharmony_ci2) child nodes
268c2ecf20Sopenharmony_ci  Required properties:
278c2ecf20Sopenharmony_ci  - reg: Must be 0, 1 or 2, corresponding to IN1, IN2 or IN3 port of INA3221
288c2ecf20Sopenharmony_ci
298c2ecf20Sopenharmony_ci  Optional properties:
308c2ecf20Sopenharmony_ci  - label: Name of the input source
318c2ecf20Sopenharmony_ci  - shunt-resistor-micro-ohms: Shunt resistor value in micro-Ohm
328c2ecf20Sopenharmony_ci
338c2ecf20Sopenharmony_ciExample:
348c2ecf20Sopenharmony_ci
358c2ecf20Sopenharmony_ciina3221@40 {
368c2ecf20Sopenharmony_ci	compatible = "ti,ina3221";
378c2ecf20Sopenharmony_ci	reg = <0x40>;
388c2ecf20Sopenharmony_ci	#address-cells = <1>;
398c2ecf20Sopenharmony_ci	#size-cells = <0>;
408c2ecf20Sopenharmony_ci
418c2ecf20Sopenharmony_ci	input@0 {
428c2ecf20Sopenharmony_ci		reg = <0x0>;
438c2ecf20Sopenharmony_ci		status = "disabled";
448c2ecf20Sopenharmony_ci	};
458c2ecf20Sopenharmony_ci	input@1 {
468c2ecf20Sopenharmony_ci		reg = <0x1>;
478c2ecf20Sopenharmony_ci		shunt-resistor-micro-ohms = <5000>;
488c2ecf20Sopenharmony_ci	};
498c2ecf20Sopenharmony_ci	input@2 {
508c2ecf20Sopenharmony_ci		reg = <0x2>;
518c2ecf20Sopenharmony_ci		label = "VDD_5V";
528c2ecf20Sopenharmony_ci		shunt-resistor-micro-ohms = <5000>;
538c2ecf20Sopenharmony_ci	};
548c2ecf20Sopenharmony_ci};
55