Machine Vision

cancel
Showing results for 
Search instead for 
Did you mean: 

Creative USB camera not found

Solved!
Go to solution

I have a Creative VF-0040 USB webcam that I'm trying to interface with in LabVIEW 2010.  I am getting a "camera not found" error, even though I have connected to it in MAX.  Here's what I've tried in troubleshooting (some from other threads on the NI boards):

 

~ Connect in MAX - I verified that the webcam works, that I have the correct name, and that LabVIEW has the capability of connecting to the camera.

~ Make sure I'm using IMAQdx rather than IMAQ.

~ Try IMAQ just in case I was being stupid.

~ Try updating the drivers - I didn't find any updates (not entirely sure I looked where/how I was supposed to), but this shouldn't be an issue anyway, because MAX can connect to the Creative camera.

~ Use different USB camera (some HP webcam).  This works, so I think it may be something specific to the Creative camera.  Interestingly enough, when I try to connect to the Creative when both the HP and the Creative are attached to the computer, labview connects to the HP and alters the interface name of the Creative.  Here's an example, in case that was unclear:

   HP webcam had the interface name "cam0" and the Creative one had interface name "cam1."  I started the attached program, (index value 1), and the program connected to the HP.  The indicator on the right showed that the HP (USB Video Device) was the zeroth element of the array and the Creative was the first.  After the program started, the creative had the interface name "cam2," while the HP still had the interface name "cam0."  Running it a second time incremented the Creative to "cam3."  Running it a third time did not change the Creative's interface name from "cam3", but still connected to the HP, using the interface name "cam3."  In case this was still unclear, the defaults on the uploaded program show exactly the exit state of the program after this last run. 

  MAX now does not allow me to rename the Creative to "cam1" or "cam2," giving the error: Unable to rename interface. Invalid or duplicate name specified.  However, only cam0 and cam3 show up under NI-IMAQdx Devices in MAX.

After recognizing this, I re-checked in MAX to make sure MAX connected to the Creative even when both the Creative and the HP were connected.  It did connect to whichever I specified.

0 Kudos
Message 1 of 4
(4,127 Views)

My apologies.  I realized I had not saved the values in the array on the right.  This is the same VI with the right values stored as default.

0 Kudos
Message 2 of 4
(4,123 Views)
Solution
Accepted by topic author yavinbase

I'm not sure what would cause the device names to increment between runs. Is it possible you disconnected the camera and maybe plugged it into a different USB port? IMAQdx computes a unique "serial number" for DirectShow devices using plug&play info assigned by Windows, which might change if the device is removed. If that occurs, IMAQdx would treat it as a new device.

 

I think the other problem is in your code. You never call "IMAQdx Open" on the camera and so your reference is invalid. If you open the code for the high-level "Configure Grab" VI, you'll see that it just opens "cam0" when the session passed into it is invalid (yes, this is kind of weird behavior that it doesn't try to open the name on the reference wire).

 

Eric

0 Kudos
Message 3 of 4
(4,118 Views)

Thank you very much!  I'm using the evaluation version atm (the lab has the full version, but I haven't activated my copy yet). As such, I couldn't open "Configure Grab."  I should've changed the HP to something other than "cam0" to see if it still had the same behavior.

 

Both problems (I think) went away when I added "IMAQdx Open" before "Configure Grab." 

0 Kudos
Message 4 of 4
(4,111 Views)