Machine Vision

cancel
Showing results for 
Search instead for 
Did you mean: 

ImaqDX Camera does not work in Built Application

I'm having an issue when I build my VI into an application. The camera works fine when I run the VI, and it also works find after I build the application, however it only works the first time you open the application. You can start and stop the VI and it works fine. If you close the application, and reopen it then the camera stops working with the following error code: -1074360316

 

Any ideas on how to trouble shoot this? Currently I can work around the problem by re-building the application everytime I close it out, but it would be nice to understand what is happening.

 

My actual VI is pretty complex, but I've made a stripped down version with only the camera functions and it has the exact same problem:

 

Andy___W_0-1621348385087.png

 

0 Kudos
Message 1 of 3
(1,342 Views)

The error is an invalid camera session.  In your code, you don't close the active session, which could be an issue.  When you exit the while loop, you should close the session.  That might clear everything so you can start a session on your next run.

 

It is always a good idea to clean everything up when you are done.

 

Bruce

Bruce Ammons
Ammons Engineering
Message 2 of 3
(1,319 Views)

Hi Bruce,

 

Thanks for the suggestion I added in the close camera at the end. The error still occurs, and it happens at the configure grab VI. Also when you stop the VI there are no errors so it looks like its closing the camera fine.

 

Andy___W_0-1621355286668.png

 

0 Kudos
Message 3 of 3
(1,312 Views)