41
The status of both battery pack and memory backup battery can be monitored with
Microsoft’s GetSystemStatusEx2() API function in your application to retrieve the status
values described in the table.
Member Description Returned Value
ACLineStatus Retrieves the status
of AC power.
AC_LINE_OFFLINE : AC power is off.
AC_LINE_ONLINE : AC power is on.
BatteryFlag Retrieves the status
of battery pack.
BATTERY_FLAG_HIGH : OK
BATTERY_FLAG_LOW : Low
BATTERY_FLAG_CRITICAL : Almost
exhausted.
BATTERY_FLAG_CHARGING :
Under charging
BatteryLifePercent Retrieves the
remaining capacity of
battery pack every
10% level.
In the range of 10 to 100%
BackupBatteryFlag Retrieves the status
of memory backup
battery.
BATTERY_FLAG_HIGH : OK
BATTERY_FLAG_LOW : Almost
exhausted
BatteryChemistry Retrieves the type of
the operating battery,
either battery pack or
dry-cell battery.
BATTERY_CHEMISTRY_LION :
Battery pack
BATTERY_CHEMISTRY_ALKALINE :
Dry-cell battery