APM Device ID
Several APM API functions require a device ID in BX. This is a 16-bit
value in the form:
1 1 1 1 1 1
║ device class ║ device unit ║
║ ╚═══════► 0-7: device unit; ffH=ALL (see below)
╚═══════════════════════► 8-15: device class
00H = system
01H = display
02H = secondary storage
03H = parallel ports
04H = serial ports
bits 8-15 (high byte) identify the device type. The value 00xxH has
the special meaning "the system as a whole".
bits 0-7 (low byte) identify the unit number of the (possibly several)
units attached of the device type in the high byte.
This value is 0-based. For instance, an ID of 0301H is the
second parallel printer.
A value of ffH indicates all devices of that type.
Notes: ID 0000H identifies the system BIOS.
ID 0001H identifies all devices power-managed by the system BIOS.
See Also: APM API