Syncing Multiple Camera Events

We’ve developed 2 reliable subVIs…one for getting the pink and one for the green but the issue we’re having is that when both are running from the same image source each output from the subVIs intermittently goes to 0.

With only one subVI connected at a time the outputs are reliable and work great but as soon as we connect the same image source to both subVIs they both alternate between the correct values and 0.

I have a feeling it has something to do with the timing but I’m not exactly sure how to fix it…we’ve put both of the subVIs in a for loop to attempt to sync the outputs with no luck. Any ideas?

We just figured this one out…we ended using a sequence structure that has the Get Image block in each frame. Before we were trying to access the same file pointer simultaneously by our 2 subVIs but now each one takes its turn processing the camera image.

This likely had to do with side effects on the input image. It is completely valid to process the images in parallel, but many of the image processing VIs allow you to wire up a destination image. If you don’t wire it, they modify the input and reuse it as the output. This works great in isolation, but not when someone else is trying to read the image at the same time. You may want to probe the input to the second processing to make sure it is really what you think it is and isn’t a modified image.

You can also look at the examples for a comparison.

Greg McKaskle