1 LEGO MINDSTORMS EV3 Battery
2 ~~~~~~~~~~~~~~~~~~~~~~~~~~~
4 LEGO MINDSTORMS EV3 has some built-in capability for monitoring the battery.
5 It uses 6 AA batteries or a special Li-ion rechargeable battery pack that is
6 detected by a key switch in the battery compartment.
9 - compatible: Must be "lego,ev3-battery"
10 - io-channels: phandles to analog inputs for reading voltage and current
11 - io-channel-names: Must be "voltage", "current"
12 - rechargeable-gpios: phandle to the rechargeable battery indication gpio
17 compatible = "lego,ev3-battery";
18 io-channels = <&adc 4>, <&adc 3>;
19 io-channel-names = "voltage", "current";
20 rechargeable-gpios = <&gpio 136 GPIO_ACTIVE_LOW>;