Re: LibusbK API clarification for UsbK_ReadPipe
Travis <[email protected]>
| Newsgroups | gmane.comp.lib.libusb.devel.windows |
|---|---|
| Message-ID | <[email protected]> |
Greetings, They are synchronous when not used with an overlapped handle. Yes, if you set a timeout policy for your pipe then these functions will return if nothing is received within that time. If memory serves, it is an ERROR_SEM_TIMEOUT but I like to define a macro that checks for a set of codes: #define IsUsbTimeout(errorCode) (errorCode == ERROR_OPERATION_ABORTED || errorCode == ERROR_CANCELLED || errorCode == ERROR_SEM_TIMEOUT) Regards, Travis On 9/24/2014 3:59 AM, Pradeepa Senanayake wrote: > Hello, > > Can someone clarify this for me? > > Best Regards, > Pradeepa Senanayake. > > On Tue, Sep 23, 2014 at 5:56 PM, Pradeepa Senanayake > <[email protected] <mailto:[email protected]>> wrote: > > Hello, > > I have a quick question. > > Are UsbK_ReadPipe and UsbK_WritePipe functions synchronous? > > If I set a timeout using the SetPipePolicy function will these > functions wait that time until the timeout or data transfer complete? > > During the timeout what is the return value coming from > GetLastError() ? > > Best Regards, > Pradeepa Senanayake. > > > > > ------------------------------------------------------------------------------ > Meet PCI DSS 3.0 Compliance Requirements with EventLog Analyzer > Achieve PCI DSS 3.0 Compliant Status with Out-of-the-box PCI DSS Reports > Are you Audit-Ready for PCI DSS 3.0 Compliance? Download White paper > Comply to PCI DSS 3.0 Requirement 10 and 11.5 with EventLog Analyzer > http://pubads.g.doubleclick.net/gampad/clk?id=154622311&iu=/4140/ostg.clktrk > > > _______________________________________________ > Libusb-win32-devel mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/libusb-win32-devel ------------------------------------------------------------------------------ Meet PCI DSS 3.0 Compliance Requirements with EventLog Analyzer Achieve PCI DSS 3.0 Compliant Status with Out-of-the-box PCI DSS Reports Are you Audit-Ready for PCI DSS 3.0 Compliance? Download White paper Comply to PCI DSS 3.0 Requirement 10 and 11.5 with EventLog Analyzer http://pubads.g.doubleclick.net/gampad/clk?id=154622311&iu=/4140/ostg.clktrk