USB_PipeClear (SWI&5538D)

USB_PipeClear (SWI&5538D) — Aborts all requests for the specified pipe.

On Entry

R0Pointer to pipe structure.
R1

ValueDefinitionDescription
0USB_PIPE_CLEAR_NOCHANGEPipe state will be unaltered after clearing.
1USB_PIPE_CLEAR_ACTIVATEPipe will be set to active after clearing.

R2Reserved. Must be set to zero.

On Exit

R0preserved
R1Error code Table A.1, “Error codes used by the USB system”
R2Preserved

Use

This call will abort all transactions on the specified pipe. The state of any active transactions is indeterminate and should not be relied upon to have completed successfully. Transactions are terminated correctly with their waiting structures notified with the appropriate result.

Only a pipe in the opened or halted state may be cleared. If the pipe is in the halted state it may be changed to the active state by setting the appropriate flag in R1.

Related SWI's

USB_PipeOpen (SWI&5538B)
USB_PipeClose (SWI&5538C)
USB_PipeHalt (SWI&5538E)