|Online Development Notebook > Index > Programming Overview > DLL Commands > SetReadTimeout|
SetReadTimeout - Set the timeout for the read operation
This is a USBm.dll function that sets the value for the read timeout.
true⁄false USBm_SetReadTimeout( time )
The USBm_SetReadTimeout function syntax has these parts:
|time||A sixteen-bit value of milliseconds.|
Note: USBm_SetReadTimeout always returns TRUE.
VB Declaration (USBmAPI.bas)
|Public Declare Function USBm_SetReadTimeout _|
Lib "USBm.dll" _
(ByVal timeout As Integer) _
This code fragment shows that the read timeout has been set to three seconds.
|int USBm_SetReadTimeout( unsigned int timeout );|
Returns true if successful, false otherwise. This function sets the timeout for all the read commands. The value should be in milliseconds. The default is 1000 msecs = 1 sec.
Hardware: U401 USB Interface U421 USB Interface U451 USB Interface
Programming: USBm DLL Programming Download Files
Application Notes: U4x1 Application Notes Misc Applications and Information FAQ
While every effort has been made to make sure that the information posted on this site is correct, the author can not be held liable for any damages whatsoever for losses as a result of the application of this information. Use this information at your own risk.
USBmicro can design your custom and semi-custom USB product. Email about USB design can be directed to " Robert " at usbmicro.com.
Copyright © USBmicro, L.L.C., 2002-2010