Jump to content

RxUsbQueryDeviceReport: Difference between revisions

From EDM2
Created page with "==Description== Obtains the Compound Descriptor of a specific USB device. ==Syntax== <pre> rc = RxUsbQueryDeviceReport(Handle,Report) </pre> ==Parameters== ; Handle : the D..."
 
W.m.brul (talk | contribs)
added return codes
Line 10: Line 10:
; Handle : the Device Handle received from the previous RxUsbOpen.  
; Handle : the Device Handle received from the previous RxUsbOpen.  


; Report :  receives the Compound Descriptor as hexadecimal string. The Compound Descriptor is the concatenation of Device Descriptor and Configuration Descriptor. 
; Report :  receives the Compound Descriptor as hexadecimal string.


==Return Code==
==Return Code==
 
<pre>
0x0000 - NO_ERROR
</pre>
===Errors===
===Errors===
 
<pre>
0x0057 - ERROR_INVALID_PARAMETER
0x1B58 - USB_NOT_INIT
0xFF13 - ERROR_I24_INVALID_PARAMETER
0xFF1F - ERROR_GEN_FAILURE
0xFF37 - ERROR_DEV_NOT_EXIST
0xFF57 - ERROR_INVALID_PARAMETER
0xFF6F - ERROR_BUFFER_OVERFLOW
0xFFEA - ERROR_MORE_DATA
</pre>
==Remarks==
==Remarks==
 
The Compound Descriptor is the concatenation of Device Descriptor and Configuration Descriptor. 
==Example Code==
==Example Code==
<pre>
<pre>
/* add RxUsbQueryDeviceReport */
/* add RxUsbQueryDeviceReport */
rc = RxFuncAdd('RxUsbQueryDeviceReport','usbcalls','RxUsbQueryDeviceReport')
rc = RxFuncAdd('RxUsbQueryDeviceReport','usbcalls','RxUsbQueryDeviceReport')
Line 34: Line 43:
rc = RxFuncDrop('RxUsbQueryDeviceReport')
rc = RxFuncDrop('RxUsbQueryDeviceReport')
say '-RxUsbQueryDeviceReport(),RC=0x'd2x(rc)
say '-RxUsbQueryDeviceReport(),RC=0x'd2x(rc)
 
</pre>
</pre>



Revision as of 13:26, 23 January 2017

Description

Obtains the Compound Descriptor of a specific USB device.

Syntax

rc = RxUsbQueryDeviceReport(Handle,Report)

Parameters

Handle
the Device Handle received from the previous RxUsbOpen.
Report
receives the Compound Descriptor as hexadecimal string.

Return Code

0x0000 - NO_ERROR

Errors

0x0057 - ERROR_INVALID_PARAMETER
0x1B58 - USB_NOT_INIT
0xFF13 - ERROR_I24_INVALID_PARAMETER
0xFF1F - ERROR_GEN_FAILURE
0xFF37 - ERROR_DEV_NOT_EXIST
0xFF57 - ERROR_INVALID_PARAMETER
0xFF6F - ERROR_BUFFER_OVERFLOW
0xFFEA - ERROR_MORE_DATA

Remarks

The Compound Descriptor is the concatenation of Device Descriptor and Configuration Descriptor.

Example Code

/* add RxUsbQueryDeviceReport */
rc = RxFuncAdd('RxUsbQueryDeviceReport','usbcalls','RxUsbQueryDeviceReport')
say '+RxUsbQueryDeviceReport(),RC=0x'd2x(rc)

/* invoke RxUsbQueryDeviceReport */
drop Report /* receives device report */
rc = RxUsbQueryDeviceReport(Handle,Report)
say '*RxUsbQueryDeviceReport(),RC=0x'd2x(rc)

/* drop RxUsbQueryDeviceReport */
rc = RxFuncDrop('RxUsbQueryDeviceReport')
say '-RxUsbQueryDeviceReport(),RC=0x'd2x(rc)

Related Functions