Machine Vision

cancel
Showing results for 
Search instead for 
Did you mean: 

snap for IMAQdx Visual Studio 2008

Solved!
Go to solution

I am trying to use the Snap example project which is in Visual Studio 2008, C#.  This is the sample project that came with the NI software install.  When I try to capture an image from the camera, I get a "The passed in interface or session is invalid" error message.  I double-checked my interface name in the NI software and it is correct.  I have a Basler A601f camera connected over firewire. 

 

Any help would be great.  Thanks.

0 Kudos
Message 1 of 5
(5,297 Views)

I have two things for you to check:

1. Can you please confirm that you are using an IMAQdx example and not an IMAQ example? Different interfaces.

2. Make sure you have closed MAX or any other software that is interacting with the camera except your current application.

 

Those are two things I can think of.

Adnan Zafar
Certified LabVIEW Architect
Coleman Technologies
0 Kudos
Message 2 of 5
(5,295 Views)

I think I'm using the IMAQ example since it is in C:\Users\Public\Documents\National Instruments\NI-IMAQ\Examples.  There is an NI-IMAQdx folder but, it only has sample projects that are old .Net projects like C++.  Is there anything more recent? 

 

I tried the VB.Net Snap project in the NI-IMAQdx\examples folder but, when I ran it, I get a COM error.

0 Kudos
Message 3 of 5
(5,293 Views)
Solution
Accepted by topic author bobbyg1

Ah that explains it; you need to use IMAQdx to work with Firewire.

 

I mostly use LabVIEW to program with IMAQdx, so I am not sure what sort of examples are available. I would recommend that you install the latest version of Vision Acquisition Software to get the latest shipped examples. You can search for errors on the forums or on ni.com.

Adnan Zafar
Certified LabVIEW Architect
Coleman Technologies
0 Kudos
Message 4 of 5
(5,291 Views)

Yep, that got me going.  I installed the latest version of the Vision Acquisition software and the example code was updated.

 

Thanks!

0 Kudos
Message 5 of 5
(5,277 Views)