Return laptop battery values
Posted: July 25th, 2020, 11:05 am
Hello. I am interested in returning some battery information values. Specifically I am interested in estimated time to full charge of a laptop battery, but any other data will be much helpful. In Windows 10 the thing I am looking for looks like this:
I have found out about Win32_PortableBattery class, and specifically TimeToFullCharge which I am interested in, but it does not return anything using command line WMIC PATH Win32_PortableBattery Get TimeToFullCharge. I believe my hardware simply does not provide this information. Therefore there is some other way to obtain or calculate this piece.
Somehow one of the nirsoft's utilities provide this information: I am wondering if it obtains some values available and then makes its own estimations based on some calculations. I am trying to find out how it obtains those values and possible formulas.
I think by using mWh values of current capacity, full charged capacity, and charge/discharge rate I can calculate my desired estimation but I can't find out how to retrieve them.
(I know that this nirsoft utility is able to export values through command line but I would like to stay away from calling external application once every minute)
I am wondering how to obtain or calculate this info?I have found out about Win32_PortableBattery class, and specifically TimeToFullCharge which I am interested in, but it does not return anything using command line WMIC PATH Win32_PortableBattery Get TimeToFullCharge. I believe my hardware simply does not provide this information. Therefore there is some other way to obtain or calculate this piece.
Somehow one of the nirsoft's utilities provide this information: I am wondering if it obtains some values available and then makes its own estimations based on some calculations. I am trying to find out how it obtains those values and possible formulas.
I think by using mWh values of current capacity, full charged capacity, and charge/discharge rate I can calculate my desired estimation but I can't find out how to retrieve them.
(I know that this nirsoft utility is able to export values through command line but I would like to stay away from calling external application once every minute)