Legacy Documentclose button

Important: The information in this document is obsolete and should not be used for new development.

Previous Book Contents Book Index Next

Inside Macintosh: Devices /
Chapter 6 - Power Manager / Power Manager Reference
Power Manager Dispatch Routines / Getting Information About the Internal Batteries


BatteryCount

You can use the BatteryCount function to find out how many batteries the computer supports.

short BatteryCount();
DESCRIPTION
The BatteryCount function returns the number of batteries that are supported internally by the computer. The value of BatteryCount returned may not be the same as the number of batteries currently installed.

ASSEMBLY-LANGUAGE INFORMATION
The trap is _PowerMgrDispatch ($A09E). The selector value for BatteryCount is 26 ($1A) in the low word of register D0. The number of batteries supported is returned in the low word of register D0.


Previous Book Contents Book Index Next

© Apple Computer, Inc.
3 JUL 1996