02-25-2014 09:10 AM
I, me again.
I would like to know if there is a way to know if an IMAQdx session is already open or not. I made a subVI that manages the imaging part of a more complex software. My problem is simple: I need to open and close the IMAQdx session. If I do this every time my VI is called i get a delay of a few seconds and I do not really like this. So I thought that I could open the session the first time that my VI is called, use it with the session already open the other times, and close it when the main program requires it, perhaps through a boolean flag.
Thank you,
Francesco.
Solved! Go to Solution.
02-25-2014 05:30 PM
We have an application where we take intermittent videos (3-7 seconds at a time) several times per hour (triggered by an external event) for over two hours. We open the IMAQdx session when the program starts, pass the Refnum around, and close it when the program exits. Note that the camera is running all this time -- we just aren't saving the images except when we want to. Makes the code much simpler.
BS
02-26-2014 02:05 AM - edited 02-26-2014 02:29 AM
Yes, i agree with you that the code is much more simpler and cleaner like you suggest. Unfortunately i do not decide the architecture of the application and i need to follow the specification.
Thank you anyway!
02-26-2014 03:29 AM
I found a solution. I used the "Not A Number/Path/Refnum?" function on the "Comparison" palette. If the session is not open yet the function return "true" else it return "false". Much simpler than what i thought!