Thanks, that sounds reasonable. I also have some cdc type devices that use a
totally different library. Ill check those out. I think adding a wrapper in
my application should take care of it.
Regarding debug, where & how can I configure?
-Walker
-------- Original message --------
From: Wander Lairson Costa
Date:05/05/2014 8:15 AM (GMT-05:00)
To: pyusb-users
Subject: Re: [pyusb-users] read function
2014-05-02 11:40 GMT-03:00 Walker Inman <win...@mit.edu>:
> To further the below, I have now tested both on windows and linux with the
> same result. It always takes until the 4th read call until my response
> appears, even with the delay between reads set to zero. This seems like
> read() is causing some state machine to progress..?? I will probably just
> wrap the read call with a for loop that runs 4x -- but this seems like quite
> a hack.
>
> Is there any documentation on how your logging module is configured? Id like
> to know more about what is happening on my read calls.
>
> Also, is there any way to check if / how much data is waiting on a bulk in
> ep without 'reading' the data?
>
> If the above 4x read calls are progressing a state machine, is there a way
> to directly advance the state machine?
>
> Thanks --- fyi, im quite new to pyusb / lib usb but have written an embedded
> usb cdc host so have some familiarity with usb etc.
>
It feels like a hardware/firmware issues. A long time ago I worked
with a multifunctional printer which used to enqueue empty packets to
the USB controller. So, every command response had to be read twice:
the first one was the empty packet, and then the packets with the real
data.
--
Best Regards,
Wander Lairson Costa
------------------------------------------------------------------------------
Is your legacy SCM system holding you back? Join Perforce May 7 to find out:
• 3 signs your SCM is hindering your productivity
• Requirements for releasing software faster
• Expert tips and advice for migrating your SCM now
http://p.sf.net/sfu/perforce
_______________________________________________
pyusb-users mailing list
pyusb-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/pyusb-users
------------------------------------------------------------------------------
Is your legacy SCM system holding you back? Join Perforce May 7 to find out:
• 3 signs your SCM is hindering your productivity
• Requirements for releasing software faster
• Expert tips and advice for migrating your SCM now
http://p.sf.net/sfu/perforce
_______________________________________________
pyusb-users mailing list
pyusb-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/pyusb-users