08-19-2016 07:01 AM
Once the image renders to the front panel it stays on the front panel even after the IMAQ dispose executes.
08-19-2016 07:27 AM
Once the image renders to the front panel it stays on the front panel even after the IMAQ dispose executes
Please Check with the VI Attached and Correct me whether my understanding iswrong or LabVIEW is not working as expected.
08-19-2016 07:29 AM - edited 08-19-2016 07:36 AM
Palanivel:If i understand correctly, other's interpretation you might need to pass error wire through the sequence structure.
Edit: Or the image wire has to come after the sequence structure to dispose.
08-19-2016 08:03 AM - edited 08-19-2016 08:05 AM
@udka wrote:Palanivel:If i understand correctly, other's interpretation you might need to pass error wire through the sequence structure.
Edit: Or the image wire has to come after the sequence structure to dispose.
Thanks uday,
But Even then the image will disappear once dispose VI is called/Executed.
08-19-2016 08:09 AM - edited 08-19-2016 08:13 AM
I am sorry whether i understood your question. Let me rephrase it
-When you use dispose the image reference will be deleted.
-If you still want to display image in your indicator you can use snapshot mode in indicator which will make copy of image.
Edit:The error wire has to pass from left to right through sequence structure.Same for Image wire.
08-19-2016 10:24 AM
drdjpowell is incorrect, the sequence structure is NOT necessary. The error wire data processes the data flow. The picture in the indicator persist if the picture (or its reference) is destroyed. Looking at the picture wire is is copied to the picture and 1 copy to destroy.
Sequence structures are a good tool when you want the software to stop everything and do this 1 sequence step then the next etc etc till sequence is finished then go back to multitasking, multithread....
Rich J
08-19-2016 03:34 PM
Unfortunately I beg to differ drjdpowell
08-19-2016 04:41 PM
I am not supprised, some of the WORST LabVIEW I have seen was in shipping examples that came with equipment.
My guess is LabVIEW is not even on the minds of manufacturers until soms askes sales if it has LabVIEW support.
Then they have one of their programmers (who is probably great with embedded C) throw together some LabVIEW.
08-20-2016 11:48 AM
OK, I'm going to join this discussion and say that The Good Doctor is correct, without the Sequence Structure you have a Race Condition, and with the Sequence, you impose an "order" and prevent Race Conditions. Unfortunately, the particular example using Images is a bit quirky because a lot of other things "get in the way" (like the amount of time to draw the Image, and whether or not it persists when the Image (buffer) is Disposed, but that's (mainly) irrelevant.
I've redraw the key elements, using a little "artistic license" to arrange the wires to make the point. On the left, where ordering of operations is governed by the Sequence, the Image output tunnel will not be populated until all of the functionality inside the Sequence is satisfied (Data Flow 101), in particular, until the data has been "saved" in Image (the ephemeral nature of drawing Images, as I noted above, makes this a difficult example to see things clearly, but there you have it). The version on the right, without the Sequence structure (and redrawn for emphasis) is the classic Data Flow Indeterminacy Problem -- you have no way of knowing which will be done first, the drawing of Image2 or the disposal of the Image.
Bob Schor
08-21-2016 07:44 AM