Hi Dan,
Thank you for your reply. Finally I've been able to communicate with my USB device, but I still have some troubles with it.
The device at issue has the following structure:
- 1 Bulk-out pipe (no problem with viWrite)
- 1 Interrupt-in pipe that sends data every 0.3 sec aprox
- 1 Interrupt-in pipe that only sends data when the device gets a signal from an infrared receiver
I need to read the two interrupts simultaneously, and at the same time I need the first to be as fast and accurate as possible. I think the best option would be to use callbacks for both interrupts, so that it would only read when data existed. but I have a pair of impediments on the matter:
- When I try to use viInstallHandler it returns me a general protection run-time
error: Unknown source position, thread id 0x00....
- I cannot set default interrupt-in pipe when USB Interrupt Event is already enabled, so it's impossible to read the two pipes at the same time althought I open a different visa session for each one. In this case if I change it before enabling events the setting is applied to both sessions.
Seen the sight I suppose there isn't another way that to convert one of interrupt pipes into bulk.
According to the properties of each one, which do you think that it would be the most optimal change?
On the other hand I'd like to solve the problem with event handlers. Do you know how?
Thanks a lot for your interest.