Problems Using 2 USB Cameras

We try to use 2 usb cameras on the robot and show one of them on the dashboard and alternate between them with a driver’s button.

I’ve encountered this post: http://www.chiefdelphi.com/forums/showthread.php?p=1542750

I tried to use the code in it and the result is attached,
the problem is that the second “Camera OPEN” dowsn’t work and outputs an error. If I open USB 0 first I can see it when it’s selected but I see nothing when the other is selected. If I open USB 1 first it’s the same but I can see the other camera.

What may cause it? How can I fix it?
Thank you.





What error? Are both cameras USB?

It may also be useful to do open and run IMAQdx Enumerate Cameras.vi to see what it returns. The WPILib VI makes this call, sorts the USB cameras to keep them in a predictable order, and the digit in the USB # is used to select from that list.

Greg McKaskle