Important: The information in this document is obsolete and should not be used for new development.
dspAttention
ThedspAttentionroutine sends an attention code and an attention message to the remote connection end. You use thePBControlfunction to call thedspAttentionroutine. See "Routines" on page 5-43 for a description of thePBControlfunction.
--> ioCompletion ProcPtr A pointer to a completion routine. <-- ioResult OSErr The function result. --> ioCRefNum Integer The driver reference number. --> csCode Integer Always dspAttentionfor this function.--> ccbRefNum Integer The CCB reference number. --> attnCode Integer The client attention code. --> attnSize Integer The size of attention data in bytes. --> attnData Ptr A pointer to attention data.
Field Description
csCode- The routine selector, always
dspAttentionfor this routine.ccbRefNum- The connection control block (CCB) reference number that the
dspInitroutine returned.attnCode- The 2-byte attention code that you wish to send to the remote connection end. You can use any value from $0000 through $EFFF for the attention code. The values $F000 through $FFFF are reserved for use by ADSP.
attnSize- The size in bytes of the attention message you wish to send.
attnData- A pointer to the attention message. The attention message can be any size from 0 through 570 bytes. There are no restrictions on the content of the attention message.
DESCRIPTION
ThedspAttentionroutine sends an attention code and message. Attention codes and attention messages can have any meaning that your application and the application at the remote connection end both recognize. The purpose of attention codes and messages is to allow clients of ADSP to send messages outside the normal data stream.For example, if a connection end on a mainframe computer is connected to several connection ends in Macintosh computers being used as remote terminals, the mainframe computer might wish to inform the remote terminals that all connections will be terminated in ten minutes. The mainframe application could send an attention message to each of the remote terminals informing them of this fact, and the terminal emulation programs in the Macintosh computers could then display an alert message on the screen so that the users could prepare to shut down.
ASSEMBLY-LANGUAGE INFORMATION
To execute thedspAttentionroutine from assembly language, call the_Controltrap macro with a value ofdspAttentionin thecsCodefield of the parameter block.RESULT CODES
noErr 0 No error errAttention -1276 Attention message too long errState -1278 Connection is not open errAborted -1279 Request aborted by dspRemoveordspCloseroutineerrRefNum -1280 Bad connection reference number