Jump to content

UsbIsoOpen: Difference between revisions

From EDM2
W.m.brul (talk | contribs)
updated whole page
W.m.brul (talk | contribs)
 
Line 49: Line 49:
</pre>
</pre>
==Related Functions==
==Related Functions==
* [[UsbStartIsoTransfer]]
* [[UsbIsoClose]]
* [[UsbOpen]]


[[Category:USBCalls]]
[[Category:USBCalls]]

Latest revision as of 17:40, 12 February 2017

Description

Allocates bandwidth and resources for Isochronous Transfer.

Syntax

ulrc = UsbIsoOpen(Handle,ucEndpoint,ucAltSetting,usBufferCount,usFrameLength)

Parameters

Handle
the Device Handle received from the previous UsbOpen.
ucEndpoint
the Endpoint Number appropriate for the data transfer.
ucAltSetting
the Alternate Setting of the interface having this endpoint.
usBufferCount
the number of isochronous data buffers. Must not exceed 8.
usFrameLength
the maximum number of bytes in an isochronous frame.

Return Code

0x0000 - NO_ERROR

Errors

0x0037 - ERROR_DEV_NOT_EXIST
0x0057 - ERROR_INVALID_PARAMETER
0x1B58 - USB_NOT_INIT
0xFF13 - USB_IDC_PARMERR
0xFF14 - USB_IDC_ALLOCERR
0xFF15 - USB_IDC_NOBANDWIDTH
0xFF18 - USB_IDC_ADDRINV

Remarks

Example Code

//Code Snippet - UsbIsoOpen
{
  APIRET ulrc;
  UCHAR ucAltSetting = 1;
  UCHAR ucEndpoint = 0x86;
  USHORT usBufferCount = 3;
  USHORT usFrameLength = 0x44;

  ulrc = UsbIsoOpen(Handle,ucEndpoint,ucAltSetting,usBufferCount,usFrameLength);
  printf("\nUsbIsoOpen - ulrc: 0x%04X (%hu)",ulrc,ulrc);
}

Related Functions