Hey. I’ve been working on our Vision Processing script for the past few days and I’ve ran into a problem that I have no idea how to fix. Sometimes, without any apparent reason, the GetImage freezes and stops the script. I tried copying it’s code and creating my own version of the VI where I pass a “Timeout” value to the Wait VI, and as expected, at some times, instead of freezing the code it waits until it times out and returns a blank image.
The Get Image VI returns when an image is available. At the lower levels, it does have a timeout, but that wasn’t exposed up higher. If it doesn’t return, it means that no image has been requested or sent by the camera. Make sure that the Acquire MJPG Loop is running and that the camera is connected, powered, etc.
I checked, and the MJPG Loop VI is called at the beginning of the Vision Processing VI, as it is in the default code. Should it be called at any other point?
Plus, I am pretty sure the camera doesn’t lose connection or power, since an updated video stream is still shown in the dashboard, even after we lose the connection in the code.