USB_EndpointInformation (SWI&55396) — Returns information about a given endpoint.
R0 | Pointer to an array of 4 Byte Words. |
R1 | 0 |
R2 | Maximal number of elements inside the array. |
R3 | Pointer to endpoint structure. |
R4 | Reserved. Must be set to zero. |
R5 | Reserved. Must be set to zero. |
R0 | preserved |
R1 | Error code Table A.1, “Error codes used by the USB system” |
R2 | Number of elements inside the array which really have been filled. |
R3, R4, R5 | preserved |
The reference to the endpoint structure is kept in every case.
This SWI is used to obtain various information about a given endpoint. Normally a direct USB Descriptor request would be the better choice but such a request consists of several steps and so this SWI may be the faster choice. You can also use this call to see whether a pipe is used. But note that this command does not implement a Test-And-Set-operation so the results of this call may be invalid a moment later in a parallel environment.
Array element | Description |
---|---|
0 | Pointer to controller structure. Don't use for reference purposes but for comparison at Service call or USB_FindObject. |
1 | Pointer to device structure. Don't use for reference purposes but for comparison at Service call or USB_FindObject. |
2 | Device number of the device the endpoint belongs to. |
3 | Device speed Table A.6, “Constants used for device speed” |
4 | Endpoint number Table 1.5, “Bits of endpoint address” |
5 | Transfer type Table A.5, “Constants used for type of USB transfer” |
6 | Data payload size. May vary from the size inside endpoint descriptor. |
7 | Number of frames that must pass until the next requests can be sent/received |
8 | Number of pipes open at this endpoint. Bit 31 is set if pipes are in shared mode, else pipe isn't shared. |