@@ -67,13 +67,13 @@ private Battery() {
6767currentRereader =new DataChannelRereader (batteryPath +"/" +batteryEv3 +"/" +current );
6868 }
6969
70- public int getVoltageMicroVolts () {
70+ public int getVoltageMicroVolt () {
7171return Integer .parseInt (voltageRereader .readString ());
7272 }
7373
7474@ Override
7575public int getVoltageMilliVolt () {
76- return getVoltageMicroVolts () /1000 ;
76+ return getVoltageMicroVolt () /1000 ;
7777 }
7878
7979/**
@@ -82,23 +82,21 @@ public int getVoltageMilliVolt() {
8282 * @return voltage
8383 */
8484public float getVoltage () {
85- return getVoltageMicroVolts () /1000000f ;
85+ return getVoltageMicroVolt () /1000000f ;
8686 }
8787
8888//TODO Review output
8989//TODO Review units
9090
9191/**
92- * Returns the current of the battery in amps.
93- *
94- * @return current
92+ * @return current from the battery in amps, or Float.NaN if run on something other than EV3BRICK
9593 */
9694public float getBatteryCurrent () {
9795if (CURRENT_PLATFORM .equals (EV3DevPlatform .EV3BRICK )) {
9896return Float .parseFloat (currentRereader .readString ());
9997 }else {
10098LOGGER .warn ("This method is not available for {} & {}" ,EV3DevPlatform .PISTORMS ,EV3DevPlatform .BRICKPI );
101- return - 1f ;
99+ return Float . NaN ;
102100 }
103101 }
104102