Important: The information in this document is obsolete and should not be used for new development.
DTInstall
After defining the fields of a deferred task record, you can call theDTInstallfunction to install the record into the deferred task queue.
FUNCTION DTInstall (dtTaskPtr: QElemPtr): OSErr;
dtTaskPtr- A pointer to a queue element to add to the deferred task queue.
DESCRIPTION
TheDTInstallfunction adds the specified task record to the deferred task queue. Your application should fill in all fields of the task record exceptqLinkandqFlags.Ordinarily, you call
DTInstallonly at interrupt time. TheDTInstallfunction does not actually execute the routine specified in thedtAddrfield of the task record. Each system interrupt handler executes routines stored in the deferred task queue after reenabling interrupts. After a routine in the queue is executed, it is removed from the deferred task queue.If the
qTypefield of the task record is not set toORD(dtQType),DTInstallreturnsvTypErrand does not add the record to the queue. Otherwise,DTInstallreturnsnoErr.ASSEMBLY-LANGUAGE INFORMATION
The registers on entry and exit forDTInstallare
Registers on entry A0 Pointer to new queue entry
Registers on exit D0 Result code To reduce overhead at interrupt time, instead of executing the
DTInstalltrap, you can load the jump vectorjDTInstallinto an address register other than A0 and execute aJSRinstruction using that register.RESULT CODES
noErr 0 No error vTypErr -2 Invalid qTypevalue (must beORD(dtQType))