07-08-2010 04:54 AM
Hello
I am using the Vision Acquisition Express VI in a while-loop. The vi itself is started with an event. Now if I am starting for the first time the Vision Acquisition Express VI I can see the live-image.
After stoping the while-loop and restart the event (Vision Acquisition Express VI) again, I always get the error message "NI-IMAQdx: (Hex 0xBFF69004) Invalid camera session".
Do I need to close the session prior or what I am doing wrong?
thanks in advance
Solved! Go to Solution.
07-08-2010 05:52 AM
I am with lv 8.0 here so not able to view your vi in 9.0. But have you used the initialize outside the loop and close outside the loop and only the aquire inside the loop. I suppose if you do it this way you should not get the error.
07-08-2010 06:22 AM
No, the initialisation is inside the loop because I want to acquire cont. image with inline processing. I think therefore I need to use the "NI Vision Acquisition Express.vi" inside the
Loop.
Please have a look at the attached vi (Version 8.0).
Thanks
07-08-2010 07:00 AM
Why are you using a event structure here? While loop isnt connected to a control and how are you stopping the vi? Abruptly?
07-08-2010 07:16 AM
This is only an example how I have implemented the vi in my SW. The problem is that I can not send you the complete structure.
1) An event "Track" starts the camera session and remains in the loop until
2) the user press "Stop" => the camera session stops the loop and
3) goes back to "timeout" and waits for next event (Track) to start the camera session again
4) at this point I get the mentioned error message
Any ideas what could be wrong?
Thanks
07-09-2010 12:23 AM
has nobody any hint...?
07-12-2010 02:23 AM
Hey There,
why dont you try to use the low-level-VIs and what muks wrote - put the initialization and closing the Imaq session outside the while-loop.
Its always better to use the low-level-vis, so i would suggest to try that!
07-12-2010 04:56 AM
ok but with the used express vi where I contin. acquire images I need automatically a while loop - isnt it?
07-12-2010 05:00 AM
You will still need a while-loop, also with low-level VIs:
The initialisation and closing the references is outside the while loop and the acquisition itself is inside.
I hope that helps.
07-12-2010 05:00 AM
@Norick_17 wrote:
ok but with the used express vi where I contin. acquire images I need automatically a while loop - isnt it?
If I get it right properly that is automatically stop the while loop then it is not neccasary. You can configure the start and stop of the acquisition and along with the stop of acquisition you can stop the while loop and it is important to close the session here.