[Contents] [Index] [Help] [Retrace] [Browse <] [Browse >]

Command          Operation
-------          ---------
CMD_FLUSH        Purge all queued requests for the parallel device.  Does
                 not affect active requests.

CMD_READ         Read a stream of characters from the parallel port.  The
                 number of characters can be specified or a termination
                 character(s) can be used.

CMD_RESET        Reset the parallel port to its initialized state.  All
                 active and queued I/O requests will be aborted.

CMD_START        Restart all paused I/O over the parallel port.
                 Reactivates the handshaking sequence.

CMD_STOP         Pause all active I/O over the parallel port.  Deactivates
                 the handshaking sequence.

CMD_WRITE        Write out a stream of characters to the parallel port.
                 The number of characters can be specified or a
                 NULL-terminated string can be sent.

PDCMD_QUERY      Return the status of the parallel port lines and
                 registers.

PDCMD_SETPARAMS  Set the parameters of the parallel port.


Exec Functions as Used in This Chapter
--------------------------------------
AbortIO()        Abort a command to the parallel device. If the command is
                 in progress, it is stopped immediately.  If it is queued,
                 it is removed from the queue.

BeginIO()        Initiate a command and return immediately (asynchronous
                 request).  This is used to minimize the amount of system
                 overhead.

CheckIO()        Determine the current state of an I/O request.

CloseDevice()    Relinquish use of the parallel device.  All requests must
                 be complete.

DoIO()           Initiate a command and wait for completion (synchronous
                 request).

OpenDevice()     Obtain use of the parallel device.

SendIO()         Initiate a command and return immediately (asynchronous
                 request).

WaitIO()         Wait for the completion of an asynchronous request.  When
                 the request is complete the message will be removed from
                 your reply port.


Exec Support Functions as Used in This Chapter
----------------------------------------------
CreateExtIO()    Create an extended I/O request structure of type
                 IOExtPar.  This structure will be used to communicate
                 commands to the parallel device.

CreatePort()     Create a signal message port for reply messages from the
                 parallel device.  Exec will signal a task when a message
                 arrives at the port.

DeleteExtIO()    Delete an extended I/O request structure created by
                 CreateExtIO().

DeletePort()     Delete the message port created by CreatePort().