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 2 - Slot Manager / Slot Manager Reference
Slot Manager Routines / Getting Information About Expansion Cards and Declaration ROMs


SCardChanged

You can use the SCardChanged function to determine if the card in a particular slot has been changed.

FUNCTION SCardChanged (spBlkPtr: SpBlockPtr): OSErr;
spBlkPtr
A pointer to a Slot Manager parameter block.
-->spSlotSignedByteThe slot number.
<--spResultLongIntA Boolean signifying whether the card was changed.

DESCRIPTION
The SCardChanged function checks if the expansion card in a slot has been changed (that is, if the card's sPRAMInit record has been initialized). You specify the slot in the spSlot field of the Slot Manager parameter block you point to in the spBlkPtr parameter.

The SCardChanged function returns a value of TRUE in the spResult field of the parameter block if the card has been changed.

ASSEMBLY-LANGUAGE INFORMATION
The trap macro and routine selector for the SCardChanged function are
Trap macroSelector
_SlotManager$0022

You must set up register D0 with the routine selector and register A0 with the address of the Slot Manager parameter block. When _SlotManager returns, register D0 contains the result code.
Registers on entry
A0Address of the parameter block
D0$0022
Registers on exit
D0Result code

RESULT CODES
noErr0No error
smEmptySlot-300No card in this slot

Previous Book Contents Book Index Next

© Apple Computer, Inc.
3 JUL 1996