I have two laptops here. One is running Vista, the other Windows 7. I need to get the specifications on the batteries in both, how do I go about that?
The reason I'm asking is that I'd like to know if they're lithium ion or something else. Supposedly other types of batteries may have adversely affected charge capacities if left plugged in for too long.
You could use WMI and the Win32_Battery class. It has a property called Chemistry
that has this information.
UPDATE:
Actually, there is also Win32_PortableBattery, which would be more appropriate for a laptop battery. They both inherit from the CIM_Battery class.
The IOCTL_BATTERY_QUERY_INFORMATION info from DeviceIOControl can tell you the following info:
Information level
The BatteryInformation structure contains the Chemistry field which describes this info you require.
There is an example here: http://msdn.microsoft.com/en-us/library/bb204769(v=VS.85).aspx
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With